Executing custom JavaScript
GET app.scrapingbee.com/api/v1/?url=https://httpbin-scrapingbee.cleverapps.io/&render_js=true&js_scenario={ "instructions": [ {"evaluate": "console.log('foo')"} ] }
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
url | string | The URL you want to scrape | |
render_js | boolean | Render the website in an headless browser | |
js_scenario | string | ||
premium_proxy | boolean | Use premium residential proxies | |
country_code | null | Premium proxy geolocation. | |
block_ads | boolean | Block ads on the page you want to scrape | |
block_resources | boolean | Block images and CSS on the page you want to scrape | |
cookies | null | Pass custom cookies to the webpage you want to scrape | |
custom_google | boolean | Set to true to scrape Google | |
device | string | Control the device the request will be sent from | |
forward_headers | boolean | Forward particular headers to the webpage, as well as other headers generated by ScrapingBee. | |
forward_headers_pure | boolean | Forward only particular headers to the webpage, and nothing else. | |
json_response | boolean | Wrap response in JSON. | |
return_page_source | boolean | Return the original HTML before the JavaScript rendering | |
session_id | boolean | Route multiple API requests through the same IP address. | |
transparent_status_code | boolean | Transparently return the same HTTP code of the page requested. | |
wait | number | Additional time in ms for JavaScript to render | |
wait_for | null | CSS selector to wait for in the DOM. | |
window_height | number | Height, in pixel, of the viewport used to render the page you want to scrape. | |
window_width | number | Width, in pixel, of the viewport used to render the page you want to scrape. |