Actions21
Contact → Update
AI-generatedOverview
This node updates an existing Contact in Odoo via its API. It is designed for scenarios where you need to programmatically modify contact details—such as name, address, email, phone numbers, or other fields—in your Odoo instance from within an n8n workflow.
Common use cases:
- Synchronizing contact information between Odoo and another CRM or database.
- Automating updates to contacts based on external triggers (e.g., form submissions, support tickets).
- Bulk updating contact records as part of a data migration or cleanup process.
Example:
If a user's email changes in your main customer database, you can use this node to automatically update the corresponding contact's email in Odoo.
Properties
| Name | Meaning |
|---|---|
| Contact ID | The unique identifier of the contact to update in Odoo. This is required. |
| Update Fields | A collection of fields to update for the contact. You can add one or more of the following:
|
Output
The output will be a JSON object representing the updated contact record as returned by the Odoo API. The structure typically includes all standard Odoo contact fields, such as:
{
"id": 123,
"name": "John Doe",
"email": "john.doe@example.com",
"phone": "+1234567890",
"mobile": "+0987654321",
"website": "https://example.com",
"vat": "DE123456789",
"comment": "Internal note here",
"function": "Manager",
"address": {
"city": "Berlin",
"country_id": 49,
"state_id": 16,
"street": "Main St 1",
"street2": "",
"zip": "10115"
}
// ...other Odoo contact fields
}
- If an error occurs and "Continue On Fail" is enabled, the output will include an
errorfield with the error message.
Dependencies
- Odoo Instance: You must have access to an Odoo server with API access enabled.
- API Credentials: The node requires valid Odoo API credentials (URL, username, password, and database name) configured in n8n under the "odooApi" credential type.
- n8n Configuration: No special environment variables are needed beyond the credentials.
Troubleshooting
Common Issues:
- Invalid Contact ID: If the provided Contact ID does not exist, the node will return an error indicating that the record was not found.
- Missing Required Fields: If required fields are missing or incorrectly formatted, Odoo may reject the update and return an error.
- Authentication Errors: Incorrect API credentials will result in authentication failures.
- Field Value Errors: Providing invalid values (e.g., non-existent country/state IDs) may cause Odoo to return validation errors.
Error Messages & Resolutions:
"Credentials are not valid": Check your Odoo API credentials in n8n."Settings are not valid: ...": There may be a misconfiguration in the Odoo connection settings."Record not found"or similar: Verify the Contact ID exists in Odoo."Validation Error": Ensure all field values conform to Odoo's requirements (e.g., correct data types, valid references).
Links and References
- Odoo Documentation
- n8n Odoo Node Docs
- n8n Expressions Guide (for dynamic field values)