添加自定义转码模板
POST
https://live.jdcloud-api.com/v1/transcodeCustoms:template
名称 | 类型 | 是否必需 | 默认值 | 描述 |
---|---|---|---|---|
videoCodec | String | False | 视频编码格式,取值:h264,h265,默认h264 |
|
videoCodeRate | Integer | True | 转码输出的码率值 - 取值范围: [128,15000] - 单位: kpbs |
|
videoFrameRate | String | True | 转码输出的帧率值 - 取值:[1,30] |
|
width | Integer | False | 转码输出视频宽度 - 取值: [128,4096] - 如果(width,height)只设置其中之一,则按所设置参数项等比缩放另一项输出转码 - 如果(width,height)都不设置,则按源流大小输出转码 |
|
height | Integer | False | 转码输出视频宽度 - 取值: [128,4096] - 如果(width,height)只设置其中之一,则按所设置参数项等比缩放另一项输出转码 - 如果(width,height)都不设置,则按源流大小输出转码 |
|
template | String | True | 转码模板(转码流输出后缀) - 取值要求:数字、大小写字母或短横线("-"),必须以数字或字母作为开头和结尾,长度不超过50字符 - 注意: 不能与系统的标准的转码模板和当前用户已自定义命名重复 - 系统标准转码模板 ld (h.264/640 * 360/15f) sd (h.264/854 * 480/25f) hd (h.264/1280 * 720/25f) shd (h.264/1920 * 1080/30f) 2k (h.264/2560 * 1440/30f) 4k (h.264/3840 * 2160/30f) ld-265 (h.265/640 * 360/15f) sd-265 (h.265/854 * 480/25f) hd-265 (h.265/1280 * 720/25f) shd-265 (h.265/1920 * 1080/30f) 2k-265 (h.265/2560 * 1440/30f) 4k-265 (h.265/3840 * 2160/30f) |
|
audioCodec | String | True | 转码输出音频编码格式 - 取值: aac、mp3 - 不区分大小写 |
|
audioFormat | String | True | 转码输出音频格式 - 取值: aac_lc,aac_low,aac_he,aac_he_v2 - 不区分大小写 |
|
audioSampleRate | Integer | True | 转码输出音频采样率 - 取值: [44100,48000] |
|
audioChannel | Integer | True | 转码输出音频通道数 1: 单声道 2: 双声道 |
|
audioCodeRate | Integer | True | 转码输出音频码率 - 取值: [16,128] - 单位: kbps |
|
jdchd | String | False | 京享超清开关 - 取值: jdchd-1.0,off - 京享超清暂时只支持h.264 |
|
audioComfort | String | False | 舒适音频 - 取值: on,off |
名称 | 类型 | 描述 |
---|---|---|
requestId | String | requestId |
返回码 | 描述 |
---|---|
200 | OK |
400 | Invalid parameter |
401 | Authentication failed |
404 | Not found |
500 | Internal server error |
503 | Service unavailable |
POST
https://live.jdcloud-api.com/v1/transcodeCustoms:template
{ "audioChannel": 2, "audioCodeRate": 48, "audioCodec": "aac", "audioFormat": "aac_lc", "audioSampleRate": 44100, "height": 1080, "template": "yt", "videoCodeRate": 1500, "videoFrameRate": "30", "width": 1920 }
{ "requestId": "bgvmivir54gddpgi764se9f4kfr7ge41" }