@Cole Xia (Shanghai Wicresoft Co,.Ltd.) I downgraded the plugin and i was able to get the token.
However, the iOS app does not receive them.
I sent a notification thru Postman and it completed successfully:
{
"multicast_id": 4267051523857827808,
"success": 1,
"failure": 0,
"canonical_ids": 0,
"results": [
{
"message_id": "0:1612045674651933%9166abc09166abc0"
}
]
}
But the app did not fire the received notification event.
On the other hand, in the output window I got this log:
[Firebase/Messaging][I-FCM002019] FIRMessaging received data-message, but FIRMessagingDelegate's-messaging:didReceiveMessage: not implemented
But i did implement that method as per instructions:
// To receive notifications in foregroung on iOS 9 and below.
// To receive notifications in background in any iOS version
public override void DidReceiveRemoteNotification(UIApplication application, NSDictionary userInfo, Action<UIBackgroundFetchResult> completionHandler)
{
// If you are receiving a notification message while your app is in the background,
// this callback will not be fired 'till the user taps on the notification launching the application.
// If you disable method swizzling, you'll need to call this method.
// This lets FCM track message delivery and analytics, which is performed
// automatically with method swizzling enabled.
FirebasePushNotificationManager.DidReceiveMessage(userInfo);
// Do your magic to handle the notification data
System.Console.WriteLine(userInfo);
completionHandler(UIBackgroundFetchResult.NewData);
}
I really do not understand what to do to make this work...