Odoo MCP 服务器 | PlugMCP
跳到正文 Odoo MCP Server
A standalone Model Context Protocol (MCP) server for Odoo, providing Claude with safe, human-approved access to Odoo CRM, projects, and other business domains.
Overview
This MCP server exposes Odoo as a set of modular, domain-specific tools that Claude can safely call:
Open-source MCP server which connects your Clawd/Claude to Odoo in a clean and safe way
把任意工具接入任意智能体。面向非开发者的 MCP 服务器目录;网关承载流量,n8n 承载应用。
产品
目录
开发者
公司
Sales & Pre-Sales — CRM pipeline, leads, contacts, solution design
Project Delivery — Fixed-scope projects, tasks, milestones
Domain-extensible — Easy to add support for other Odoo apps (Support, Finance, Knowledge, ERP Implementation, etc.)All write operations are safety-checked to prevent accidental outbound communication (emails, SMS, calendar invites). Internal-only notes, activities, and field updates are safe by design.
Disclaimer
This project is an independent, community-maintained MCP server and is not affiliated with, endorsed by, or sponsored by Odoo S.A.
Odoo is a trademark of Odoo S.A. Any product names, logos, and brands are used for identification only.
You are responsible for validating security, compliance, and access controls before using this server in production environments.
Always test write-enabled workflows in a non-production environment first.
Key Features
✅ Safety-first : Outbound communication blocker prevents emails, SMS, and invites
✅ Human-in-the-loop : Write operations require explicit staged approval and runtime gates
✅ Multi-company : Supports Odoo's multi-company architecture
✅ Per-user credential boundary : Odoo credentials are selected for one user/profile and kept out of prompts and tool arguments
✅ Version-aware Odoo transport : XML-RPC for Odoo 18 and below; JSON-2 for Odoo 19 and above
✅ Fully typed : Pydantic validation on all tool inputs
✅ Easy deployment : Single pip install entry point
Installation
Via pip pip install odoo-mcp-server
Via uv (fast Python installer) uvx --from https://github.com/elewa-git/odoo-mcp-server odoo-mcp-server
Setup The primary organisation path is Claude Cowork through a reachable, OpenCrane-managed remote MCP connector with per-user OAuth and per-user Odoo credential custody. The secondary path is local stdio, which remains local-first and needs no hosted relay. A plugin repository is not remote hosting.
See setup.md for the current setup, onboarding, transport, rotation, and fail-closed availability rules.
Hosted MCP Server Warning Do not expose a shared MCP process that can select or read arbitrary users' Odoo tokens. A remote deployment is acceptable only when OpenCrane authenticates each user, binds profile selection and credential release to that identity, and fails closed when the adapter or qualification is unavailable.
Tools
Generic Odoo Tools
odoo_ping — Validate connectivity and show your profile
odoo_search_read — Find records with flexible filters
odoo_read_records — Read specific records by ID
odoo_log_internal_note — Add internal chatter notes directly (safe)
odoo_schedule_activity — Build staged payload for an internal reminder activity
odoo_fields_get — Introspect model field definitions
odoo_search_count — Count records matching a filter
odoo_diagnose_call — Diagnose planned model calls without executing them
odoo_preview_write — Build a canonical non-executing mutation payload
odoo_validate_write — Validate payload against SafetyGuard and live metadata (when applicable)
odoo_execute_approved_write — Execute only with token + confirm + env gate
odoo_setup_credentials — Start or inspect secure credential onboarding
odoo_check_for_update — Check latest GitHub release/tag and suggest update command
odoo_apply_self_update — Apply local package update (guarded by explicit confirm + env gate)
Write Approval Flow All mutating operations follow a strict staged approval flow, except internal notes.
Internal notes are the only direct mutation endpoint.
Builds a canonical draft payload (model, operation, record_ids, values, method, args, kwargs)
Does not validate against live Odoo metadata
Does not execute anything
Applies SafetyGuard policy checks
Validates payload fields against live fields_get metadata for create/write
Issues a short-lived, single-use approval_token
The client presents the validated operation for approval before any execution step
The validated payload must be accepted by the user as-is
odoo_execute_approved_write
Requires confirm=true
Requires the exact validated payload alongside the approval token
Requires a valid unused token from step 2
Requires ODOO_MCP_ENABLE_WRITES=1
Executes only the validated operation (create, write, or call)
Missing confirmation, invalid/expired token, or disabled runtime write gate blocks execution.
Tokens are single-use and payload-bound; replay and drift attempts are rejected.
MCP Self-Update Flow (Optional) The MCP can suggest and apply its own update locally, but this is gated by default.
Read-only update check against GitHub releases/tags
Returns current version, latest version, and a suggested upgrade command
Requires confirm=true
Requires ODOO_MCP_ENABLE_SELF_UPDATE=1
Runs a local pip upgrade from the selected git ref/tag
After successful self-update, restart the MCP host/client so the new package is loaded.
Sales & Pre-Sales Tools
odoo_search_opportunities — Find CRM deals with flexible filters
odoo_get_opportunity — Get full deal context (chatter, activities, all fields)
odoo_propose_stage_change — Build staged payload to move deals to another stage
odoo_propose_log_note — Add internal notes to deals directly (safe)
odoo_propose_activity — Build staged payload for a follow-up activity
odoo_propose_field_update — Build staged payload for allowed field updates
odoo_search_contacts — Find contacts/companies
odoo_get_pipeline_summary — See pipeline health: deal counts, total revenue by stage
Project Delivery Tools
odoo_search_projects — Find projects by name, client, status, staleness
odoo_get_project — Get full project context (tasks grouped by stage)
odoo_search_tasks — Find overdue, stale, and at-risk tasks
(Future: task updates, notes, activities — not yet implemented)
MCP Resources
odoo://models/{database} — List models in an explicitly selected database
odoo://model/{model_name} — Introspect a specific model's fields and metadata
Safety Guarantees The SafetyGuard in src/mcp/odoo/utils/safety.py enforces blocklists defined in src/mcp/odoo/utils/safety_blocked_methods.py:
❌ All email/SMS sending models: mail.mail, sms.sms, mailing lists
❌ Direct email methods: action_send_mail, action_quotation_send, send_mail, etc.
❌ message_post with external message types (comment, email, notification)
❌ Calendar events with attendees (would send invites)
❌ Any method that subscribes followers or changes notification routing
✅ Safe operations allowed :
Field updates on CRM leads, projects, contacts, etc.
Internal chatter notes using message_type='note' (Odoo 18) or message_type='comment' + subtype_id=2 (Odoo 19)
Activity creation (internal reminders, never external)
Record creation and searches (read-only)
Architecture ┌─────────────────────────────────────────────────────────────────────┐
│ MCP Client │
│ (ClawdBot, Claude Desktop or Terminal) │
└────────────────────────────┬────────────────────────────────────────┘
│ stdio
▼
┌────────────────────────────────────────────────────────────────────┐
│ Odoo MCP Server │
│ (MCPServer + Domain Tool Modules + SafetyGuard) │
│ │
│ ┌──────────────────────────────────────────────────────────────┐ │
│ │ Generic Tools (search, read, diagnostics, staged writes, etc.)│ │
│ └──────────────────────────────────────────────────────────────┘ │
│ ┌──────────────────────────────────────────────────────────────┐ │
│ │ Domain Tool Modules │ │
│ │ • sales.py (8 CRM tools) │ │
│ │ • projects.py (6 project tools) │ │
│ │ • (others: support, finance, erp, knowledge — future) │ │
│ └──────────────────────────────────────────────────────────────┘ │
│ ┌──────────────────────────────────────────────────────────────┐ │
│ │ OdooClient + SafetyGuard │ │
│ │ • XML-RPC (Odoo <=18) or JSON-2 (Odoo >=19) │ │
│ │ • Profile-bound credential custody │ │
│ │ • Safety validation before all writes │ │
│ └──────────────────────────────────────────────────────────────┘ │
└────────────────────────────┬───────────────────────────────────────┘
│ Version-aware Odoo transport
▼
┌─────────────────────────────────────────────────────────────────────┐
│ Odoo Instance │
│ (https://my.odoo.com or your custom URL) │
└─────────────────────────────────────────────────────────────────────┘
Testing # Install dev dependencies
pip install -e ".[dev]"
# Run safety tests (CRITICAL — always run these)
pytest src/mcp/odoo/tests/test_safety.py -v
# Run all tests
pytest tests/ src/mcp/odoo/tests/ -v
Development
Project Structure src/
core/
credentials.py ← Per-user credential management
mcp/
odoo/
server.py ← Main MCP server & generic tools
utils/
client.py ← Async Odoo XML-RPC client
safety.py ← SafetyGuard: outbound blocker
tools/
sales.py ← CRM domain tools (8 tools)
projects.py ← Project management tools (6 tools)
_shared.py ← Shared types (ResponseFormat enum)
tests/
test_safety.py ← Safety validation tests (critical!)
tests/ ← Integration tests (future)
pyproject.toml ← Package config
README.md ← This file
Adding a New Domain Tool Module
Create src/mcp/odoo/tools/my_domain.py:
def register(mcp: MCPServer, get_odoo: Any) -> None:
"""Register my domain tools on the shared MCP server."""
@mcp.tool(name="odoo_my_tool", ...)
async def my_tool(input: MyInput, ctx: Context) -> str:
odoo = get_odoo(ctx)
if isinstance(odoo, str):
return odoo
# Your implementation here
return result
Import and register in src/mcp/odoo/server.py:
from src.mcp.odoo.tools import my_domain
my_domain.register(mcp, _odoo)
Add tests in src/mcp/odoo/tests/.
Safety Validation All writes go through staged validation and execution gates. Never bypass this — these layers prevent accidental outbound communication:
Code layer (SafetyGuard) — blocks dangerous models/methods
Validation layer (odoo_validate_write) — enforces live schema checks and token issuance
Human layer (approved client interaction) — explicit user approval before execution
Execution gates (odoo_execute_approved_write) — requires confirm=true, valid token, and runtime env gate
Odoo layer — Odoo's own permissions
Limitations & Roadmap
Current (v0.1)
✅ CRM pipeline (leads, opportunities, contacts)
✅ Project delivery (projects, tasks)
✅ Generic Odoo tools (search, read, diagnostics, staged write flow)
✅ Internal notes & activities (safe only)
Planned (v0.2+)
🔜 Support & Retainers (helpdesk tickets, SLAs)
🔜 Finance & Admin (invoices, payments — read-only)
🔜 Knowledge & Context (articles, workspaces)
🔜 ERP Implementation (hour-based packages, Odoo config)
🔜 Orchestration pipelines (daily reports, approval flow, debriefs)
Troubleshooting
"Credentials not found" Use the secure local loopback/CLI onboarding flow, or the OpenCrane profile onboarding flow for Cowork.
For local stdio, ask Claude to create an Odoo connection. It returns a local browser
form for credential entry and can check completion before running odoo_ping.
Existing databases are retained; use odoo_list_databases and odoo_switch_database
to select among them. odoo-mcp-onboard remains a terminal fallback. Both flows
save validated credentials in the owner-only local file. For Cowork, credentials
must remain in the selected user's OpenCrane-backed custody. Do not paste an API
key into chat to repair either path.
"Odoo authentication failed"
Odoo URL (must include https://)
Database name (case-sensitive)
Email matches your Odoo login
API key is valid (generate new one in Odoo Settings > Users > API Keys)
"SafetyViolation: BLOCKED" This is intentional! The tool attempted an operation that could send external communication. If you believe this is a false positive, please file an issue. Do NOT disable SafetyGuard.
Contributing Contributions welcome! Please:
Add tests for new tools (especially safety tests)
Update docs and examples
Run pytest src/mcp/odoo/tests/test_safety.py before submitting PRs
Follow Pydantic & type annotation patterns
License
Support For questions, issues, or feature requests:
Graphify Turn any codebase, with its docs, SQL schemas, configs, and PDFs, into a queryable knowledge graph. A /graphify skill for Claude Code, Cursor, Codex, and Gemini CLI: local deterministic AST parsing, e Agent Skills Production-grade engineering skills for AI coding agents. Impeccable The design vocabulary for your coding agent. Steer with polish and bolder, review with critique and audit, catch AI slop before it ships. Gemini Cli An open-source AI agent that brings the power of Gemini directly into your terminal. Archify Turn any idea, plan, or codebase into a beautiful interactive diagram. An agent skill for Claude Code, Codex, and more. Filesystem Read, write, search and move files in the directories you allow. The reference filesystem server from the Model Context Protocol project. Everything A test server that exercises every MCP feature: tools, resources, prompts, sampling and notifications. For client builders, from the Model Context Protocol project. Git Read and change local Git repositories: status, diffs, log, commits, branches and checkout. The reference server from the Model Context Protocol project. Chrome Devtools Chrome DevTools for coding agents Open Code Review Secure, fast, efficient, battle-tested at Alibaba's scale. Hybrid architecture code review tool: deterministic pipelines + LLM Agent, precise line-level comments, built-in multi-language ruleset (NPE, Codebase Memory Local code intelligence for developers and AI agents. Connect code, docs and infrastructure in a persistent graph, with CBM Lens, MCP tools, agent integrations and change-aware test selection. Codebase Memory Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens. Developer tools MCP 服务器 最佳 Developer tools MCP 服务器 azure-aigateway Configure Azure API Management as an AI Gateway for AI models, MCP tools, and agents. WHEN: semantic caching, token limit, content safety, load balancing, AI model governance, MCP rate limiting, jailb supabase Use when doing ANY task involving Supabase. Triggers: Supabase products (Database, Auth, Edge Functions, Realtime, Storage, Vectors, Cron, Queues); client libraries and SSR integrations (supabase-js,
暂无工具列表。远程服务器在首次健康检查后会获得工具列表。
如何安装 Odoo? 在本页复制适用于 Cursor、Claude Desktop、Claude Code 或 VS Code 的 stdio 配置。它使用发布者的安装方式,而不是 PlugMCP 代理。
Odoo 需要 API 密钥吗? 此记录未列出必需的环境变量。
Odoo 使用哪种传输方式? Odoo 通过 stdio 在本地运行。
Odoo 上次检查是什么时候? 上次检查时间:2026-10-28。 Open-source MCP server which connects your Clawd/Claude to Odoo in a clean and safe way
工具
0 / 10