If you work on the custom application, Firebase settings should be updated in the backoffice.
Register mobile device
To send push notifications, we need to know the information about the mobile device and associated Firebase token. Opigno Enterprise API provides an endpoint to register mobile devices. If device already exists (there is a match between a user context ID and device UUID), an associated token will be updated. To register device, theregisterMobileDevice mutation should be executed right after the login.
Mutation has one required argument deviceData that represents the information about the mobile device that is being registered:
| Argument | Type | Description |
|---|---|---|
deviceName | String | Required. A name of the device that uses a Firebase token. |
deviceUuid | String | Required. UUID of the current mobile device. |
deviceOs | String | Required. Current mobile device OS. |
firebaseToken | String | Required. A Firebase token assigned to the device to send push notifications. |
Unregister mobile device
To prevent push notifications from being created when a user is logged out from the application, should be executed theunregisterMobileDevice mutation. It has one argument - firebaseToken.
If the mutation executed without any errors, a boolean value will be returned as a response indicating the success status: