promptstringआवश्यक
Text prompt for video generation. Either prompt or multi_prompt must be provided, but not both.
kwaivgi/kling-video/v3/pro/text-to-videoKling V3 Pro Text to Video by Kuaishou turns a text prompt into a 3-15 second 1080p video with optional native audio.
model को आज़माएँ
आप आगे क्या करना चाहेंगे?
प्लेग्राउंड में इसके इनपुट और परिणाम लोड करने के लिए कोई उदाहरण चुनें।
{
"prompt": "Close-up of glowing fireflies dancing in a dark forest at twilight. Soft bioluminescent particles float through the air. Shallow depth of field, bokeh lights in background. Magical atmosphere, gentle movement."
}मानवीय पसंद
ब्लाइंड साइड-बाय-साइड वोटों से प्राप्त Elo रेटिंग, अन्य इमेज और वीडियो मॉडलों से तुलना में।
रैंकिंग का स्रोत Artificial Analysis Arena
टेक्स्ट-से-वीडियो Arena (मौन): लोग एक ही प्रॉम्प्ट से बने दो क्लिप्स में से बेहतर चुनते हैं, मॉडल नाम देखे बिना; ऑडियो का मूल्यांकन नहीं किया जाता।
Kling V3 Pro text-to-video: write a scene and get back a 3–15 second clip, with native audio and multi-shot control.
| Field | Type | Default | Notes |
|---|---|---|---|
prompt | string, required | — | Up to 2,500 characters. |
aspect_ratio | 16:9 / 9:16 / 1:1 | 16:9 | Output frame shape. |
duration | 3–15 | 5 | Output length in seconds. |
generate_audio | boolean | true | Generate native audio with the clip. |
shot_type | customize / intelligent | customize | customize follows your multi_prompt shot list; intelligent lets the model plan the cuts. |
multi_prompt | object[] | — | Optional list of shots, each with its own prompt and duration. |
You pay for output seconds: $0.168 with audio (the default) and $0.112 without.
| Output | With audio | Without audio |
|---|---|---|
| 3s | $0.504 | $0.336 |
| 5s (default) | $0.84 | $0.56 |
| 10s | $1.68 | $1.12 |
| 15s | $2.52 | $1.68 |
Failed runs are not charged.
multi_prompt with one entry per shot.Other Kling V3 Pro endpoints and tiers: kwaivgi/kling-video/v3/pro/image-to-video, kwaivgi/kling-video/v3/pro/motion-control, kwaivgi/kling-video/v3/standard/text-to-video, kwaivgi/kling-video/v3/4k/text-to-video.
बिल्डिंग शुरू करें
इस model को SandBase Unified Run API के माध्यम से सबमिट करें।
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "kwaivgi/kling-video/v3/pro/text-to-video",
"prompt": "Close-up of glowing fireflies dancing in a dark forest at twilight. Soft bioluminescent particles float through the air. Shallow depth of field, bokeh lights in background. Magical atmosphere, gentle movement.",
"duration": 5,
"shot_type": "customize",
"aspect_ratio": "16:9",
"generate_audio": true
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"एक SandBase API key बनाएँ और इसे अपने server environment में सेट करें। सभी requests Bearer authentication का उपयोग करती हैं।
export SANDBASE_API_KEY="YOUR_API_KEY"Key को सर्वर पर रखें। इसे browser code में expose न करें या repository में commit न करें।
इस model ID और इसके inputs के साथ /v1/run पर POST करें। ऊपर दिया गया request example submission और polling दोनों शामिल करता है।
Completed, failed या timeout होने तक poll करने के लिए लौटाए गए run ID का उपयोग करें। Output केवल completed होने के बाद पढ़ें।
curl "https://api.sandbase.ai/v1/run/$RUN_ID" \
-H "Authorization: Bearer $SANDBASE_API_KEY"Model के image, video या audio field में सार्वजनिक रूप से उपलब्ध फ़ाइल URL पास करें। समर्थित formats और limits प्रत्येक Playground input के पास दिखाए गए हैं।
Playground में समर्थित image fields पर upload या replace control का उपयोग करें। Video URL fields hosted driving video स्वीकार करते हैं; इससे video-upload support का संकेत नहीं मिलता।
promptstringआवश्यकText prompt for video generation. Either prompt or multi_prompt must be provided, but not both.
durationintegerThe duration of the generated video in seconds
डिफ़ॉल्ट: 5
संभावित मान: 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
shot_typestringThe type of multi-shot video generation. 'intelligent' lets the model automatically determine shot structure.
डिफ़ॉल्ट: "customize"
संभावित मान: "customize", "intelligent"
aspect_ratiostringThe aspect ratio of the generated image.
डिफ़ॉल्ट: "16:9"
संभावित मान: "16:9", "9:16", "1:1"
multi_promptarrayList of prompts for multi-shot video generation. If provided, overrides the single prompt and divides the video into multiple shots with specified prompts and durations.
generate_audiobooleanWhether to generate native audio for the video. Supports Chinese and English voice output. Other languages are automatically translated to English. For English speech, use lowercase letters; for acronyms or proper nouns, use uppercase.
डिफ़ॉल्ट: true
{
"model": "kwaivgi/kling-video/v3/pro/text-to-video",
"prompt": "Close-up of glowing fireflies dancing in a dark forest at twilight. Soft bioluminescent particles float through the air. Shallow depth of field, bokeh lights in background. Magical atmosphere, gentle movement.",
"duration": 5,
"shot_type": "customize",
"aspect_ratio": "16:9",
"generate_audio": true
}पूरा हुआ run अपना परिणाम output में दिखाता है। नीचे दिया गया model का सेव किया हुआ example है, नई generation नहीं।
[
{
"poster": "https://static.sandbase.ai/examples/posters/b58a784a894237addece.jpg",
"source": "Kling AI official schema mirror",
"source_url": "https://kling.ai/document-api/guides/get-started/overview",
"url": "https://static.sandbase.ai/examples/f582e051-7e71-4908-8adb-c3ae426edd17/output/5f556a12-5745-4b0e-a6aa-94529a974b5a.mp4"
}
]