I want to upload a video to youtube using javascript. Currently, I can login and get the list of the videos, but I do not know how to write the snippet to upload files.
I used google js api Link1 and youtube v3 api Link2
var requestOptions = {
playlistId: playlistId,
part: 'snippet',
myRating:'like',
maxResults: 1
};
var request = gapi.client.youtube.videos.insert(requestOptions);
I am using the above code to get video list items, but not sure how to continue to upload a video.