io.github.Nizoka/pdfnative-mcp
NPM · PDFNATIVE-MCP · SCANNED AUG 3
PDF native MCP server: generate, validate, sign PAdES, embed, extract. AI-powered.
Available components
How this component scores in each security and reliability category. Every signal is checked automatically from public evidence about the published package, including repeated runs of it in an isolated sandbox, and we only credit what we can confirm. How we score →
Supply Chain Security87
- No malware found by supply-chain analysis.Pass
- Only part of the dependency tree could be resolved (95 of 99), so this covers what we could see, not the whole tree.Partial
- No install/post-install scripts declared.Pass
- Only part of the dependency tree could be resolved (95 of 99), so this covers what we could see, not the whole tree. View diagnostics → Partial
Provenance & Transparency97
- Source repository is publicly reachable at the declared URL. View diagnostics → Pass
- Cryptographically verified build provenance (signed, bound to Nizoka/pdfnative-mcp). View diagnostics → Pass
- Clear OSI-approved license (MIT).Pass
- Actively maintained (last published 12 days ago).Pass
- Disclosure check failed: no security disclosure policy was found in the source repository. See how to fix → Fail
Schema Quality & AI Usability74
- 100% of prompts and resources have a non-trivial description (not blank, and not just the item's name).Pass
- AI-judged instruction clarity (excellent).Pass
- Context-footprint check failed: tool/resource definitions use about 12111 tokens (~504/item across 24 items; 24 tools + 0 resources), over budget; trim descriptions and params. See how to fix → Fail
- Usage-examples check failed: none of the tools include examples. See how to fix → Fail
Stability & Change Management27
- Stability observed for 8 of 30 days with no destabilising changes; credit accrues until the full window elapses.Partial
Tool Coverage97
- 100% of tools have a non-trivial description (not blank, and not just the tool's name).Pass
- 89% of tool parameters carry a description.Partial
- Structured output schemas are declared (100% of tools); any adoption earns full credit.Pass
Capabilities100
- Implements a supported MCP spec version (2025-11-25); the latest is 2026-07-28.Pass
Add this component to your MCP client. Where a client-specific snippet is available, pick your client below and copy it straight into your config; otherwise use the connection detail shown.
npm · pdfnative-mcp
claude mcp add nizoka-pdfnative-mcp -- npx -y pdfnative-mcp
codex mcp add nizoka-pdfnative-mcp -- npx -y pdfnative-mcp
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"nizoka-pdfnative-mcp": {
"type": "local",
"command": [
"npx",
"-y",
"pdfnative-mcp"
],
"enabled": true
}
}
} openclaw mcp add nizoka-pdfnative-mcp --command npx --arg -y --arg pdfnative-mcp
mcp_servers:
nizoka-pdfnative-mcp:
command: "npx"
args: ["-y", "pdfnative-mcp"] {
"mcpServers": {
"nizoka-pdfnative-mcp": {
"command": "npx",
"args": [
"-y",
"pdfnative-mcp"
]
}
}
} Every change we have recorded for this component, newest first. Security-relevant changes are always shown. ▲ marks a change for the better, ▼ a change for the worse; unmarked changes are neutral.
- 3 Aug 26 +36
- Install scripts: unverified → pass ▲ security
- Known CVEs: unverified → partial ▲ security
- Provenance: unverified → pass ▲ security
- The attested source repository moved: Nizoka/pdfnative-mcp security
- Maintenance: unverified → pass ▲ functional
- Dependency health: unverified → partial ▲ functional
- License: unverified → pass ▲ functional
- Stability: unverified → 0.27 ▲ functional
- Schema quality: unverified → excellent ▲ functional
- Licence: MIT functional
- 2 Aug 26 +20
- Malware scan: unverified → pass ▲ security
- Stability: Stability not yet verified: not enough scan history yet (needs a 30-day window). security
- MCP protocol: unverified → pass ▲ functional
- 1 Aug 26 −8
- We updated how we score, so this day's move reflects our rubric, not a change to the server See what changed → functional
- 31 Jul 26 −18
- Malware scan: pass → unverified ▼ security
- 28 Jul 26 −22
- Install scripts: pass → unverified ▼ security
- Provenance: pass → unverified ▼ security
- The attested source repository moved: Nizoka/pdfnative-mcp security
- Maintenance: pass → unverified ▼ functional
- License: pass → unverified ▼ functional
- Licence: MIT functional
- 27 Jul 26 71
First indexed and scored.
Diagnostic detail from the automated scan of this channel: what the scanner observed at each step, so you can see exactly where a check passed or failed. It is informational only and never changes the trust score.
Captured 3 Aug 2026 · Analysed npm/[email protected]
Provenance verified
Ecosystem: npm · Outcome: verified
Reason: verified
- Source repo:
- Nizoka/pdfnative-mcp
- Certificate issuer:
- https://token.actions.githubusercontent.com
- Certificate SAN:
- https://github.com/Nizoka/pdfnative-mcp/.github/workflows/publish.yml@refs/tags/v1.5.0
- Rekor log index:
- 2214800772
- Predicate type:
- https://slsa.dev/provenance/v1
- Subject digest:
- sha512:e0116a673241c8d4b52eb19c224b729ef7c586888403cb219fb241b56c53fb9548e20a3b6dd900220ac3574a91810f993d410e2fe7cbd272510c4a8de
- Discovery method:
- attestation_endpoint
Dependencies 95 packages
95 packages in the resolved dependency tree · 94 deprecated · 29 stale.
The dependency tree was only partially resolved, so these counts may be incomplete.
The tools this component advertises to a client, with an estimated token cost for each. Expand a tool to see its parameters and schema. The per-tool counts are indicative and are not scored directly; the schema's total context footprint is one signal in Schema Quality & AI Usability.
add_attachment Add embedded file attachment (PDF/A-3, Factur-X) ~265
Generate a PDF/A-3 (ISO 19005-3) document with one or more embedded files. USE THIS INSTEAD OF generate_basic_pdf when you need a Factur-X / ZUGFeRD electronic invoice (single XML payload with relationship='Source'), or any PDF that must carry machine-readable side-files. The visible document body is supplied via the optional `blocks` parameter (same block schema as generate_basic_pdf). The tool auto-emits PDF/A-3b conformance — PDF/A-3 is the only PDF/A part that legally permits embedded files. Each attachment is capped at 8 MiB.
| Name | Type | Req | Description |
|---|---|---|---|
| attachments | array | yes | One or more files to embed. Auto-enables PDF/A-3 (ISO 19005-3). Factur-X invoices use a single attachment with relationship=Source and mimeType=application/xml. |
| blocks | array | — | Optional human-readable document body (same block schema as generate_basic_pdf). When omitted, a minimal cover paragraph is emitted so the PDF is not empty. |
| footerText | string | — | Optional footer text rendered on every page. |
| outputMode | string | — | — |
| outputPath | string | — | — |
| title | string | yes | Document title (also written to the /Info dictionary). |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
add_barcode Add barcode / QR code ~506
Generate a single-page PDF embedding a barcode or QR code. Supported formats: • qr — URLs, vCards, any UTF-8 text ≤ 4296 chars. Use ecLevel='H' for printed media (logos/dirt-tolerant); 'M' (default) for screens. • code128 — alphanumeric SKUs, ASCII payloads. • ean13 — retail product codes (must be 12 or 13 digits; 13th is auto-computed). • datamatrix— dense industrial / aerospace markings. • pdf417 — ID cards, boarding passes. Common recipe for a QR code pointing to a URL: { format: 'qr', data: 'https://example.com', caption: 'Scan me' }. The `data` field is the raw payload — do NOT pre-encode URLs.
| Name | Type | Req | Description |
|---|---|---|---|
| caption | string | — | Optional caption rendered above the barcode. |
| data | string | yes | Raw payload to encode — do NOT URL-encode. For QR/URL pass e.g. "https://example.com" verbatim. EAN-13 must be 12 or 13 digits (13th is auto-computed). Code 128 accepts ASCII alphanumerics. |
| ecLevel | string | — | QR ONLY. Error correction level (L=7%, M=15%, Q=25%, H=30%). Ignored for code128/ean13/datamatrix/pdf417. Use H for printed media that may get smudged or partially covered (e.g. logo overlay). |
| format | string | yes | Barcode symbology to render. |
| height | number | — | Barcode height in PDF points (ignored for square symbologies like QR/Data Matrix). |
| outputMode | string | — | — |
| outputPath | string | — | — |
| pdfA | string | — | 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 embe… |
| title | string | — | PDF document title (also rendered as page heading). |
| width | number | — | Barcode width in PDF points. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
add_chart Add native vector chart ~605
Generate a single-page PDF with a native vector chart (pdfnative v1.6.0): bar, barH (horizontal bar), line (optional markers), pie or donut — rendered as pure PDF path operators, zero rasterisation. Multi-series bar/line, legends, 'nice' 1/2/5×10ⁿ axis ticks, gridlines, negative values, and a tagged-PDF /Figure + /Alt (auto-generated when altText omitted, so PDF/A stays conformant). Pie/donut use exactly one series (each value = a slice). Colours are hex strings (e.g. '#3366cc'). For a chart embedded amongst headings/paragraphs/tables, use a 'chart' block inside generate_basic_pdf instead.
| Name | Type | Req | Description |
|---|---|---|---|
| align | string | — | Horizontal alignment within the content width. Default 'left'. |
| altText | string | — | Alt text for the tagged-PDF /Figure /Alt. Auto-generated when omitted. |
| axis | object | — | Value-axis options (bar/line only). |
| categories | array | — | Category / slice labels (x-axis). Defaults to 1-based indices when omitted. |
| chartType | string | yes | Chart kind. 'pie'/'donut' use exactly one series; 'bar'/'barH'/'line' support multiple series. |
| colors | array | — | Palette override (per-series for bar/line, per-slice for pie/donut). |
| height | number | — | Plot-area height in points. Default 240. |
| intro | string | — | Optional introductory paragraph rendered above the chart. The chart `title` (if any) is also used as the PDF metadata title. |
| legend | string | — | Legend placement. Defaults to 'bottom' for multi-series/pie, else 'none'. |
| markers | boolean | — | Draw point markers on line series. Default false. |
| outputMode | string | — | Either 'base64' (returns the PDF inline) or 'file' (writes into the PDFNATIVE_MCP_OUTPUT_DIR sandbox). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pdfA | string | — | 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 embe… |
| series | array | yes | Data series. Pie/donut charts use exactly one series (each value becomes a slice). |
| title | string | — | Chart title rendered above the plot. |
| width | number | — | Plot width in points (clamped to content width). Default 460. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
add_form Add interactive form ~256
Generate a PDF containing an interactive AcroForm with text fields, text areas, checkboxes, radio buttons, and dropdowns. Suitable for data-capture forms, surveys, and fillable templates.
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | yes | Ordered list of form field definitions. |
| footerText | string | — | Optional footer text rendered at the bottom of every page. |
| outputMode | string | — | Either 'base64' (returns the PDF inline) or 'file' (writes to a sandboxed path inside PDFNATIVE_MCP_OUTPUT_DIR). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pdfA | string | — | 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 embe… |
| title | string | yes | Form title rendered at the top of the document. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
add_international_text Add international text ~470
Generate a PDF rendering text in any of 24 scripts (Arabic, Hebrew, Thai, CJK, Devanagari, Bengali, Tamil, Telugu, Sinhala, Tibetan, Khmer, Myanmar, Ethiopic, Cyrillic, Greek, Georgian, Armenian, Vietnamese, Turkish, Polish, Latin fallback) with optional COLRv1 colour emoji and mathematical / technical symbols (the "math" font — Noto Sans Math, ∀ ∃ √ ∑ ∫ ∞ ± ÷ ×). BiDi reordering (incl. UAX#9 isolates), Arabic harakat positioning, and complex-script OpenType shaping are handled automatically by the embedded Noto fonts; input is NFC-normalised for maximal glyph coverage and embedded newlines auto-split into paragraphs. Pass `lang` as a single code or an array (e.g. ["ar","emoji"] or ["latin","math"]) for multi-script / symbol runs.
| Name | Type | Req | Description |
|---|---|---|---|
| lang | — | yes | Language / script identifier. Either a single code (e.g. 'ar'), a comma-separated list ('ar,emoji'), or an array (['ar','emoji']). Multiple codes enable multi-font run splitting (script + emoji + Lat… |
| normalize | string | — | Unicode normalization form applied before shaping. Defaults to 'NFC' (recommended for international scripts: composes decomposed sequences for the widest glyph coverage). Override with 'NFD'/'NFKC'/'… |
| outputMode | string | — | — |
| outputPath | string | — | — |
| paragraphs | array | yes | Ordered list of paragraphs to render in the chosen script. |
| pdfA | string | — | Optional PDF/A conformance level. When set, Tagged PDF + sRGB OutputIntent + XMP metadata are emitted; the 'latin' Noto Sans fallback is auto-registered for non-WinAnsi Latin (ISO 19005-1 §6.3.4). Se… |
| title | string | yes | PDF title (rendered as page heading and stored as document metadata). |
| viewerPreferences | object | — | Reader presentation hints (catalog /PageLayout, /PageMode, /ViewerPreferences). PDF/A-safe; all optional. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
add_table Add table / report ~849
Generate a tabular PDF report from column headers and data rows. Ideal for data exports, financial summaries, schedules. Smart-table fields (pdfnative v1.2) automatically engage the document backend: `wrap` (auto/always/never), `repeatHeader` (header row on every page), `zebra` (alternate-row tint), `caption` (above the table, tagged for PDF/A), `minRowHeight` (points), `cellPadding` (points). Every row must have the same length as `headers`. For PDF/A output, set pdfA="pdfa2b" (most compatible).
| Name | Type | Req | Description |
|---|---|---|---|
| autoFitColumns | boolean | — | When true, column widths auto-fit content (pdfnative v1.1). Switches the backend to buildDocumentPDFBytes; byte output differs from the default path. |
| caption | string | — | Caption rendered above the table (and emitted as /Caption structure element in tagged/PDF/A mode). pdfnative v1.2. |
| cellBorders | object | — | Per-cell vector borders (pdfnative v1.4). Switches the backend to buildDocumentPDFBytes. Choose individual sides or `all`. |
| cellPadding | number | — | Horizontal cell padding in points applied to both insets (default 3). pdfnative v1.2. |
| cellVAlign | string | — | Vertical alignment of cell content (pdfnative v1.4). Switches the backend to buildDocumentPDFBytes. |
| clipCells | boolean | — | When true, cell contents are clipped to column bounds via PDF clip-path operators (pdfnative v1.1). Recommended for PDF/A and visual safety. Switches the backend to buildDocumentPDFBytes. |
| footerText | string | — | Optional text rendered at the bottom of every page. |
| headers | array | yes | Column header labels. Must have the same length as each row in `rows`. |
| infoItems | array | — | Optional key-value metadata rows rendered below the title (e.g. date, author). |
| minRowHeight | number | — | Minimum row height in points (default 12). pdfnative v1.2. |
| outputMode | string | — | Either 'base64' (returns the PDF inline) or 'file' (writes to a sandboxed path inside PDFNATIVE_MCP_OUTPUT_DIR). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pdfA | string | — | 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 embe… |
| repeatHeader | boolean | — | Repeat the header row on every continuation page (pdfnative v1.2). Default true. |
| rows | array | yes | Data rows. Each row is an array of cell strings with the same length as `headers`. |
| title | string | yes | Report title rendered at the top of the document and used as PDF metadata title. |
| viewerPreferences | object | — | Reader presentation hints (catalog /PageLayout, /PageMode, /ViewerPreferences). PDF/A-safe; all optional. |
| watermark | object | — | Optional semi-transparent text watermark rendered on every page (e.g. 'DRAFT', 'CONFIDENTIAL'). Text only in this version. opacity < 1.0 is rejected under pdfA='pdfa1b' (ISO 19005-1 forbids transpare… |
| wrap | string | — | Cell wrap policy (pdfnative v1.2). 'auto' (default) wraps only when a cell overflows; 'always' wraps every cell; 'never' uses v1.1 character truncation. |
| zebra | boolean | — | Enable zebra striping (alternate-row light tint, PDF/A-1b safe). pdfnative v1.2. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
annotate_pdf Annotate PDF (markup / drawing) ~256
Add markup / drawing annotations (ISO 32000-1 §12.5) to an existing PDF via pdfnative v1.5's annotation writer. Non-destructive incremental update: original content is preserved byte-for-byte and each annotation is appended to the target page's /Annots. Types: text (sticky note), highlight | underline | strikeout | squiggly (text-markup), square | circle (shapes), line, freetext. Each annotation needs a 0-based `page` and a `rect` [x1,y1,x2,y2]; line also needs `start`/`end`. Optional per-annotation: contents, color, opacity, title, plus type-specific fields (open/icon, quadPoints, interiorColor/borderWidth, fontSize). Encrypted sources are rejected (ENCRYPTED_SOURCE). NOTE: annotations are visual overlays — they do NOT remove or redact the underlying content.
| Name | Type | Req | Description |
|---|---|---|---|
| annotations | array | yes | Markup / drawing annotations to add. Each is attached to a 0-based page index. |
| outputMode | string | — | — |
| outputPath | string | — | — |
| pdfBase64 | string | yes | Base64-encoded source PDF to annotate. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
decrypt_pdf Decrypt a PDF ~231
Open an encrypted PDF (pdfnative v1.6.0 reader/decryptor — RC4 V1–V4, AES-128 V4/R4, AES-256 V5/R6) and emit an UNENCRYPTED copy. Pass `password` (user or owner); documents with an empty user password decrypt without one. CAVEAT: decryption rebuilds the page tree, so existing signatures and the interactive AcroForm are DROPPED and only self-contained URI links are kept. To READ an encrypted PDF without rebuilding it, pass `password` directly to inspect_pdf / extract_text / extract_attachments instead.
| Name | Type | Req | Description |
|---|---|---|---|
| outputMode | string | — | — |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| password | string | — | Password to open the encrypted source (user or owner). Omit only for documents with an empty user password. |
| pdfBase64 | string | yes | Base64-encoded encrypted PDF to decrypt. NOTE: signatures and AcroForm are dropped (page-tree rebuild). |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
draft_governance_issue Draft a governance-compliant GitHub issue (HITL) ~473
Produce a LOCAL, governance-compliant GitHub issue draft plus a structured compliance report — and NEVER submit anything. This is the MCP-native embodiment of the pdfnative AI-governance / Human-In-The-Loop contract (.github/ai-governance.json, .github/AGENT_RULES.md): the agent is a DRAFTSMAN, the human is the only gate. The server makes NO outbound network call and has NO GitHub write path. The assembled draft is validated against the zero-dependency + reproduction policy; a violation (proposing a runtime dependency, missing reproduction, or duplicateSearchPerformed=false) throws GOVERNANCE_VIOLATION so the human must fix it before submitting under their own identity. Returns the draft markdown inline by default; outputMode='file' also writes a .md to the sandbox. After calling this, present BOTH the draft and the compliance report to the user, then STOP.
| Name | Type | Req | Description |
|---|---|---|---|
| actualBehavior | string | — | What actually happened (defaults to the reproduction result when omitted). |
| affectedPackages | array | — | Packages impacted by this issue (e.g. ["pdfnative-mcp"], ["pdfnative"]). |
| duplicateSearchPerformed | boolean | yes | MUST be true: confirms you searched open AND closed issues/PRs for duplicates before drafting. |
| expectedBehavior | string | yes | What you expected to happen instead. |
| issueType | string | yes | Issue category: 'bug' | 'feature' | 'security' | 'docs' | 'performance'. |
| outputMode | string | — | 'inline' (default) returns the draft markdown in the response. 'file' additionally writes it to the sandbox (requires PDFNATIVE_MCP_OUTPUT_DIR); outputPath must be a relative .md path. |
| outputPath | string | — | Relative .md path inside the sandbox (only when outputMode='file'). |
| reproduction | object | yes | The minimal, locally-executed reproduction that justifies this issue. |
| summary | string | yes | One or two paragraphs describing the problem or proposal. |
| targetRepo | string | — | Destination repository label for the draft (documentation only — the server never contacts it). Typically 'pdfnative-mcp' or 'pdfnative'. |
| title | string | yes | Concise issue title (imperative, no trailing period). |
| Name | Type | Req | Description |
|---|---|---|---|
| compliance | object | yes | — |
| draftMarkdown | string | yes | The full draft, ready for a human to review and submit. |
| filePath | string | — | Sandboxed absolute path (when outputMode='file'). |
| issueType | string | yes | — |
| outputMode | string | yes | — |
| sizeBytes | integer | yes | — |
| targetRepo | string | yes | — |
| title | string | yes | — |
| warnings | array | yes | — |
No examples provided.
embed_image Embed image in PDF ~322
Generate a PDF document with an embedded JPEG or PNG image. The image is accepted as a base64-encoded string and can include an optional caption and custom render dimensions.
| Name | Type | Req | Description |
|---|---|---|---|
| caption | string | — | Optional caption rendered below the image. |
| height | number | — | Render height in points. If omitted, aspect ratio is preserved. |
| imageBase64 | string | yes | Base64-encoded image bytes. Supports JPEG and PNG formats. |
| mimeType | string | yes | MIME type of the image. Must match the actual encoding of imageBase64. |
| outputMode | string | — | Either 'base64' (returns the PDF inline) or 'file' (writes to a sandboxed path inside PDFNATIVE_MCP_OUTPUT_DIR). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pdfA | string | — | 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 embe… |
| title | string | yes | Document title rendered at the top and used as PDF metadata title. |
| width | number | — | Render width in points. If omitted, the image is auto-sized to fit the page. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
encrypt_pdf Encrypt / re-secure a PDF ~348
Re-secure an existing PDF with the PDF Standard Security Handler (pdfnative v1.6.0): AES-128 (V4/R4, default) or AES-256 (V5/R6). RC4 is never emitted. Set ownerPassword (required) and optionally userPassword (open password), algorithm, and permissions { print, copy, modify, extractText }. Re-encrypt an already-encrypted source under a NEW password by passing its current `password` (password rotation in one call). CAVEAT: encryption rebuilds the page tree, so existing signatures and the interactive AcroForm are DROPPED and only self-contained URI links are kept — encrypt BEFORE signing, not after.
| Name | Type | Req | Description |
|---|---|---|---|
| algorithm | string | — | Content cipher: aes128 (V4/R4, widest compatibility) or aes256 (V5/R6, strongest). |
| outputMode | string | — | — |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| ownerPassword | string | yes | Owner password (required, non-empty). Controls permissions and full access. |
| password | string | — | Current password of an already-encrypted source (enables password rotation). Omit for an unencrypted source. |
| pdfBase64 | string | yes | Base64-encoded source PDF to encrypt. NOTE: existing signatures and AcroForm are dropped (page-tree rebuild). |
| permissions | object | — | Access permission flags (enforced by conforming readers). Each defaults to allowed when omitted. |
| userPassword | string | — | User (open) password. Omitted or empty string means the document opens without a password prompt. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
extract_attachments Extract embedded files from PDF ~322
Read-only extraction of embedded files from a non-encrypted PDF (PDF/A-3 / Factur-X / ZUGFeRD). Walks the catalog /Names → /EmbeddedFiles tree and returns each attachment's metadata (name, mimeType, AFRelationship, description, sizeBytes) plus, by default, its decoded payload as dataBase64. Completes the invoice round-trip: add_attachment → inspect_pdf → extract_attachments. Pass `filename` to pull a single named file, or `includeData: false` for a metadata-only probe. Encrypted PDFs are rejected with EXTRACTION_UNSUPPORTED.
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['attachments.name']). Composes after verbosity. Unknown paths are omitted. |
| filename | string | — | Optional exact attachment name to extract. When omitted, every embedded file is returned. |
| includeData | boolean | — | When true (default) each attachment carries its decoded payload as dataBase64. Set false for a metadata-only probe (names, sizes, relationships) with no payload bytes. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes to read embedded files from. |
| verbosity | string | — | Response verbosity. 'full' (default) returns the attachments[] array; 'summary' returns a token-frugal { attachmentCount } and drops the array. |
| Name | Type | Req | Description |
|---|---|---|---|
| attachmentCount | integer | yes | — |
| attachments | array | yes | — |
No examples provided.
extract_pages Extract pages into one PDF ~302
Extract an arbitrary subset of pages (0-based, in the order given) from a PDF into a SINGLE new document (pdfnative v1.4 page-tree API). The output is a fresh, self-contained PDF (signatures/AcroForm dropped; URI links kept unless dropAnnotations=true). Encrypted sources are rejected (ENCRYPTED_SOURCE). Use split_pdf instead when you need several output PDFs (one per range).
| Name | Type | Req | Description |
|---|---|---|---|
| dropAnnotations | boolean | — | When true, drop ALL annotations. Default keeps self-contained URI link annotations. |
| encrypt | object | — | Re-encrypt the produced PDF with the PDF Standard Security Handler (AES-128 V4/R4 default, or AES-256 V5/R6). RC4 is never emitted. Requires a Web Crypto CSPRNG. |
| maxOutputSizeBytes | integer | — | Maximum size, in bytes, of the produced PDF. Defaults to 268435456 (256 MiB). |
| outputMode | string | — | — |
| outputPath | string | — | — |
| pages | array | yes | 0-based page indices to keep, in output order. Duplicates and out-of-range indices are rejected. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded source PDF. Pass `password` for an encrypted source. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
extract_text Extract plain text from PDF ~389
Best-effort plain-text extraction from a non-encrypted PDF. Walks each page's content stream and pulls the operands of Tj/'/"/TJ text operators. The result.extractable boolean is FALSE when one or more pages have non-empty content but yielded no text (this is EXPECTED for PDFs using subset fonts without /ToUnicode CMaps — it is not an error). The accompanying `extractableReason` field explains why. Encrypted PDFs are rejected with EXTRACTION_UNSUPPORTED. Tagged-mode structure-tree extraction (cleaner output for tagged PDFs) is tracked on the roadmap.
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['fullText'] or ['extractable']). Composes after verbosity. Unknown paths are omitted. |
| includeRuns | boolean | — | When true, each page also carries `runs[]` — positioned text-showing operations `{ text, x, y, fontSize, fontName }` in device space (content-stream order). Useful for layout-aware extraction; larger… |
| maxTextLength | integer | — | Hard cap on total extracted characters across all pages (memory bound for adversarial input). Default 16000000. Exceeding it fails with OUTPUT_TOO_LARGE. |
| pages | array | — | Optional 0-based page indices to extract. When omitted, every page is extracted. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes. |
| verbosity | string | — | Response verbosity. 'full' (default) returns the per-page pages[] array and fullText; 'summary' returns a token-frugal { pageCount, extractedPageCount, extractable, charCount } and drops the text pay… |
| Name | Type | Req | Description |
|---|---|---|---|
| extractable | boolean | yes | False when one or more requested pages produced text that is entirely U+FFFD replacement characters — a font with no usable /ToUnicode CMap or base encoding. Blank pages are still considered extracta… |
| extractableReason | string | — | Human-readable explanation when extractable=false. Absent when extractable=true. |
| extractedPageCount | integer | yes | — |
| fullText | string | yes | — |
| pageCount | integer | yes | — |
| pages | array | yes | — |
No examples provided.
fill_form Fill / flatten an existing AcroForm ~443
Fill (and optionally flatten) the AcroForm of an EXISTING PDF (pdfnative v1.6.0) — the counterpart to add_form, which CREATES a new form. Non-destructive incremental update: original bytes are preserved (a prior signature stays valid for its revision). `values` maps fully-qualified field name → value: text/choice take a string (array for multi-select listboxes); checkbox/radio take a boolean or the export-state string. Set flatten:true to stamp appearances into page content and drop the interactive layer (pass no values + flatten:true for a pure flatten). Encrypted documents are supported via `password` (appended objects are encrypted under the existing scheme). Signature fields cannot be filled (FORM_UNSUPPORTED). Discover field names with read_form_fields first.
| Name | Type | Req | Description |
|---|---|---|---|
| flatten | boolean | — | When true, stamp appearances into page content and remove the interactive fields after filling. |
| nonWinAnsi | string | — | Behaviour when a value contains non-WinAnsi characters (appearance font is Helvetica/WinAnsi). 'throw' (default) rejects it; 'needAppearances' writes the value and sets /NeedAppearances so the viewer… |
| onUnknownField | string | — | Behaviour for a value key that matches no field. 'throw' (default) → FORM_FIELD_NOT_FOUND; 'ignore' skips it. |
| outputMode | string | — | — |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded source PDF containing the AcroForm to fill. Use read_form_fields first to discover field names. |
| values | object | — | Map of fully-qualified field name → value. Text/choice: a string (array of strings for multi-select listboxes). Checkbox/radio: a boolean or the export-state string. Omit (or pass {}) with flatten:tr… |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
generate_basic_pdf Generate basic PDF ~591
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.
| Name | Type | Req | Description |
|---|---|---|---|
| blocks | array | yes | Ordered list of content blocks composing the document body. |
| footerText | string | — | Optional footer text rendered at the bottom of every page. |
| normalize | string | — | Optional Unicode normalization applied to all rendered text before shaping. 'NFC' (recommended) composes base + combining marks into precomposed code points for better glyph coverage; 'NFD'/'NFKC'/'N… |
| outline | — | — | Document outline (bookmarks panel). Either 'auto' (derive a flat outline from heading blocks) or an explicit nested bookmark tree. |
| outputMode | string | — | Either 'base64' (returns the PDF inline as a base64 string) or 'file' (writes to a path inside the configured PDFNATIVE_MCP_OUTPUT_DIR sandbox). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pageLabels | array | — | Page-label ranges (the visible page numbers in the viewer, e.g. roman front-matter then decimal body). startPage values must be unique and strictly increasing. |
| pdfA | string | — | 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 embe… |
| title | string | yes | Document title (rendered at top of page 1 and used as PDF metadata title). |
| viewerPreferences | object | — | Reader presentation hints (catalog /PageLayout, /PageMode, /ViewerPreferences). PDF/A-safe; all optional. |
| watermark | object | — | Optional semi-transparent text watermark rendered on every page (e.g. 'DRAFT', 'CONFIDENTIAL'). Text only in this version. opacity < 1.0 is rejected under pdfA='pdfa1b' (ISO 19005-1 forbids transpare… |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
inspect_pdf Inspect PDF metadata ~313
Read-only inspection of an existing PDF: version, page count, encryption state, PDF/A claim, signature count, hasSignaturePlaceholder, embedded attachments[], document info / metadata. Use the `check` array for CI-style assertions — supported values: 'pdfa', 'signed' (true when at least one signature has signed content), 'encrypted', 'placeholder' (unsigned /Sig widget present), 'attachments' (at least one /EmbeddedFile). The checksPassed boolean is true only when ALL requested checks hold.
| Name | Type | Req | Description |
|---|---|---|---|
| check | array | — | Optional CI assertions. The result.checksPassed flag is true only when every requested check holds (e.g. ['pdfa','signed']). |
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['pageCount','signatureCount']). Composes after verbosity. Unknown paths are omitted. |
| pages | boolean | — | When true, include per-page metadata in the response. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes to inspect. |
| verbosity | string | — | Response verbosity. 'full' (default) returns every field; 'summary' returns a token-frugal scalar subset (version, pageCount, encryption, pdfA, signatureCount, hasSignaturePlaceholder, attachmentCoun… |
| Name | Type | Req | Description |
|---|---|---|---|
| attachments | array | yes | Embedded files exposed via /Names → /EmbeddedFiles (PDF/A-3, Factur-X). |
| checks | object | — | — |
| checksPassed | boolean | — | — |
| encryption | string | yes | — |
| encryptionInfo | object | — | Precise Standard Security Handler details (pdfnative v1.6.0), present only when the document is encrypted and was opened successfully. Objects served by the reader are already decrypted. |
| hasSignaturePlaceholder | boolean | yes | True when at least one signature widget exists with empty /Contents — i.e. an unsigned placeholder awaiting `sign_pdf`. |
| info | object | — | Document /Info dictionary entries decoded as strings. |
| pageCount | integer | yes | — |
| pageLabels | array | — | Logical page-numbering ranges from the /PageLabels number tree (ISO 32000-1 §12.4.2), or absent when the document has none. Each range gives the 0-based first page, numbering style, optional prefix a… |
| pdfA | string|null | — | Detected PDF/A claim (e.g. '1B', '2B', '2U', '3B') from XMP metadata, or null when absent. |
| perPage | array | — | — |
| signatureCount | integer | yes | — |
| version | string | yes | PDF version (e.g. "1.7"). |
No examples provided.
merge_pdfs Merge PDFs ~401
Concatenate 2–50 source PDFs into a single document (pdfnative v1.4 page-tree API). Each kept page's object graph is deep-copied into a fresh, self-contained PDF. Signatures and AcroForms are dropped (a page-tree edit invalidates /ByteRange); self-contained URI link annotations are preserved unless dropAnnotations=true. Encrypted sources are rejected (ENCRYPTED_SOURCE) — decrypt first. A secure-by-default 256 MiB in-memory assembly guard (maxOutputSizeBytes) guards against memory exhaustion; the emitted PDF is separately capped at 50 MiB (OUTPUT_TOO_LARGE). Returns one PDF (base64 or sandboxed file).
| Name | Type | Req | Description |
|---|---|---|---|
| dropAnnotations | boolean | — | When true, drop ALL annotations. Default (false) keeps self-contained URI link annotations and drops cross-document/widget annotations. |
| encrypt | object | — | Re-encrypt the produced PDF with the PDF Standard Security Handler (AES-128 V4/R4 default, or AES-256 V5/R6). RC4 is never emitted. Requires a Web Crypto CSPRNG. |
| maxOutputSizeBytes | integer | — | In-memory assembly guard (pdfnative maxOutputSize): the merge throws before materialising an object graph larger than this. Defaults to 268435456 (256 MiB). Note the emitted PDF is separately capped… |
| outputMode | string | — | — |
| outputPath | string | — | — |
| password | string | — | Password applied to every encrypted source (pdfnative v1.6.0). Sources with an empty user password open without it. The merged output is unencrypted unless `encrypt` is set. |
| pdfsBase64 | array | yes | Base64-encoded source PDFs to concatenate, in order. 2–50 documents. Signatures and AcroForms are dropped (a page-tree edit invalidates them); encrypted PDFs are rejected. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
prepare_signature_placeholder Prepare signature placeholder ~507
Create a PDF with an embedded /Sig AcroForm placeholder ready to be digitally signed by the sign_pdf tool. NOTE: as of v1.0.0, sign_pdf auto-injects a placeholder when missing (autoInjectPlaceholder defaults to true), so this tool is OPTIONAL. Use it only when you need to: (a) customize the placeholder size for >4096-bit RSA keys via placeholderBytes, (b) attach the signature widget to a specific page via pageIndex, or (c) precompute and ship the placeholder PDF separately from the signing step. Otherwise call sign_pdf directly with any PDF.
| Name | Type | Req | Description |
|---|---|---|---|
| blocks | array | — | Optional document body blocks rendered before the signature field. |
| contactInfo | string | — | Contact information for the signer. |
| fieldName | string | — | Optional AcroForm field name for the signature widget (default 'Signature1'). |
| location | string | — | Signing location (city / country). |
| outputMode | string | — | Either 'base64' (returns the PDF inline) or 'file' (writes to a sandboxed path inside PDFNATIVE_MCP_OUTPUT_DIR). |
| outputPath | string | — | Required when outputMode='file'. Relative path inside the sandbox; must end with .pdf. |
| pageIndex | integer | — | Zero-based page index the (invisible) widget attaches to (default 0). |
| pdfA | string | — | 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 embe… |
| placeholderBytes | integer | — | Reserved bytes for the future CMS /Contents blob (default 16384). Increase only for >4096-bit RSA or PAdES-B-LT. |
| reason | string | — | Reason for signing (e.g. "Approved", "I agree to the terms"). |
| signerName | string | — | Name of the intended signer, embedded in the /Sig dictionary. |
| title | string | yes | Document title. Used as the PDF metadata title and rendered at the top of page 1. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
read_form_fields Read AcroForm fields ~249
Read-only enumeration of an existing PDF's interactive AcroForm fields (pdfnative v1.6.0). Returns each terminal field's fully-qualified name, classified type (text | checkbox | radio | dropdown | listbox | button | signature | unknown), current value, flags (readOnly / required / multiline), choice options, and widget placements. Call this FIRST to discover field names before driving fill_form. Encrypted sources are supported via `password`. Token-frugal: verbosity:'summary' returns just { fieldCount }.
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['fields.name','fields.type']). Composes after verbosity. Unknown paths are omitted. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes whose AcroForm fields should be enumerated. |
| verbosity | string | — | Response verbosity. 'full' (default) returns the fields[] array; 'summary' returns a token-frugal { fieldCount } and drops the array. |
| Name | Type | Req | Description |
|---|---|---|---|
| fieldCount | integer | yes | — |
| fields | array | yes | — |
No examples provided.
sign_pdf Sign PDF (RSA / ECDSA, PAdES) ~646
Apply a PAdES-compatible CMS digital signature to a PDF. Since v1.0.0 you can sign ANY PDF in ONE call — autoInjectPlaceholder defaults to true, so you do NOT need to run prepare_signature_placeholder first unless you want to customize the placeholder appearance. Supports RSA-SHA256 and ECDSA-SHA256 (P-256). Required inputs: pdfBase64, algorithm, certDerBase64, plus EITHER rsaKeyPkcs1DerBase64 (when algorithm='rsa-sha256') OR ecPrivateScalarHex / ecPrivateKeyDerBase64 (when algorithm='ecdsa-sha256'). To convert PEM keys to DER base64: `openssl pkey -in key.pem -outform DER | base64 -w0`. To convert a PEM X.509 cert: `openssl x509 -in cert.pem -outform DER | base64 -w0`. After signing, call verify_pdf to confirm validity.
| Name | Type | Req | Description |
|---|---|---|---|
| algorithm | string | yes | Signature algorithm. ECDSA only supports P-256 in v1.0.0. |
| autoInjectPlaceholder | boolean | — | When true (default) and the input PDF has no /Sig widget, pdfnative.addSignaturePlaceholder is called before signing — enabling single-call signing of any PDF. |
| certDerBase64 | string | yes | Base64 of the signer X.509 certificate in DER form. Convert from PEM with: openssl x509 -in cert.pem -outform DER | base64 -w0 |
| contactInfo | string | — | — |
| ecPrivateKeyDerBase64 | string | — | Base64 of an ECDSA P-256 private key in SEC1 (RFC 5915) or PKCS#8 (RFC 5208) DER form. Convert from PEM with: openssl pkey -in key.pem -outform DER | base64 -w0 Mutually exclusive with ecPrivateScal… |
| ecPrivateScalarHex | string | — | Hex-encoded P-256 private scalar `d` (exactly 64 lowercase or uppercase hex chars, no 0x prefix). Mutually exclusive with ecPrivateKeyDerBase64; either is accepted for ECDSA. |
| location | string | — | — |
| outputMode | string | — | — |
| outputPath | string | — | — |
| pdfBase64 | string | yes | Base64-encoded PDF bytes. When the PDF already contains a /Sig placeholder it is signed in place; otherwise the placeholder is auto-injected (set autoInjectPlaceholder=false to opt out). |
| reason | string | — | — |
| rsaKeyPkcs1DerBase64 | string | — | Base64 of the RSA private key in PKCS#1 RSAPrivateKey DER (NOT PKCS#8, NOT PEM). Required when algorithm=rsa-sha256. Convert from PEM with: openssl rsa -in key.pem -outform DER -traditional | base64… |
| signerName | string | — | — |
| signingTime | string | — | ISO-8601 timestamp. Defaults to now. |
| Name | Type | Req | Description |
|---|---|---|---|
| filePath | string | — | Absolute sandboxed file path (when mode='file'). |
| mode | string | yes | — |
| sizeBytes | integer | yes | — |
No examples provided.
split_pdf Split PDF into ranges ~411
Split one PDF into several documents — one per requested page range (pdfnative v1.4 page-tree API). Ranges are 0-based and inclusive; `end` defaults to `start` (a single page). Each output is a fresh, self-contained PDF (signatures/AcroForm dropped; URI links kept unless dropAnnotations=true). Encrypted sources are rejected (ENCRYPTED_SOURCE). In base64 mode every produced PDF is returned as its own embedded resource block; in file mode each is written to a 1-based indexed sibling of outputPath ('out.pdf' → 'out-1.pdf', 'out-2.pdf', …). Use extract_pages instead when you want a single PDF from an arbitrary page subset.
| Name | Type | Req | Description |
|---|---|---|---|
| dropAnnotations | boolean | — | When true, drop ALL annotations. Default keeps self-contained URI link annotations. |
| encrypt | object | — | Re-encrypt the produced PDF with the PDF Standard Security Handler (AES-128 V4/R4 default, or AES-256 V5/R6). RC4 is never emitted. Requires a Web Crypto CSPRNG. Applied to every produced range. |
| maxOutputSizeBytes | integer | — | Maximum size, in bytes, of each produced PDF. Defaults to 268435456 (256 MiB). |
| outputMode | string | — | — |
| outputPath | string | — | Base output path (file mode). Each PDF is written to an indexed sibling: 'out.pdf' → 'out-1.pdf', 'out-2.pdf', … |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded source PDF. Pass `password` for an encrypted source. |
| ranges | array | yes | Page ranges to extract, one output PDF per range. 0-based, inclusive; `end` defaults to `start` (a single page). |
| Name | Type | Req | Description |
|---|---|---|---|
| count | integer | yes | — |
| mode | string | yes | — |
| parts | array | yes | — |
| totalBytes | integer | yes | — |
No examples provided.
validate_pdf Validate PDF/UA structure ~290
Read-only PDF/UA (ISO 14289-1) structural conformance check. Verifies the accessibility prerequisites of a Tagged PDF: catalog /MarkInfo /Marked true, /StructTreeRoot (+ /ParentTree), /Metadata (XMP), /Lang, and per-page MCID uniqueness. Response shape: { standard: 'pdf-ua-1', valid, errors: [], warnings: [], summary }. Read `valid` for an overall yes/no; iterate `errors[]` for blocking violations and `warnings[]` for best-practice recommendations. This is a fast structural gate, NOT a full reference validator (veraPDF) — it does not check fonts, colour or rendering. Generate accessible input with any document tool using pdfA (e.g. pdfA='pdfa2u'), then validate the result here.
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['valid']). Composes after verbosity. Unknown paths are omitted. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes to validate for PDF/UA (ISO 14289-1) structural conformance. |
| verbosity | string | — | Response verbosity. 'full' (default) returns errors[] and warnings[]; 'summary' returns a token-frugal verdict { standard, valid, errorCount, warningCount, summary } and drops the message arrays. |
| Name | Type | Req | Description |
|---|---|---|---|
| errors | array | yes | Blocking PDF/UA conformance violations. Empty when valid is true. |
| standard | string | yes | Conformance standard checked (ISO 14289-1). |
| summary | string | yes | Human-readable one-line summary of the result. |
| valid | boolean | yes | True when no blocking structural violations were found. |
| warnings | array | yes | Non-blocking best-practice recommendations. |
No examples provided.
verify_pdf Verify PDF signatures ~380
Read-only verification of every PAdES Baseline / adbe.pkcs7.detached signature in a PDF. For each /Sig widget, recomputes the ByteRange SHA-256, validates the CMS messageDigest (integrity), and verifies the CMS signatureValue with the embedded signer certificate. Supports RSA-SHA256 and ECDSA-SHA256 (P-256). The response shape: { allValid, signatureCount, summary, signatures: [{ valid, integrity, signerSubject, signingTime, reason, chainTrust: 'self-signed'|'unverified'|'trusted', errors: [] }] }. Read `allValid` for an overall yes/no; iterate `signatures[]` for per-signature detail. Without trustedRootsDerBase64, chainTrust is 'self-signed' (single-cert chain) or 'unverified' (signer rooted in an external CA).
| Name | Type | Req | Description |
|---|---|---|---|
| fields | array | — | Optional dot-path projection applied to the structured result (e.g. ['allValid'] or ['signatures.valid']). Composes after verbosity. Unknown paths are omitted. |
| password | string | — | Password to open an encrypted source PDF (user or owner — both are tried). Omit for unencrypted documents. Never logged or echoed back. |
| pdfBase64 | string | yes | Base64-encoded PDF bytes to verify. |
| trustedRootsDerBase64 | array | — | Optional list of base64-encoded X.509 root certificates (DER). When supplied, each signer certificate is validated against these roots; otherwise chainTrust is reported as self-signed or unverified. |
| verbosity | string | — | Response verbosity. 'full' (default) returns the per-signature signatures[] array; 'summary' returns a token-frugal verdict { signatureCount, allValid, invalid, summary } and drops signatures[]. |
| Name | Type | Req | Description |
|---|---|---|---|
| allValid | boolean | yes | — |
| signatureCount | integer | yes | — |
| signatures | array | yes | — |
| summary | string | yes | — |
No examples provided.