Render a structured document to a native PDF file.
Use describe("pdf.render") when your code needs the complete live JSON Schemas.
At a glance
| Property | Value |
|---|---|
| Package | @runstamp/pdf |
| Domain / verb | pdf / render |
| Customer jobs | create |
| Deterministic | Yes |
| Side effects | network |
Availability
| Local | SDK | CLI | MCP | Managed API |
|---|---|---|---|---|
| public ga | public ga | public ga | public ga | public ga |
Managed API route: POST /api/v2/operations/pdf/render. Managed execution requires a free-trial workspace or an active Platform or Enterprise workspace, and an environment-bound API key.
Input and result
| Schema | Required fields | Optional fields |
|---|---|---|
| Input | none | none |
| Options | none | deterministic, deterministicSeed, timeoutMs, locale, lossPolicy, limits, render |
| Result value | bytes, mediaType, extension, byteLength, hash | none |
Every success also carries losses, diagnostics, and a hash-bound receipt.
Defaults, limits, and format constraints
Defaults
| Path | Default |
|---|---|
$.deterministic | default=true |
$.lossPolicy | default="collect" |
$.render.strict | default=true |
$.render.assetPolicy.allowRemoteSources | default=false |
Formats and profiles
| Path | Constraint |
|---|---|
$.anyOf[0].pages[].graphics[].anyOf[0].format | oneOf="jpeg","png" |
$.anyOf[1].children[].anyOf[1].format | oneOf="jpeg","png","svg" |
$.anyOf[1].children[].anyOf[2].graphic.anyOf[0].format | oneOf="jpeg","png" |
$.anyOf[1].content[].anyOf[1].format | oneOf="jpeg","png","svg" |
$.anyOf[1].content[].anyOf[2].graphic.anyOf[0].format | oneOf="jpeg","png" |
$.render.pdfVersion | oneOf="1.4","1.5","1.6","1.7","2.0" |
Other limits
| Path | Constraint |
|---|---|
$.anyOf[0].meta.creationDate.anyOf[0] | pattern (see exact schema) |
$.anyOf[0].meta.modDate.anyOf[0] | pattern (see exact schema) |
$.anyOf[0].pages | minItems=1 |
$.anyOf[0].pages[].graphics[].anyOf[0].width | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[0].height | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[0].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[1].stroke.dash[] | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[1].stroke.opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[1].stroke.width | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[2].d | minLength=1 |
$.anyOf[0].pages[].graphics[].anyOf[2].fill.anyOf[0].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[2].fill.anyOf[1].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[2].fill.anyOf[2].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[2].stroke.dash[] | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[2].stroke.opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[2].stroke.width | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[3].width | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[3].height | exclusiveMinimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[3].radius | minimum=0 |
$.anyOf[0].pages[].graphics[].anyOf[3].fill.anyOf[0].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[3].fill.anyOf[1].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[3].fill.anyOf[2].opacity | minimum=0maximum=1 |
$.anyOf[0].pages[].graphics[].anyOf[3].stroke.dash[] | exclusiveMinimum=0 |
Showing 32 of 203 constraints. Use describe() or the machine-readable reference for the complete schema.
Invoke
const input = await fetch("https://runstamp.com/demo-evidence/operation-evidence/pdf/pdf.render/input.json").then((response) => response.json());
const result = await runstamp.run("pdf.render", input);
if (!result.ok) throw new Error(`${result.error.code}: ${result.error.remediation}`);
console.log(result.value, result.losses, result.diagnostics, result.receipt);curl -fsS https://runstamp.com/demo-evidence/operation-evidence/pdf/pdf.render/input.json -o input.json
npx -p @runstamp/sdk runstamp ops invoke pdf.render --input input.json{
"tool": "runstamp_invoke_operation",
"arguments": {
"operation": "pdf.render",
"input": "<JSON from https://runstamp.com/demo-evidence/operation-evidence/pdf/pdf.render/input.json>",
"execution_mode": "local"
}
}Errors and losses
Declared errors (6)
common/SCHEMA_REJECTEDcommon/CONTRACT_VIOLATIONcommon/OPERATION_CANCELLEDcommon/OPERATION_TIMEOUTcommon/RESOURCE_LIMIT_EXCEEDEDpdf/LOSS_POLICY_VIOLATED
Declared losses (7)
pdf/TEXT_CHARACTER_UNMAPPABLEpdf/TEXT_GLYPH_MISSINGpdf/PAGE_SIZE_CLAMPEDpdf/ELEMENT_OVERFLOWS_PAGEpdf/TOKEN_WRAPPEDpdf/SCHEMA_FALLBACK_UNVERIFIEDpdf/UNCLASSIFIED_CONDITION
SDK AbortSignal, CLI exit 130, and MCP cancellation return the typed common/OPERATION_CANCELLED failure envelope.
Verified example and exact contract
- Fixture:
icp-workflow(pdf-summary-audit-findings-itgc.json). - Example input — SHA-256
403ad6ea2dbae4775ed0cb3a90e1c79530f52bf9202139eb6a77d1ba4656b9d9. - Example result — SHA-256
506410d3f5d3b2dea5066749838a787553e9bc8fbc7aadac39464b1b310145c5. - Verified result SHA-256:
f2ab899bb57883b7f79f1a1b29a2efed9bf3b766d6633cf0f837d02801a11c25. - Qualification lane:
11-pdf-xlsx.
Contract fingerprints
- Descriptor:
29bde8fb1b7e1f2dd4c5ab2e66225958e907819bd17fda34b71c1cfaacbbd464. - Input schema:
dea5c7f16d79ac5c7b277315d3a4f2ff53f2824d00f6e79ea11fb6dbcc173093. - Options schema:
3fd2aa16128f67f494083fef33474ef1072586bc76f439ca32cd15c01c371615. - Result value schema:
e7e0bc52bf866264c04c0cc2a2d2d788751a82a731f6a8bc31b2efb72d06d08c.
The machine-readable operation reference publishes the complete schemas, qualification results, and evidence bindings for every operation.