YouriT/mcp-odoo-model-explorer
If you are the rightful owner of mcp-odoo-model-explorer and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.
The MCP Odoo Model Explorer is a server that allows AI assistants to explore and analyze Odoo models, fields, relationships, and methods, facilitating ERP development.
MCP Odoo Model Explorer
A Model Context Protocol (MCP) server that provides AI assistants with resources and tools to explore and analyze Odoo models, fields, relationships, and methods. Connect to any Odoo instance to inspect database structure, search models, fetch records, and discover related entities for ERP development.
Table of Contents
Features
- Models Resource: Browse all Odoo models via
odoo://models - Model Schema: Inspect field properties and types via
odoo://model/{model} - Record Access: Fetch specific records via
odoo://record/{model}/{id} - Advanced Search: Filter records with domain queries, pagination, and ordering
- Related Models: Discover model relationships via many2one, one2many, many2many fields
- Model Methods: Search Odoo GitHub source for model methods and implementations
Usage
Configure your MCP client to run:
bunx @yourit/mcp-odoo-model-explorer
Environment Variables
| Variable | Required | Description |
|---|---|---|
ODOO_DB | Yes | Database name |
ODOO_USER | Yes | Username |
ODOO_PASSWORD | Yes | Password |
ODOO_URL | No | Odoo instance URL (defaults to https://{ODOO_DB}.odoo.com) |
ODOO_READONLY | No | Set to false to enable record mutations (default: true) |
GITHUB_TOKEN | No | GitHub token for get-model-methods tool |
Resources
MCP Resources provide read-only access to Odoo data via URI patterns:
| Resource | URI Pattern | Description |
|---|---|---|
| Models | odoo://models | List all available Odoo models |
| Model Schema | odoo://model/{model} | Get model info including all fields |
| Record | odoo://record/{model}/{id} | Get a specific record by ID |
Tools
Tools provide parameterized actions for complex queries:
| Tool | Description | Parameters |
|---|---|---|
search-model | Search models with domain filters | domain, limit, fields? |
search-records | Search records in a model | model, domain?, fields?, limit?, offset?, order? |
count-records | Count records matching domain filter | model, domain? |
get-related-models | Find related models | model |
get-model-methods | Find model methods in Odoo source | model |
update-record | Update existing records | model, ids, values (requires ODOO_READONLY=false) |
Development
Requires Bun runtime.
bun install # Install dependencies
bun src/index.ts # Run the server
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
MIT License - see file for details.