v1
latestOpenAPI 3.0.32026-07-241112213.6 KBSubmit Task
Submit an asynchronous Photo Avatar task. Returns a taskId; poll the Query Task endpoint for the result.
Script source (scriptMode):
- text: text-to-speech, requires ttsText and voiceId; voiceModel and voiceSettings are optional.
- audio: use an uploaded audio file, requires audioFileId.
Credits: billing type photo_avatar4, charged by generated video duration (seconds, rounded up); avatar4=0.1/s, avatar4Fast=0.06/s, avatar2=0.4/s; 50% off when offPeak=true and mode=avatar4/avatar4Fast. Settled on success, fully refunded on failure.
post/v1/photo_avatar/task/submit
Headers
Topview-Uidstring required
User ID
Authorizationstring required
API key, format: Bearer {apiKey}
Request body
Example request
{
"avatarId": "avatar-001",
"templateImageFileId": "file-123",
"mode": "avatar4",
"scriptMode": "text",
"ttsText": "Hi everyone, I am a digital avatar.",
"voiceId": "voice-888",
"voiceModel": "elevenlabs-v3",
"voiceSettings": {
"volume": 100,
"stability": 50
},
"audioFileId": "file-audio-001",
"captionId": "caption-001",
"customMotion": "smile, wave",
"saveCustomAiAvatar": "false",
"offPeak": true,
"boardId": "board-12345",
"noticeUrl": "https://example.com/topview/callback"
}Response
Accepted (the task has been created and entered the processing pipeline; poll the query endpoint for the execution result)
Example response
{
"code": "200",
"message": "Success",
"result": {
"taskId": "task-123456",
"status": "init"
}
}