Generate basic PDF
generate_basic_pdfGenerate multi-page A4 PDFs from structured blocks including headings, paragraphs, lists, spacers, and page breaks. Optionally produces PDF/A compliant output for archival.
Instructions
Generate a multi-page A4 PDF from structured blocks (headings, paragraphs, lists, page breaks, spacers). DEFAULT TOOL for plain documents โ prefer this over specialized tools unless you need barcodes, tables, attachments, or non-Latin scripts. Optional pdfA flag enables Tagged PDF / PDF/A-1b/2b/2u/3b output (auto-embeds Noto Sans for non-WinAnsi Latin per ISO 19005 ยง6.3.4). Returns the PDF as base64 by default, or writes it to a sandboxed file path when outputMode=file.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | Yes | Document title (rendered at top of page 1 and used as PDF metadata title). | |
| blocks | Yes | Ordered list of content blocks composing the document body. | |
| footerText | No | Optional footer text rendered at the bottom of every page. | |
| pdfA | No | Optional PDF/A conformance level (powered by pdfnative v1.2). Use 'pdfa1b' for archival of simple text+images, 'pdfa2b'/'pdfa2u' for richer content (2u guarantees Unicode mapping), 'pdfa3b' when embedding source attachments (Factur-X / ZUGFeRD). Mutually exclusive with PDF encryption. See docs/guides/PDFA.md. | |
| outputMode | No | Either 'base64' (returns the PDF inline as a base64 string) or 'file' (writes to a path inside the configured PDFNATIVE_MCP_OUTPUT_DIR sandbox). | base64 |
| outputPath | No | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | Yes | ||
| sizeBytes | Yes | ||
| filePath | No | Absolute sandboxed file path (when mode='file'). | |
| base64 | No | Base64-encoded PDF bytes (when mode='base64'). |