Generate PDFs from your AI agent
Connect Papyr to Claude, Cursor, Windsurf, or any MCP-compatible AI tool. Ask your AI to generate an invoice PDF — it calls Papyr and saves the file. No integration code required.
What you can ask your AI
Setup
Get your API key
Sign up at getpapyr.dev/signup and copy your API key from the dashboard. Free tier includes 100 documents per month.
Add to Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json and add:
{
"mcpServers": {
"papyr": {
"command": "npx",
"args": ["-y", "papyr-mcp"],
"env": {
"PAPYR_API_KEY": "pk_live_..."
}
}
}
}Add to Cursor
Open Cursor Settings → MCP → Add server, or edit ~/.cursor/mcp.json:
{
"mcpServers": {
"papyr": {
"command": "npx",
"args": ["-y", "papyr-mcp"],
"env": {
"PAPYR_API_KEY": "pk_live_..."
}
}
}
}Restart and ask
Restart Claude Desktop or Cursor. Then just ask: "Generate an invoice PDF for order #1042 and save it to ./invoice.pdf"
Available tools
render_pdfGenerate a PDF from an HTML string. Supports inline styles, Google Fonts, Flexbox, Grid, and all modern CSS. Pass an output_path to save directly to disk.
params: html, options (format, landscape, margin, printBackground), output_path
render_templateGenerate a PDF using a built-in template. Pass JSON data for invoice, receipt, or report — no HTML required.
params: template (invoice|receipt|report), data, options, output_path
list_templatesList available built-in templates and their expected data fields.
params: none