Please tell me where to dig. I am trying to implement a task like the @entrytodoctorBot bot. Very interested in the implementation of the functional, namely:

  1. scrolling back and forth without additional output
  2. insert data in the right place- inlinebutton "get the schedule"

Thank you in advance.

1 answer 1

Generally speaking, this scrolling is implemented by editing the buttons on the message when you click on the arrow.

When you handle the callback by clicking on the scroll button, use the editMessageReplyMarkup method to change the layout of the buttons below the message. You must first organize the keyboard so that the y scrolling buttons in the callback_data fields will encode the page number to open.

This is in brief. Unfortunately, the more accurate answer will depend on the architecture of your bot and on the chosen library for interacting with the API.