API reference
Files
Upload files, preview conversion cost, and expand archives.
Create an upload URL
POST
https://api.markitdown.ai/files/upload-urlPresigned URL for a direct uploadBody
namerequired | string | Original filename. |
mimerequired | string | Content type, e.g. application/pdf. |
bytesrequired | integer | File size in bytes. |
Returns { fileId, putUrl, r2Key }. PUT the raw file bytes to putUrl, then use fileId with inspect/convert.
Inspect cost
POST
https://api.markitdown.ai/files/inspectPreview pages, route, and credit costTakes the same body as convert (fileId, estimatedCredits, optional signals) and returns { route, pages, reservedCredits }. Use reservedCredits as estimatedCredits for the convert call.
Expand a ZIP archive
POST
https://api.markitdown.ai/files/expand-zipList convertible files inside an uploaded .zipBody
fileIdrequired | uuid | An uploaded .zip file. |
Returns { files, skipped } (up to 100 files). Feed the expanded file ids into a pipeline run for batch conversion.