Can we run the ACTION program programmatically in the notification service from the notification listening service?

Is it possible to programmatically activate ACTION in a notification from the NotificationListenerService? I wrote a Notification Listener service that reads all incoming notifications and fires when this is done. But I'm not sure if we can take any action on incoming notifications.

For example: In the WhatsApp message notification, I can read the package name, sender and message information, but is there a way to send a response to the sender? Android Wear is currently doing this, so I am wondering if it should follow the general approach that applies to notification, or does it have a specific API for the WhatsApp service.

+4
source share
2 answers

When ever a whatsapp notification was received through the listerner notification service, there is one other notification that was received (hidden) that has a tag value something like this: XXXXXXX@s.whatsapp.net (xxxxxxx is a phone number), I think it’s somehow contains a key to send a response to this user.

I am working on a different application logic that does not require you to send answers, but I found it interesting, but I could not get enough time to test it myself.

+2
source

, . Pushbullet Android WhatsApp, Hangouts, Facebook messenger .., , , . , .

0

All Articles