I was never satisfied with any YouTube downloader solution, because they either required chasing some website that was either bloated with ads, painfully slow, taken down the next day or all of those combined. Using youtube-dl in the command line was my go-to, but doesn't really work great on mobile.
So I made this bot, to have the videos right on the platform where I'd send them anyway, fast and effortless.
It uses ytdl-core under the hood to get the stream URL of YouTube videos, because from my testing it proved substantially faster then youtube-dl. The bot then takes the highest-quality stream URL that combines audio and video (usually 720p) and gives it directly to telegram, so that it's never downloaded to my server, which greatly improves speed.
TikTok support was also added using youtube-dl.
This is designed to be as easy and fast as possible: Just send a YouTube or TikTok link to the bot.
Thats it! The bot may ask you if you want your YouTube video in mp3 or mp4 format, but it downloads both in the background right away.
I am open to contributions. Just clone the repo and run two commands to get started:
npm ci
and
npm run dev
Make sure to include your bot credentials in the .env file or as environment variables.