Public tools API
The website's free PDF tools use an anonymous API that is built for those pages only. What it does, its limits, and why your code should use /v1 instead.
On this page
The free tools on this website, such as the invoice generator, the HTML to PDF converter and the e-invoice validator, work without an account. Behind them is a small, separate API at https://api.castpdf.com/public/v1/tools/*. You may notice its requests in your browser's network panel and wonder whether you can call it from your own code. This page explains what it is and why the answer is no.
What it is
The public tools API serves the tool pages and nothing else. It has no API keys and no accounts: every call is anonymous. In exchange, it is locked down in several ways that make it a poor fit for anything but a person clicking a button on our website:
- A human check. Each call must carry a fresh Cloudflare Turnstile token from the tool page, proving a person is in front of it. A missing, expired or reused token is refused with
403 forbidden. Scripts and servers cannot produce these tokens. - Website only. Browsers may call it only from castpdf.com pages (CORS); other websites are refused.
- Strict limits per address. 10 calls a minute and 100 calls in 24 hours from one IP address (IPv6 addresses count per /64 network), plus a daily ceiling across all visitors. Over a limit, the answer is
429 rate_limitedwith aretry-afterheader. A refused call still counts against your address, so retrying in a loop keeps you locked out. - Small documents. A tool PDF has at most 20 pages, and every input has a size cap well below the regular API's.
- A footer line. Every PDF it makes carries the line "Made with CastPDF · castpdf.com" at the bottom of each page.
- Nothing is kept. Inputs and PDFs are not stored, there is no document log, no signed links and no webhooks.
It is not a supported API. Its paths, fields and limits can change whenever the tool pages change, without notice and without a version number, and it can be switched off. Code written against it will break.
What to use instead
Use the regular API at https://api.castpdf.com/v1 with a free account. The Free plan includes 100 live PDFs a month and up to 30 requests a minute with a live key, and test keys make watermarked PDFs for development that are never counted, at 20 requests a minute. Live PDFs on the Free plan carry the same footer line; paid plans remove it. In return you get everything the tools lack:
- your own templates with versions, and the same invoice and certificate designs as starter templates in the dashboard;
- stored PDFs with signed download links, a document log, background rendering, batches and email delivery;
- webhooks on paid plans, stable versioned endpoints, and an OpenAPI description to generate a client from.
The Quickstart takes a few minutes: create an account, copy a test key and send your first POST /v1/pdf. Plan details are on the pricing page and in usage and billing.