Skip to main content
POST
Create Custom Agent Video

Authorizations

x-api-key
string
header
required

HeyGen API key. Obtain from your HeyGen dashboard.

Headers

Idempotency-Key
string

Optional client-supplied key for safely retrying mutations. Subsequent calls within 24 hours that share this key replay the original response — even if the request body differs slightly (a warning is logged). A retry that arrives while the original is still in flight gets a 409 request_in_progress. Keys must be 1–255 characters from [A-Za-z0-9_:.-]; a UUID is a safe default. Scope is per-endpoint and per-resource: the same key on a different route or path parameter is independent.

Required string length: 1 - 255
Pattern: ^[A-Za-z0-9_\-:.]{1,255}$

Path Parameters

agent_id
string
required

Custom-agent id (e.g. chiron).

Body

application/json

Body for POST /v3/custom-agents/{agent_id}/videos.

Assets (screen recording, still, wallpaper, presenter background) come from the caller — upload via POST /v3/assets/direct-uploads, then pass the resulting URL in the matching *_url field here. This endpoint does NOT accept multipart file uploads.

topic
string
required

What the video should be about.

Required string length: 1 - 512
lane
enum<string> | null

Device lane. Agent infers from the topic when omitted.

Available options:
mac,
iphone,
watch
wallpaper
string | null

neo-green / neo-purple / neo-pink / wwdc26, or a user-supplied HTTP(S) URL.

Maximum string length: 256
avatar_id
string | null

HeyGen avatar id for the on-camera presenter.

Maximum string length: 128
avatar_still_url
string | null

URL of a still image (from /v3/assets/direct-uploads) for talking-photo inference.

Maximum string length: 1024
voice_id
string | null

Voice id for narration (HeyGen or ElevenLabs).

Maximum string length: 128
watch_model
string | null

Watch lane only: <size> <finish> + <band> selector.

Maximum string length: 128
script
string | null

Verbatim voice-over script; agent generates one when omitted.

Maximum string length: 4096
screen_recording_url
string | null

URL of a screen-recording MP4 (from /v3/assets/direct-uploads or your own S3).

Maximum string length: 2048
presenter_background_url
string | null

URL of an image to composite behind the matted avatar.

Maximum string length: 2048
presenter_background_video_url
string | null

URL of a looping video to composite behind the matted avatar.

Maximum string length: 2048

Response

Accepted — submission acknowledged; poll for completion.

data
CustomAgentVideoCreateResponse · object

202 response body for POST /v3/custom-agents/{agent_id}/videos.