Learn R Programming

tuber (version 3.0.0)

set_video_thumbnail: Set Video Thumbnail

Description

Uploads a custom video thumbnail to YouTube and sets it for a video. Requires OAuth 2.0 authentication.

Usage

set_video_thumbnail(video_id, file)

Value

A list containing the response from the API.

Arguments

video_id

Character. ID of the video to set the thumbnail for.

file

Character. Path to the thumbnail image file (JPG or PNG, max 2MB).

References

https://developers.google.com/youtube/v3/docs/thumbnails/set

Examples

Run this code
if (FALSE) {
# Set API token via yt_oauth() first

set_video_thumbnail(video_id = "yJXTXN4xrI8", file = "thumbnail.jpg")
}

Run the code above in your browser using DataLab