I want to achieve a custom notification behavior like WhatsApp or any other app where users can interact with the notification in-tray, type a message and send it indirectly from there.
So, far I have been successful to show a custom notification with 2 buttons when the app is in the foreground. I achieved this by simply showing a custom notification when I get control in the firebase service's onMessageReceived() function.
According to my research and work, you do not get control in the service when app is in background or killed state.
So, the question is how do you achieve this? I want to show notification with a title, body, and 2 buttons. Upon clicking the buttons, I want to do 2 different tasks i.e calling APIs by opening the app.
Any help would be appreciated.