跳到主要内容

Service

Start Live Streaming

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: live_start_push

Data:

ColumnNameTypeconstraintDescription
url_typeLive stream protocol typeenum{"1":"RTMP","2":"RTSP","3":"GB28181"}
urlLive stream URLtextRTMP: (rtmp://xxxxxxx) Example: rtmp://192.168.1.1:8080/live
video_idID of the live video streamtext{}Format: #{uav_sn}/#{camera_id}/#{video_index}; UAV SN number / payload and mount position enumeration value / payload lens number
Example for nest stream ID "1748FEV3HMA923171787/nest-camera-out/normal",
Example for UAV stream ID "1748FEV3HMA923171787/drone-camera-0/normal"
video_qualityLive stream qualityenum{"2":"SD","3":"HD"}Resolution for different quality levels: SD: 1280 * 720, HD: 1920 * 1080
video_typeLive stream typetextirDifferent lens types, e.g., normal/zoom/infrared

Example:

{
"timestamp": 1711022516332,
"data": {
"url": "rtmp://test-mediacenter.autelrobotics.cn:1936/live/1748FEV3HMA923171787/drone-camera-0/normal",
"url_type": 1,
"video_id": "1748FEV3HMA923171787/drone-camera-0/normal",
"video_quality": 1,
"video_type": "zoom"
},
"method": "live_start_push",
"tid": "b92a6aa1-96eb-4b4a-848f-c0f63f206d3b",
"bid": "74008969-0d46-4f69-9a03-78423824fe24",
"gateway": "TH7923221094"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: live_start_push

Data:

ColumnNameTypeconstraintDescription
infoLive stream informationtextFor responses that need to include parameters, info can be used. For example, RTSP requires returning the live stream URL from the device side

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_start_push",
"data": {
"result": 0,
"info": "rtmp://192.168.1.1:8080/live"
}
}

Stop Live Streaming

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: live_stop_push

Data:

ColumnNameTypeconstraintDescription
video_idID of the live video streamtextFormat: #{uav_sn}/#{camera_id}/#{video_index}; UAV SN number / payload and mount position enumeration value / payload lens number
Example for nest stream ID "1748FEV3HMA923171787/nest-camera-out/normal",
Example for UAV stream ID "1748FEV3HMA923171787/drone-camera-0/normal"

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_stop_push",
"data": {
"video_id": "1748FEV3HMA923171787/drone-camera-0/normal"
}
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: live_stop_push

Data: null

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_stop_push",
"data": {
"result": 0
}
}

Set Live Stream Quality

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: live_set_quality

Data:

ColumnNameTypeconstraintDescription
video_idID of the live video streamtextFormat: #{uav_sn}/#{camera_id}/#{video_index}; UAV SN number / payload and mount position enumeration value / payload lens number
video_qualityLive stream qualityenum{"2":"SD","3":"HD"}Resolution for different quality levels: SD: 1280 * 720, HD: 1920 * 1080

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_set_quality",
"data": {
"video_id": "1ZNDH1D0010098/39-0-7/normal-0",
"video_quality": 4
}
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: live_set_quality

Data: null

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_set_quality",
"data": {
"result": 0
}
}

Set Live Stream Lens

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: live_lens_change

Data:

ColumnNameTypeconstraintDescription
video_idID of the live video streamtext{}Format: #{uav_sn}/#{camera_id}/#{video_index}; UAV SN number / payload and mount position enumeration value / payload lens number
video_typeType of live video stream lensenum{"normal":"Default","wide":"Wide angle","zoom":"Zoom","ir":"Infrared"}

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_lens_change",
"data": {
"video_id": "1581F5BMD228Q00A82XX/39-0-7/zoom-0",
"video_type": "zoom"
}
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: live_lens_change

Data: null

Example:

{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp:": 1654070968655,
"method": "live_lens_change",
"data": {
"result": 0
}
}