Skip to main content
Glama

Frappe MCP

A permission-aware Model Context Protocol (MCP) server for Frappe Framework sites. It discovers apps, DocTypes, fields, records, reports, workflows, workspaces, print formats, files, and translations at runtime. It also supports guarded document operations and portable app customizations.

The server is installed as a Frappe app and serves MCP over authenticated Streamable HTTP. Its tools operate through the active Frappe session and native Frappe APIs. It is designed for Frappe Framework, ERPNext, HRMS, and other installed apps without maintaining app-specific DocType catalogs.

Status: The current release has been exercised against Frappe 15.96.0, ERPNext 15.96.1, and HRMS 15.60.0. See compatibility and validation. Support for other versions should be verified in a dedicated test site.

What it can do

  • Discover installed apps, modules, permission-visible DocTypes, and readable schemas.

  • Read documents and child tables under Frappe document and field permissions.

  • Create, update, delete, submit, cancel, or apply workflows with preview and explicit confirmation.

  • Create standard DocTypes, Custom Fields, Property Setters, Client Scripts, and role permission rules using native Frappe controllers.

  • Export selected standard DocTypes and customization records to an installed app as JSON and fixtures, with a preview, backup manifest, and rollback operation.

  • Discover and run permitted reports; inspect workspaces, print formats, files, and translations.

  • Invoke explicitly named Frappe-whitelisted methods after preview and confirmation.

There is no arbitrary SQL or Python execution tool. Authorization remains the responsibility of Frappe roles, document permissions, field permissions, report roles, and the authenticated user.

Related MCP server: Frappe MCP Server

Requirements

  • A Frappe Bench and site with a supported Frappe installation.

  • Python 3.10 or later for the package metadata. Use the Python runtime managed by the target Bench when installing the app.

  • Network access from the MCP client to the Frappe site.

  • A dedicated Frappe user with only the roles needed for the intended tools. Schema customization and export tools require System Manager.

Install in a Bench

Run these commands from the Bench directory. Use a development or staging site first; do not install an unreviewed integration on a production site.

bench get-app https://github.com/<OWNER>/mcp-frappe.git
bench --site <site-name> install-app mcp_frappe
bench restart

The repository URL above is a placeholder until the project is published. If you already have a local checkout, make it available as apps/mcp_frappe in the Bench and install it on the target site.

The MCP endpoint is:

https://<frappe-host>/api/method/mcp_frappe.mcp.handle_mcp

Frappe token authentication uses this HTTP header:

Authorization: token <api_key>:<api_secret>

Do not enable Guest access for this endpoint. Use HTTPS outside a trusted local environment. Store credentials in the MCP client's secret store or environment, never in a checked-in config file.

Connect an MCP client

Configure an MCP client that supports Streamable HTTP and custom HTTP headers. For clients with a JSON configuration format, the conceptual configuration is:

{
  "mcpServers": {
    "frappe": {
      "url": "https://<frappe-host>/api/method/mcp_frappe.mcp.handle_mcp",
      "headers": {
        "Authorization": "token ${FRAPPE_API_KEY}:${FRAPPE_API_SECRET}"
      }
    }
  }
}

Client configuration formats and environment-variable expansion vary. Confirm that your client supports Streamable HTTP and custom headers; do not assume the example's variable interpolation works in every client. Create an API key for a dedicated Frappe user and make the secret available to the client using its documented secret mechanism.

First-use workflow

An AI agent should discover the site instead of assuming installed apps or DocTypes:

  1. Call list_installed_apps.

  2. Call list_doctypes for the relevant app/module.

  3. Call get_doctype_schema before constructing filters or write payloads.

  4. Read records with list_documents or get_document; request only the fields needed.

  5. For writes, call the tool with confirm: false (the default), inspect the returned preview, then repeat with confirm: true.

  6. For update/delete/submit/cancel/workflow actions, pass the exact expected_modified returned by the latest preview.

  7. Verify the result with a fresh read.

See AI agent guide for detailed instructions and examples, and tool reference for every tool and argument.

Documentation

Development and validation

Read development guide before contributing. It describes the package layout, local Bench workflow, and automated test commands. Real HTTP acceptance evidence from the isolated prueba.localhost site is summarized in the validation report; its raw JSONL evidence and runner are under e2e/.

License

This project is released under the MIT License. The vendored transport retains its upstream copyright and license notices; see UPSTREAM.md and THIRD_PARTY_LICENSES-frappe-mcp.txt.

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Enables interaction with Frappe Framework sites through comprehensive document operations, schema introspection, report generation, and method execution. Provides secure API-based access to create, read, update, and delete Frappe documents while supporting financial reporting and DocType management.
    24
    16
    ISC
  • A
    license
    Not graded
    quality
    D
    maintenance
    Allows AI assistants to interact with Frappe applications through the official REST API, enabling document CRUD operations, schema handling, and detailed API instructions.
    510 npm
    2
    ISC
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI models to securely interact with Frappe Framework/ERPNext instances, supporting document CRUD, RPC methods, file management, workflows, reporting, and more via the Model Context Protocol.
    510 npm
    ISC
  • A
    license
    Not graded
    quality
    D
    maintenance
    Integrates with ERPNext/Frappe API to enable AI assistants to interact with ERPNext data and create custom applications including DocTypes, workflows, scripts, and more.
    MIT