> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mixroute.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Kling Motion Control

> Generate Kling videos from a character image and motion-reference video.

Authenticate with your MixRoute API Key using `Authorization: Bearer $MIXROUTE_API_KEY` and send JSON. The model ID belongs in the URL, not a body `model` field. Do not add `/v1` or wrap the request in `metadata`.

Supports `kling-3.0` and `kling-2.6`, both at `720p` / `1080p` only, not `4k`. This controls character motion from a reference video; it is not a separate motion model or a camera-movement-only setting.

## Request Parameters

| Field                            | Type      | Required | Description                                                                                                                                                                    |
| -------------------------------- | --------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `contents`                       | object\[] | Yes      | Input collection containing an appearance image and a motion video, with an optional prompt.                                                                                   |
| `contents[].type`                | string    | Yes      | Required per item: prompt, image, video; 3.0 additionally supports element.                                                                                                    |
| `contents[].text`                | string    | By type  | Required for prompt items, maximum 2500 characters; may include positive and negative descriptions.                                                                            |
| `contents[].url`                 | string    | By type  | Required for image/video items. Images accept URLs or Base64; videos use public URLs.                                                                                          |
| `contents[].element_id`          | string    | By type  | Required for 3.0 element items only; at most 1 Element.                                                                                                                        |
| `contents[].id`                  | string    | By type  | Required for element items, unique within the task and referenced as @id.                                                                                                      |
| `settings.character_orientation` | string    | Yes      | video: follow video orientation, reference length 3-30 s; image: follow image orientation, reference length 3-10 s. With an Element, orientation follows the video; set video. |
| `settings.resolution`            | string    | No       | 720p (default) or 1080p; 4k is unsupported.                                                                                                                                    |
| `settings.audio`                 | string    | No       | original (default) preserves reference audio; off removes audio. native is unsupported.                                                                                        |

<Warning>
  Do not send `settings.duration`. Usable continuous motion determines output length, which may be shorter than the reference; at least 3 seconds of usable motion is required. Billing uses actual generated duration.
</Warning>

## Media Limits

* Image: JPG/JPEG/PNG, at most 50 MB; both dimensions at least 300 px, aspect ratio 1:2.5 to 2.5:1.
* Video: MP4/MOV, at most 100 MB, each dimension 340-3850 px; duration depends on character\_orientation.
* Match character proportions across image and video. Keep the head and limbs visible and unobstructed. Prefer one person in a continuous single shot; avoid cuts and fast movements.

## Request Example

Set the `MIXROUTE_API_KEY` environment variable. Replace `example.com` media URLs with real, publicly accessible files.

```bash theme={null}
curl --request POST "https://api.mixroute.ai/kling/motion-control/kling-3.0" \
  --header "Authorization: Bearer $MIXROUTE_API_KEY" \
  --header "Content-Type: application/json" \
  --data '{
  "contents": [
    {
      "type": "prompt",
      "text": "The person follows the reference motion."
    },
    {
      "type": "image",
      "url": "https://example.com/person.png"
    },
    {
      "type": "video",
      "url": "https://example.com/motion.mp4"
    }
  ],
  "settings": {
    "resolution": "720p",
    "character_orientation": "video",
    "audio": "original"
  }
}'
```

See [Kling Overview](/en/api-reference/endpoint/kling).

## Submission Response

```json theme={null}
{
  "code": 0,
  "message": "",
  "request_id": "REQUEST_ID",
  "data": {
    "id": "task_example",
    "status": "submitted"
  }
}
```

Keep `data.id` and use [Query Kling Task](/en/api-reference/endpoint/kling-tasks) until `succeeded` or `failed`. Successful submission does not mean generation has finished.
