/download_youtube

Telegram bot for downloading video from YouTube

Primary LanguagePythonMIT LicenseMIT

Download video from YouTube

Description

You can download videos from YouTube using my telegram bot. You should only send a link to the video.
This is my second telegram bot. I learned how to create them on the Coursera course




















How to use

1. command /start - displays a welcome message
2. command /help - displays information on all available commands
3. If you send a text message, the bot will think that you have sent a link and will try to download the video, but will not be able to do so. What it will tell you in a reply message
4. The same will happen with links not on YouTube videos
5. If you send a link to a YouTube video, the bot will offer you options for downloading formats. Once you select the format the bot will start downloading the video and then sending it to you

About the project

- The bot is written in Python 3.9.4
- To interact with the Telegram API, I use the pyTelegramBotAPI library
- To download videos from YouTube, I use the pytube library

Project setup

git clone https://github.com/VITca64rus/download_youtube
pip install -r requirements.txt

In telegram_bot.py change 'YOUR_TOKEN' on 5 line

python telegram_bot.py