Wowza Streaming Cloud with Ultra Low Latency quick start guide

Learn how to use the Wowza Streaming Cloud™ service's REST API to send an encoded live stream to an ultra low latency stream target for browser-based playback with Wowza Player or playback through a mobile app.

Note: Ultra low latency streaming is available through Wowza Streaming Cloud with Ultra Low Latency. For additional information see How to use Wowza Streaming Cloud for ultra low latency streaming.

Video tutorial: Ultra low latency quick start guide


Tip: See our Wowza ultra low latency playlist on YouTube for more video tutorials about ultra low latency streaming.

Create an ultra low latency stream target


Start by creating an ultra low latency stream target using the Wowza Streaming Cloud REST API. Example commands are presented in curl, but you can also use a GUI REST client for API testing such as Postman or Paw.

Notes:

  • Ultra low latency stream targets are not available in the sandbox environment, so be sure to use https://api.cloud.wowza.com not https://api-sandbox.cloud.wowza.com in your API request.
  • Use the /stream_targets/ull endpoint instead of the /stream_targets endpoint to create an ultra low latency stream target.
  • For [key], substitute your API key or your access key as appropriate. For more information, see Locating and using API and access keys.
  • For [version], substitute the version number of the API that you're using. For the current version, use v1.2.

Ultra low latency stream target parameters

Parameter Data Type Description
enable_hls Boolean If true, creates an Apple HLS playback URL that can be used to view the stream on mobile devices or to provide redundancy in the event that WebSocket connection attempts fail. The default is false.
enabled Boolean If true (the default), allows the source stream to be ingested by the target's origin server.
name string The name of the stream target. Enter a descriptive alphanumeric string that is under 200 characters.
region_override string Optional, for ultra low latency stream targets whose source_delivery_method is pull. The location of the ultra low latency stream target's origin server. If unspecified, Wowza Streaming Cloud determines the optimal region for the origin server.
source_delivery_method string The method being used to deliver the source stream to the origin server. Valid values are pull, which instructs the stream target to pull the stream from the source, or push, which instructs the source to push the stream to the target.
source_url string Required when the source delivery method is pull. The URL of a source IP camera or encoder. Consult the camera or encoder documentation for the URL syntax.

Example requests and responses

Create an ultra low latency stream target for a push stream. Use this request when streaming from the GoCoder mobile app or any source encoder that can send an RTMP or RTSP stream in H.264. Configuring a push stream indicates that your video source will push the stream to Wowza Streaming Cloud. 

curl -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" -H "Content-Type: application/json" -X POST -d '{
    "ull_stream_target": {
	"name": "My Ultra Low Latency Push Target",
	"source_delivery_method": "push",
	"enabled": true
    }
}' "https://api.cloud.wowza.com/api/[version]/stream_targets/ull"

The command creates an ultra low latency stream target with an id parameter, ingest connection details, and playback details, including a hash of playback URLs. You will need details from this response to configure your source encoder. The response should look something like this:

{
    "ull_stream_target": {
        "id": "cetkpl5i",
        "name": "My Ultra Low Latency Push Target",
        "enabled": true,
        "state": "stopped",
        "stream_name": "0I0q1NXZhMnvjUVWWHaW3SM8LfhN5d03",
        "primary_url": "rtmp://origin.wowza.com:1935/live/0I0q1NXZhMnvjUVWWHaW3SM8LfhN5d03",
        "source_delivery_method": "push",
        "playback_urls": {
           "ws": [
               "ws://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160/stream.ws",
               "wss://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160/stream.ws"
            ],
            "wowz": [
               "wowz://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160",
               "wowzs://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160"
            ]
        },
        "connection_code": "295903",
        "connection_code_expires_at": "2017-10-26T20:46:20.000Z",
        "enable_hls": false,
        "created_at": "2017-10-25T20:46:20.000Z",
        "updated_at": "2017-10-25T20:46:20.000Z",
    }
}

Alternatively, create an ultra low latency stream target for a pull stream from an RTSP encoder. Configuring a pull stream instructs Wowza Streaming Cloud to pull the stream from the encoder. Refer to documentation for your source encoder to determine the source_url value. The hostname or IP address used in the source_url must be publicly accessible.

curl -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" -H "Content-Type: application/json" -X POST -d '{
    "ull_stream_target": {
	"name": "My Ultra Low Latency Pull Target",
	"source_delivery_method": "pull",
	"enabled": true,
	"source_url": "rtsp://example.com/video"
    }
}' "https://api.cloud.wowza.com/api/[version]/stream_targets/ull"

The details of the new ultra low latency stream target are provided in the response, which should look something like this:

{
    "ull_stream_target": {
        "id": "vpxfks4v",
        "name": "My Ultra Low Latency Pull Target",
        "enabled": true,
        "state": "stopped",
        "source_delivery_method": "pull",
        "source_url": "rtsp://sample.com/video",
        "playback_urls": {
           "ws": [
               "ws://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160/stream.ws",
               "wss://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160/stream.ws"
            ],
            "wowz": [
               "wowz://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160",
               "wowzs://edge.cdn.wowza.com/live/_definst_/0P0q1bjZhRzJxaE80b3lremtKSnZ6160"
            ]
        },
        "enable_hls": false,
        "created_at": "2017-10-19T18:47:35.000Z",
        "updated_at": "2017-10-19T18:47:35.000Z",
        "links": [...]
    }
}

Related API requests

View all ultra low latency stream targets:

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/ull"

View the details of an ultra low latency stream target:

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/ull/[ull_stream_target_id]"

Update an ultra low latency stream target's configuration:

Note: The enable_hls and source_delivery_method parameters can't be updated.

curl -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" -H "Content-Type: application/json" -X POST -d '{
	"ull_stream_target": {
		"name": "My Awesome Ultra Low Latency Pull Stream Target",
	}
}' "https://api.cloud.wowza.com/api/[version]/stream_targets/ull/[ull_stream_target_id]"

Delete an ultra low latency stream target:

curl -X DELETE -H "wsc-api-key: [key]" -H " wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/ull/[ull_stream_target_id]"

Configure the source


Use the details of the ultra low latency stream target you created in the Wowza Streaming Cloud REST API to configure a source.

RTMP encoder with push source delivery method

For an RTMP encoder delivering a stream into Wowza Streaming Cloud over a push connection, use the primary URL value returned when you created the ultra low latency stream target. The primary URL is the ingest location. For example:
rtmp://origin.wowza.com:1935/live/0I0q1NXZhMnvjUVWWHaW3SM8LfhN5d03

Refer to documentation for your specific encoder to note where to input the stream settings. Encoders may require the stream name value to be separated from the primary URL. For example:
Address or URL: rtmp://origin.wowza.com:1935/live/
Stream or Stream key: 0I0q1NXZhMnvjUVWWHaW3SM8LfhN5d03

RTMP encoder with pull source delivery method

For an RTMP encoder delivering a stream with a pull connection, you configure the source by determining and providing the source_url value when creating the ultra low latency stream source. The source_url must be an RTMP URL with a publicly accessible hostname or IP address.

RTSP encoder with pull source delivery method

For an RTSP pull connection, such as an IP camera, you configure the source by determining and providing the source_url value when creating the ultra low latency stream source. The source_url for your camera must include a publicly accessible hostname or IP address.

Wowza GoCoder app

To stream from the Wowza GoCoder app, use the connection code value returned when you created the ultra low latency stream target. See How to configure Wowza GoCoder to stream to an ultra low latency stream target for more information.

Wowza GoCoder SDK

To learn more about developing an app with the Wowza GoCoder SDK to encode and stream to the Wowza Streaming Cloud ultra low latency stream target, see the these articles:

Wowza Streaming Engine

See How to stream from Wowza Streaming Engine to an ultra low latency stream target in Wowza Streaming Cloud for more information.

Configure playback


Wowza Player

To quickly test playback functionality, use Wowza Player Builder for Ultra Low Latency to preview the stream and to get an embed code so that viewers can watch the stream from your webpage.

For specific instructions, see How to configure Wowza Player for ultra low latency streams.

Notes: 
  • Wowza Player for Ultra Low Latency works with the latest version of most modern web browsers such as Google Chrome, Firefox, Safari, and Microsoft Edge; however, ultra low latency streams from a Wirecast encoder may not play as expected on the latest version of the Safari browser.
  • Wowza Player for Ultra Low Latency currently supports HLS streams only for browser-based playback on iOS devices. For ultra low latency stream playback on iOS devices, see How to play an ultra low latency stream with Wowza GoCoder SDK for iOS.

Wowza GoCoder SDK

Alternatively, you can also use the GoCoder SDK to develop an app with playback functionality. For more information, see How to play an ultra low latency live stream with Wowza GoCoder SDK for iOS or How to play an ultra low latency live stream with Wowza GoCoder SDK for Android.

Start streaming


Push source delivery method

Start sending video from the Wowza GoCoder app or another encoding device, and the live steam starts.

If you have trouble sending a stream through the GoCoder app, check the settings. You also may need to regenerate a connection code. You can do this in the stream target details page in the Wowza Streaming Cloud web manager or through the following API request:

curl -X PUT -H "wsc-api-key: [key]" -H " wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/[ull_stream_target_id]/regenerate_connection_code"

Pull source delivery method

When someone requests the stream by accessing the playback URL, the ultra low latency target will ingest the stream and it will start playing. After about a minute of no requests, Wowza Streaming Cloud stops ingesting the stream.

View ultra low latency stream analytics, usage, and viewer data through the API


Stream metrics, usage, and viewer data endpoints allow you to view data that will help you understand how your stream was processed and viewed.

Stream metrics show connection data for the stream target's origin server, including the average inbound bitrate of the stream and the number of dropped connections.

Usage data shows the amount of bandwidth used and billed by a target.

Viewer data includes the locations where the ultra low latency stream was requested and how many requests were made to the edge server.

Example requests

Get connection metrics for an ultra low latency stream target for the most recent 10 minutes that it ran:

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/[ull_stream_target_id]/metrics/historic"

Get viewer data for an ultra low latency stream target for the current billing period:

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/usage/viewer_data/stream_targets/[ull_stream_target_id]"

Get a snapshot of connection and processing metrics for an active ultra low latency stream target:

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/stream_targets/[ull_stream_target_id]/metrics/current"

Get network usage (bandwidth) used and billed for all stream targets:

Note: The network usage query returns bandwidth for all targets in the account, not just ultra low latency stream targets.

curl -X GET -H "wsc-api-key: [key]" -H "wsc-access-key: [key]" "https://api.cloud.wowza.com/api/[version]/usage/network/stream_targets/"

View ultra low latency target details, usage, and viewer data in Wowza Streaming Cloud


You can view (but not edit) details about ultra low latency stream targets in the Wowza Streaming Cloud web manager.

  1. In Wowza Streaming Cloud, click Advanced on the menu bar and then click Stream Targets.
  2. Find an ultra low latency stream target and click its name.

The stream target detail page shows the target's setup as it was configured in the REST API. To edit the ultra low latency stream target, use the REST API.

Note: Only secure WebSocket and Apple HLS playback URLs are shown on the ultra low latency stream target detail page. Additional WebSocket, WOWZ, and HLS playback URLs are available through the REST API.

  1. (Optional) Click Usage to see bandwidth usage and viewer data for the ultra low latency stream target.

More resources



If you're having problems or want to discuss this article, post in our forum.