我可以使用YouTube的LiveStreaming API访问所有直播吗? [英] Can I access all live broadcasts with YouTube's LiveStreaming API?
本文介绍了我可以使用YouTube的LiveStreaming API访问所有直播吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Meerkat允许通过REST API访问其所有直播. YouTube的实时流API是否允许相同的内容?我可以看到它们允许通过特定用户的API进行CRUD.我的问题是我可以使用API访问所有直播吗?
Meerkat allows access to all its live broadcasts via REST API. Does YouTube's live streaming API allow the same? I can see that they allow CRUD through the API for a particular user. My question is can I access all live broadcasts with the API?
推荐答案
You can use the Search/list endpoint of the regular YouTube v3 API and filter the results to only receive live content. Make sure to pass in the following parameters:
part -> snippet
eventType -> live
type -> video
(将eventType
设置为live
时必需)
完整的获取请求:
HTTP GET https://www.googleapis.com/youtube/v3/search?part=snippet&eventType=live&type=video&key={YOUR_API_KEY}
这篇关于我可以使用YouTube的LiveStreaming API访问所有直播吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文