Heygen Video 1.0 Text To Video API Documentation
Playground
Try it on WaveSpeedAI!HeyGen Video 1.0 Text-to-Video generates short AI videos from text prompts with duration control, optional prompt enhancement, and seed settings for creative content, marketing videos, social media, and production workflows. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.
Features
HeyGen Video 1.0 Text-to-Video generates short videos directly from text prompts. Describe the subject, setting, action, camera movement, and visual direction, then choose the duration, resolution, and aspect ratio for the final clip.
It supports 480p and 768p output with durations from 5 to 15 seconds, making it suitable for social content, creative concepts, promotional clips, and visual storytelling.
Why Choose This?
-
Text-to-video generation
Create videos directly from natural-language scene descriptions. -
480p and 768p output
Choose the resolution that fits your quality and cost requirements. -
Multiple aspect ratios
Generate landscape, portrait, square, and ultrawide video layouts. -
Flexible duration
Generate clips from5to15seconds. -
Prompt enhancement
Choosedisabled,turbo, orqualitydepending on how much prompt expansion you want. -
Seed control
Use a fixed seed when comparing prompt or parameter changes.
Parameters
| Parameter | Required | Description |
|---|---|---|
| prompt | Yes | Text description of the scene, subject, action, camera movement, and visual direction. Supports up to 32000 characters. |
| duration | No | Video duration in whole seconds. Range: 5–15. Default: 5. |
| resolution | No | Output resolution: 480p or 768p. Default: 768p. |
| aspect_ratio | No | Output aspect ratio: 21:9, 16:9, 4:3, 1:1, 3:4, or 9:16. Default: 16:9. |
| prompt_enhancement | No | Prompt enhancement mode: disabled, turbo, or quality. Default: disabled. |
| seed | No | Optional integer seed. Omit for automatic selection. |
How to Use
- Write a prompt — Describe the subject, setting, action, camera movement, and visual style.
- Set duration — Choose a length from
5to15seconds. - Choose resolution — Select
480por768p. - Choose aspect ratio — Select the layout that fits your target content.
- Configure prompt enhancement optional — Use
turboorqualitywhen you want additional prompt expansion. - Set seed optional — Use a fixed seed when reproducibility is useful.
- Submit — Generate and retrieve the completed video.
Pricing
Pricing is based on the requested duration and selected resolution.
| Resolution | Price per Second |
|---|---|
| 480p | $0.020 |
| 768p | $0.036 |
Example Costs
| Duration | 480p | 768p |
|---|---|---|
| 5s | $0.10 | $0.18 |
| 10s | $0.20 | $0.36 |
| 15s | $0.30 | $0.54 |
aspect_ratio, prompt_enhancement, and seed do not add separate charges.
Best Use Cases
- Social media videos — Create short-form visual stories and promotional clips.
- Creative concepts — Explore scene ideas, visual styles, and camera directions.
- Advertising content — Generate short campaign and product-focused video concepts.
- Visual storytelling — Turn written scene descriptions into motion.
- Presentation content — Create short supporting visuals for pitches and presentations.
- Rapid video prototyping — Test different prompts, framing, and motion ideas quickly.
Pro Tips
- Keep the main subject and action clear.
- Describe camera movement explicitly when it matters.
- Include lighting, environment, mood, and visual style when they are important to the result.
- Use
480pfor lower-cost iteration before moving to768p. - Leave
prompt_enhancement=disabledwhen you want the model to follow your original wording more directly. - Use a fixed
seedwhen comparing prompt or setting changes.
Notes
promptis required.durationsupports whole-second values from5to15.durationdefaults to5.resolutiondefaults to768p.aspect_ratiodefaults to16:9.prompt_enhancementdefaults todisabled.
Related Models
- HeyGen Video 1.0 Text-to-Video — Generate videos directly from text prompts.
- HeyGen Video 1.0 Image-to-Video — Animate an input image with prompt-guided motion.
Authentication
For authentication details, please refer to the Authentication Guide.
API Endpoints
Submit Task & Query Result
set -euo pipefail
export WAVESPEED_API_KEY="your-api-key"
REQUEST_BODY=$(cat <<'JSON'
{
"prompt": "A cinematic ocean wave at sunrise, highly detailed",
"duration": 5,
"resolution": "768p",
"aspect_ratio": "16:9",
"prompt_enhancement": "disabled"
}
JSON
)
# 1. Submit the prediction.
SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
-X POST "https://api.wavespeed.ai/api/v3/heygen/video-1.0/text-to-video" \
-H "Authorization: Bearer ${WAVESPEED_API_KEY}" \
-H "Content-Type: application/json" \
-d "${REQUEST_BODY}")
TASK=$(printf '%s' "${SUBMIT_RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
PREDICTION_ID=$(printf '%s' "${TASK}" | jq -r '.id // empty')
if [ -z "${PREDICTION_ID}" ]; then
printf 'Submission response did not contain a prediction id
' >&2
exit 1
fi
RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/${PREDICTION_ID}/result"
# 2. Poll until the prediction finishes.
while true; do
RESPONSE=$(curl --silent --show-error --fail-with-body \
"${RESULT_URL}" \
-H "Authorization: Bearer ${WAVESPEED_API_KEY}")
RESULT=$(printf '%s' "${RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
STATUS=$(printf '%s' "${RESULT}" | jq -r '.status // empty')
case "${STATUS}" in
completed) printf '%s\n' "${RESULT}" | jq '.outputs'; break ;;
failed|cancelled|timeout|deleted) printf '%s\n' "${RESULT}" | jq . >&2; exit 1 ;;
*) sleep 2 ;;
esac
doneParameters
Task Submission Parameters
Request Parameters
| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
| prompt | string | Yes | 1 ~ 32000 characters | Describe the scene, action, and camera movement. | |
| duration | integer | No | 5 | 5 ~ 15 · step 1 | Requested video duration in seconds. |
| resolution | string | No | 768p | 480p, 768p | Output video resolution. |
| aspect_ratio | string | No | 16:9 | 21:9, 16:9, 4:3, 1:1, 3:4, 9:16 | Output video aspect ratio. |
| prompt_enhancement | string | No | disabled | disabled, turbo, quality | Optional prompt enhancement. Disabled by default. |
| seed | integer | No | - | 0 ~ 2147483647 | Random seed. Omit for a random result. |
Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data.id | string | Unique identifier for the prediction, Task Id |
| data.model | string | Model ID used for the prediction |
| data.outputs | array | Output values, usually URL strings; some models return text strings or structured result objects (empty when status is not completed) |
| data.urls | object | Object containing related API endpoints |
| data.status | string | Task status. completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses. |
| data.created_at | string | ISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”) |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |
Result Request Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| id | string | Yes | - | Task ID |
Result Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data | object | The prediction data object containing all details |
| data.id | string | Unique identifier for the prediction |
| data.model | string | Model ID used for the prediction |
| data.outputs | array<string | object> | Array of generated outputs (empty when status is not completed). Items are usually URL strings, but may be text strings or structured result objects, depending on the model. |
| data.urls | object | Object containing related API endpoints |
| data.status | string | Status: completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses |
| data.created_at | string | ISO timestamp of when the request was created |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |