Firebase通知 - 注册令牌无效,请在Android中检查令牌格式 [英] Firebase Notifications - Invalid reg token, please check token format in Android
问题描述
注册令牌无效,请检查令牌格式
错误快照:
[] [1]
Firebase消息的注册标记。通过 Firebase文档:
在您的应用程序初始启动时,FCM SDK为客户端应用程序实例生成注册令牌。如果您想定位单个设备或创建设备组,则需要通过扩展FirebaseInstanceIdService来访问此令牌。
我上一次注册令牌看起来像
cpeBAc1NkUE:APA91bEpAKHQTdgkWVdDzDZG8BPon0APaIhbbuSejDpZF-FO1gD2saDV7_EQDo2WEz0H6e5U-uf0i-v4b25NXgGzV2oUrNuboM5675WY7VCP3JcBl8BCNY7eV0VFGHT9oRox0EEoo_ch
![enter image description here][1]
If I send push message by selecting a package from Firebase console, the push goes to all devices, but during sending to individual device, it displays the error:
Invalid reg token,please check token format
Error Snapshot:
[][1]
UserID in console is not the registration token for Firebase messaging. By Firebase docs:
on initial startup of your app, the FCM SDK generates a registration token for the client app instance. If you want to target single devices or create device groups, you'll need to access this token by extending FirebaseInstanceIdService.
My last registration token looks like cpeBAc1NkUE:APA91bEpAKHQTdgkWVdDzDZG8BPon0APaIhbbuSejDpZF-FO1gD2saDV7_EQDo2WEz0H6e5U-uf0i-v4b25NXgGzV2oUrNuboM5675WY7VCP3JcBl8BCNY7eV0VFGHT9oRox0EEoo_ch
这篇关于Firebase通知 - 注册令牌无效,请在Android中检查令牌格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!