Stream targets query examples (push publishing) for the Wowza Streaming Engine REST API

Use cURL to query the Wowza Streaming Engine™ media server software REST API to identify and manage stream targets in a Wowza Streaming Engine instance.

Notes:

Contents


Get a list of stream targets
Create a stream target
Remove a stream target

Get a list of stream targets


The following example shows how to get a list of the currently defined stream targets:

curl -X GET --header 'Accept:application/json; charset=utf-8' http://localhost:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/live/pushpublish/mapentries

Create a stream target


The following request creates a stream target. An RTMP profile is used in this example, but you can create stream targets with other profiles in a similar way.

curl -X POST --header 'Accept:application/json; charset=utf-8' --header 'Content-type:application/json; charset=utf-8' http://localhost:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/live/pushpublish/mapentries/ppsource -d'
{
   "restURI": "http://localhost:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/live/pushpublish/mapentries/ppsource",
   "serverName":"_defaultServer_",
            "sourceStreamName": "myStream",
            "entryName": "ppsource",
            "profile": "rtmp",
            "host": "localhost",
            "application":"live",
            "userName":"testUser",
            "password":"pass",
            "streamName":"myStream"
}'

Remove a stream target


When you're finished with a stream target, you can delete it with the following request:

curl -X DELETE --header 'Accept: application/json; charset=utf-8' http://localhost:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/live/pushpublish/mapentries/ppsource

Originally Published: 06-16-2015.
Updated: For Wowza Streaming Engine 4.3.0 on 10-06-2015.
 

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