termux / termux-api

Termux add-on app which exposes device functionality as API to command line programs.
https://f-droid.org/en/packages/com.termux.api/
2.08k stars 430 forks source link

Reply to notification #551

Open babaric-dev opened 1 year ago

babaric-dev commented 1 year ago

Feature description

I hope termux api can reply to notifications (i.e. whatsapp) and there are already bots doing so. So i think it shouldnt be that hard to implement

Nonetheless, the implementation may be useful for automation or bots

Reference implementation

Have you checked if the feature is accessible through the Android API? Do you know of other open-source apps that has a similar feature as the one you want? (Provide links)

2096779623 commented 1 year ago

Duplicate of #538 .

HusniMuhammad commented 10 months ago

you can use this command

termux-notification --button1 "Answer" --button1-action "termux-toast \$REPLY"

If you're click reply button. The termux-toast will be appeared according to the command

Screenshot_20230906-172956

For more information about termux-notification

termux-notification -h

information about actions eg: --button1-action

termux-notification --help-actions

If it's works please close this issue