【问题标题】:PHP YouTube Live Streaming API insufficientPermissions ErrorPHP YouTube Live Streaming API不足权限错误
【发布时间】:2015-07-01 06:15:07
【问题描述】:

我正在尝试通过“YouTube 直播 API”(YouTube 数据 API v3)访问 listLiveBroadcasts。我有 Auth 2.0 访问权限,并且每次都成功获取令牌。使用相同的逻辑,我成功访问了 Google+ 日历事件,我也启用了 YouTube API。但是当我尝试列出时:

$youtube->liveBroadcasts->listLiveBroadcasts( 'id,contentDetails', array( 'mine' => 'true', ));

它给出了错误:

[domain] => global
[reason] => insufficientPermissions
[message] => Insufficient Permission

什么都试过了,把范围设置为$scopes到

auth/youtube;

也尝试过包括:

force-ssl
readonly

同样的代码在工作

https://developers.google.com/youtube/v3/live/docs/liveBroadcasts/list

使用 google 的示例 api 密钥。

【问题讨论】:

    标签: php youtube oauth-2.0 youtube-api youtube-livestreaming-api


    【解决方案1】:

    您不应该使用 Google 的示例 API 密钥。在 Developer Console 中创建一个新应用程序并使用该应用程序的 API 密钥。

    【讨论】:

      猜你喜欢
      • 2017-08-21
      • 2021-01-18
      • 2017-06-15
      • 2022-11-10
      • 2018-04-10
      • 2014-05-18
      • 1970-01-01
      • 2015-08-29
      • 2014-10-24
      相关资源
      最近更新 更多