【问题标题】:Youtube video comment status can't be changed from "heldForReview" to any otherYoutube 视频评论状态不能从“heldForReview”更改为任何其他
【发布时间】:2018-06-08 13:02:55
【问题描述】:

我尝试使用以下 API 将 youtube 视频评论状态从“已发布”更改为“保留评论”,并成功更改了评论状态。

https://www.googleapis.com/youtube/v3/comments/setModerationStatus?id={COMMENT_ID}&moderationStatus=heldForReview&key={API_KEY}

当我尝试将评论状态从“heldForReview”更改为“已发布”(使用与 moderationStatus=published 相同的上述 API)时,我收到了以下错误

{
 "error": {
  "errors": [
   {
    "domain": "youtube.comment",
    "reason": "processingFailure",
    "message": "The API server failed to successfully process the request. While this can be a transient error, it usually indicates that the requests input is invalid.",
    "locationType": "parameter",
    "location": "id"
   }
  ],
  "code": 400,
  "message": "The API server failed to successfully process the request. While this can be a transient error, it usually indicates that the requests input is invalid."
 }
}

我还尝试使用谷歌开发者 API 资源管理器将评论状态从“heldForReview”更改为“已发布”,但收到了同样的错误。

我非常感谢任何解决方案。

【问题讨论】:

    标签: youtube-api youtube-data-api


    【解决方案1】:

    这意味着您输入的 ID 无效。要正确获取评论 ID,您可以单击评论的日期

    这会将网址更改为:

    https://www.youtube.com/watch?v=[ID]&lc=[ID]
    

    使用 lc 的值来获得正确的 ID,然后您将获得可以更改评论状态的成功请求。此外,您还必须使用 OAuth 2.0 进行请求授权。希望这会有所帮助。

    【讨论】:

      猜你喜欢
      • 2013-01-16
      • 2012-11-07
      • 2015-09-26
      • 2013-11-21
      • 2016-11-14
      • 2016-11-22
      • 2017-07-12
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多