Unode
User GuideAPI ReferenceHelp & SupportBusiness Cooperation

Seedream Image Generation

Introduction

Given a text prompt and/or reference image(s), Seedream models will generate new images. Seedream is Bytedance's high-quality image generation model family, supporting text-to-image, image-to-image, and sequential (multi-image set) generation via the VolcEngine channel.

Supported Models

Currently supported models include:

ModelDescription
doubao-seedream-4-5-251128Seedream 4.5 image generation model supporting text-to-image and image-to-image generation
doubao-seedream-5-0-260128Seedream 5.0 image generation model with enhanced quality, web search tool support, and PNG output

Request Examples

curl https://www.unodetech.xyz/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  -d '{
    "model": "doubao-seedream-5-0-260128",
    "prompt": "A cute little sea otter",
    "size": "2048x2048",
    "response_format": "url"
  }'

Response Example:

{
  "model": "doubao-seedream-5-0-260128",
  "created": 1780599167,
  "data": [
    {
      "url": "https://example.com/generated-image.jpeg",
      "size": "2048x2048"
    }
  ],
  "usage": {
    "generated_images": 1,
    "output_tokens": 16384,
    "total_tokens": 16384
  }
}
curl https://www.unodetech.xyz/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  -d '{
    "model": "doubao-seedream-5-0-260128",
    "prompt": "A cute little sea otter wearing a beret",
    "image": "data:image/png;base64,<BASE64_DATA>",
    "size": "2048x2048"
  }'
curl https://www.unodetech.xyz/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  -d '{
    "model": "doubao-seedream-5-0-260128",
    "prompt": "A series of illustrations showing a fox exploring different seasons",
    "extra_fields": {
      "sequential_image_generation": "auto",
      "sequential_image_generation_options": {
        "max_images": 4
      }
    }
  }'

Response Example:

{
  "model": "doubao-seedream-5-0-260128",
  "created": 1780599167,
  "data": [
    { "url": "https://example.com/image1.jpeg", "size": "2048x2048" },
    { "url": "https://example.com/image2.jpeg", "size": "2048x2048" },
    { "url": "https://example.com/image3.jpeg", "size": "2048x2048" },
    { "url": "https://example.com/image4.jpeg", "size": "2048x2048" }
  ],
  "usage": {
    "generated_images": 4,
    "output_tokens": 65536,
    "total_tokens": 65536
  }
}
curl https://www.unodetech.xyz/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  -d '{
    "model": "doubao-seedream-5-0-260128",
    "prompt": "Create an elegant gift set containing these items",
    "image": [
      "data:image/png;base64,<BASE64_IMAGE_1>",
      "data:image/png;base64,<BASE64_IMAGE_2>",
      "data:image/png;base64,<BASE64_IMAGE_3>"
    ]
  }'

Request

Endpoint

Create Image

POST /v1/images/generations

Create images based on text prompts and/or reference images.

Authentication Method

Include the following in the request header for API key authentication:

Authorization: Bearer $API_KEY

Where $API_KEY is your API key.

Request Body Parameters

Size Values

ValueDescriptionModels
2K~2048px (model chooses exact dimensions based on prompt)5.0, 4.5
3K~3072px5.0, 4.5
4K~4096px5.0, 4.5
<width>x<height>Explicit pixel dimensions, e.g. 2048x2048. Must satisfy both minimum total pixels and aspect ratio constraints (see API docs for per-model limits).All

Seedream extra_fields Reference

The following parameters are supported in the extra_fields object for Seedream image generation models via the VolcEngine channel.

extra_fields Parameters

Response

Successful Response

The endpoint returns a response with the following top-level fields:

usage Fields

Image Object

Each object in the data array contains:

Example image object:

{
  "model": "doubao-seedream-5-0-260128",
  "created": 1780599167,
  "data": [
    {
      "url": "https://example.com/generated-image.jpeg",
      "size": "2048x2048"
    }
  ],
  "usage": {
    "generated_images": 1,
    "output_tokens": 16384,
    "total_tokens": 16384
  }
}

Best Practices

Prompt Writing Tips

  1. Use clear and specific descriptions
  2. Specify important visual details
  3. Describe the expected artistic style and atmosphere
  4. Pay attention to composition and perspective instructions
  5. Seedream supports both Chinese and English prompts

Parameter Selection Tips

  1. Size Selection

    • 2K / 3K / 4K: Preset tiers where the model selects exact dimensions based on the prompt
    • <width>x<height>: Use explicit dimensions when you need a specific aspect ratio or resolution
  2. Image Set Generation

    • Set extra_fields.sequential_image_generation to "auto" to generate a coherent set of related images from a single prompt
    • Control the set size with extra_fields.sequential_image_generation_options.max_images (up to 15)
    • When using reference images, the total of input images + generated images must not exceed 15
  3. Reference Images

    • Pass reference images as base64 data URLs (data:image/png;base64,...) in the image field
    • Use up to 14 reference images for multi-image composition

Common Questions

  1. Image generation failed

    • Check if the prompt complies with content policies
    • Verify API key permissions
    • Confirm reference image format (must be base64 data URL, not file upload)
  2. Results do not match expectations

    • Optimize prompt descriptions with more specific visual detail
    • Adjust the size parameter
    • Try enabling prompt optimization via extra_fields.optimize_prompt_options
  3. Sequential generation returning only one image

    • Ensure extra_fields.sequential_image_generation is set to "auto" (default is "disabled")

Last updated on