Skip to content

How to ignore old messages sent when the bot was offline #304

Answered by AlexWayfer
Abo5 asked this question in Q&A
Discussion options

You must be logged in to vote

I guess, it's not a question to the library. It's up to your application (bot), business logic.

Commonly, you can process these messages and response as regular (but with delay).

But… to ignore them — you have to keep some marker in application, like a start time, and compare incoming messages time with it, for example.

As I know, Telegram will forget about these pending messages after some time, maybe around 1 hour, or 24 hours.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by atipugin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants