spend_cap_exceeded
HTTP 402. The account is on a paid plan and the next render would cross the monthly spend cap. Nothing was rendered and nothing was billed.
{ "error": { "type": "spend_cap_exceeded", "message": "Monthly spend cap of $50.00 reached.", "docs_url": "https://galleyrender.com/docs/errors/spend_cap_exceeded", "details": { "period": "2026-09", "spend_cap_usd": 50, "spent_usd": 49.994, "resets_on": "2026-10-01", "raise_cap_url": "https://galleyrender.com/docs/billing/spend-cap" } }}Why this happens
Section titled “Why this happens”One raise site: the pre-flight limit check, for accounts on every plan including free — the
cap is your own ceiling, and a render whose estimate would cross it does not start. A free account
usually meets quota_exceeded first, because 200 renders a month
costs well under the $50 default cap, but a lowered cap bites before the quota does.
details.estimated_units and details.estimated_usd say what the render was estimated to cost:
one unit for png/jpg, and the template version’s declared expected_pages for a PDF.
The cap defaults to $50 a month and is stored per account. It is enforced against Galley’s own ledger of what the period has cost at $0.006 per PNG/JPG and $0.015 per PDF page, not against anything Stripe reports back, because meters only reconcile at invoice time. That is what makes it a hard stop rather than an alert after the fact.
It exists so that a runaway loop costs you dinner rather than a holiday.
How to fix it
Section titled “How to fix it”Decide whether the spend is real. If it is, raise the cap — the API has no endpoint for it, so
ask through the dashboard or support@galleyrender.com. If it is not, find what is looping: check
GET /v1/usage for by_format, and remember that a PDF costs per page, so a
long report is not one unit. Identical repeat renders are free; if your spend is climbing on
repeated work, something is varying in data or options. See
Caching and signed URLs.
Does retrying help?
Section titled “Does retrying help?”No. The cap holds until it is raised or until details.resets_on.