API
JSON in, bytes or JSON out. One key, no OAuth dance, no SDK required. Every response carries the credits it used.
Authentication
Send your key in the X-API-Key header. Keys are created in the dashboard, shown once, and up to three can be active at a time.
curl -X POST https://api.docufinery.com/api/v1/render \
-H "X-API-Key: dk_live_..." \
-H "Content-Type: application/json" \
-d '{"markup": "# Invoice", "format": "md"}' \
--output invoice.pdfOperations
Everything below is live. Credit costs are the ones the server charges.
| What it does | Endpoint | Credits |
|---|---|---|
| Render markup to PDF | POST /api/v1/render | 1 per document, +1 per 10 pages over 10 |
| Render many documents | POST /api/v1/render/batch | 1 per document, failures refunded |
| Render a stored template | POST /api/v1/render/from-template | 1 per document |
| Merge PDFs | POST /api/v1/pdf/merge | 1 per operation |
| Split a PDF | POST /api/v1/pdf/split | 1 per operation, returns a ZIP |
| Compress a PDF | POST /api/v1/pdf/compress | 1 per operation |
| Rotate pages | POST /api/v1/pdf/rotate | 1 per operation |
| Watermark pages | POST /api/v1/pdf/watermark | 1 per operation |
| Reorder pages | POST /api/v1/pdf/reorder | 1 per operation |
| Extract pages | POST /api/v1/pdf/extract-pages | 1 per operation |
| Unlock a PDF | POST /api/v1/pdf/unlock | 1 per operation, password required |
| Strip metadata | POST /api/v1/metadata/strip | 1 per operation |
| Redact text, patterns or regions | POST /api/v1/redact | 2 per operation |
| Inspect metadata | POST /api/v1/metadata/inspect | free, no API key |
| Parse a document to markdown | POST /api/v1/parse | 1 per 10 text pages, 1 per OCR page |
| Parse many documents | POST /api/v1/parse/batch | same rates, failures refunded |
| Convert a document | POST /api/v1/convert | 1 per document |
| Convert one small document | POST /api/v1/convert/free | free, no API key |
| Extract tables from a PDF | POST /api/v1/tables | 3 per table-bearing page |
| Find the tables and the price first | POST /api/v1/tables/detect | free, no API key |
| Capture a URL as evidence | POST /api/v1/capture | 1, or 5 retained with a timestamp and manifest |
| Verify a capture | GET /api/v1/capture/{id}/verify | free, no API key |
| Capture a URL repeatedly | POST /api/v1/capture/schedule | priced per capture |
| Read a web page | POST /api/v1/extract | 1 per page |
| Read one page, truncated | POST /api/v1/extract/preview | free, no API key |
| Clean a spreadsheet | POST /api/v1/spreadsheet/clean | 2 plus 1 per 500 rows |
| Preview what cleaning would change | POST /api/v1/spreadsheet/preview | free, no API key |
| Turn a chat or mail export into an archive | POST /api/v1/archive | 2 per export |
| Get a YouTube transcript | POST /api/v1/youtube | 1 per video |
| Get a transcript, truncated | POST /api/v1/youtube/preview | free, no API key |
| Store, list, update, delete templates | /api/v1/templates | free |
Errors
Every error returns the same body shape, so one handler covers all of them. These codes are stable: changing one is a breaking API change.
{"error": {"code": "too_many_pages", "message": "...", "limit": 500, "got": 912}}| Code | HTTP |
|---|---|
| missing_api_key | 401 |
| invalid_api_key | 401 |
| invalid_input | 422 |
| insufficient_credits | 402 |
| unsupported_format | 422 |
| too_large | 413 |
| too_many_pages | 422 |
| render_failed | 500 |
| rate_limited | 429 |
| not_found | 404 |
| internal_error | 500 |
Limits
Checked before any work starts, so an over-limit request costs nothing rather than failing halfway through and being refunded.
| Limit | Value |
|---|---|
| Maximum upload size | 100 MB |
| Maximum pages per request | 500 |
| Requests per minute (sync) | 60 |
| Requests per minute (batch) | 10 |
| Concurrent requests per key (sync) | 5 |
| Concurrent requests per key (batch) | 2 |
Machine-readable
These exist so a client generator, or an agent, can read the API without a human in the loop.
- /docs — Interactive documentation you can call the API from
- /openapi.json — OpenAPI 3.1 specification
- /postman/collection.json — Postman collection
- /llms.txt — Short summary for language models
- /llms-full.txt — Full summary, every operation
- /facts — What this product does, and what it explicitly does not
Cost
Credits are bought once and never expire, and a failed operation is refunded automatically. Packs and what each operation costs.