Flexible parameters
Configure 11 documented parameters, including aspect_ratio, duration_seconds, enable_sound, first_frame_image_url, last_frame_image_url.
All-purpose video generation guided by image and video references
curl -X POST https://runapi.ai/api/v1/kling/image_to_video \
-H "Authorization: Bearer $RUNAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-o1",
"image_url": "https://cdn.runapi.ai/public/samples/image.jpg",
"prompt": "Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan."
}'
import { KlingClient } from "@runapi.ai/kling";
const client = new KlingClient();
const result = await client.imageToVideo.run({
model: "kling-o1",
image_url: "https://cdn.runapi.ai/public/samples/image.jpg",
prompt: "Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan.",
});
import os
import requests
response = requests.post(
"https://runapi.ai/api/v1/kling/image_to_video",
headers={"Authorization": f"Bearer {os.environ['RUNAPI_API_KEY']}"},
json={"model":"kling-o1","image_url":"https://cdn.runapi.ai/public/samples/image.jpg","prompt":"Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan."}
)
response.raise_for_status()
<?php
$client = curl_init("https://runapi.ai/api/v1/kling/image_to_video");
curl_setopt_array($client, [
CURLOPT_HTTPHEADER => ["Authorization: Bearer " . getenv("RUNAPI_API_KEY"), "Content-Type: application/json"],
CURLOPT_POSTFIELDS => json_encode([
'model' => 'kling-o1',
'image_url' => 'https://cdn.runapi.ai/public/samples/image.jpg',
'prompt' => 'Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan.',
])
]);
$response = curl_exec($client);
RunApi client = new RunApi(System.getenv("RUNAPI_API_KEY"));
Task task = client.imageToVideo().run({"model":"kling-o1","image_url":"https://cdn.runapi.ai/public/samples/image.jpg","prompt":"Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan."});
task.waitForResult();
require "runapi/kling"
client = RunApi::Kling::Client.new
result = client.image_to_video.run(
model: "kling-o1",
image_url: "https://cdn.runapi.ai/public/samples/image.jpg",
prompt: "Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan."
)
client := runapi.NewClient(os.Getenv("RUNAPI_API_KEY"))
task, err := client.imageToVideo.Run({"model":"kling-o1","image_url":"https://cdn.runapi.ai/public/samples/image.jpg","prompt":"Create a 10-second video of a person walking through an autumn forest, leaves falling, cinematic camera pan."})
if err != nil { log.Fatal(err) }
task.Wait()
$ runapi generate \
--model kling-o1 \
--endpoint image_to_video \
--wait
18 versions available
Pick any model and generate in seconds.
Pick any model and generate in seconds.
| Provider | Kuaishou |
| Model ID | kling-o1 |
| Modality | Video |
| Task types | Asynchronous |
| API endpoint | /api/v1/kling/text_to_video, /api/v1/kling/image_to_video |
| Billing unit | second |
| Input parameters | aspect_ratio, callback_url, duration_seconds, enable_sound, first_frame_image_url, last_frame_image_url, mode, model, preserve_reference_video_audio, prompt, reference_image_urls, reference_video_type, reference_video_url |
| Max duration | 5s |
| Aspect ratios | 16:9, 9:16, 1:1 |
| Catalog status | Operational |
Sign up for free and create an API key for kling-o1 from the dashboard.
POST to /api/v1/kling/image_to_video with the kling-o1 model slug and your parameters.
Poll the task or follow the callback to retrieve the completed kling-o1 result.
Configure 11 documented parameters, including aspect_ratio, duration_seconds, enable_sound, first_frame_image_url, last_frame_image_url.
Exposes 2 public endpoint(s): text_to_video, image_to_video.
Asynchronous tasks accept a callback URL for completion notifications.
Metered by second with no subscription requirement.
modeGeneration mode. (std, pro)
promptVideo description; reference media with matching numbered markers.
aspect_ratioOutput aspect ratio. (16:9, 9:16, 1:1)
callback_urlWebhook URL for async notifications.
enable_soundSound generation must remain disabled.
duration_secondsDuration in seconds. (5)
reference_video_urlPublic HTTP(S) MP4 or MOV reference video URL; cannot be combined with last_frame_image_url.
last_frame_image_urlPublic HTTP(S) JPG, JPEG, or PNG final-frame image URL; cannot be combined with reference_image_urls or reference_video_url.
reference_image_urlsOrdered public HTTP(S) JPG, JPEG, or PNG reference image URLs; cannot be combined with last_frame_image_url.
reference_video_typeUse the video as a base edit or feature reference. (base, feature)
first_frame_image_urlPublic HTTP(S) JPG, JPEG, or PNG first-frame image URL.
preserve_reference_video_audioPreserve the reference video's original audio.
Generate product launch clips and short-form ads from a text brief, cutting production from weeks to hours.
Convert lesson scripts into animated explainer videos at scale without a camera or crew.
Produce viral short-form content for social platforms directly from a prompt.
Pass the model ID shown in the quickstart.
Per-key rate limits scale with your usage tier. The pricing page shows current limits. If you need higher throughput, contact support to discuss tier upgrades.
Yes. Variant is a parameter in the request. Switch by changing the model ID — no code changes, no re-authentication, no separate billing setup. All variants share the same API key and request shape.
Where streaming is available, RunAPI streams end-to-end. LLM models support token-level streaming. Media models use async task polling or webhook callbacks for result delivery.
Open an issue on the public GitHub repo or email support at [email protected]. Include the task ID and model ID so the team can investigate the specific generation.
No. Your RunAPI API key is enough to access this variant and every other model in the catalog. You do not need accounts with the underlying provider.
We're here to help with enterprise setup, integrations, and technical questions.
Contact Us