Skip to content

This async handler uses the pytube library to fetch detailed information about a YouTube video URL sent by a user in Telegram. It replies with the video's thumbnail, title, duration, and view count, and attempts to send a playable video stream directly in the chat. If sending the video fails, it gracefully falls back to sending the direct stream ..

License

Notifications You must be signed in to change notification settings

abdellahaarab/Python-telegram-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Enterprise

Python Telegram Bot

A simple Telegram bot built with Python to download YouTube videos and provide related functionalities.


🚀 Cloning from GitHub

  1. Open your terminal and run:

    git clone https://github.com/abdellahaarab/Python-telegram-bot.git
  2. Navigate into the project folder:

    cd Python-telegram-bot
  3. Install the required dependencies:

    pip install -r r.txt
  4. Run the bot:

    python main.py

⚙️ Configuration

  1. Open the project in your favorite text editor.

  2. Create or edit the .env file and add your Telegram bot token as:

    token="your_token_here"

📊 Project Statistics

Python Version Issues Forks Stars License Contributors Repository Size


☕ Required Python Packages

Make sure to install the following Python packages to run the bot smoothly:

pip install python-telegram-bot
pip install pyTelegramBotAPI
pip install pytube
pip install pytube3

About

This async handler uses the pytube library to fetch detailed information about a YouTube video URL sent by a user in Telegram. It replies with the video's thumbnail, title, duration, and view count, and attempts to send a playable video stream directly in the chat. If sending the video fails, it gracefully falls back to sending the direct stream ..

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages