
Mcp Odoo
io.github.erpipe-org由 GitHub 帳號 erpipe-org 發布v1.3.0更新於 Oct 24, 2026
Odoo MCP: gated writes, multi-instance. Free hosted: ERPipe (mcp.erpipe.com)
概覽
讓助理透過 XML-RPC 或 JSON-2 讀取、診斷 Odoo 16+ 資料庫,並在明確的審批閘門下寫入資料。
- 可以做什麼
- 提供 41 個 Odoo 工具:列出模型與欄位、有界範圍的記錄搜尋與讀取、伺服器端彙總、附件讀取、結構目錄與網域建構。另含診斷、移轉輔助、本機外掛原始碼掃描、對已索引記錄的本機 BM25 知識檢索、應收應付帳齡與會計摘要、背景唯讀任務,以及跨多個已設定執行個體的唯讀彙整。寫入須先預覽、依即時欄位中介資料驗證,再憑審批權杖執行。
- 適用情境
- 適合讓助理不必手寫指令碼就能取得真實 Odoo 脈絡,用於查詢、報表、診斷或移轉規劃,並希望寫入保留人工審批步驟。也適合合作夥伴或代理機構用一個伺服器查詢多個客戶資料庫。
- 執行需求
- 以 PyPI 套件 odoo-mcp 在本機透過 stdio 執行(uvx、pip、pipx 或 Docker),需要 Python 執行環境。需以環境變數或設定檔提供 ODOO_URL、ODOO_DB、ODOO_USERNAME 與 ODOO_PASSWORD(密碼或 API 金鑰),並能連線至 Odoo 伺服器。除非設定 ODOO_MCP_ENABLE_WRITES,否則寫入維持關閉。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Mcp Odoo,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Odoo MCP
ERPipe is the managed Odoo MCP gateway from the maintainer of erpipe-org/mcp-odoo, formerly tuanle96/mcp-odoo; the Python project remains the self-hosted server.
The free AI layer for Odoo — any edition, any version.
Odoo's built-in AI is Enterprise-only. Odoo MCP gives Community and Enterprise 16+ the same power for $0 with the LLM you already use (Claude, GPT, Gemini, DeepSeek, Ollama).
Five-minute install. Zero Odoo-side setup. Safe writes, real diagnostics, JSON-2 ready years before the Odoo 22 XML-RPC removal.
[PyPI] [Python] [Downloads] [License] [CI] [Stars] [Forks] [Agent Skills]
🚀 ERPipe hosted — free v1 · live at erpipe.com · TypeScript open core · 🔍 Fixed-price audits
Want ChatGPT / Claude on a stable remote URL without running a process?
ERPipe is the hosted product from the same author — free v1 public beta, live in production.
Sign up → add HTTPS Odoo instance(s) → connect once tohttps://mcp.erpipe.com/mcp(workspace OAuth, multi-instance, gated writes, audit dashboard).
This repo stays the local / self-host Python server (full 41-tool surface, stdio, Docker). TypeScript building blocks:erpipe.
Odoo MCP turns any Odoo 16+ database into a Model Context Protocol server — using only your existing credentials. No App Store module, no permission setup, no admin access required. Built for local agents, IDEs, and automation tools that need real Odoo context without hand-rolled scripts or unsafe direct write access.
It speaks XML-RPC for Odoo 16-18 and External JSON-2 for Odoo 19+. It exposes a compact MCP surface with read tools, diagnostics, schema discovery, migration helpers, local addon scanning, and a gated write workflow. One server can serve multiple named Odoo instances at once.
Try it in 30 seconds
Once configured (see Setup), ask your agent things like:
"Show me all customers from Spain with unpaid invoices."
"Find products with stock below 10 units in the main warehouse."
"Audit the
custom_billingaddon for upgrade risks before we move to Odoo 19."
Highlights
Why Odoo MCP
Comparing specific projects? See the per-project breakdown in docs/comparison.md.
Setup
Two paths to a working server: set it up yourself, or paste one prompt and let your coding agent do it for you.
For humans
The fastest path is the interactive wizard via uvx, which fetches the package on demand:
The wizard asks for your Odoo URL, database, and credentials, tests the connection live, writes the config file, and prints ready-to-paste snippets for Claude Code, Cursor, and Claude Desktop. Prefer a quick smoke check instead? uvx odoo-mcp --health.
Using Claude Desktop on macOS? It reads MCP configuration from:
Use an absolute Python path because GUI apps may not inherit your shell PATH:
More client configs (Windsurf, VS Code, Zed, Continue.dev, Streamable HTTP) are in docs/client-configs.md.
Other ways to install:
Prefer a container? See Docker. For local development:
For AI agents
Paste this into Claude Code, Cursor, Codex, or any coding agent and it will install the server for you:
Already know your client? One-liners and config snippets:
- Claude Code
.mcp.jsonand Codex CLIconfig.toml:examples/README.md - Cursor
.cursor/mcp.json+ agent rules:examples/cursor/ - Windsurf, VS Code, Zed, Continue.dev, Cline, Streamable HTTP, Docker:
docs/client-configs.md - Machine-readable install guide for agents (Cline-style):
llms-install.md
Framework SDKs
Copy-paste-runnable integrations live in examples/:
Configuration reference
Set connection values in the environment:
For Odoo 19 JSON-2:
ODOO_JSON2_DATABASE_HEADER=1 sends X-Odoo-Database on JSON-2 calls. Set it to 0 only when host or dbfilter routing already selects the intended database.
Optional environment variables:
You can also use odoo_config.json:
Multiple Odoo instances
One server can talk to several Odoo databases. Add an instances map to your config file (auto-detected — a file without instances keeps the flat single-instance shape above):
- Every read/write tool accepts an optional
instanceparameter; omitted → thedefaultinstance.defaultitself is optional when only one instance is defined. - Each entry supports the same keys as the flat config (
url,db,username,password,api_key,transport,json2_database_header,lang) plustimeoutandverify_ssl. Instance entries are self-contained: credentials and transport never fall back to env vars (so one instance can never inherit another deployment'sODOO_API_KEY). Only non-credential knobs (ODOO_TIMEOUT,ODOO_VERIFY_SSL,ODOO_LOCALE) act as fallback defaults for entries that omit them. Env overrides likeODOO_TRANSPORT/ODOO_API_KEYstill apply to legacy flat configs, as before. ODOO_CONFIG_FILE=/path/to/config.jsonpoints at an explicit config file, checked before./odoo_config.json,~/.config/odoo/config.json, and~/.odoo_config.json.- Precedence: when
ODOO_URL/ODOO_DB/ODOO_USERNAME/ODOO_PASSWORDare all set, the environment wins and defines a single instance nameddefault— unset them to use a multi-instance file. - Instance names must match
[A-Za-z0-9_-]{1,64}. Clients connect lazily — an instance is only contacted when a tool targets it. - Discovery: the
list_instancestool returns configured names, URLs, databases, and transports — never credentials. - Write-approval tokens encode the instance name, so a token validated against one instance can never execute on another.
- MCP resources (
odoo://…) always use the default instance in this release; use tools for multi-instance access.
Run
Start the MCP server over stdio:
or:
Start Streamable HTTP for local clients:
Non-local HTTP binds are rejected unless you pass --allow-remote-http or set MCP_ALLOW_REMOTE_HTTP=1. This server does not include built-in HTTP authentication. Put remote HTTP deployments behind your own authentication, TLS, and network policy.
Check runtime posture without starting the server loop:
MCP Tools
41 tools grouped by use case. Each tool name is a single-purpose handle the agent can call. Tools that talk to Odoo accept an optional instance parameter when multiple instances are configured (see Multiple Odoo instances).
Read & Discover (11)
Write & Operate (5)
Diagnose (3)
Migrate (3)
Audit & Plan (3)
Knowledge search — local-first (3)
Accounting (2)
Background tasks (4)
Cross-instance fan-out — read-only (3)
One question across many configured instances, merged and attributed. See the partner playbook.
Utility (2)
Resources
Prompts
11 prompts: 5 diagnostic, plus 6 operational workflow prompts that encode end-to-end business processes and route every write through the approval gate.
Safe Write Model
Writes are intentionally boring.
preview_writecreates a canonical, non-executing payload.validate_writechecks model metadata, required fields, readonly fields, relation hints, record IDs, and payload shape.execute_approved_writeruns only when all gates pass:- the approval came from
validate_writein the same server process, - validation used trusted, non-empty live Odoo
fields_getmetadata, - the token has not expired or been consumed,
confirm=trueis passed,ODOO_MCP_ENABLE_WRITES=1is set.
- the approval came from
Odoo access rules, record rules, and server-side constraints still decide the final result.
Batch creates go through the same gates: pass values_list (one dict per
record, max 100) to preview_write/validate_write — execution maps to a
single atomic Odoo create(vals_list) call. Per-record differing write
values are deliberately unsupported (they would need one non-atomic RPC per
record). Optional extras: ODOO_MCP_ELICIT_WRITES=1 adds a native
human-confirmation form, ODOO_MCP_AUDIT_LOG records every write-path event.
Large binary fields (a resume attached to ir.attachment.datas, a product
image, ...) don't have to be inlined as base64 in the tool call — pass
<field>_from_path instead (e.g. datas_from_path: "/local/path/cv.pdf") to
validate_write. The server reads the file itself; the approval only ever
carries a sha256:<hex>:<size> fingerprint for that field, never the real
content, so nothing large has to round-trip through the calling agent's
context. Requires ODOO_MCP_ATTACHMENT_UPLOAD_ROOTS (fails closed otherwise)
and respects ODOO_MCP_MAX_ATTACHMENT_UPLOAD_BYTES. No new tool — this rides
the same preview_write → validate_write → execute_approved_write gate as
every other write.
Reviewed side-effect methods such as sale.order.action_confirm can be enabled
one by one:
ODOO_MCP_ALLOW_UNKNOWN_METHODS=1 is still supported for trusted deployments,
but health_check reports it as broad mode. Prefer exact allowlist entries when
you only need a small number of reviewed methods.
Docker
Use the prebuilt GHCR image:
Or build it locally:
Run over stdio from an MCP client (replace mcp/odoo:latest with ghcr.io/erpipe-org/mcp-odoo:latest to use the prebuilt image):
Run Streamable HTTP locally:
Test
Run the normal quality gates:
Run real Odoo smoke tests:
The smoke harness boots disposable Docker Compose stacks, validates direct Odoo access, validates MCP stdio, and for Odoo 19 also validates JSON-2 and Streamable HTTP.
Run the multi-instance smoke (one stack, three databases, two accounts on one instance):
Compatibility
XML-RPC remains the default transport for broad compatibility. Odoo 19 supports External JSON-2 through ODOO_TRANSPORT=json2. XML-RPC and JSON-RPC are deprecated since Odoo 19 and scheduled for removal in Odoo 22 (fall 2028), so new integrations should plan for JSON-2.
Documentation
Contributing
Issues, pull requests, and compatibility reports are welcome. Start with CONTRIBUTING.md, include your Odoo version, transport, client type, and the verification you ran.
Security
Do not publish logs that contain Odoo credentials, API keys, database names from private environments, or full Odoo debug traces. Report vulnerabilities through SECURITY.md.
License
MIT. See LICENSE.
來源:README.md,提交 76ec136
工具
0版本歷史
1- v1.3.0最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分