1. Image (Doubao native)
Ark-Docs
  • Video (Doubao native)
    • Submit a video generation task (Doubao native)
      POST
    • Retrieve a video generation task (Doubao native)
      GET
  • Video (OpenAI compatible)
    • Submit a video generation task (OpenAI compatible)
      POST
    • Retrieve a video generation task
      GET
    • Submit a video generation task (OpenAI Video alias)
      POST
    • Retrieve a video generation task (OpenAI Video alias)
      GET
  • Video content
    • Download the generated video file
      GET
  • Image (Doubao native)
    • Generate an image (Doubao native)
      POST
  • Image (OpenAI compatible)
    • Generate an image (OpenAI compatible)
      POST
    • Edit an image (OpenAI compatible)
      POST
  • Asset library (Doubao native)
    • Manage the asset library (Doubao native)
      POST
  • 数据模型
    • VideoGenerationRequest
    • VideoFormDataRequest
    • VideoMetadata
    • DoubaoNativeVideoRequest
    • DoubaoNativeContentItem
    • VideoTaskResponse
    • DoubaoNativeVideoResponse
    • VideoTaskError
    • DoubaoImageRequest
    • ImageEditFormDataRequest
    • DoubaoImageResponse
    • ErrorResponse
    • DoubaoAssetRequest
    • DoubaoAssetResponse
  1. Image (Doubao native)

Generate an image (Doubao native)

POST
/doubao/api/v3/images/generations
Generate images synchronously in Volcengine Ark format. There is no task to
poll; the complete result is returned in one response.
Point your client's base URL at https://<gateway-host>/doubao/api/v3 to
keep using Ark field names unchanged.
Text to image, image to image, or multi-image fusion?
The image field decides, and nothing else does:
Scenarioimage
Text to imageomit it
Single-image edita string URL or data: URI
Multi-image fusionan array of strings
Size
Two forms, pick one:
1.
A preset keyword: 1K, 1.5K, or 2K.
2.
Explicit pixels as widthxheight, for example 2048x2048. Width and
height must stay within 1024x1024 to 4096x4096 pixels with an aspect
ratio between 1:16 and 16:1.
Gateway behaviour that differs from Ark
FieldArkThis gateway
streamSSE streamingNot supported. Send false or omit it.
response_formaturl or b64_jsonurl only. Base64 output is not served on this route.
Other native fields-Forwarded unchanged, so new Ark parameters work without a gateway upgrade.
Use POST /v1/images/generations if you need b64_json.

请求参数

Authorization
JWT Bearer
在 Header 添加参数
Authorization
示例:
Authorization: ********************
or
Body 参数application/json必填

示例
{
    "model": "doubao-seedream-5-0-pro-260628",
    "prompt": "A snow-covered mountain lake at night, mirroring the Milky Way, photorealistic",
    "size": "2K"
}

请求示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
cURL
curl --location '/doubao/api/v3/images/generations' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
    "model": "doubao-seedream-5-0-pro-260628",
    "prompt": "A snow-covered mountain lake at night, mirroring the Milky Way, photorealistic",
    "size": "2K"
}'

返回响应

🟢200
application/json
Images generated.
Bodyapplication/json

示例
{
    "data": [
        {
            "url": "https://ark-content-generation-v2-cn-beijing.tos-cn-beijing.volces.com/seedream/xxx.jpeg",
            "size": "2048x2048",
            "output_format": "jpeg"
        }
    ],
    "created": 1757469067,
    "usage": {
        "generated_images": 1,
        "output_tokens": 15908,
        "total_tokens": 15908
    }
}
🟠400
🟠401Unauthorized
🟠429RateLimited
修改于 2026-10-28 04:38:45
上一页
Download the generated video file
下一页
Generate an image (OpenAI compatible)
Built with