
OneSignal and Odoo 19
Web push from your Odoo website, sent when you decide.
Visitors subscribe to push notifications on your Odoo website. You write pushes in Odoo and send them to OneSignal segments, chosen customers or everyone, now or later. Order and delivery pushes go out only for the rules you switch on.
What it does
You paste the App ID and App API key of your OneSignal app and choose the website. Odoo adds the OneSignal Web SDK to the website pages and serves the OneSignalSDKWorker.js file at the site root, so visitors get the subscribe prompt you set up in OneSignal. A visitor who is logged in is linked to their Odoo contact through a random External ID.
A push in Odoo has a title, a message, an optional image and link, and up to two buttons. You send it to OneSignal segments (and leave others out), to contacts you pick, or to everyone subscribed, at once, at a date and time, or at the same local time in every time zone. Delivered, clicked, failed and waiting counts come back from OneSignal.
Nothing is sent by itself. A push leaves Odoo only when an administrator presses Send. Automatic pushes for a confirmed order, a delivery with its tracking number or a cart left on the website are off until you switch them on, and each one goes only to the customer of that order.
Who it is for
| Web shops on Odoo that want to reach customers who have left the site | |
| Stores that send order and delivery updates as push instead of more email | |
| Companies with several websites, each with its own OneSignal app |
Key features
Screenshots from an Odoo 19 test database. The OneSignal answers come from a test stand-in; the OneSignal prompt itself is loaded from OneSignal and is not shown.
One OneSignal app per website
App ID, App API key (Odoo administrators only), the website, the subscribe switch and the link to logged-in contacts. Test and Load Segments reads your segments; Send Me a Test Push sends one to you only.

Pushes with their results
Drafts, scheduled and sent pushes with the audience and how many were delivered and clicked.

Segments, link, buttons and statistics
Pick segments and segments to leave out. After sending, Refresh Statistics shows delivered, clicked, failed, errored and waiting.

At each subscriber's local time
Send at a date and time (up to 30 days ahead) or at a time of day in every time zone. A scheduled push can be cancelled.

To chosen customers
Only contacts who subscribed while logged in and did not ask for no pushes are reached.

Automatic pushes you switch on
Sales order confirmed, delivery sent, website cart left behind. All start switched off.

Placeholders and a test to yourself
{customer}, {order}, {amount}, {tracking} and {company} in the title and message. The link opens the order in the customer portal unless you set another one.

Written on the order
Each automatic push leaves a line on the order. A push that fails never stops the order.

Push settings on the contact
The random External ID and a No Pushes box per contact.

API log
Every call to OneSignal with its status and time. The key and External IDs stay out of the log.

How it works
| 1 | Create the web push app in OneSignal for your website address. |
| 2 | Add the app in Odoo with App ID and App API key, choose the website, tick Ask Website Visitors to Subscribe. |
| 3 | Press Test and Load Segments and Send Me a Test Push after subscribing yourself. |
| 4 | Write a push and press Send, or schedule it. |
| 5 | Switch on the automatic pushes you want, one by one. |
Settings
| Ask Website Visitors to Subscribe | Load the Web SDK and serve the service worker |
| Link Logged-in Visitors to Their Contact | Random External ID per contact |
| Audience | Segments, chosen contacts or everyone subscribed |
| When | On Send, at a date and time, or at a local time of day |
| Automatic pushes | Order confirmed, delivery sent, cart left behind, each off by default |
| Hours Before the Reminder | How long a cart waits before its single reminder |
| No Pushes (OneSignal) | On the contact: no automatic pushes and no pushes to chosen contacts |
FAQ
Do I need a OneSignal account?
Yes, with a web push app for your site. The module uses your own App ID and App API key.
Can pushes go out without anyone pressing a button?
Only for automatic pushes you switched on, and then only to the customer of that order.
Does it work with mobile apps?
Pushes to contacts and segments go to every subscription of the OneSignal app, so a mobile app that uses the same app and External IDs gets them too.
What about a website that already has a service worker?
Put OneSignal's worker in a subdirectory, as OneSignal explains on its Web SDK setup page.
Is the External ID my contact number?
No, it is random, so nobody can claim another customer's pushes by guessing it.
Compatibility and support
Odoo 19 Community and Enterprise. Needs Website, eCommerce and Inventory.
Questions before or after you buy: modvantaapps@gmail.com. We answer setup questions and fix bugs.
Buy Now - $29Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module