MCP.Market

CastPDF MCP server

by castpdf·io.github.castpdf/castpdf-mcp·v0.1.0

Create PDFs from your CastPDF templates or HTML, issue EU e-invoices, and look up documents.

B83/100grade B
What users say
No reviews yet
Be the first
Safety scan
B83/100

full report

Adoption
New

0 stars

Reviews

Write one

Nobody has reviewed CastPDF yet.

If you have run it, two minutes of your experience saves the next person an afternoon.

CastPDF tools (6, 2 write)

write = sends, deletes, buys or posts

Read from the package source without running it. The installed server may list more.

  • create_e_invoicewrite action

    Issues a structured invoice as an EU e-invoice and returns a signed download URL. standard: zugferd or factur-x give a PDF/A-3b with the XML embedded (readable by people and machines; for Germany prefer zugferd); xrechnung-cii or xrechnung-ubl give the XRechnung XML only (German public sector; needs invoice.buyer_reference = Leitweg-ID and electronic_address on seller and buyer). Totals and VAT ar

  • create_pdfwrite action

    Renders a PDF and returns a signed download URL (valid until expires_at). Give EITHER template_id with data (the usual way: see get_template_fields for the data shape) OR raw html (with optional css; the html may use Liquid tags such as {{ name }} filled from data). By default it makes a TEST document (watermarked, not counted); set test to false only when the user explicitly asks for a live/final

  • get_document

    Looks up one generated document by id: status, error code if it failed, page count, and a fresh signed download URL while the file is stored.

  • get_template_fields

    Returns the fields a template expects, read from its sample data: scalar fields by dotted path (e.g. customer.name) with type and sample value, and line_items (arrays of objects, e.g. invoice positions) with the fields of one item. Build the `data` object for create_pdf from this: nest dotted paths as objects (customer.name becomes { "customer": { "name": ... } }) and send line items as arrays of

  • list_documents

    Lists generated documents (PDFs and e-invoices), newest first: id, status (queued, processing, succeeded, failed, canceled), pages, test flag, template, created_at, and a signed download URL while the file is stored. Page with next_before.

  • list_templates

    Lists the PDF templates saved in the CastPDF account (id, name, current version, updated_at). Use it to find the template_id for create_pdf, then call get_template_fields to see which data the template expects.

Public scan report

scanner v0.1.10 · 2026-10-12 · same rubric, same numbers if you re-run it

no findings
  • Code scan6 source files scanned25/25
  • –Live reliabilityno gateway calls yet and no remote to proben/a
  • –Tool poisoningtools not inspected (local package is not executed); not countedn/a
  • Auth qualitystatic API keys via environment variables6/15
  • Maintenancelast push 0 days ago15/15
  • Maintainer identityregistry namespace matches repository owner; GitHub account older than a year8/10
Overall 83/100. Components that don't apply are left out of the denominator. Any critical finding is an F.RubricAppeal a findingJSON

How CastPDF compares

Against every graded MCP server, from our own scans and uptime checks. Updated after each scan run.

Safety score
83/100
higher than 65% of 48,255 servers
Tools
6
the typical server has 7
Tools that change things
33%
typical: 0%. Fewer write tools means less an agent can break

What its tools let an agent do: 4 read · 2 create

Install CastPDF in Claude Code, Cursor or VS Code

Runs npx -y @castpdf/mcp on your machine. Read the scan report first; the gateway never runs local packages.

claude mcp add castpdf-mcp -- npx -y @castpdf/mcp
Add to Cursor

What the publisher says

From the CastPDF repository's README, as published. We do not edit it. Read it on GitHub

CastPDF MCP server

The official Model Context Protocol server for CastPDF. It lets AI agents (Claude, Cursor and other MCP clients) list your PDF templates, create PDFs and EU e-invoices, and look up documents, using your CastPDF API key.

Documents are test documents by default (watermarked, not counted against your plan). The agent only makes a live document when you explicitly ask for one, and a cpdftest... key can never make live documents at all. Start with a test key.

Tools

Download links are signed and expire (see expires_at); the agent shares the link, the file itself is not sent through the conversation.

Setup

You need Node.js 20 or newer and a CastPDF API key (dashboard > API keys). The server reads the key from the CASTPDFAPIKEY environment variable.

Claude Desktop

Settings > Developer > Edit Config, then add to claudedesktopconfig.json:

{
  "mcpServers": {
    "castpdf": {
      "command": "npx",
      "args": ["-y", "@castpdf/mcp"],
      "env": { "CASTPDF_API_KEY": "cpdf_test_..." }
    }
  }
}

Restart Claude Desktop. On Windows, if npx is not found, use "command": "cmd" and "args": ["/c", "npx", "-y", "@castpdf/mcp"].

Claude Code

claude mcp add castpdf --env CASTPDF_API_KEY=cpdf_test_... -- npx -y @castpdf/mcp

Add --scope user to use it in every project. Check it with claude mcp list or /mcp inside Claude Code.

Cursor

Add to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (one project):

{
  "mcpServers": {
    "castpdf": {
      "command": "npx",
      "args": ["-y", "@castpdf/mcp"],
      "env": { "CASTPDF_API_KEY": "cpdf_test_..." }
    }
  }
}

Do not commit a file that contains your key.

Other clients

Any MCP client that starts stdio servers works with the command npx -y @castpdf/mcp and the environment variable CASTPDFAPIKEY.

Streamable HTTP

For clients that connect over HTTP, or to run one shared server:

CASTPDF_API_KEY=cpdf_test_... npx -y @castpdf/mcp --http --port 3000
# MCP endpoint: http://127.0.0.1:3000/mcp   health check: http://127.0.0.1:3000/health

Every request to that endpoint uses the server's API key, so:

(DNS rebinding protection) and no browser Origin.

  • By default it listens on 127.0.0.1 only and accepts only localhost, 127.0.0.1 and [::1] as Host header

on any other interface (--host 0.0.0.0). Put a TLS-terminating proxy in front of it, and list the public host name in CASTPDFMCPALLOWED_HOSTS.

  • Set CASTPDFMCPAUTH_TOKEN to require Authorization: Bearer on every request. It is required to listen
  • The server is stateless (no sessions, POST only), so it can run behind a load balancer.

Example client config for HTTP (Claude Code):

claude mcp add --transport http castpdf http://127.0.0.1:3000/mcp

Configuration

Shortened. The full README is on GitHub.

Nothing above is checked by us. What we check is on the safety report.

CastPDF: common questions

Is CastPDF MCP server safe?
Mostly: it is graded B (83/100). Read the CastPDF safety report
How do I install CastPDF?
It runs on your machine. Copy the Claude Code, Cursor, VS Code or Claude Desktop config from the install section.
Does CastPDF need an API key?
Yes. The registry entry asks for CASTPDF_API_KEY.
Is CastPDF maintained?
The last commit was 23 days ago (2026-10-12). The latest release is v0.1.0.
What can I use instead of CastPDF?
Servers from other publishers that do the same job: Docling MCP server.
How does CastPDF compare with other MCP servers?
safety score 83/100 (higher than 65% of 48,255 servers); tools 6 (the typical server has 7); tools that change things 33% (typical: 0%. Fewer write tools means less an agent can break). Full comparison.

Alternatives to CastPDF

Same job from other publishers: the closest match first, then the best rated.

  • Docling MCP
    Convert PDFs and other documents to structured formats via Docling, for AI applications.
    A