pdfnative-cli command builder
Pick a command, fill the form, copy the resulting npx pdfnative-cli invocation. Covers all twenty-one commands of pdfnative-cli v1.4.0 — authoring (render, fill, annotate, metadata), the page tree (merge, split, extract), the complete PAdES ladder (sign --timestamp B-T, ltv B-LT, doc-timestamp B-LTA, plus encrypt / decrypt and verify), reading (inspect, extract-text, compare), and automation (batch with declarative manifests, doctor, schema, completion, govern). The most-used flags have form fields; the CLI guide is the exhaustive flag reference. The builder runs entirely in your browser — nothing is uploaded.
--chunk-size.
E_CHECK_FAILED.
--stream / --stream-true.
PdfLayoutOptions. CLI flags override the layout file.
--font (22 bundled scripts).
$PDFNATIVE_SIGN_KEY.
$PDFNATIVE_SIGN_CERT.
$PDFNATIVE_SIGN_CHAIN.
node:crypto, inheriting its side-channel hardening; the pure-JS path is not constant-time.
--json: { valid, signatures, invalid }.
Scope (since v1.0.0): full CMS/PKCS#7 verification (RSA-SHA256 — plus SHA-384/512 since v1.4.0 — and ECDSA-SHA256), byte-range integrity, certificate chain, trust evaluation against --trust roots, RFC 3161 timestamp validation (PAdES-T) incl. /DocTimeStamp revisions (v1.4.0), and OCSP/CRL revocation checking. See the CLI guide.
Encrypted sources are supported since v1.3.0 — decrypt them on ingest with --password, and re-encrypt the merged output with --encrypt. Signatures and /AcroForm are dropped (page edits invalidate /ByteRange); URI /Link annotations are preserved. Every path is validated against traversal.
<prefix>-<n>.pdf.
{ "annotations": [...] }): each entry a markup annotation plus a 1-based page.
Written with an incremental save, so existing signatures stay valid. Types: text, highlight, underline, strikeout, squiggly, square, circle, line, freetext. Overlay, not redaction.
rules prints the agent/human protocol; policy the machine-readable JSON; verify-issue gates a draft.
E_POLICY on a violation.
policy).
Agents act as draftsmen: a human must always review and submit. verify-issue is a pure, fully offline validator — no GitHub or network access.
schema metadata). Mutually exclusive with the individual flags.
Written as an incremental save — the original bytes stay as a prefix, so existing signatures remain valid for their revision. /Info and XMP stay in sync. Reading metadata remains inspect's job.
/DSS dictionary.
collect writes the evidence JSON; embed / add write the PDF.
collect / add — the explicit network opt-in (SSRF-guarded). embed is 100 % offline.
collect — the air-gap bridge.
/DSS. Repeatable.
Air-gapped workflow: ltv collect --online on a connected machine → transfer the JSON → ltv embed --data inside the enclave, where no network I/O is even possible. Continue to B-LTA with doc-timestamp.
Appends an RFC 3161 /DocTimeStamp revision (/SubFilter /ETSI.RFC3161, ISO 32000-2 §12.8.5) covering every byte — PAdES B-LTA. Earlier revisions stay byte-identical; run again years later to renew the protection.
{ text, x, y, fontSize, fontName }.
0 disables.
{ pages, characters }.
Real Unicode from the /ToUnicode mapping in reading order — ndjson is a natural feed for a RAG ingestion pipeline.
CI contract: identical → exit 0; different → the report prints on stdout first, then exit 1 / E_CHECK_FAILED. Not a visual diff — pdfnative has no rasteriser; compare diffs what the format declares.
--flatten or --export.
--data shape.
The three modes compose into a round trip: --export the current values, edit the JSON, feed it back with --data, optionally --flatten.
*.json documents (directory mode).
{ "version": 1, "tasks": [{ "id", "command", "flags" }] }. "@<id>" references an earlier task's output; a 14-command whitelist applies (never ltv / compare / the meta commands); validated in full before anything runs; max 1 000 tasks.
--timestamp, --url, --online, --revocation online).
@id-dependent tasks are skipped.
{ total, succeeded, failed }.
Five offline checks: CLI version, Node (≥ 22 since v1.4.0), WebCrypto CSPRNG, resolved pdfnative engine version, and the command count. The first thing to run in a new environment — and the first thing an agent should call.
$id embeds the CLI version, so agents can self-validate before invoking a command. 19 subjects in v1.4.0.
Generated command
npx pdfnative-cli render
Paste this in any shell. Secrets are never sent — the entire builder runs client-side.
What this playground does not do
It does not execute the CLI in your browser — signing real PDFs requires real private keys, and we will not pretend to. For an in-browser demo of render output, see the homepage live demo. To exercise the full CLI on your machine: npx pdfnative-cli <your built command>.
Resources
- CLI guide — full command reference, security model, recipes
- pdfnative-cli on GitHub
- pdfnative-cli release notes
- MCP guide · MCP playground