Skip to main content
POST
cURL

Usage notes

  • Frames: image_urls[0] is the required first frame and an optional image_urls[1] is the last frame. Put middle frames in keyframe_urls in chronological order (up to 8). The output aspect ratio follows the first frame, so aspect_ratio is not accepted.
  • Frame limit: the total number of frames (first + keyframes + last) is capped by duration: 3s → 4, 4s → 5, 5s → 6, 6s → 7, 7s → 8, 8s → 9, 9s or longer → 10. Exceeding the cap returns a 400 error before a task is created.
  • Mentioning frames: use @first_frame, @keyframe_1..@keyframe_N and @last_frame in the prompt to describe what happens at each frame. Only frames you provided can be mentioned.
  • Audio: every clip includes native audio, so there is no generate_audio parameter — sending it is rejected.
  • Not supported: negative_prompt, multi_shot / multi_prompt, reference videos, kling_elements, voices, and 4K output.

Billing

Billed per second of output video. The per-second rate depends on the resolution (720p or 1080p) and does not change with the number of frames. Current prices are shown on the model page.

Task flow

The create call returns data.task_id. Poll Query video task until status is completed (outputs in data.result) or failed, or pass callback_url to be notified when the task reaches a terminal state.

Authorizations

Authorization
string
header
required

Use your APIPod API key as a Bearer token in the Authorization header.

Body

application/json
model
string
required

Public APIPod model ID.

Allowed value: "kling-4.0-i2v"
prompt
string
required

Required, up to 8,000 characters. Mention the frames you uploaded as @first_frame, @keyframe_1..@keyframe_N and @last_frame; only provided frames can be mentioned, otherwise the request is rejected.

Required string length: 1 - 8000
image_urls
string[]
required

Required. image_urls[0] is the first frame; an optional image_urls[1] is the last frame. Put middle frames in keyframe_urls. The output aspect ratio follows the first frame. first_frame_image / last_frame_image are accepted as aliases.

Required array length: 1 - 2 elements
keyframe_urls
string[]

Optional middle frames in chronological order (up to 8), mentioned as @keyframe_1..@keyframe_N. Requires a first frame; the total frame count is capped by duration.

Maximum array length: 8
duration
integer
default:5

Output duration in seconds (3-30). Defaults to 5. Also caps the total number of frames (first + keyframes + last): 3s → 4, 4s → 5, 5s → 6, 6s → 7, 7s → 8, 8s → 9, 9s or longer → 10.

Required range: 3 <= x <= 30
resolution
enum<string>
default:720p

Output resolution. Defaults to 720p. 4K is not available for Kling 4.0.

Available options:
720p,
1080p
callback_url
string
default:""

HTTPS URL that receives the task's terminal state.

Response

200 - application/json

Task accepted

Standard response for task submission

code
integer
required
data
Task Submit Data · object
required

Data content for task submission

message
string
required