Happy Horse 1.0 is now on ModelsLab

Try Now
Skip to main content
Imagen

Kling 3.0 API AI Video Generation for Developers

Kling 3.0 API for text-to-video, image-to-video, and motion-controlled cinematic clips. One REST endpoint, predictable pricing, no cold starts. Webhook delivery for async video generation.

What is the Kling AI API?

Kling AI, exposed as a developer video API

Kling AI is Kuaishou's family of cinematic video generation models, including Kling 3.0 and Kling 2.6 with motion control. The models produce high-fidelity 5–10 second clips from a text prompt or a reference image, with controllable camera motion, subject trajectory, and aspect ratio.

The ModelsLab Kling AI API exposes Kling 3.0 and Kling 2.6 motion control as one REST endpoint so developers can ship cinematic video features inside SaaS apps, marketing platforms, and creative tools without managing GPU clusters or wiring up Kuaishou's vendor SDK directly.

When to use the Kling AI API

Use the Kling AI API when you need cinematic-quality video output with motion control — pan, tilt, zoom, subject trajectory — exposed through a clean REST surface. Kling 3.0 is the right choice for short-form social, ads, product video, and storyboard previs.

  • Text-to-video at 720p and 1080p with cinematic motion
  • Image-to-video to animate a still photo or product shot
  • Motion control for explicit camera movement and subject trajectory
  • 5–10 second clip durations, MP4 output via CDN URL
  • Webhook callback for async generation — no long-polling required
  • Pay-per-second pricing, no monthly minimum

Trusted by

Google logo
Salesforce logo
Amazon logo
IBM logo
Adobe logo
Sony logo
Google logo
Salesforce logo
Amazon logo
IBM logo
Adobe logo
Sony logo
Google logo
Salesforce logo
Amazon logo
IBM logo
Adobe logo
Sony logo
Google logo
Salesforce logo
Amazon logo
IBM logo
Adobe logo
Sony logo
1B+

Images Processed Monthly

500K+

Active Developers

5K+

Discord Community Members

300+

Available AI APIs

Kling AI API quick start

Generate cinematic video clips from a text prompt or a reference image with one POST request.

Python — text-to-video with Kling 3.0

Python
1import requests
2
3response = requests.post(
4 "https://modelslab.com/api/v6/video/text2video",
5 json={
6 "key": "YOUR_API_KEY",
7 "model_id": "kling-3.0",
8 "prompt": "a slow dolly-in on a vintage red sports car parked at sunset, cinematic 35mm",
9 "negative_prompt": "low quality, blurry",
10 "height": 1080,
11 "width": 1920,
12 "num_frames": 121,
13 "fps": 24
14 }
15)
16
17# Returns webhook payload with the final MP4 URL when complete
18print(response.json())

JavaScript — image-to-video with motion control

JavaScript
1const response = await fetch('https://modelslab.com/api/v6/video/img2video', {
2 method: 'POST',
3 headers: { 'Content-Type': 'application/json' },
4 body: JSON.stringify({
5 key: 'YOUR_API_KEY',
6 model_id: 'kling-2.6-motion-control',
7 init_image: 'https://example.com/product.png',
8 prompt: 'slow orbit around the product, soft studio lighting',
9 motion_control: { pan: 0.4, tilt: 0.0, zoom: 0.2 },
10 num_frames: 121,
11 fps: 24,
12 webhook: 'https://your-app.com/webhooks/kling',
13 }),
14});
15
16const data = await response.json();
17console.log(data);

cURL — motion-controlled trajectory

bash
1curl -X POST 'https://modelslab.com/api/v6/video/text2video' \
2 -H 'Content-Type: application/json' \
3 -d '{
4 "key": "YOUR_API_KEY",
5 "model_id": "kling-2.6-motion-control",
6 "prompt": "a hummingbird hovering over a flower, then darting forward",
7 "motion_control": {
8 "trajectory": [
9 {"frame": 0, "subject_x": 0.5, "subject_y": 0.5},
10 {"frame": 60, "subject_x": 0.7, "subject_y": 0.4},
11 {"frame": 120, "subject_x": 0.9, "subject_y": 0.3}
12 ],
13 "zoom": 0.1
14 },
15 "num_frames": 121,
16 "fps": 24
17 }'

Kling AI API endpoints

REST endpoints for programmatic video generation with motion control, text-to-video, and image-to-video.

Text-to-video endpoint

POST /v6/video/text2video — generate videos from text prompts. Submit a natural-language description with optional motion control parameters and receive webhook notifications when generation completes. Returns video URL with metadata.

Image-to-video endpoint

POST /v6/video/img2video — animate a still image into video. Upload an image URL or base64 file with motion instructions. The API processes the image and applies physics-based animation while preserving subject identity.

Motion control endpoint

Specify precise camera movements and subject trajectories in your request. Define horizontal pan, vertical tilt, zoom parameters, and per-frame subject positions using structured JSON for full cinematic control.

Webhook callbacks

Async processing with webhook notifications. Submit generation requests and receive callbacks when processing completes — includes status updates, error handling, and the final MP4 URL.

Multiple resolutions

Generate 720p and 1080p clips at 24fps or 30fps. Aspect ratios include 16:9 (landscape), 9:16 (portrait for short-form social), and 1:1 (square for ad formats).

Text-to-video endpoint
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result
Example of AI outpainting result

Enterprise-grade video generation API with consistent uptime, fast processing, and predictable pay-per-second pricing.

Kling 3.0 vs Kling 2.6 motion control

What changed between Kling 3.0 and Kling 2.6 motion control. Both are exposed via the same ModelsLab endpoint.

CapabilityKling 3.0Kling 2.6 motion control
Max resolution1080p720p / 1080p
Max clip length10 seconds10 seconds
Frame rate24 / 30 fps24 fps
Camera motion controlPan / tilt / zoomPan / tilt / zoom + trajectory
Subject trajectory keyframesImplicit via promptPer-frame positions
Best forHigh-fidelity hero shotsPrecise camera & subject control
ModelsLab model_idkling-3.0kling-2.6-motion-control

Specs based on Kuaishou public release notes for Kling 3.0 (2026) and Kling 2.6 motion control.

Motion control parameters

Camera and subject motion knobs accepted by the Kling motion-control endpoint.

ParameterRangeEffect
pan-1.0 to 1.0Horizontal camera movement (negative left, positive right)
tilt-1.0 to 1.0Vertical camera movement (negative down, positive up)
zoom-1.0 to 1.0Zoom out (negative) or in (positive)
roll-1.0 to 1.0Camera rotation around the optical axis
trajectory[]arrayPer-frame subject_x / subject_y positions for explicit subject motion

How to use the Kling AI API

Integrate AI video generation in three simple steps.

STEP 01
STEP 01

Step 1: Get your API key

Sign up for ModelsLab and grab your API key from the dashboard. The same key works across image, video, audio, and LLM endpoints. No credit card required to start.

STEP 02
STEP 02

Step 2: Send your video request

POST to the Kling endpoint with your text prompt or image URL. Include motion control parameters, aspect ratio, duration, and a webhook URL in the JSON body.

STEP 03
STEP 03

Step 3: Receive the video URL

Get the MP4 URL via webhook callback when generation completes. Videos are CDN-distributed for fast download or streaming. Typical generation time is 60–120 seconds for a 5-second clip.

Why teams use the ModelsLab Kling AI API

Key advantages that set us apart

Kling 3.0 and Kling 2.6 motion control on one REST endpoint
Text-to-video and image-to-video supported
Pan, tilt, zoom, roll, and per-frame trajectory control
Webhook callbacks for async video delivery
720p and 1080p output, 24/30 fps, all common aspect ratios
Pay-per-second pricing — no subscription required
Predictable response times on dedicated GPU pool
Python and JavaScript SDKs plus full OpenAPI spec
CDN-distributed MP4 delivery for fast download
Integrated with image, audio, and LLM APIs in the same dashboard
24/7 developer support and SLA-backed uptime for enterprise
GDPR-compliant — generated videos auto-deleted after 7 days

Our Popular Use Cases

B2B applications powered by the Kling AI API:

Build video creation SaaS products with Kling AI as the generation engine. Offer text-to-video, image animation, and motion control to your users without managing GPU infrastructure.

SaaS video platforms

Kling AI API — frequently asked questions

The ModelsLab Kling AI API is a REST endpoint that runs Kling 3.0 and Kling 2.6 motion-control video generation on cloud GPU infrastructure. POST a text prompt or reference image, optionally include motion-control parameters, and receive an MP4 URL via webhook when the clip is ready.

Set model_id="kling-3.0" in your request body. The endpoint URL is the same; the model_id parameter selects which Kling release runs the generation. For motion-control workloads, use model_id="kling-2.6-motion-control" instead.

Kling 3.0 is the newer release with improved fidelity and 1080p native output. Kling 2.6 motion control is a specialized version that exposes per-frame subject trajectories and explicit camera motion knobs. Kling 3.0 is the default for hero shots; 2.6 motion control is the right pick when you need precise control over camera and subject movement.

The motion_control object accepts pan (-1.0 to 1.0), tilt (-1.0 to 1.0), zoom (-1.0 to 1.0), roll (-1.0 to 1.0), and trajectory (an array of per-frame {frame, subject_x, subject_y} positions). Pan moves the camera horizontally, tilt vertically, zoom in/out, roll rotates the optical axis, and trajectory moves the subject explicitly across frames.

A 5-second 1080p clip typically generates in 60–90 seconds on Kling 3.0. Motion-control jobs take 90–120 seconds. The API runs on a dedicated GPU pool with no cold starts, so the first request is the same speed as the thousandth.

Pricing is per-second of generated video. Kling 3.0 starts at $0.05 per output second; Kling 2.6 motion control starts at $0.07 per second (extra inference for motion control). There is no monthly subscription required. Volume pricing kicks in at 1000+ minutes per month.

Yes. POST to the img2video endpoint with an init_image URL and a prompt that describes the desired motion. Kling animates the source image while preserving subject identity. This is ideal for product videos, animated portraits, and brand-asset animation.

Yes. Pass width=1080 and height=1920 for 9:16 vertical clips suitable for TikTok, Reels, and Shorts. The API also supports 1:1 square (1080×1080) for feed ads and 16:9 landscape for YouTube and broadcast.

Both are supported. For 5-second clips, you can poll the status endpoint or supply a webhook URL in the request body. Webhook delivery is recommended for production — no long-polling, lower failure rate, and the final MP4 URL is delivered straight to your event handler when ready.

Yes. Prompts and generated videos are processed on infrastructure inside compliant regions. Outputs are auto-deleted from the CDN after 7 days by default. A signed DPA is available for enterprise customers, and dedicated VPC deployments are offered for teams with strict compliance needs.

Related developer APIs

Your Data is Secure: GDPR Compliant AI Services

ModelsLab GDPR Compliance Certification Badge

GDPR Compliant

AI Image API Pricing Starting at $0.0047 Per Image

ModelsLab offers a free tier with pay-as-you-go pricing, a Standard plan at $47/month for 10,000 API calls, and a Premium plan at $199/month with unlimited calls. All plans include access to Flux, SDXL, Stable Diffusion 3, and 10,000+ community models. Cancel anytime.

Coming Soon

We are making some changes to our pricing, please check back later.

Get Expert Support in Seconds

We're Here to Help.

Want to know more? You can email us anytime at support@modelslab.com

View Docs

Plugins

Explore Plugins for Pro

Our plugins are designed to work with the most popular content creation software.

API

Build Apps with
ML
API

Use our API to build apps, generate AI art, create videos, and produce audio with ease.