Create a live stream

POST {{baseUrl}}/live_streams

The quickest way to your first broadcast is with a live stream. In Wowza Video, a live stream automatically handles a lot of the configuration and processing necessary to provide your stream to a global audience.

We've already configured the body of this request, and in this single API call, you'll:

* specify how the video connects with Wowza Video
* set up a webpage hosted by Wowza that you'll send your viewers to
* configure the generated player, embedded in the hosted page, that viewers will use to watch the stream

ACTION
Click Send. This request creates a live stream that receives a WebRTC source, generates a player, and configures a hosted page.

The response includes:

* An id that identifies the live stream. You'll typically need this ID to complete other actions on the stream, but this collection captures and uses the ID in subsequent requests.
* source_connection_information that you'll use to configure the WebRTC publish page as the source for the live stream. You'll complete this configuration below.
* Information about the hosted page and player that will be generated. We didn't explicitly include configuration details for the hosted page or the player in the request, instead we relied on the default values for both.
* Other details of the live stream's configuration.

Let's use the source connection information to configure the WebRTC Publish Page you'll use to capture video source.

ACTION
1. Open wowza.com/webrtc/publish and grant access to your camera and microphone when prompted. This is the WebRTC Publish Page and we'll use it to capture your video source. The configurations we do now will set up the connection between your browser and Wowza Video.
2. Click the Settings button in the upper-right corner of the page.
3. Using the source_connection_information from the response, enter the following information:

SDP URL — Value from sdp_url
Application Name — Value from application_name
Stream Name — Value from stream_name

Leave Audio Bitrate and Video Bitrate as they are.

4. Close the Settings dialog box to apply your changes.

Next step

Open the GET Fetch a live stream request.


Below is additional information about the POST Create a live stream request.

Request Body

{"live_stream"=>{"aspect_ratio_height"=>720, "aspect_ratio_width"=>1280, "billing_mode"=>"pay_as_you_go", "broadcast_location"=>"us_west_oregon", "encoder"=>"other_webrtc", "name"=>"My Live Stream", "transcoder_type"=>"transcoded"}}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: Created

{"live_stream":{"aspect_ratio_height":94083223,"aspect_ratio_width":97908157,"asset_id":"officia tempor occaecat cillum consectetur","billing_mode":"pay_as_you_go","broadcast_location":"eu_germany","closed_caption_type":"both","connection_code":"","connection_code_expires_at":"1970-05-10T11:17:21.075Z","created_at":"1977-12-11T22:49:27.720Z","delivery_method":"pull","delivery_protocols":["d","cupidatat pariatur et cillum"],"delivery_type":"single-bitrate","direct_playback_urls":{"delivery_protocol":[{"name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"output_id":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"url":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"application_name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"stream_name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}},{"name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"output_id":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"url":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"application_name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},"stream_name":{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}}]},"encoder":"other_srt","hosted_page":false,"hosted_page_description":"","hosted_page_logo_image_url":"","hosted_page_sharing_icons":false,"hosted_page_title":"","hosted_page_url":"","id":"","low_latency":false,"name":"","playback_stream_name":"","player_countdown":false,"player_countdown_at":"1991-09-30T09:47:40.031Z","player_embed_code":"","player_hls_playback_url":"","player_id":"","player_logo_image_url":"","player_logo_position":"bottom-left","player_responsive":false,"player_type":"","player_video_poster_image_url":"","player_width":-9748688,"recording":true,"reference_id":"","save_asset":false,"source_connection_information":{},"stream_source_id":"","stream_targets":[{"id":"dcxq5q6c"},{"id":"dcxq5q6c"}],"target_delivery_protocol":"hls-https","transcoder_type":"transcoded","updated_at":"1957-04-29T19:57:39.038Z","use_stream_source":false,"vod_stream":false}}