Skip to contents

Posts a new top-level comment on a YouTube video. Requires OAuth 2.0 authentication. YouTube no longer accepts comments on a channel itself, so a video is required.

Usage

post_comment(video_id, channel_id = NULL, text)

Arguments

video_id

Character. ID of the video to comment on.

channel_id

Character. Optional ID of the channel that owns the video.

text

Character. The text of the comment.

Value

A list containing the API response.

Examples

if (FALSE) { # \dontrun{
# Set API token via yt_oauth() first

post_comment(video_id = "yJXTXN4xrI8", text = "Great video!")
} # }