Typeset PDFs, from your own code

Add typeset-PDF generation to your app or agent — one HTTP call in, a designed, print-ready PDF out. 1 credit per PDF, and a failed conversion costs nothing.

No subscription. Credits come in packs and never expire.

REST API

One POST, bearer auth, JSON in and a download link out. OpenAPI 3.1 published.

MCP server

Three tools in any MCP client over stdio. Your agent converts without you writing a client.

Claude Skill

Ask for a PDF in plain language; the skill picks the theme and mode and hands back a link.

GPT Action

Import the OpenAPI document into a custom GPT — nothing to build, only to configure.

Convert your first document

Set $MDPRINT_API_URL to this site's origin and $MDPRINT_API_KEY to your key, then:

curl -X POST $MDPRINT_API_URL/api/v1/convert \
  -H "Authorization: Bearer mdp_sk_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "markdown": "# Quarterly Review\n\nRevenue is up.",
    "theme": "default",
    "mode": "report"
  }'

The response carries a link to the finished PDF, valid for five minutes:

{
  "download_url": "https://…/api/download/<token>/quarterly-review.pdf",
  "expires_in": 300,
  "filename": "quarterly-review.pdf",
  "bytes": 214512,
  "credits_remaining": 41
}

markdown is the only required field. theme fantasy gives the tabletop treatment — stat blocks, GM callouts, parchment; default covers reports, newsletters, newspapers, résumés, certificates and poetry. GET /api/v1/themes lists every value that exists, so an agent can read the options rather than guess them.

Use it from an MCP client

The MCP server is a thin stdio client over the same API. Drop this into your client's config — Claude Desktop puts it under Settings → Developer → Edit Config:

{
  "mcpServers": {
    "grimoireprint": {
      "command": "npx",
      "args": ["-y", "@mdprint/mcp-server"],
      "env": { "MDPRINT_API_KEY": "mdp_sk_your_key_here" }
    }
  }
}

In Claude Code it is one line:

claude mcp add grimoireprint --env MDPRINT_API_KEY=mdp_sk_your_key_here -- npx -y @mdprint/mcp-server

Restart the client and three tools appear: convert_markdown_to_pdf, list_themes and get_credit_balance. Running out of credits, a bad key or a rate limit come back as ordinary tool errors saying what to do about them.

stdio, not a remote endpoint. The key comes from the environment, which is what the MCP specification asks of a stdio server. A hosted HTTP endpoint would need full OAuth 2.1, so it is not offered rather than shipped as a deviation.

Or skip the client entirely

Pricing

One credit per PDF. The credit is spent only once the PDF exists, so a rejected request, an invalid option or a conversion failure is never charged. API keys spend purchased credits, and nothing they produce is watermarked.

50 Pack $5 50 PDFs
200 Pack $15 200 PDFs
500 Pack $30 500 PDFs

Packs are one-time purchases and the credits never expire. The monthly free allowance is for browser use; a key has none, because keys are free to mint and one would be an unlimited free tier. Each key has an hourly conversion allowance — 60 by default, raisable on request — and every response carries the numbers in its headers.

Get a key

Keys are issued on request while self-service key management is being built. Tell us roughly what you are building and how many PDFs a month you expect, and we will send one back with a starting balance.

A key is shown once and stored only as a hash — treat it like a password, because it spends real credits.