Reputation: 76
I am trying to integrate Firebase Cloud Messaging into an ongoing project. I followed the guide for installation here and installed both @react-native-firebase/app and @react-native-firebase/messaging.
However, when I attempt to get device token with await messaging.getToken()
it fails with this warning -NativeFirebaseError: [messaging/unknown] MISSING_INSTANCEID_SERVICE
Please note that if I send a push notification from firebase console, it gets delivered on a real phone, which shows that the issues is probably not with the FCM set up.
Any helpful suggestions will be appreciated
Upvotes: 5
Views: 6115
Reputation: 124
If you're using a Huawei device, you might encounter this error.
Upvotes: 1
Reputation: 115
is emulator have you installed google play??? cause the device cannot generate token without google play. in geymotion: To install, see https://stackoverflow.com/a/20137324/2234894
Upvotes: 9