Render a version: kept as an output (201), or answered directly with Accept
POST
/v1/templates/{template}/versions/{version}/render
const url = 'https://example.com/v1/templates/example/versions/example/render';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"values":{"additionalProperty":"example"},"format":"example","dpi":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/templates/example/versions/example/render \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "values": { "additionalProperty": "example" }, "format": "example", "dpi": 1 }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”template
required
string
version
required
string
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
values
Values, by field name.
object
key
additional properties
string
format
string
dpi
integer
Example generated
{ "values": { "additionalProperty": "example" }, "format": "example", "dpi": 1}Responses
Section titled “Responses”With Accept naming the format: the PDF, or the one page asked for as an image; the report in X-… headers; nothing kept.
string format: binary
string format: binary
string format: binary
Made; the answer describes it.
Media typeapplication/json
object
id
required
string
template
required
string
version
required
integer
profile
required
string
format
required
string
engine
required
object
version
required
string
build
required
string
packageSha256
required
string
publishedWith
required
object
build
required
string
version
required
string
fonts
required
The fonts used, by role (regular, bold, italic, bolditalic): each one’s SHA-256.
object
key
additional properties
string
profiles
required
object
fileCreatedAt
required
string
valuesSha256
required
string
warnings
required
Array
resources
required
object
filename
required
string
printStatus
string
preflight
size
required
integer
sha256
required
string
createdAt
required
string
expiresAt
required
string
download
required
string
proof
boolean
pages
Array<object>
object
page
required
integer
width
required
integer
height
required
integer
file
required
string
size
required
integer
sha256
required
string
download
required
string
Example generated
{ "id": "example", "template": "example", "version": 1, "profile": "example", "format": "example", "engine": { "version": "example", "build": "example" }, "packageSha256": "example", "publishedWith": { "build": "example", "version": "example" }, "fonts": { "additionalProperty": "example" }, "profiles": {}, "fileCreatedAt": "example", "valuesSha256": "example", "warnings": [ "example" ], "resources": {}, "filename": "example", "printStatus": "example", "preflight": "example", "size": 1, "sha256": "example", "createdAt": "example", "expiresAt": "example", "download": "example", "proof": true, "pages": [ { "page": 1, "width": 1, "height": 1, "file": "example", "size": 1, "sha256": "example", "download": "example" } ]}Headers
Section titled “Headers”Location
string
Where to follow it.
The request is malformed (bad-request).
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}No key, or not a valid one.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}The key lacks the scope, or its tenant is suspended or deleted.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}Not there, or not the tenant’s.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}In conflict with what is there.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}Understood, but refused: values, layout or package problems.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}Past the tier’s ratePerMinute (rate-limited).
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}Headers
Section titled “Headers”Retry-After
integer
Seconds until the next minute.
The render workers are full (busy).
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}Headers
Section titled “Headers”Retry-After
integer
Seconds to wait.
A direct render took longer than the server waits (render-too-slow): submit it as a job.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}