Random YouTube video generator script using YouTube Data API v3 written in Python.
Due to its query parameter this script fetches low viewed (0 - 250 views) YouTube video IDs oftenly.
Default Search Query: Prefix (IMG) + Random Integer (999-9999) + Postfix (MOV)
You can change its parameter to whatever you want.
Google Developer Key for YouTube
DEVELOPER_KEY = 'YOUR_DEVELOPER_KEY'
Sign up and change with your own developer key: https://console.developers.google.com
Google APIs Client Library
pip3 install --upgrade google-api-python-client
> random-youtube-video.py
> 0CGyCMzi1l8
Now you can use this video ID as "https://www.youtube.com/watch?v=0CGyCMzi1l8"
Change the ID parameter with your output: "https://www.youtube.com/watch?v=ID"