> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anyfast.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Seedream 4.0 i2i

> ByteDance Seedream 4.0 image-to-image model. Generate images from reference images with text prompts.

Seedream 4.0 i2i is an image-to-image generation model from ByteDance's Seedream series, available through Anyfast API.

## Key capabilities

* **Image-to-Image** — Generate images with reference images and text prompts
* **Sequential Generation** — Batch generate multiple images in one request
* **Custom Size** — Flexible output sizes
* **Watermark Control** — Optional watermark and logo configuration

## Quick example

<CodeGroup>
  ```bash cURL theme={null}
  curl https://www.anyfast.ai/v1/images/generations \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "model": "doubao-seedream-4-0-250828",
      "prompt": "A girl and a cow doll happily riding a roller coaster, morning, noon, and night",
      "image": ["https://example.com/ref1.png", "https://example.com/ref2.png"],
      "sequential_image_generation": "auto",
      "sequential_image_generation_options": {
        "max_images": 3
      },
      "size": "2K",
      "watermark": false
    }'
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      "https://www.anyfast.ai/v1/images/generations",
      headers={
          "Authorization": "Bearer YOUR_API_KEY",
          "Content-Type": "application/json"
      },
      json={
          "model": "doubao-seedream-4-0-250828",
          "prompt": "A girl and a cow doll happily riding a roller coaster, morning, noon, and night",
          "image": ["https://example.com/ref1.png", "https://example.com/ref2.png"],
          "sequential_image_generation": "auto",
          "sequential_image_generation_options": {
              "max_images": 3
          },
          "size": "2K",
          "watermark": False
      }
  )

  task = response.json()
  print(f"Task ID: {task['id']}")
  ```
</CodeGroup>

## Parameters

| Parameter                             | Type    | Required | Description                                                |
| ------------------------------------- | ------- | -------- | ---------------------------------------------------------- |
| `model`                               | string  | Yes      | Must be `doubao-seedream-4-0-250828`                       |
| `prompt`                              | string  | Yes      | Text prompt for image generation                           |
| `image`                               | array   | Yes      | Array of reference image URLs                              |
| `sequential_image_generation`         | string  | No       | Set to `auto` to enable batch generation                   |
| `sequential_image_generation_options` | object  | No       | Options: `max_images` (int)                                |
| `size`                                | string  | No       | Output image size, e.g. `1024x1024`, `2K`                  |
| `watermark`                           | boolean | No       | Default: `false`                                           |
| `seed`                                | integer | No       | Random seed for reproducibility                            |
| `logo_info`                           | object  | No       | Logo config: `add_logo`, `position`, `language`, `opacity` |

<Card title="API Reference" icon="code" href="/api-reference/model-api/bytedance/doubao-seedream-4-0-250828-i2i">
  View the interactive API playground for Seedream 4.0 i2i.
</Card>

<script src="/feedback.js" />
