What is the event for when you "like" a message? #1195
-
Hello, I'm writing a bot connected to an AI Api. I would like to have an event like Closest thing I could read from the documentation is https://core.telegram.org/bots/api#setmessagereaction Kind regards, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Telegram Updates Events: https://core.telegram.org/bots/api#update You need to listen the "message_reaction" event. Example of use: const TelegramBot = require('node-telegram-bot-api');
const bot = new TelegramBot(TOKEN, {
polling: {
params: {
"allowed_updates": JSON.stringify(["update_id", "message", "edited_message", "channel_post", "edited_channel_post", "inline_query", "chosen_inline_result", "callback_query", "shipping_query", "pre_checkout_query", "poll", "poll_answer", "my_chat_member", "chat_member", "message_reaction"])
}
}
});
bot.on('message_reaction', (msg) => {
const chatId = msg.chat.id;
console.log(msg);
bot.sendMessage(chatId, 'Received your reaction message');
}); |
Beta Was this translation helpful? Give feedback.
Telegram Updates Events: https://core.telegram.org/bots/api#update
You need to listen the "message_reaction" event.
Example of use: