Odoo Live Chat in external apps
Conversational support with the data centralized in the ERP. How at TechSed we connect the support chat of any company app with Odoo, keeping every conversation linked to its contact and project.
The problem we wanted to solve
Several of our applications needed a live support channel. A concrete example is our Yurumi fleet-control module, used by field staff to log dispatches and daily reports: when something doesn't work, they need to message support without leaving the app.
We didn't want to reinvent a chat system or add yet another external tool (think Intercom or Zendesk) that ends up fragmenting customer data into silos separate from the ERP. Odoo already has Live Chat, so the question was: how do we use it from our apps?
The problem: the Live Chat widget, embedded in an external app, always opens as an anonymous "Visitor" and can't be linked to a contact. The operator doesn't know who's on the other side and the conversation isn't associated with any contact — context is missing. We wanted that, when a user already identified in our app starts a chat, that conversation gets automatically linked to their contact in Odoo — without asking them to log in again and without breaking the ongoing chat.
Why use Odoo's Live Chat (and not something else)
- It's already where the business lives: sales, projects, inventory, contacts… it's all in Odoo. Support should be there too.
- No new tools or licenses: operators handle chats from Discuss, the same place where they already work.
- Embeddable in any app: the widget is inserted with a couple of scripts — in an app, a web portal or a mobile app.
- Centralized data: history, metrics and contacts stay inside Odoo, not in a third party.
The technical challenge
Solving it had its complexity. Three constraints shaped the design:
- The widget opens as a guest. Embedded cross-origin, the only identifier the browser
exposes for the chat is a
guest_tokenthat Odoo stores inlocalStorage. - Users aren't Odoo users. In our apps people authenticate with their own credentials (employee, magic link). You can't use Odoo's native login.
- You can't break the live chat. A first "heavy-handed" attempt — reassigning the conversation member from the guest to the contact — broke the session: on reload, the widget lost the chat and opened a new one. That was the big lesson.
The solution: a small, generic add-on
We built an Odoo module, livechat_partner_link, whose only job is to link an
ongoing chat to a contact (a res.partner). It's deliberately small and generic: it
depends only on im_livechat, so it can be reused in any company app.
How a conversation gets linked to a contact
The visitor keeps chatting in the same conversation; only the contact’s identity is added.
guest.localStorage: the only identifier the widget exposes.res.partner by email and creates it if it doesn’t exist.POST /livechat/partner-link with the token and the partner. The module links the conversation.The path is simple: the user opens the chat, the browser stores the guest_token, the
app backend resolves (or creates) the contact and calls the module's endpoint to link the
chat. From there, the operator sees who the customer is.
The interesting technical bits
A non-invasive solution
The key to the final design: the chat's "live member" remains the guest. We never reassign it. So everything the widget needs keeps working intact: channel membership, session restore on reload, the realtime bus and sending messages.
The contact is added in the reporting layer: the visitor's history is pointed to the
res.partner, the guest is renamed with the contact's name, and a "View Contact"
button is exposed in the operator's panel. The visitor simply keeps chatting, now
identified.
The key The chat's "current member" remains the guest, so the widget session doesn't break. The contact is added in the reporting layer.
The endpoint
The app, authenticated as a technical user, calls a single endpoint:
{ "guest_token": "42|<token>", "partner_id": 17 }
{ "ok": true, "data": { "linked": true, "thread_id": 42, "...": "..." } }
It's idempotent (re-linking the same chat does nothing) and generic: resolving or
creating the contact — for example, looking it up by email and creating it if it doesn't
exist — is done by each app with the standard res.partner API. The module doesn't get
involved in that, which is why it works for any integration.
Use cases
- Apps fully separate from Odoo: users open support from the app and the support team already knows who's writing and from which app.
- Customer portal / website: the logged-in customer chats and the conversation stays tied to their CRM record.
- Mobile or satellite apps: any app with its own users can offer support without duplicating contacts.
- After-sales and onboarding: conversational follow-up with the customer's full history at hand.
The big win: everything centralized in Odoo
Beyond the convenience, the real value is in data centralization. Every company app embeds its own support channel, and it all ends up in one place.
A single Odoo as the source of truth
Every company app embeds the same support channel; all the data stays centralized in Odoo.
+ /livechat/partner-link
- One contact per person: no duplicated or out-of-sync data across applications.
- Conversations and history in one place: the support team works from Discuss, with the full CRM context (sales, projects, tickets).
- Reporting and traceability: support metrics and per-customer follow-up, native to Odoo.
- Lower costs and fewer fragile integrations: no third-party licenses or syncs that break.
Frequently asked questions
Can you use Odoo Live Chat inside an external app?
Yes. The Odoo Live Chat widget can be embedded in any app, even cross-origin. By default
it opens as an anonymous visitor; with the livechat_partner_link module the conversation
is automatically linked to the contact (res.partner) of the user already identified in
the app.
How is a Live Chat conversation linked to an Odoo contact?
The app, authenticated as a technical user, calls a single idempotent endpoint
(POST /livechat/partner-link) with the chat guest_token. The module points the visitor
history to the res.partner, renames the guest with the contact name, and exposes a
View Contact button in the operator panel.
Do you need an external tool like Intercom or Zendesk?
No. Odoo already includes Live Chat, so conversational support lives inside the same ERP as sales, projects, inventory and contacts, without fragmenting customer data into separate silos.
Does the module break the widget session when linking the contact?
No. It is a non-invasive solution: the chat’s “live member” remains the guest, so channel membership, session restore on reload and the realtime bus keep working. The contact is added only in the reporting layer.
Conclusion
With a small, generic and non-invasive add-on, any company application can offer live support using Odoo's Live Chat, keeping every conversation tied to its contact. Reusable, with no external tools and with all the data where it belongs: inside Odoo.
Have a similar challenge with Odoo?
At TechSed we work with Odoo every day. This module was born from a concrete need on a project and we kept it generic so we could reuse it; it happens to us often that a specific requirement, solved well, ends up being a solid, reusable piece.
If you're thinking about something like this — connecting Odoo with your own application, automating a process or a custom development — write to us and let's look at it together. We prefer to understand the problem well before proposing: often the best solution is the simplest one and, sometimes, the most honest thing is to recommend building nothing.
Shall we talk? Write to us at [email protected] and tell us what you need.
