- 🔥最新公告
- OpenAI SDK教程
- 聊天(OpenAIChat)
- AnthropicClaude
- 火山引擎API
- 图像(Images)
- 视频生成(Videos)
- 视频生成
- sora
- 数字人系列-对口型(lipsync)
- Runway(官方格式)
- Luma(官方格式)
- 可灵API(官方格式)
- 智谱清影(Cogvideox官方格式)
- 可灵2.0(通用格式)
- 即梦视频 3.0
- 音频(Audio)
- 嵌入(RAG-Embeddings)
- 重排序(RAG-Reranker)
- 对象存储+文件解析(Files)
- 内容审查(Moderations)
- 助手测试版(AssistantsBeta)待开发
- 线程数(Threads)待开发
- 留言(Messages)待开发
- 运行(Runs)待开发
- 批量API(Batch API)待开发
- 微调(Fine-tuning)待开发
- 🔥AI 工具
- 文档智能&图片处理
- AI产品配置教程
- 教程类
- 系统API
- Midjourney
- 未命名接口POST
- 未命名接口POST
创建任务
POST
https://api.chatfire.cn/tasks/kling
最后修改时间:2025-01-03 06:19:03
责任人:未设置
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Query 参数
vip
string
必需
示例值:
true
Header 参数
Content-Type
string
必需
示例值:
application/json
Body 参数application/json
aspect_ratio
string
视频尺寸
camera
object
运镜参数
horizontal
integer
必需
pan
integer
必需
roll
integer
必需
tilt
integer
必需
type
string
必需
vertical
integer
必需
zoom
integer
必需
cfg
number
参考度
duration
integer
时长
negative_prompt
string
负向提示词
prompt
string
提示词
tail_image_url
string
结束图片,尾帧
url
string
开始图片,主要
model
string
必需
mode
string
必需
示例
{
"aspect_ratio": "16:9",
"camera": {
"horizontal": 0,
"pan": 0,
"roll": 0,
"tilt": 0,
"type": "empty",
"vertical": 0,
"zoom": 0
},
"cfg": 0.5,
"duration": 5,
"negative_prompt": "",
"prompt": "一只可爱的黑白边境牧羊犬,头伸出车窗,毛发被风吹动,微笑着伸出舌头",
"tail_image_url": "",
"url": ""
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.chatfire.cn/tasks/kling?vip=true' \
--header 'Content-Type: application/json' \
--data-raw '{
"aspect_ratio": "16:9",
"camera": {
"horizontal": 0,
"pan": 0,
"roll": 0,
"tilt": 0,
"type": "empty",
"vertical": 0,
"zoom": 0
},
"cfg": 0.5,
"duration": 5,
"negative_prompt": "",
"prompt": "一只可爱的黑白边境牧羊犬,头伸出车窗,毛发被风吹动,微笑着伸出舌头",
"tail_image_url": "",
"url": ""
}'
返回响应
🟢200成功
application/json
Body
id
string
必需
status
string
必需
status_code
null
必需
data
object
必需
result
integer
必需
status
integer
必需
message
string
必需
data
object
必需
timestamp
array[integer]
必需
metadata
null
必需
created_at
integer
必需
description
null
必需
示例
{
"id": "kling@vip-104590378",
"status": "success",
"status_code": null,
"data": {
"result": 1,
"status": 200,
"message": "Success",
"data": {
"task": {
"id": 104590378,
"userId": 5137445,
"type": "m2v_txt2video_hq",
"status": 5,
"taskInfo": {
"type": "m2v_txt2video_hq",
"inputs": [],
"arguments": [
{
"name": "prompt",
"value": "一只可爱的黑白边境牧羊犬,头伸出车窗,毛发被风吹动,微笑着伸出舌头"
},
{
"name": "negative_prompt",
"value": ""
},
{
"name": "duration",
"value": "5"
},
{
"name": "aspect_ratio",
"value": "16:9"
},
{
"name": "imageCount",
"value": "1"
},
{
"name": "cfg",
"value": "0.5"
},
{
"name": "camera_json",
"value": "{\"type\": \"empty\", \"horizontal\": 0, \"vertical\": 0, \"zoom\": 0, \"tilt\": 0, \"pan\": 0, \"roll\": 0}"
},
{
"name": "biz",
"value": "klingai"
},
{
"name": "camera_control_enabled",
"value": "false"
},
{
"name": "kling_version",
"value": "1.6"
},
{
"name": "__deviceType",
"value": "python-httpx/0.28.1"
},
{
"name": "__effect",
"value": "m2v_txt2video_1080p_v16"
},
{
"name": "__platform",
"value": "WEB"
},
{
"name": "__priority",
"value": "HIGH"
},
{
"name": "__userType",
"value": "MEMBERSHIP"
}
],
"extraArgs": {}
},
"favored": false,
"deleted": false,
"viewed": false,
"createTime": 1735885761506,
"updateTime": 1735885761506,
"viewTime": 0
},
"works": [],
"status": 5,
"message": "",
"limitation": {
"type": "m2v_txt2video_hq",
"remaining": 10000,
"limit": 10000
},
"userPoints": {
"points": [
{
"orderId": "658342152586133530",
"type": "plan",
"amount": 800000,
"balance": 40520,
"startTime": 1724990554245,
"endTime": 1788062554245
},
{
"orderId": "669768530862800967",
"type": "recharge",
"amount": 33000,
"balance": 33000,
"startTime": 1727713780229,
"endTime": 1790785780229
},
{
"orderId": "672518967248572455",
"type": "plan",
"amount": 300000,
"balance": 300000,
"startTime": 1728369624939,
"endTime": 1791441624939
},
{
"orderId": "702508662275219538",
"type": "plan",
"amount": 66000,
"balance": 66000,
"startTime": 1735519759759,
"endTime": 1798591759759
}
],
"total": 439520
},
"userTickets": {
"ticket": [
{
"orderId": "702508559179464732",
"type": "priority",
"packageType": "reward",
"amount": 1,
"balance": 1,
"startTime": 1735519611272,
"endTime": 1738198011272
},
{
"orderId": "702508559179464732",
"type": "extend",
"packageType": "reward",
"amount": 2,
"balance": 2,
"startTime": 1735519611272,
"endTime": 1738198011272
},
{
"orderId": "702508559179464732",
"type": "hq_5s",
"packageType": "reward",
"amount": 5,
"balance": 5,
"startTime": 1735519611272,
"endTime": 1738198011272
}
]
}
},
"timestamp": [
2025,
1,
3,
14,
29,
21,
876821000
]
},
"metadata": null,
"created_at": 1735885758,
"description": null
}
修改于 2025-01-03 06:19:03