§ Convert
Office Document Conversion API
Legacy formats onto modern ones, modern ones into ODF, and documents into something you can read as text. The endpoint is a fixed list of seventeen pairs rather than the cross product of everything LibreOffice can open: six inputs, nine targets, and anything else refused with a message naming what this input can become.
- Endpoint
- POST /office/convert
- Inputs
- Exactly 1 doc, rtf, xls, ppt, docx, or xlsx file
- Returns
- The converted file, with the target’s media type
- Limits
- 50 MB per file, 60 MB per request, 60s timeout, 2 conversions at a time.
- Price
- $0.001
§ 01 The request
One POST, and the file comes back.
curl -sS --fail-with-body \
-o quarterly.csv \
-H "Authorization: Bearer $OHMYWRAP_KEY" \
-F "file=@quarterly.xlsx" \
-F 'options={"to":"csv"}' \
https://api.ohmywrap.com/office/convertOptions
| Option | Type | Default | What it does |
|---|---|---|---|
| torequired | string | — | The target format. No default, because guessing would convert documents nobody asked to convert. |
Worth knowing
It does not render to PDF — `to: "pdf"` is refused, because page ranges, PDF/A, and image downsampling are a different endpoint’s options and would mean nothing for five targets out of nine. CSV export writes the first sheet only; that is LibreOffice’s behaviour, so convert to ods when you need all of them. Your extension is your declaration and the container is what gets checked: a mismatch is 422 container_mismatch and never reaches a parser.
Your first /office/convert 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.