An python bot to download Public Videos/Audios from Links in Telegram Chat/Channel.
- Note: It not only works for Youtube, but support a lot of sites. It downloads in webm format from youtube. Basically this downloader is intended to be used in telegram chats and in telegram video player.
- Audio can be downloaded from audio-only sites like sound cloud.
This bot is make specifically for one purpose. That is to monitor Telegram Groups and Chats and download Public and (even private to some extent) Videos/Audios from Links in Telegram Chat/Channel.
This bot works in various steps as :
- It listens for new messages in your Telegram Groups.
- Scans for messages with URL Regex.
- Tries to download that link
- If download is done, it sends to telegram.
- Deletes that specific message only.
- This bot supports instagram login and download private posts and stories too. Highlights are not yet supported.
- Send /help command to look available features.
- Here's information about login method.
- You can get Telegram Bot Token
BOT_TOKEN
from BotFather bot on telegram.
ig_session
is your Instagram username.- You can get your instagram session file
username.session
by running this Session Generator File locally.
- While deploying place Session File in same directory of your
bot.py
and setig_session
as variable. If you don't want logins, just leaveig_session
variable empty in environment variable field.
Download Python From here :
While installing, tick install path / environment variables whatever is given
- Install required python modules using commands below:
pip install python-telegram-bot --pre
pip install yt-dlp
pip install ffmpeg
pip install requests
pip install instaloader
- Install all above modules using :
pip install -r requirements.txt
- Install Python, PIPs using above methods
- Download all files in this repo.
- Replace variables at the top of
main.py
file with your ones, removingos.environ.get('BOT_TOKEN')
andos.environ.get('ig_session')
commands.
Type any one of the following command on terminal to run bot:
py main.py
python main.py
python3 main.py
Press the button below or at the top of this readme and insert necessary environment variables and you're done.
Distributed Under GPL or MIT License by @PrabeshAryalNP on social or @PrabeshAryal on code sites.