§ Chain
PDF Pipeline API
Applies an ordered list of steps to one document in a single round trip. Each step’s options are exactly the standalone endpoint’s options, because the pipeline calls the same code. Eight steps cost the same one call as one step.
- Endpoint
- POST /pdf/pipeline
- Inputs
- Exactly 1 PDF
- Aux part
- stamp — one image, for a `stamp` step
- Returns
- application/pdf
- Limits
- 8 steps, 20 MB per file, 3,000 pages.
- Price
- $0.001
§ 01 The request
One POST, and the file comes back.
POST /pdf/pipeline
curl -sS --fail-with-body \
-o processed.pdf \
-H "Authorization: Bearer $OHMYWRAP_KEY" \
-F "file=@raw.pdf" \
-F 'options={"steps":[{"op":"rotate","options":{"rotation":180}},{"op":"extract","options":{"pages":["1-2"]}},{"op":"optimize"}]}' \
https://api.ohmywrap.com/pdf/pipelineOptions
| Option | Type | Default | What it does |
|---|---|---|---|
| stepsrequired | object[] | — | 1 to 8 steps, applied in order. |
| steps[].oprequired | string | — | `rotate`, `stamp`, `extract`, `remove-pages`, `set-metadata`, or `optimize`. |
| steps[].options | object | {} | That operation’s own options. |
Worth knowing
The value here is one upload and one round trip: each step still re-parses, so it saves bandwidth and latency, not CPU. Only the six single-document transforms are chainable — anything else is 422 invalid_pipeline, and the error names what is allowed.
Your first /pdf/pipeline call takes one line of curl.
Ten thousand calls cost ten dollars, the pack never expires, and nothing you send is kept.
10,000 calls for $10. No subscription, no expiry.