Telegram bot on Python
This is a bot for telegram channel suggestions wrote on Python3. The main goal of the bot is to provide one-sided communication between users and administrators of the channel.
It support additional features like a anti-spam, user banning, logging, and automatic free proxy collecting. Current version of bot is synchronous and single threaded.
Use the package manager pip3 to install foobar.
pip3 install pyTelegramBotAPI
pip3 install SQLAlchemy
pip3 install loguru
# for proxy support
pip3 install aiohttp
pip3 install proxybroker
$ python3 ./bot_orm/orm_model.py
Now you need to get your channel id. Bot will send all from users to it.
TOKEN = '123456789:FORE_EXAMPLE_hqzNIrx6hXTG5pMmCx00uh3w'
$ python3 ./run.py
OUT_CHANEL_ID = -1234567890
In case of no errors bot will redirect content (images, gifs, links) to your channel.
$ python3 ./run.py
if __name__ == '__main__':
while True:
logger.info('Starting new iteration of main')
try:
main(use_proxy=True, refresh_proxy_list=True)
except Exception as e:
logger.critical(repr(e))
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.