davidmckenzie / telebagger

Simple Telegram to Discord one-way relay service
The Unlicense
31 stars 14 forks source link

telebagger

Simple Telegram to Discord one-way relay service. Uses the Discord-Webhooks and Telethon libraries.

Monitors a specified Telegram channel and relays any messages received in that channel to a Discord webhook. Designed to run as a human user for channels where bots are not permitted.

Installation

pip install telethon

Then copy config.example.json and set the fields accordingly.

Once config is set up, simply run:

python3 telelooper.py

For autorestarts, use pm2:

pm2 start telelooper.py --interpreter=python3

Telelooper vs Telebagger

Telelooper retrieves unread messages manually every few seconds, while Telebagger relies on Telethon's events. Telethon's events can be unreliable for supergroups, many missed messages can be expected. I would recommend using the telelooper.py script over the telebagger.py script unless you have a pressing need to use events.