setMyCommands
Updates or replaces a Telegram bot's command list for a chosen scope and language, returning true on success.
Instructions
Use this method to change the list of the bot's commands. See https://core.telegram.org/bots/features#commands for more details about bot commands. Returns True on success.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"commands": "<commands>"
},
"name": "setMyCommands"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scope | No | An object, describing scope of users for which the commands are relevant. Defaults to BotCommandScopeDefault. | |
| commands | Yes | A list of bot commands to be set as the list of the bot's commands. At most 100 commands can be specified. | |
| language_code | No | A two-letter ISO 639-1 language code. If empty, commands will be applied to all users from the given scope, for whose language there are no dedicated commands. |