curl --request POST \
--url https://openapi.akool.com/api/open/v3/content/video/createbytranslate \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"url": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
"language": "ja,zh-CN-shandong,zh-CN-sichuan",
"source_language": "en",
"lipsync": false,
"speaker_num": 1,
"webhookUrl": "",
"remove_bgm": true,
"caption_type": 2,
"caption_url": "https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt",
"studio_voice": {
"no_translate_words": [
"kaka",
"lal"
],
"fixed_words": {
"hi": "hello",
"bad": "good"
},
"pronounced_words": {
"lel": "lele",
"gga": "gaga"
},
"style": "professional"
},
"dynamic_duration": false
}
'import requests
url = "https://openapi.akool.com/api/open/v3/content/video/createbytranslate"
payload = {
"url": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
"language": "ja,zh-CN-shandong,zh-CN-sichuan",
"source_language": "en",
"lipsync": False,
"speaker_num": 1,
"webhookUrl": "",
"remove_bgm": True,
"caption_type": 2,
"caption_url": "https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt",
"studio_voice": {
"no_translate_words": ["kaka", "lal"],
"fixed_words": {
"hi": "hello",
"bad": "good"
},
"pronounced_words": {
"lel": "lele",
"gga": "gaga"
},
"style": "professional"
},
"dynamic_duration": False
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: 'https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4',
language: 'ja,zh-CN-shandong,zh-CN-sichuan',
source_language: 'en',
lipsync: false,
speaker_num: 1,
webhookUrl: '',
remove_bgm: true,
caption_type: 2,
caption_url: 'https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt',
studio_voice: {
no_translate_words: ['kaka', 'lal'],
fixed_words: {hi: 'hello', bad: 'good'},
pronounced_words: {lel: 'lele', gga: 'gaga'},
style: 'professional'
},
dynamic_duration: false
})
};
fetch('https://openapi.akool.com/api/open/v3/content/video/createbytranslate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.akool.com/api/open/v3/content/video/createbytranslate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'url' => 'https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4',
'language' => 'ja,zh-CN-shandong,zh-CN-sichuan',
'source_language' => 'en',
'lipsync' => false,
'speaker_num' => 1,
'webhookUrl' => '',
'remove_bgm' => true,
'caption_type' => 2,
'caption_url' => 'https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt',
'studio_voice' => [
'no_translate_words' => [
'kaka',
'lal'
],
'fixed_words' => [
'hi' => 'hello',
'bad' => 'good'
],
'pronounced_words' => [
'lel' => 'lele',
'gga' => 'gaga'
],
'style' => 'professional'
],
'dynamic_duration' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://openapi.akool.com/api/open/v3/content/video/createbytranslate"
payload := strings.NewReader("{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://openapi.akool.com/api/open/v3/content/video/createbytranslate")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.akool.com/api/open/v3/content/video/createbytranslate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}"
response = http.request(request)
puts response.read_body{
"code": 123,
"msg": "<string>",
"data": {
"_id": "<string>",
"video_status": 123,
"video": "<string>"
}
}Create Video Translation
Translate videos into multiple languages with AI voices and lip-sync
curl --request POST \
--url https://openapi.akool.com/api/open/v3/content/video/createbytranslate \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"url": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
"language": "ja,zh-CN-shandong,zh-CN-sichuan",
"source_language": "en",
"lipsync": false,
"speaker_num": 1,
"webhookUrl": "",
"remove_bgm": true,
"caption_type": 2,
"caption_url": "https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt",
"studio_voice": {
"no_translate_words": [
"kaka",
"lal"
],
"fixed_words": {
"hi": "hello",
"bad": "good"
},
"pronounced_words": {
"lel": "lele",
"gga": "gaga"
},
"style": "professional"
},
"dynamic_duration": false
}
'import requests
url = "https://openapi.akool.com/api/open/v3/content/video/createbytranslate"
payload = {
"url": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
"language": "ja,zh-CN-shandong,zh-CN-sichuan",
"source_language": "en",
"lipsync": False,
"speaker_num": 1,
"webhookUrl": "",
"remove_bgm": True,
"caption_type": 2,
"caption_url": "https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt",
"studio_voice": {
"no_translate_words": ["kaka", "lal"],
"fixed_words": {
"hi": "hello",
"bad": "good"
},
"pronounced_words": {
"lel": "lele",
"gga": "gaga"
},
"style": "professional"
},
"dynamic_duration": False
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: 'https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4',
language: 'ja,zh-CN-shandong,zh-CN-sichuan',
source_language: 'en',
lipsync: false,
speaker_num: 1,
webhookUrl: '',
remove_bgm: true,
caption_type: 2,
caption_url: 'https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt',
studio_voice: {
no_translate_words: ['kaka', 'lal'],
fixed_words: {hi: 'hello', bad: 'good'},
pronounced_words: {lel: 'lele', gga: 'gaga'},
style: 'professional'
},
dynamic_duration: false
})
};
fetch('https://openapi.akool.com/api/open/v3/content/video/createbytranslate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.akool.com/api/open/v3/content/video/createbytranslate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'url' => 'https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4',
'language' => 'ja,zh-CN-shandong,zh-CN-sichuan',
'source_language' => 'en',
'lipsync' => false,
'speaker_num' => 1,
'webhookUrl' => '',
'remove_bgm' => true,
'caption_type' => 2,
'caption_url' => 'https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt',
'studio_voice' => [
'no_translate_words' => [
'kaka',
'lal'
],
'fixed_words' => [
'hi' => 'hello',
'bad' => 'good'
],
'pronounced_words' => [
'lel' => 'lele',
'gga' => 'gaga'
],
'style' => 'professional'
],
'dynamic_duration' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://openapi.akool.com/api/open/v3/content/video/createbytranslate"
payload := strings.NewReader("{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://openapi.akool.com/api/open/v3/content/video/createbytranslate")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.akool.com/api/open/v3/content/video/createbytranslate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"url\": \"https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4\",\n \"language\": \"ja,zh-CN-shandong,zh-CN-sichuan\",\n \"source_language\": \"en\",\n \"lipsync\": false,\n \"speaker_num\": 1,\n \"webhookUrl\": \"\",\n \"remove_bgm\": true,\n \"caption_type\": 2,\n \"caption_url\": \"https://drz0f01yeq1cx.cloudfront.net/1759979948074-b14aeb874a4547ca81373d140edd02d2-1758273867083fa8fa1ca7cfe409ab7fb07abdb931660translatedsubtitles.srt\",\n \"studio_voice\": {\n \"no_translate_words\": [\n \"kaka\",\n \"lal\"\n ],\n \"fixed_words\": {\n \"hi\": \"hello\",\n \"bad\": \"good\"\n },\n \"pronounced_words\": {\n \"lel\": \"lele\",\n \"gga\": \"gaga\"\n },\n \"style\": \"professional\"\n },\n \"dynamic_duration\": false\n}"
response = http.request(request)
puts response.read_body{
"code": 123,
"msg": "<string>",
"data": {
"_id": "<string>",
"video_status": 123,
"video": "<string>"
}
}merge_interval and face_enhance parameters have been deprecated and are no longer supported.Voice Selection
The API selects the voice type separately for each target language:- Original voice clone (
voice_type: 0): Used when the target language exactly matches one of the following codes:en,fr,zh,ar,bg,hr,cs,da,nl,fil,fi,de,el,hi,hu,id,it,ja,ko,ms,nb,pl,pt,ro,ru,sk,es,sv,ta,tr,uk,vi. - AI voice (
voice_type: 2): Used for target language codes outside this list.
zh selects original voice cloning, while zh-CN selects AI voice. For comma-separated targets, use language codes without surrounding spaces.
You can provide optional voice settings in voices_map, keyed by target language. The server overrides any supplied voice_type according to the rules above and passes the resulting settings to the translation service. This endpoint does not read an ai_voice request parameter. A voice_id is not required by the current OpenAPI request validation.
Video Duration
/api/open/v3/content/video/createbytranslate does not enforce a 60-second duration limit in the current OpenAPI validation. Shorter videos may reduce processing time; keeping videos under 60 seconds is a recommendation, not a request requirement. Downstream processing constraints may still apply.
The separate legacy endpoint /api/open/v3/content/video/translate rejects videos longer than 60 seconds. This restriction does not apply to the Create Video Translation endpoint documented here.Authorizations
Body
The video URL address you want to translate. Current OpenAPI validation does not enforce a 60-second duration limit; shorter videos are recommended for faster processing.
Target language(s) for translation. For multiple languages, separate with commas without surrounding spaces (e.g., "ja,zh-CN-shandong,zh-CN-sichuan"). Exact matches to en, fr, zh, ar, bg, hr, cs, da, nl, fil, fi, de, el, hi, hu, id, it, ja, ko, ms, nb, pl, pt, ro, ru, sk, es, sv, ta, tr, uk, vi use original voice cloning (voice_type 0). Other target codes use AI voice (voice_type 2). For example, zh uses voice_type 0, while zh-CN uses voice_type 2.
The original language of the video. Use "DEFAULT" for automatic language detection, or specify a language code (e.g., "en" for English, "zh" for Chinese, "es" for Spanish)
Enable synchronized mouth movements with the audio track in translated video
Callback URL address for HTTP notifications when processing completes
Number of speakers in the video (0 = Auto Detect)
Whether to remove background music from the video
Caption handling: 0=none, 1=add original subtitle, 2=add target subtitle, 3=translate and replace original subtitle, 4=add translated subtitle
0, 1, 2, 3, 4 Subtitle file URL (supports SRT or ASS files)
Optional voice settings keyed by exact target language code. The server sets the language and overrides voice_type for each target according to the language selection rules. The current OpenAPI validation does not require voice_id.
Show child attributes
Show child attributes
Advanced voice and translation settings
Show child attributes
Show child attributes
Control the dynamic duration of the video