curl --request POST \
--url https://api.anam.ai/v1/avatar-videos \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"script": "Welcome to the product tour.",
"personaId": "00000000-0000-0000-0000-000000000000",
"metadata": {
"customerJobId": "onboarding-42"
}
}
'{
"id": "avv_123",
"status": "pending",
"truncated": true,
"effectiveMaxDurationSeconds": 123,
"region": "eu",
"zeroDataRetention": true,
"content": {
"available": true,
"deleteAt": "2023-11-07T05:31:56Z",
"url": "<string>",
"expiresAt": "2023-11-07T05:31:56Z"
},
"createdAt": "2023-11-07T05:31:56Z",
"metadata": {},
"completionReason": "script_completed",
"durationSeconds": 123,
"sessionId": "<string>",
"failure": {
"code": "<string>",
"message": "<string>",
"retryable": true
},
"retryOf": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z"
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}create avatar video
Creates an asynchronous avatar-video render backed by a normal recorded Anam session. A saved persona contributes only its snapshotted avatar, voice, language, model and director notes; its greeting, brain, prompt and tools never run. The request is rejected rather than queued when either concurrency limit is full.
curl --request POST \
--url https://api.anam.ai/v1/avatar-videos \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"script": "Welcome to the product tour.",
"personaId": "00000000-0000-0000-0000-000000000000",
"metadata": {
"customerJobId": "onboarding-42"
}
}
'{
"id": "avv_123",
"status": "pending",
"truncated": true,
"effectiveMaxDurationSeconds": 123,
"region": "eu",
"zeroDataRetention": true,
"content": {
"available": true,
"deleteAt": "2023-11-07T05:31:56Z",
"url": "<string>",
"expiresAt": "2023-11-07T05:31:56Z"
},
"createdAt": "2023-11-07T05:31:56Z",
"metadata": {},
"completionReason": "script_completed",
"durationSeconds": 123,
"sessionId": "<string>",
"failure": {
"code": "<string>",
"message": "<string>",
"retryable": true
},
"retryOf": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z"
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}{
"code": "<string>",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"details": {}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Stable caller-generated key. Reusing it with the same body returns the original resource; a different body returns 409.
1 - 255Body
- Option 1
- Option 2
Exact text spoken through TTS; the brain is never invoked.
1 - 20000Saved persona to snapshot. Mutually exclusive with direct configuration fields.
"cara-4-latest"
Show child attributes
Show child attributes
"en"
-1 <= x <= 1Voice generation options for Cartesia Sonic-3 models.
- Cartesia Sonic-3
- ElevenLabs V1
- ElevenLabs V2
- ElevenLabs V3
- ElevenLabs V4
- Fish Audio
Show child attributes
Show child attributes
x >= 1x >= 1Optional engine routing for the render session, as on the session token endpoint. Internal accounts only; other accounts get 403.
Show child attributes
Show child attributes
Caller metadata, up to 16 KB serialized. It is stored and returned as sent. A zero-data-retention video, which includes every video created on a regional host, doesn't store it: its responses return {}. Keep your own mapping from the video id to your records.
Seconds to keep the recording, session report and job content after the job ends; Lab then deletes them within about a minute. Without a value, they are kept until deleted. Download the recording as soon as it is ready.
300 <= x <= 2592000Response
Accepted. Poll the returned resource.
"avv_123"
pending, running, finalizing, completed, failed, cancelled Region the job is pinned to: eu when created on api.eu.anam.ai, us when created on api.us.anam.ai. Its session, recording and retries stay in that region. Null when created on api.anam.ai.
eu, us, null Whether the job runs with Zero Data Retention, which keeps its script, and a direct request's style prompts, out of Lab's database. A persona-sourced job's director notes stay in its stored persona. Always true for a job created on a regional host.
Show child attributes
Show child attributes
script_completed, max_duration_reached, cancelled, null Underlying normal EngineSession ID. Use its recording deletion endpoint for deletion.
Show child attributes
Show child attributes
Was this page helpful?

