TubeFetch is a Discord bot that allows users to download YouTube videos directly from Discord, with support for video quality selection, subtitle downloads, and large file handling.
- Slash Commands for a modern Discord experience
- Choose video quality (e.g., 360p, 720p, best, worst)
- List available qualities and subtitles for any YouTube video
- Download subtitles in your preferred language
- Handles Discord file size limits: uploads large files to transfer.sh and provides a temporary download link
- Ephemeral responses for privacy
- Robust error handling and file cleanup
/fetch url:quality: subtitles: language: t; language:<lang> - Download a YouTube video at the specified quality and (optionally) subtitles.
/qualities url:RL> - List available video qualities for a YouTube link.
/subtitles url:RL> - List available subtitle languages for a YouTube link.
/help- Show help and usage instructions.
git clone https://github.com/yourusername/TubeFetch.git
cd TubeFetchpip install -r requirements.txt- Create a
.envfile in the project root:TOKEN=your_discord_bot_token_here
python3 bot.py- If a video is too large for Discord, TubeFetch will upload it to transfer.sh and provide a temporary download link (valid for 14 days).
- The bot introduces itself when joining a new server.
- All commands are slash commands for ease of use.
MIT License
Pull requests and suggestions are welcome! Please open an issue or submit a PR.
- yt-dlp for YouTube downloading
- discord.py for Discord integration
- transfer.sh for temporary file hosting
Enjoy downloading YouTube videos right from your Discord server!