1

It is going to be a YouTube API question using JavaScript. Hold on...

I regularly stream to YouTube using OBS Studio. I do it so, that I click on the "Live broadcast" icon in YouTube Studio.

YouTube Studio: https://studio.youtube.com/channel/`CHANNEL_ID`

The page gets navigated upon clicking to https://studio.youtube.com/channel/`CHANNEL_ID`/livestreaming

This gets redirected to https://studio.youtube.com/video/`NEW_VIDEO_ID`/livestreaming

Here you can edit your streaming settings before the broadcasting starts, like title, description, etc. and you will have a video URL like this: https://www.youtube.com/watch?v=`NEW_VIDEO_ID`

And the live chat URL: https://studio.youtube.com/live_chat?is_popout=1&v=`NEW_VIDEO_ID`

What I wish to achieve:

I wish to create a simplified webpage, what I can dock into OBS Studio, where I can set up title, description, etc, and when I click on "Create stream" or something like this, it will get the NEW_VIDEO_ID, so that I could copy the video URL (what I can share), and also I could open the live chat in OBS Studio without having a separate Chrome window open.

I guess it is possible through YouTube API. (But I didn't figure out how.)

I preferably create a static HTML file with JavaScript (so that I wouldn't need to run a server), but I am open to Node.js solutions as well.

Thank you for your help!

Erik Kránicz
  • 345
  • 1
  • 2
  • 12
  • Here is basically the answer to your question w.r.t. getting your live stream URL: [How to get livestream tiny URL with YouTube Data API v3](https://stackoverflow.com/a/64152800/8327971). That would imply quite a lot of work (create a broadcast, create a live stream, bound the broadcast to the live stream, etc.) The video ID (that you can share with others or use it yourself) is that broadcast's [`id`](https://developers.google.com/youtube/v3/live/docs/liveBroadcasts#id). – stvar Dec 28 '20 at 10:39

0 Answers0