962 B
962 B
How to use the script
Installation of the libraries
Create a venv:
$ python -m venv api
Activate the venv:
$ source ./api/bin/activate
Install the following libraries:
# Google APIs Client Library for Python
(api) $ pip install --upgrade google-api-python-client
# The google-auth-oauthlib and google-auth-httplib2 libraries for user authorization.
(api) $ pip install --upgrade google-auth-oauthlib google-auth-httplib2
Now we're all set!
Usage of the script
*The following command assumes that you own a YouTube channel with some playlists.
In a terminal with the api
venv activated, type:
(api) $ python youtube_api.py channel video_ID
where playlist_name
is the name of the playlist where you want to insert the
video video_ID
.
A new browser instance will pop up where you will have to identify yourself and
follow the instructions. Use username
, password
and phone number
from
my_credentials
.