Skip to main content
POST
Create image
  • 路径 POST /kling/v1/images/generations
  • Image O1 与 Image 3.0 Omni 请使用 Omni 图像,不使用本入口。
  • 字段详解:请参考官网权威文档
请求参数
注意:使用 kling-v1-5image 参数不为空时,image_reference 参数必填。非 kling-v1-5 模型不支持 image_reference 补充约束prompt 长度 ≤ 2500;图生图场景(image 非空)不支持 negative_prompt 模型边界kling-v3-omni 仅通过 /kling/v1/images/omni-image 放行;kling-v2-5-turbo 等视频模型不能用于 /images/generations

场景一:文生图

场景二:角色特征参考

场景三:人脸参考

场景四:批量生成

示例响应
任务成功响应

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
aspect_ratio
string

纵横比

callback_url
string

回调通知地址

element_list
object[]
external_task_id
string

自定义任务ID

human_fidelity
number

面部参考强度 [0,1]

image
string

参考图像,Base64或URL

image_fidelity
number

图片参考强度 [0,1]

image_reference
string

图片参考类型:subject, face

model_name
string

模型名称,默认kling-v1

n
integer

生成图片数量 [1,9]

negative_prompt
string

负向文本提示词

prompt
string

正向文本提示词,必须

resolution
string

清晰度:1k, 2k

watermark_info
object

水印信息

Response

200 - application/json

OK

code
integer

错误码

data
object

单个任务数据

data_list
object[]

任务列表数据

message
string

错误信息

request_id
string

请求ID