For AI agents
An MCP server for PDF generation
pdfs.build runs a hosted Model Context Protocol server. Connect Claude Code, Cursor, Codex or any MCP client, and your agent gets the whole document lifecycle as native tools: create a template, write its code and schema, compile it against edge-case data, publish it, and render the finished PDF. One endpoint and a browser sign-in. No API key, no integration code.
Connect in one line
- Claude Code
- Cursor
- OpenAI Codex
- VS Code Copilot
- Gemini CLI
- GitHub Copilot CLI
- opencode
- Windsurf
https://backend.pdfs.build/mcp # Claude Code
claude mcp add --transport http pdfs-build https://backend.pdfs.build/mcp
# OpenAI Codex
codex mcp add pdfs-build --url https://backend.pdfs.build/mcp
codex mcp login pdfs-build
# Gemini CLI
gemini mcp add --transport http pdfs-build https://backend.pdfs.build/mcp
Clients that read a config file take the same URL. This is Cursor's
.cursor/mcp.json:
{
"mcpServers": {
"pdfs-build": {
"url": "https://backend.pdfs.build/mcp"
}
}
} Add to Cursor Opens Cursor and installs the server.
VS Code Copilot, GitHub Copilot CLI, opencode and Windsurf connect the same way. Once you have an account, the app lists the exact setup for each client under Developers, then MCP.
What your agent can do
The server exposes the full template lifecycle, not just a render call. An agent can take a document from a sentence to a published template to a PDF inside one conversation.
Find a starting point
Look through your own library or the design gallery, clone a template, or open a blank draft.
list_templates browse_templates create_template duplicate_template
Write the template
Author the template code, the JSON schema that validates incoming data, and the sample data that keeps the preview honest.
write_document edit_document write_schema write_sample_data
Check its own work
Compile against generated edge-case data and read diagnostics per case, so the agent repairs a broken layout before you ever see it.
compile_document
Save and publish
Save a checkpoint, then publish. Publishing only succeeds when the template compiles.
save_template publish_template
Render the PDF
Render a saved template with real data, with no API key involved, and get expiring share and download links back.
render_template
Set up everything around it
Mint REST API keys, register webhook endpoints on paid plans, install fonts, and turn an existing Word document into a template.
create_api_key create_webhook install_google_font import_docx
The complete tool list, with what each one takes and returns, is in the API reference.
What a conversation looks like
The model reads the template's schema and maps what it knows onto it. You design the document once. There is no glue code between the two, and when the template gains a field, every connected agent sees it on its next call.
- 1 You: “Generate the October invoice for Acme.”
- 2
list_templatesfinds the invoice template in your library. - 3
get_templateloads its code, its schema and its sample data. - 4
compile_documentconfirms the template compiles with the data the agent assembled. - 5
render_templatereturns the rendered document with share and download links. - 6 Agent: “Here is the invoice,” with the link.
MCP or the REST API?
Use MCP when an AI agent is doing the work: designing a template with you, or producing a document in the middle of a conversation. It needs no API key and is included in every plan.
Use the REST API when your own backend renders documents at volume. It takes an API key and adds async jobs, batches and webhooks, and it starts on the Starter plan.
Both work on the same templates and draw on the same monthly render quota. A common split is an agent that builds and maintains the templates over MCP, and a service that renders them over REST.
What it costs
In every plan
The MCP server is included from Starter up, at no extra cost. Pro starts with a 7-day free trial.
Renders count once
A render over MCP draws on the same monthly quota as a render from the app or the REST API.
No AI credits spent
Your assistant does the reasoning, so designing over MCP does not use your AI design credits.
Plans and quotas are on the pricing page.
Frequently asked questions
Do I need an API key to use the MCP server?
No. The MCP endpoint signs you in with OAuth 2.1. On first use your client opens a browser tab, you approve access, and the client stores and refreshes the token. API keys belong to the REST API and are not accepted on the MCP endpoint.
Which AI clients can connect?
Any client that supports remote MCP servers over Streamable HTTP. The app has ready-made setup for Claude Code, Cursor, OpenAI Codex, VS Code Copilot, Gemini CLI, GitHub Copilot CLI, opencode and Windsurf.
Is the MCP server included in every plan?
Yes, at no extra cost, from Starter up. Pro starts with a 7-day free trial. Renders made over MCP count toward your plan's monthly render quota.
Does designing over MCP use my AI design credits?
No. Over MCP your own assistant does the reasoning and pdfs.build runs the tools: it stores the template, compiles it and renders it. AI design credits are spent only by the assistant built into the pdfs.build editor.
Can several agents work at the same time?
Yes, with one connection each. A connection holds one active template and every edit must name it, so a write cannot land on the wrong document. Agents that share a connection share its active template.
When should I use the REST API instead?
Use the REST API when your own backend renders documents at volume. It takes an API key and adds async jobs, batches of up to 500 documents and webhooks. Use MCP when an AI agent is doing the work in a conversation. Both use the same templates and the same render quota.
For a longer walkthrough, read The pdfs.build MCP Server: PDF Generation for Any AI Agent.
Give your agent a document engine
Pro is free for 7 days, then $49 a month. Plans start at $19 a month.
Start 7-day free trial