POST /v1/crawl
Crawl an entire website asynchronously, following internal links up to a configurable page limit. The crawl is enqueued as a background job and returns a jobId immediately. Poll GET /v1/crawl/:id (or GET /v1/jobs/:id) for status, then read the pages from GET /v1/crawl/:id/results.
Optionally provide a webhook URL to receive a signed POST when the crawl finishes.
Start a crawl
POST /v1/crawl
Content-Type: application/json
x-api-key: YOUR_KEYBody
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
url | string | Yes | Starting URL. The crawl stays on the same domain. | |
maxPages | number | No | 10 | Maximum pages to scrape. Clamped to your plan's crawl_pages cap: Free 50, Hobby 500, Pro 10,000, Scale 50,000. |
limit | number | No | Alias for maxPages. Takes precedence when both are set. | |
maxDepth | number | No | Maximum link depth from the seed URL (seed = depth 0). | |
includePaths | string[] | No | Only crawl URLs whose path matches one of these prefixes/globs. | |
excludePaths | string[] | No | Skip URLs whose path matches one of these prefixes/globs. | |
allowBackwardLinks | boolean | No | false | Allow following links that climb above the seed path. |
ignoreRobotsTxt | boolean | No | false | robots.txt is respected by default; set true to opt out. |
webhook | string | No | Completion webhook URL. webhookUrl is accepted as an alias. | |
scrapeOptions.timeout | number | No | Time in milliseconds the fetch levels may spend on each page, from 1000 up to your plan's ceiling (30000 on Free, 120000 on paid plans), as timeout on scrape. Outside the range or above your plan's ceiling is a 400 with code: "invalid_timeout". | |
tech | "profile" | "deep" | No | Tag audit: list the technologies on every crawled page, plus a site summary. profile costs the crawl price; deep renders each page in a real browser for 5 credits a page, at most 200 pages. See Tag audit. | |
sitemap | "include" | "skip" | No | "skip" | "include" also crawls the URLs listed in the site's sitemap (same host, same path rules, at link depth 1). Reading the sitemap is free. |
formats | string[] | No | ["markdown"] | What each page carries: markdown, html (the page after includeTags, excludeTags and removeBase64Images; the fetched HTML when none is set), rawHtml (the fetched HTML), links (absolute link URLs). |
onlyMainContent | boolean | No | false | Remove navigation, headers, footers and other boilerplate from each page's Markdown. As on /v1/scrape, it does not prune html or links. If cleaning would leave less than 500 characters and under 30% of the page, the whole page is returned instead. |
includeTags | string[] | No | Keep only these CSS selectors on each page. | |
excludeTags | string[] | No | Remove these CSS selectors from each page. | |
removeBase64Images | boolean | No | false | Drop inline base64 images from each page. |
scrapeOptions | object | No | The per-page options above (formats, onlyMainContent, includeTags, excludeTags, removeBase64Images) in one object, alongside scrapeOptions.timeout. It wins over the top-level names. |
screenshot, json, summary and branding are not produced for crawled pages: asking for them returns 400 with code: "unsupported_format". Every page already carries listing, the free structured data found on it (JSON-LD and Open Graph).
Credits: 1 per page crawled, charged as the crawl runs, whatever formats and cleaning options you choose. A page whose content is the same as a page the crawl already returned (for example /pricing and /pricing/, or a link that redirects to a page already crawled) is not charged, not counted against maxPages and not returned. Addresses that differ only in a #fragment, letter case of the host, a default port, tracking parameters (utm_*, gclid, fbclid and similar) or query parameter order are fetched once. If the site answers 429 Too Many Requests, the crawl pauses before its next request (2 seconds, doubling up to 60 seconds) and tries the page again; refused requests are free, and a site that keeps refusing ends the crawl with a rate_limited note in error. On Free, the crawl stops when your balance runs out. On a paid plan, auto-reload adds credits in $5 blocks and the crawl keeps going; it stops if auto-reload is off, the charge fails or your monthly limit is reached (Pricing). If the job queue is unavailable, the call returns 503 with status: "failed" instead of queuing a job that would never run.
Example request
curl -X POST https://api.superscraper.dev/v1/crawl \
-H "x-api-key: ss_live_xxxxxxxxxxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{
"url": "https://www.northside-roasters.example",
"maxPages": 25,
"webhook": "https://myapp.example.com/webhooks/crawl-done"
}'Response (HTTP 202)
{
"jobId": "01hwz3p4q8k2nmx7vyd6cbse1f",
"status": "queued",
"url": "https://www.northside-roasters.example",
"options": {
"limit": 25,
"allowBackwardLinks": false,
"ignoreRobotsTxt": false
},
"message": "Crawl queued. Poll GET /v1/crawl/:id (or /v1/jobs/:id) for status."
}GET /v1/crawl/:id
Poll a crawl job for its current status. GET /v1/jobs/:id returns the same fields.
GET /v1/crawl/01hwz3p4q8k2nmx7vyd6cbse1f
x-api-key: YOUR_KEYResponse fields
| Field | Type | Description |
|---|---|---|
id | string | Job ID |
url | string | Starting URL |
status | string | "queued", "running", "completed", "failed", or "cancelled" |
result_url | string | null | Where the stored pages live (present when status: "completed"). GET /v1/crawl/:id/results reads it for you. |
pages_scraped | number | Pages scraped so far |
error | string | null | Error message (present when status: "failed") |
created_at | string | ISO 8601 timestamp |
completed_at | string | null | ISO 8601 timestamp when the job finished |
Example: job in progress
{
"id": "01hwz3p4q8k2nmx7vyd6cbse1f",
"url": "https://www.northside-roasters.example",
"status": "running",
"result_url": null,
"pages_scraped": 8,
"error": null,
"created_at": "2026-05-30T14:22:10Z",
"completed_at": null
}Example: job done
{
"id": "01hwz3p4q8k2nmx7vyd6cbse1f",
"url": "https://www.northside-roasters.example",
"status": "completed",
"result_url": "https://api.superscraper.dev/v1/crawl/01hwz3p4q8k2nmx7vyd6cbse1f/results",
"pages_scraped": 24,
"error": null,
"created_at": "2026-05-30T14:22:10Z",
"completed_at": "2026-05-30T14:24:37Z"
}GET /v1/jobs
List your 20 most recent crawl jobs.
GET /v1/jobs
x-api-key: YOUR_KEYResponse
{
"jobs": [
{
"id": "01hwz3p4q8k2nmx7vyd6cbse1f",
"url": "https://www.northside-roasters.example",
"status": "completed",
"pages_scraped": 24,
"created_at": "2026-05-30T14:22:10Z",
"completed_at": "2026-05-30T14:24:37Z"
},
{
"id": "01hwz2r9j5m1klx4uac3byqd8e",
"url": "https://www.hilltop-coffee.example",
"status": "failed",
"pages_scraped": 3,
"created_at": "2026-05-29T09:15:44Z",
"completed_at": "2026-05-29T09:16:02Z"
}
]
}GET /v1/crawl/:id/results
Read the crawled pages. Tenant-scoped.
curl https://api.superscraper.dev/v1/crawl/01hwz3p4q8k2nmx7vyd6cbse1f/results -H "x-api-key: ss_live_xxxxxxxxxxxxxxxxxxxx"{
"jobId": "01hwz3p4q8k2nmx7vyd6cbse1f",
"status": "completed",
"pageCount": 24,
"totalPages": 24,
"truncated": false,
"pages": [
{
"url": "https://www.northside-roasters.example/",
"ok": true,
"markdown": "# Northside Coffee Roasters ...",
"metadata": { "title": "Northside Coffee Roasters", "statusCode": 200 }
}
]
}Each page has metadata with the page title and HTTP statusCode when known. With onlyMainContent, metadata.contentFilter is "main_content", or "fallback_full_page" when cleaning would have removed most of the page. Whenever you ask for cleaning, metadata.filterApplied says whether the cleaned result was returned (true, even when your options left the page empty) or the unfiltered page was returned instead (false; with filterError: shaping_failed when cleaning failed, shaping_degraded when the page was too large or too slow to clean and its text was returned). html, rawHtml and links appear when you asked for them in formats.
A crawl run with tech (a tag audit) adds tech to every fetched page and a tech_summary to this response.
When results are held in object storage, this endpoint answers 302 to the stored file, so follow redirects. Before the crawl finishes, or when no pages were stored, it answers 404 with code: "results_not_available" and a message that says why.
DELETE /v1/crawl/:id
Cancel a running crawl. Marks the job cancelled so the worker stops persisting new pages and
you stop polling. A job that has already reached a terminal state (completed, failed, or
cancelled) reports that state instead of being cancelled. Tenant-scoped and idempotent.
curl -X DELETE https://api.superscraper.dev/v1/crawl/01hwz3p4q8k2nmx7vyd6cbse1f \
-H "x-api-key: ss_live_xxxxxxxxxxxxxxxxxxxx"{ "jobId": "01hwz3p4q8k2nmx7vyd6cbse1f", "status": "cancelled", "cancelled": true }Webhook payload
When a webhook URL is provided, SuperScraper POSTs a signed envelope when the crawl finishes. The event is crawl.completed or crawl.failed. The body carries a reference to the stored pages and a bounded sample (25 entries by default), never the whole crawl:
{
"event": "crawl.completed",
"timestamp": 1751500000,
"data": {
"jobId": "01hwz3p4q8k2nmx7vyd6cbse1f",
"status": "completed",
"pagesScraped": 24,
"resultUrl": "https://api.superscraper.dev/v1/crawl/01hwz3p4q8k2nmx7vyd6cbse1f/results",
"resultStorage": "database",
"resultsStored": 24,
"resultsTruncated": false,
"totalResults": 24,
"sampleTruncated": false,
"results": [ { "url": "https://www.northside-roasters.example/", "ok": true } ]
}
}When pages were skipped because their content repeated a page already returned, data.duplicatesSkipped gives the count.
Fetch the pages with GET /v1/crawl/:id/results. Signature verification and retries are described in Webhooks. Respond with any 2xx status to acknowledge the webhook.