/gmail-label-to-yt-playlist

Gmail label to youtube playlist

Primary LanguagePython

Make a youtube playlist from a gmail label

Getting Started

This script will login to gmail and read all emails with a specified label. It will then use regex to find a youtube video ID in the body and then use that ID to post the video to a playlist.

Used to grab all the unlisted patreon video links in my email for KF games.

Prerequisites

  • Python 3.6+ (uses f strings)
  • API Access to gmail and youtube (link below to get started)
  • Gmail label set up for emails to be searched
  • Youtube playlist created and ID copied

Setup

Google API Setup

  1. Follow the intial setup guide at the Google developers page here: https://developers.google.com/gmail/api/quickstart/python

Note Section

https://developers.google.com/gmail/api/quickstart/python