---
title: "Kling AI: Next-Gen AI Video & AI Image Generator"
source: "https://kling.ai/document-api/apiReference/model/videoModels"
author:
published:
created: 2026-04-24
description:
tags:
  - "clippings"
---
<table><colgroup><col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-video-o1</p></th><th><p>std（3s～10s）</p></th><th><p>pro（3s～10s）</p></th></tr><tr><td rowspan="3"><p>text to video</p></td><td><p>single-shot-video generation</p></td><td><p>✅（only 5s、10s）</p></td><td><p>✅（only 5s、10s）</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="6"><p>image to video</p></td><td><p>single-shot-video generation</p><p>（only start frame）</p></td><td><p>✅（only 5s、10s）</p></td><td><p>✅（only 5s、10s）</p></td></tr><tr><td><p>start & end frame</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>element control</p><p>（only multi-image elements）</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>cideo reference</p><p>(including multi-image elements)</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v3-omni</p></th><th><p>std（3s～15s）</p></th><th><p>pro（3s～15s）</p></th><th><p>4k（3s～15s）</p></th></tr><tr><td rowspan="4"><p>text to video</p></td><td><p>single-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>multi-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="7"><p>image to video</p></td><td><p>single-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>multi-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start & end frame</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>element control</p><p>（video character elements & multi-image elements）</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>reference video</p></td><td><p>✅（only 3s～10s）</p></td><td><p>✅（only 3s～10s）</p></td><td><p>❌</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v1</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>camera control</p></td><td><p>✅</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="4"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start/end frame</p></td><td><p>✅</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>motion brush</p></td><td><p>✅</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>video extension</p><p>（Not supported negative_prompt and cfg_scale)</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>video effects</p><p>Dual-character: Hug, Kiss, heart_gesture</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v1-5</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="6"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start/end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>motion brush</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>camera control</p><p>（simple only）</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>video extension</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>video effects</p><p>Dual-character: Hug, Kiss, heart_gesture</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v1-6</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="4"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start/end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>multi-image2video</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>multi-elements</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>video extension</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td colspan="2"><p>video effects</p><p>Dual-character: Hug, Kiss, heart_gesture</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v2-master</p></th><th><p>5s</p></th><th><p>10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="2"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v2-1</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th></tr><tr><td><p>text</p><p>to video</p></td><td><p>all</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="3"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start/end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v2-1-master</p></th><th><p>5s</p></th><th><p>10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="2"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v2-5-turbo</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th></tr><tr><td rowspan="2"><p>text</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="3"><p>image</p><p>to video</p></td><td><p>video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start/end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td colspan="2"><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v2-6</p></th><th><p>std 5s</p></th><th><p>std 10s</p></th><th><p>std x other duration</p></th><th><p>pro 5s</p></th><th><p>pro10s</p></th><th><p>pro x other duration</p></th></tr><tr><td rowspan="2"><p>text to video</p></td><td><p>video generation</p></td><td><p>✅ (only no audio)</p></td><td><p>✅ (only no audio)</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="5"><p>image to video</p></td><td><p>video generation</p></td><td><p>✅ (only no audio)</p></td><td><p>✅ (only no audio)</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>start/end frame</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅ (only no audio)</p></td><td><p>✅ (only no audio)</p></td><td><p>-</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>-</p></td></tr><tr><td><p>motion control</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td><td><p>-</p></td><td><p>-</p></td><td><p>✅</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col></colgroup><tbody><tr><th colspan="2"><p>kling-v3</p></th><th><p>std（3～15s）</p></th><th><p>pro（3～15s）</p></th><th><p>4k（3～15s）</p></th></tr><tr><td rowspan="4"><p>text to video</p></td><td><p>single-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>multi-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr><tr><td rowspan="7"><p>image to video</p></td><td><p>single-shot-video generation （only start frame）</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>multi-shot-video generation</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>start & end frame</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>element control</p><p>（video character elements & multi-image elements）</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>✅</p></td></tr><tr><td><p>motion control</p></td><td><p>✅</p></td><td><p>✅</p></td><td><p>❌</p></td></tr><tr><td><p>voice control (human voice)</p></td><td><p>❌</p></td><td><p>❌</p></td><td><p>❌</p></td></tr><tr><td><p>others</p></td><td><p>-</p></td><td><p>-</p></td><td><p>-</p></td></tr></tbody></table>

| no related of model | support or not | description |
| --- | --- | --- |
| avatar | ✅ | Generate digital human broadcast-style videos with just one photo |
| lip sync | ✅ | Can be combined with text or audio to drive the mouth shape of characters in the video |
| video to audio | ✅ | Supports adding audio to all videos generated by Kling models and user-uploaded videos |
| text to audio | \- | Supports generating audio by text prompts |
| others | \- | \- |

<table><colgroup><col> <col> <col> <col> <col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th><p>Model</p></th><th colspan="2"><p>kling-v1</p></th><th colspan="2"><p>kling-v1-5</p></th><th colspan="2"><p>kling-v1-6</p><p>Image to Video</p></th><th colspan="2"><p>kling-v1-6</p><p>Text to Video</p></th><th><p>kling-v2 Master</p></th></tr><tr><td><p>Mode</p></td><td><p>STD</p></td><td><p>PRO</p></td><td><p>STD</p></td><td><p>PRO</p></td><td><p>STD</p></td><td><p>PRO</p></td><td><p>STD</p></td><td><p>PRO</p></td><td><p>-</p></td></tr><tr><td><p>Resolution</p></td><td><p>720p</p></td><td><p>720p</p></td><td><p>720p</p></td><td><p>1080p</p></td><td><p>720p</p></td><td><p>1080p</p></td><td><p>720p</p></td><td><p>1080p</p></td><td><p>720p</p></td></tr><tr><td><p>Frame Rate</p></td><td><p>30fps</p></td><td><p>30fps</p></td><td><p>30fps</p></td><td><p>30fps</p></td><td><p>30fps</p></td><td><p>30fps</p></td><td><p>24fps</p></td><td><p>24fps</p></td><td><p>24fps</p></td></tr></tbody></table>

<table><colgroup><col> <col> <col> <col> <col> <col></colgroup><tbody><tr><th><p>Model</p></th><th colspan="2"><p>kling-v2-1</p><p>Image to Video</p></th><th><p>kling-v2-1 Master</p></th><th><p>kling-v2-5</p><p>Image to Video</p></th><th><p>kling-v2-5</p><p>Text to Video</p></th></tr><tr><td><p>Mode</p></td><td><p>STD</p></td><td><p>PRO</p></td><td><p>-</p></td><td><p>PRO</p></td><td><p>PRO</p></td></tr><tr><td><p>Resolution</p></td><td><p>720p</p></td><td><p>1080p</p></td><td><p>1080p</p></td><td><p>1080p</p></td><td><p>1080p</p></td></tr><tr><td><p>Frame Rate</p></td><td><p>24fps</p></td><td><p>24fps</p></td><td><p>24fps</p></td><td><p>24fps</p></td><td><p>24fps</p></td></tr></tbody></table>
source: "https://kling.ai/document-api/apiReference/model/lipSync"
## Identify Face
POST `/v1/videos/identify-face`
```bash
curl --request POST \
  --url https://api-singapore.klingai.com/v1/videos/identify-face \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
    "video_url": "https://p1-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/kling20260206mp4.mp4",
    "video_id": ""
  }'
```
200
```json
{
  "code": 0, // Error codes; Specific definitions can be found in "Error Code"
  "message": "string", // Error information
  "request_id": "string", // Request ID, generated by the system, used to track requests and troubleshoot problems
  "data": {
    "session_id": "id", // Session ID
    "final_unit_deduction": "string", // The deduction units of task
    "face_data": [ //Face data list
      {
        "face_id": "string", // Face ID
        "face_image": "url", // Face image URL
        "start_time": 0, // Face appearance start time, unit: ms
        "end_time": 5200 //Face appearance end time, unit: ms
      }
    ]
  }
}
```
Identify faces in the video for lip-sync processing.
### Request Header
Data Exchange Format
AuthorizationstringRequired
Authentication information, refer to API authentication
### Request Body
video\_idstringOptional
The ID of the video generated by Kling AI
- Used to specify the video and determine whether it can be used for lip-sync services.
- This parameter and 'video\_url' are mutually exclusive—only one can be filled, and neither can be left empty.
- Only supports videos generated within the last 30 days with a duration of no more than 60 seconds.
video\_urlstringOptional
The URL of the video
- Used to specify the video and determine whether it can be used for lip-sync services.
- This parameter and 'video\_id' are mutually exclusive—only one can be filled, and neither can be left empty.
- Supported video formats:.mp4/.mov, file size ≤100MB, duration 2s–60s, resolution 720p or 1080p, with both width and height between 512px–2160px. If validation fails, an error code will be returned.
- The system checks video content—if issues are detected, an error code will be returned.
## Create Task
POST `/v1/videos/advanced-lip-sync`
```bash
curl --request POST \
  --url https://api-singapore.klingai.com/v1/videos/advanced-lip-sync \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
    "session_id": "850508686686064678",
    "face_choose": [
      {
        "face_id": "0",
        "sound_file": "https://p1-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/go-to-world.mp3",
        "sound_insert_time": 1000,
        "sound_start_time": 0,
        "sound_end_time": 3000,
        "sound_volume": 2,
        "original_audio_volume": 2
      }
    ],
    "external_task_id": "",
    "callback_url": ""
  }'
```
200
```json
{
  "code": 0, // Error codes; Specific definitions can be found in "Error Code"
  "message": "string", // Error information
  "request_id": "string", // Request ID, generated by the system, used to track requests and troubleshoot problems
  "data": {
    "task_id": "string", // Task ID, generated by the system
    "task_info": { //Task creation parameters
      "external_task_id": "string" //User-defined task ID
    },
    "task_status": "string", // Task status, Enum values: submitted, processing, succeed, failed
    "created_at": 1722769557708, // Task creation time, Unix timestamp, unit: ms
    "updated_at": 1722769557708 //Task update time, Unix timestamp, unit: ms
  }
}
```
### Request Header
Data Exchange Format
AuthorizationstringRequired
Authentication information, refer to API authentication
### Request Body
session\_idstringRequired
Session ID generated during the identify face API. It remains unchanged during the selection/editing process.
face\_choosearrayRequired
Specified Face for Lip-Sync
- Includes Face ID, lip movement reference data, etc.
- Currently only supports one person lip-sync.
▾Hide child attributes
face\_idstringRequired
Face ID
- Returned by the facial recognition interface.
audio\_idstringOptional
Sound ID Generated via TTS API
- Only supports audio generated within the last 30 days with a duration of no less than 2 seconds and no more than 60 seconds.
- Either audio\_id or sound\_file must be provided (mutually exclusive; cannot be empty or both populated).
sound\_filestringOptional
Sound File
- Supports Base64-encoded audio or accessible audio URL.
- Accepted formats:.mp3/.wav/.m4a/.aac (max 5MB). Format mismatches or oversized files will return error codes.
- Only supports audio with a duration of no less than 2 seconds and no more than 60 seconds.
- Either audio\_id or sound\_file must be provided (mutually exclusive; cannot be empty or both populated).
- The system will verify the audio content and return error codes if there are any problems.
sound\_start\_timelongRequired
Time point to start cropping sound
- Based on the original sound start time, the start time is 0'0", units: ms
- The sound before the starting point will be cropped, and the cropped sound must not be shorter than 2 seconds.
sound\_end\_timelongRequired
Time point to stop cropping sound
- Based on the original sound start time, the start time is 0'0", units: ms
- The sound after the end point will be cropped, and the cropped sound must not be shorter than 2 seconds.
- The end point time shouldn't be later than the total duration of the original sound.
sound\_insert\_timelongRequired
The time for inserting cropped sound
- Based on the original video start time, the start time is 0'0", units: ms
- The time range for inserting sound should overlap with the face's lip-sync time interval for at least 2 seconds.
- The start time for inserting sound must not be earlier than the start time of the video, and the end time for inserting sound must not be later than the end time of the video.
Volume Controls (higher values = louder)
- Value range: \[0, 2\]
Original video volume (higher values = louder)
- Value range: \[0, 2\]
- No effect if source video is silent.
watermark\_infoobjectOptional
Whether to generate watermarked results simultaneously
- Defined by the enabled parameter, format:
```json
"watermark_info": { "enabled": boolean }
```
- true: generate watermarked result, false: do not generate
- Custom watermarks are not currently supported
external\_task\_idstringOptional
Custom Task ID
- User-defined task ID. It will not override the system-generated task ID, but supports querying tasks by this ID.
- Please note that uniqueness must be ensured for each user.
callback\_urlstringOptional
The callback notification address for the result of this task. If configured, the server will actively notify when the task status changes.
- For specific message schema, see [Callback Protocol](https://kling.ai/document-api/apiReference/callbackProtocol)
## Query Task (Single)
GET `/v1/videos/advanced-lip-sync/{id}`
```bash
curl --request GET \
  --url https://api-singapore.klingai.com/v1/videos/advanced-lip-sync/{task_id} \
  --header 'Authorization: Bearer <token>'
```
200
```json
{
  "code": 0, // Error codes; Specific definitions can be found in "Error Code"
  "message": "string", // Error information
  "request_id": "string", // Request ID, generated by the system, used to track requests and troubleshoot problems
  "data": {
    "task_id": "string", // Task ID, generated by the system
    "task_status": "string", // Task status, Enum values: submitted, processing, succeed, failed
    "task_status_msg": "string", // Task status message, displaying the failure reason when the task fails (such as triggering the content risk control of the platform, etc.)
    "task_info": { //Task creation parameters
      "parent_video": { //Original video information
        "id": "string", // Original video ID
        "url": "string", // Original video URL
        "duration": "string" //Original video duration, unit: s
      }
    },
    "task_result": { //Task result
      "videos": [ //Generated video list
        {
          "id": "string", // Generated video ID; globally unique
          "url": "string", // URL for generating videos (Please note that for security purposes, generated images/videos will be deleted after 30 days. Please save them promptly.)
          "watermark_url": "string", // Watermarked video download URL, anti-hotlinking format
          "duration": "string" //Total video duration, unit: s
        }
      ]
    },
    "watermark_info": {
      "enabled": boolean //Whether watermark is enabled
    },
    "final_unit_deduction": "string", // The deduction units of task
    "created_at": 1722769557708, // Task creation time, Unix timestamp, unit: ms
    "updated_at": 1722769557708 //Task update time, Unix timestamp, unit: ms
  }
}
```
### Request Header
Data Exchange Format
AuthorizationstringRequired
Authentication information, refer to API authentication
### Path Parameters
task\_idstringOptional
Task ID for Video Generation - Lip-Sync. Fill the value directly in the request path.
## Query Task (List)
GET `/v1/videos/advanced-lip-sync`
```bash
curl --request GET \
  --url 'https://api-singapore.klingai.com/v1/videos/advanced-lip-sync?pageNum=1&pageSize=30' \
  --header 'Authorization: Bearer <token>'
```
200
```json
{
  "code": 0, // Error codes; Specific definitions can be found in "Error Code"
  "message": "string", // Error information
  "request_id": "string", // Request ID, generated by the system, used to track requests and troubleshoot problems
  "data": [
    {
      "task_id": "string", // Task ID, generated by the system
      "task_status": "string", // Task status, Enum values: submitted, processing, succeed, failed
      "task_status_msg": "string", // Task status message, displaying the failure reason when the task fails (such as triggering the content risk control of the platform, etc.)
      "task_info": { //Task creation parameters
        "parent_video": { //Original video information
          "id": "string", // Original video ID
          "url": "string", // Original video URL
          "duration": "string" //Original video duration, unit: s
        }
      },
      "task_result": { //Task result
        "videos": [ //Generated video list
          {
            "id": "string", // Generated video ID; globally unique
            "url": "string", // URL for generating videos (Please note that for security purposes, generated images/videos will be deleted after 30 days. Please save them promptly.)
            "watermark_url": "string", // Watermarked video download URL, anti-hotlinking format
            "duration": "string" //Total video duration, unit: s
          }
        ]
      },
      "watermark_info": {
        "enabled": boolean //Whether watermark is enabled
      },
      "final_unit_deduction": "string", // The deduction units of task
      "created_at": 1722769557708, // Task creation time, Unix timestamp, unit: ms
      "updated_at": 1722769557708 //Task update time, Unix timestamp, unit: ms
    }
  ]
}
```
### Request Header
Data Exchange Format
AuthorizationstringRequired
Authentication information, refer to API authentication
### Query Parameters
Page number
- Value range: \[1, 1000\]
Number of items per page
- Value range: \[1, 500\]

source: "https://kling.ai/document-api/apiReference/model/multiImageToVideo"
POST `/v1/videos/multi-image2video`
  --url https://api-singapore.klingai.com/v1/videos/multi-image2video \
    "model_name": "kling-v1-6",
    "image_list": [
      { "image": "https://p1-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/dog.png" },
      { "image": "https://p1-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/dog_cloth.png" }
    "prompt": "A white Bichon Frise wearing a red Northeast-style floral cotton jacket, licking its paw",
    "negative_prompt": "",
    "mode": "pro",
    "duration": "5",
    "aspect_ratio": "16:9",
    "callback_url": "",
    "external_task_id": ""
  "code": 0, // Error code; Specific definitions can be found in "Error Code"
  "message": "string", // Error message
Generate video from multiple reference images (elements).
Model Name
Enum values：kling-v1-6
image\_listarrayRequired
Reference Image List
- Support up to 4 images, load with key:value format as follows:
"image_list":[
  { "image":"image_url" },
  { "image":"image_url" },
  { "image":"image_url" },
  { "image":"image_url" }
]
- Please directly upload the image with selected subject since there is no cropping logic on the API side
- Supports image input as either Base64-encoded string or URL (ensure the URL is publicly accessible)
- Important: When using Base64, do NOT add any prefix like `data:image/png;base64,`. Submit only the raw Base64 string.
- Correct Base64 format:
iVBORw0KGgoAAAANSUhEUgAAAAUA...
- Incorrect Base64 format (with data: prefix):
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUA...
- Supported image formats:.jpg /.jpeg /.png
- Image file size must not exceed 10MB. Image dimensions must be at least 300px. Aspect ratio must be between 1:2.5 and 2.5:1
imagestringRequired
Image URL or Base64 string
promptstringRequired
Positive text prompt
- Cannot exceed 2500 characters
negative\_promptstringOptional
Negative text prompt
- Cannot exceed 2500 characters
Video generation mode
Enum values：stdpro
- std: Standard Mode, which is cost-effective
- pro: Professional Mode, generates higher quality video output
Different model versions and video modes have different support ranges. For details, see [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels)
Video Length, unit: s (seconds)
Enum values：510
The aspect ratio of the generated video frame (width:height)
Enum values：16:99:161:1
The callback notification address for the result of this task. If configured, the server will actively notify when the task status changes
- The specific message schema of the notification can be found in [Callback Protocol](https://kling.ai/document-api/apiReference/callbackProtocol)
Customized Task ID
- User-defined task ID. It will not override the system-generated task ID, but supports querying tasks by this ID
- Please note that it must be unique for each user
GET `/v1/videos/multi-image2video/{id}`
  --url https://api-singapore.klingai.com/v1/videos/multi-image2video/{task_id} \
  "code": 0, // Error code; Specific definitions can be found in "Error Code"
  "message": "string", // Error message
    "task_status_msg": "string", // Task status message, displays failure reason when task fails (such as content moderation triggers)
    "task_result": {
      "videos": [
          "duration": "string" //Total video duration, unit: s (seconds)
      "enabled": boolean
    "final_unit_deduction": "string", // Final unit deduction for the task
Task ID for Multi-Image to Video
- Request path parameter, fill the value directly in the request path
- You can choose to query by external\_task\_id or task\_id
Customized Task ID for Multi-Image to Video
- Request path parameter, fill the value directly in the request path
- The external\_task\_id filled in when creating the task. You can choose to query by external\_task\_id or task\_id
GET `/v1/videos/multi-image2video`
  --url 'https://api-singapore.klingai.com/v1/videos/multi-image2video?pageNum=1&pageSize=30' \
  "code": 0, // Error code; Specific definitions can be found in "Error Code"
  "message": "string", // Error message
      "task_status_msg": "string", // Task status message, displays failure reason when task fails (such as content moderation triggers)
        "external_task_id": "string" //User-defined task ID
      "task_result": {
        "videos": [
            "duration": "string" //Total video duration, unit: s (seconds)
        "enabled": boolean
      "final_unit_deduction": "string", // Final unit deduction for the task

source: "https://kling.ai/document-api/apiReference/model/imageToVideo"
POST `/v1/videos/image2video`
curl --location --request POST 'https://api-singapore.klingai.com/v1/videos/image2video' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "model_name": "kling-v2-6",
    "image": "https://p2-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/multi-2.png",
    "image_tail": "https://p2-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/multi-1.png",
    "prompt": "Camera zooms out, the girl smiles",
    "sound": "off",
}'
  "request_id": "string", // Request ID, generated by the system
    "task_info": { // Task creation parameters
      "external_task_id": "string" // Customer-defined task ID
    "created_at": 1722769557708, // Task creation time, Unix timestamp, unit ms
    "updated_at": 1722769557708 // Task update time, Unix timestamp, unit ms
💡
Please note that in order to maintain naming consistency, the original model field has been changed to model\_name. Please use this field to specify the model version in the future.  
We maintain backward compatibility. If you continue using the original model field, it will not affect API calls and will be equivalent to the default behavior when model\_name is empty (i.e., calling the V1 model).
Enum values：kling-v1kling-v1-5kling-v1-6kling-v2-masterkling-v2-1kling-v2-1-masterkling-v2-5-turbokling-v2-6kling-v3
imagestringOptional
Reference Image
- Supports image Base64 encoding or image URL (ensure accessibility)
- Supported image formats: `.jpg / .jpeg / .png`
- File size: ≤10MB, dimensions: min 300px, aspect ratio: 1:2.5 ~ 2.5:1
- At least one of `image` or `image_tail` must be provided; both cannot be empty
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
image\_tailstringOptional
Reference Image - End frame control
- Supports image Base64 encoding or image URL (ensure accessibility)
- Supported image formats: `.jpg / .jpeg / .png`
- File size: ≤10MB, dimensions: min 300px
- At least one of `image` or `image_tail` must be provided; both cannot be empty
- `image_tail`, `dynamic_masks/static_mask`, and `camera_control` are mutually exclusive - only one can be used at a time
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
Whether to generate multi-shot video
When true: the prompt parameter is invalid, and the first/end frame generation is not supported.
When false: the shot\_type and multi\_prompt parameters are invalid
shot\_typestringOptional
Storyboard method
Enum values：customizeintelligence
When multi\_shot is true, this parameter is required
promptstringOptional
💡
The Omni model can achieve various capabilities through Prompt with elements, images, videos, and other content:
- Specify elements/images/videos using <<<>>> format, e.g.: <<<element\_1>>>, <<<image\_1>>>, <<<video\_1>>>
- For detailed capabilities, see: [KLING Omni Model User Guide](https://kling.ai/quickstart/klingai-video-o1-user-guide), [Kling VIDEO 3.0 Omni Model User Guide](https://kling.ai/quickstart/klingai-video-3-omni-model-user-guide)
- When multi\_shot is false or shot\_type is intelligence, this parameter must not be empty.
- Use `<<<voice_1>>>` to specify voice, with the sequence matching the voice\_list parameter order
- A video generation task can reference up to 2 voices; when specifying a voice, the sound parameter must be "on"
- The simpler the syntax structure, the better. Example: `The man<<<voice_1>>> said: "Hello"`
- When voice\_list is not empty and prompt references voice ID, the task will be billed as "with specified voice"
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
multi\_promptarrayOptional
Information about each storyboard, such as prompts and duration
Define the shot sequence number, corresponding prompt word, and duration through the index, prompt, and duration parameters, where:
- Supports up to 6 storyboards, with a minimum of 1 storyboard.
- The maximum length of the prompt for each storyboard 512 characters.
- The duration of each storyboard should not exceed the total duration, but should not be less than 1.
- The sum of the durations of all storyboards equals the total duration of the current task.
Load with key:value format as follows:
"multi_prompt":[
{"index":int,"prompt":"string","duration":"5"},
{"index":int,"prompt":"string","duration":"5"}
When multi\_shot is true and shot\_type is customize, this parameter is required.
element\_listarrayOptional
Reference Element List, based on element ID from element library
- Supports up to 3 reference elements
The elements are categorized into video customization element (named as Video Character Elements) and image customization elements (named as Multi-Image Elements), each with distinct scopes of application. Please exercise caution in distinguishing between them. See [Kling Element Library User Guide](https://kling.ai/quickstart/klingai-element-library-3-user-guide).
- Load with key:value format as follows:
"element_list":[
  { "element_id": long },
  { "element_id": long }
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
element\_idlongRequired
Element ID from element library
voice\_listarrayOptional
List of voices referenced when generating videos
- A video generation task can reference up to 2 voices
- When voice\_list is not empty and prompt references voice ID, the task will be billed as "with specified voice"
- voice\_id is returned through the voice customization API, or use system preset voices. See [Custom Voices API](https://kling.ai/document-api/apiReference/model/customVoices); NOT the voice\_id of Lip-Sync API
- element\_list and voice\_list are mutually exclusive and cannot coexist
Example:
"voice_list":[
  {"voice_id":"voice_id_1"},
  {"voice_id":"voice_id_2"}
The support range for different model versions and video modes varies. For details, see [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels)
Whether to generate sound when generating video
Enum values：onoff
The support range for different model versions and video modes varies. For details, see [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels)
Flexibility in video generation; higher value means lower model flexibility and stronger relevance to user prompt
- Value range: \[0, 1\]
kling-v2.x models do not support this parameter
Enum values：stdpro4k
- `std`: Standard Mode, basic mode, cost-effective. The output video resolution is 720P.
- `pro`: Professional Mode, generates videos use longer duration but higher quality video output. The output video resolution is 1080P.
- `4k`: 4K Mode, generates videos use longer duration but higher quality video output. The output video resolution is 4K.
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
static\_maskstringOptional
Static brush mask area (mask image created by user using motion brush)
The "Motion Brush" feature includes Dynamic Brush (dynamic\_masks) and Static Brush (static\_mask)
- Supports image Base64 encoding or image URL (same format requirements as image field)
- Supported image formats: `.jpg / .jpeg / .png`
- Aspect ratio must match the input image (image field), otherwise task will fail
- Resolution of static\_mask and dynamic\_masks.mask must be identical, otherwise task will fail
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
dynamic\_masksarrayOptional
Dynamic brush configuration list
- Can configure multiple groups (up to 6), each containing "mask area" and "motion trajectory" sequence
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
maskstringRequired
Dynamic brush mask area (mask image created by user using motion brush)
- Supports image Base64 encoding or image URL (same format requirements as image field)
- Aspect ratio must match the input image (image field), otherwise task will fail
- Resolution of static\_mask and dynamic\_masks.mask must be identical, otherwise task will fail
trajectoriesarrayRequired
Motion trajectory coordinate sequence
- For 5s video, trajectory length ≤77, coordinate count range: \[2, 77\]
- Coordinate system uses bottom-left corner of image as origin
Note 1: More coordinate points = more accurate trajectory. 2 points = straight line between them
Note 2: Trajectory direction follows input order. First coordinate is start point, subsequent coordinates are connected sequentially
xintRequired
X coordinate of trajectory point (pixel coordinate with image bottom-left as origin)
yintRequired
Y coordinate of trajectory point (pixel coordinate with image bottom-left as origin)
camera\_controlobjectOptional
Camera movement control protocol (if not specified, model will intelligently match based on input text/images)
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
typestringRequired
Predefined camera movement type
Enum values：simpledown\_backforward\_upright\_turn\_forwardleft\_turn\_forward
- simple: Simple camera movement, can choose one of six options in "config"
- down\_back: Camera descends and moves backward ➡️ Pan down and zoom out. config parameter not required
- forward\_up: Camera moves forward and tilts up ➡️ Zoom in and pan up. config parameter not required
- right\_turn\_forward: Rotate right then move forward ➡️ Right rotation advance. config parameter not required
- left\_turn\_forward: Rotate left then move forward ➡️ Left rotation advance. config parameter not required
configobjectOptional
Contains 6 fields to specify camera movement in different directions
- Required when type is "simple"; leave empty for other types
- Choose only one parameter to be non-zero; rest must be 0
horizontalfloatOptional
Horizontal movement - camera translation along x-axis
- Value range: \[-10, 10\]. Negative = left, Positive = right
verticalfloatOptional
Vertical movement - camera translation along y-axis
- Value range: \[-10, 10\]. Negative = down, Positive = up
panfloatOptional
Horizontal pan - camera rotation around y-axis
- Value range: \[-10, 10\]. Negative = rotate left, Positive = rotate right
tiltfloatOptional
Vertical tilt - camera rotation around x-axis
- Value range: \[-10, 10\]. Negative = tilt down, Positive = tilt up
rollfloatOptional
Roll - camera rotation around z-axis
- Value range: \[-10, 10\]. Negative = counterclockwise, Positive = clockwise
zoomfloatOptional
Zoom - controls camera focal length change, affects field of view
- Value range: \[-10, 10\]. Negative = longer focal length (narrower FOV), Positive = shorter focal length (wider FOV)
Video duration in seconds
Enum values：3456789101112131415
Support varies by model version and video mode. See [Capability Map](https://kling.ai/document-api/apiReference/model/videoModels) for details.
Callback notification URL for task result. If configured, server will notify when task status changes.
- Will not overwrite system-generated task ID, but supports querying task by this ID
- Must be unique within a single user account
## Scenario invocation examples
### Image to video with multi-shot
curl --location 'https://xxx/v1/videos/image2video' \
--header 'Authorization: Bearer xxx' \
--header 'Content-Type: application/json' \
--data '{
    "model_name": "kling-v3",
    "image": "xxx",
    "prompt": "",
    "multi_shot": "true",
    "shot_type": "customize",
    "multi_prompt": [
            "index": 1,
            "prompt": "Two friends talking under a streetlight at night.  Warm glow, casual poses, no dialogue.",
            "duration": "2"
        },
            "index": 2,
            "prompt": "A runner sprinting through a forest, leaves flying.  Low-angle shot, focus on movement.",
            "duration": "3"
        },
            "index": 3,
            "prompt": "A woman hugging a cat, smiling.  Soft sunlight, cozy home setting, emphasize warmth.",
            "duration": "3"
        },
            "index": 4,
            "prompt": "A door creaking open, shadowy hallway.  Dark tones, minimal details, eerie mood.",
            "duration": "3"
        },
            "index": 5,
            "prompt": "A man slipping on a banana peel, shocked expression.  Exaggerated pose, bright colors.",
            "duration": "3"
        },
            "index": 6,
            "prompt": "A sunset over mountains, small figure walking away.  Wide angle, peaceful atmosphere.",
            "duration": "1"
    "duration": "15",
    "sound": "on",
}'
### Image to video with element
curl --location 'https://api-singapore.klingai.com/v1/images/generations' \
--header 'Authorization: Bearer xxx' \
--header 'Content-Type: application/json' \
--data '{
    "model_name": "kling-v3",
    "prompt": "Merge all the characters from the images into the <<<object_2>>> diagram",
    "element_list": [
            "element_id": "160"
        },
            "element_id": "161"
        },
            "element_id": "159"
    "image": "xxx",
    "resolution": "2k",
    "n": "9",
    "aspect_ratio": "3:2",
}'
curl --location 'https://xxx/v1/videos/text2video' \
--header 'Authorization: Bearer xxx' \
--header 'Content-Type: application/json' \
--data '{
    "model_name": "kling-v3",
    "prompt": "",
    "multi_prompt": [
            "index": 1,
            "prompt": "Two friends talking under a streetlight at night.  Warm glow, casual poses, no dialogue.",
            "duration": "2"
        },
            "index": 2,
            "prompt": "A runner sprinting through a forest, leaves flying.  Low-angle shot, focus on movement.",
            "duration": "3"
        },
            "index": 3,
            "prompt": "A woman hugging a cat, smiling.  Soft sunlight, cozy home setting, emphasize warmth.",
            "duration": "3"
        },
            "index": 4,
            "prompt": "A door creaking open, shadowy hallway.  Dark tones, minimal details, eerie mood.",
            "duration": "3"
        },
            "index": 5,
            "prompt": "A man slipping on a banana peel, shocked expression.  Exaggerated pose, bright colors.",
            "duration": "3"
        },
            "index": 6,
            "prompt": "A sunset over mountains, small figure walking away.  Wide angle, peaceful atmosphere.",
            "duration": "1"
    "multi_shot": true,
    "shot_type": "customize",
    "duration": "15",
    "sound": "on",
    "aspect_ratio": "9:16",
}'
### Generate video with voice control
curl --location 'https://api-singapore.klingai.com/v1/videos/image2video/' \
--header 'Authorization: Bearer {Replace your token}' \
--header 'Content-Type: application/json; charset=utf-8' \
--data '{
    "model_name": "kling-v2-6",
    "image": "Replace the URL of image",
    "prompt": "<<<voice_1>>>Ask the people in the picture to say the following words, '\''Welcome everyone'\''",    //If a specific dialogue needs to be enclosed in quotation marks
    "voice_list": [
            "voice_id": "Replace the ID of voice"
    "sound": "on",
}'
GET `/v1/videos/image2video/{id}`
  --url https://api-singapore.klingai.com/v1/videos/image2video/{task_id} \
  "request_id": "string", // Request ID, generated by the system, is used to track requests and troubleshoot problems
    "task_status_msg": "string", // Task status information, displaying the failure reason when the task fails (such as triggering the content risk control of the platform, etc.)
          "url": "string", // URL for generating videos (To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
          "watermark_url": "string", // Watermarked video download URL, anti-leech format
          "duration": "string" // Total video duration, unit: s
    "task_info": { // Task creation parameters
      "external_task_id": "string" // Customer-defined task ID
    "updated_at": 1722769557708 // Task update time, Unix timestamp, unit: ms
Task ID for image to video
- Request path parameter, fill value directly in request path
- Choose one between task\_id and external\_task\_id for querying
Customized Task ID for image to video
- The external\_task\_id provided when creating the task
- Choose one between task\_id and external\_task\_id for querying
GET `/v1/videos/image2video`
  --url 'https://api-singapore.klingai.com/v1/videos/image2video?pageNum=1&pageSize=30' \
  "code": 0, // Error codes; Specific definitions can be found in Error codes
  "request_id": "string", // Request ID, generated by the system, to track requests and troubleshoot problems
      "task_status_msg": "string", // Task status information, displaying the failure reason when the task fails (such as triggering the content risk control of the platform, etc.)
      "task_info": { // Task creation parameters
        "external_task_id": "string" // Customer-defined task ID
            "url": "string", // URL for generating videos (To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
            "watermark_url": "string", // Watermarked video download URL, anti-leech format
            "duration": "string" // Total video duration, unit: s (seconds)
      "updated_at": 1722769557708 // Task update time, Unix timestamp, unit: ms
Data volume per page

source: "https://kling.ai/document-api/apiReference/model/videoExtension"
POST `/v1/videos/video-extend`
  --url https://api-singapore.klingai.com/v1/videos/video-extend \
    "prompt": "A puppy appears",
    "video_id": "743211632612511839",
    "task_info":{ // Task creation parameters
- Note 1: Video extension refers to extending the duration of text-to-video/image-to-video results. Each extension can add 4 to 5 seconds, and the model and mode used cannot be selected; they must be the same as the source video.
- Note 2: Videos that have been extended can be extended again, but the total video duration cannot exceed 3 minutes.
video\_idstringRequired
Video ID
- Supports video IDs generated by the text-to-video, the image-to-video and the video extension interface (it cannot exceed 3 minutes).
- Only videos generated by V1.0, V1.5, and V1.6 models are supported.
> Please note that based on the current cleanup policy, videos will be cleared 30 days after generation, and extension will not be possible.
Text Prompt
Cannot exceed 2500 characters
Cannot exceed 2500 characters
Prompt reference strength. The higher the value, the stronger the reference to the prompt.
Value range: \[0, 1\]
The callback notification address for the task results. If configured, the server will actively notify when the task status changes.
GET `/v1/videos/video-extend/{id}`
  --url https://api-singapore.klingai.com/v1/videos/video-extend/{task_id} \
    "task_info": {
      "parent_video": { //Parameters information when the task is created
        "id": "string", //Video ID before the extension；globally unique
        "url": "string", //URL for generating images(To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
        "duration": "string" //Original video duration, unit: s (seconds)
          "id": "string", // Generated video ID; globally unique, will be cleared after 30 days
Task ID for Video Generation. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
Customized Task ID for Video Generation. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
GET `/v1/videos/video-extend`
  --url 'https://api-singapore.klingai.com/v1/videos/video-extend?pageNum=1&pageSize=30' \
      "task_info": {
        "parent_video": { //Parameters information when the task is created
          "id": "string", //Video ID before the extension；globally unique
          "url": "string", //URL for generating images(To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
          "duration": "string" //Original video duration, unit: s (seconds)
            "id": "string", // Generated video ID; globally unique, will be cleared after 30 days
Value range: \[1, 1000\]
Value range: \[1, 500\]

source: "https://kling.ai/document-api/apiReference/model/textToVideo"
POST `/v1/videos/text2video`
  --url https://api-singapore.klingai.com/v1/videos/text2video \
    "prompt": "A cute little rabbit wearing glasses, sitting at a table, reading a newspaper, with a cup of cappuccino on the table",
    "aspect_ratio": "1:1",
Please note that in order to maintain naming consistency, the original model field has been changed to model\_name, so in the future, please use this field to specify the version of the model that needs to be called.  
At the same time, we keep the behavior forward-compatible. If you continue to use the original model field, it will not have any impact on the interface call, there will not be any exception, which is equivalent to the default behavior when model\_name is empty (i.e., call the V1 model).
Authentication information, refer to API authorization
Enum values：kling-v1kling-v1-6kling-v2-masterkling-v2-1-masterkling-v2-5-turbokling-v2-6kling-v3
- Use <<<voice\_1>>> to specify voice, same sequence as voice\_list. Up to 2 voices; when specifying voice, sound must be on. Simpler grammar is better. For example: The man <<<voice\_1>>> said, "Hello.".
- When voice\_list is not empty and prompt references voice ID, task is billed as "with voice generation".
Each storyboard cue can include both positive and negative descriptions
Is sound generated simultaneously when generating videos
The degree of freedom for generating video; the larger the value, the smaller the degree of freedom of the model
Terms of controlling camera movement (if not specified, the model will intelligently match based on the input text/images)
typestringOptional
Predefined camera movements type
- simple: Simple camera movement, you can choose one of six options in "config"
- down\_back: Camera descends and moves backward ➡️ Pan down and zoom out. The config parameter must be set to "None" under this type.
- forward\_up: Camera moves forward and tilts up ➡️ Zoom in and pan up. The config parameter must be set to "None" under this type.
- right\_turn\_forward: Rotate right then move forward ➡️ Rotate right and advance. The config parameter must be set to "None" under this type.
- left\_turn\_forward: Rotate left then move forward ➡️ Rotate left and advance. The config parameter must be set to "None" under this type.
Contains 6 fields, used to specify the camera's movement or change in different directions
- Required when type is simple, not required for other types
- Choose 1 of the following 6 parameters, only one can be non-zero, others must be 0
Horizontal, controls the camera's movement along the horizontal axis (translation along the x-axis)
- Value range: \[-10, 10\]
- Negative value indicates a translation to the left, positive value indicates a translation to the right
Vertical, controls the camera's movement along the vertical axis (translation along the y-axis)
- Value range: \[-10, 10\]
- Negative value indicates a downward translation, positive value indicates an upward translation
Pan, controls the camera's rotation in the horizontal plane (rotation around the y-axis)
- Value range: \[-10, 10\]
- Negative value indicates rotation to the left around y-axis, positive value indicates rotation to the right around y-axis
Tilt, controls the camera's rotation in the vertical plane (rotation around the x-axis)
- Value range: \[-10, 10\]
- Negative value indicates rotation down around x-axis, positive value indicates rotation up around x-axis
Roll, controls the camera's roll (rotation around the z-axis)
- Value range: \[-10, 10\]
- Negative value indicates counterclockwise rotation around z-axis, positive value indicates clockwise rotation around z-axis
Zoom, controls the camera's focal length change, affecting the distance of the field of view
- Value range: \[-10, 10\]
- Negative value indicates longer focal length, smaller field of view; positive value indicates shorter focal length, larger field of view
Callback notification URL for this task result. If configured, the server will actively notify when the task status changes
- Users can provide a customized task ID, which will not overwrite the system-generated task ID but can be used for task queries
## More Scene Invocation Examples
### Text To Video with Multiple Shot
GET `/v1/videos/text2video/{id}`
  --url https://api-singapore.klingai.com/v1/videos/text2video/{task_id} \
          "duration": "string" // Total video duration, unit: s (seconds)
Task ID for text-to-video. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
Customized Task ID for text-to-video. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
GET `/v1/videos/text2video`
  --url 'https://api-singapore.klingai.com/v1/videos/text2video?pageNum=1&pageSize=30' \

source: "https://kling.ai/document-api/apiReference/model/multiElements"
## Initialize Video for Editing
POST `/v1/videos/multi-elements/init-selection`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/init-selection \
    "video_id": "",
    "video_url": "https://v1-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/animals-output-5s.mp4"
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "status": 0, // Rejection code, non-zero indicates recognition failure
    "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
    "fps": 30.0, // Frame rate of parsed video, required when fetching selection preview video
    "original_duration": 1000, // Duration of parsed video, required when creating task
    "width": 720, // Width of parsed video, currently unused
    "height": 1280, // Height of parsed video, currently unused
    "total_frame": 300, // Total frame count of parsed video, required when creating task
    "normalized_video": "url" // URL of initialized video
Initialize the original video before using Multi-elements feature. When replacing or removing elements within the existing video, the relevant elements need to be marked in the video beforehand.
The ID of the video generated by the Kling AI
- Only videos generated within the last 30 days are supported
- Only supports videos with a duration of ≥2 seconds and ≤5 seconds, or ≥7 seconds and ≤10 seconds
Get link for uploaded video
- Only.mp4/.mov formats are supported
- Only supports videos with a duration of ≥2 seconds and ≤5 seconds, or ≥7 seconds and ≤10 seconds
- Video resolution must be between 720px and 2160px (inclusive) in both width and height
- Only supports videos with frame rates of 24, 30, or 60 fps
## Add Video Selection Area
POST `/v1/videos/multi-elements/add-selection`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/add-selection \
    "session_id": "847570360458960960",
    "frame_index": 0,
    "points": [
        "x": 0.7738498789346246,
        "y": 0.297142857142857
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "status": 0, // Rejection code, non-zero indicates recognition failure
    "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
    "res": {
      "frame_index": 0,
      "rle_mask_list": [{
        "object_id": 0,
        "rle_mask": {
          "size": [720, 1280],
          "counts": "string"
        "png_mask": {
          "size": [720, 1280],
          "base64": "string"
      }]
Session ID, generated during the video initialization task and remains unchanged during editing operations
frame\_indexintRequired
Frame Number
- A maximum of 10 frames can be marked. That is, up to 10 frames can be used to define selection areas in the video
- Only supports marking 1 frame at a time
pointsarrayRequired
Click Coordinates, represented by x and y
- Value range: \[0, 1\], expressed as percentages; \[0, 1\] represents the top-left corner of the frame
- Multiple points can be marked at once; up to 10 points can be marked on a single frame
xfloatRequired
X coordinate \[0-1\]
yfloatRequired
Y coordinate \[0-1\]
### Sample Code
#### Decoding Image Segmentation Result
```typescript
export type RLEObject = {
  size: [h: number, w: number]
  counts: string
type RLE = {
  h: number
  w: number
  m: number
  binaries: number[]
export function decode(rleObj: RLEObject) {
  const [h, w] = rleObj.size
  const R: RLE = { h, w, m: 0, binaries: [0] }
  rleFrString(R, rleObj.counts)
  const unitArray = new Uint8Array(h * w)
  rleDecode(R, unitArray)
  return unitArray
function rleDecode(R: RLE, M: Uint8Array) {
  let j
  let k
  let p = 0
  let v = false
  for (j = 0; j < R.m; j++) {
    for (k = 0; k < R.binaries[j]; k++) {
      const x = Math.floor(p / R.h)
      const y = p % R.h
      M[y * R.w + x] = v === false ? 0 : 1 // Note: y * width + x indicates row-major (horizontal) layout.
      p++
    v = !v
function rleFrString(R: RLE, s: string) {
  let m = 0
  let p = 0
  let k
  let x
  let more
  const binaries = []
  while (s[p]) {
    x = 0
    k = 0
    more = 1
    while (more) {
      const c = s.charCodeAt(p) - 48
      x |= (c & 0x1f) << (5 * k)
      more = c & 0x20
      p++
      k++
      if (!more && c & 0x10) {
        x |= -1 << (5 * k)
    if (m > 2) {
      x += binaries[m - 2]
    binaries[m++] = x
  R.m = m
  R.binaries = binaries
#### Rendering the Segmentation Mask Layer
```typescript
// height refers to the video height and width refers to the video width
function drawMask(rleMask: string, height: number, width: number) {
  if (!canvasRef.value) return
  const ctx = canvasRef.value.getContext('2d')
  if (!ctx) return
  const decodeData = decode({ counts: rleMask, size: [height, width] })
  const imageData = ctx.createImageData(width, height)
  for (let y = 0; y < height; y++) {
    for (let x = 0; x < width; x++) {
      const index = y * width + x
      if (decodeData[index]) {
        const imageIndex = index * 4
        // Set pixel color: red, green, blue, alpha
        imageData.data[imageIndex] = 116 // red
        imageData.data[imageIndex + 1] = 255 // green
        imageData.data[imageIndex + 2] = 82 // blue
        imageData.data[imageIndex + 3] = 163 // alpha
  ctx.putImageData(imageData, 0, 0)
## Delete Video Selection Area
POST `/v1/videos/multi-elements/delete-selection`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/delete-selection \
    "session_id": "847570360458960960",
    "frame_index": 0,
    "points": [
        "x": 0.7738498789346246,
        "y": 0.297142857142857
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "status": 0, // Rejection code, non-zero indicates recognition failure
    "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
    "res": {
      "frame_index": 0,
      "rle_mask_list": [{
        "object_id": 0,
        "rle_mask": {
          "size": [720, 1280],
          "counts": "string"
        "png_mask": {
          "size": [720, 1280],
          "base64": "string"
      }]
Session ID, generated during the video initialization task and remains unchanged during editing operations
frame\_indexintRequired
Frame Number
pointsarrayRequired
Click Coordinates to delete, represented by x and y
- Value range: \[0, 1\], expressed as percentages; \[0, 1\] represents the top-left corner of the frame
- Multiple points can be provided at once
- Coordinates must exactly match those used when adding the video selection area
xfloatRequired
X coordinate \[0-1\]
yfloatRequired
Y coordinate \[0-1\]
## Clear Video Selection
POST `/v1/videos/multi-elements/clear-selection`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/clear-selection \
    "session_id": "847570360458960960"
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "status": 0, // Rejection code, non-zero indicates recognition failure
    "session_id": "id" // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
Session ID, generated during the video initialization task and remains unchanged during editing operations
## Preview Video with Selected Areas
POST `/v1/videos/multi-elements/preview-selection`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/preview-selection \
    "session_id": "847570360458960960"
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "status": 0, // Rejection code, non-zero indicates recognition failure
    "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
    "res": {
      "video": "url", // Video with mask
      "video_cover": "url", // Cover image of video with mask
      "tracking_output": "url" // Mask result for each frame in image segmentation results
Session ID, generated during the video initialization task and remains unchanged during editing operations
POST `/v1/videos/multi-elements`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements \
    "session_id": "847570360458960960",
    "edit_mode": "removal",
    "image_list": [],
    "prompt": "Delete the chick from <<<video_1>>>",
    "mode": "std",
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
      "external_task_id": "string" // User-defined task ID
Session ID, generated during the video initialization task and remains unchanged during editing operations
edit\_modestringRequired
Operation Type
Enum values：additionswapremoval
- addition: Add an element
- swap: Replace an element
- removal: Remove an element
image\_listarrayOptional
Cropped Reference Images
- For adding video elements: This parameter is required; upload 1–2 images
- For editing (swapping) video elements: This parameter is required; upload 1 image only
- For deleting video elements: This parameter is not required
- Use key:value format as follows:
- The API does not perform cropping, please upload images with subjects already cropped
Positive Prompt
- Use the format <<<xxx>>> to explicitly refer to a specific video or image, such as <<<video\_1>>> or <<<image\_1>>>
- To ensure optimal results, the prompt must include references to the video and image(s) required for the editing
- Must not exceed 2,500 characters
**Recommended Prompt Templates:**
**Adding Elements:**
- EN: Using the context of <<<video\_1>>>, seamlessly add \[x\] from <<<image\_1>>>
- ZH: 基于<<<video\_1>>>中的原始内容，以自然生动的方式，将<<<image\_1>>>中的【】，融入<<<video\_1>>>的【】
**Replacing Elements:**
- EN: swap \[x\] from <<<image\_1>>> for \[x\] from <<<video\_1>>>
- ZH: 使用<<<image\_1>>>中的【】，替换<<<video\_1>>>中的【】
**Removing Elements:**
- EN: Delete \[x\] from <<<video\_1>>>
- ZH: 删除<<<video\_1>>>中的【】
Note: \[x\] or 【】 are placeholders where you should fill in specific content.
Negative Prompt
- Must not exceed 2,500 characters
Video Generation Mode
- std: Standard mode, basic rendering, cost-effective
- pro: Professional mode, high-quality, enhanced rendering, better video output quality
Video Duration (in seconds)
- Only 5-second and 10-second videos are supported
- To generate a 5-second video, the input video must be ≥2 seconds and ≤5 seconds
- To generate a 10-second video, the input video must be ≥7 seconds and ≤10 seconds
Callback URL for Task Result Notification. If configured, the server will actively send notifications when the task status changes
- For the message schema, refer to the [Callback Protocol](https://kling.ai/document-api/apiReference/callbackProtocol)
- A user-defined task ID; it will not overwrite the system-generated task ID, but can be used to query the task
- Please ensure uniqueness of the task ID within a single user account
GET `/v1/videos/multi-elements/{id}`
  --url https://api-singapore.klingai.com/v1/videos/multi-elements/{task_id} \
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
    "task_status_msg": "string", // Task status message, displays failure reason when task fails (e.g., triggered platform content moderation)
      "external_task_id": "string" // User-defined task ID
          "id": "string", // Generated video ID, globally unique
          "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
          "url": "string", // URL of generated video (Note: For security purposes, generated images/videos will be deleted after 30 days, please save them promptly)
Task ID for Multi-Elements video editing
Custom Task ID for Multi-Elements video editing
GET `/v1/videos/multi-elements`
  --url 'https://api-singapore.klingai.com/v1/videos/multi-elements?pageNum=1&pageSize=30' \
  "request_id": "string", // Request ID, generated by the system, used for tracking requests and troubleshooting
      "task_status_msg": "string", // Task status message, displays failure reason when task fails (e.g., triggered platform content moderation)
        "external_task_id": "string" // User-defined task ID
            "id": "string", // Generated video ID, globally unique
            "session_id": "id", // Session ID, generated during video initialization task, remains unchanged during editing operations, valid for 24 hours
            "url": "string", // URL of generated video (Note: For security purposes, generated images/videos will be deleted after 30 days, please save them promptly)
            "duration": "string" // Total video duration, unit: s

source: "https://kling.ai/document-api/apiReference/model/motionControl"
POST `/v1/videos/motion-control`
  --url https://api-singapore.klingai.com/v1/videos/motion-control \
  --header 'Content-Type: application/json; charset=utf-8' \
  --data-raw '{
    "image_url": "https://p2-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/multi-3.ng.png",
    "prompt": "The girl is wearing a loose gray T-shirt and denim shorts",
    "video_url": "https://p2-kling.klingai.com/kcdn/cdn-kcdn112452/kling-qa-test/dance.mp4",
    "keep_original_sound": "yes",
    "character_orientation": "image",
    "external_task_id": "xxx"
      "external_task_id": "string" //Customer-defined task ID
Enum values：kling-v2-6kling-v3
Text prompt, can include positive and negative descriptions
- Can add elements to the scene, achieve camera movement effects, etc. See [Kling "Motion Control" User Guide](https://kling.ai/quickstart/motion-control-user-guide)
image\_urlstringRequired
Reference image. Characters, background and other elements in generated video will follow this reference.
- Video content requirements:
	- Character proportions should match the reference motion as much as possible; avoid driving half-body characters with full-body motions
		- Character should show clear upper body or full body including limbs and head, avoid occlusion
		- Avoid extreme orientations (upside down, lying flat, etc.). Character should occupy sufficient screen area
		- Supports realistic/stylized characters (including humans/humanoid animals/some pure animals/some humanoid body proportion characters)
- File size: ≤10MB, dimensions: 300px ~ 65536px, aspect ratio: 1:2.5 ~ 2.5:1
video\_urlstringRequired
URL of reference video. Character actions in generated video will follow this reference.
- Video content requirements:
	- Character should show clear upper body or full body including all limbs and head, avoid occlusion
		- Recommend uploading single-person action video; for 2+ people, actions will be taken from the character with largest screen proportion
		- Recommend using real person actions; some stylized characters/humanoid body proportions may work
		- Video should be single continuous shot with character always visible, avoid cuts or camera movements (will be truncated otherwise)
		- Avoid overly fast actions; relatively stable actions produce better results
- Supported formats:.mp4 /.mov, file size: ≤100MB, dimensions: 340px ~ 3850px. Validation failures will return error codes.
- Duration limits: minimum 3 seconds, maximum depends on character\_orientation:
	- When character\_orientation is "video": maximum 30 seconds
		- When character\_orientation is "image": maximum 10 seconds
- The duration range of the uploaded motion reference is from 3 to 30 seconds, in which the generated video length will align with the duration of the uploaded video. If motions are complex or fast-paced, there is a chance that the output may be shorter than the uploaded video duration, as the model can only extract the valid action duration for generation. The minimum extractable continuous action duration is 3 seconds. Please note that in such cases, the consumed credits cannot be refunded. It is recommended to adjust the complexity and speed of the actions accordingly.
- System will validate video content and return error codes if issues are found
Reference Element List based on element ID configuration
  { "element_id": 829836802793406551 }
- When referencing the element, the generated video can only temporarily refer to the orientation of the person in the video.
- Currently, only one element can be introduced.
Whether to keep the original sound of the video
Enum values：yesno
character\_orientationstringRequired
Character orientation in generated video, can match image or video
Enum values：imagevideo
- image: Match character orientation in the image; reference video duration must not exceed 10 seconds
- video: Match character orientation in the video; reference video duration must not exceed 30 seconds
- When referencing the element, the generated video can only temporarily refer to the orientation of the person in the video.
modestringRequired
- std: Standard Mode - basic mode, cost-effective
- pro: Professional Mode (High Quality) - high performance mode, better video quality
GET `/v1/videos/motion-control/{id}`
  --url https://api-singapore.klingai.com/v1/videos/motion-control/{task_id} \
      "external_task_id": "string" //Customer-defined task ID
          "url": "string", // URL for generating videos, anti-leech format (To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
       },
Task ID for Motion Control. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
Customized Task ID for Motion Control. Fill the value directly in the request path. Choose either task\_id or external\_task\_id for querying.
GET `/v1/videos/motion-control`
  --url 'https://api-singapore.klingai.com/v1/videos/motion-control?pageNum=1&pageSize=30' \
        "external_task_id": "string" //Customer-defined task ID
            "url": "string", // URL for generating videos, anti-leech format (To ensure information security, generated images/videos will be cleared after 30 days. Please make sure to save them promptly.)
