Skip to main content
POST
cURL
Use POST /v1/images/generations with async: true to submit a Seedream image task without holding the HTTP connection open. This asynchronous workflow applies to these model IDs: For account availability, see the Models page or query /v1/models. For provider parameter details, see the BytePlus image generation API and Seedream 4.0-5.0 tutorial.

Submit the task

Send model, prompt, and async: true. The example also requests a 2K URL response with watermark: false. Size support varies by model ID, so use a size supported by the selected model. The create response returns data.task_id, data.status, and an empty data.data array while the task is pending. Store data.task_id; do not use the top-level response code as the task identifier.

Poll the task

Pass the stored task ID to Retrieve a Seedream image task. Continue polling while data.status is pending. Stop when it becomes success or failure.

Read the image URL

When a task succeeds, read data.data[0].url from parsed JSON. In shell, jq -r '.data.data[0].url' preserves special characters in the complete URL.Download or transfer the image promptly. The URL is temporary; this documentation does not assume a fixed lifetime.

Authorizations

Authorization
string
header
required

Bearer token authentication. Use your CometAPI key.

Body

application/json
model
string
required

Seedream model ID. This async workflow is documented for doubao-seedream-4-0-250828, doubao-seedream-4-5-251128, doubao-seedream-5-0-260128, and seedream-5-0-pro-260628. Query /v1/models or open the Models page for account availability.

Example:

"doubao-seedream-5-0-260128"

prompt
string
required

Text prompt describing the image to generate.

Example:

"A clean studio photograph of a small red ceramic teapot on a pale blue table, soft window light, no text."

async
boolean
required

Asynchronous task mode. Set this to true, store data.task_id, and poll the task endpoint.

size
string

Requested output size. Use a value supported by the selected model.

Example:

"2K"

response_format
string

Response workflow for this async request. The example uses url and retrieves the URL from the completed task.

Example:

"url"

watermark
boolean

Whether to request a visible watermark on the generated image.

Example:

false

Response

200 - application/json

Seedream asynchronous task submission response.

code
string
required

Request status code. A successful submission returns success.

Example:

"success"

message
string
required

Status message. A successful submission can return an empty string.

data
object
required
Last modified on July 31, 2026