Issue
While sending the notification and when my application is in the foreground, i am getting the notification with the action buttons in the notification, while when my application is killed or in background the notification is coming but without the action button, i am getting just the title and content body. I have tried many solution but it does work. Is android have new permission issues are introduced? Any help and suggestion will be appreciated.Here is the Image
Solution
As there's no any code provided I can't say what's the specific issue here, butt keep in mind. In FCM there are 2 types of notifications:
- Notification payload
- Data payload
When you send a notification from FCM, it is a notification payload. In this case if your app is killed, the notification will go directly to the system tray and will be handled by the OS. The onMessageReceived()
won't execute.
If you send the notification from the backend side, it's a data payload. In that case the onMessageReceived()
will be executed.
Check more here FCM Message Types
Answered By - Hayk Mkrtchyan
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.