Downloading Bilibili videos is very simple, just one line of command with you-get. But I'm so lazy that I don't even want to type the command. It would be great if NAS could download it by itself after throwing a coin.
Bilibili's favorite list is full of invalid videos. I want to create a small tool that automatically downloads favorites after being added. 🤔
— DIYgod (@DIYgod) May 24, 2019
RSS+IFTTT+Webhooks+ffmpeg?
Concept#
The whole concept is like this: Coin throwing -> RSS update -> IFTTT triggers Webhook -> Server downloads.
Coin throwing to RSS update can be directly implemented using RSSHub. RSS update to triggering Webhook can also be configured directly in IFTTT. The only missing part in this whole domino is from Webhook to download.
Action#
So I wrote a simple tool - download-webhook. It can trigger the server to execute you-get and download videos to the specified directory through a simple post request.
Result#
- Throw a coin to the Biting Cat
- RSS update
- IFTTT triggers
- download-webhook receives download request
- Download completed
Further#
The above also applies to automatically downloading YouTube, Instagram, Tumblr videos, Netease Cloud Music songs, etc., as long as RSSHub and you-get support it.
In addition, for images, you can directly pass the image address as a parameter in the Webhook URL to download it. So it is also easy to automatically download Bing's daily wallpapers, or even Telegram's NSFW channels (I won't recommend it here).