Skip to content

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.

Request Parameters ​

Body (application/json) ​

ParameterTypeRequiredDescription
modelstringYesThe 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。
callBackUrlstringNoThe 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`objectobject`Yes
  input.promptstringNoVideo 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_urlsarray&lt;string&gt;NoArray 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_urlsarray&lt;string&gt;NoArray 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.durationstringNoVideo duration. This field may be configured when using a video with images. 示例:5。
  input.resolutionstringNoVideo 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_ratiostringNoVideo 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.audiobooleanNoNo audio is generated when a video is provided; set false. Allowed values:false / true。 示例:false。
  input.elementsarray&lt;object&gt;NoList 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[].namestringYesSubject name. It must be unique within the same request and can be referenced in the prompt field using @name. 示例:element_dog。
    input.elements[].descriptionstringYesText description of the subject asset. 示例:A happy golden retriever。
    input.elements[].element_input_urlsarray&lt;string&gt;YesList 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_urlsarray&lt;string&gt;NoOptional list of subject audio asset URLs. HTTP, HTTPS, and OSS URLs are supported. Default:[]。

Request Example ​

bash
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
  }
}'
json
{
  "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 ​

json
{
  "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

参数类型必填说明
codeinteger是Unified callback code: 200 for success, 501 for failure. Allowed values:200 / 501。 示例:200。
msgstring是Unified callback message. Allowed values:Playground task completed successfully. / Playground task failed.。 示例:Playground task completed successfully.。
dataobject是—
  data.taskIdstring是The unique task identifier.
  data.modelstring是The model used for the task. Allowed values:kling-3.0-omni/transformation。 示例:kling-3.0-omni/transformation。
  data.statestring是Terminal task state. Allowed values:success / fail。 示例:success。
  data.paramstring是JSON string containing the submitted task parameters.
  data.resultJsonstring否JSON string containing resultUrls, firstFrameUrl, lastFrameUrl, or resultObject when successful. Present only when state is success.
  data.failCodestring否Failure code, a numeric string such as "400" or "500". Present only when state is fail.
  data.failMsgstring否Failure reason. Present only when state is fail.
  data.costTimeinteger否Processing time in seconds. Present on both success and failure callbacks.
  data.completeTimeinteger否Task completion timestamp.
  data.createTimeinteger否Task creation timestamp.
  data.updateTimeinteger否Use completeTime as the completion time; updateTime may equal createTime.
  data.creditsConsumednumber否Credits consumed by the task; 0 for failed tasks.

Task completed successfully

json
{
  "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

json
{
  "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
  }
}

ModelFold — one API for all the best AI models.