Skip to content

RuslanUC/TelegramFTP

Repository files navigation

Telegram-FTP

Use telegram as ftp storage.

Based on aioftp server and pyrogram.

Enviroment variables you need to set:

API_ID: Go to my.telegram.org to obtain this.

API_HASH: Go to my.telegram.org to obtain this.

BOT_TOKEN: Get the bot token from BotFather.

MONGODB: MongoDB connect string.

CHAT_ID: Chat id to send files to.

HOST: FTP server host (default: 0.0.0.0).

PORT: FTP server port (default: 9021).

Setup:
  1. Create bot in BotFather.
  2. Obtain API_ID and API_HASH on my.telegram.org.
  3. Create mongodb database on MongoDB Cloud (or use your server) and copy connect string.
  4. Insert all variables into .env
  5. Add bot to your channel with admin rights.
  6. Run get_channel_id.py, send /id command in your channel.
  7. Copy id to .env
  8. Create mongodb database named ftp.
  9. Run setup_database.py.
  10. Run accounts_manager.py to create accounts.
  11. Disable your ftp client timeout.
  12. Run main.py.

About

Use telegram as ftp storage.

Resources

License

Stars

Watchers

Forks

Languages