Description
When someone fills in a contact form on your site, this plugin writes them into
your Odoo database as a contact (res.partner) and tags it with the Odoo
contact tag you choose, so web enquiries are easy to find and filter.
It talks to Odoo over the External JSON-2 API (POST /json/2/{model}/{method}
with bearer-token authentication). It deliberately avoids the legacy XML-RPC and
/jsonrpc endpoints, which Odoo has deprecated.
What it does
- Field mapping you control. Point any Odoo contact field — name, email,
phone, mobile, company, website, job position, street, city, ZIP, notes — at
whichever field id your form sends. Nothing is hard-coded. - Contact tag. Enter the ID of an Odoo contact tag and every contact the
plugin creates or updates gets that tag. Tags already on a contact are kept. - Duplicate handling. Matches on email, case-insensitively. Choose whether a
repeat submission updates the existing contact, is left alone, or always
creates a new record. - Non-destructive updates. When it updates an existing contact it appends to
the Notes field rather than overwriting it, and never rewrites the contact’s
name. Your sales team’s notes survive. - A built-in form. The
[odoo_contact_form]shortcode gives you a plain,
nonce- and honeypot-protected contact form, so you can prove the whole chain works
without installing a form plugin first. - Divi Contact Form support. Detected automatically when Divi or the Divi
Builder is active. - Diagnostics. A read-only “Test connection” check (which also confirms the
tag ID exists) and a “Create a test contact” button, so you find out about a bad API key on the settings screen
rather than from a visitor’s lost enquiry. - Safe by design. A sync failure is logged and swallowed — it never turns
into a broken-looking page for the person who filled in your form.
Requirements
- An Odoo server running version 19 or newer, reachable over HTTPS.
- An Odoo API key for a user with create/write access to
res.partnerand read
access to contact tags (res.partner.category). - PHP 8.1 or newer, WordPress 6.4 or newer.
Extending it
Form integrations are pluggable. Implement OdooConnector\Forms\FormIntegration
and add it through the odoo_connector_form_integrations filter to support
WPForms, Gravity Forms, Contact Form 7 or anything else.
External services
This plugin sends data to the Odoo server that you configure on its settings
screen. No data is sent anywhere else, and the plugin contacts no service
belonging to CandorLight LLC or to any third party.
What is sent, and when. Each time a visitor submits a connected form, the
plugin makes an HTTPS request to your Odoo server containing the form values you
have mapped. In a default setup that is the visitor’s name, email address, phone
number, company name, company website and message, plus a provenance line naming
the form, your site’s URL and the submission time, and the contact tag ID you
configured. Requests are also made
when you press “Test connection” (a read-only count of contacts and a lookup of
the configured tag) or “Create a
test contact” on the settings screen.
Where it goes. To the URL you enter as the Odoo URL — normally your own
self-hosted Odoo instance or your Odoo Online subscription. This plugin’s
authors do not operate, host or have access to that server.
Whose terms apply. If you use Odoo Online or another hosted Odoo service,
that provider’s terms and privacy policy govern the data once it arrives:
Odoo S.A.’s terms are at https://www.odoo.com/terms and their privacy policy at
https://www.odoo.com/privacy . If you self-host, the data stays on your own
infrastructure.
Because the plugin transmits personal data your visitors have submitted, make
sure your own privacy policy says so, and that you have a lawful basis for
sending it to your CRM.
Installation
- Upload the plugin to
/wp-content/plugins/or install it through
Plugins Add New, then activate it. - In Odoo, create an API key: click your avatar My Profile (or
My Preferences) Account Security New API Key. Odoo requires a
duration and currently caps keys at three months, so note the expiry date. - In WordPress, go to Settings Connector for Odoo. Enter your
Odoo server root URL (no trailing slash, no/webor/odoopath), the
database name, and the API key. Save. - Press Test connection. A green result means the URL, the database and the
key are all good. - Under Contacts, enter the ID of the Odoo contact tag to apply. In
Odoo go to Contacts Configuration Tags, open the tag and read the
number at the end of the URL. Leave it empty for no tag. - Under Field mapping, check that each Odoo field points at the field id
your form actually sends. Divi lowercases its field ids and strips spaces, so
a field labelled “Company name” arrives ascompanyname. - Submit your form once and confirm the contact appears in Odoo.
FAQ
-
Which versions of Odoo are supported?
-
Odoo 19 and newer. The plugin uses the External JSON-2 API, which older releases
do not provide. It does not fall back to XML-RPC. -
Where do I find my database name?
-
It is the Odoo database name, not your WordPress database. If you are unsure,
runodoo.infoin your browser’s developer console while viewing any Odoo page. -
Do I need the CRM module in Odoo?
-
No. Contacts and contact tags are part of every Odoo install.
-
How do I stop sending submissions to Odoo?
-
Deactivate the plugin. Your settings are kept until you delete it.
-
My API key stopped working after a few months.
-
Odoo caps API key lifetimes (currently at three months). Generate a new key and
paste it into the settings screen. The stored key is never shown back to you —
the field displays dots — so leaving the dots untouched keeps the existing key. -
Does it work with Contact Form 7 / WPForms / Gravity Forms?
-
Not out of the box. Divi’s contact form and the bundled
[odoo_contact_form]
shortcode are supported today. Other forms can be added through the
odoo_connector_form_integrations filter without modifying the plugin. -
Does the plugin store submissions in WordPress?
-
No. Submissions are passed straight through to Odoo and are not written to your
WordPress database. If logging is switched on, request details are written to
your PHP error log with API keys and tokens redacted — that log is the only
local copy, and logging is off by default. -
A submission did not reach Odoo. How do I debug it?
-
Turn on Logging in the settings screen and make sure
WP_DEBUG_LOGis
enabled inwp-config.php. Every request, response code and error is written to
the log, prefixed[odoo-connector]. Failed payloads are logged in full so a
lost enquiry can be re-entered by hand. -
My Divi form submits but nothing happens.
-
Turn on Logging and submit the form once. If no
et_pb_contact_form_submitline appears in the log, your Divi version does not fire the action this
fired
plugin listens to. -
Is this an official Odoo product?
-
No. It is an independent integration by CandorLight LLC, not affiliated with,
endorsed by or sponsored by Odoo S.A. “Odoo” is a trademark of Odoo S.A.
Reviews
There are no reviews for this plugin.
Contributors & Developers
“CandorLight Connector for Odoo” is open source software. The following people have contributed to this plugin.
ContributorsTranslate “CandorLight Connector for Odoo” into your language.
Interested in development?
Browse the code, check out the SVN repository, or subscribe to the development log by RSS.
Changelog
0.8.0
- New: “Tag ID” setting. Every contact created or updated is linked to that Odoo
contact tag; existing tags are kept. “Test connection” checks the tag exists. - Removed: CRM lead / opportunity creation and its settings.
- Removed: the “Send submissions” switch; deactivate the plugin to stop
syncing. - Security: the built-in form verifies its nonce before reading any other posted
value, and every field is sanitized and validated for its type (email, phone,
URL, text length). - Security: removed the Divi hook probe, which inspected $_POST on every
request. The Divi integration no longer reads request data at all; it only
receives values from Divi’s own nonce-checked submit action and sanitizes them.
0.7.0
- First public release.
- Settings screen with connection details, field mapping, duplicate handling and
CRM lead options. - Odoo External JSON-2 API client covering arbitrary model calls, plus helpers
for finding, creating and updating contacts and creating CRM leads. - Divi Contact Form integration, plus the
[odoo_contact_form]shortcode with
honeypot spam protection and post/redirect/get handling. - Duplicate handling on email with update / skip / always-create modes.
- Updates now append to an existing contact’s Notes instead of overwriting them,
and no longer rewrite the contact’s name. - Optional CRM lead or opportunity creation with a templated subject.
- “Test connection” and “Create a test contact” diagnostics.
- Opt-in logging with credentials redacted; logging now defaults to off.
- The Divi hook probe is now opt-in and scoped to genuine contact-form requests.
0.1.0
- Initial internal scaffold: settings screen, JSON-2 client, connection test.
Versions 0.2.0 through 0.6.0 were internal development builds and were never
released publicly.