A
A
Ant_onio2020-09-11 13:56:40
Python
Ant_onio, 2020-09-11 13:56:40

How to send content to a telegram bot in a group?

The problem is that the bot in telegram groups does not process content except for direct commands through "/"
Task: each user in the group can send a video message, video, and the bot must process this case. I managed to get the bot to react to sending a video as a replay to any bot message, which is not very convenient and in this case there is no information about the sender in the chat object (message.chat.user_name == None).
Hence the question: how can I make the bot process any message in the chat, or somehow indicate that the sent video is addressed to the bot?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
G
german levi, 2020-09-11
@Ant_onio

if the bot is an admin in a group, then as far as I remember, all messages in the group are available to him.

L
Lesha, 2020-09-11
@hydrugz

how can I make the bot process any message in the chat

What about t.me/BotFather ?
- /setprivacy
- 'Enable' - your bot will only receive messages that either start with the '/' symbol or mention the bot by username.
'Disable' - your bot will receive all messages that people send to groups.
Current status is: DISABLED

https://core.telegram.org/bots#privacy-mode

S
soremix, 2020-09-11
@SoreMix

No code? There will be no used libraries?
https://github.com/eternnoir/pyTelegramBotAPI#mess...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question