Docs menu
- Docs
- Guides
- Credits and pricing
Credits and pricing
You pay in credits, only for a page we deliver. The route that fetched the page sets its price. Blocks we detect are free, and so are our errors. X-Credits-Charged on every answer says what the request cost.
What a page costs
Leave engine and proxy_tier out, and we try the cheapest route first.
| Route | Credits a page | Included data | Each started 128 KiB above | Most a page costs |
|---|---|---|---|---|
| HTTP, datacenter | 1 | 64 KiB | +1 | 129 |
| HTTP, residential | 8 | 64 KiB | +8 | 520 |
| Browser, datacenter | 15 | 1 MiB | +1 | 87 |
| Browser, residential | 32 | 64 KiB | +8 | 544 |
Lowest credits per page, before page size. Each site has its own price: a site we have not priced yet costs at least 8 on residential and Browser. Run check_site (free) to see the price for your site.
- Included data means everything we download to build the page, not only the HTML you get back. Above it, each started 128 KiB adds the amount in the next column. When we open the site’s home page first to look like a visitor (our routing choice, never yours), those bytes are ours up to a fixed allowance per route. The same goes for a first try that was blocked or stalled when our retry then got the page. Above the allowance, those bytes count like page bytes. All bytes count toward the byte cap.
- Most a page costs is the largest page we fetch on that route, on most sites, before extras.
- Extras: JSON output (
response_types=json) and a premium country add +1 each. A screenshot adds +1 (viewport) or +2 (full), only when its link is delivered. Page actions (actions) add +3 per page, however many actions run. Markdown, text, links, metadata, page data, compact HTML and network capture (network=true) add nothing. - A copy served for
max_agecosts the cache price from the price list, never more than the fetch it copies. See Reuse a recent copy. - Schema extraction (
schema) adds a base and a rate per started 1,000 weighted tokens (input + 5 × output), only when the answer matches the schema. The answer’screditssays what it added; a failed extraction is free, and the page is still charged. - Documents: when the
urlanswers with a PDF, DOCX, PPTX or XLSX file, it adds the document price per PDF page, per PPTX slide, per started 3,000 characters of DOCX text, or per started 1,000 non-empty XLSX cells.X-Document-Unitssays what we counted. We count after the file arrives; if your balance cannot cover it, nothing is sent and nothing is charged. A scanned or locked file is a free 422document_unreadable. - Engines and proxy tiers explains the routes.
Where the credits went
Three headers split X-Credits-Charged in parts. They always add up to it.
| header | what it paid for |
|---|---|
X-Credits-Route |
Reaching the page: the engine and proxy tier, a premium country, and data above the included amount. |
X-Credits-Output |
What we made of the page: JSON output, a schema extraction, and a document’s pages. |
X-Credits-Other |
The rest: page actions, and on a monitor’s page the monitor check. |
The screenshot is not in them, as it is not in X-Credits-Charged. When we
lower the charge, for example because the browser found no more text than
the HTTP page, the cut comes off the route first, then other, then output.
What is free
- A block we detect: a 422
blockedwithX-Billing: blocked. - Every error of ours, 4xx and 5xx. Errors carry no
X-Credits-Charged. - A target that answers 5xx.
- A page action that cannot run: a 422
action_failed. Above the failure cap, it is charged.
A free answer carries no page content: only the status, our headers and, for a block, our JSON error.
GET /v1/tier,GET /v1/stats/domain, and the MCP toolcheck_site.- Submitting a batch. Each URL is charged on its own, when we fetch it.
Cap what one page may cost
max_creditsis the most one page may cost. We skip any route above it, andX-Ladder-Truncated: truesays routes were skipped. If no route is left, the answer is a free 400max_credits_too_lowbefore any attempt.- A page whose bytes would cost more than
max_creditsis cut at the bytes it pays for: a 200 withX-Truncated: max_credits, charged at mostmax_credits.
Check a site first
Before you spend credits on a new site, ask what it costs and how well it works. All three are free. The first shows the success of each route over the last days, the second shows today’s price, and the MCP tool shows both:
curl -s -H "Authorization: Bearer $MEG_API_KEY" \ "https://get.megalania.io/v1/stats/domain?host=lab.megalania.io&days=7"
curl -s -H "Authorization: Bearer $MEG_API_KEY" \ "https://get.megalania.io/v1/tier?host=lab.megalania.io"
{"name": "check_site", "arguments": {"host": "www.example.com"}}/v1/stats/domainanswers each route’ssuccess_rateandblock_sharefor the whole platform. A route counts only the days with at least 3 customers and at least 20 requests behind it./v1/tieranswersprice, the quote for a typical page on the host, andquotes, what each route we can use today costs. A request pays the route that delivers the page. Before response types and premium geo, the quotes equal the base prices on the Plan page.check_sitereturns both, assuccessandprice, and says when there is no data yet.
Fetch, extract and lists explains every field.