mcpField
E
Enterich

Enterich

Local
github.comFinance0Updated 1d ago

About Enterich

Enterich is an MCP server for ERPNext accounting, using external OAuth and the permissions of a dedicated ERPNext user. Its fixed, read/write-separated tools can create or update drafts, but people submit documents in ERPNext.

Key features

  1. 01Fixed set of accounting tools
  2. 02Separate read and write operations
  3. 03Create and update drafts only
  4. 04Bound by the ERPNext agent user's rights
  5. 05Validate tokens through external authorization

Use cases

  1. 01Look up invoices, accounts, and bank records
  2. 02Generate receivables, payables, and ledger reports
  3. 03Prepare accounting drafts for human review

MCP support

Enterich exposes fixed ERPNext accounting tools to MCP clients over Streamable HTTP. It implements protected-resource authorization and validates each access token.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"dev-interlusion-enterich": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"ENTERICH_RESOURCE_URL",
"-e",
"ENTERICH_ISSUER",
"-e",
"ENTERICH_JWKS_URL",
"-e",
"ENTERICH_CLIENT_ID",
"-e",
"ENTERICH_SUBJECT",
"-e",
"ENTERICH_REQUIRED_SCOPES",
"-e",
"ENTERICH_TOKEN_ALGORITHMS",
"-e",
"ENTERICH_CLOCK_LEEWAY",
"-e",
"ENTERICH_ERPNEXT_URL",
"-e",
"ENTERICH_ERPNEXT_HOST",
"-e",
"ENTERICH_ERPNEXT_PUBLIC_URL",
"-e",
"ENTERICH_ERPNEXT_API_KEY",
"-e",
"ENTERICH_ERPNEXT_API_SECRET",
"-e",
"ENTERICH_COMPANY",
"-e",
"ENTERICH_TOOLS",
"-e",
"ENTERICH_MAX_DRAFTS_PER_HOUR",
"-e",
"ENTERICH_TIMEZONE",
"-e",
"ENTERICH_HOST",
"-e",
"ENTERICH_PORT",
"-e",
"ENTERICH_LOG_LEVEL",
"ghcr.io/interlusion/enterich:0.5.0"
],
"env": {
"ENTERICH_RESOURCE_URL": "<ENTERICH_RESOURCE_URL>",
"ENTERICH_ISSUER": "<ENTERICH_ISSUER>",
"ENTERICH_JWKS_URL": "<ENTERICH_JWKS_URL>",
"ENTERICH_CLIENT_ID": "<ENTERICH_CLIENT_ID>",
"ENTERICH_SUBJECT": "<ENTERICH_SUBJECT>",
"ENTERICH_REQUIRED_SCOPES": "<ENTERICH_REQUIRED_SCOPES>",
"ENTERICH_TOKEN_ALGORITHMS": "<ENTERICH_TOKEN_ALGORITHMS>",
"ENTERICH_CLOCK_LEEWAY": "<ENTERICH_CLOCK_LEEWAY>",
"ENTERICH_ERPNEXT_URL": "<ENTERICH_ERPNEXT_URL>",
"ENTERICH_ERPNEXT_HOST": "<ENTERICH_ERPNEXT_HOST>",
"ENTERICH_ERPNEXT_PUBLIC_URL": "<ENTERICH_ERPNEXT_PUBLIC_URL>",
"ENTERICH_ERPNEXT_API_KEY": "<ENTERICH_ERPNEXT_API_KEY>",
"ENTERICH_ERPNEXT_API_SECRET": "<ENTERICH_ERPNEXT_API_SECRET>",
"ENTERICH_COMPANY": "<ENTERICH_COMPANY>",
"ENTERICH_TOOLS": "<ENTERICH_TOOLS>",
"ENTERICH_MAX_DRAFTS_PER_HOUR": "<ENTERICH_MAX_DRAFTS_PER_HOUR>",
"ENTERICH_TIMEZONE": "<ENTERICH_TIMEZONE>",
"ENTERICH_HOST": "<ENTERICH_HOST>",
"ENTERICH_PORT": "<ENTERICH_PORT>",
"ENTERICH_LOG_LEVEL": "<ENTERICH_LOG_LEVEL>"
}
}
}
}
Run commanddocker run -i --rm -e ENTERICH_RESOURCE_URL -e ENTERICH_ISSUER -e ENTERICH_JWKS_URL -e ENTERICH_CLIENT_ID -e ENTERICH_SUBJECT -e ENTERICH_REQUIRED_SCOPES -e ENTERICH_TOKEN_ALGORITHMS -e ENTERICH_CLOCK_LEEWAY -e ENTERICH_ERPNEXT_URL -e ENTERICH_ERPNEXT_HOST -e ENTERICH_ERPNEXT_PUBLIC_URL -e ENTERICH_ERPNEXT_API_KEY -e ENTERICH_ERPNEXT_API_SECRET -e ENTERICH_COMPANY -e ENTERICH_TOOLS -e ENTERICH_MAX_DRAFTS_PER_HOUR -e ENTERICH_TIMEZONE -e ENTERICH_HOST -e ENTERICH_PORT -e ENTERICH_LOG_LEVEL ghcr.io/interlusion/enterich:0.5.0
Environment variables to set
ENTERICH_RESOURCE_URLThe MCP endpoint exactly as clients enter it, https; its path is the one served
ENTERICH_ISSUERThe authorization server's issuer, https
ENTERICH_JWKS_URLThe authorization server's signing keys, https
ENTERICH_CLIENT_IDThe OAuth client the agent's tokens are issued to
ENTERICH_SUBJECTThe agent identity's sub
ENTERICH_REQUIRED_SCOPESScopes required in the token, space-separated
ENTERICH_TOKEN_ALGORITHMSSecretToken signing algorithms accepted, comma-separated
ENTERICH_CLOCK_LEEWAYSeconds of clock leeway for token times, 0 to 60
ENTERICH_ERPNEXT_URLThe base URL Enterich calls ERPNext at
ENTERICH_ERPNEXT_HOSTThe Host header sent to ERPNext, by default the URL's host
ENTERICH_ERPNEXT_PUBLIC_URLThe base URL people open ERPNext at, for links in results
ENTERICH_ERPNEXT_API_KEYSecretThe ERPNext agent user's API key
ENTERICH_ERPNEXT_API_SECRETSecretThe ERPNext agent user's API secret
ENTERICH_COMPANYThe assigned company, exactly as named in ERPNext
ENTERICH_TOOLSThe operations to offer, comma-separated; by default all
ENTERICH_MAX_DRAFTS_PER_HOURMost drafts of each type the agent may create in an hour; unset, no limit
ENTERICH_TIMEZONEIANA time zone for today's date, the ERPNext site's
ENTERICH_HOSTThe listen address
ENTERICH_PORTThe listen port
ENTERICH_LOG_LEVELThe level for libraries' log lines: DEBUG, INFO, WARNING or ERROR

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
ocighcr.io/interlusion/enterich:0.5.0

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Enterich's logo: a drake in a cap, holding a microphone, with an MCP chain

Enterich

An MCP server for ERPNext with hard limits: a short, fixed list of tools, tokens from an external OAuth authorization server, and only the rights of one ERPNext user.

Status: Every operation is tested against a model of ERPNext v16's API, and weekly against a real ERPNext v16 site. The changelog lists the releases.

What it is

  • A separate service, not a Frappe app. It calls ERPNext's REST API with the API key of a dedicated agent user and holds no other ERPNext credential. Whatever the service does, ERPNext's role for that user is the upper limit.
  • A resource server for the MCP authorization spec. It serves the protected resource metadata, answers a missing token with 401, and checks every access token itself (issuer, audience, client, subject). Sign-in happens at an external authorization server such as Keycloak.
  • A fixed list of operations, each with its own purpose and input schema, read and write separated. No generic document access, method calls or file access.
  • Client-neutral. It speaks plain MCP (Streamable HTTP) and doesn't rely on any client asking before a write.

What it is not

  • Not a general ERPNext API bridge: tools that take a DocType, report name, method name, field list, filter expression or file path as input are out of scope.
  • Not a way to post: no tool submits, cancels, amends, deletes or discards a document. The agent prepares drafts; a person reviews and submits them in ERPNext (reviewing drafts).
  • Not affiliated with or endorsed by Frappe Technologies. ERPNext and Frappe are their trademarks.

Tools

Enterich offers 37 tools. A deployment may offer fewer (ENTERICH_TOOLS); every tool works on one company, within the rights ERPNext gives the agent user.

Master data (REQ-003)

Items.

ToolTitleKind
list_itemsList itemsread
get_itemGet itemread
Order to cash (REQ-004)

Customers, sales invoices, receivables.

ToolTitleKind
list_customersList customersread
get_customerGet customerread
list_sales_invoicesList sales invoicesread
get_sales_invoiceGet sales invoiceread
list_sales_tax_templatesList sales tax templatesread
report_accounts_receivableAccounts receivableread
create_draft_sales_invoiceCreate draft sales invoicecreate draft
update_draft_sales_invoiceUpdate draft sales invoiceupdate draft
create_draft_sales_returnCreate draft sales returncreate draft
update_draft_sales_returnUpdate draft sales returnupdate draft
Procure to pay (REQ-005)

Suppliers, purchase invoices, payables.

ToolTitleKind
list_suppliersList suppliersread
get_supplierGet supplierread
list_purchase_invoicesList purchase invoicesread
get_purchase_invoiceGet purchase invoiceread
list_purchase_tax_templatesList purchase tax templatesread
report_accounts_payableAccounts payableread
create_draft_purchase_invoiceCreate draft purchase invoicecreate draft
update_draft_purchase_invoiceUpdate draft purchase invoiceupdate draft
create_draft_purchase_returnCreate draft purchase returncreate draft
update_draft_purchase_returnUpdate draft purchase returnupdate draft
Record to report (REQ-006)

Accounts, cost centres, journal entries, ledger, trial balance.

ToolTitleKind
list_accountsList accountsread
list_cost_centersList cost centresread
list_journal_entriesList journal entriesread
get_journal_entryGet journal entryread
report_general_ledgerGeneral ledgerread
report_trial_balanceTrial balanceread
create_draft_journal_entryCreate draft journal entrycreate draft
update_draft_journal_entryUpdate draft journal entryupdate draft
Bank and cash (REQ-007)

Bank accounts, bank transactions, payments.

ToolTitleKind
list_bank_accountsList bank accountsread
list_bank_transactionsList bank transactionsread
get_bank_transactionGet bank transactionread
list_payment_entriesList payment entriesread
get_payment_entryGet payment entryread
create_draft_payment_entryCreate draft payment entrycreate draft
update_draft_payment_entryUpdate draft payment entryupdate draft

Scope

Enterich is maintained for our own use. Contributions are welcome (contributing); support isn't promised. Report vulnerabilities privately, as the security policy describes.

Documentation

Start at docs/README.md. The most important parts:

Licence

Apache-2.0. Why: ADR-006.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.