0

Below is the payload of notification i am sending

"notification":{
     "title":"title",
     "body":"message",
     "sound": "default",
     "click_action":"11" 
     },
     "data": {
         "data":{
             "title":"title",
             "message":"message",
             "type":3,
         }
    }

i am send click_action 11 for which i have already defined DarwinNotificationCategory with 2 actions as follows

final List darwinNotificationCategories = [ DarwinNotificationCategory( '11', actions: [ DarwinNotificationAction.plain( 'apply', 'Apply', options: { DarwinNotificationActionOption.foreground, }, ), DarwinNotificationAction.plain( 'save', 'Save', options: { DarwinNotificationActionOption.foreground, }, ), ], ), ];

when i recieve the remote notification on ios actions are correctly being displayed and on tap of notification i am getting callback in onMessageOpenedApp() but i am not able to identify which action was clicked by user. How can i handle this?

i am only getting RemoteMessage Object but the action clicked is not received

Md. Ibrahim Hassan
  • 5,359
  • 1
  • 25
  • 45

0 Answers0