curl --request POST \
--url https://api.evolink.ai/v1/images/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "doubao-seedream-5.5",
"prompt": "一片宁静的湖水倒映着夕阳的美景",
"size": "16:9",
"quality": "2K"
}
'{
"created": 1757165031,
"id": "task-unified-1793612886-seedream55",
"model": "doubao-seedream-5.5",
"object": "image.generation.task",
"progress": 0,
"status": "pending",
"task_info": {
"can_cancel": true,
"estimated_time": 45
},
"type": "image",
"usage": {
"billing_rule": "per_image",
"credits_reserved": 1.836,
"user_group": "default"
}
}{
"error": {
"code": "invalid_request",
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"code": "unauthorized",
"message": "Invalid or expired token",
"type": "authentication_error"
}
}{
"error": {
"code": "insufficient_quota",
"message": "Insufficient quota. Please top up your account.",
"type": "insufficient_quota"
}
}{
"error": {
"code": "model_access_denied",
"message": "Token does not have access to model: doubao-seedream-5.5",
"type": "invalid_request_error"
}
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Too many requests, please try again later",
"type": "rate_limit_error"
}
}{
"error": {
"code": "internal_error",
"message": "Internal server error",
"type": "api_error"
}
}Seedream 5.5 图像生成
🚧 该模型暂未开放,敬请期待
- Seedream 5.5 (doubao-seedream-5.5) 支持文生图、图生图和图像编辑,可生成透明背景图片
- 异步处理,使用返回的任务 ID 查询任务状态
- 生成的图像链接,有效期为24小时,请尽快保存
计费说明
- 按实际生成的图片数量计费
- 参考图另行收费,与生成图片分开计费
curl --request POST \
--url https://api.evolink.ai/v1/images/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "doubao-seedream-5.5",
"prompt": "一片宁静的湖水倒映着夕阳的美景",
"size": "16:9",
"quality": "2K"
}
'{
"created": 1757165031,
"id": "task-unified-1793612886-seedream55",
"model": "doubao-seedream-5.5",
"object": "image.generation.task",
"progress": 0,
"status": "pending",
"task_info": {
"can_cancel": true,
"estimated_time": 45
},
"type": "image",
"usage": {
"billing_rule": "per_image",
"credits_reserved": 1.836,
"user_group": "default"
}
}{
"error": {
"code": "invalid_request",
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"code": "unauthorized",
"message": "Invalid or expired token",
"type": "authentication_error"
}
}{
"error": {
"code": "insufficient_quota",
"message": "Insufficient quota. Please top up your account.",
"type": "insufficient_quota"
}
}{
"error": {
"code": "model_access_denied",
"message": "Token does not have access to model: doubao-seedream-5.5",
"type": "invalid_request_error"
}
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Too many requests, please try again later",
"type": "rate_limit_error"
}
}{
"error": {
"code": "internal_error",
"message": "Internal server error",
"type": "api_error"
}
}授权
##所有接口均需要使用Bearer Token进行认证##
获取 API Key :
访问 API Key 管理页面 获取您的 API Key
使用时在请求头中添加:
Authorization: Bearer YOUR_API_KEY
请求体
图像生成模型名称
doubao-seedream-5.5 "doubao-seedream-5.5"
提示词,描述想要生成的图像,或描述如何编辑已输入的图像
语言支持: 中英文之外,Seedream 5.5 还支持俄语、阿拉伯语、菲律宾语、泰语、土耳其语、韩语、马来语、西班牙语、葡萄牙语、印尼语、法语、德语、越南语、日语。
长度限制: 最多 4000 tokens(中文约 2600 字、英文约 5000 词),超出返回 400 且不计费。
效果建议: 建议中文不超过 300 字、英文不超过 600 词。过长虽在限额内,但信息容易分散,模型可能忽略细节导致画面元素缺失。
"一片宁静的湖水倒映着夕阳的美景"
生成图像的尺寸,支持两种格式:
方式1 - 比例格式:
auto、1:1、2:3、3:2、3:4、4:3、4:5、5:4、9:16、16:9、21:9、9:21- 配合
quality参数使用,系统自动生成对应比例和分辨率的图片,无需手动指定像素
方式2 - 像素格式:
- 宽度x高度,如:
1024x1024、2048x2048等在范围内的值 - 总像素取值范围:
[921600, 4624220] - 宽高比取值范围:
[1/16, 16] - 宽高均需大于
14px
不传 size 时默认 auto。模型根据提示词确定画面比例,输出分辨率由 quality 确定。
"16:9"
输出分辨率,与 size 的比例格式配合使用,默认 1K。
| 比例 | 1K | 1.5K | 2K |
|---|---|---|---|
1:1 | 1024×1024 | 1536×1536 | 2048×2048 |
2:3 | 832×1248 | 1248×1872 | 1664×2496 |
3:2 | 1248×832 | 1872×1248 | 2496×1664 |
3:4 | 864×1152 | 1344×1792 | 1776×2368 |
4:3 | 1152×864 | 1792×1344 | 2368×1776 |
4:5 | 896×1120 | 1344×1680 | 1792×2240 |
5:4 | 1120×896 | 1680×1344 | 2240×1792 |
9:16 | 800×1424 | 1152×2048 | 1584×2816 |
16:9 | 1424×800 | 2048×1152 | 2816×1584 |
21:9 | 1568×672 | 2352×1008 | 3136×1344 |
9:21 | 672×1568 | 1008×2352 | 1344×3136 |
1K, 1.5K, 2K "2K"
提示词优化模式,仅支持 standard(默认)。
传入 fast 将返回 400,不计费。
standard "standard"
参考图像URL列表,用于图生图与图像编辑功能
注意:
- 参考图另行收费,与生成图片分开计费
- 单次请求支持输入图像数量:
10张 - 图像大小:不超过
30MB - 支持的图像格式:
.jpeg、.jpg、.png、.webp、.bmp、.tiff、.gif、.heic、.heif - 宽高比(宽/高)范围:
[1/16, 16] - 宽高长度(px)> 14
- 总像素范围:
[196, 6000×6000] - 图像URL需要服务器能直接查看,或者图像URL在访问时会直接进行下载(一般这种URL是以图像的扩展名作为结尾,例如
.png、.jpg)
10[
"https://example.com/image1.png",
"https://example.com/image2.png"
]
输出图片格式
可选值:
png: PNG 格式(默认)jpeg: JPEG 格式
注意: 传 background=transparent 时输出固定为 png:不传 output_format 会自动按 png 输出,指定 jpeg 会被拒绝。
png, jpeg "png"
是否在生成图像中添加水印
false
输出图片的背景类型,默认 auto。
可选值:
auto:由模型根据提示词和参考图确定背景类型。任务详情的result_data[].background返回实际背景类型,值为transparent或opaquetransparent:生成带透明通道的 PNG 图片,支持文生图和图生图opaque:生成不透明背景图片
使用 transparent 时:
- 可不传参考图;如提供,最多
10张,输入图片无需包含透明通道 - 输出格式固定为
png;不传output_format时自动使用png,传入jpeg将返回错误
auto, transparent, opaque "auto"
任务完成后的HTTPS回调地址
回调时机:
- 任务完成(completed)、失败(failed)或取消(cancelled)时触发
- 在计费确认完成后发送
安全限制:
- 仅支持HTTPS协议
- 禁止回调到内网IP地址(127.0.0.1、10.x.x.x、172.16-31.x.x、192.168.x.x等)
- URL长度不超过
2048字符
回调机制:
- 超时时间:
10秒 - 失败后最多重试
3次(会分别在失败的1秒/2秒/4秒后进行重试) - 回调响应体格式与任务查询接口返回的格式一致
- 回调地址若返回2xx状态码视为成功,其他状态码会触发重试
"https://your-domain.com/webhooks/image-task-completed"
响应
图像生成任务创建成功
任务创建时间戳
1757165031
任务ID
"task-unified-1793612886-seedream55"
实际使用的模型名称
"doubao-seedream-5.5"
任务的具体类型
image.generation.task 任务进度百分比 (0-100)
0 <= x <= 1000
任务状态
pending, processing, completed, failed "pending"
异步任务信息
Show child attributes
Show child attributes
任务的输出类型
text, image, audio, video "image"
使用量和计费信息
Show child attributes
Show child attributes