YouTube 流式传输 API 表示用户未启用实时流式传输
YouTube Streaming API says user is not enabled for live streaming
我正在使用属于其他人的 Google's YouTube API Explorer (alternate) to look up information on an arbitrary streaming broadcast。
无论我在 id
字段中输入什么,我总是会返回
{
"error": {
"errors": [{
"domain": "youtube.liveBroadcast",
"reason": "liveStreamingNotEnabled",
"message": "The user is not enabled for live streaming.",
"extendedHelp": "https://www.youtube.com/features"
}],
"code": 403,
"message": "The user is not enabled for live streaming."
}
}
考虑到视频是流式传输,这似乎很荒谬。
我突然想到我可能误解了 id
字段的说明,所以我尝试了几种不同的可能性。这些包括...
- 频道 ID (
UCHZoP1Jy-g_h3sqzScrOEwQ
)
- 用户 ID (
GWTV
)
- 视频 ID (
J_RrkyIOVhg
)
...都无济于事。
如何向频道询问其直播视频? This question would have answered that in the past, but the comments indicate that the answer no longer works. This question 也没有任何帮助。
编辑 2022
如果您正在寻找如何从任意频道获取流式传输状态和当前流式传输视频,请查看 and particularly 。
API 文档的 Errors heading 有这个有趣的图表:
Error Type
Error Detail
Description
insufficientPermissions
insufficientLivePermissions
The request is not authorized to retrieve the live broadcast
insufficientPermissions
liveStreamingNotEnabled
(This is the error I'm getting.)
The user that authorized the request is not enabled to stream live video on YouTube. The user can find more information at https://www.youtube.com/features
这意味着因为我的账户没有直播,所以我无法在其他人的中查看任何人的直播信息API,即使我可以在浏览器中将其拉出。
这看起来有点武断,但我在原题中得到的错误结果是权限问题。请注意,即使在为 我自己启用直播后, 我 for third-party streams because Google does not allow 也会检查直播 API 是否有非您的用户。
我在尝试获取 Youtube 直播状态时遇到了同样的错误消息。
在我的例子中,我使用的是 'Youtube Brand Account',尝试将品牌帐户切换为授权用户是值得的。效果很好。
HTH
为了解决这个问题,我们需要在工作室 > 设置 > 频道 > 功能 > 启用广播中启用直播
直播服务将在 24 小时后运行
我正在使用属于其他人的 Google's YouTube API Explorer (alternate) to look up information on an arbitrary streaming broadcast。
无论我在 id
字段中输入什么,我总是会返回
{
"error": {
"errors": [{
"domain": "youtube.liveBroadcast",
"reason": "liveStreamingNotEnabled",
"message": "The user is not enabled for live streaming.",
"extendedHelp": "https://www.youtube.com/features"
}],
"code": 403,
"message": "The user is not enabled for live streaming."
}
}
考虑到视频是流式传输,这似乎很荒谬。
我突然想到我可能误解了 id
字段的说明,所以我尝试了几种不同的可能性。这些包括...
- 频道 ID (
UCHZoP1Jy-g_h3sqzScrOEwQ
) - 用户 ID (
GWTV
) - 视频 ID (
J_RrkyIOVhg
)
...都无济于事。
如何向频道询问其直播视频? This question would have answered that in the past, but the comments indicate that the answer no longer works. This question 也没有任何帮助。
编辑 2022
如果您正在寻找如何从任意频道获取流式传输状态和当前流式传输视频,请查看
API 文档的 Errors heading 有这个有趣的图表:
Error Type | Error Detail | Description |
---|---|---|
insufficientPermissions |
insufficientLivePermissions |
The request is not authorized to retrieve the live broadcast |
insufficientPermissions |
liveStreamingNotEnabled (This is the error I'm getting.) |
The user that authorized the request is not enabled to stream live video on YouTube. The user can find more information at https://www.youtube.com/features |
这意味着因为我的账户没有直播,所以我无法在其他人的中查看任何人的直播信息API,即使我可以在浏览器中将其拉出。
这看起来有点武断,但我在原题中得到的错误结果是权限问题。请注意,即使在为 我自己启用直播后, 我
我在尝试获取 Youtube 直播状态时遇到了同样的错误消息。
在我的例子中,我使用的是 'Youtube Brand Account',尝试将品牌帐户切换为授权用户是值得的。效果很好。 HTH
为了解决这个问题,我们需要在工作室 > 设置 > 频道 > 功能 > 启用广播中启用直播
直播服务将在 24 小时后运行