Document automation
Data in, typeset documents out — without leaving your network
One API call turns a record into a finished PDF. Batch it to thousands, route it for approval, and never send a customer's payload to someone else's renderer.
AGPLv3 · Self-hostable · No per-document fees
{
"template": "service-agreement",
"engine": "typst",
"source": { "sheet": "Q3-clients" },
"flow": "legal-review"
}
→ 412 documents · 180ms median · 0 failed Why teams move off hosted document APIs
Convenient until the payload matters
Hosted generation is the right call for plenty of products. It stops being the right call when the data in the document is the data you are contractually obliged to protect.
Your customer data goes to their servers
Hosted document APIs require you to POST the payload — names, salaries, pricing, medical details — to a third party for every render. That is a data-processing relationship your security review has to approve.
Cost scales with success
Per-document pricing means the bill grows exactly as fast as your usage. Volume you can forecast becomes a line item you cannot control.
Rendering is a black box
When output differs between two runs you cannot inspect the renderer, pin its version, or reproduce the environment that produced yesterday's file.
The pipeline
Five stages, each one re-runnable
A failed render does not lose the mapping that produced it. Re-run one stage, or one record, without rebuilding the job.
What it does
Automation that survives contact with real documents
Generating one document is easy. These are the parts that decide whether a system holds up at the four-hundredth.
Data-driven generation
Pull from CRMs, databases, spreadsheets and APIs to populate documents. Salesforce and HubSpot connectors, direct database connections, and REST for anything else.
Workflow engine
Route documents to the right approver with conditional logic, automatic escalations, SLA monitoring, and notifications that fire from the document's own state.
Smart templates
Conditional content blocks and dynamic clause selection driven by a business rule engine. One template emits the right variant instead of four templates drifting apart.
Batch processing
Generate thousands of documents in a single job, with progress tracking, per-record error reporting, and safe re-runs of only the records that failed.
Deterministic rendering
Identical inputs produce byte-identical PDFs across workers, so diffs are meaningful and a re-render is never a surprise.
API and webhooks
Everything the UI does is available over REST, with webhooks for build completion, approval transitions, and signature events.
An honest comparison
Self-hosted against a hosted rendering API
Hosted document APIs are well-built and genuinely faster to adopt. The differences below are architectural rather than a judgement about quality.
Written about the common architecture of hosted rendering services, not any single vendor. Some offer VPC or on-premise deployment at enterprise tiers — check the specific terms of whatever you are comparing against.
Every build is accounted for
When a document is wrong, you can find out why
Each build records the template version, the source record, and the engine that produced it. Debugging is a lookup rather than a reconstruction.
- 01 The job is queued With the source, the template version, and the flow it will follow.
- 02 Records map to fields Failures are reported per record, not per job.
- 03 The engine renders Pinned version, deterministic output, byte-identical on re-run.
- 04 Delivery fires Store, email, or webhook — with the artifact hash recorded.
Who this is for
Where self-hosting earns its cost
If a hosted API already clears your security review and your volume is modest, use it. These are the cases where it does not.
Platform teams
You already run Postgres and object storage. Document generation becomes another service in the cluster rather than another vendor in the security review.
Regulated SaaS
You generate documents containing your customers' data and cannot forward that payload to a third party under your own DPA.
High-volume operations
Statements, invoices, and catalogs at a scale where per-document pricing stops being rational.
Teams with real layout needs
Typesetting that holds up in print — proper hyphenation, widow control, and tables that break correctly across pages.
Before you commit