crawlId back immediately, then poll it or register a webhook to collect the per-page results. One credit per page scraped.
When to use
- You want every page of a site (or a section of it) as clean data, and you do not have the URL list yourself.
- The job is large enough that waiting on a single request is impractical.
Example request
Send aPOST to /v1/web/crawl. Scope the crawl with limit, maxDepth, and path filters, and control how each page is scraped with scrapeOptions.
Example response
The crawl is accepted right away:Request options
string
required
The site to start from. Must be
http(s).number
default:"100"
Maximum number of pages to scrape. 1–5000.
number
How many links deep from the starting page to follow. 0–10.
string[]
Only follow URLs whose path matches every one of these patterns (e.g.
["^/blog/.*"]). Up to 50.string[]
Skip URLs whose path matches any of these patterns (e.g.
["^/tag/.*"]). Up to 50.boolean
default:"false"
Also follow links into subdomains of the starting site.
boolean
default:"false"
Also follow links that lead off the starting site.
boolean
default:"false"
Treat URLs that differ only by query string as the same page.
string
default:"include"
Whether to seed discovery from the site’s published page list:
skip or include.object
How to scrape each page —
formats, onlyMainContent, includeTags, excludeTags, removeBase64Images, blockAds, renderJs, waitFor, timeout, location, headers, preferStructure, maxAge. Same options as a single Scrape, with per-page formats limited to markdown, html, rawHtml, links, and structured.object
Register a callback instead of polling.
webhook.url receives progress and completion events; webhook.headers are extra headers sent with each callback (e.g. for authentication).Poll for results
PollGET /v1/web/crawl/{id} for progress and per-page results.
Response fields
string
The crawl id.
string
crawl or batch.string
Overall job state:
running, completed, failed, or cancelled.string
The starting URL.
number
Total pages in this job.
number
Pages scraped so far.
number
Pages that failed.
number
Credits consumed so far. One per scraped page.
object[]
Per-page results, each with
url, status (queued, running, completed, failed), depth, error, and data (the scraped page, once completed).A crawl costs one credit per page scraped, reflected in
creditsUsed. Scope the job with limit, maxDepth, and path filters to keep spend predictable, and preview reach first with Map.Next steps
Crawl API reference
Full request and response schema with a live playground.
Map a site
Preview a crawl’s scope without scraping.
Scrape a list of URLs
When you already have the URLs.
Scrape one URL
The per-page primitive behind a crawl.