38 PDF operations behind one endpoint. Send base64 files, name a tool, get base64 files back. One billable operation per call — no per-operation credit weighting, no separate URL to learn per tool.
POST /v1/processsk_ keyEvery request carries your secret key as a bearer token. Keys start with sk_ and are created in your dashboard. The x-api-key header is accepted as an alternative for clients that cannot set Authorization.
Authorization: Bearer sk_live_your_key
One POST to https://mostly-pdf.web.app/v1/process with a JSON body of three fields:
| Field | Type | Required | What it is |
|---|---|---|---|
tool | string | yes | Which operation to run — any slug from the table below. |
files | string[] | yes | Input file(s), base64-encoded. Multi-file operations take several. |
options | object | no | Operation-specific settings, e.g. {"degrees":90} or {"ranges":["1-3","5"]}. |
The response returns outputs: an array of base64 result files, in the same order the operation produces them.
curl -X POST https://mostly-pdf.web.app/v1/process \
-H "Authorization: Bearer sk_live_your_key" \
-H "Content-Type: application/json" \
-d '{
"tool": "merge-pdf",
"files": ["<base64 of first.pdf>", "<base64 of second.pdf>"]
}'
const res = await fetch("https://mostly-pdf.web.app/v1/process", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.MOSTLYPDF_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
tool: "rotate-pdf",
options: { degrees: 90 },
files: [Buffer.from(await fs.readFile("in.pdf")).toString("base64")],
}),
});
const { outputs } = await res.json();
await fs.writeFile("out.pdf", Buffer.from(outputs[0], "base64"));
import base64, os, requests
with open("in.pdf", "rb") as f:
payload = base64.b64encode(f.read()).decode()
r = requests.post(
"https://mostly-pdf.web.app/v1/process",
headers={"Authorization": f"Bearer {os.environ['MOSTLYPDF_KEY']}"},
json={"tool": "compress-pdf", "files": [payload]},
timeout=120,
)
r.raise_for_status()
with open("out.pdf", "wb") as f:
f.write(base64.b64decode(r.json()["outputs"][0]))
Pass any slug below as the tool field. Free operations run without a paid plan; where a daily free allowance applies it is listed. Operations marked conversion service run server-side and are the ones that return 501 if that service is not enabled on your account.
| slug | Operation | Input files | Tier | Free allowance | Runs on |
|---|---|---|---|---|---|
chat-with-pdf |
Chat with PDF | one file | Pro | unlimited | ai |
compare-pdf |
Compare PDF | two or more | Free | unlimited | conversion service |
compress-pdf |
Compress PDF | one file | Free | unlimited | conversion service |
crop-pdf |
Crop PDF | one file | Free | unlimited | in-browser engine |
email-to-pdf |
Email to PDF | render | Free | unlimited | render |
excel-to-pdf |
Excel to PDF | one file | Free | unlimited | conversion service |
extract-pages |
Extract Pages | one file | Free | unlimited | in-browser engine |
fill-pdf-form |
Fill PDF Form | one file | Free | unlimited | in-browser engine |
html-to-pdf |
HTML to PDF | render | Free | unlimited | render |
jpg-to-pdf |
JPG to PDF | two or more | Free | unlimited | in-browser engine |
markdown-to-pdf |
Markdown to PDF | render | Free | unlimited | render |
merge-pdf |
Merge PDF | two or more | Free | unlimited | in-browser engine |
ocr-pdf |
OCR PDF | one file | Pro | unlimited | conversion service |
odt-to-pdf |
ODT to PDF | one file | Free | unlimited | conversion service |
organize-pdf |
Organize PDF | one file | Free | unlimited | in-browser engine |
page-numbers |
Add Page Numbers | one file | Free | unlimited | in-browser engine |
pdf-to-excel |
PDF to Excel | one file | Pro | unlimited | conversion service |
pdf-to-jpg |
PDF to JPG | one file | Free | unlimited | conversion service |
pdf-to-pdfa |
PDF to PDF/A | one file | Free | unlimited | conversion service |
pdf-to-powerpoint |
PDF to PowerPoint | one file | Pro | unlimited | conversion service |
pdf-to-word |
PDF to Word | one file | Pro | unlimited | conversion service |
powerpoint-to-pdf |
PowerPoint to PDF | one file | Free | unlimited | conversion service |
protect-pdf |
Protect PDF | one file | Free | unlimited | conversion service |
redact-pdf |
Redact PDF | one file | Pro | unlimited | conversion service |
remove-pages |
Remove Pages | one file | Free | unlimited | in-browser engine |
repair-pdf |
Repair PDF | one file | Free | unlimited | conversion service |
request-signature |
Request Signature | one file | Pro | one free envelope every month with a Mostly Tiny account/day | workflow |
rotate-pdf |
Rotate PDF | one file | Free | unlimited | in-browser engine |
rtf-to-pdf |
RTF to PDF | one file | Free | unlimited | conversion service |
sign-pdf |
Sign PDF | one file | Pro | unlimited | in-browser engine |
sign-pdf-certified |
Certify PDF (digital signature) | one file | Pro | unlimited | in-browser engine |
split-pdf |
Split PDF | one file | Free | unlimited | in-browser engine |
summarize-pdf |
Summarize PDF | one file | Pro | unlimited | ai |
txt-to-pdf |
TXT to PDF | one file | Free | unlimited | conversion service |
unlock-pdf |
Unlock PDF | one file | Free | unlimited | conversion service |
url-to-pdf |
Webpage to PDF | render | Free | unlimited | render |
watermark-pdf |
Watermark PDF | one file | Free | unlimited | in-browser engine |
word-to-pdf |
Word to PDF | one file | Free | unlimited | conversion service |
Errors return a JSON body with a machine-readable error field and an HTTP status:
| Status | Meaning |
|---|---|
200 | Processed |
400 | Invalid argument |
401 | Missing/invalid API key |
403 | Key lacks scope |
501 | Tool needs the conversion service (not enabled) |
The interactive explorer below is generated from the same OpenAPI document that powers this page — you can also point your own client or an MCP server straight at it.
A Mostly Tiny product · all PDF tools