MCP Server (Claude / Cursor / VS Code)
We provide an official Model Context Protocol (MCP) server, reportflow-mcp, that lets any MCP-compatible AI client — Claude Desktop, Claude Code, Cursor, VS Code, and more — generate Report Flow PDFs from natural language.
- Hosted endpoint (no npm required):
https://mcp.re-port-flow.com/mcp - npm:
reportflow-mcp - Source: github.com/re-port-flow/reportflow-mcp
- MCP Registry:
io.github.re-port-flow/reportflow-mcp
Why Report Flow MCP?
Several MCP servers exist for business-document generation, but Report Flow MCP differentiates itself on three axes.
- Remote-ready, setup-free — A hosted endpoint at
https://mcp.re-port-flow.com/mcplets you connect from Claude.ai (web) without installing npm or Node.js. Unlike other Japanese 帳票 (chohyo) MCP servers that ship as stdio-only local processes, business users without a dev environment can start using it day one. - No-code template design + template marketplace — Templates are designed in a browser-based GUI editor (Konva-based) with no code. A free template gallery covers invoices, quotes, receipts, delivery slips, reports and more, so AI agents can invoke ready-made templates from day one. You don't need to author JSON schemas to add templates.
- OAuth 2.0 + dynamic client registration — Authentication is OAuth 2.0 (Authorization Code + PKCE) with Dynamic Client Registration — no API key is ever handed to the AI client. Local-mode tokens live in the OS keychain; remote-mode tokens are managed server-side. The security posture matches Claude.ai's first-party Connectors.
What it does
- Generate PDFs from natural-language requests like "create an invoice for Acme Corp totalling $330"
- Expose your Report Flow designs and their parameter schemas to the AI as MCP Resources
- Bulk-generate many PDFs and download them as a single ZIP
- Save outputs to whichever workspace folder the AI client is currently in
Requirements
- Node.js 18+ (auto-fetched by
npx) - A local environment with a browser (only for the first login)
- A Report Flow account
These are the requirements for local execution (npx). With the remote (hosted) server, you don't need Node.js or a local browser/keychain — all you need is a Report Flow account and an AI client that supports remote MCP servers.
Setup
There are two ways to set up. Local execution (npx) is recommended, and it can save generated PDFs into your local workspace folder. If you'd rather not install Node.js, or you're using a browser-based client such as Claude.ai (web), use the remote (hosted) server.
Local execution (npx, recommended)
Claude Desktop / Claude Code / Cursor
Add the following to your config file (.mcp.json, claude_desktop_config.json, ~/.cursor/mcp.json, etc.):
{
"mcpServers": {
"reportflow": {
"command": "npx",
"args": ["-y", "reportflow-mcp"]
}
}
}
That's the entire setup. No env vars, no API keys, no secrets to manage on the client — authentication uses OAuth.
VS Code (MCP-enabled builds)
VS Code uses a top-level servers key (different from Claude / Cursor's mcpServers). Add the following to .vscode/mcp.json:
{
"servers": {
"reportflow": {
"command": "npx",
"args": ["-y", "reportflow-mcp"]
}
}
}
Remote (hosted) server
No npm or Node.js installation required — you connect to a hosted endpoint by URL. This suits Claude.ai (web) and any client that supports remote MCP servers. Authentication runs as OAuth (Dynamic Client Registration) in the client's browser, and tokens are managed server-side, so no local keychain is used.
Endpoint:
https://mcp.re-port-flow.com/mcp
For clients that support the HTTP transport (Claude Code, Cursor, etc.), add the following to your config file:
{
"mcpServers": {
"reportflow": {
"type": "http",
"url": "https://mcp.re-port-flow.com/mcp"
}
}
}
In VS Code (.vscode/mcp.json), the top-level key is servers:
{
"servers": {
"reportflow": {
"type": "http",
"url": "https://mcp.re-port-flow.com/mcp"
}
}
}
With the Claude Code CLI you can also add it with:
claude mcp add --transport http reportflow https://mcp.re-port-flow.com/mcp
In Claude.ai (web / desktop), register the URL above under Settings → Connectors (custom connector). An OAuth consent screen opens in your browser on connect.
The remote server can't access your file system, so generated PDFs are not saved to a local workspace folder — they're returned as download URLs instead. If you want generated files saved locally and automatically, use local execution (npx).
First-run authentication
After reloading the MCP client, ask the AI:
Authenticate with ReportFlow
A browser window opens. Sign in → pick a workspace → consent, and you're done. Tokens are stored in your OS keychain (macOS Keychain / Windows Credential Manager / Linux libsecret) and refreshed automatically.
On Linux without libsecret, the server automatically falls back to a chmod-0600 file under $XDG_STATE_HOME/reportflow-mcp/.
The steps above apply to local execution (npx). With the remote server, the OAuth consent flow starts automatically when the client connects, and tokens are managed server-side. There's no need to ask the AI to "log in" and no local keychain is involved.
Usage
1. Generate a PDF from natural language
Using the invoice template, create a PDF for Acme Corp totalling $330.
Behind the scenes the AI will:
- Look up your designs via
list_templates - Fetch the parameter schema with
get_design_parameters - Build a
paramsobject from your request - Call
generate_pdf_syncand return the local file path
2. Slash commands (prompt templates)
| Command | Purpose |
|---|---|
/generate_pdf | Step-by-step recipe for a single PDF |
/generate_pdfs | Recipe for batch PDF generation |
/reportflow_help | Quick feature tour |
3. Where files are saved
Output location is resolved in this order:
- An explicit instruction from the user (e.g. "save to my Desktop")
- The currently-open workspace root (Claude Code / Cursor / VS Code)
- The OS temp directory as fallback
Reference
Tools (called by the AI)
| Tool | Purpose |
|---|---|
authenticate | First-time / re-authentication |
list_templates | List available designs |
get_design_parameters | Fetch the parameter schema for a design |
generate_pdf_sync / generate_pdf_async | Generate one PDF (sync returns a path; async returns a request ID) |
generate_pdfs_sync / generate_pdfs_async | Generate many PDFs (returns a ZIP) |
download_file / download_zip | Download artifacts produced by async tools |
suggest_params | Translate a natural-language brief into a params JSON via MCP Sampling (requires a Sampling-capable client) |
Resources (attachable as AI context)
| URI | Contents |
|---|---|
reportflow://designs | List of available designs |
reportflow://designs/{designId}/parameters | Parameter schema for one design |
reportflow://errors | Catalog of error messages from the Content Service |
reportflow://server-info | Server feature overview |
Prompts
/generate_pdf, /generate_pdfs, /reportflow_help — pass arguments and the AI follows the prepared workflow.
Related endpoints
The MCP server calls the Report Flow API under the hood. For the underlying contracts, see:
- Single PDF Sync Generation
- Single PDF Async Generation
- Multiple PDF Sync Generation
- Multiple PDF Async Generation
- File Download
- Design Parameters
Troubleshooting
Errors containing re-authentication required
Your tokens have expired. Ask the AI: "re-authenticate with ReportFlow".
npx cannot find the package
npm cache clean --force
then retry.
No keychain available on Linux
If libsecret is missing, the server automatically falls back to a chmod-0600 file under $XDG_STATE_HOME/reportflow-mcp/.
Browser cannot open over SSH / remote shell
Authenticate once on a local machine. After the initial login, the cached token can be reused on remote hosts — either via the same OS keychain entry, or by copying the fallback file mentioned above.
Rate limit exceeded (429)
Per-workspace rate limit. Wait the number of seconds reported in the Retry-After header before retrying. For batch jobs, prefer the async endpoints.
Support
- Bugs / feature requests: GitHub Issues
- General API questions: Report Flow API documentation
Next steps
- Async Workflows — bulk-generation best practices
- Webhook Notifications — completion events and HMAC-SHA256 verification
- n8n integration — low-code workflow integration