
Hey y'all, I'm attempting to set up push notifications with FCM and Flutter. When trying to send a test push notification from the console, I keep running into this issue:
Failed sending to target ddgO4iC2_U7ciAA_6vHPmv:...8czMdeVU with error: Expired device token.
Alternatively, I've also seen an error ending with this one twice:
with error: Request contains an invalid argument.
Here is the code where I enable messaging:
FirebaseMessaging.instance.getToken().then((token) async {
if (token == null) {
return;
}
await account.createPushTarget(
targetId: ID.unique(),
identifier: token,
providerId: '661e90e9001427890121');
});```
At least in the console, the target is successfully being registered.
For firebase setup, I followed these docs:
https://firebase.google.com/docs/flutter/setup
https://firebase.google.com/docs/cloud-messaging/flutter/client
Appwrite selfhosted server version: `1.5.4`
appwrite SDK version: `12.0.1`
Recommended threads
- Unable to create push providers - FCM or...
Currently unable to create a push provider for FCM or APNS.... https://github.com/appwrite/console/issues/2045 When uploading a file... FCM = Valid file retu...
- 1.7.0 Self Hosted Upgrade
Hi, I've tried a fresh install on 1.7.0 and I've also done a fresh install on 1.6.2. 1.6.2 is working fine fresh, update to 1.7.0 and migrate fails Fresh inst...
- Functions not work on Server only Localh...
Hi, I successfully upgraded from 1.4 to 1.7, but I'm having a problem. The functions no longer work with the settings I had. I assume some changes were made. It...
