Create Custom Avatar
Create a custom avatar and voice clone using a video.
1. API endpoint
POST https://app.aistudios.com/api/odin/v3/avatars/customavatar
2. Request parameter
key | desc | type | required | default |
---|---|---|---|---|
url | Video URL | String | true | - |
name | Name of the custom avatar and voice clone | String | true | - |
gender | Gender of the custom avatar and voice clone | String enum (MALE, FEMALE) | true | - |
locale | Language of the voice clone sample voice | String enum (en, ko, zh) | false | en |
perFrame | Whether the video has person movements | Boolean | false | true |
isWebcam | Whether the video is recorded with a webcam | Boolean | false | false |
3. Response parameters
key | desc | type |
---|---|---|
avatarId | ID of the created custom avatar | String |
voiceId | ID of the created voice clone | String |
4. Sample Request
- cURL
- Node.js
- Python
curl https://app.aistudios.com/api/odin/v3/avatars/customavatar \
-H "Authorization: ${API KEY}" \
-H "Content-Type: application/json" \
-X POST \
-d '{
"url": "https://cdn.aistudios.com/uploads/models/en/M000351175_BG00001308.mp4",
"name": "Ian",
"gender": "MALE",
"locale": "en",
"perFrame": false,
"isWebcam": true
}'
import axios from "axios";
const token = ${API KEY};
axios.post('https://app.aistudios.com/api/odin/v3/avatars/customavatar',
{
"url": "https://cdn.aistudios.com/uploads/models/en/M000351175_BG00001308.mp4",
"name": "Ian",
"gender": "MALE",
"locale": "en",
"perFrame": false,
"isWebcam": true
},
{
headers: {
'Authorization': ${token},
'Content-Type': 'application/json'
}
}
)
.then((res) => {
console.log(res.data);
})
.catch((error) => {
console.error(error);
})
import requests
import json
url = "https://app.aistudios.com/api/odin/v3/avatars/customavatar"
body = {
"url": "https://cdn.aistudios.com/uploads/models/en/M000351175_BG00001308.mp4",
"name": "Ian",
"gender": "MALE",
"locale": "en",
"perFrame": false,
"isWebcam": true
}
headers = {
"Content-Type": "application/json",
"Authorization": ${API TOKEN}
}
r = requests.post(url, data=json.dumps(body), headers=headers)