Kling AI - Text to Video
Generate professional-quality videos from text descriptions using Kling AI's advanced video generation model. Features customizable duration, aspect ratios, camera controls, and professional rendering modes.
Endpoint
Request Headers
Field | Value |
---|---|
API-KEY | <api-key> |
Content-Type | application/json |
Request Parameters
Field Name | Type | Example | Description | Required |
---|---|---|---|---|
type | string | TEXT_TO_VIDEO | Feature identifier | ✔️ |
model | string | kling | AI model to use | ✔️ |
conversationId | string | TEXT_TO_VIDEO | Conversation context | ✔️ |
promptObject.prompt | string | a futuristic city | Video description | ✔️ |
promptObject.duration | number | 5 | Video duration (5 or 10 seconds) | ✔️ |
promptObject.negative_prompt | string | blurry, low quality | What not to include in the video | ❌ |
Advanced Parameters
Field Name | Type | Example | Description | Required |
---|---|---|---|---|
promptObject.aspect_ratio | string | 16:9 | Video aspect ratio (16:9, 9:16, 1:1) | ❌ |
promptObject.version | string | 1.0 | Model version (1.0 or 1.5) | ❌ |
promptObject.mode | string | std | Rendering mode (std or pro) | ❌ |
promptObject.cfg_scale | number | 0.5 | CFG scale (0 to 1) | ❌ |
promptObject.camera_control_type | string | default | Camera movement type | ❌ |
promptObject.camera_control_value | number | 0 | Camera control intensity (-10 to 10) | ❌ |
Camera Control Types
default
- AI auto-selects based on prompthorizontal
- Horizontal camera movementvertical
- Vertical camera movementzoom
- Zoom in/out effectpan
- Panning movementtilt
- Tilting movementroll
- Rolling movement
Code Examples
- cURL
- JavaScript
- Python
curl --location 'https://api.1min.ai/api/features' \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"type": "TEXT_TO_VIDEO",
"model": "kling",
"conversationId": "TEXT_TO_VIDEO",
"promptObject": {
"prompt": "a futuristic city with flying cars at sunset",
"duration": 5,
"negative_prompt": "blurry, low quality",
"aspect_ratio": "16:9",
"mode": "std",
"version": "1.0",
"cfg_scale": 0.5,
"camera_control_type": "default"
}
}'
fetch('https://api.1min.ai/api/features', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'API-KEY': 'YOUR_API_KEY'
},
body: JSON.stringify({
type: 'TEXT_TO_VIDEO',
model: 'kling',
conversationId: 'TEXT_TO_VIDEO',
promptObject: {
prompt: 'a futuristic city with flying cars at sunset',
duration: 5,
negative_prompt: 'blurry, low quality',
aspect_ratio: '16:9',
mode: 'std',
version: '1.0',
cfg_scale: 0.5,
camera_control_type: 'default'
}
})
})
import requests
url = "https://api.1min.ai/api/features"
headers = {
"Content-Type": "application/json",
"API-KEY": "YOUR_API_KEY"
}
data = {
"type": "TEXT_TO_VIDEO",
"model": "kling",
"conversationId": "TEXT_TO_VIDEO",
"promptObject": {
"prompt": "a futuristic city with flying cars at sunset",
"duration": 5,
"negative_prompt": "blurry, low quality",
"aspect_ratio": "16:9",
"mode": "std",
"version": "1.0",
"cfg_scale": 0.5,
"camera_control_type": "default"
}
}
response = requests.post(url, headers=headers, json=data)
Interactive Playground
API Playground
https://api.1min.ai/api/features
Controls adherence to prompt (0-1)
Generated cURL Command:
curl -X POST "https://api.1min.ai/api/features" \
-H "API-KEY: <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"type": "TEXT_TO_VIDEO",
"model": "kling",
"conversationId": "TEXT_TO_VIDEO",
"promptObject": {
"prompt": "a futuristic city with flying cars at sunset",
"duration": 5,
"negative_prompt": "",
"aspect_ratio": "16:9",
"mode": "std",
"version": "1.0",
"cfg_scale": 0.5,
"camera_control_type": "default"
}
}'
Response
{}