tdlib/telegram-bot-api

Failed to forward message: 'Bad Request: message thread not found'

dxyspx opened this issue · 7 comments

Description:

I am encountering an issue with the forwardMessage API. Previously, I was able to successfully forward messages to message_thread_id. However, in the past few days, I have been receiving an increasing number of errors:

Failed to forward message: {'ok': False, 'error_code': 400, 'description': 'Bad Request: message thread not found'}.

Almost all topics are no longer receiving forwarded messages. This issue has become widespread and is impacting functionality significantly.

Please advise on how to resolve this issue.

Thank you.

Do you have more than a million messages in the target forum?

The total number of messages across all topics might exceed one million. However, each individual topic has at most around 150,000 messages. The topic with the most messages is still receiving forwarded messages. On the other hand, some topics with only a few thousand messages are already unable to receive forwarded messages.

Does this issue relate to the number of messages?

Yes, this happens when the total number of messages in the forum exceeds one million, the oldest forum messages are archived and become inaccessible.

Thank you. So, is the best solution to delete some of the forwarded messages to allow subsequent forwarding to continue working?

No, it will not help. You can only create new forum topics and stop using the old ones. Messages from the old topics will become inaccessible anyway after the new topics will have more than a million messages.

No, it will not help. You can only create new forum topics and stop using the old ones. Messages from the old topics will become inaccessible anyway after the new topics will have more than a million messages.

Thank you for helping me resolve the issue. After creating new topics, I am now able to receive forwarded messages. However, do I need to repeat this process every time the message count exceeds one million?

Yes.