Skip to content

Seedream / Wan asynchronous image model ​

seedream-5.0, seedream-4.5 and wan2.7-image-pro use the MoonNexAI asynchronous image-task API for text-to-image, image-to-image, product images, character references and visual sketches. Save the task ID from creation, then query status and result URLs.

Model List ​

ModelsUsual ModeRecommended entranceQuery Entry
seedream-5.0text-to-image, image-to-image/v1/images/generations/async/v1/images/tasks/{task_id}
seedream-4.5text-to-image, image-to-image/v1/images/generations/async/v1/images/tasks/{task_id}
wan2.7-image-protext-to-image, image-to-image/v1/images/generations/async/v1/images/tasks/{task_id}

The actual size, single generation and price are based on MoonNexAI console, price page and GET /v1/models.

text-to-image ​

bash
curl https://moonnexai.com/v1/images/generations/async \
  -H "Authorization: Bearer <MOONNEXAI_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedream-5.0",
    "input": {
      "messages": [
        {
          "role": "user",
          "content": [
            {
              "text": "A premium ceramic coffee cup on a clean studio table, soft light, product photography."
            }
          ]
        }
      ]
    },
    "parameters": {
      "size": "2048x2048",
      "n": 1,
      "watermark": false
    }
  }'

response will contain task ID after successful creation:

json
{
  "id": "task_xxx",
  "object": "image.generation",
  "created": 1782135793,
  "status": "queued",
  "model": "seedream-5.0"
}

image-to-image ​

image-to-image places the picture URL and text in the same user message. The picture can be either a URL of the client's own public network or a URL of MoonNexAI hosting; the URL needs access during task execution.

bash
curl https://moonnexai.com/v1/images/generations/async \
  -H "Authorization: Bearer <MOONNEXAI_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "wan2.7-image-pro",
    "input": {
      "messages": [
        {
          "role": "user",
          "content": [
            {
              "image": "https://example.com/product.png"
            },
            {
              "text": "Keep the product shape, change the background to a bright kitchen counter, realistic commercial photo."
            }
          ]
        }
      ]
    },
    "parameters": {
      "size": "2048x2048",
      "n": 1,
      "watermark": false
    }
  }'

It is recommended that a picture be entered at least 300x300 and that the address that requires login, short-term signature or a stop-take be avoided.

Query task ​

bash
curl https://moonnexai.com/v1/images/tasks/task_xxx \
  -H "Authorization: Bearer <MOONNEXAI_API_KEY>"

Processing:

json
{
  "id": "task_xxx",
  "object": "image.generation",
  "status": "running",
  "progress": 42,
  "model": "seedream-5.0"
}

Success:

json
{
  "id": "task_xxx",
  "object": "image.generation",
  "status": "succeeded",
  "progress": 100,
  "model": "seedream-5.0",
  "data": [
    {
      "url": "https://example.com/result.png"
    }
  ]
}

The client should first judge status. Only succeeded reads data[].url; and when error or fail_reason is read, do not judge task success based on URL field.

Common parameters ​

fieldTypeAnnotations
modelstringseedream-5.0, seedream-4.5 or wan2.7-image-pro.
input.messagesarrayMessage array. Usually a message is sent by role=user.
content[].textstringPicture generation or change requirements.
content[].imagestringOptional. image-to-image enters a picture URL.
parameters.sizestringOutput size. Common writings are 2048x2048; compatible 2048*2048.
parameters.nintegerGenerates the quantity.
parameters.watermarkbooleanAdd watermarks.
parameters.thinking_modebooleanModels support the way you think. You can keep your mind on when you do not need it.

Size recommendations ​

The usual equation can start with 2048x2048; vertical and long maps can be selected by the support size shown on the model list or price page. If size is wrong, switch to the recommended size shown on the model page and try again.

Results and billing ​

These three models are billed per task. Save id / task_id, model, request parameters and query results after submission. Current prices are configured in the MoonNexAI console.

Relevant Pages ​