Render
Renders one page of a document, or one frame of an image, at a readable size for vision models and document viewers. Size it with dpi or with width and height, never both; by default the response body is the image file.
Use thumbnail for fixed size previews, and screenshot for web pages as a browser shows them.
HTTPBearerAuthorizationBearer <token>Static API key from PAPYRUS_API_KEY
- body
source*Sourcefile://, http(s):// URL or :///
destination?|Connector URI to write the result to
nulloutput?OutputModejson returns the envelope with the artifact inline, file returns the artifact as the response body; with a destination the response is always the light JSON envelope
"file""file""json"options?Operation options, omitted fields take their defaults
The JSON envelope (light with a destination), or the op file for output=file
- response
source*The input document
result*The primary artifact
options*The request options with defaults applied
{
"source": {
"uri": "s3://demo-s3/papyrus-test/sample.pdf",
"name": "sample.pdf",
"size": 18810,
"mimeType": "application/pdf",
"extension": "pdf",
"label": "pdf",
"group": "document",
"pageCount": 1
},
"result": {
"uri": "s3://demo-s3/papyrus-test/sample-1.png",
"name": "sample-1.png",
"size": 397384,
"mimeType": "image/png",
"extension": "png",
"label": "png",
"group": "image",
"width": 1275,
"height": 1650
},
"options": {
"page": 1,
"dpi": 150,
"format": "png"
}
}Markdown POST
Extracts Markdown from a document or web page, ready to pass to an LLM or index for retrieval. The format is detected from the content, and `options.chunking` adds structure-aware chunks sized for your embedding model, with the headings they sit under and their offsets in the Markdown. The default `options.readMode` is `auto`: images, presentations, and PDF or Word documents whose text cannot be extracted, such as scans, are read page by page by the vision model configured on the server; everything else is extracted from the text stored in the file. Set `ocr` to read every page with the model, or `text` to never use it. `options.readMode` in the response is the mode used. Without a model on the server, `auto` extracts text only, so scans return little or nothing and images fail with `415 unsupported_format`, as do corrupt and encrypted files. Legacy formats such as `.doc` and `.ppt` are converted with LibreOffice first and take longer.
Thumbnail POST
Fits one page, image or web page into a fixed box, a 256 × 256 px WebP by default, for file lists, search results and link previews. A URL that serves HTML, such as `https://axelered.com`, is captured in a browser at desktop width. Use render when you need a page at reading size.