bots.setBotMenuButton #

Sets the menu button action » for a given user or for all users

Layer 223

boolFalse#bc799737 = Bool;
boolTrue#997275b5 = Bool;
---functions---
bots.setBotMenuButton#4504d54f user_id:InputUser button:BotMenuButton = Bool;

Parameters #

NameTypeDescription
user_idInputUserUser ID
buttonBotMenuButtonBot menu button action

Result #

Bool

Only bots can use this method #

Possible errors #

CodeTypeDescription
400BUTTON_INVALIDThe specified button is invalid.
400BUTTON_TEXT_INVALIDThe specified button text is invalid.
400BUTTON_URL_INVALIDButton URL invalid.
400USER_BOT_REQUIREDThis method can only be called by a bot.

Bot menu button #

Bots can choose the behavior of the menu button shown next to the text input field.