number
The HTTP status, mirrored in the body for convenience.
string
A stable, machine-readable code. Branch on this — the wording of
message may change; the code won’t.string
A human-readable explanation of what went wrong.
Failed calls are free. Because credits are charged only on success, an error never costs you anything — see Credits.
Statuses
400 — Validation error
400 — Validation error
The request body didn’t pass validation — a missing
url, a non-http scheme, an out-of-range maxAge, or requesting the json format without jsonOptions. Fix the request and retry.402 — Insufficient credits
402 — Insufficient credits
Your workspace doesn’t have enough credits to cover the call. It’s rejected up front, before any work runs, so nothing is charged. Top up and retry.
404 — Not found
404 — Not found
The resource doesn’t exist — an unknown job, crawl, or batch id — or a
cacheOnly scrape found no fresh capture to serve. A cacheOnly miss is expected and never triggers a live fetch; see Caching.422 — Origin unreachable
422 — Origin unreachable
The target site did not respond, so there was nothing to return. This says something about that URL rather than about our service, and retrying it will not change the answer: treat it as a dead address and move on. Nothing was charged.
429 — Rate limited
429 — Rate limited
You’ve sent requests faster than your allowance. Back off and retry after a short delay, ideally with exponential backoff.
504 — Timed out
504 — Timed out
The page ran past the 90-second synchronous budget. The fetch keeps going in the background, so
the capture usually lands in the cache and an immediate retry returns it quickly. Pages that hit
this are almost always behind heavy bot protection. If you would rather not wait at all, send
async: true and poll the job instead.5xx — Server error
5xx — Server error
Something went wrong on our side, or the target page couldn’t be delivered within the time budget. These are safe to retry — the failed call wasn’t charged.
Handling errors
Readcode to decide what to do, not the HTTP status alone:
VALIDATION_ERROR— fix the request; retrying as-is won’t help.UNAUTHORIZED— check the key.INSUFFICIENT_CREDITS— top up, then retry.NOT_FOUND— forcacheOnly, fall back to a live fetch if you want the page.REQUEST_TIMEOUT— retry once; the background fetch usually makes the second call fast. Useasync: trueif you would rather not wait.UPSTREAM_UNREACHABLE— the site is not answering; do not retry it.TOO_MANY_REQUESTSand5xx— retry with exponential backoff.