Live Streaming


Apps that have integrated with the Zoom Video SDK can live stream a session to Facebook Live, YouTube Live, and a number of other custom live streaming platforms.

In this tutorial, we will show you how to set up a streaming event in a third-party platform(Youtube) and implement a feature to start and stop live streaming of a session using the Video SDK.

Retrieve Live Streaming Credentials from Selected Platform

Live streaming with SDKs requires the following information from third-party streaming platforms: Stream URL, Stream Key, Broadcast URL.

For instance, if you wanted to livestream a session to Youtube, you must Enable Live Streaming on your Google account and retrieve the stream information.

Step 1: Login to YouTube. Locate the video icon and press “Go Live”.

Go Live option on YouTube

Step 2: Click the Stream button in the top panel. Note: YouTube Webcam services are not compatible with Zoom SDK.

YouTube Stream button

Step 3: Fill out the required information and toggle “Schedule for later”. If this is not selected, the live stream will start immediately and will not provide streaming information.

YouTube settings for Schedule for Later

Step 4: After creating the stream, the Steam URL and Stream Key will be available.

YouTube Stream URL and Key setup

To automate the above steps and get stream information programmatically, you may utilize the Youtube Live Streaming API.

Start Live Streaming the Session

To start live streaming a session from your app, first obtain an instance of ZoomVideoSDKLiveStreamHelper and verify that the current user can start streaming. Next, call startLiveStreamWithStreamingURL within ZoomVideoSDKLiveStreamHelper to begin live streaming.


// Get the ZoomVideoSDKLiveStreamHelper to perform livestream actions.
ZoomVideoSDKLiveStreamHelper *liveStreamHelper = [[ZoomVideoSDK shareInstance] getLiveStreamHelper];
// Check if live stream can start.
if ([liveStreamHelper canStartLiveStream] == Errors_Success) {
    // Call startLiveStreamWithStreamingURL to begin live stream.
    ZoomVideoSDKERROR liveStreamStartReturnValue = [liveStreamHelper startLiveStreamWithStreamingURL:streamingURL StreamingKey:key BroadcastURL:broadcastURL];
    switch (liveStreamStartReturnValue) {
        case Errors_Success:
            // Live stream successfully began.
            break;
        case Errors_Session_Live_Stream_Error:
            // Live stream could not start.
            break;
        default:
            break;
    }
}

// Get the ZoomVideoSDKLiveStreamHelper to perform livestream actions.
if let liveStreamHelper = ZoomVideoSDK.shareInstance()?.getLiveStreamHelper() {
    // Check if live stream can start.
    if liveStreamHelper.canStartLiveStream() == .Errors_Success {
        // Call startLiveStreamWithStreamingURL to begin live stream.
        let liveStreamStartReturnValue = liveStreamHelper.startLiveStream(withStreamingURL: streamingURL, streamingKey: streamingKey, broadcastURL: broadcastURL)
        switch liveStreamStartReturnValue {
        case .Errors_Success:
            // Live stream successfully began.
            break
        case .Errors_Session_Live_Stream_Error:
            // Live stream could not start.
            break
        default:
            break
        }
    }
}

In order to stop the stream using the SDK, you will need to call

stopLiveStream.


// Get the ZoomVideoSDKLiveStreamHelper to perform livestream actions.
ZoomVideoSDKLiveStreamHelper *liveStreamHelper = [[ZoomVideoSDK shareInstance] getLiveStreamHelper];
// Call stopLiveStream to stop the live stream.
[liveStreamHelper stopLiveStream];

// Get the ZoomVideoSDKLiveStreamHelper to perform livestream actions.
if let liveStreamHelper = ZoomVideoSDK.shareInstance()?.getLiveStreamHelper() {
    // Call stopLiveStream to stop the live stream.
    liveStreamHelper.stopLiveStream()
}

After calling the startLiveStream function, you can listen for updates through your ZoomVideoSDKDelegate implementation's onLiveStreamStatusChanged callback.

NameDescription
ZoomVideoSDKLiveStreamStatus_NoneNo live stream is active
ZoomVideoSDKLiveStreamStatus_InProgressLive streaming is in progress.
ZoomVideoSDKLiveStreamStatus_EndLive streaming has ended

Need help?

If you're looking for help, try Developer Support or our Developer Forum. Priority support is also available with Premier Developer Support plans.