How to Generate Kling 4.0 Video via the Kling API
5 min read • October 18, 2026 (November 5, 2026)
Table of contents
- Introduction
- Before you start
- Kling 4.0 at a glance
- Generate a Kling 4.0 video in two calls
- Longer, wider and 1080p
- Image-to-video with keyframes
- Omni with references and voices
- Batch-generate with the script
- What it costs
- The same from an AI assistant
- Examples
- Frequently asked questions
- Conclusion
Introduction
Kling 4.0 launched in the Kling app on October 15, 2026, and the useapi.net Kling API has run it on your Kling AI website subscription since that day, while Kling’s own developer API added it between October 25 and 28, at higher prices. To call it, send "model_name": "kling-v4-0" to POST /videos/text2video. useapi.net is a third-party API, not affiliated with Kling AI or Kuaishou Technology. Kling 4.0 makes 3 to 30 second clips at 720p or 1080p, always with a stereo soundtrack, and adds the 21:9 aspect ratio and keyframes between the start and end frames. Since November 5, 2026 the API also runs Kling 4.0 Flash (kling-v4-0-flash), a lower-cost 720p version for 3 to 20 second clips.
This guide is one real run. We asked Kling 4.0 for the cheapest clip it makes, 3 seconds at 720p, on a Kling Pro subscription. The job finished in about 2 minutes and took 27 Kling credits off the balance (300,290 to 297,590 in the account’s hundredths of a credit), about $0.29 at the Pro plan’s credit price, during Kling’s launch discount for subscribers. That discount has ended, and the same clip now uses 30 credits, $0.33 (as of November 2026). Every response below is from that run, with the account email left out.
Before you start
You need a useapi.net API token and a Kling account connected through Setup Kling. Kling 4.0 at 1080p needs a paid Kling plan. Export the token so the curl examples run as they are:
export USEAPI_TOKEN="user:1234-..." # your useapi.net API token
export KLING_EMAIL="[email protected]" # your connected Kling account
email is optional in the request body: without it, the API picks one of your Kling accounts that has a free job slot (429 when every account is busy). With more than one account, note which account ran the job (GET tasks/task_id explains how to find it), because polling the task needs that account’s email. If Kling hasn’t opened Kling 4.0 to your account yet, the create call returns 403 with AUTH.VPrivilegeEscalation, and nothing is charged.
Kling 4.0 at a glance
Kling 4.0 (kling-v4-0) | Kling 4.0 Flash (kling-v4-0-flash) | |
|---|---|---|
| Duration | 3 to 30 seconds, default 5 | 3 to 20 seconds, default 5 |
| Resolution | std 720p, pro 1080p (paid Kling plan). No 4K or HDR yet | std 720p only |
| Aspect ratio | 16:9, 9:16, 1:1, 21:9 | 16:9, 9:16, 1:1, 21:9 |
| Audio | Always on, stereo | Always on |
| Prompt | Up to 8000 characters | Up to 8000 characters |
| Shots | Kling may cut the clip into several shots, or you write up to 6 shot prompts (15 seconds in total) | No multi-shot parameters |
| Frames (image-to-video) | Start, end and up to 9 keyframes | Start image only |
| Credits per second | 10 at 720p, 15 at 1080p, on every Kling plan | 6 at 720p |
The same model is on three endpoints: text-to-video, image-to-video with start, end and keyframe images, and Omni with reference images, elements, videos and voices. The credit price is the same on all three, for Kling 4.0 and for Flash.
Generate a Kling 4.0 video in two calls
Generation is asynchronous. The create call answers right away with a task, and you poll the task until it is final.
1. Submit the job
POST /videos/text2video with model_name set to kling-v4-0:
curl -s -X POST "https://api.useapi.net/v1/kling/videos/text2video" \
-H "Authorization: Bearer $USEAPI_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"email": "'"$KLING_EMAIL"'",
"model_name": "kling-v4-0",
"mode": "std",
"duration": "3",
"aspect_ratio": "16:9",
"prompt": "A small paper boat sails across a rain puddle on a city sidewalk at dusk, neon signs reflect and ripple in the water, raindrops patter around it and a tram bell rings in the distance, low camera at water level"
}'
The answer came back in about a second. The parts that matter, from our run:
{
"task": {
"id": 324332112308198,
"type": "m2v_aio2video",
"status": 5,
"status_name": "submitted",
"status_final": false
},
"works": [],
"status": 5,
"status_name": "submitted",
"status_final": false,
"message": "",
"userPoints": {
"points": [],
"total": 297590
}
}
task.id is the id you poll. userPoints.total is the balance after the charge, in hundredths of a credit, so 297590 is 2,975.90 credits. The task’s arguments echo what Kling received: kling_version 4.0, model_mode std, enable_audio true and prefer_multi_shots true. Kling 4.0 always turns audio on, and it may cut the clip into shots on its own. The create call is the paid step, so don’t resend it after a timeout. Poll or list your tasks instead.
2. Poll for the result
curl -s "https://api.useapi.net/v1/kling/tasks/324332112308198?email=$KLING_EMAIL" \
-H "Authorization: Bearer $USEAPI_TOKEN"
Ours read processing for about 2 minutes, then:
{
"status": 99,
"status_name": "succeed",
"status_final": true,
"works": [
{
"workId": 324332112317252,
"status_name": "succeed",
"resource": {
"resource": "https://v15-kling.klingai.com/bs2/upload-ylab-stunt-sgp/....mp4",
"height": 720,
"width": 1280,
"duration": 3041
}
}
]
}
The MP4 is 1280×720, 3.04 seconds, H.264 video with a two-channel AAC soundtrack. A task is done when status_final is true, and status_name: "succeed" means it worked. The other final statuses are failures, listed on GET /tasks/task_id. Pass a replyUrl in the create body if you’d rather get a webhook than poll.
3. Download the master
Free Kling plans get a watermarked works[0].resource.resource. On a paid plan, GET /assets/download returns a cdnUrl to the clean file:
curl -s "https://api.useapi.net/v1/kling/assets/download?email=$KLING_EMAIL&workIds=324332112317252&fileTypes=MP4" \
-H "Authorization: Bearer $USEAPI_TOKEN"
Longer, wider and 1080p
Change three fields and keep the rest. A 10-second 1080p cinema-wide clip:
{
"model_name": "kling-v4-0",
"mode": "pro",
"duration": "10",
"aspect_ratio": "21:9",
"prompt": "..."
}
That costs 150 credits (15 per second) on every Kling plan. duration goes up to 30. To direct the cuts yourself, send shot_1_prompt with shot_1_duration, shot_2_prompt with shot_2_duration and so on, up to 6 shots and 15 seconds in total, in place of prompt and duration. negative_prompt and cfg_scale don’t apply to Kling 4.0.
Image-to-video with keyframes
POST /videos/image2video-frames with model_name: kling-v4-0 takes a start frame (image, required), an optional end frame (image_tail) and up to 9 keyframes in between (keyframe_1 to keyframe_9), in order. That is up to 10 images in total, and at most the duration in seconds plus one, so a 5-second clip takes up to 6 images. Upload each image with POST /assets first and pass the returned URLs:
curl -s -X POST "https://api.useapi.net/v1/kling/videos/image2video-frames" \
-H "Authorization: Bearer $USEAPI_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"email": "'"$KLING_EMAIL"'",
"model_name": "kling-v4-0",
"mode": "std",
"duration": "5",
"image": "https://example.com/start.jpg",
"keyframe_1": "https://example.com/middle.jpg",
"image_tail": "https://example.com/end.jpg",
"prompt": "the boat drifts from the puddle into the gutter stream"
}'
The aspect ratio comes from the start image. You poll and download the result the same way as above.
Omni with references and voices
POST /videos/omni with omni_version: v4 runs Kling 4.0 with up to 10 reference images, 7 elements (IMAGE and VIDEO), 5 reference videos of 3 to 30 seconds each (30 seconds in total) and 3 voices, including your own voice saved with POST /videos/voices. Reference them in the prompt as @image_1, @video_1 or @voice_1. omni_version: v4-flash runs Kling 4.0 Flash with the same images, elements and up to 5 reference videos (3 to 20 seconds each, 20 seconds in total), but no voices. Omni 4.0 doesn’t take start and end frames, so use image-to-video above for those. The Kling Omni tutorial walks through the reference workflows.
Batch-generate with the script
The kling-4 example in the kling-api GitHub repo reads Kling 4.0 prompts from prompts.json (text-to-video, 21:9 and multi-shot) or prompts-frames.json (start, end and keyframe images), checks each one against the documented limits before it spends credits, submits it, polls the task and downloads the clean master. Run it with Node.js v21 or newer:
git clone https://github.com/useapi/kling-api.git
cd kling-api/kling-4
node ./kling4.mjs "$USEAPI_TOKEN" "$KLING_EMAIL"
The Kling v3 tutorial explains the script line by line.
What it costs
Kling 4.0 uses the credits of your Kling AI website subscription, at the rates in the table above, and useapi.net adds no per-video charge. On Kling Pro ($32.56 a month for 3,000 credits), that comes to about $0.11 a second at 720p and $0.16 at 1080p, so a 5-second 720p video uses 50 credits, $0.54, and the plan makes 60 of them a month. A 5-second Kling 4.0 Flash video uses 30 credits, $0.33 on Pro (as of November 2026). The cost calculator on the Kling API page prices every model on each Kling plan.
Kling’s own developer API sells Kling 4.0 in prepaid packs from $500 instead, separate from the app subscriptions: $0.154 a second at 720p and $0.231 at 1080p, and $0.092 a second for Kling 4.0 Flash (as of November 5, 2026). Kling 4.0 API pricing compares the price per second on each Kling plan with Kling’s developer API and the API resellers.
Kling 4.0 also runs on a PixVerse subscription, through the useapi.net PixVerse API with "model": "kling-4.0" in POST videos/create. On every PixVerse plan it costs more per second than on a Kling plan, so a Kling subscription is the cheaper way to run it (every route compared).
The same from an AI assistant
The hosted Kling MCP server at https://api.useapi.net/v1/kling/mcp exposes the same calls as 45 tools for Claude Code, Cursor and VS Code, Kling 4.0 and 4.0 Flash included. Ask for “a 5-second Kling 4.0 clip of …” and the assistant calls kling_text_to_video with model_name: kling-v4-0 on your account.
Examples
Kling 4.0 » kling-v4-0, text-to-video, std 720p, 3 seconds, 16:9, the run above
The prompt is in step 1. 27 Kling credits on a Pro plan during Kling’s launch discount (30 at the full price), about 2 minutes, with its stereo soundtrack.
Four more Kling 4.0 clips, 9:16 at 720p with their own sound, made with the batch script at 45 credits each on Kling Pro during the launch discount, are in a 20-second YouTube Short.
Kling 4.0 Flash (kling-v4-0-flash, text-to-video, std 720p, 10 seconds, 16:9) made this cinematic muscle-car clip with sound from one prompt: 60 Kling credits, $0.61 on Kling Premier (November 5, 2026).
Frequently asked questions
Is there a Kling 4.0 API? Through useapi.net, yes, on your Kling AI website subscription: $0.152 a second at 1080p on Kling Premier, from a prompt, from start, end and key frames, or from Omni references and voices, and Kling 4.0 Flash at 720p. Kling’s own developer API charges $0.231 a second at 1080p, in prepaid packs from $500 sold separately from the app subscriptions (as of November 5, 2026).
What is the model name for Kling 4.0? Through useapi.net, Kling 4.0 is kling-v4-0 in the model_name field of POST /videos/text2video and POST /videos/image2video-frames, and omni_version: v4 on POST /videos/omni. Kling 4.0 Flash is kling-v4-0-flash, or omni_version: v4-flash. negative_prompt and cfg_scale don’t apply to either, and the credit price is the same on all three endpoints.
Does Kling 4.0 need a paid Kling plan? Through useapi.net, Kling 4.0 at 720p (mode: std) runs on any Kling account that has credits, including credits bought without a subscription, and 1080p (mode: pro) needs a paid Kling AI subscription. The Free plan has no monthly credits, so it needs a credit pack first. A 403 with AUTH.VPrivilegeEscalation means Kling hasn’t opened the model to that account yet, and nothing is charged. Kling 4.0 Flash makes 720p only.
Can I turn audio off? Through useapi.net, no: Kling 4.0 always makes a stereo soundtrack and doesn’t accept enable_audio, so leave the field out. Our test video came back with two-channel AAC audio next to H.264 video. For a video without sound, use Kling v3 (kling-v3-0) instead, where enable_audio: false turns the sound off.
How long can a Kling 4.0 video be? Through useapi.net, a Kling 4.0 video runs 3 to 30 seconds in one generation, set with duration, while Kling 4.0 Flash stops at 20 seconds and Kling v3 at 15. When you write the shots yourself with shot_1_prompt to shot_6_prompt, the total stays within 15 seconds, and a single prompt may still be cut into several shots by Kling.
Do I need a Kling developer account or API key? Through useapi.net, no: you need a useapi.net API token and a Kling account connected once through Setup Kling, with no Kling developer account and no prepaid pack. The same token works on the hosted Kling MCP server, so Claude Code, Cursor or VS Code can make Kling 4.0 videos for you.
Conclusion
Kling 4.0 is one field away from any Kling call you already make: set model_name to kling-v4-0 and pick a duration up to 30 seconds. The full model reference is on the Kling API page, and the runnable code is in the kling-api GitHub repo.
Visit our Discord Server or
Telegram Channel for any support questions and concerns.