> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sinancode.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Seedream Image Generation

> Generate images using Volcano Engine's Seedream model, supporting single-image and batch modes, with optional versions 4.0, 4.5, or 5.0-lite (synchronous).
- max_images = 1: Generate a single image.
- max_images > 1: Generate a batch of images, up to N images.
- max_images not set: Automatic batch mode, up to 15 images.

Generate images using [ByteDance](https://seed.bytedance.com)'s Seedream model, supporting both single image and multi-image modes.

**Key Features:**

* **Multi-Version Support** - Supports 5.0-lite (default), 4.5, and 4.0
* **Flexible Output Modes** - Single image (`max_images=1`) or multi-image (`max_images=2-15`)
* **Text-to-Image & Image-to-Image** - Generate from text or reference images (up to 14)
* **HD Output** - 5.0-lite supports 2K/3K, 4.5/4.0 supports 2K/4K, or specify exact resolution


## OpenAPI

````yaml /en/openapi.yaml POST /generate/vol/seedream
openapi: 3.0.0
info:
  contact:
    email: support@sinancode.com
    name: API Support
    url: https://sinancode.com/support
  description: AI Model Task Scheduling Platform API
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
  termsOfService: https://sinancode.com/terms-of-service
  title: TikTomato API
  version: '1.0'
servers:
  - url: https://api.sinancode.com/v1
    description: Production server
security: []
paths:
  /generate/vol/seedream:
    post:
      tags:
        - public
      summary: Seedream Image Generation
      description: >-
        Generate images using Volcano Engine's Seedream model, supporting
        single-image and batch modes, with optional versions 4.0, 4.5, or
        5.0-lite (synchronous).

        - max_images = 1: Generate a single image.

        - max_images > 1: Generate a batch of images, up to N images.

        - max_images not set: Automatic batch mode, up to 15 images.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/vol.CreateSeedreamTaskRequest'
        description: Task parameters
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/dto.CreateTaskResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
      security:
        - AccessToken: []
components:
  schemas:
    vol.CreateSeedreamTaskRequest:
      properties:
        images:
          description: >-
            Input images (optional, supports multiple reference images, up to
            14)

            Example: ["https://example.com/1.jpg", "https://example.com/2.jpg"]
          example:
            - https://media.sinancode.com/uploads/1765851887405-rfpmtj1u.png
          items:
            type: string
          type: array
        max_images:
          default: 1
          description: >-
            Maximum number of images (optional, default 1)

            - Set to 1: Generate a single image (disables group image function)

            - Set to 2-15: Generate a group of images, up to N images (input
            image count + generated count ≤ 15)
          example: 4
          maximum: 15
          minimum: 1
          type: integer
        prompt:
          description: >-
            Prompt (required, recommended not to exceed 300 Chinese characters
            or 600 English words)
          example: 把这张照片变成黏土风格。放在一张拍立得照片中...
          maxLength: 2000
          minLength: 1
          type: string
        size:
          default: 2K
          description: >-
            Image size (optional, default 2K)

            Two formats are supported:

            - Tier: 2K, 3K (for 5.0-lite) or 2K, 4K (for 4.5/4.0), where the
            model automatically determines the aspect ratio based on the prompt

            - Exact resolution: width x height, e.g., "2048x2048", "2560x1440"
          example: 2K
          type: string
        version:
          default: 5.0-lite
          description: |-
            Model version (optional, default 5.0-lite)
            Available values: 4.0, 4.5, 5.0-lite
          enum:
            - '4.0'
            - '4.5'
            - 5.0-lite
          example: 5.0-lite
          type: string
      required:
        - prompt
      type: object
    dto.CreateTaskResponse:
      properties:
        task_id:
          description: Task ID
          example: 01234567-89ab-cdef-0123-456789abcdef
          type: string
      required:
        - task_id
      type: object
    apierror.ErrorResponse:
      properties:
        error_code:
          description: Machine-readable error code (e.g., TASK.INVALID_PARAMS)
          type: string
        message:
          description: User-friendly error message
          type: string
      type: object
  securitySchemes:
    AccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Please use your API Token for authentication

````