Youtube Data Api 有 commentCount 字段,这是频道上的评论数吗? [英] Youtube Data Api has commentCount field and is this the number of comments on channel?

查看:24
本文介绍了Youtube Data Api 有 commentCount 字段,这是频道上的评论数吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Youtube Data Api v3,在统计部分有一个名为 commentsCount 的字段,我想知道这是不同用户在一个频道上发表的评论还是频道用户在多个频道上发表的评论视频.

I'm using Youtube Data Api v3 and there is a field called commentsCount in statistics section, I wanted to know if this is the comments for made by different users on a channel or is the comments made by the channel user on several videos.

例如,如果我向 Channel 4 on Demand 发送一个 HTTP 请求,其中有很多用户发表的评论,我只会得到

for example if I send a HTTP request for Channel 4 on Demand which has lots of comments made by users, I only get

GET https://www.googleapis.com/youtube/v3/channels?part=statistics&forUsername=4oD&key={YOUR_API_KEY}

HTTP 响应

{
"kind": "youtube#channelListResponse",
"etag": "\"jSwUP5mXUGwzAFbnLazODtWp_hU/wSdSPc8UxAJku7v41o3DVmEytAU\"",
"pageInfo": {
"totalResults": 1,
"resultsPerPage": 5
},
"items": [
{
"kind": "youtube#channel",
"etag": "\"jSwUP5mXUGwzAFbnLazODtWp_hU/qDF5UBIAV1LXx_oOE_V-wpUvx7c\"",
"id": "UCQQGTtqKZf0S0pQ2ey5c4Ag",
"statistics": {
"viewCount": "9245",
"commentCount": "2",
"subscriberCount": "62314",
"hiddenSubscriberCount": false,
"videoCount": "1"
}
}
]
}

谢谢

推荐答案

Youtube API v3 说commentCount 是频道的评论数".这意味着 commentCount 不是所有频道视频的评论总数,而是频道的评论总数.众所周知,我们可以在频道的讨论部分对特定频道发表评论,例如此处

Youtube API v3 says that "commentCount is the number of comment for the channel". This means that commentCount is not the total number of comment for all of channel's videos but for comment for channel. As we know, we can comment for a specific channel in the discussion part of the channel like here

这篇关于Youtube Data Api 有 commentCount 字段,这是频道上的评论数吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆