For the full API schema, see the Crawl API Reference.
Quick Start
1
Install the SDK
2
Crawl a website
Crawling is asynchronous—start the job and then poll for results. The SDKs provide a
startAndWait / start_and_wait convenience method that handles polling for you.Response
Starting a crawl job returns ajobId:
data:
status field on the job can be pending, running, completed, or failed. Each page in data also has its own status and may include an error field if that page failed.
Crawl Options
Control how the crawler traverses the site withcrawlOptions:
Example with URL filters
Example with URL filters
Outputs
Useoutputs.formats to control what data is returned for each crawled page. This works the same as Fetch outputs—you can request markdown, HTML, links, screenshots, structured JSON, or a branding profile.
Structured JSON extraction per page
Structured JSON extraction per page
Pass a JSON Schema to extract structured data from each crawled page. You can use a raw JSON Schema object, a Zod schema (Node), or a Pydantic model (Python).
Output Controls
Control what gets extracted from each crawled page. These work the same as Fetch output controls:Browser & Stealth
Configure how the cloud browser runs. These options apply to all pages in the crawl:Navigation Controls
Control page load behavior and timing for each crawled page:Cache Controls
Control caching behavior for crawl results:Pagination
Crawl results are returned in batches. You can control pagination when retrieving results:
The response includes pagination metadata:
When using
startAndWait / start_and_wait with returnAllPages set to true (the default), the SDK automatically fetches all paginated results and combines them into a single response.