Edit PDF API
Apply cover, type, watermark, rotate, and permanent remove operations server-side.
Web UI: Edit PDF
Authentication
Bearer API key required on every request.
Request
POST https://api.omnicap.app/v1/edit-pdf
Content-Type: multipart/form-data
file(file, required)PDF to edit.
ops(string, required)JSON array of up to 200 edit operations. Coordinates are PDF user space: origin at the bottom-left, y upward. Page indexes start at 0. A rect is [x0, y0, x1, y1]. Text and note x,y are the baseline. Apply order is rotate, then remove (redact), cover (whiteout), text, image, highlight, note, and watermark. Text uses font helv, times, or cour, size 6–96, color #RRGGBB, and at most 400 characters. Cover paints white and leaves the original characters in the file. Remove deletes the text in the rect, fails if any remains, and also scrubs metadata and hidden text for the whole file. The last watermark wins, opacity 0.05–0.6, at most 80 characters, on every page. An image op names an extra multipart part imageId (img-…): PNG or JPG, at most 8 images, 20 MB each. Highlight and note are annotations.
password(string)Password if the PDF is locked.
Response
Mode: sync — binary file body
Headers: X-Page-Count
Editing in the browser
The preview stays in the browser. The file uploads when the edited PDF is downloaded, and that download uses one page credit. A password is sent only with that upload.
Embed on your site
Free for blogs and docs. Keep the "Powered by Omnicap" link visible in the widget.
<div id="omnicap-edit-pdf"></div> <script src="https://omnicap.app/embed.js" data-tool="edit-pdf" data-target="omnicap-edit-pdf" data-height="520" async></script>
Sample ops
Cover paints white and leaves the characters in the file. Remove deletes them and fails the request if any remain in the box. Any remove also scrubs metadata and hidden text for the whole file. Send image bytes as extra multipart parts whose field name is the op imageId.
[
{
"type": "whiteout",
"page": 0,
"rect": [72, 700, 180, 718]
},
{
"type": "text",
"page": 0,
"x": 72,
"y": 704,
"text": "Acme",
"fontSize": 12,
"font": "helv",
"color": "#111111"
},
{ "type": "redact", "page": 0, "rect": [72, 640, 180, 658] },
{ "type": "watermark", "text": "DRAFT", "opacity": 0.18 }
]Examples
curl
curl -X POST "https://api.omnicap.app/v1/edit-pdf" \ -H "Authorization: Bearer $OMNICAP_API_KEY" \ -F "file=@/path/to/document.pdf" \ -F "ops=YOUR_OPS"
Node.js (fetch)
const form = new FormData();
form.append("file", fileBlob, "document.pdf");
form.append("ops", "YOUR_OPS");
const res = await fetch("https://api.omnicap.app/v1/edit-pdf", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.OMNICAP_API_KEY}` },
body: form,
});
const out = await res.arrayBuffer();Billing
1 billable unit(s) per successful call.
Changelog
- 2026-11-13: Documented edit coordinates, limits, apply order, and cover versus remove.
- 2026-10-24: Initial public release.