Parse API (v2)

Parse a document image into structured output. Use output_format to select blocks or markdown (default).

Currently supports document.type = image_url only (data URI or remote http(s) image URL). PDF / file URL inputs are not yet supported.

Image limits: 20 MB file size; 50 megapixels or 200 MB decoded (whichever is exceeded first).

post/v2/parse

Headers

X-Client-Namestring

The name of the project that is making the request.

Request body

modelstring required

The name of a compatible Cohere parse model.

output_format'blocks' | 'markdown'

Selects the page payload shape in the response. Defaults to "markdown".

  • "markdown": each page includes markdown content. Tables are inlined as HTML, and images are referenced as ![<description>](<image_id>) with matching entries in page.markdown.images.
  • "blocks": each page includes an ordered blocks array of text, image, and table content regions, including bounding boxes where available.

Response

OK

idstring required

Unique identifier for the parse response.

Changes