Best way to determine specific errors?
See original GitHub issueI’m trying to determine when there is an invalid token, an expired token, message rate exceeded error, etc. (https://firebase.google.com/docs/cloud-messaging/send-message#admin_sdk_error_reference).
When i send a single message/notification to a token like so:
var response = await FirebaseMessaging.DefaultInstance.SendAsync(message);
I get the following response (I’m getting this when i catch a thrown exception from FirebaseMessaging… I think i must be using this incorrectly as this seems strange… shouldn’t there be a response object?).
What am I doing that is incorrect? Shouldn’t I be able to find a code that matches to whats in the admin_sdk_error_reference section? (link i have above)
Response status code does not indicate success: 400 (BadRequest)
{
"error": {
"code": 400,
"message": "The registration token is not a valid FCM registration token",
"errors": [
{
"message": "The registration token is not a valid FCM registration token",
"domain": "global",
"reason": "badRequest"
}
],
"status": "INVALID_ARGUMENT"
}
}
Issue Analytics
- State:
- Created 4 years ago
- Reactions:6
- Comments:26 (11 by maintainers)
Top Results From Across the Web
Measurements and Error Analysis
Random errors can be evaluated through statistical analysis and can be reduced by averaging over a large number of observations (see standard error)....
Read more >Calculate Percentage Error
How to Calculate Percentage Error · Step 1. Subtract the actual value from the estimated value. · Step 2. Divide the results with...
Read more >How to Accurately Perform Basic Error Analysis
To find the percent error, find the difference between your average and the true value and divide it by the true value.
Read more >Estimation of Errors: Formulas & How to Calculate
You can estimate the errors of a measured value by comparing it to a standard value or reference value. The error can be...
Read more >ERRORS AND ERROR ESTIMATION
There may be no “best” method. Sometimes “best” is a matter of opinion. When attempting to estimate the error of a measurement, it...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@swebgit They will be released incrementally over a series of releases.
Note that the FCM APIs now support the fine-grained error handling scheme outlined above.
FirebaseMessagingException
andMessagingErrorCode
types were included in the v1.8 release. More to come.