无法使用 Youtube API 将我的 Youtube 广播转换为直播 [英] Cannot make transition of my Youtube broadcast to live using Youtube API

查看:30
本文介绍了无法使用 Youtube API 将我的 Youtube 广播转换为直播的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

现在,我正试图弄清楚在将我的 YT 广播转换为直播时我做错了什么.

Right now I'm trying to figure out what i'm doing wrong when making transition of my YT broadcast to live.

所以我提出请求并得到以下响应:

So I make the request and get the following response:

{
  "code" : 403,
  "errors" : [ {
    "domain" : "youtube.liveBroadcast",
    "message" : "Invalid transition",
    "reason" : "invalidTransition",
    "extendedHelp" : "https://developers.google.com/youtube/v3/live/docs/liveBroadcasts/transition#params"
  } ],
  "message" : "Invalid transition"
}

当然,我已经多次阅读文档,所以我已经监视了 LiveStream 并等待其活动"状态(并且我的广播具有 lifeCycleStatus="ready").

Of course i've read docs many times so I've monitored the LiveStream and was waiting for its "active" state (and my Broadcast has lifeCycleStatus="ready").

错误消息没有解释我不能进行转换的真正原因.而且...当然我无权访问 Youtube 服务器的日志:)

Error message doesn't explain real reason why cannot I do the transition.
And... of course I do not have access to logs of Youtube servers :)

你有什么建议?
如何找出我错在哪里?

What can you suggest?
How to find out where am I wrong?

因此,即使我遗漏了某些内容,文档和错误消息也无法帮助我理解任何内容.所以无论如何这对于 YT LiveStreaming API 来说是一个错误"......

So even if i've missed something, docs and error message do not help me to understand anything. So anyway it is kind of a "bug" for YT LiveStreaming API...

推荐答案

所以有点不清楚的规则是:

So a bit unclear rule is:

  1. 确保您已创建并准备好广播和直播.
    并确保广播生命周期状态不是COMPLETE,否则重新创建广播...因此请确保您的广播生命周期状态 ready
  2. 将广播绑定到直播
  3. 开始发布视频以进行直播
  4. 等待直播状态active
  5. 过渡到testing(是的,你必须这样做,而不是转移到live)
  6. 等待广播lifeCycleStatus成为testing
  7. 过渡到live
  8. 等待广播lifeCycleStatus变成live
  1. ensure you have broadcast and livestream created and ready.
    and ensure that broadcast lifecycle status is not COMPLETE, otherwise recreate broadcast ... so ensure that your broadcast lifecycle status is ready
  2. bind broadcast to livestream
  3. start publishing video to livestream
  4. wait for livestream status active
  5. transition to testing (yes, you have to do it instead of moving to live)
  6. wait for broadcast lifeCycleStatus to become testing
  7. transition to live
  8. wait for broadcast lifeCycleStatus to become live

您不能跳过testing,也不能从complete 过渡到testingready.

You cannot skip testing and cannot transition from complete to testing or ready.

这篇关于无法使用 Youtube API 将我的 Youtube 广播转换为直播的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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