Generate a video from text
kling_text_to_videoGenerate a video from a prompt (or custom multi-shot with shot_N_prompt / shot_N_duration on kling-v3-0 / kling-v4-0). Per model: kling-v4-0 3-30 s, std / pro, audio always on, multi-shot; kling-v4-0-flash 3-20 s, std (720p) only, audio always on, start image only, no custom shots; kling-v3-0 3-15 s, std / pro / 4k, audio on by default (enable_audio false is cheaper); kling-v3-0-turbo 3-15 s, std / pro; kling-v2-6 5 or 10 s, std / pro (native audio needs pro); older models 5 or 10 s. negative_prompt and cfg_scale only on older models. kling-v2-5 and kling-v2-1-master run in pro only. Uses Kling credits: kling-v2-6 std is the cheapest at 15 credits for 5 s; kling-v3-0 6-9 credits a second (12 at pro), kling-v4-0 10 a second (15 at pro / 1080p), kling-v4-0-flash 6 a second, 4k and Master models cost much more. A job: waits up to ~50 s, then returns task_id + email for kling_get_task. POST /videos/text2video.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | std (720p), pro (1080p) or 4k, as the model allows. | |
| No | The Kling account email. Optional: by default the account with the most free job slots; results name the account used. Pass it whenever an input belongs to one account (an uploaded file, a voice, an element, your own avatar or motion, a task_id). | ||
| prompt | No | What happens in the video. | |
| duration | No | Seconds; allowed values depend on the model (default 5). | |
| cfg_scale | No | Prompt adherence 0-1 (kling-v1-x only). | |
| model_name | No | Model (default kling-v1-6). | |
| multi_shot | No | Kling picks the shots (kling-v3-0; kling-v4-0 is always multi-shot). | |
| aspect_ratio | No | 16:9 (default), 9:16, 1:1, or 21:9 (kling-v4-0 only). | |
| enable_audio | No | Sound: kling-v3-0 on by default (false = cheaper); kling-v2-6 native audio needs mode pro; not accepted by kling-v4-0 / turbo (always on). | |
| shot_1_prompt | No | Custom multi-shot: shot 1's prompt (with shot_1_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| shot_2_prompt | No | Custom multi-shot: shot 2's prompt (with shot_2_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| shot_3_prompt | No | Custom multi-shot: shot 3's prompt (with shot_3_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| shot_4_prompt | No | Custom multi-shot: shot 4's prompt (with shot_4_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| shot_5_prompt | No | Custom multi-shot: shot 5's prompt (with shot_5_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| shot_6_prompt | No | Custom multi-shot: shot 6's prompt (with shot_6_duration; at least 2 shots, total 3-15 s; not with prompt / duration). | |
| negative_prompt | No | What to avoid (older models only). | |
| shot_1_duration | No | Custom multi-shot: shot 1's seconds, 1-15. | |
| shot_2_duration | No | Custom multi-shot: shot 2's seconds, 1-15. | |
| shot_3_duration | No | Custom multi-shot: shot 3's seconds, 1-15. | |
| shot_4_duration | No | Custom multi-shot: shot 4's seconds, 1-15. | |
| shot_5_duration | No | Custom multi-shot: shot 5's seconds, 1-15. | |
| shot_6_duration | No | Custom multi-shot: shot 6's seconds, 1-15. |