Parse File Bytes to Markdown
Converts raw text, source code, web/data, PDF, Microsoft Office, and image bytes into LLM-usable Markdown.
Authorizations
Bearer authentication header of the form Bearer <API_KEY>, where <API_KEY> is your api key.
Query Parameters
Optional file extension hint, such as pdf, docx, xlsx, pptx, html, json, csv, md, py, rtf, jpg, png, or txt.
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 Preserve hyperlinks in Markdown output
Include image references in Markdown output
Shorten base64-encoded image data in the Markdown output
Extract only the main content from HTML-like inputs
When true for PDF inputs, detect and OCR images embedded in the selected pages, inserting recognized text at each image's position in page reading order while preserving the PDF text layer. pdf.start/pdf.end limit the inclusive page range. When false, all OCR is disabled, including the automatic scanned-PDF fallback.
PDF page-range options as a JSON object, e.g. {"start": 2, "end": 5}.
Optional client identifier used for usage attribution.
1 - 100Set to enabled to bypass shared caches and omit request and response content from retained usage logs. Requires zero data retention to be enabled for your organization (contact [email protected]), otherwise the request fails with ZDR_NOT_ENABLED. Successful ZDR responses include X-Context-ZDR: true.
enabled, disabled Optional comma-separated caller-defined tags for tracking this request. Tags are recorded on the request's usage log and can be used to filter usage on the dashboard usage page. Up to 20 tags, each 1-50 characters. Optional tags for tracking usage. Up to 20 tags, each 1 to 50 characters.
201 - 50Body
Raw file bytes. The request body must not exceed 25 MiB.
The body is of type file.
Response
Successful response
Indicates success
true Input bytes converted to GitHub Flavored Markdown
Detected content type used for parsing
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 Metadata about the API key used for the request. Included in every response whenever a valid API key is provided, even when the response status is not 200.