Docs

Crawl

POST /v1/crawl finds and reads pages from a start URL. 1 credit per page crawled. Supports async runs. View as Markdown

POST /v1/crawl finds the pages of a site and reads them. Costs 1 credit per page read. Pass async: true to return immediately with a run id; a request that runs longer than the response window also returns 202 with a run id. Poll GET /v1/runs/{id} for the result. With no includePaths, a start URL that has a path stays under that path.

Product page: /crawl.

Example

curl -s -X POST https://webcrawl.app/v1/crawl \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://docs.example.com/guides","maxPages":25,"excludePaths":["/guides/archive"]}'

Request body

  • url (string (required)): Start URL
  • maxPages (integer): Most pages to read (limit is accepted as an alias)
  • includePaths / excludePaths (string[]): Path scope filters
  • includeSubdomains (boolean): Default false
  • onlyRootDomain (boolean): Restrict to the root domain
  • extractStructured (boolean): Also extract structured data from each page (adds credits per page)
  • async (boolean): Return a run id immediately
  • timeout (integer): Milliseconds per page (default 20000)

Related