Failure reasons for app push notifications
Netcore utilizes FCM (Firebase Cloud Messaging) for Android notifications and APNS (Apple Push Notification Service) for iOS notifications. Notifications may run into certain failure during submission to FCM or APNS, such errors are logged as Failures at Netcore. Most common reasons are listed below:
Android-Firebase Cloud Messaging Errors
Error | Description |
---|---|
Invalid Registration | If you're managing FCM independently, there's a chance you've submitted an incorrect token. |
UNREGISTERED | App instance was unregistered from FCM. This usually means that the token used is no longer valid and a new one must be used. An existing registration token may cease to be valid in a number of scenarios, including: - If the client app unregisters with FCM. - If the client app is automatically unregistered, which can happen if the user uninstalls the application. - If the registration token expires (for example, Google might decide to refresh registration tokens). - If the client app is updated but the new version is not configured to receive app push messages. |
MismatchSenderId | The authenticated sender ID is different from the sender ID for the registration token. To resolve this, update the Android Server Key stored in Netcore Cloud. You can do this by going to App Assets section in settings and update the respective android app asset settings. |
Invalid JSON | Ensure that the JSON message is correctly structured and includes valid fields within the Name-Value pairs you're transmitting. |
Message Too Big | Ensure that the total size of the payload data in your message doesn't surpass the GCM limit of 4096 bytes. Consider reducing the number of Name-Value pairs you're passing if needed to stay within this limit. |
INTERNAL | The server encountered an error while trying to process the request. You could retry the same request following the requirements listed in "Timeout" (see row above) |
Device Message Rate Exceeded | The frequency of messages sent to a specific user is excessive. |
None | This is an UNSPECIFIED_ERROR with no information available from FCM |
Note: you can also refer to the official FCM documentation for failure reasons.
iOS - Apple Push Notification Service Errors
Error | Description |
---|---|
Processing error | There was a problem on APNS's end. |
Others | There was a problem on APNS's end. |
Invalid token | It appears that the users' tokens have expired. |
Invalid payload size | Make sure the combined size of the payload data within a message doesn't exceed APNS limits, typically set at 4096 bytes. You might need to reduce the number of key-value pairs you're including to stay within this limit. |
BadCollapseId | The collapse identifier surpasses the maximum permitted size. |
BadDeviceToken | The token shared with Netcore Cloud was incorrect or invalid. Ensure that the request contains a valid token that matches the environment. |
BadMessageId | The specified value for "apns-id" is incorrect. |
BadPriority | The specified value for "apns-priority" is incorrect. |
DeviceTokenNotForTopic | The device token doesn't correspond to the specified topic. |
DuplicateHeaders | Some headers were duplicated in the request. |
MissingDeviceToken | This message typically refers to a missing device token within the request path. It's crucial to ensure that the designated path header contains the necessary device token for the intended operation to be carried out successfully. |
MissingTopic | This error suggests that the request lacks the essential "apns-topic" header. When a client connects using a certificate that supports multiple topics, providing this header becomes mandatory. It ensures that the request is properly identified and processed within the APNS system. |
BadCertificate | This error usually arises when the certificate used for authentication during the push notification process is corrupted or not valid. |
Unregistered | This message indicates that the device token is no longer active. This typically happens when app has been installed from the device. |
InternalServerError | An internal server error indicates that something went wrong on the server's end while attempting to fulfill a request. |
Note: you can also refer to the official APNS documentation for failure reasons.
Updated 3 months ago