L
L
Lavrenty Fedotov2017-02-20 19:51:36
Python
Lavrenty Fedotov, 2017-02-20 19:51:36

Telegram bot notifications?

I am writing a bot in Python. There is a sub.txt file where all the id's of those who entered the bot are recorded.
How to tell to take id from sub.txt and insert them into bot.send_message( ID , "hi") and send immediately?
Those. not by cron, but simply by the command to run from the bot itself and so that it inserts the id from the file itself
. Is it possible to do this?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
nllm, 2017-02-26
@lavr_fedotov

Yes it is possible.
We read the file. In a loop, we go through all the lines from the file. We send a message.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question