1

I have some problems with command views in telegram bot. i'm using telegram.bot SDK with c# asp.net:

var keyboard = new ReplyKeyboardMarkup(new[]
            {
                new [] // first row
                {
                    new KeyboardButton("/help"),
                    new KeyboardButton("/start")
                },
                new []
                {
                    new KeyboardButton("/news"),
                    new KeyboardButton("/lots")
                }
            }, resizeKeyboard: true);

The result is a similar keyboard buttons, but i need a list of commands. like this: Want this But i cant find how to do it and have this: Have this

  • You have to add the command list manually with BotFather. Read [this answer](https://stackoverflow.com/a/34458436 "this answer") for more information. – Nicola Capovilla Jan 04 '18 at 13:57

1 Answers1

0

You can set commands from BotFather,

Or you can use SetMyCommandsAsync() and GetMyCommandsAsync() methods to edit your commands programmatically.

Muaath
  • 579
  • 3
  • 19
  • Hi Muaath , Any idea how to use SetMyCommandsAsync and GetMyCommandsAsync? It seem not work.. – Eyalk Jun 26 '21 at 16:47
  • I didn't use them. But they should work, Now some Tg clients has some errors with personalized commands. – Muaath Jul 08 '21 at 21:29
  • @Eyalk: The command must be lower case. The description can be anything. If command is not lowercase, you get 400:BAD_REQUEST – Gichamba Jul 13 '22 at 17:48