cotestatnt / AsyncTelegram2

Powerful, flexible and secure Arduino Telegram BOT library. Hardware independent, it can be used with any MCU capable of handling an SSL connection.
MIT License
83 stars 25 forks source link

Feature Request: Bot Command Scope #104

Closed tsmith111992 closed 10 months ago

tsmith111992 commented 1 year ago

I was looking through the code and did not see a way to set the command scope. Was hoping that this might be a feature that could be incorporated.

Thanks

henkjannl commented 1 year ago

Hi,

I'm not sure if this is what you are looking for, but I was looking for how to set the default commands and found that this is working:

myBot.setMyCommands("/start", "start new session"); myBot.setMyCommands("/help", "get help");

You can call the function multiple times to add additional commands. Hope this helps.

@cotestatnt may be good to add a line in the readme for this. I was trying to submit two JSON lists to the function until I found out it is much simpler :-)