First-party app
Odoo

Odoo

Read and write Odoo ERP/CRM records — contacts, leads, sales orders, products and users — over the Odoo external JSON-RPC API.

stable Customer Relationship ManagementCommerce & Payments

About

Odoo ships in the w6w first-party pack. It declares 21 actions, 3 health checks, and the host runs its code in a sandbox that never sees the credential.

App id
io.w6w.odoo
Version
0.1.2
Author
w6w
Licence
MIT
Categories
Customer Relationship Management · Commerce & Payments

Overview

Odoo is an ERP whose modules span CRM, sales, invoicing, inventory and manufacturing, and this app reads and writes the models most workflows actually touch — contacts, CRM leads, sales orders and products — over Odoo’s external RPC API, plus discovery actions that reach any other model an installed Odoo app exposes.

It covers the contact lifecycle (create, read, update, delete) and the CRM lead lifecycle (create, read, update), creating and confirming sales orders, and listing products and users. Because Odoo’s own API surface is exactly its database schema, this app also ships List Models, Describe Model, Search Records, Count Records and a Call Method escape hatch, so a workflow can discover and act on any model the connected database has installed, not only the ones named above.

Good for creating a lead or contact automatically from an external form, confirming a sales order once payment or approval lands elsewhere, keeping a product catalog synced with an outside pricing tool, or reaching a module-specific model such as accounting, projects, HR or inventory that has no dedicated action here.

Build with Odoo

Three routes to the same 21 actions. The Workflow tab is generated from Odoo's own manifest and carries its real ids, so it is copy-pasteable; the Code and CLI examples are the same call for any action on any app, so every app-specific value in them is a blank you fill in.

Call Method

call-method

Call any method on any Odoo model via `execute_kw` — business actions like `action_confirm`, or methods from custom modules. Positional arguments go in Args, keyword arguments in Kwargs. Runs with exactly the connected user's permissions.

Confirm Sales Order

confirm-order

Confirm one or more quotations (`sale.order.action_confirm`), moving them from draft to a confirmed sale. Runs Odoo's full confirmation logic — stock moves, deliveries and invoicing schedules — in a single transaction, not just a status change.

Count Records

count-records

Count the records matching a domain on any model, without transferring them. Much cheaper than listing records just to count them.

Create Contact

create-contact

Create a contact or company (`res.partner`) and return its record id. Set Is Company for an organisation, or Parent Company to attach a person to one.

Create Lead

create-lead

Create a CRM lead or opportunity (`crm.lead`) and return its record id. Name is the pipeline card's title; the person's own name goes in Contact Name.

Create Sales Order

create-order

Create a draft quotation (`sale.order`) for a customer and return its record id. Add lines with Odoo's x2many command format. Confirm it separately with Confirm Sales Order.

Delete Contact

delete-contact

Permanently delete one or more contacts (`res.partner`). Errors if an id no longer exists, or if another record still references it — Odoo will not orphan linked documents.

Describe Model

describe-model

List a model's fields, types and requiredness via the ORM's `fields_get`. Use this to discover exact Odoo field names before writing records — they are often not what you would guess (a lead's email address is `email_from`).

Get Contact

get-contact

Read one or more contacts (`res.partner`) by record id. Ids that no longer exist are skipped silently rather than raising — compare `count` against the ids you asked for.

Get Lead

get-lead

Read one or more CRM leads or opportunities (`crm.lead`) by record id. Missing ids are skipped rather than raising — compare `count` against the ids you asked for.

Get Sales Order

get-order

Read one or more sales orders (`sale.order`) by record id. Note `order_line` comes back as a list of line IDs — use Search Records on `sale.order.line` to read the lines themselves.

Get Product

get-product

Read one or more product variants (`product.product`) by record id. `list_price` is the catalogue price — customer-specific prices come from pricelists, not this field.

List Contacts

list-contacts

Search contacts and companies (`res.partner`). Filter with an Odoo domain — e.g. `[["is_company","=",true]]` for organisations only, or `[["email","!=",false]]` for records that have an email address.

List Leads

list-leads

Search CRM leads and opportunities (`crm.lead`). Both live in one model — filter with `[["type","=","opportunity"]]` or `[["type","=","lead"]]` to pick one. Requires the CRM app to be installed.

List Models

list-models

Discover the models installed on this Odoo database (`ir.model`). Which models exist depends on the installed apps, so check here before targeting one — e.g. filter with `[["model","like","crm"]]`.

List Sales Orders

list-orders

Search quotations and sales orders (`sale.order`). They share one model — filter by `state`: `draft`/`sent` are quotations, `sale` is confirmed, e.g. `[["state","=","draft"]]`. Requires the Sales app.

List Products

list-products

Search sellable product variants (`product.product`) — the ids that sales order lines reference. For the catalogue-level product instead, use Search Records on `product.template`.

List Users

list-users

Search Odoo users (`res.users`) — the ids that assignment fields such as a lead's salesperson reference. Requires the connected user to have read access to users.

Search Records

search-records

Run `search_read` against any Odoo model — for anything the named actions do not cover, such as `sale.order.line`, `account.move`, `project.task` or a custom model. Use List Models and Describe Model to find the model and field names.

Update Contact

update-contact

Update one or more contacts (`res.partner`). Only the fields you supply are changed. To clear a field, set it to `false` in Additional Values, e.g. `{"phone": false}`.

Update Lead

update-lead

Update one or more CRM leads or opportunities (`crm.lead`) — including moving them to another pipeline stage. Only the fields you supply are changed.

A workflow step names the app and the action, and the editor fills in the connection when you pick one. This is the Step shape from the workflow spec, carrying Odoo's real ids.

{
  "manifestVersion": "2",
  "name": "odoo-example",
  "steps": [
    {
      "id": "call-method",
      "uses": {
        "app": "io.w6w.odoo",
        "action": "call-method",
        "connection": "conn_YOUR_CONNECTION_ID"
      },
      "with": {
        "model": "<model>",
        "method": "<method>"
      }
    }
  ]
}

Here are some of the things you can do

  • Call Method

    perform
    call-method
  • Confirm Sales Order

    perform
    confirm-order
  • Count Records

    read
    count-records
  • Create Contact

    perform
    create-contact
  • Create Lead

    perform
    create-lead

+16 more actions available

Every app-specific value here is a blank you have to fill in. An app action is reached through the connection that authenticates it, so the address is a connection id, not the app id — and connections belong to your account, so a public page cannot know yours. Create one for Odoo, then fill in the three blanks: conn_YOUR_CONNECTION_ID, the action key, and the parameters that action declares. The call itself is real — the shape is transcribed from the studio's own snippet builder, which prints the same kind of blanks — but nothing in it is specific to Odoo. The Workflow tab is where this app's real ids are.

Install
npm install @w6w/sdk
yarn add @w6w/sdk
pnpm add @w6w/sdk
deno add npm:@w6w/sdk
Code
import { W6wClient, isActionRun } from "@w6w/sdk";

// Reads W6W_BASE_URL and W6W_TOKEN from the environment when omitted.
const client = new W6wClient();

const envelope = await client.run({
  urn: "conn_YOUR_CONNECTION_ID",
  action: "create-lead",
  payload: {
    name: "<value>",
    // type: "<value>",
    // partnerId: "<value>",
    // contactName: "<value>",
    // emailFrom: "<value>",
    // phone: "<value>",
    // expectedRevenue: "<value>",
    // values: "<value>",
    // context: "<value>",
  },
});

if (isActionRun(envelope)) console.log(envelope.value);
Install the CLI
npm install -g @w6w/cli
CLI
w6w run conn_YOUR_CONNECTION_ID --action create-lead --payload '{"name":"<value>"}'

Give an AI agent Odoo — without giving it Odoo's credentials. One MCP endpoint exposes every app, function and workflow the caller is entitled to, as tools it can discover and run. Access is granted per team while we onboard.

One tool call
{
  "name": "w6w_invoke",
  "arguments": {
    "ref": "app:io.w6w.odoo#call-method",
    "input": {
      "model": "<model>",
      "method": "<method>"
    }
  }
}

Every tool names its target with a single ref. The app: form above doesn't name a connection at all — the host resolves which of the caller's Odoo connections to sign with, and refuses rather than guesses when the answer is ambiguous.

What the agent gets

Credentials it can't read

The token is attached host-side, at the moment of the call. It is never a tool argument, never in the model's context, and never in a transcript — so a prompt injection has nothing to exfiltrate.

A tool surface scoped to the caller

Tools are derived per end user from what that person has actually connected and is entitled to — not one shared bot identity carrying the union of everyone's access.

A durable workflow in one call

Multi-step work runs on the workflow engine and returns a run handle the agent can poll — retries, branching and state survive the conversation that started them.

Health-aware discovery

Odoo's declared health checks are on the surface too, so an agent can tell "the vendor is down" from "your credential expired" before it burns a retry on either.

The MCP surface is part of the hosted platform. Odoo itself is MIT, and the runtime that executes it is source-available (FSL).

Request MCP access

Health checks

Odoo declares its own checks, so its health is a property of the app rather than something the host guesses at.

service

Odoo platform status

dependency

Odoo instance reachable

Unauthenticated `common.version` JSON-RPC call against this connection's Odoo instance — proves the host resolves, that /jsonrpc is enabled, and that the database is served.

quota

API rate-limit headroom