添加廣告插入配置。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
ice:AddAdInsertion |
create |
*全部資源
|
無 | 無 |
請求文法
POST HTTP/1.1
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| Name |
string |
是 |
配置名稱,同個帳號下有唯一性,最長支援 128 個字元,支援字元:[A-Za-z0-9_-]+ |
my_ad |
| ClientToken |
string |
否 |
等冪參數,每次提交確保唯一性,避免重複提交表單,最長支援 200 個字元 |
****0311a423d11a5f7dee713535**** |
| ContentUrlPrefix |
string |
是 |
內容 URL 首碼,支援 http/https 協議,最長支援 512 個字元 |
https://source.com/ |
| SlateAdUrl |
string |
否 |
slate 廣告 URL,支援 http/https 協議,只支援 MP4 類型檔案(.mp4),最長支援 2048 個字元 |
http://storage.com/slate1.mp4 |
| ConfigAliases |
string |
否 |
動態配置別名,json 字串,其中 player_params.{name}最多添加 20 個,name 部分限制 150 個字元長度,每個 player_params.xxx 下最多添加 50 對 key-value,key 限制 150 個字元長度,value 限制 500 個字元長度,例: { "player_params.{name}": { "{key}": "{value}" } } |
{ "player_params.p1": { "1": "abc" } } |
| CdnContentSegmentUrlPrefix |
string |
否 |
視頻內容分區的 CDN 首碼,支援 http/https 協議,最長支援 512 個字元 |
http://cdn.com/ |
| CdnAdSegmentUrlPrefix |
string |
否 |
廣告分區的 CDN 首碼,支援 http/https 協議,最長支援 512 個字元 |
http://cdn.com/ |
| AdMarkerPassthrough |
string |
否 |
廣告標記透傳,ON/OFF,預設 OFF 枚舉值:
|
ON |
| PersonalizationThreshold |
integer |
否 |
個人化配置閾值,單位秒,不填預設 8 秒 |
5 |
| AdsUrl |
string |
是 |
廣告策略伺服器 URL,支援 http/https 協議,最長支援 2048 個字元 |
http://ads.com/ad1?param1=[palyer_params.p1] |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
Schema of Response |
||
| Config |
object |
廣告插入配置 |
|
| CreateTime |
string |
建立時間 |
2024-06-13T08:26:09Z |
| LastModified |
string |
修改時間 |
2024-06-13T08:26:09Z |
| Name |
string |
廣告插入配置名稱 |
my_ad |
| ContentUrlPrefix |
string |
內容 URL 首碼 |
https://source.com/ |
| AdsUrl |
string |
廣告策略伺服器 URL |
http://ads.com/ad1?param1=[palyer_params.p1] |
| ConfigAliases |
string |
動態配置別名 |
{ "player_params.p1": { "1": "abc" } } |
| PersonalizationThreshold |
integer |
個人化配置閾值 |
5 |
| SlateAdUrl |
string |
slate 廣告 URL |
http://storage.com/slate1.mp4 |
| CdnConfig |
object |
CDN 配置 |
|
| ContentSegmentUrlPrefix |
string |
視頻內容分區的 CDN 首碼 |
http://cdn.com/ |
| AdSegmentUrlPrefix |
string |
廣告分區的 CDN 首碼 |
http://cdn.com/ |
| AdMarkerPassthrough |
string |
廣告標記透傳 |
ON |
| ManifestEndpointConfig |
object |
清單播放端點配置 |
|
| HlsPrefix |
string |
HLS 清單播放端點首碼 |
https://****0311a423d11a5f7dee713535****.weaverpull-ssai.ap-southeast-1.ice.alibabacloudcs.com/v1/master/****4fda5b1a8e0d46c9bf6262a7****/my_ad/ |
| DashPrefix |
string |
DASH 清單播放端點首碼 |
https://****0311a423d11a5f7dee713535****.weaverpull-ssai.ap-southeast-1.ice.alibabacloudcs.com/v1/dash/****4fda5b1a8e0d46c9bf6262a7****/my_ad/ |
| RequestId |
string |
請求 ID |
******3B-0E1A-586A-AC29-742247****** |
樣本
正常返回樣本
JSON格式
{
"Config": {
"CreateTime": "2024-06-13T08:26:09Z",
"LastModified": "2024-06-13T08:26:09Z\n",
"Name": "my_ad",
"ContentUrlPrefix": "https://source.com/\n",
"AdsUrl": "http://ads.com/ad1?param1=[palyer_params.p1]\n",
"ConfigAliases": "{ \"player_params.p1\": { \"1\": \"abc\" } }\n",
"PersonalizationThreshold": 5,
"SlateAdUrl": "http://storage.com/slate1.mp4\n",
"CdnConfig": {
"ContentSegmentUrlPrefix": "http://cdn.com/\n",
"AdSegmentUrlPrefix": "http://cdn.com/\n"
},
"AdMarkerPassthrough": "ON",
"ManifestEndpointConfig": {
"HlsPrefix": "https://****0311a423d11a5f7dee713535****.weaverpull-ssai.ap-southeast-1.ice.alibabacloudcs.com/v1/master/****4fda5b1a8e0d46c9bf6262a7****/my_ad/\n",
"DashPrefix": "https://****0311a423d11a5f7dee713535****.weaverpull-ssai.ap-southeast-1.ice.alibabacloudcs.com/v1/dash/****4fda5b1a8e0d46c9bf6262a7****/my_ad/"
}
},
"RequestId": "******3B-0E1A-586A-AC29-742247******"
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。