Push
Start push publishing
POST
http://<OME_HOST>:<API_PORT>/v1/vhosts/{vhost_name}/apps/{app_name}:startPush
Example - RTMP push publishing by Output Stream Name
POST http[s]://{host}/v1/vhosts/default/apps/app:startPush
{
"id": "{unique_push_id}",
"stream": {
"name": "{output_stream_name}"
},
"protocol": "rtmp",
"url":"rtmp://{host}[:port]/{app_ame}",
"streamKey":"{stream_name}"
}
Example - MPEG TS push publishing by Output Stream Name
POST http[s]://{host}/v1/vhosts/default/apps/app:startPush
{
"id": "{unique_push_id}",
"stream": {
"name": "{output_stream_name}"
},
"protocol": "mpegts",
"url":"udp://{host}[:port]",
"streamKey":""
}
Example - Push publishing by Output Stream Name and Track Ids
POST http[s]://{host}/v1/vhosts/default/apps/app:startPush
{
"id": "{unique_push_id}",
"stream": {
"name": "{output_stream_name}",
"trackIds": [ 101, 102 ]
},
"protocol": "rtmp",
"url":"rtmp://{host}[:port]/{appName}",
"streamKey":"{stream_name}"
}
Example - Push publishing by Output Stream Name and Variant Names
POST http[s]://{host}/v1/vhosts/default/apps/app:startPush
{
"id": "{unique_push_id}",
"stream": {
"name": "{output_stream_name}",
"variantNames": [ "h264_fhd", "aac" ]
},
"protocol": "rtmp",
"url":"rtmp://{host}[:port]/{app_name}",
"streamKey":"{stream_name}"
}
* variantName means Application.OutputProfiles.OutputProfie.Encodes.[Video|Audio|Data].Name in the Server.xml configuration file.
Path Parameters
Name | Type | Description |
---|---|---|
vhost_name* | string | A name of |
app_name* | string | A name of |
Headers
Name | Type | Description |
---|---|---|
authorization* | string | A string for authentication in For example, |
Request Body
Name | Type | Description |
---|---|---|
id* | string | Unique identifier of push publishing |
stream* | string | Output stream for push. |
name* | string | Output stream name |
trackIds | array | Used for push publishing specific track ids. |
protocol* | string | Transport protocol [rtmp | mpegts] |
url* | string | Destination URL. |
streamKey* | object | Destination stream key. |
variantNames | array | Used for push publishing specific variant names. |
Stop push publishing
POST
http://<OME_HOST>:<API_PORT>/v1/vhosts/{vhost_name}/apps/{app_name}:stopPush
Example
POST http[s]://{host}/v1/vhosts/default/apps/app:stopRecord
{
"id": "{unique_push_id}"
}
Path Parameters
Name | Type | Description |
---|---|---|
vhost_name* | string | A name of |
app_name* | string | A name of |
Headers
Name | Type | Description |
---|---|---|
authorization* | string | A string for authentication in For example, |
Request Body
Name | Type | Description |
---|---|---|
id* | string | Unique identifier of push publishing |
Push publishing status
POST
http://<OME_HOST>:<API_PORT>/v1/vhosts/{vhost_name}/apps/{app_name}:pushes
Example
POST http[s]://{host}/v1/vhosts/default/apps/app:pushes
{
"id": "{unique_push_id}"
}
Path Parameters
Name | Type | Description |
---|---|---|
vhost_name* | string | A name of
|
app_name* | string | A name of
|
Headers
Name | Type | Description |
---|---|---|
authorization* | string | A string for authentication in
format. \ For example,
if access token is
. |
Request Body
Name | Type | Description |
---|---|---|
id | string | Unique identifier of push publishing |
Last updated