Frappe MCP Server
About
An MCP server for the Frappe Framework, enabling AI assistants to interact with Frappe's REST API for document management and schema operations.
Details
- Author
- sena-it
- Categories
- Developer Tools, Other, API, Database
Jump to
Setup
Install Frappe MCP Server in your MCP client (Claude Desktop, Cursor, Windsurf, and others).
Repository: https://github.com/sena-it/frappe-mcp-server
Follow the installation instructions in the repository README, then restart your MCP client.
An MCP server for the Frappe Framework, enabling AI assistants to interact with Frappe's REST API for document management and schema operations.
A Model Context Protocol (MCP) server for Frappe Framework that exposes Frappe's functionality to AI assistants through the official REST API, with a focus on document CRUD operations, schema handling, and detailed API instructions.
This MCP server allows AI assistants to interact with Frappe applications through a standardized interface using the official Frappe REST API. It provides tools for:
- Document operations (create, read, update, delete, list)
- Schema and metadata handling
- DocType discovery and exploration
- Detailed API usage instructions and examples
The server includes comprehensive error handling, validation, and helpful responses to make it easier for AI assistants to work with Frappe.
- Node.js 18 or higher
- A running Frappe instance (version 15 or higher)
- API key and secret from Frappe (required)
The server is configured using environment variables:
- FRAPPE_URL: The URL of your Frappe instance (default:http://localhost:8000)
- FRAPPE_API_KEY: Your Frappe API key (required)
- FRAPPE_API_SECRET: Your Frappe API secret (required)
Important: API key/secret authentication is the only supported authentication method. BothFRAPPE_API_KEYandFRAPPE_API_SECRETmust be provided for the server to function properly. Username/password authentication is not supported.
This MCP serveronly supports API key/secret authenticationvia the Frappe REST API. Username/password authentication is not supported.
To get API credentials from your Frappe instance:
- Go to User > API Access > New API Key
- Select the user for whom you want to create the key
- Click "Generate Keys"
- Copy the API Key and API Secret
- Verify that bothFRAPPE_API_KEYandFRAPPE_API_SECRETenvironment variables are set correctly
- Ensure the API key is active and not expired in your Frappe instance
- Check that the user associated with the API key has the necessary permissions
- Verify the Frappe URL is correct and accessible
The server provides detailed error messages to help diagnose authentication issues.
FRAPPE_URL=https://your-frappe-instance.com FRAPPE_API_KEY=your_api_key FRAPPE_API_SECRET=your_api_secret npx frappe-mcp-server
To use this MCP server with an AI assistant, you need to configure the assistant to connect to this server. The exact configuration depends on the AI assistant platform you're using.
For Claude, add the following to your MCP settings configuration file:
{ "mcpServers": { "frappe": { "command": "npx", "args": ["frappe-mcp-server"], // Assumes frappe-mcp-server is in MCP server path "env": { "FRAPPE_URL": "https://your-frappe-instance.com", "FRAPPE_API_KEY": "your_api_key", // REQUIRED "FRAPPE_API_SECRET": "your_api_secret" // REQUIRED }, "disabled": false, "alwaysAllow": [] } } }
Note: BothFRAPPE_API_KEYandFRAPPE_API_SECRETenvironment variables are required. The server will start without them but most operations will fail with authentication errors.
- create_document: Create a new document in Frappe
- get_document: Retrieve a document from Frappe
- update_document: Update an existing document in Frappe
- delete_document: Delete a document from Frappe
- list_documents: List documents from Frappe with filters
- get_doctype_schema: Get the complete schema for a DocType including field definitions, validations, and linked DocTypes
- get_field_options: Get available options for a Link or Select field
- get_frappe_usage_info: Get combined information about a DocType or workflow, including schema metadata, static hints, and app-provided usage guidance
- find_doctypes: Find DocTypes in the system matching a search term
- get_module_list: Get a list of all modules in the system
- get_doctypes_in_module: Get a list of DocTypes in a specific module
- check_doctype_exists: Check if a DocType exists in the system
- check_document_exists: Check if a document exists
- get_document_count: Get a count of documents matching filters
- get_naming_info: Get the naming series information for a DocType
- get_required_fields: Get a list of required fields for a DocType
- get_api_instructions: Get detailed instructions for using the Frappe API
- schema://{doctype}: Schema information for a DocType
- schema://{doctype}/{fieldname}/options: Available options for a Link or Select field
- schema://modules: List of all modules in the system
- schema://doctypes: List of all DocTypes in the system
The server provides comprehensive usage information by combining three sources:
- Frappe Metadata: Schema information retrieved directly from the Frappe API
- Static Hints: Supplementary context stored in JSON files within thestatic_hints/directory
- Custom App Introspection: Usage instructions provided directly by custom Frappe apps
This enhancement enables AI assistants to better understand Frappe modules, making them more effective at assisting users with Frappe-based applications.
For more details, seeUsage Information Enhancement.
// Example of using the create_document tool const result = await useToolWithMcp("frappe", "create_document", { doctype: "Customer", values: { customer_name: "John Doe", customer_type: "Individual", customer_group: "All Customer Groups", territory: "All Territories", }, });
// Example of using the get_document tool const customer = await useToolWithMcp("frappe", "get_document", { doctype: "Customer", name: "CUST-00001", fields: ["customer_name", "customer_type", "email_id"], // Optional: specific fields });
// Example of using the list_documents tool with filters const customers = await useToolWithMcp("frappe", "list_documents", { doctype: "Customer", filters: { customer_type: "Individual", territory: "United States", }, fields: ["name", "customer_name", "email_id"], limit: 10, order_by: "creation desc", });
// Example of using the find_doctypes tool const salesDocTypes = await useToolWithMcp("frappe", "find_doctypes", { search_term: "Sales", module: "Selling", is_table: false, });
// Example of using the get_required_fields tool const requiredFields = await useToolWithMcp("frappe", "get_required_fields", { doctype: "Sales Order", });
// Example of using the get_api_instructions tool const instructions = await useToolWithMcp("frappe", "get_api_instructions", { category: "DOCUMENT_OPERATIONS", operation: "CREATE", });
// Example of using the get_frappe_usage_info tool const salesOrderInfo = await useToolWithMcp("frappe", "get_frappe_usage_info", { doctype: "Sales Order", }); // Example of getting workflow information const workflowInfo = await useToolWithMcp("frappe", "get_frappe_usage_info", { workflow: "Quote to Sales Order Conversion", });
The server provides detailed error messages with context to help diagnose issues:
- Missing required parameters
- Invalid field values
- Permission errors
- Network issues
- Server errors
- A descriptive message
- HTTP status code (when applicable)
- Endpoint information
- Additional details from the Frappe server
-
Check DocType Schema First: Before creating or updating documents, get the schema to understand required fields and validations.
Use Pagination: When listing documents, uselimitandlimit_startparameters to paginate results.
Specify Fields: Only request the fields you need to improve performance.
Validate Before Creating: Useget_required_fieldsto ensure you have all required fields before creating a document.
Check Existence: Usecheck_document_existsbefore updating or deleting to ensure the document exists.
This is a web browser that enables your coding agent, such as Claude Code, to visit websites on your behalf and assist you in identifying bugs or creating UI test cases.
This server enables AI assistants and other MCP clients to interact with Directus instances programmatically.
Hosted MCP server and coordination layer for AI coding agents — live API contracts, database schema, frontend/backend mismatch detection, and shared handoff tickets for Claude Code, Cursor, Codex, and Lovable.
A FastAPI microservice for health-related operations, featuring JWT authentication and a PostgreSQL database with Alembic migrations.
Kamy renders invoices, receipts, contracts, and 5 more production-grade templates with a single REST call or TypeScript SDK method. No headless browser. No DevOps.
A GraphQL server that supports the Model Context Protocol (MCP), enabling Large Language Models (LLMs) to interact with GraphQL APIs through schema introspection and query execution.
Interact with MediaWiki installations through the MediaWiki API as a bot user.
Interact with Gibson projects to create/update projects, explain database/API interactions, and write code within your IDE.
Interact with Odoo instances using the XML-RPC API. Requires configuration via environment variables or config files.
Hosted MCP server for live sports data — scores, analytics, schedules, standings, multi-book odds, team form, head-to-head, model predictions, and pre-generated matchup analysis across 1,000+ leagues in 150+ countries. Free tier, no card.
Integrate with the Codehooks.io serverless backend platform.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.





