Skip to main content
Glama
plgonzalezrx8

odoo-mcp

odoo-mcp

Docker-first FastMCP server for Odoo 19 JSON-2 integrations.

odoo-mcp exposes Odoo as an MCP server over both HTTP and stdio. It uses the Odoo 19 external JSON-2 API only:

POST /json/2/<model>/<method>
Authorization: bearer <ODOO_API_KEY>
X-Odoo-Database: <optional database>

Legacy XML-RPC and JSON-RPC are intentionally out of scope.

Status

This is an early implementation with a strong v1 foundation:

  • FastMCP 3.2.4

  • Docker Compose first

  • HTTP and stdio transports

  • lazy Odoo credential loading so MCP discovery works before secrets are present

  • guarded write operations with confirm=True

  • generic Odoo tools

  • comprehensive CRM tool pack

  • resources and prompts for safe Odoo work

  • pytest, ruff, mypy, and GitHub Actions CI

Related MCP server: Odoo MCP Server

Quick Start With Docker

Copy the environment template and edit the Odoo values:

cp .env.example .env

Required for real Odoo calls:

ODOO_URL=https://your-odoo-host.example.com
ODOO_API_KEY=your-odoo-api-key
ODOO_DATABASE=your-database-if-needed

Start the HTTP server:

docker compose up --build

The default MCP endpoint is:

http://localhost:8000/mcp

Check local process readiness:

docker compose exec odoo-mcp uv run --no-sync odoo-mcp healthcheck

Local Development

Install dependencies:

uv sync

Run the full gate:

uv run pytest
uv run ruff check .
uv run ruff format --check .
uv run mypy src

Run HTTP locally:

uv run odoo-mcp http --host 0.0.0.0 --port 8000 --path /mcp

Run stdio locally:

uv run odoo-mcp stdio

Inspect sanitized config:

uv run odoo-mcp inspect-config

MCP Client Config

Stdio example:

{
  "mcpServers": {
    "odoo": {
      "command": "uv",
      "args": ["run", "odoo-mcp", "stdio"],
      "env": {
        "ODOO_URL": "https://your-odoo-host.example.com",
        "ODOO_API_KEY": "your-odoo-api-key",
        "ODOO_DATABASE": "your-database-if-needed"
      }
    }
  }
}

HTTP clients should connect to /mcp. If the server is exposed beyond a trusted network, set MCP_AUTH_MODE=static or MCP_AUTH_MODE=jwt.

Configuration

Variable

Purpose

ODOO_URL

Base URL for Odoo 19 JSON-2 calls.

ODOO_API_KEY

Odoo API key sent as Authorization: bearer ....

ODOO_DATABASE

Optional Odoo database header.

ODOO_TIMEOUT_SECONDS

HTTP timeout for Odoo calls. Defaults to 30.

ODOO_ALLOWED_GENERIC_METHODS

Comma-separated allowlist for otherwise blocked generic methods.

ODOO_CRM_OPTIONAL_FEATURES

Comma-separated optional CRM features to expose.

MCP_AUTH_MODE

none, static, or jwt. Defaults to none.

MCP_STATIC_TOKEN

Bearer token for MCP_AUTH_MODE=static.

JWT_JWKS_URI

JWKS URL for MCP_AUTH_MODE=jwt.

JWT_PUBLIC_KEY

Public key alternative for JWT verification.

JWT_ISSUER

Optional expected JWT issuer.

JWT_AUDIENCE

Optional expected JWT audience.

JWT_REQUIRED_SCOPES

Optional comma-separated JWT scopes.

MCP_HTTP_HOST

HTTP bind host. Defaults to 0.0.0.0.

MCP_HTTP_PORT

HTTP bind port. Defaults to 8000.

MCP_HTTP_PATH

MCP endpoint path. Defaults to /mcp.

MCP_LOG_LEVEL

HTTP server log level. Defaults to info.

Tool Catalog

Generic Odoo tools:

  • odoo_search_read

  • odoo_read

  • odoo_create

  • odoo_write

  • odoo_unlink

  • odoo_action

  • odoo_call_method

  • odoo_current_user

  • odoo_model_fields

  • odoo_list_models

CRM tools:

  • leads and opportunities: crm_list_leads, crm_get_lead, crm_create_lead, crm_update_lead, crm_assign_lead

  • pipeline: crm_list_pipeline_stages, crm_move_lead_to_stage, crm_pipeline_report

  • won/lost lifecycle: crm_mark_won, crm_mark_lost, crm_restore_lead, crm_list_lost_reasons

  • conversion and merge: crm_convert_lead_to_opportunity, crm_merge_opportunities

  • activities: crm_schedule_activity, crm_mark_activity_done, crm_list_activities, crm_list_activity_types, crm_activity_report

  • teams and scoring: crm_list_teams, crm_update_lead_score

  • optional features: crm_enrich_lead, crm_list_scoring_rules, crm_recurring_revenue_report

Optional CRM tools are registered only when their feature key is listed in ODOO_CRM_OPTIONAL_FEATURES.

Resources And Prompts

Resources:

  • odoo://server/info

  • odoo://user/context

  • odoo://model/{model}/fields

  • odoo://crm/pipeline/summary

Prompts:

  • odoo_safe_operation

  • odoo_crm_pipeline_review

  • odoo_record_change_plan

Safety Model

Odoo remains the final authorization layer through its access rights and record rules. The MCP server adds local guardrails:

  • mutating Odoo client calls require confirm=True

  • generic dangerous methods such as call_kw and execute_kw are blocked unless explicitly allowlisted

  • HTTP MCP auth is separate from the server-side Odoo API key

  • inspect-config redacts secrets

  • Odoo API errors redact configured secret values

Use MCP_AUTH_MODE=static for simple private HTTP deployments:

MCP_AUTH_MODE=static
MCP_STATIC_TOKEN=change-me

Use MCP_AUTH_MODE=jwt with JWT_JWKS_URI or JWT_PUBLIC_KEY for production identity-provider-backed deployments.

Extending

Add module packs under src/odoo_mcp/tools/ and register them from src/odoo_mcp/server.py. Prefer typed, curated tools for business workflows and leave odoo_call_method as the explicit escape hatch.

When adding new Odoo workflows:

  1. Write tests first with mocked Odoo JSON-2 behavior.

  2. Prefer single-call Odoo methods like search_read because each JSON-2 call is its own transaction.

  3. Require confirm=True for writes, actions, posting, validation, archive, and delete operations.

  4. Add focused README entries for new tools and optional feature flags.

Available Tools

1 tool
healthcheckA

Return local server readiness metadata.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

Output Schema

ParametersJSON Schema
NameRequiredDescription

No output parameters

TDQS

A4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description indicates a read-only operation returning metadata, which is typical for a healthcheck. However, without annotations, the description does not explicitly confirm non-destructive behavior or other traits like rate limits or authentication needs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence with no redundant words, efficiently conveying the tool's purpose. It earns its place without any filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (no parameters, no siblings), the description is nearly complete. The presence of an output schema reduces the need to detail return values, though 'metadata' is somewhat vague. It covers the essential purpose.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With zero parameters and 100% schema coverage, the baseline is 4. The description adds value by specifying the returned content ('readiness metadata'), which is beyond what the empty schema provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description explicitly states the tool returns 'local server readiness metadata,' using a specific verb ('return') and a clear resource. No sibling tools exist, so differentiation is not needed.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage as a health check for monitoring server readiness, but provides no explicit when-to-use or when-not-to-use guidance. The lack of siblings reduces the need for alternatives, but the description misses contextual cues like frequency or prerequisites.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

A3.7/5.0
Disambiguation5/5

With only one tool, there is no possibility of confusion between tools. The purpose of 'healthcheck' is clear and distinct.

Naming Consistency5/5

A single tool cannot be inconsistent with itself. The name 'healthcheck' is a reasonable single-word descriptor.

Tool Count1/5

The server is named for Odoo, a full-featured ERP system, but provides only a single health check endpoint. This is an extreme mismatch between scope and tool count.

Completeness1/5

For an Odoo integration, a single healthcheck tool is severely incomplete, lacking any CRUD operations or domain-specific functionality.

Maintenance

ActivityInactive
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Enables AI assistants to interact with Odoo data using natural language to search, read, create, and update records. It acts as a secure bridge between MCP clients and Odoo instances version 17.0 through 19.0.
    11
    Apache 2.0
  • A
    license
    Not graded
    quality
    D
    maintenance
    Bridges AI agents to Odoo ERP via MCP, enabling CRUD operations, model introspection, and report generation with secure API key and connection management through a web admin UI.
    4
    GPL 3.0
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI agents to interact with Odoo ERP to perform sales tasks such as searching clients and products, and creating and confirming quotations via the MCP protocol.
    2
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables interaction with Odoo 18 (JSON-RPC API) via MCP, supporting model exploration, CRUD operations, and secure API key authentication.
    Apache 2.0

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/plgonzalezrx8/odoo-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server