机器翻译
参数 | 类型 | 是否必填 | 示例值 | 描述 |
参数 | 类型 | 是否必填 | 示例值 | 描述 |
Action | String | 是 | VideoProjectSerialDubTaskCreate | 调用的接口名称,固定为:VideoProjectSerialDubTaskCreate |
Version | String | 是 | 2021-05-21 | API 版本号,固定为:2021-05-21 |
projectId | String | 是 | | 项目 id,创建任务的所属项目 |
taskInfo | Object | 是 | { "taskName": "test_video_task", "serialNumber": 1, "sourceLang": "zh", "targetLangs": [ "en", "th" ], "aiRemoveType": 2, "isDub": true, "bgmPolicy": 0, "dubVoiceMode": 0, "suppressionParams": { "excludeSubtitle": false }, "needVideoSpeed": true, "maxTargetSubtitleLines": 3, "targetStyleMap": { en: "{\"fontSize\":11,\"textColor\":\"#000000\",\"textAlpha\":1,\"borderWidth\":\"\",\"backgroundColor\":\"#ffffff\",\"backgroundAlpha\":0,\"alignment\":0,\"x\":0,\"y\":-0.9,\"linePadding\":1,\"maxWidth\":1,\"fontFamily\":\"loki://98301255\"}" }, "sourceStyleMap": { en: "{\"fontSize\":11,\"textColor\":\"#000000\",\"textAlpha\":1,\"borderWidth\":\"\",\"backgroundColor\":\"#ffffff\",\"backgroundAlpha\":0,\"alignment\":0,\"x\":0,\"y\":-0.9,\"linePadding\":1,\"maxWidth\":1,\"fontFamily\":\"loki://98301255\"}" } "dubOrTranslationTaskID": "1234", "auditFailPolicy": 0 } | 配音任务详细信息
|
serialInfo | Array of Object | 是 | [ { "episode": 1, "video": { "videoUrl":"https://xxxx/test_1.mp4", "name": "1.mp4" }, "subtitle": { "uri": "xxx", "name": "xxx字幕文件.srt", "fileType": 1, "subtitleLang": 1, "arrangement": 1, }, "subtitles": [ { "uri": "xxx", "name": "xxx字幕文件.srt", "fileType": 1, "targetLang": "en", "subtitleLang": 1, "arrangement": 1, } ] } ] | 配音剧集信息列表,数组,每个元素描述一集的资源,包括以下信息
|
字体名称 | value | 对应的id |
字体名称 | value | 对应的id |
Amita-Bold | amita_bold | loki://14444020 |
Eczar-SemiBold | eczar_semibold | loki://13897166 |
Harmattan-Regular | harmattan_regular | loki://14035806 |
Kurale-Regular | kurale_regular | loki://14449082 |
Martel Sans-Black | martelsans_black | loki://13891582 |
Martel Sans-Bold | martelsans_bold | loki://13891540 |
Martel Sans-ExtraBold | martelsans_extrabold | loki://13891048 |
Martel Sans-ExtraLight | martelsans_extralight | loki://13855100 |
Martel Sans-Light | martelsans_light | loki://13889692 |
Martel Sans-Regular | martelsans_regular | loki://13890920 |
Martel Sans-SemiBold | martelsans_semibold | loki://13889674 |
Mirza-Regular | mirza_regular | loki://14471318 |
Poppins-Regular | poppins_regular | loki://13853206 |
RozhaOne-Regular | rozhaone_regular | loki://14131940 |
SinkinSans-400Regular | sinkinsans_regular | loki://10608858 |
WixMadeforText-Rg | wixmadefortext_regular | loki://20853453 |
Arimo-VariableFont | arimo_variable | loki://98301255 |
Montserrat-Bold | montserrat_bold | loki://98604010 |
NotoSansKR-B | notosanskr_bold | loki://98659002 |
Sarabun | sarabun | loki://132212773 |
MinSans-Bold | minsans_bold | loki://98657494 |
NotoSans-Bold | notosans_bold | loki://135308526 |
NotoSans-Medium | notosans_medium | loki://220633655 |
Gen Shin Gothic P Bold | genshingothic_p_bold | loki://127504594 |
NotoSans-CJK | notosans_cjk | loki://228190238 |
Noto Serif-CJK | notoserif_cjk | loki://241348364 |
NotoSans-THai-Medium | notosans_thai_medium | loki://228190282 |
NotoSans-Arabic-Medium | notosans_arabic_medium | loki://228190477 |
NotoSans-Devanagari-Medium | notosans_devanagari_medium | loki://228190334 |
参数 | 类型 | 示例值 | 描述 |
参数 | 类型 | 示例值 | 描述 |
data | | { TaskIDs: ['12312','23432'], SubtitleFileCheckReports: [ { "EpisodeNum": "1", "SourceLanguage": "zh", "TargetLanguage": "en", "Issues": [ { "CheckPass": false, "Code": 211313, "Msg": "Error_211313" } ] } ] } | 创建任务的返回结果
|
参数 | 类型 | 示例值 | 描述 |
参数 | 类型 | 示例值 | 描述 |
Error.Code | String | 1001 | |
Error.Message | String |
| 当创建失败时,会返回具体原因,本接口会校验以下问题
|
错误码 | 含义 |
错误码 | 含义 |
Error_211311 | 字幕文件缺失 |
Error_211312 | 字幕校验参数缺失 |
Error_211313 | 字幕文件无法解析,可能是文件不存在或者格式错误 |
Error_211314 | 字幕内容缺失 |
Error_211315 | 字幕时间大于视频时长 |
Error_211316 | 字幕时间小于0 |
Error_211317 | 字幕是双语字幕 |
Error_211318 | 字幕批量校验失败 |
Error_211331 | 缺少/无效的序列号 |
Error_211332 | 缺少时间轴 |
Error_211333 | 缺少字幕文本 |
Error_211334 | 时间轴错误 |
Error_211335 | 时间轴格式错误 |