Fetch a page and return its content
POST/v1/extract
Fetches one URL and returns the representations you ask for. Accepts JSON or
form-encoded bodies (application/x-www-form-urlencoded); the same field names
apply to both.
Request body
urlstringrequiredformatsstring[]only_main_contentbooleaninclude_tagsstring[]exclude_tagsstring[]400 EXTRACTION_SELECTION_EMPTY — adjust the selectors and retry.max_age_msinteger0 forces a fresh fetch.headersobject<string,string>Host and hop-by-hop headers are rejected. See the cache-isolation side effect in the introduction.wait_for_msintegertimeout_msintegercountrystringadvanced_modebooleantrue lets the fetch service escalate based on page signals; false keeps it on the direct engine. This is the supported way to ask for rendering.render_js is deliberately not accepted: it is the platform's paid browser
troubleshooting switch. Sending it returns 400 with code 11000.
Reading the result
data.successis the call's real outcome (see the introduction).data.outputscontains exactly the formats you requested; a requested-but-emptymarkdownis"", an unproducible one isnull.data.meta.strategy_usedisX1/X2/X3and drives the price;data.meta.cache_hittells you whether a snapshot was reused.data.meta.result.status_codeis the target site's status and may benullwhen the fetch service could not observe one — it is not this API's status code.
Request
Responses
- 200
- 400
- 401
- 402
- 403
- 429
- 500
- 502
- 503
- 504
Either a retrieved page or a platform-level failure inside data
(data.success: false).
Response Headers
Always no-store — no intermediary may cache these responses.
The fetch service's own request identifier for this call. Quote it together with
the envelope's request_id in support requests.
The request was rejected — see the error table for the code
The credential is missing, invalid, or expired
The account has no credits or quota left
The credential is valid but not allowed to do this
Too many requests — back off and retry
A fault on our side — retry later, and contact us if it persists
The fetch service failed — retry later
The fetch service is unreachable — retry later
The fetch service did not answer in time — retry later