查詢導播台配置資訊。
介面說明
先通過 CreateCaster 介面建立導播台,再調用本介面查詢導播台配置資訊。
QPS 限制
本介面的單使用者 QPS 限制為 15 次/秒。超過限制,API 呼叫會被限流,這可能會影響您的業務,請合理調用。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
live:DescribeCasterConfig |
get |
*Caster
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| RegionId |
string |
否 |
地區 ID。 |
cn-shanghai |
| CasterId |
string |
是 |
導播台 ID。
說明
直播控制台雲導播台頁面導播台列表中的導播台名稱即導播台 ID。 |
LIVEPRODUCER_POST-cn-0pp1czt**** |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
導播台配置資訊。 |
||
| AutoSwitchUrgentConfig |
string |
自動切備播配置。 |
{"eofThres":3} |
| AutoSwitchUrgentOn |
string |
開啟斷流自動切換備播。
|
true |
| CallbackUrl |
string |
使用者回調地址。 |
http://learn.aliyundoc.com/callBackLive |
| CasterId |
string |
導播台 ID。 |
LIVEPRODUCER_POST-cn-0pp1czt**** |
| CasterName |
string |
導播台名稱。 |
coco-caster10 |
| ChannelEnable |
integer |
是否啟用 Channel。 取值:
|
1 |
| Delay |
number |
延時播放。單位:秒 。
|
0 |
| DomainName |
string |
主播流網域名稱。 |
example.com |
| ProgramEffect |
integer |
輪播生效標誌。 取值:
|
0 |
| ProgramName |
string |
輪播台名稱。 |
program_name |
| RecordConfig |
object |
錄製配置參數為空白時,表示不啟用錄製功能。 |
|
| OnDemand |
integer |
按需錄製。取值:
|
0 |
| OssBucket |
string |
儲存位置。 |
liveBucket**** |
| OssEndpoint |
string |
儲存位置所在 OSS 節點。 |
oss-cn-shanghai.aliyundoc.com |
| RecordFormat |
object |
||
| RecordFormat |
array<object> |
錄製格式配置。 |
|
|
object |
錄製時間長度資訊。 |
||
| CycleDuration |
integer |
錄製時間長度。 |
3600 |
| Format |
string |
錄製格式。 |
M3U8 |
| OssObjectPrefix |
string |
錄製檔案名稱。 |
record/{liveApp****}/{liveStream****} |
| SliceOssObjectPrefix |
string |
切片名稱。 |
record/{liveApp****}/{liveStream****}/{UnixTimestamp****} |
| RequestId |
string |
請求 ID。 |
97df6b7f-3490-47d2-ac50-8833e1b64597 |
| SideOutputUrl |
string |
使用者自訂導播台旁路輸出地址。 |
rtmp://sophon-developer.aliyundoc.com/caster/4a82a3d1b7f0462ea37348366201****?auth_key=1608953344-0-0-ac8c628078541d7055a170ec59a5**** |
| SideOutputUrlList |
string |
使用者自訂導播台旁路輸出地址清單。 |
["rtmp://domain/app1/stream1","rtmp://domain/app2/stream2"] |
| SyncGroupsConfig |
object |
||
| SyncGroup |
array<object> |
儲存配置。 |
|
|
object |
儲存配置。 |
||
| HostResourceId |
string |
導播台資源 ID。 |
28768383240243**** |
| Mode |
integer |
靜態頁面緩衝的模式。取值:
|
0 |
| ResourceIds |
object |
||
| ResourceId |
array |
需要修改資源群組的雲資源的資源 ID 列表,資源 ID 數量限制為 1 至 50。 |
|
|
string |
需要修改資源群組的雲資源的資源 ID 列表,資源 ID 數量限制為 1 至 50。 |
1 |
|
| TranscodeConfig |
object |
轉碼配置。 |
|
| CasterTemplate |
string |
導播台轉碼模板。取值:
|
lp_hd |
| LiveTemplateIds |
object |
||
| LocationId |
array |
直播轉碼配置。 |
|
|
string |
直播轉碼配置。取值:
|
lld |
|
| CustomParams |
object |
自訂配置 |
|
| video |
object |
視頻參數 |
|
| fps |
integer |
視訊框架率 |
300 |
| bitrate |
integer |
視頻碼率 |
300 |
| width |
integer |
視頻畫面寬度,單位為像素(px)。 |
1080 |
| height |
integer |
視頻畫面高度,單位為像素(px)。 |
720 |
| UrgentImageId |
string |
備播圖片媒資庫素材 ID。 |
a089175eb5f4427684fc0715159a**** |
| UrgentImageUrl |
string |
備播圖片素材 URL。 |
http://learn.aliyundoc.com/AppName/image.jpg |
| UrgentLiveStreamUrl |
string |
備播直播流 URL。 |
rtmp://demo.aliyundoc.com |
| UrgentMaterialId |
string |
備播視頻媒資庫素材 ID。 |
98646538-bcf9-4aef-bd4a-e6bb76588**** |
樣本
正常返回樣本
JSON格式
{
"AutoSwitchUrgentConfig": "{\"eofThres\":3}",
"AutoSwitchUrgentOn": "true",
"CallbackUrl": "http://learn.aliyundoc.com/callBackLive",
"CasterId": "LIVEPRODUCER_POST-cn-0pp1czt****",
"CasterName": "coco-caster10",
"ChannelEnable": 1,
"Delay": 0,
"DomainName": "example.com",
"ProgramEffect": 0,
"ProgramName": "program_name",
"RecordConfig": {
"OnDemand": 0,
"OssBucket": "liveBucket****",
"OssEndpoint": "oss-cn-shanghai.aliyundoc.com",
"RecordFormat": {
"RecordFormat": [
{
"CycleDuration": 3600,
"Format": "M3U8",
"OssObjectPrefix": "record/{liveApp****}/{liveStream****}",
"SliceOssObjectPrefix": "record/{liveApp****}/{liveStream****}/{UnixTimestamp****}"
}
]
}
},
"RequestId": "97df6b7f-3490-47d2-ac50-8833e1b64597",
"SideOutputUrl": "rtmp://sophon-developer.aliyundoc.com/caster/4a82a3d1b7f0462ea37348366201****?auth_key=1608953344-0-0-ac8c628078541d7055a170ec59a5****",
"SideOutputUrlList": "[\"rtmp://domain/app1/stream1\",\"rtmp://domain/app2/stream2\"]",
"SyncGroupsConfig": {
"SyncGroup": [
{
"HostResourceId": "28768383240243****",
"Mode": 0,
"ResourceIds": {
"ResourceId": [
"1"
]
}
}
]
},
"TranscodeConfig": {
"CasterTemplate": "lp_hd",
"LiveTemplateIds": {
"LocationId": [
"lld"
]
},
"CustomParams": {
"video": {
"fps": 300,
"bitrate": 300,
"width": 1080,
"height": 720
}
}
},
"UrgentImageId": "a089175eb5f4427684fc0715159a****",
"UrgentImageUrl": "http://learn.aliyundoc.com/AppName/image.jpg",
"UrgentLiveStreamUrl": "rtmp://demo.aliyundoc.com",
"UrgentMaterialId": "98646538-bcf9-4aef-bd4a-e6bb76588****"
}
錯誤碼
|
HTTP status code |
錯誤碼 |
錯誤資訊 |
描述 |
|---|---|---|---|
| 400 | InvalidCasterId.Malformed | %s | |
| 401 | IllegalOperation | %s | |
| 500 | InternalError | %s | |
| 404 | InvalidCaster.NotFound | %s |
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。