Is it possible to get a list of users in a Youtube Gaming Live Stream

烈酒焚心 提交于 2019-12-11 05:07:10

问题


I am working with the Youtube Live Streaming api. I don't see this, but I am wondering if there is a way to get a list of all viewers.


回答1:


If you have the specific stream's videoId you can use the undocumented live_stats endpoint to get the number of viewers:

https://www.youtube.com/live_stats?v={videoid}



回答2:


@JAL - your answer works great. Thanks, I have also found success using this url:

Getting the live stream details (like viewer numbers):

https://www.googleapis.com/youtube/v3/videos?part=snippet%2CliveStreamingDetails&id={VIDEO_ID_HERE}&fields=items(id%2Csnippet(title%2CliveBroadcastContent)%2CliveStreamingDetails%2FconcurrentViewers)&key={YOUR_API_KEY_HERE}

I found this url from another question: Get list of gaming live streams on Youtube.



来源:https://stackoverflow.com/questions/37715244/is-it-possible-to-get-a-list-of-users-in-a-youtube-gaming-live-stream

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!