Skip to main content

Scrape

POST /scrape runs a synchronous scrape on a URL and returns content in the requested formats. Messora’s native anti-bot engine handles protections automatically.

Endpoint

Authentication

X-API-Key header required. See Authentication.

Parameters

string
required
Public URL to scrape. Internal URLs (RFC1918, loopback, cloud metadata) are rejected by the SSRF guard.
string[]
default:"[\"markdown\"]"
Desired output formats. Accepted values: markdown, json, raw.
object
JSON schema for structured extraction. Required when formats includes json.
string
Context prompt to guide structured extraction (used with json_schema).
boolean
default:"false"
If true, render JavaScript before extraction (headless browser).
boolean
default:"false"
If true, extract only the main page content, removing navigation, footers, and sidebars.
integer
default:"60"
Maximum wait time in seconds (1–180).
integer
Extra wait in milliseconds after load (useful with render_js).
integer
default:"1"
Maximum pages to extract in a single call (1–50). Multiplies the cost: markdown/raw charge 1 credit per page, so max_pages: 50 costs up to 50 credits. Ignored when formats includes json (flat 10 credits).
string[]
Attribution tags for usage records (up to 10 tags).
The full parameter list — including fact_check, max_age_ms, max_depth, follow_subdomains, include_frames and parse_pdf — is generated from the schema on the POST /scrape reference page.

Cost

Failures (blocked_antibot, timeout, extraction_failed) do not consume credits.

Example

Successful response

Structured extraction (JSON)

To extract structured data, include json in formats and provide a json_schema:
Structured extraction costs 10 credits per request. A failed run (blocked_antibot, timeout, extraction_failed) refunds all 10.

Response status

Errors