Seedream
ByteDance Seedream image models for text-to-image and image-to-image, including model-specific size and pixel limits.
Seedream image models are called through the OpenAI-compatible image endpoint, supporting text-to-image and image-to-image.
Endpoint
| Item | Value |
|---|---|
| Endpoint | https://api.tokenhub.belivestudios.com/v1/images/generations |
| Auth | Header Authorization: Bearer sk-your-key |
| Model | doubao-seedream-5-0-lite-260128 (see console model list) |
Text to Image
curl https://api.tokenhub.belivestudios.com/v1/images/generations \
-H "Authorization: Bearer sk-your-key" \
-H "Content-Type: application/json" \
-d '{
"model": "doubao-seedream-5-0-lite-260128",
"prompt": "An orange cat napping on a keyboard, realistic photography",
"size": "2K"
}'from openai import OpenAI
client = OpenAI(
# The OpenAI SDK appends /images/generations, so /v1 must be retained.
base_url="https://api.tokenhub.belivestudios.com/v1",
api_key="sk-your-key",
)
result = client.images.generate(
model="doubao-seedream-5-0-lite-260128",
prompt="An orange cat napping on a keyboard, realistic photography",
size="2K", # 2K is supported by all four models below
)
print(result.data[0].url)Why did the Python example return 404?
The OpenAI client's base_url must be https://api.tokenhub.belivestudios.com/v1. If it is set to https://api.tokenhub.belivestudios.com, the SDK requests the nonexistent /images/generations path instead of /v1/images/generations.
Size rules
size can be a model-supported resolution preset or an explicit WIDTHxHEIGHT value. The four models have different rules and cannot be described by a single 1K / 2K / 4K list.
| Model ID | Accepted presets | Total-pixel range for explicit dimensions | Default |
|---|---|---|---|
doubao-seedream-4-0-250828 | 1K, 2K, 4K | 921,600–16,777,216 | 2048x2048 |
doubao-seedream-4-5-251128 | 2K, 4K | 3,686,400–16,777,216 | 2048x2048 |
doubao-seedream-5-0-lite-260128 | 2K, 3K, 4K | 3,686,400–16,777,216 | 2048x2048 |
doubao-seedream-5-0-pro-260628 | 1K, 1.5K, 2K | 921,600–4,624,220 | 2K |
An explicit WIDTHxHEIGHT value must also have an aspect ratio within [1/16, 16]. The pixel limit applies to width multiplied by height, not to either dimension independently.
Safe values across all four models
2K is the only preset supported by all four models. For explicit dimensions, use a total area of 3,686,400–4,624,220 pixels and an aspect ratio within [1/16, 16]; for example, 1920x1920.
Example:
{
"size": "1920x1920"
}Write resolution presets with an uppercase K. These limits are based on the current Volcengine image-generation API rules and BeLive Studio API validation messages; check the latest API response after a model upgrade.
Image to Image
Use image for a single reference-image URL/Base64 value, or pass an array of strings for multiple references. Reference-image counts and sequential-generation capabilities vary by model.