MCP Odoo Bridge Server
Enables interaction with Odoo data, allowing for searching, reading, counting, creating, updating, and deleting records, as well as discovering model structures and executing custom methods.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Odoo Bridge Server Find all recent sales orders for Azure Interior"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Odoo Bridge Server
Licensed under the Apache License, Version 2.0 - See LICENSE for details.
A Model Context Protocol (MCP) server that enables AI assistants like Claude to interact with Odoo data using natural language.
๐ฏ What is MCP?
The Model Context Protocol is an open standard by Anthropic that enables AI assistants to securely connect to external data sources. This server acts as a bridge between Claude (or other MCP clients) and your Odoo instance.
Learn more: MCP Documentation
Related MCP server: Odoo MCP Server
โจ Features
Feature | Description |
๐ Search Records | Find records using natural language or Odoo domain syntax |
๐ Read Records | Get detailed record information by ID |
๐ Count Records | Get counts matching criteria |
โ Create Records | Create new records (with permission) |
โ๏ธ Update Records | Modify existing records (with permission) |
๐๏ธ Delete Records | Remove records (with permission) |
๐ List Models | Discover available models |
๐ง Get Fields | Understand model structure |
โก Execute Methods | Run custom methods (if enabled) |
๐ API Key Auth | Secure authentication via API keys |
๐ Audit Logging | All operations logged for compliance |
๐ Prerequisites
Odoo instance (17.0, 18.0, or 19.0 recommended)
Python 3.10+ installed
AD Odoo MCP Bridge module installed in Odoo (see Odoo Module)
๐ Installation
1. Clone the Repository
git clone https://github.com/yourusername/ad-mcp-bridge-server.git
cd ad-mcp-bridge-server2. Install Dependencies
pip install -e .Or with uv:
uv pip install -e .3. Install the Odoo Module
Install the ad_odoo_mcp_bridge module in your Odoo instance:
Add the module folder to your Odoo addons path
Go to Apps โ Install "AD Odoo MCP Bridge"
โ๏ธ Configuration
Environment Variables
The server requires the following environment variables:
Variable | Required | Description | Example |
| Yes | Your Odoo instance URL |
|
| Yes* | API key for authentication |
|
| Yes* | Username (if not using API key) |
|
| Yes* | Password (if not using API key) |
|
| No | Database name (auto-detected if not set) |
|
| No | Default max records per query (default: |
|
| No | Request timeout in seconds (default: |
|
| No | YOLO mode - bypasses MCP security (โ ๏ธ DEV ONLY) |
|
* Authentication: You must provide either
ODOO_API_KEYor bothODOO_USERandODOO_PASSWORD.
MCP Transport Options
Variable | Required | Description | Example |
| No | Transport type: |
|
| No | Host for HTTP transport (default: |
|
| No | Port for HTTP transport (default: |
|
YOLO Mode Values
Value | Description |
| All operations require explicit MCP Bridge permissions (default) |
| Allows read-only operations on all models without configuration |
| โ ๏ธ DANGEROUS - Allows all operations including write/delete without restrictions |
โ ๏ธ Warning: YOLO mode bypasses security checks and should NEVER be used in production. It's intended only for local development and testing.
Create a .env File (Optional)
ODOO_URL=https://mycompany.odoo.com
ODOO_DB=mycompany
ODOO_API_KEY=your-api-key-here๐ Usage with Claude Desktop
Step 1: Generate API Key in Odoo
Go to MCP Bridge โ Configuration โ API Keys
Click Create โ Select user โ Generate Key
Copy the key (shown only once!)
Step 2: Configure Claude Desktop
Edit claude_desktop_config.json:
Windows: %APPDATA%\Claude\claude_desktop_config.json
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"odoo": {
"command": "python",
"args": ["-m", "ad_mcp_bridge_server"],
"cwd": "/path/to/ad-mcp-bridge-server/src",
"env": {
"ODOO_URL": "http://localhost:8069",
"ODOO_DB": "your_database",
"ODOO_API_KEY": "your-api-key"
}
}
}
}Windows Note: Use the full Python path if needed:
"command": "C:\\path\\to\\venv\\Scripts\\python.exe"
Step 3: Restart Claude Desktop
Close and reopen Claude Desktop. You should see the ๐ง Tools icon.
Step 4: Start Chatting!
Try these prompts:
"Show me all customers from the United States"
"What's the status of order SO/2024/0153?"
"Create a new lead for ABC Company"
"How many unpaid invoices do we have?"
๐ Usage with VS Code
Create .vscode/mcp.json in your workspace:
{
"servers": {
"odoo": {
"command": "python",
"args": ["-m", "ad_mcp_bridge_server"],
"cwd": "/path/to/ad-mcp-bridge-server/src",
"env": {
"ODOO_URL": "http://localhost:8069",
"ODOO_DB": "your_database",
"ODOO_API_KEY": "your-api-key"
}
}
}
}๐งช Testing with MCP Inspector
Use the official MCP debugging tool:
npx @modelcontextprotocol/inspector python -m ad_mcp_bridge_serverThis opens a web UI to test all tools interactively.
๐๏ธ Odoo Module
This MCP server requires the AD Odoo MCP Bridge module installed in Odoo.
Compatibility
Odoo Version | Status |
19.0 | โ Fully Supported |
18.0 | โ Supported |
17.0 | โ Supported |
16.0 | โ Supported |
Module Features
Model Configuration: Choose which models AI can access
Permission Control: Set read/create/update/delete per model
API Key Management: Generate and manage API keys
Audit Logging: Track all AI operations
Rate Limiting: Control request frequency
YOLO Mode: Quick access mode for development
Module Installation
Copy
ad_odoo_mcp_bridgefolder to your Odoo addons pathRestart Odoo
Go to Apps โ Remove "Apps" filter โ Search "MCP" โ Install
๐ Security
API Key Authentication: All requests require a valid API key
Permission Inheritance: AI inherits Odoo user's permissions
Audit Trail: All operations logged with IP, timestamp, and details
Rate Limiting: Configurable per-key request limits
Field Exclusions: Sensitive fields can be blocked
๐ API Endpoints (Odoo Module)
The Odoo module exposes these JSON-RPC endpoints:
Endpoint | Description |
| Health check |
| Server information |
| List enabled models |
| Get model fields |
| Search records |
| Read record by ID |
| Count records |
| Create record |
| Update record |
| Delete record |
| Execute method |
๐ ๏ธ Development
Run Locally
cd src
export ODOO_URL=http://localhost:8069
export ODOO_DB=mydb
export ODOO_API_KEY=your-key
python -m ad_mcp_bridge_serverProject Structure
ad-mcp-bridge-server/
โโโ src/
โ โโโ ad_mcp_bridge_server/
โ โโโ __init__.py
โ โโโ __main__.py # Entry point
โ โโโ config.py # Pydantic settings
โ โโโ odoo_client.py # Odoo HTTP client
โ โโโ server.py # MCP server & tools
โโโ pyproject.toml
โโโ README.md
โโโ .env.example๐ MCP Resources
๐ค Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Fork the repository
Create your feature branch (
git checkout -b feature/amazing-feature)Commit your changes (
git commit -m 'Add some amazing feature')Push to the branch (
git push origin feature/amazing-feature)Open a Pull Request
โ Support
Thank you for using this project! If you find it helpful and would like to support my work, kindly consider buying me a coffee. Your support is greatly appreciated!
And don't forget to give the project a โญ star if you like it!
๐ License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
๐ Acknowledgments
๐ About
A Model Context Protocol (MCP) server that enables AI assistants to securely interact with Odoo ERP systems through standardized resources and tools for data retrieval and manipulation.
Made with โค๏ธ for the Odoo and AI community
Available Tools
11 toolscount_recordsA
Count records matching a domain.
Args:
model: The Odoo model name
domain: Search filter as Odoo domain list
Returns:
Number of matching records
Example:
Count unpaid invoices: model='account.move', domain=[['payment_state', '!=', 'paid']]
Inputs: model (required), domain. Returns: result
create_recordA
Create a new record in Odoo.
Args:
model: The Odoo model name
values: Dictionary of field values for the new record
Returns:
Success message with the new record ID
Example:
Create customer: model='res.partner', values={'name': 'New Customer', 'email': 'new@example.com'}
Inputs: model (required), values (required). Returns: result
delete_recordB
Delete a record from Odoo.
Args:
model: The Odoo model name
record_id: The ID of the record to delete
Returns:
Success message
โ ๏ธ WARNING: This action is irreversible!
Inputs: model (required), record_id (required). Returns: result
execute_methodA
Execute a custom method on an Odoo model.
Args:
model: The Odoo model name
method: The method name to call
record_ids: Optional list of record IDs to call the method on
args: Positional arguments for the method
kwargs: Keyword arguments for the method
Returns:
Method result
โ ๏ธ Note: This requires special permission in Odoo settings.
Example:
Confirm sale order: model='sale.order', method='action_confirm', record_ids=[5]
Inputs: model (required), method (required), record_ids, args, +1 more. Returns: result
get_model_fieldsB
Get field definitions for an Odoo model.
Args:
model: The Odoo model name
field_types: Optional list of types to filter (e.g., ['many2one', 'char'])
Returns:
List of fields with their types and descriptions
Inputs: model (required), field_types. Returns: result
get_recordB
Get a specific record by ID.
Args:
model: The Odoo model name
record_id: The ID of the record to retrieve
fields: List of fields to return (empty = all accessible fields)
Returns:
JSON object with the record data
Example:
Get customer details: model='res.partner', record_id=5
Inputs: model (required), record_id (required), fields. Returns: result
get_record_nameC
Get the display name of a record (useful for looking up references).
Args:
model: The Odoo model name
record_id: The record ID
Returns:
Display name of the record
Inputs: model (required), record_id (required). Returns: result
list_modelsA
List all Odoo models available for MCP access.
Returns:
List of models with their permissions (read, create, update, delete)
Inputs: no named parameters. Returns: result
search_and_read_oneA
Search and return the first matching record (convenience method).
Args:
model: The Odoo model name
domain: Search filter as Odoo domain list
fields: List of fields to return
Returns:
The first matching record or a message if not found
Inputs: model (required), domain (required), fields. Returns: result
search_recordsA
Search for records in an Odoo model.
Args:
model: The Odoo model name (e.g., 'res.partner', 'sale.order')
domain: Search filter as Odoo domain list (e.g., [['is_company', '=', True]])
Common operators: =, !=, >, <, >=, <=, like, ilike, in, not in
fields: List of fields to return (empty = smart defaults)
limit: Maximum records to return (default 80)
offset: Number of records to skip (for pagination)
order: Sort order (e.g., 'name asc, id desc')
Returns:
JSON list of matching records
Examples:
- Find all companies: model='res.partner', domain=[['is_company', '=', True]]
- Find orders from this month: model='sale.order', domain=[['date_order', '>=', '2024-01-01']]
- Find unpaid invoices: model='account.move', domain=[['payment_state', '!=', 'paid']]
Inputs: model (required), domain, fields, limit, +2 more. Returns: result
update_recordB
Update an existing record in Odoo.
Args:
model: The Odoo model name
record_id: The ID of the record to update
values: Dictionary of field values to update
Returns:
Success message
Example:
Update customer phone: model='res.partner', record_id=5, values={'phone': '123-456-7890'}
Inputs: model (required), record_id (required), values (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogโฆ
TDQS
Scored across 11 tools
Every tool has a clearly distinct purpose with no ambiguity. Core CRUD operations (create_record, get_record, update_record, delete_record) are separate from search operations (search_records, search_and_read_one, count_records), metadata tools (list_models, get_model_fields), and specialized utilities (execute_method, get_record_name). The descriptions clearly differentiate each tool's specific function.
All tools follow a consistent verb_noun naming pattern throughout (e.g., count_records, create_record, search_records). The naming is perfectly uniform with no deviations in style or convention, making the tool set highly predictable and readable.
With 11 tools, this server is well-scoped for its purpose as an Odoo bridge. It provides comprehensive coverage of database operations (CRUD, search, count), metadata access, and specialized utilities without being overwhelming. Each tool earns its place in the set.
The tool surface provides complete CRUD/lifecycle coverage for the Odoo domain with no obvious gaps. It includes all essential operations (create, read, update, delete, search, count), metadata tools for discovery, and specialized utilities like execute_method for custom actions. The set enables full agent workflows without dead ends.
Related MCP Connectors
Odoo MCP connector for ChatGPT and Claude: ask sales, invoices and stock in plain words. Read-only.
Odoo virtual employee via MCP: query, create, modify records, workflows, PDFs, and activities.
Read, write and run Odoo actions from any AI app, as each user, with approval rules per colleague.
Connect any AI assistant to Odoo 16โ19 via OAuth 2.0 + PKCE. 400 free calls, no local install.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables LLMs to interact with Odoo ERP systems through MCP protocol. Supports multi-server architecture with secure authentication, allowing natural language access to Odoo data, resources, and business operations.-
- AlicenseBqualityDmaintenanceAn MCP server that enables AI assistants to interact with Odoo ERP apps like Inventory, CRM, Sales, and Manufacturing. It allows users to read, create, and manage Odoo records and workflows using natural language commands.2515 npm1ISC
- AlicenseNot gradedqualityDmaintenanceAn MCP server that connects AI assistants to Odoo ERP instances via the built-in XML-RPC API without requiring any additional addons. It enables users to search, create, update, and manage Odoo records and models through natural language.29 npmMIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server that enables AI assistants to interact with Odoo ERP systems, allowing natural language access to business data, CRUD operations, and instance management without requiring Odoo module installation.1MIT