# Doubao Seedream 5.5 & 5.0 API Setup Guide

> Call ByteDance Doubao Seedream 5.5 (text-to-image, transparent PNG, layer decomposition), Seedream 5.0 Pro/Lite, 4.5 and 4.0 via WanAPIs async image tasks. Transparent ¥1 = $1 quota billing with cURL examples.

Web page: https://wanapi.ai/docs/seedream

ByteDance's Doubao Seedream image family is served on WanAPIs through the async image task endpoint POST /v1/images/tasks. It covers seedream-5-5 (text-to-image, reference editing, transparent PNG and single-model layer decomposition) as well as seedream-5-0-pro, seedream-5-0-lite, seedream-4-5 and seedream-4-0. Quota is denominated at ¥1 = $1 (500000 quota = ¥1); live rates and comparisons are published on /pricing and /compare/seedream-5-5-api-pricing.

## At a glance

| Item | Value |
| --- | --- |
| Callable model IDs | seedream-5-5 · seedream-5-0-pro · seedream-5-0-lite · seedream-4-5 · seedream-4-0 |
| Submit endpoint | POST https://api.wanapis.com/v1/images/tasks (async-only; do not call /v1/images/generations) |
| Poll endpoint | GET https://api.wanapis.com/v1/images/tasks/{task_id} (same API key) |
| Billing model | ¥1 = $1 quota (500000 quota = ¥1); Seedream 5.5 reserves an estimate and settles actual usage on completion |
| Pricing comparison | https://wanapi.ai/compare/seedream-5-5-api-pricing |

## Setup steps

### 1. 1. Pick the exact WanAPIs model ID

Use seedream-5-5 for generation (1K / 1.5K / 2K), transparent PNG output, and layer decomposition. For earlier generations, use seedream-5-0-pro (1K and 2K resolution tiers), seedream-5-0-lite, seedream-4-5, or seedream-4-0. Always put the model ID in the JSON request body's model field.

### 2. 2. Seedream 5.5 generation & transparent PNG

Normal generation requires prompt, accepts 0–10 reference URLs in image_urls, and fixes n to 1. size accepts 1K / 1.5K / 2K (default 2K), aspect ratios such as 1:1, or exact pixel dimensions (total area 921600–4624220, aspect ratio 1/16–16, never combined with resolution). For transparent PNG output, set output_format to png and background to transparent.

**Seedream 5.5 · transparent PNG**

```
curl https://api.wanapis.com/v1/images/tasks \
  -H "Authorization: Bearer $WANAPIS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedream-5-5",
    "prompt": "a single white ceramic mug, isolated on a transparent background",
    "size": "1K",
    "n": 1,
    "output_format": "png",
    "background": "transparent"
  }'
```

### 3. 3. Seedream 5.5 layer decomposition

Set layer_decomposition to true to split a source image into a base image plus transparent PNG layers. Three strict rules apply: (1) image_urls must contain exactly one image; (2) omit background completely, including auto; (3) size only accepts auto / 1K / 1.5K / 2K (ratios and exact pixel dimensions are rejected). Use layer_decomposition_options.max_images (2–100 including base, default 30) and optional text_recognition for OCR.

**Seedream 5.5 · layer decomposition**

```
curl https://api.wanapis.com/v1/images/tasks \
  -H "Authorization: Bearer $WANAPIS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedream-5-5",
    "image_urls": ["https://example.com/source.png"],
    "size": "1K",
    "n": 1,
    "layer_decomposition": true,
    "layer_decomposition_options": {"max_images": 2, "text_recognition": true}
  }'
```

### 4. 4. Poll for results and read layer metadata

Poll GET /v1/images/tasks/{task_id} with data.task_id using the same API key. On SUCCESS, image URLs are returned in data.data.data.result.images[].url[], where the first image is the base. If layers metadata is returned, scale/position each transparent PNG using bounding_box and sort by z_index; layers may be absent, so never require it to fetch images. Layer decomposition can take around 13 minutes — keep polling the original task_id without resubmitting, and download temporary links promptly.

**Poll task status**

```
curl https://api.wanapis.com/v1/images/tasks/task_xxx \
  -H "Authorization: Bearer $WANAPIS_API_KEY"
```

### 5. 5. Calling Seedream 5.0 Pro / Lite / 4.5 / 4.0

Earlier Seedream models use the same POST /v1/images/tasks endpoint with model, prompt, size (aspect ratio such as 1:1 or 16:9; note seedream-5-0-lite only honours aspect ratios and falls back to 2048x2048 on pixel dimensions) and optional image_urls. Only seedream-5-0-pro has 1K / 2K resolution tiers; the others use a single tier.

**Seedream 5.0 Pro · 2K text-to-image**

```
curl https://api.wanapis.com/v1/images/tasks \
  -H "Authorization: Bearer $WANAPIS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedream-5-0-pro",
    "prompt": "editorial studio photo of minimalist ceramic tableware, warm daylight",
    "size": "16:9",
    "resolution": "2K",
    "n": 1
  }'
```

## Known limitations

- All Seedream models are async-only. Calling synchronous /v1/images/generations returns 400 and directs you to /v1/images/tasks.
- Seedream 5.5's displayed base rate corresponds to one 1K/1.5K output; 2K, reference inputs and layer outputs settle against actual usage, refunding excess or charging any shortfall.
- PSD and ZIP exports are not promised for layer decomposition, and OCR is not guaranteed to extract text.

## FAQ

### How is Seedream 5.5 billed on WanAPIs?

WanAPIs bills in ¥1 = $1 quota units (500000 quota = ¥1). Seedream 5.5 reserves an estimated upper amount from your selected parameters and settles actual usage upon completion. Live rates are shown on /pricing and /model/seedream-5-5.

### Why did my Seedream 5.5 layer decomposition request return 400?

The most common causes are including the background field (omit it completely, even auto), passing more or fewer than 1 URL in image_urls, or passing pixel/ratio dimensions instead of auto / 1K / 1.5K / 2K.

### What exact model IDs should I pass for Doubao Seedream?

Pass seedream-5-5, seedream-5-0-pro, seedream-5-0-lite, seedream-4-5, or seedream-4-0. You can query the full live list anytime at GET https://api.wanapis.com/api/pricing.

---

Generated by the WanAPIs website and kept in sync with the web page. All guides in Markdown: https://wanapi.ai/docs/index.md
