Update records
odoo_writeUpdate fields on one or more existing Odoo records. The model must be on the workspace's write whitelist with can_write=true; sensitive fields cannot be set. Runs in one call, except a write with force_workflow (see that parameter). Hard limit of 200 ids per call: split a longer list into batches. context sets the company scope.
A WRITE REPLACES THE WHOLE VALUE OF EVERY FIELD YOU PASS — it never merges. On long-form fields (description, internal notes, …) that is destructive and unrecoverable: the previous value leaves no trace in the chatter. If the user asked you to ADD to or COMPLETE such a field, pass mode='append' with only the new content; the default mode='replace' is for when they want what is there discarded. To change PART of an html field, use odoo_html (edit / replace_section) instead of rewriting it. Html fields take markdown, converted the Odoo way: - [ ]/- [x] checklists, pipe tables, ##/### sections, --- separators. No inline style, invented classes or invented image URLs.
READ THE ANSWER BEFORE REPORTING: Odoo accepts fields it will not keep (computed, screen-only) and still says success, so the result carries ignored (with the reason), unverified and warnings. Their absence means everything landed. Report what was saved in Odoo, never that the change already shows on the user's screen.
SEND INTERDEPENDENT FIELDS IN ONE CALL: Odoo respects a field you write explicitly alongside the ones that would recompute it, but across two calls the second write recomputes over the first and silently discards it.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"model": "<model>",
"ids": "<ids>",
"values": "<values>"
},
"name": "odoo_write"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ids | Yes | Record IDs to update (max 200). | |
| mode | No | 'replace' (default) overwrites every field with what you send. 'append' keeps the current content of the html/text fields and puts yours below it, per record — use it whenever the user asked to add to or complete a description or a note. Other field types are replaced in both modes. | replace |
| model | Yes | Odoo model technical name. | |
| values | Yes | Field-value dict applied to every id. | |
| context | No | Optional Odoo context. | |
| force_workflow | No | Only after a `workflow_field` refusal, and only when the user explicitly asked to set that field by hand anyway (a data fix). It skips the refusal. In Tuqui's chat the write then returns a preview and runs only once the user replied to it in a later turn. |