API
If you're looking for an API, you can choose from your desired programming language.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import requests
api_key = "YOUR_API_KEY"
url = "https://api.segmind.com/v1/kling-2"
# Prepare data and files
data = {}
files = {}
data['prompt'] = "A photograph of a giant panda swimming in a crystal-clear outdoor pool. The panda is gracefully paddling with its black and white fur glistening in the sunlight, its playful expression clearly visible. The pool is surrounded by lush green foliage and colorful flowers, with a wooden deck leading to a grassy lawn. Soft, natural light bathes the scene, highlighting the water's clarity and the panda's movements."
data['duration'] = 5
data['cfg_scale'] = 0.5
# For parameter "start_image", you can send a raw file or a URI:
# files['start_image'] = open('IMAGE_PATH', 'rb') # To send a file
data['start_image'] = 'https://segmind-resources.s3.amazonaws.com/input/65a44af9-de76-474e-898f-57e83b0ff3b3-a-photograph-of-a-giant-panda-swimming-i_k_2X05UAQYWIOoZJLuVpyg_eFEiq19KSYO9FzXR4tdibQ.jpeg' # To send a URI
data['aspect_ratio'] = "16:9"
data['negative_prompt'] = ""
headers = {'x-api-key': api_key}
# If no files, send as JSON
if files:
response = requests.post(url, data=data, files=files, headers=headers)
else:
response = requests.post(url, json=data, headers=headers)
print(response.content) # The response is the generated image
Attributes
Prompt for video generation
Number of second of video to be generated.
Allowed values:
Flexibility in video generation: Higher values reduce flexibility but increase adherence to the user's prompt.
min : 0,
max : 1
Input image that acts as the starting frame for the generated video. Get best results with16:9 or 9:16 and 1280x720 or 720x1280, depending on the aspect ratio you choose.
Aspect ratio of the output video
Allowed values:
Prompt to exclude from the generated video
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Kling 2.0 is a state-of-the-art AI video generation model developed by Kling AI (Kuaishou), officially released in April 2025. It represents a significant leap forward in generative video and image technology, delivering professional-grade results for creators, marketers, educators, and anyone seeking high-quality, customizable video content.
What Does Kling 2.0 Do?
Kling 2.0 is an upgrade to Kling 1.6 to generate videos from text prompts or reference images. Its core strength lies in transforming detailed user instructions into visually rich, dynamic, and realistic video sequences. The model excels at understanding complex prompts, interpreting nuanced actions, and simulating sophisticated camera movements, all while maintaining high visual fidelity and stylistic consistency.
What Is Kling 2.0 Good At?
- Fluid, Realistic Motion: Kling 2.0 delivers highly natural movement in generated videos, overcoming the stiff or jerky animations seen in earlier models. It can handle complex physical actions-like running, riding, or flying-with convincing realism.
- Prompt Adherence: The model interprets and executes user instructions with greater accuracy, supporting multi-step actions and nuanced emotional transitions. This makes it easier to achieve the exact creative vision without excessive prompt tweaking.
- Visual Fidelity: Kling 2.0 produces cinematic-quality visuals up to 720p, with advanced lighting, atmospheric effects, and detailed textures. It maintains consistency in style and character appearance throughout a video.
- Multi-Modal Integration: Leveraging its Multi-Modal Visual Language (MVL), Kling 2.0 can blend text, images, and video inputs, enabling more complex and engaging narratives.
Ideal Use Cases
Kling 2.0 is versatile and fits a wide range of creative and professional scenarios:
- Content Creation: Ideal for YouTubers, filmmakers, and social media influencers who need dynamic, visually appealing videos with minimal production effort.
- Marketing and Advertising: Brands can quickly generate high-quality promotional videos tailored to specific campaigns or audiences.
- Education and Training: Educators can create engaging instructional videos or visualizations that illustrate complex concepts with clarity and style.
- Entertainment and Storytelling: Writers and animators can rapidly prototype scenes, visualize storyboards, or produce short films without traditional filming or animation resources.
- Rapid Prototyping: Designers and agencies can iterate on visual concepts, test different scenarios, and present ideas to clients with unprecedented speed.
Summary
Kling 2.0 stands out as a next-generation AI creative tool, combining advanced video generation, precise prompt adherence, cinematic visuals, and powerful editing capabilities. It empowers users-from solo creators to large enterprises-to produce, customize, and iterate on professional-quality video content with ease, making it a leading choice in the evolving landscape of AI-driven media production.
Other Popular Models
face-to-many
Turn a face into 3D, emoji, pixel art, video game, claymation or toy

faceswap-v2
Take a picture/gif and replace the face in it with a face of your choice. You only need one image of the desired face. No dataset, no training

sdxl-inpaint
This model is capable of generating photo-realistic images given any text input, with the extra capability of inpainting the pictures by using a mask

codeformer
CodeFormer is a robust face restoration algorithm for old photos or AI-generated faces.
