Interface: PdfDocumentJson
A complete, JSON-serializable description of a PDF document. Pass it to renderDocumentJson to produce PDF bytes.
Properties
| Property | Modifier | Type | Description |
|---|---|---|---|
autoOutline? | readonly | boolean | TemplateAutoOutlineOptions | Auto-generate a bookmarks tree from headings. |
blocks | readonly | readonly JsonBlock[] | Body blocks. Required and non-empty. A block flows by default, or is placed at absolute coordinates when it carries an x/x1/cx anchor (see JsonPositionedBlock). |
compress? | readonly | boolean | Compress content streams. Defaults to the engine default. |
conformance? | readonly | DocumentConformanceProfile | Validate and emit a PDF/A or PDF/UA conformance profile. |
defaultFont? | readonly | string | Name of a declared font (or built-in font) used as the document default. |
defaultPageSize? | readonly | PageSize | Default page size for pages that do not specify one. |
defaults? | readonly | TextDefaults | Document-wide text defaults. |
encryption? | readonly | DocumentEncryptionOptions | Password-encrypt the output. |
fonts? | readonly | readonly JsonFontDeclaration[] | Fonts to load and register before rendering. |
footer? | readonly | readonly JsonBlock[] | Blocks rendered at the bottom of every page (page tokens interpolated). |
header? | readonly | readonly JsonBlock[] | Blocks rendered at the top of every page (page tokens interpolated). |
info? | readonly | DocumentInfo | Information dictionary values. |
language? | readonly | string | BCP 47 language tag for the document. |
page? | readonly | TemplatePageOptions | Page geometry and margins. |
pageNumber? | readonly | TemplatePageNumberOptions | Automatic page numbering. |
strictLayout? | readonly | boolean | TemplateStrictLayoutOptions | Strict layout checks for fixed templates. |
styles? | readonly | TemplateStylesheet | Reusable named styles. |
tagged? | readonly | boolean | Emit a tagged (accessible) structure tree. |
title? | readonly | string | Document title (information dictionary, XMP, and display-title preference). |
xmpMetadata? | readonly | XmpMetadataInput | XMP metadata packet or structured input. |