Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

REST method

REST query body example

REST response body example

Response states

Description

/mpegts/startup

Code Block
languagejs
themeRDark
{
  "localStreamName":"test",
  "transport":"srt",
  "hasAudio": true,
  "hasVideo": true
}
Code Block
languagejs
themeRDark
{
  "localMediaSessionId": "32ec1a8e-7df4-4484-9a95-e7eddc45c508",
  "localStreamName": "test",
  "uri": "srt://192.168.1.39:31014",
  "status": "CONNECTED",
  "hasAudio": truefalse,
  "hasVideo": truefalse,
  "record": false,
  "transport": "SRT",
  "cdn": false,
  "timeout": 90000,
  "maxTimestampDiff": 900001,
  "allowedList": []
}

200 - OK

409 - Conflict

500 - Internal error


Start MPEG-TS publishing


/mpegts/find
Code Block
languagejs
themeRDark
{
  "localStreamName":"test",
  "uri": "srt://192.168.1.39:31014"
}
Code Block
languagejs
themeRDark
[
 {
  "localMediaSessionId": "32ec1a8e-7df4-4484-9a95-e7eddc45c508",
  "localStreamName": "test",
  "uri": "srt://192.168.1.39:31014",
  "status": "CONNECTEDPROCESSED_LOCAL",
  "hasAudio": truefalse,
  "hasVideo": truefalse,
  "record": false,
  "transport": "SRT",
  "cdn": false,
  "timeout": 90000,
  "maxTimestampDiff": 900001,
  "allowedList": []
 }
]

200 – streams found

404 – streams not found

500 - Internal error

Find the MPEG-TS stream by criteria

/mpegts/find_all


Code Block
languagejs
themeRDark
[
 {
  "localMediaSessionId": "32ec1a8e-7df4-4484-9a95-e7eddc45c508",
  "localStreamName": "test",
  "uri": "srt://192.168.1.39:31014",
  "status": "CONNECTED",
  "hasAudio": true,
  "hasVideo": true,
  "record": false,
  "timeout": 90000,
  "maxTimestampDiff": 90000
 }
]

200 – streams found

404 – streams not found

500 - Internal error

Find all MPEG-TS streams

/mpegts/terminate

Code Block
languagejs
themeRDark
{
  "localStreamName":"test"
}

200 - stream stopped

404 - stream not found

500 - Internal error

Stop MPEG-TS stream

...

Name

Description

Example

localStreamNameName to set to the stream on servertest
transportTransport to usesrt
uriEndpoint URI to publish the streamudp://192.168.1.39:31014
localMediaSessionIdStream media session Id32ec1a8e-7df4-4484-9a95-e7eddc45c508
statusStream statusCONNECTED
hasAudioStream has audio tracktrue
hasVideoStream has video tracktrue
recordStream is recordingfalse
timeoutMaximum media data receiving timeout, ms90000
maxTimestampDiffMaximum stream timestamps difference, mss900001

allowedList

Client addresses list which are allowed to publish the stream

["192.168.1.0/24"] 

...