Skip to main content
POST
Parse a file
From 1 credit See the guide for examples and usage.

Authorizations

Authorization
string
header
required

Send your API key as Authorization: Bearer <API_KEY>. Keys have full access unless restricted to specific permissions.

Query Parameters

extension
enum<string>

File type hint, such as pdf, docx, xlsx, pptx, html, json, csv, md, py, rtf, jpg, png, txt, warc, or warc.gz. Use it when the Content-Type header is missing or generic.

Available options:
warc,
warc.gz,
txt,
text,
md,
markdown,
html,
htm,
xhtml,
xml,
rss,
atom,
csv,
tsv,
yaml,
yml,
py,
java,
js,
jsx,
mjs,
cjs,
json,
jsonl,
ndjson,
php,
sh,
bash,
zsh,
fish,
rb,
ts,
tsx,
rtf,
srt,
css,
scss,
less,
styl,
sass,
svg,
pdf,
docx,
doc,
xlsx,
xlsm,
xlsb,
xltx,
xltm,
xls,
pptx,
pptm,
ppsx,
ppsm,
potx,
potm,
ppt,
pps,
pot,
jpg,
jpeg,
jpe,
png,
gif,
bmp,
tiff,
tif,
webp,
ppm,
pbm,
pgm,
pnm

Keep link URLs in the Markdown.

includeImages
boolean
default:false

Include image references in the Markdown.

shortenBase64Images
boolean
default:true

Shorten inline base64 image data.

useMainContentOnly
boolean
default:false

Keep only the main content, without navigation, headers, footers, or sidebars. Applies to HTML-like inputs.

ocr
boolean
default:false

Read text from images and scanned PDF pages with OCR, within the pdf page range. Adds 1 credit per page read.

includeNumberedPages
boolean
default:false

Start each PDF page in the Markdown with a <!-- page N --> line, where N is the original 1-based page number.

pdf
object

PDF page range as a JSON object, such as {"start": 2, "end": 5}.

client
string

Client identifier for usage attribution.

Required string length: 1 - 100
zdr
enum<string>
default:disabled

enabled turns on zero data retention. Returns 403 ZDR_NOT_ENABLED unless your organization has ZDR.

Available options:
enabled,
disabled
tags
string[]

Comma-separated labels for this request, such as production,team-alpha. Filter usage and request logs by them. Labels for this request. Filter usage and request logs by them in the dashboard or with GET /org/logs.

Maximum array length: 20
Required string length: 1 - 50
Example:

Body

Raw file bytes, up to 50 MiB.

The body is of type file.

Response

File converted to Markdown.

success
enum<boolean>
required

Always true for a successful parse.

Available options:
true
markdown
string
required

The file content as GitHub Flavored Markdown.

type
enum<string>
required

File type the input was parsed as.

Available options:
warc,
html,
xml,
json,
jsonl,
text,
csv,
tsv,
markdown,
yaml,
python,
java,
javascript,
php,
shell,
ruby,
typescript,
rtf,
srt,
css,
scss,
less,
stylus,
sass,
svg,
pdf,
docx,
doc,
xlsx,
xls,
pptx,
ppt,
jpg,
png,
gif,
bmp,
tiff,
webp,
ppm,
pbm,
pgm,
pnm
request_id
string<uuid>
required

Unique ID of this request, also in X-Request-Id. Include it when contacting support.

Example:

"3f1c2a6e-8b4d-4c1e-9f0a-2d7b5e6c8a91"

key_metadata
object

Credits this request used and your remaining balance.