Skip to content

About

Muapi HeyGen Avatar 6 API guide: Avatar 6 vs Avatar 6 Turbo, photo, reference-video and public-avatar modes at 1080p/2K, per-second pricing, and runnable curl, Python and JavaScript examples.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HeyGen Avatar 6 API

Create lip-synced talking-avatar videos with HeyGen Avatar 6 and the faster, lower-cost Avatar 6 Turbo through Muapi's asynchronous REST API, with copy-paste curl, Python, and JavaScript examples for photo, reference-video, and public-avatar modes at 1080p or 2K.

Muapi HeyGen Avatar 6 page · HeyGen Avatar 6 playground · AI avatar & lipsync API · API reference · Create an API key · muapi.ai

Related Projects

  • MuAPI — Unified API for image, video, and audio generation across hundreds of AI models.
  • AI-Avatar-Lipsync-API — Compare Muapi avatar and lipsync endpoints with runnable examples.
  • Text-to-Speech-API — Generate the narration audio an avatar video needs.
  • Open-Generative-AI — Open-source generative media studio built on Muapi.

What HeyGen Avatar 6 is

HeyGen Avatar 6 creates a lip-synced talking video at 1080p or 2K, driven by speech audio (2 to 60 seconds) or, for public avatars, by text. On Muapi it is two endpoints with identical inputs: heygen-avatar-6 and heygen-avatar-6-turbo, the faster, lower-cost tier. The output is one MP4 whose length follows the audio, and an optional prompt directs gestures, expression, and posture.

Input modes

The mode is chosen automatically from the fields you send. Use the inputs of one mode per request.

Mode Send Notes
Photo images_list (1 photo) + audio_url Animates the photo. Output keeps the photo's aspect ratio.
Reference video video_url + audio_url (+ optional 1 reference photo in images_list) Drives an animated or illustrated character from a video of at least 2 seconds, up to 50 MB.
Public avatar avatar + either audio_url or text Pick a HeyGen public avatar by name (for example Abigail Sofa Front). With text, choose a voice (default Warm Pro Narrator). Supports aspect_ratio.

HeyGen offers 1,248 public avatars and 102 voices; names are matched ignoring case and extra spaces and are validated when you submit, so an unknown name fails fast before any work starts. Audio must be 2 to 60 seconds and up to 15 MB.

Avatar 6 vs Avatar 6 Turbo

Avatar 6 Avatar 6 Turbo
Muapi endpoint heygen-avatar-6 heygen-avatar-6-turbo
Positioning Higher-quality tier Faster, lower-cost tier
Inputs and modes Photo, reference video, public avatar Same
Resolution 1080p, 2K 1080p, 2K
Price per second (1080p) $0.10 $0.05
Price per second (2K) $0.145 $0.087

Quality differences are not benchmarked here; run the same input through both in the playground.

Quick start

Muapi is asynchronous: submit a request, save the returned request_id, then poll the result endpoint.

export MUAPI_API_KEY="your-key"

curl -X POST https://api.muapi.ai/api/v1/heygen-avatar-6 \
  -H "x-api-key: $MUAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "images_list": ["https://example.com/portrait.png"],
    "audio_url": "https://example.com/speech.mp3",
    "resolution": "1080p",
    "prompt": "Speak warmly to the camera with subtle hand gestures"
  }'
# {"request_id":"REQUEST_ID","status":"processing"}

curl "https://api.muapi.ai/api/v1/predictions/REQUEST_ID/result" \
  -H "x-api-key: $MUAPI_API_KEY"

Poll until status is completed or failed. On completion the video URL is in outputs[0]. You can also pass ?webhook=https://your.app/hook on the submit call to be notified instead of polling.

Request fields

Field Mode Notes
images_list Photo, reference video Exactly 1 public image URL. Required in photo mode; optional reference photo in reference video mode.
video_url Reference video Animated or illustrated character video. Requires audio_url.
avatar Public avatar HeyGen public avatar name.
audio_url All Speech audio, 2-60 seconds, up to 15 MB. Required in photo and reference video modes; for a public avatar send audio_url or text.
text Public avatar Up to 1,000 characters, in place of audio_url.
voice Public avatar + text Voice name. Default Warm Pro Narrator.
prompt All Optional direction for gestures, expression, posture. Up to 1,200 characters.
aspect_ratio Public avatar 16:9 (default), 9:16, 1:1, 4:5, 5:4. Ignored in photo and reference video modes.
resolution All 1080p (default) or 2K.

Pricing

Billing is per second of output, which equals the audio length rounded up to the next second, between 2 and 60 seconds, with no subscription:

1080p 2K
Avatar 6 $0.10 / sec $0.145 / sec
Avatar 6 Turbo $0.05 / sec $0.087 / sec

For example, 30 seconds of audio at 1080p costs $3.00 on Avatar 6 and $1.50 on Turbo. When you send text instead of audio for a public avatar, Muapi estimates the length at about 12 characters per second (between 2 and 60 seconds) and bills that estimate. Failed tasks are refunded. These are Muapi's current prices; confirm on the model page.

Examples

Path What it does
examples/curl/avatar.sh Photo-mode request, poll, and print the video URL with curl and jq.
examples/python/heygen_avatar.py Minimal Python client (requests) for photo, reference video, and public avatar modes.
examples/python/talking_photo.py Animates a photo with an audio file and downloads the MP4.
examples/javascript/heygen_avatar.mjs Minimal Node 18+ client using fetch.
pip install -r requirements.txt
export MUAPI_API_KEY="your-key"
python examples/python/talking_photo.py https://example.com/portrait.png https://example.com/speech.mp3
node examples/javascript/heygen_avatar.mjs

These examples have not been run against a live HeyGen Avatar 6 call yet; try the endpoint in the playground first.

Errors and production notes

  • Keep the API key in an environment variable; never commit credentials.
  • Media URLs must be publicly reachable over HTTP(S) and directly downloadable. Audio length and avatar names are checked when you submit.
  • Handle non-success HTTP responses and failed task states. Failed tasks are refunded.
  • Do not resubmit after a timeout without checking the original request_id; duplicate submissions are billed.
  • Only animate photos and voices you have the right to use, and disclose AI-generated avatars where required.

License

MIT

About

Muapi HeyGen Avatar 6 API guide: Avatar 6 vs Avatar 6 Turbo, photo, reference-video and public-avatar modes at 1080p/2K, per-second pricing, and runnable curl, Python and JavaScript examples.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors