Jipok / TelegramRetranslator

telegram client (telethon) that forwards all messages from the selected channels/chats to another one
MIT License
12 stars 3 forks source link
bot client python relay retranslator telegram telethon

Retranslator

Telegram client that forwards all messages from the selected channels/chats to another one

Installation

  1. Need python 3.5 or higher
  2. pip3 install telethon
  3. wget https://raw.githubusercontent.com/Jipok/TelegramRetranslator/master/retranslator.py
  4. Register app on my.telegram.org
  5. Change the API_HASH and API_ID in the script to values from my.telegram.org

Run

  1. python3 retranslator.py

or

chown +x ./retranslator.py
./retranslator.py
  1. Log in
  2. Open normal telegram client
  3. Find a chat with the retranslator bot. There should be a list of dialogs with their id.
  4. Select the channel/chat id where the messages will be forwarded.
  5. Select the id of chats and channels from where messages should be forwarded.
  6. Selecting same id again will remove chat/channel from forwarding.

Multiple accounts

The script saves two files:

You can give the script another profile name:

python3 retranslator.py another_name
# or
./retranslator.py another_name

SOCKS5 proxy

  1. pip install pysocks
  2. Uncomment 5th line
  3. Uncomment the 34th line and specify the proxy server