Meghar
Meghar

Reputation: 15

How to gather all chats a Telegram bot is an admin of?

How is it possible to get all chats in the form of a iterabale object (list-like) or iterate over all possible chats the bot is an admin/participant of (using python-telegram-bot)? Is there a python-telegram-bot method for getting all chats a bot is a admin/participant of?

Upvotes: 0

Views: 825

Answers (1)

CallMeStag
CallMeStag

Reputation: 7020

No, there is not, because the Telegram Bot API does not provide such a method. You can use the Update.my_chat_member updates to keep track of that. See here for an example on how that can be done using python-telgeram-bot.


Disclaimer: I'm currently the maintainer of python-telegram-bot.

Upvotes: 1

Related Questions