Skip to main content
The resources (image, video, voice) generated by our API are valid for 7 days. Please save the relevant resources as soon as possible to prevent expiration.
Experience our video translation technology in action by exploring our interactive demo on GitHub: AKool Video Translation Demo.

Get AI Voices List

GET https://openapi.akool.com/api/open/v4/voice/videoTranslation
Request Headers
ParameterValueDescription
x-api-keyAPI KeyYour API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.
AuthorizationBearer {token}Your API Key used for request authorization.Get Token.
Query Parameters
ParameterTypeRequiredValueDescription
language_codeStringfalsezh-CN-shandongLanguage code, used to filter voice list for specific language
pageIntegerfalse1Page number, default is 1
sizeIntegerfalse100Items per page, default is 100
Response Attributes
ParameterTypeDescription
codeIntegerInterface returns business status code(1000:success)
msgStringInterface returns status information
dataObjectResponse data object
- pageIntegerCurrent page number
- sizeIntegerItems per page
- countIntegerTotal number of items
- resultArrayArray of voice items
— _idStringUnique identifier for the voice
— voice_idStringVoice ID used for API calls
— genderStringVoice gender (Male/Female)
— languageStringVoice language name
— nameStringVoice name
— previewStringPreview audio URL
— thumbnailUrlStringVoice avatar image URL
— create_timeIntegerVoice creation timestamp
— flag_urlStringLanguage flag image URL
— useCaseStringVoice use case category
— categoryStringVoice category
— ageArrayAge range tags
— styleArrayVoice style tags
— durationIntegerPreview audio duration in milliseconds
— scenarioArrayRecommended usage scenarios
— language_codeStringLanguage code identifier
Example Request
curl --location 'https://openapi.akool.com/api/open/v4/voice/videoTranslation?language_code=zh-CN-shandong&page=1&size=100' \
--header 'x-api-key: {{API Key}}'
Response
{
    "code": 1000,
    "msg": "OK",
    "data": {
        "page": 1,
        "size": 100,
        "count": 1,
        "result": [
            {
                "_id": "671777eadefc20dd56512948",
                "voice_id": "6889b755662160e2caad5fdf",
                "gender": "Male",
                "language": "Chinese (Jilu Mandarin, Simplified)",
                "name": "Honest Big Brother",
                "preview": "https://d3c24lvfmudc1v.cloudfront.net/agicontent/voices/1749809765037-audio.mp3",
                "thumbnailUrl": "https://static.website-files.org/assets/voiceover_face/compressed_image_1742893228182.jpg",
                "create_time": 1729353600000,
                "flag_url": "https://static.website-files.org/assets/national_flag/China.png",
                "useCase": "Conversational",
                "category": "conversational",
                "age": [
                    "Middle aged"
                ],
                "style": [
                    "casual",
                    "animated",
                    "strong"
                ],
                "duration": 10116,
                "scenario": [
                    "chat",
                    "podcast"
                ],
                "language_code": "zh-CN-shandong"
            }
        ]
    }
}

Get Language List Result

GET https://openapi.akool.com/api/open/v3/language/list
Request Headers
ParameterValueDescription
x-api-keyAPI KeyYour API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.
AuthorizationBearer {token}Your API Key used for request authorization.Get Token.
Response Attributes
ParameterTypeDescription
codeIntegerInterface returns business status code(1000:success)
msgStringInterface returns status information
dataObjectResponse data object
- lang_listArrayArray of supported languages
— lang_nameStringLanguage name (e.g., “Afrikaans (South Africa)”)
— lang_codeStringLanguage code (e.g., “af-ZA”)
— urlStringLanguage flag icon URL
— need_voice_idBooleanWhether this language requires selecting an AI voice ID
Example Request
curl --location 'https://openapi.akool.com/api/open/v3/language/list' \
--header 'x-api-key: {{API Key}}'
Response
{
    "code": 1000,
    "msg": "OK",
    "data": {
        "lang_list": [
            {
                "lang_name": "Afrikaans (South Africa)",
                "lang_code": "af-ZA",
                "url": "https://d11fbe263bhqij.cloudfront.net/public/landing/icons/nf/af-ZA.png",
                "need_voice_id": true
            },
            {
                "lang_name": "Albanian (Albania)",
                "lang_code": "sq-AL",
                "url": "https://d11fbe263bhqij.cloudfront.net/public/landing/icons/nf/sq-AL.png",
                "need_voice_id": true
            },
            {
                "lang_name": "Amharic (Ethiopia)",
                "lang_code": "am-ET",
                "url": "https://d11fbe263bhqij.cloudfront.net/public/landing/icons/nf/am-ET.png",
                "need_voice_id": true
            }
      ]
    }
}

Create video translation

POST https://openapi.akool.com/api/open/v3/content/video/createbytranslate
Request Headers
ParameterValueDescription
x-api-keyAPI KeyYour API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.
AuthorizationBearer {token}Your API Key used for request authorization.Get Token.
Body Attributes
ParameterTypeRequiredValueDescription
urlStringtrueThe video url address you want to translate.
source_languageStringtrueThe original language of the video.
languageStringtrueThe language you want to translate into. If you want to translate into multiple languages at once, separate them with commas in English format.
lipsyncBooleanfalsetrue/falseGet synchronized mouth movements with the audio track in a translated video.
merge_intervalNumberfalse1The segmentation interval of video translation, the default is 1 second. This field is deprecated
face_enhanceBooleanfalsetrue/falseWhether to facial process the translated video, this parameter only works when lipsync is true. This field is deprecated
webhookUrlStringfalseCallback url address based on HTTP request.
speaker_numNumberfalse0Number of speakers in the video, the default is 0 (Auto Detect).
remove_bgmBooleanfalsefalseWhether to remove background music (default: false)
caption_typeNumberfalse0Caption type (default: 0, 0 none;1 add original subtitle;2 add target subtitle;3 translate and replace original subtitle;4 add translated subtitle;)
caption_urlStringfalseCaption URL (default: ""), subtitle file address, support SRT or ASS files.
voices_mapObjectfalseVoice Language maps
-[language_code]Objecttrue{"voice_id": "6889b755662160e2caad5fdf"}Target language code map
—voice_idStringtrue"" or “6889b755662160e2caad5fdf”Voice ID corresponding to the target language code, getVoiceId
studio_voiceObjectfalseStudio voice settings
-no_translate_wordsArrayfalse[“kaka”,“lal”]List of words that do not need to be translated
-styleStringfalseprofessionalTranslation style, available values: ‘affectionate’, ‘angry’, ‘calm’, ‘cheerful’, ‘depressed’, ‘disgruntled’, ‘embarrassed’, ‘empathetic’, ‘excited’, ‘fearful’, ‘friendly’, ‘unfriendly’, ‘sad’, ‘serious’, ‘relaxed’, ‘professional’
-fixed_wordsObjectfalse{"hi": "hello", "bad": "good"}Translation word mapping table for corrections
-pronounced_wordsObjectfalse{"lel": "lele", "gga": "gaga"}Pronunciation correction word mapping table
Response Attributes
ParameterTypeValueDescription
codeint1000Interface returns business status code(1000:success)
msgStringInterface returns status information
dataObject{ "_id": "", "video_status": 1, "video": "" }_id: Interface returns data, video_status: the status of video: [1:queueing, 2:processing, 3:completed, 4:failed], video: the url of Generated video
Example Body
{
    "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",
    "voices_map": {
        "ja": {
            "voice_id": ""
        },
        "zh-CN-shandong": {
            "voice_id": "6889b755662160e2caad5fdf"
        },
        "zh-CN-sichuan": {
            "voice_id": "6889b74e662160e2caad5fd5"
        }
    },
    "studio_voice": {
      "no_translate_words": ["kaka","lal"],
      "fixed_words": {"hi": "hello", "bad": "good"},
      "pronounced_words": {"lel": "lele", "gga": "gaga"},
      "style": "professional"
   }
}
Request
curl --location 'https://openapi.akool.com/api/open/v3/content/video/createbytranslate' \
--header "x-api-key: {{API Key}}" \
--header 'Content-Type: application/json' \
--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",
    "voices_map": {
        "ja": {
            "voice_id": ""
        },
        "zh-CN-shandong": {
            "voice_id": "6889b755662160e2caad5fdf"
        },
        "zh-CN-sichuan": {
            "voice_id": "6889b74e662160e2caad5fd5"
        }
    },
    "studio_voice": {
      "no_translate_words": ["kaka","lal"],
      "fixed_words": {"hi": "hello", "bad": "good"},
      "pronounced_words": {"lel": "lele", "gga": "gaga"},
      "style": "professional"
   }
}'
Response
{
  "code": 1000,
  "msg": "OK",
  "data": {
    "_id": "68ccee42e267570255824ab5",
    "create_time": 1758260802773,
    "uid": 101400,
    "team_id": "6805fb69e92d9edc7ca0b409",
    "target_video": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
    "language": "ja",
    "source_language": "en",
    "video_id": "68ccee42f392598dae31999b",
    "video_status": 1,
    "video_lock_duration": 16.44,
    "deduction_lock_duration": 4,
    "video": "",
    "credentialId": "6823024be0c8e98471611c72",
    "task_id": "68ccee42f392598dae31999b",
    "target_video_md5": "md5_1758260802301",
    "lipsync": false,
    "lipSyncType": 0,
    "speaker_num": 1,
    "webhookUrl": ""
  },
  "all_results": [
    {
      "code": 1000,
      "msg": "OK",
      "data": {
        "_id": "68da023e776f4277705a7887",
        "create_time": 1759117886720,
        "uid": 101400,
        "team_id": "6805fb69e92d9edc7ca0b409",
        "target_video": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
        "language": "hi",
        "source_language": "en",
        "video_id": "68da023ef392598dae319ada",
        "video_status": 1,
        "video_lock_duration": 16.44,
        "deduction_lock_duration": 4,
        "video": "",
        "credentialId": "6823024be0c8e98471611c72",
        "task_id": "68da023ef392598dae319ada",
        "target_video_md5": "md5_1759117886236",
        "lipsync": false,
        "lipSyncType": 0,
        "speaker_num": 1
      }
    },
    {
      "code": 1000,
      "msg": "OK",
      "data": {
        "_id": "68da023f776f4277705a788b",
        "create_time": 1759117887169,
        "uid": 101400,
        "team_id": "6805fb69e92d9edc7ca0b409",
        "target_video": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
        "language": "fr",
        "source_language": "en",
        "video_id": "68da023ff392598dae319adb",
        "video_status": 1,
        "video_lock_duration": 16.44,
        "deduction_lock_duration": 4,
        "video": "",
        "credentialId": "6823024be0c8e98471611c72",
        "task_id": "68da023ff392598dae319adb",
        "target_video_md5": "md5_1759117886236",
        "lipsync": false,
        "lipSyncType": 0,
        "speaker_num": 1
      }
    },
    {
      "code": 1000,
      "msg": "OK",
      "data": {
        "_id": "68da023f776f4277705a7890",
        "create_time": 1759117887643,
        "uid": 101400,
        "team_id": "6805fb69e92d9edc7ca0b409",
        "target_video": "https://d11fbe263bhqij.cloudfront.net/agicontent/video/translate/cut3_content_create_EN_01.mp4",
        "language": "ja",
        "source_language": "en",
        "video_id": "68da023f6ae5f91ba94f6f8e",
        "video_status": 1,
        "video_lock_duration": 16.44,
        "deduction_lock_duration": 4,
        "video": "",
        "credentialId": "6823024be0c8e98471611c72",
        "task_id": "68da023f6ae5f91ba94f6f8e",
        "target_video_md5": "md5_1759117886236",
        "lipsync": false,
        "lipSyncType": 0,
        "speaker_num": 1
      }
    }
  ]
}

Get Video Info Result

GET https://openapi.akool.com/api/open/v3/content/video/infobymodelid
Request Headers
ParameterValueDescription
x-api-keyAPI KeyYour API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.
AuthorizationBearer {token}Your API Key used for request authorization.Get Token.
Query Attributes
ParameterTypeValueDescription
video_model_idStringNULLvideo db id: You can get it based on the _id field returned by Create By Translate API .
Response Attributes
ParameterTypeValueDescription
codeint1000Interface returns business status code(1000:success)
msgStringOKInterface returns status information
dataObject{ video_status:1, _id:"", video:"" }video_status: the status of video: [1:queueing, 2:processing, 3:completed, 4:failed] video: Generated video resource url _id: Interface returns data
Example Request
curl --location 'http://openapi.akool.com/api/open/v3/content/video/infobymodelid?video_model_id=64b126c4a680e8edea44f02b' \
--header "x-api-key: {{API Key}}"
Response
{
  "code": 1000,
  "msg": "OK",
  "data": {
    "faceswap_quality": 2,
    "storage_loc": 1,
    "_id": "64dd92c1f0b6684651e90e09",
    "create_time": 1692242625334,
    "uid": 378337,
    "type": 2,
    "from": 1,
    "video_id": "0acfed62e24f4cfd8801c9e846347b1d",
    "video_lock_duration": 7.91,
    "deduction_lock_duration": 10,
    "video_status": 2,
    "external_video": "",
    "lipsync_video_url": "",
    "video": ""
  }
}
Response Code Description
Please note that if the value of the response code is not equal to 1000, the request is failed or wrong
ParameterValueDescription
code1000Success
code1003Parameter error or Parameter can not be empty
code1008The content you get does not exist
code1009You do not have permission to operate
code1101Invalid authorization or The request token has expired
code1102Authorization cannot be empty
code1200The account has been banned
code1201create audio error, please try again later
code1202The same video cannot be translated lipSync in the same language more than 1 times
code1203video should be with audio
code1204Your video duration is exceed 60s!
code1205Create video error, please try again later
code1207The video you are using exceeds the size limit allowed by the system by 300M
code1209Please upload a video in another encoding format
code1210The video you are using exceeds the value allowed by the system by 30fp
I