Tools reference¶
The MCP server exposes 18 tools. All operations on models
go through the compatibility layer: you can use modern model and field
names, and the server resolves them to whatever exists in the target version. The
unavailable fields are dropped with a dropped_fields warning instead
of failing the whole call.
Write tools
Five tools modify data: odoo_create, odoo_write,
odoo_unlink, odoo_execute and odoo_translate_set. They are marked below with
:material-pencil: WRITES. The public core does not apply approval
gates (that lives in a private governance layer). Use a least-privilege
user and review every write.
Summary¶
| Tool | Type | What it does |
|---|---|---|
odoo_search |
read | Searches and returns ids |
odoo_search_count |
read | Counts records |
odoo_read |
read | Reads records by id |
odoo_search_read |
read | Searches and reads in one call |
odoo_export_records_json |
read | Exports to JSON |
odoo_export_records_csv |
read | Exports to CSV |
odoo_version |
read | Version/edition/deployment/transport |
odoo_connections |
read | Active sessions |
odoo_list_models |
read | Lists models |
odoo_fields_get |
read | Fields of a model (cached) |
odoo_module_info |
read | Status of a module |
odoo_translate_get |
read | Reads a translation |
odoo_report |
read | Renders a QWeb report to base64 |
odoo_create |
writes | Creates a record |
odoo_write |
writes | Updates records |
odoo_unlink |
writes | Deletes records |
odoo_execute |
writes | Calls any method of the model |
odoo_translate_set |
writes | Sets a translation |
Read and query¶
odoo_search¶
Searches a model and returns the matching ids.
| Parameter | Required | Type | Notes |
|---|---|---|---|
model |
yes | string | modern or historical name |
domain |
no | array | Odoo search domain |
limit / offset / order |
no | — | pagination and ordering |
odoo_search_count¶
Counts the records that match a domain (without fetching data).
odoo_read¶
Reads records by id, optionally limiting the fields.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
ids |
yes | array of integers |
fields |
no | array of strings |
odoo_search_read¶
Searches and reads in a single call — the main query tool.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
domain, fields, limit, offset, order |
no | — |
odoo_search_read {
"model": "account.move",
"domain": [["state","=","posted"]],
"fields": ["name","amount_total","invoice_date"],
"limit": 10, "order": "invoice_date desc"
}
odoo_export_records_json¶
Exports the records that match a domain as a JSON array (read-only).
Same parameters as odoo_search_read. Returns { model, count, records }.
odoo_export_records_json { "model": "product.template", "fields": ["name","list_price"], "limit": 500 }
odoo_export_records_csv¶
Same as the previous one but returns CSV text. The many2one values are flattened to
their display name. Returns { model, count, columns, csv }.
odoo_export_records_csv { "model": "res.partner", "domain": [["customer_rank",">",0]], "fields": ["name","email","city"] }
Metadata and introspection¶
odoo_version¶
No parameters. Returns version, raw_version, edition, deployment and the
active transport.
odoo_connections¶
No parameters. Lists the Odoo instances with an active session on the server.
odoo_list_models¶
Lists models, optionally filtered by a name fragment.
| Parameter | Required | Type | Notes |
|---|---|---|---|
like |
no | string | fragment (case-insensitive) |
limit |
no | integer | default 200 |
odoo_fields_get¶
Returns the field definitions of a model (cached). It accepts historical or modern names.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
attributes |
no | array of strings |
odoo_module_info¶
Installation status and metadata of a module by its technical name.
odoo_translate_get¶
Reads the value of a field in a specific language for a record.
| Parameter | Required | Type | Notes |
|---|---|---|---|
model |
yes | string | |
id |
yes | integer | |
field |
yes | string | |
lang |
yes | string | e.g. es_MX, en_US, zh_CN |
odoo_report¶
Renders a report action (by report_name) for certain ids and returns
the document in base64.
| Parameter | Required | Type | Notes |
|---|---|---|---|
report_name |
yes | string | e.g. account.report_invoice |
ids |
yes | array of integers |
Write :material-pencil:¶
odoo_create :material-pencil: WRITES¶
Creates a record. Returns the new id.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
values |
yes | object |
odoo_write :material-pencil: WRITES¶
Updates records by id.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
ids |
yes | array of integers |
values |
yes | object |
odoo_unlink :material-pencil: WRITES¶
Deletes records by id.
odoo_execute :material-pencil: WRITES¶
Calls an arbitrary method of the model (escape hatch). args/kwargs are
passed as-is. It does not go through edition resolution, so use it with judgment.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
method |
yes | string |
args |
no | array |
kwargs |
no | object |
odoo_translate_set :material-pencil: WRITES¶
Sets the translation of a field for a language. In Odoo 16+ it uses the native
update_field_translations API; in earlier versions it writes the field under the
language context. The compatibility layer picks the correct path.
| Parameter | Required | Type |
|---|---|---|
model |
yes | string |
id |
yes | integer |
field |
yes | string |
lang |
yes | string |
value |
yes | string |
odoo_translate_set { "model": "product.template", "id": 42, "field": "name", "lang": "en_US", "value": "Wireless mouse" }
To understand how names are resolved across versions, see Cross-version compatibility.