A
A
AYKostarev2020-07-09 11:01:35
Python
AYKostarev, 2020-07-09 11:01:35

Can a Telegram bot send a message to a person with whom they have not corresponded before?

In general, it is necessary to make a bot that sends a message to users who have joined the channel. Just send_message(user_id, 'text') doesn't work - it throws a 'chat not found' error. I work with PyTelegramBotApi, but if you can solve it using some other library, it's also okay.
Thank you!

Answer the question

In order to leave comments, you need to log in

4 answer(s)
D
Dr. Bacon, 2020-07-09
@bacon

A bot can't "send a message to a person they haven't corresponded with before". This is a Telegram limitation, not a library one.

R
robprane, 2020-07-09
@robprane

No, he can not. The user must be the first to start a conversation with the bot.

D
Dimonchik, 2020-07-09
@dimonchik2013

the bot can't spam, they spam differently

Z
zeetabit, 2020-07-10
@zeetabit

the bot cannot, but the client library (which works like a regular messenger via the telegram api, NOT the bot api) can

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question