All models
ByteDance
Image
Available
Seedream 5.5 图层分离
计费 = 输入图费用 + 实际输出张数(底图 + 每个分离图层)× 所选 `size` 档位单价(`auto` 按 2K 档计费)。可用 `max_images` 限制最多输出张数。当前价格见 kie.ai/pricing。
Text to Image
From 60 credits (≈ ₹60.00) per request.
Parameters
| Parameter | Type | Description |
|---|---|---|
image_urlRequired |
string | 必填。待分离图片的 URL。 - 只能传 1 张,须为公网可访问地址 - 支持格式:JPEG、PNG、WEBP - 不超过 10 MB format: uri |
prompt |
string | 可选。描述要分离的元素,0–2000 字符。 - 传入时,模型按描述分离指定元素 - 留空时,模型自动识别图片中的主要元素 - 可用 `x1 y1 x2 y2` 标注元素位置,坐标按 0–1000 归一化 max length 2000 |
size |
string | 输出图片的清晰度档位。默认 `auto`。 - `auto`:保持原图尺寸(小于 1K 提升到 1K,大于 2K 压缩到 2K),按 2K 档计费 - `1K` / `1.5K` / `2K`:固定清晰度档位 one of: "auto", "1K", "1.5K", "2K" · default "auto" |
output_format |
string | 底图的输出格式。默认 `png`。仅影响底图,分离出的图层固定为 PNG(透明背景)。 one of: "png", "jpeg" · default "png" |
max_images |
integer | 最多输出的图片张数(含 1 张底图)。范围 2–100,默认 30。按实际返回的张数计费。 min 2 · max 100 · default 30 |
text_recognition |
boolean | 是否识别图层中的文字。默认 `false`。 default false |
nsfw_checker |
boolean | 默认 false。为 false 时不额外进行内容过滤,结果由模型直接返回。 |
What you get back
Files arrive in output.files[] as private links that expire, with their type and size.
Use it from your code
# 1. Create the task
curl https://nexus.promptscenes.in/api/v1/tasks \
-H "Authorization: Bearer $NEXUS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"model": "seedream-5.5-layer-decomposition",
"input": {
"image_url": "https://example.com/input.png",
"size": "auto",
"output_format": "png",
"max_images": 30,
"text_recognition": false
},
"callback_url": "https://your-app.com/webhooks/nexus"
}'
# 2. Poll for the result
curl https://nexus.promptscenes.in/api/v1/tasks/TASK_ID \
-H "Authorization: Bearer $NEXUS_API_KEY"
import os, time, uuid, requests
API = "https://nexus.promptscenes.in/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['NEXUS_API_KEY']}"}
task = requests.post(
f"{API}/tasks",
headers={**HEADERS, "Idempotency-Key": str(uuid.uuid4())},
json={
"model": "seedream-5.5-layer-decomposition",
"input": {
"image_url": "https://example.com/input.png",
"size": "auto",
"output_format": "png",
"max_images": 30,
"text_recognition": False,
},
"callback_url": "https://your-app.com/webhooks/nexus",
},
).json()
while task["status"] not in ("succeeded", "failed", "cancelled"):
time.sleep(3)
task = requests.get(f"{API}/tasks/{task['id']}", headers=HEADERS).json()
print(task["status"], task.get("output"))
const API = "https://nexus.promptscenes.in/api/v1";
const headers = {
Authorization: `Bearer ${process.env.NEXUS_API_KEY}`,
"Content-Type": "application/json",
};
let task = await fetch(`${API}/tasks`, {
method: "POST",
headers: { ...headers, "Idempotency-Key": crypto.randomUUID() },
body: JSON.stringify({
"model": "seedream-5.5-layer-decomposition",
"input": {
"image_url": "https://example.com/input.png",
"size": "auto",
"output_format": "png",
"max_images": 30,
"text_recognition": false
},
"callback_url": "https://your-app.com/webhooks/nexus"
}),
}).then((r) => r.json());
while (!["succeeded", "failed", "cancelled"].includes(task.status)) {
await new Promise((r) => setTimeout(r, 3000));
task = await fetch(`${API}/tasks/${task.id}`, { headers }).then((r) => r.json());
}
console.log(task.status, task.output);
Request
{
"model": "seedream-5.5-layer-decomposition",
"input": {
"image_url": "https://example.com/input.png",
"size": "auto",
"output_format": "png",
"max_images": 30,
"text_recognition": false
}
}
Response
{
"id": "6f1c…",
"object": "task",
"model": "seedream-5.5-layer-decomposition",
"status": "succeeded",
"output": {
"files": [
{
"url": "https://…signed…",
"mime": "…",
"size": 0
}
]
},
"estimated_cost": "…",
"charged": "…"
}