Below you will find pages that utilize the taxonomy term “Code”
Building a YouTube-Twitter Bot, Part 3: Checking for New Video and Tweeting Link
At the end of the last post I mentioned that I might put these posts on hold for until 2021. While posts were on hold, the development was not; at least not until just before Christmas. The bot is actually live and tweeting!!! Please go follow it, it’s called @YTBotbyPS. YouTube Bot by princelySid is where the name comes from.
The problem with coming back to writing is that you’ve forgotten almost everything you did to get to the point you’re now at, development-wise, and you have your editor leave messages like this on the post you started but didn’t finish
Building a YouTube-Twitter Bot, Part 2: Extracting List of New Uploads
To recap, we’re building a bot that given a list of YouTube channels, it’ll tweet out snippets of a newly posted video. Below is the list of planned activities:
- Get list of my subscriptions from YouTube.
- Mark channels as music or blog and whether they’re Kenyan.
- For each channel get a list of recent videos and store that in a database.
- Take the last video link and download the video.
- Clip the video to 40s.
- Tweet that video (title, link to YouTube)
- Save link to tweet, video in database
- Check every 30 minutes if there’s a new video, if yes start from 4.
In the previous post we managed to get the data from YouTube and save it into a csv file. I’ve subscribed to over 900 channels; a rather ridiculous number of channels I’ve been told.
Building a YouTube-Twitter Bot, Part 1: A List of Subscriptions
To recap, I am building a bot that given a list of YouTube channels it’ll tweet out snippets of the videos when a new one is posted. In the previous post, I had a list of the things we need to do to get there:
- Get list of my subscriptions from YouTube.
- Mark channels as music or blog.
- For each channel get a list of recent videos and store that in a database.
- Take the last video link and download the video.
- Clip the video and clip it to 40s.
- Tweet that video (title, link to Youtube)
- Save link to tweet, video in database
- Check every 30 minutes if there’s a new video, if yes start from 4.
Today we’ll be looking at the first one: getting a list of subscriptions from YouTube.
Building a YouTube-Twitter Bot, Part 0: The Idea
One of my passions in life is finding and consuming great Kenyan content: text, video, audio; doesn’t matter much to me. In a bid to keep abreast with this content, I subscribe to all the Kenyan content I can find on YouTube. However, keeping up with all of this has been difficult.
A combination of algorithmic feeds and an overwhelming amount of content means that I miss out on a lot content. I only have so many hours in a day and I have a full time job.