Skip to content
PenBlitz
← Developers

Command line

penblitz-server does everything without a window: serve the API, render, print and set up assistants.

Where it is

The program is inside the app. Call it by its full path, or add a link to it somewhere on your PATH.

/Applications/PenBlitz.app/Contents/MacOS/penblitz-server --help

Commands

CommandWhat it does
serveRuns the REST API. Options: --port, --bind, --api-key, --printer.
renderWrites previews as SVG (and G-code with --gcode) into a folder.
printPrints a document or mail merge and waits until it is finished.
templatesLists the stored templates.
examplePrints sample mail-merge data as CSV, or JSON with --json.
traceTurns a picture of a signature into a single-line SVG.
discoverSearches the local network for printers.
mcpRuns as MCP server for AI assistants.
mcp-installRegisters the MCP server: claude-code, codex, claude-desktop, cursor or all.
openapiPrints the OpenAPI description of the API.

Examples

# previews of a mail merge, one SVG per row
penblitz-server render --template voucher-qr --csv customers.csv --out preview/

# print a short letter right away
penblitz-server print --text "Dear Anna, thank you!"

# one placeholder from the command line
penblitz-server print --template letter --set text="Hello"

# the API without a printer, for development
penblitz-server --mock serve --port 8787

# a signature photo as pen line
penblitz-server trace signature.png signature.svg

Options for every command

  • --mock simulates the printer; no hardware is needed.
  • --data-dir uses another folder for settings, templates and jobs.

Do not run penblitz-server serve and the app at the same time: both would use the same settings and the same printer.