如何查找Telegram机器人加入的聊天列表 python-telegram-bot

huangapple go评论62阅读模式
英文:

how to find out the list of chats in which the telegram bot is a member python-telegram-bot

问题

I am a telegram bot for administering channels, how can I get a list of all channels in which the bot is or is an administrator using the bot?
I use python-telegram-bot v20

So far, it turns out only to get the id of the channel in which the correspondence is directly received.

我是一个用于管理电报频道的电报机器人,如何使用这个机器人获取所有包含该机器人或其为管理员的频道列表?
我使用python-telegram-bot v20

到目前为止,我只能获取到直接接收到通信的频道的ID。

英文:

I am a telegram bot for administering channels, how can I get a list of all channels in which the bot is or is an administrator using the bot?
I use python-telegram-bot v20

So far, it turns out only to get the id of the channel in which the correspondence is directly received

答案1

得分: 1

Telegram Bot API中,没有从中请求该信息的方法。您必须手动跟踪。您可以使用Update.my_chat_member来实现,示例见此处


免责声明:我目前是python-telegram-bot的维护者。

英文:

There is no method to request that information from the Telegram Bot API. You will have to keep track manually. For this you can use Update.my_chat_member as showcased here.


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

huangapple
  • 本文由 发表于 2023年5月15日 03:50:24
  • 转载请务必保留本文链接:https://go.coder-hub.com/76249407.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定