Answer the question
In order to leave comments, you need to log in
How to correctly set a welcome message for a Telegram bot?
Hello. I am writing a bot for telegram. I noticed that for all bots, when the message "/start" is displayed, a list of available commands is displayed. Can this be somehow set in the settings via BotFather? Or should I write something like this?
const TelegramBot = require('node-telegram-bot-api'),
token = '',
app = new TelegramBot(token, {polling:true});
app.on('message', (msg) => {
switch(msg.text) {
case '/start':
//здесь код для отправки сообщения, содержащего все команды
break;
};
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question