Reputation: 1
I am developing a python telegram bot app, and need to close or hide an inline keyboard with a set of InlineKeyboardButton, once the user clicks on one of them, because if any button is clicked later, my app is not in the same context and the response is not appropriate.
I did not find a comprehensive way to make this. I saw how it can be done with custom keyboards and one time use parameter. How could I handle this with inline keyboards?
Upvotes: 0
Views: 5955
Reputation: 1438
You can use editMessageReplyMarkup method.
Use this method to edit only the reply markup of messages.
Just omit reply_markup
parameter. This will effectively hide/delete your inline keyboard.
Upvotes: 1