For detailed usage, checkout the Scrape API Reference.
Installation
Usage
Response
The Start Scrape JobPOST /scrape endpoint will return a jobId in the response which can be used to get information about the job in subsequent requests.
GET /scrape/{jobId}/status will return the following data:
GET /scrape/{jobId} will return the following data:
pending, running, completed, failed. There can also be other optional fields like error with an error message if an error was encountered, and html and links in the data object depending on which formats are requested for the request.
To see the full schema, checkout the API Reference.
Session Configurations
You can also provide configurations for the session that will be used to execute the scrape job just as you would when creating a new session itself. These could include using a proxy or solving CAPTCHAs. To see all the different available session parameters, checkout the API Reference or Session Parameters.Scrape Configurations
You can also provide optional parameters for the scrape job itself such as the formats to return, only returning the main content of the page, setting the maximum timeout for navigating to a page, etc.Batch Scrape
Batch Scrape works the same as regular scrape, except instead of a single URL, you can provide a list of up to 1,000 URLs to scrape at once.Response
The Start Batch Scrape JobPOST /scrape/batch endpoint will return a jobId in the response which can be used to get information about the job in subsequent requests.
GET /scrape/batch/{jobId}/status will return the following data:
GET /scrape/batch/{jobId} will return the following data:
Hyperbrowser’s CAPTCHA solving and proxy usage features require being on a
PAID plan.pending, running, completed, failed. The results of all the scrapes will be an array in the data field of the response. Each scraped page will be returned in the order of the initial provided urls, and each one will have its own status and information.
To see the full schema, checkout the API Reference.
As with the single scrape, by default, batch scraping is handled in an asynchronous manner of first starting the job and then checking its status until it is completed. However, with our SDKs, we provide a simple function (client.scrape.batch.startAndWait) that handles the whole flow and returns the data once the job is completed.