by Kuaishou

Build Kling 4.0 scenes from image, video and audio references. Map upload tokens, validate media limits and quote source-video costs before launch.

kling/4.0/reference-to-video
Kling 4.0 AI Video Generator online
  • Up to 1080p
  • 3–30s clips
  • Sound included
  • Up to 10 reference images
  • 4 aspect ratios
  • Create Video
  • Image to Video
  • Reference to Video
  • Extend Video
  • Edit Video

About Kling 4.0

reference-to-video takes a required prompt and separate arrays for reference images, videos and audio. Preserve each array’s upload order so @Image1, @Video1 and @Audio1 identify the intended asset.

Call it with the model name kling/4.0/reference-to-video on POST /jobs/createTask, from $0.45.

Introduction

Kling 4.0 Reference to video casts a new clip from what you upload: up to 10 reference images for people, objects and places, up to 5 reference videos (30 seconds in total) for motion, camera and pacing, and up to 3 audio clips for a voice or a sound. Name each one in the prompt as @Image1, @Image2, @Video1 or @Audio1, numbered in upload order. Clips run 3 to 30 seconds at 720p or 1080p with a stereo soundtrack.

Choose a Kling 4.0 mode by starting material

What you have at the startMode
a written scene or scriptKling 4.0 Text to video
an opening frame, and optionally a closing frame and in-between framesKling 4.0 Image to video
photos, clips or voice samples to cast fromKling 4.0 Reference to video (you are here)
a clip you want to changeKling 4.0 Video edit
a clip you want to continueKling 4.0 Video extend

Key features

Images, videos and voices in one request

Kling 4.0 takes all three kinds of reference together. Images set who and what appears, videos set how the camera and the subject move, and audio clips set how someone sounds.

Name each reference in the prompt

Write @Image1, @Image2 and so on in upload order, and say what each one is. In our trailer example "@Image1 is the woman, @Image2 is the chrome trailer" was enough to put that woman in front of that trailer.

Borrow a camera move from a clip

A reference video passes on its motion and pacing. Turn on keep_original_audio to keep that clip's own sound instead of generating new audio.

Request parameters

ParameterRequiredDescription
aspect_ratioNoThe shape of the frame: wide, square or tall. auto · 16:9 · 9:16 · 1:1 · 21:9 · Default: auto
duration_secondsNoLength of the generated clip. ≥ 3 · ≤ 30 · Default: 5
keep_original_audioNoKeep the source clip’s own sound. Default: false
promptYesDescribe what you want to make.
reference_audio_urlsNoAudio to match: a voice, music or a rhythm.
reference_image_urlsNoPictures of the people, outfits or places the result should keep.
reference_video_urlsNoClips whose motion, camera or style the result should follow.
resolutionNoChoose an available output size. 720p · 1080p · Default: 720p

Pricing

Prices are in USD and charged to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your PopNow balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.

OptionUSD per second
resolution 720p · with_video true$0.09
resolution 1080p · with_video true$0.135
resolution 720p$0.15
resolution 1080p$0.224

Send the same request body to POST /jobs/quote to see the estimated and maximum USD charge before running. A quote does not run the task or charge your balance.

Use cases

Put a person in a place they were never photographed

A portrait plus a photo of a location becomes a scene of that person there, with the action you describe.

Keep a prop or vehicle consistent

Give a car, a motorcycle or an outfit its own reference image so it looks the same in every clip.

Match a voice

Add a voice sample of 5 to 30 seconds as @Audio1 and write the line in quotes; the spoken line follows that voice.

Prompt guide & pro tips

Open with the cast list

Start with one sentence per reference - "@Image1 is the man, @Image2 is the motorcycle" - then describe the shot.

A few clear references beat many similar ones

One clear photo per person or object works better than several near-duplicates that the model has to average.

Leave aspect_ratio on auto

On auto the clip follows the shape of your references; set it only when you need a specific frame.

API quick start

Call the Kling 4.0 API in three steps

  1. Create an API key. Sign in to PopNow and create a key in the API console. Keys start with sk-popnow-. API calls are billed in USD from your PopNow balance.
  2. Send the request. POST /jobs/createTask with model kling/4.0/reference-to-video and an input object that follows the parameter table. The response returns a task ID straight away.
  3. Get the result. Poll GET /jobs/recordInfo with the task ID, or pass a callBackUrl and we post the result to it. Download the output links when the task succeeds.
# 1. Create the task. Keep the Idempotency-Key if you retry after a network error.
export IDEMPOTENCY_KEY="$(uuidgen)"
curl -X POST https://api.popnow.ai/api/v1/jobs/createTask \
  -H "Authorization: Bearer $POPNOW_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $IDEMPOTENCY_KEY" \
  -d '{
  "model": "kling/4.0/reference-to-video",
  "input": {
    "prompt": "A slow aerial shot drifting over a misty pine forest at sunrise",
    "aspect_ratio": "auto",
    "resolution": "720p",
    "duration_seconds": 5
  }
}'

# 2. Copy data.taskId from the response, then poll until state is succeeded, failed, canceled or expired.
TASK_ID="TASK_ID_FROM_RESPONSE"
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=$TASK_ID" \
  -H "Authorization: Bearer $POPNOW_API_KEY"

Replace the prompt and any links with your own. The API tab has the response, polling and callback reference.

About the Kling 4.0 Reference to Video endpoint

The limits are ten images, five videos totalling no more than 30 seconds, and three audio clips of 5 to 30 seconds each. References condition a newly generated scene; they do not specify chronological keyframes.

keep_original_audio only applies when a reference video is present and defaults to false. Source video can affect the quote, so retrieve a fresh estimate after changing, adding or removing a clip.

Kling 4.0 API questions

How much does the Kling 4.0 API cost?

Kling 4.0 starts at $0.45 for a 5-second clip with Reference to Video, its lowest-priced task. Prices by option: 720p · true $0.09 per second, 1080p · true $0.135 per second, 720p $0.15 per second, 1080p $0.224 per second. API usage is charged in USD to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your PopNow balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.

What are the limits of the Kling 4.0 · Reference to Video API?

Clip length: 3–30 s; Resolutions: 720p · 1080p; Aspect ratios: auto · 16:9 · 9:16 · 1:1 · 21:9; Reference audio: 3; Reference images: 10. Requests outside these limits are rejected before anything is charged.

More about Kling 4.0