Skip to content

Scrape and parse (POST)

POST
/v1/scrape/{parserId}

Fetch one URL and extract it with an owned parser. Sync calls time out after 120 seconds. Set async=1/true (or POST async: true) to submit queue-backed work and receive 202 with job and batch IDs. POST can write rows to a database sink instead of returning extracted data.

Credits: default fetch 1, default browser 5, high-quality fetch 10, high-quality browser 25, hardcore 80. Invalid/private target URLs return 422. A class concurrency cap returns 429 with code concurrency_limited.

parserId
required
string

Your parser ID from the dashboard.

object
url
required
string format: uri
async
boolean
sink

Return data or write rows to an owned database.

object
mode
required
string
default: return
Allowed values: return database
database
string
/^[a-z0-9-]{1,32}$/
table
string
/^[a-z0-9_]{1,48}$/
key

Upsert key columns; defaults to _url for parser jobs.

Array<string>

Extracted structured data.

Extracted data matching your parser schema.

object
X-Credits-Used
integer

Credits consumed by this request.

X-Credits-Remaining
integer

Remaining credit balance.

Asynchronous job accepted.

object
job_id
string
batch_id
string
sink

Return data or write rows to an owned database.

object
mode
required
string
default: return
Allowed values: return database
database
string
/^[a-z0-9-]{1,32}$/
table
string
/^[a-z0-9_]{1,48}$/
key

Upsert key columns; defaults to _url for parser jobs.

Array<string>

Missing URL or parser ID.

Missing or invalid API key.

object
error
required
string
Example
invalid request
field

Field that failed validation.

string
detail
string
hint
string

Insufficient unreserved credits.

object
error
required
string
Example
insufficient credits
required
required
integer
available
required
integer

Resource missing or not owned by this account.

object
error
required
string
Example
invalid request
field

Field that failed validation.

string
detail
string
hint
string

Validation failed.

object
error
required
string
Example
invalid request
field

Field that failed validation.

string
detail
string
hint
string

Request, concurrency, or plan limit exceeded.

One of:
object
error
required
string
Example
invalid request
field

Field that failed validation.

string
detail
string
hint
string
Retry-After
integer

Seconds to wait when supplied.

Failed to fetch content from target URL.