CommentThreads
Stay organized with collections
Save and categorize content based on your preferences.
A
commentThread
resource contains information about a YouTube comment thread, which comprises a top-level comment and replies, if any exist, to that comment. A
commentThread
resource can represent comments about either a video or a channel.
Both the top-level comment and the replies are actually
comment
resources nested inside the
commentThread
resource. The
commentThread
resource does not necessarily contain all replies to a comment, and you need to use the
comments.list
method if you want to retrieve all replies for a particular comment. Also note that some comments do not have replies.
Methods
The API supports the following methods for
commentThreads
resources:
- list
- Returns a list of comment threads that match the API request parameters.
Try it now
.
- insert
- Creates a new top-level comment. To add a reply to an existing comment, use the
comments.insert
method instead.
Try it now
.
Properties
The following table defines the properties that appear in this resource:
Properties
|
kind
|
string
Identifies the API resource's type. The value will be
youtube#commentThread
.
|
etag
|
etag
The Etag of this resource.
|
id
|
string
The ID that YouTube uses to uniquely identify the comment thread.
|
snippet
|
object
The
snippet
object contains basic details about the comment thread. It also contains the thread's top-level comment, which is a
comment
resource.
|
snippet.
channelId
|
string
The YouTube channel that is associated with the comments in the thread. (The
snippet.videoId
property identifies the video.)
- If the comments are about a video, then the value identifies the channel that uploaded the video. (The
snippet.videoId
property identifies the video.)
- If the comments refer to the channel itself, the
snippet.videoId
property will not have a value.
|
snippet.
videoId
|
string
The ID of the video that the comments refer to, if any. If this property is not present or does not have a value, then the thread applies to the channel and not to a specific video.
|
snippet.
canReply
|
boolean
This setting indicates whether the current viewer can reply to the thread.
|
snippet.
totalReplyCount
|
unsigned integer
The total number of replies that have been submitted in response to the top-level comment.
|
snippet.
isPublic
|
boolean
This setting indicates whether the thread, including all of its comments and comment replies, is visible to all YouTube users.
|
replies
|
object
The
replies
object is a container that contains a list of replies to the comment, if any exist. The
replies.comments
property represents the list of comments itself.
|
Except as otherwise noted, the content of this page is licensed under the
Creative Commons Attribution 4.0 License
, and code samples are licensed under the
Apache 2.0 License
. For details, see the
Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2022-11-04 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples / code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]