Kling 3.0 Omni Transformation
This page is generated from the upstream official OpenAPI documentation. Endpoints, parameters and examples match the official docs; brand and API domain are replaced with ModelFold.
Endpoint
POST /jobs/createTask
Full URL: https://ai.modelfold.online/v1/jobs/createTask
Authentication: every request must include the
Authorization: Bearer <API_KEY>header.
Query Task Status
After submitting a task, you can check the task progress and retrieve generation results via the unified query endpoint:
- Get Task Details — Learn how to query task status and obtain generation results
TIP
For production use, we recommend using the callBackUrl parameter to receive automatic notifications when generation completes, rather than polling the status endpoint.
Related Resources
- Market Overview — Browse all available models
- Common API — Check account credits and usage status
Request Parameters
Body (application/json)
| Parameter | Type | Required | Description |
|---|---|---|---|
model | string | Yes | The name of the model used to generate the task. This field is required. - This endpoint requires the kling-3.0-omni/transformation model Default:"kling-3.0-omni/transformation"。 Allowed values:kling-3.0-omni/transformation。 示例:kling-3.0-omni/transformation。 |
callBackUrl | string | No | The URL to receive generation task completion updates. Optional but recommended for production use. - System will POST task status and results to this URL when generation completes - Callback includes generated content URLs and task information - Your callback endpoint should accept POST requests with JSON payload containing results - Alternatively, use the Get Task Details endpoint to poll task status - To ensure callback security, see Webhook Verification Guide for signature verification implementation 示例: https://your-domain.com/api/callback。 |
input | `object | object` | Yes |
input.prompt | string | No | Video description. It must not be empty after leading and trailing whitespace is removed. Maximum length: 3,072 characters. 示例:Transform the input video into a cinematic night scene while preserving the character movements from the original video.。 |
input.video_urls | array<string> | No | Array of video URLs. Exactly 1 video is required. HTTP, HTTPS, and OSS URLs are supported. Videos must be in MP4 or MOV format; each file must not exceed 200 MB; duration must be between 3 and 15.5 seconds; width and height must each be between 700 and 4,553 px; total pixels must not exceed 8,294,400; the aspect ratio must be between 0.4 and 2; and the frame rate must be between 24 and 60 fps. |
input.image_urls | array<string> | No | Array of image URLs. The maximum number of images depends on the number and types of reference subjects. When using only multi-image subjects, the combined number of reference images and multi-image subjects must not exceed 4. Video character subjects cannot be used together with multi-image subjects or reference images. HTTP, HTTPS, and OSS URLs are supported. Images must be in JPG, JPEG, or PNG format; each file must not exceed 50 MB; both width and height must be at least 300 px; and the aspect ratio must be between 0.4 and 2.5. |
input.duration | string | No | Video duration. This field may be configured when using a video with images. 示例:5。 |
input.resolution | string | No | Video resolution. 720p outputs a 720p video, 1080p outputs a 1080p video, and 4k outputs a 4K video. Default:"720p"。 Allowed values:720p / 1080p / 4k。 示例:720p。 |
input.aspect_ratio | string | No | Video aspect ratio. Only auto can be used with video-only input. When using a video with images, 16:9, 9:16, and 1:1 are supported; auto is not supported. Default:"16:9"。 Allowed values:16:9 / 9:16 / 1:1 / auto。 示例:16:9。 |
input.audio | boolean | No | No audio is generated when a video is provided; set false. Allowed values:false / true。 示例:false。 |
input.elements | array<object> | No | List of one-time subject assets. The default is an empty array. When using only multi-image subjects, up to 7 subjects can be uploaded. When using only video character subjects, the number of video character subjects must not exceed 3. When using both video character and multi-image subjects, the number of video character subjects must not exceed 3, and the number of multi-image subjects must not exceed 4. Default: []。 |
input.elements[].name | string | Yes | Subject name. It must be unique within the same request and can be referenced in the prompt field using @name. 示例:element_dog。 |
input.elements[].description | string | Yes | Text description of the subject asset. 示例:A happy golden retriever。 |
input.elements[].element_input_urls | array<string> | Yes | List of image URLs for a multi-image subject (provide 2 to 4 images), or a video URL for a video character subject (provide exactly 1 video). Images and videos cannot be mixed. HTTP, HTTPS, and OSS URLs are supported. |
input.elements[].element_input_audio_urls | array<string> | No | Optional list of subject audio asset URLs. HTTP, HTTPS, and OSS URLs are supported. Default:[]。 |
Request Example
curl -X POST "https://ai.modelfold.online/v1/jobs/createTask" \
-H "Authorization: Bearer $MODELFOLD_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-3.0-omni/transformation",
"callBackUrl": "https://your-domain.com/api/callback",
"input": {
"prompt": "Transform the input video into a cinematic night scene while preserving the character movements from the original video.",
"video_urls": [
"https://example.com/source-video.mp4"
],
"resolution": "720p",
"aspect_ratio": "auto",
"audio": false
}
}'{
"model": "kling-3.0-omni/transformation",
"callBackUrl": "https://your-domain.com/api/callback",
"input": {
"prompt": "Transform the input video into a cinematic night scene while preserving the character movements from the original video.",
"video_urls": [
"https://example.com/source-video.mp4"
],
"resolution": "720p",
"aspect_ratio": "auto",
"audio": false
}
}Response
200 — Request Successful
{
"code": 200,
"msg": "success",
"data": {
"taskId": "task_kling-2.6_1765182425861"
}
}Callback
videoTaskCompleted
Callback URL: {request.body#/callBackUrl} (the callBackUrl in the request body).
The system sends this callback when the kling-3.0-omni/transformation task succeeds or fails.
Callback body parameters
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
code | integer | 是 | Unified callback code: 200 for success, 501 for failure. Allowed values:200 / 501。 示例:200。 |
msg | string | 是 | Unified callback message. Allowed values:Playground task completed successfully. / Playground task failed.。 示例:Playground task completed successfully.。 |
data | object | 是 | — |
data.taskId | string | 是 | The unique task identifier. |
data.model | string | 是 | The model used for the task. Allowed values:kling-3.0-omni/transformation。 示例:kling-3.0-omni/transformation。 |
data.state | string | 是 | Terminal task state. Allowed values:success / fail。 示例:success。 |
data.param | string | 是 | JSON string containing the submitted task parameters. |
data.resultJson | string | 否 | JSON string containing resultUrls, firstFrameUrl, lastFrameUrl, or resultObject when successful. Present only when state is success. |
data.failCode | string | 否 | Failure code, a numeric string such as "400" or "500". Present only when state is fail. |
data.failMsg | string | 否 | Failure reason. Present only when state is fail. |
data.costTime | integer | 否 | Processing time in seconds. Present on both success and failure callbacks. |
data.completeTime | integer | 否 | Task completion timestamp. |
data.createTime | integer | 否 | Task creation timestamp. |
data.updateTime | integer | 否 | Use completeTime as the completion time; updateTime may equal createTime. |
data.creditsConsumed | number | 否 | Credits consumed by the task; 0 for failed tasks. |
Task completed successfully
{
"code": 200,
"msg": "Playground task completed successfully.",
"data": {
"taskId": "task_example_video_webhook_001",
"model": "kling-3.0-omni/transformation",
"state": "success",
"param": "{\"input\":\"{\\\"prompt\\\":\\\"Transform the input video into a cinematic night scene while preserving the character movements from the original video.\\\",\\\"video_urls\\\":[\\\"https://example.com/source-video.mp4\\\"],\\\"resolution\\\":\\\"720p\\\",\\\"aspect_ratio\\\":\\\"auto\\\",\\\"audio\\\":false}\",\"callBackUrl\":\"https://example.com/callback\",\"model\":\"kling-3.0-omni/transformation\"}",
"resultJson": "{\"resultUrls\":[\"https://example.com/generated-video.mp4\"]}",
"costTime": 12,
"completeTime": 1234567890,
"createTime": 1234560000,
"updateTime": 1234567890,
"creditsConsumed": 1.23
}
}Task failed
{
"code": 501,
"msg": "Playground task failed.",
"data": {
"taskId": "task_example_video_webhook_001",
"model": "kling-3.0-omni/transformation",
"state": "fail",
"param": "{\"input\":\"{\\\"prompt\\\":\\\"Transform the input video into a cinematic night scene while preserving the character movements from the original video.\\\",\\\"video_urls\\\":[\\\"https://example.com/source-video.mp4\\\"],\\\"resolution\\\":\\\"720p\\\",\\\"aspect_ratio\\\":\\\"auto\\\",\\\"audio\\\":false}\",\"callBackUrl\":\"https://example.com/callback\",\"model\":\"kling-3.0-omni/transformation\"}",
"failCode": "400",
"failMsg": "<error detail>",
"costTime": 12,
"creditsConsumed": 0
}
}