> ## Documentation Index
> Fetch the complete documentation index at: https://nango.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Odoo (API Key)

> Integrate your application with the Odoo JSON-2 API using an API key

## 🚀 Quickstart

Connect to Odoo with Nango and see data flow in 2 minutes.

<Steps>
  <Step id="create-integration" title="Create the integration">
    In Nango ([free signup](https://app.nango.dev)), go to [Integrations](https://app.nango.dev/dev/integrations) -> *Configure New Integration* -> *Odoo (API Key)*.
  </Step>

  <Step id="authorize-odoo" title="Authorize Odoo">
    Go to [Connections](https://app.nango.dev/dev/connections) -> *Add Test Connection* -> *Authorize*, then enter your Odoo domain and API key. Later, you'll let your users do the same directly from your app.
  </Step>

  <Step id="call-odoo-api" title="Call the Odoo API">
    Let's make your first request to the Odoo API (search and read partner records). Odoo's JSON-2 API takes the model and method in the URL path, and any arguments in the request body. Replace the placeholders below with your [secret key](https://app.nango.dev/dev/environment-settings), [integration ID](https://app.nango.dev/dev/integrations), and [connection ID](https://app.nango.dev/dev/connections):

    <Tabs>
      <Tab title="cURL">
        ```bash theme={null}
        curl "https://api.nango.dev/proxy/2/res.partner/search_read" \
          -X POST \
          -H "Authorization: Bearer <NANGO-SECRET-KEY>" \
          -H "Provider-Config-Key: <INTEGRATION-ID>" \
          -H "Connection-Id: <CONNECTION-ID>" \
          -H "Content-Type: application/json" \
          -d '{"domain": [["is_company", "=", true]], "fields": ["name"]}'
        ```
      </Tab>

      <Tab title="Node">
        Install Nango's backend SDK with `npm i @nangohq/node`. Then run:

        ```typescript theme={null}
        import { Nango } from '@nangohq/node';

        const nango = new Nango({ secretKey: '<NANGO-SECRET-KEY>' });

        const res = await nango.post({
            endpoint: '/2/res.partner/search_read',
            data: { domain: [['is_company', '=', true]], fields: ['name'] },
            providerConfigKey: '<INTEGRATION-ID>',
            connectionId: '<CONNECTION-ID>'
        });

        console.log(res.data);
        ```
      </Tab>
    </Tabs>

    Or fetch credentials with the [Node SDK](/docs/reference/sdks/node#get-a-connection-with-credentials) or [API](/docs/reference/api/connection/get).

    ✅ You're connected! Check the [Logs](https://app.nango.dev/dev/logs) tab in Nango to inspect requests.
  </Step>

  <Step id="implement-nango" title="Implement Nango in your app">
    Follow our [Auth implementation guide](/docs/guides/primitives/auth) to integrate Nango in your app.

    To obtain your own production credentials, follow the setup guide linked below.
  </Step>
</Steps>

## 📚 Odoo (API Key) integration guides

Nango-maintained guides for common use cases.

* [How do I link my Odoo account?](/docs/api-integrations/odoo-api-key/connect)\
  Connect your Odoo account using the Connect UI

Official docs: [Odoo JSON-2 API](https://www.odoo.com/documentation/latest/developer/reference/external_api.html)

<Note>
  This integration uses Odoo's native JSON-2 API (`/json/2/<model>/<method>`) with a personal API key. If your Odoo instance instead exposes the third-party OCA REST API module, use the [Odoo (OAuth)](/docs/integrations/all/odoo) or [Odoo (Client Credentials)](/docs/integrations/all/odoo-cc) integration instead.
</Note>

## 🧩 Pre-built syncs & actions for Odoo (API Key)

Enable them in your dashboard. Extend and customize to fit your needs.

### Others

| Function name          | Description                                                                           | Type                                           | Source code                                                                                                                       |
| ---------------------- | ------------------------------------------------------------------------------------- | ---------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| `call-method`          | Call an arbitrary Odoo model method through the JSON-2 API.                           | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/call-method.ts)          |
| `count-records`        | Count Odoo records matching a domain, without fetching them.                          | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/count-records.ts)        |
| `create-record`        | Create an Odoo model record                                                           | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/create-record.ts)        |
| `delete-record`        | Delete an Odoo model record.                                                          | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/delete-record.ts)        |
| `duplicate-record`     | Duplicate an existing Odoo model record.                                              | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/duplicate-record.ts)     |
| `find-records-by-name` | Find Odoo records by a partial name match, as used for autocomplete/dropdown lookups. | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/find-records-by-name.ts) |
| `get-record-fields`    | Fetch Odoo fields metadata for a model.                                               | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/get-record-fields.ts)    |
| `read-record`          | Fetch specific Odoo records by ID.                                                    | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/read-record.ts)          |
| `search-read-records`  | Search and read records from any Odoo model.                                          | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/search-read-records.ts)  |
| `search-records`       | Search for Odoo record IDs matching a domain, without reading their fields.           | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/search-records.ts)       |
| `update-record`        | Update an Odoo model record                                                           | [Action](/docs/guides/functions/action-functions)   | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/actions/update-record.ts)        |
| `contacts`             | Sync Odoo contacts and companies.                                                     | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/contacts.ts)               |
| `crm-leads`            | Sync Odoo CRM leads and opportunities.                                                | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/crm-leads.ts)              |
| `invoices`             | Sync Odoo invoices and bills                                                          | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/invoices.ts)               |
| `payments`             | Sync Odoo customer and vendor payments                                                | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/payments.ts)               |
| `products`             | Sync Odoo products.                                                                   | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/products.ts)               |
| `project-tasks`        | Sync Odoo project tasks.                                                              | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/project-tasks.ts)          |
| `sale-orders`          | Sync Odoo sale orders.                                                                | [Sync](/docs/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/odoo-api-key/syncs/sale-orders.ts)            |

***
