A
A
Azaaaaaaaaaaaaa111112021-11-13 16:22:42
JavaScript
Azaaaaaaaaaaaaa11111, 2021-11-13 16:22:42

How to get data from telegram bot inline button?

Hello. I am using Telegraf.js to create a food ordering bot. The task is this, the client entered the bot, then clicked on the menu and selected Burgers, the bot sends him 2 posts with Pictures of burgers and a description, from the bottom of each post there are Inline buttons attached, by clicking which the client specifies the size. The question is how to find out which inline button the user clicked,

3

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
ambal245, 2021-11-15
@ambal245

Set a parameter in the callback_query button and then catch the click in $data['callback_query']['data'] and display the required information.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question