Skip to content

Notification Issues

The platform supports push notifications via two providers. Each provider has a different token model and a different failure surface.

Provider How it works Best for
ntfy Self-hosted push server. Customers subscribe to a per-subscription topic. Token identifies the topic. Web and desktop notifications, self-hosted setups
FCM Firebase Cloud Messaging. Requires a Google service account JSON. Mobile apps

Token Lifecycle

Each subscription has a single notification token stored in ntfy_token. The token status is tracked in ntfy_token_status:

Status Meaning
False (no token) Token was never generated, or was cleared
active Token is valid and in use
expired Token has passed its ntfy_token_expiry date

Auto-renewal: If auto_generate_tokens is enabled on the notification server record, expired tokens are regenerated automatically. If it is disabled, the operator must manually regenerate the token.

Tip

After regenerating a token, the customer must update their notification subscription in the portal or app using the new token value. The old topic or device registration will stop receiving messages.


Testing Notification Delivery

  1. Navigate to SAAS Management → Configuration → Notification Servers → <server>.
  2. Click Test Connection.
    • For ntfy: calls /v1/health on the ntfy server and expects a 200 OK.
    • For FCM: performs a basic connectivity check to Google's FCM endpoint.
  3. To test actual message delivery to an ntfy topic:

    curl -d "Test from Sadeem" https://ntfy.yourdomain.com/your-topic-token
    

    The customer should receive this notification immediately on any subscribed device.

Note

Test Connection only verifies that the Master can reach the notification server. It does not confirm that a specific subscription token is valid. Use the curl method above to verify end-to-end delivery.


ntfy Failures

Issue Symptom Fix
Wrong server URL Test Connection fails with a connection error URL must include the scheme: https://ntfy.yourdomain.com — not ntfy.yourdomain.com
auth_method mismatch HTTP 401 on token creation Check the Authentication setting on the notification server record — it must match the ntfy server's auth-required config
Admin credentials wrong Token creation fails with 401 or 403 Verify Admin Username and Admin Password on the notification server record
Token expired ntfy_token_status shows expired Enable auto_generate_tokens on the server record, or click Action → Generate Token on the subscription
ntfy server down All notifications fail silently Check the ntfy process: systemctl status ntfy or inspect the container if Docker-hosted

No Token Assigned

Symptom: The subscription's ntfy_token field is empty.

  1. Verify at least one notification server exists: SAAS Management → Configuration → Notification Servers.
  2. Confirm the subscription has a Notification Server linked (or that get_default_server() returns a result if none is set explicitly).
  3. Click Action → Generate Token on the subscription.

FCM Failures

Issue Symptom Fix
Service account JSON invalid Test Connection error containing invalid_grant or Could not deserialize key data Re-download the service account JSON from Google Cloud Console → IAM → Service Accounts → Keys
Wrong project ID Messages send with 200 OK but customer never receives them Verify the project_id in the service account JSON matches your Firebase project
Device token expired Messages acknowledged by FCM but not delivered FCM device tokens expire when the customer app is reinstalled or cleared — the customer app must request a new token and POST it back to the subscription

Warning

FCM delivery acknowledgement (200 OK from Google) does not guarantee the customer received the notification. If FCM reports success but messages are not arriving, the device token is almost certainly stale.


Enable / Disable Notifications Action

The Enable Notifications and Disable Notifications buttons on the subscription form toggle notifications on the customer's running Odoo instance via the SaaS Slave (a feature that gives the customer instance self-service control over module installation and management) API. This is a remote action — it requires the customer instance to be reachable.

If the button does not work:

  1. Confirm saas_slave_enabled is ticked on the subscription form.
  2. Verify the customer instance is in Running state and reachable from the Master.
  3. Check the chatter on the subscription for error messages from the slave endpoint.
  4. If the customer instance is unreachable, resolve the connectivity issue first, then retry the action.

Note

The Enable/Disable Notifications buttons are hidden when saas_slave_enabled = False. If the buttons are not visible at all, check that field first.