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

# Seedance 2.0-mini

> Create videos from a prompt, first and last frames, or reference media.

## Parameters and input modes

| Request type | Required input fields |
| - | - |
| Text to video | prompt |
| First frame or first and last frames | first\_frame\_url. last\_frame\_url is optional. |
| Reference generation | At least one nonempty reference\_image\_urls or reference\_video\_urls array. Audio is optional. |

## Use cases

Submit the selected example to the task creation endpoint. Replace the example media URLs with your own public HTTPS file URLs.

In the prompt, use @图片1 (image 1), @视频1 (video 1), and @音频1 (audio 1) to say what each reference should control. Numbering starts at 1 within each array. Use first\_frame\_url when the opening frame must match a specific image.

```json Text to video theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "prompt": "Morning mist drifts across a mountain lake as the camera moves forward.",
    "duration": 5,
    "aspect_ratio": "16:9"
  }
}
```

```json Animate an image theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "prompt": "Slowly pull back to reveal the valley.",
    "first_frame_url": "https://cdn.example.com/start.jpg"
  }
}
```

```json Set both frames theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "prompt": "Move the camera slowly toward the cabin.",
    "first_frame_url": "https://cdn.example.com/start.jpg",
    "last_frame_url": "https://cdn.example.com/end.jpg",
    "aspect_ratio": "adaptive",
    "duration": 5
  }
}
```

```json Combine image, video and audio theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "reference_image_urls": [
      "https://cdn.example.com/cabin.jpg"
    ],
    "reference_video_urls": [
      "https://cdn.example.com/camera-motion.mp4"
    ],
    "duration": 5,
    "prompt": "以 @图片1 中雾里的木屋门廊作为开场画面，沿用 @视频1 的第一人称运镜穿过走廊，推开门时逐渐拉高 @音频1 的背景音乐。",
    "reference_audio_urls": [
      "https://cdn.example.com/beat.mp3"
    ],
    "generate_audio": true
  }
}
```

```json Generate synchronized audio theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "prompt": "咖啡店门口，店员拿起椅背上的围巾，朝正要出门的客人喊：「等一下，你的围巾忘拿了！」镜头对准店员的脸，清楚听到这句普通话，口型与台词同步。",
    "generate_audio": true
  }
}
```

```json Continue with the last frame theme={null}
{
  "model": "seedance-2.0-mini",
  "input": {
    "prompt": "Continue from this frame and move the camera through the doorway.",
    "first_frame_url": "https://cdn.example.com/previous-last-frame.jpg",
    "return_last_frame": true
  }
}
```

> To connect two clips, set return\_last\_frame=true on the previous task and use its result.items\[].last\_frame\_url as first\_frame\_url for the next task.

## Playground and pricing

Cost = per-second rate (rounded up to a whole Credit) × billable seconds, kept to 0.001 Credit. Submitted tasks keep the price quoted at submission.

> [card] [Try in Playground](https://apistable.ai/models/seedance-2.0-mini#try)
>
> Set your parameters and generate a video.

> [card] [View pricing](https://apistable.ai/models/seedance-2.0-mini#pricing)
>
> Compare standard and official fallback prices by resolution.


## OpenAPI

````yaml openapi-seedance-2.0-mini.json POST /api/v1/tasks/create_task
openapi: 3.1.0
info:
  title: APIstable API
  version: 1.0.0-preview
  description: >-
    Public /api/v1 protocol. Valid API keys have the same account-scoped access.
    Read the selected model documentation for its ID, supported inputs, result
    format and availability before submitting. No client submission idempotency
    or max_credits. Availability, pricing, file retention and callback formats
    follow the selected model contract. Unconfigured operations return 503.
servers:
  - url: https://apistable.ai
    description: API Stable API
security: []
paths:
  /api/v1/tasks/create_task:
    post:
      summary: Seedance 2.0-mini
      description: Create videos from a prompt, first and last frames, or reference media.
      operationId: seedance-2.0-mini
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - input
              additionalProperties: false
              properties:
                model:
                  type: string
                  enum:
                    - seedance-2.0-mini
                  example: seedance-2.0-mini
                  description: The APIstable model ID for this endpoint.
                input:
                  $schema: https://json-schema.org/draft/2020-12/schema
                  type: object
                  properties:
                    prompt:
                      type: string
                      minLength: 1
                      maxLength: 4000
                      description: >-
                        Describe the subject, motion and camera. Required in
                        text mode. Requests with media and no prompt only use
                        channels that accept this combination. If supplied,
                        1–4000 characters after trimming.
                    resolution:
                      type: string
                      enum:
                        - 480p
                        - 720p
                      description: 'Output resolution. Allowed: 480p, 720p. Default 720p.'
                      default: 720p
                    aspect_ratio:
                      type: string
                      enum:
                        - adaptive
                        - '16:9'
                        - '4:3'
                        - '1:1'
                        - '3:4'
                        - '9:16'
                        - '21:9'
                      description: >-
                        Width-to-height ratio. Default adaptive (chosen from the
                        input). Use 16:9 for landscape, 9:16 for portrait, or
                        1:1 for square.
                      default: adaptive
                    generate_audio:
                      type: boolean
                      description: >-
                        Generate a synchronized soundtrack. Default true. Set
                        false for silent output.
                      default: true
                    seed:
                      type: integer
                      minimum: -1
                      maximum: 4294967295
                      description: >-
                        Integer from -1 to 4294967295. Use -1 for a random seed.
                        A fixed seed can improve repeatability; output can still
                        vary.
                    return_last_frame:
                      type: boolean
                      description: >-
                        Set true to also return the final frame image. Default
                        false.
                      default: false
                    web_search:
                      type: boolean
                      description: >-
                        Set true to look up information while generating.
                        Default false.
                      default: false
                    nsfw_check:
                      type: boolean
                      description: >-
                        Screen the prompt and input images, including the first
                        and last frames, before creating a task. Default false.
                        True requires a prompt or image.
                      default: false
                    output_count:
                      default: 1
                      type: integer
                      minimum: 1
                      maximum: 4
                      description: >-
                        Number of independent video results, 1–4. Default 1.
                        Each successful item is charged separately.
                    official_fallback:
                      default: false
                      type: boolean
                      description: >-
                        Default false. True permits official fallback when it
                        supports the requested parameters. Official pricing
                        applies only on official success.
                    duration:
                      type: integer
                      minimum: 4
                      maximum: 15
                      description: >-
                        Output duration in seconds. Integer from 4 to 15.
                        Default 5.
                      default: 5
                    first_frame_url:
                      type: string
                      format: uri
                      description: >-
                        Required in first-frame and first/last-frame modes.
                        Provide a public HTTPS image URL. Cannot be combined
                        with reference media. Keep URLs accessible and files
                        unchanged until the task finishes.
                    last_frame_url:
                      type: string
                      format: uri
                      description: >-
                        Closing image as a public HTTPS URL. Requires
                        first_frame_url. Keep URLs accessible and files
                        unchanged until the task finishes.
                    reference_image_urls:
                      maxItems: 9
                      type: array
                      items:
                        type: string
                        format: uri
                        description: Public HTTPS file URL accessible to the server.
                      description: >-
                        Up to 9 images. The generation provider validates the
                        files. Keep URLs accessible and files unchanged until
                        the task finishes.
                    reference_video_urls:
                      maxItems: 3
                      type: array
                      items:
                        type: string
                        format: uri
                        description: Public HTTPS file URL accessible to the server.
                      description: >-
                        Up to 3 reference clips. A readable duration is required
                        for billing. The generation provider validates the
                        files. Keep URLs accessible and files unchanged until
                        the task finishes.
                    reference_audio_urls:
                      maxItems: 3
                      type: array
                      items:
                        type: string
                        format: uri
                        description: Public HTTPS file URL accessible to the server.
                      description: >-
                        Up to 3 reference audio clips. The generation provider
                        validates the files. Include an image or video reference
                        with audio. Keep URLs accessible and files unchanged
                        until the task finishes.
                  additionalProperties: false
                  description: >-
                    Video generation parameters. The selected model and input
                    mode determine which combinations are available.
                callback_url:
                  type: string
                  format: uri
                  description: >-
                    Optional public HTTPS endpoint for signed completion
                    callbacks; no redirects or private IPs.
            example:
              model: seedance-2.0-mini
              input:
                prompt: A quiet mountain lake at sunrise
                resolution: 720p
                duration: 5
                aspect_ratio: '16:9'
                official_fallback: false
      responses:
        '200':
          description: Accepted task. Poll the common task endpoint or use callback_url.
          content:
            application/json:
              schema:
                type: object
                required:
                  - code
                  - msg
                  - data
                additionalProperties: false
                properties:
                  code:
                    const: 200
                  msg:
                    const: success
                  data:
                    type: object
                    required:
                      - task_id
                    additionalProperties: false
                    properties:
                      task_id:
                        type: string
        '400':
          description: >-
            40001 invalid JSON, 40002 invalid input/callback or input rejected
            by screening, 40003 unsupported parameter.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Invalid or revoked API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '402':
          description: '40201: Insufficient credits (live acceptance).'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: '40301: Website session requests require the APIstable site origin.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: '40401: Unknown model or resource not found in this account.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: '40901: Resource incompatible with this operation.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '410':
          description: '41001: Source audio or temporary resource has expired.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '413':
          description: '41301: Request too large.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '422':
          description: '42201: Requested capability combination is not enabled.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: '42901: Rate/concurrency limit (live acceptance).'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '503':
          description: '50301: Service unavailable. No live submission or charge.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      callbacks:
        Webhook:
          '{$request.body#/callback_url}':
            post:
              requestBody:
                required: true
                description: >-
                  When the task succeeds or fails, APIstable sends a JSON POST
                  to the `callback_url` supplied at creation. Verify the
                  signature and return HTTP 2xx to acknowledge delivery.


                  Read `data.status` to determine the generation outcome.
                  Partial success also reports `succeeded` and includes only
                  successful items. For a failed task, `data.result` is `null`
                  and `data.message` contains the failure reason.


                  Use `X-APIstable-Signature`, `X-APIstable-Timestamp`, and
                  `X-APIstable-Event-Id` to verify and deduplicate deliveries.
                  See [Webhook security](/webhook-secret).


                  **Webhook payload example**


                  ```json

                  {
                    "code": 200,
                    "msg": "success",
                    "data": {
                      "task_id": "c6adbc82-8b9a-4d6f-8b60-1114c8c4aafb",
                      "model": "seedance-2.0-mini",
                      "status": "succeeded",
                      "created_at": "2026-11-13T08:30:00.000Z",
                      "completed_at": "2026-11-13T08:31:20.000Z",
                      "duration": 80000,
                      "charged_credits": 100,
                      "message": "",
                      "input": "{\"prompt\":\"A quiet mountain lake at sunrise\"}",
                      "result": {
                        "urls": [
                          "https://cdn.example.com/generated/video.mp4"
                        ],
                        "items": [
                          {
                            "id": "e7aacd19-819a-4747-bbbf-46fb6f2995a5",
                            "urls": [
                              "https://cdn.example.com/generated/video.mp4"
                            ],
                            "last_frame_url": null,
                            "draft": false,
                            "draft_expires_at": null
                          }
                        ]
                      }
                    }
                  }

                  ```
                content:
                  application/json:
                    schema:
                      type: object
                      required:
                        - code
                        - msg
                        - data
                      properties:
                        code:
                          type: integer
                          const: 200
                        msg:
                          type: string
                          const: success
                        data:
                          type: object
                          additionalProperties: false
                          required:
                            - task_id
                            - model
                            - status
                            - created_at
                            - completed_at
                            - duration
                            - charged_credits
                            - message
                            - input
                            - result
                          properties:
                            task_id:
                              type: string
                            model:
                              type: string
                              const: seedance-2.0-mini
                            status:
                              type: string
                              enum:
                                - succeeded
                                - failed
                            created_at:
                              type: string
                              format: date-time
                            completed_at:
                              type:
                                - string
                                - 'null'
                              format: date-time
                            duration:
                              type:
                                - integer
                                - 'null'
                              minimum: 0
                              description: >-
                                Total elapsed milliseconds; null while
                                processing.
                            charged_credits:
                              type:
                                - number
                                - 'null'
                              minimum: 0
                              description: Final charged Credits; null until completion.
                            message:
                              type: string
                              description: >-
                                Failure reason for failed tasks, or an
                                actionable pending-settlement message while
                                processing; empty on success.
                            input:
                              type: string
                              contentMediaType: application/json
                              description: JSON-serialized accepted model input.
                            result:
                              type:
                                - object
                                - 'null'
                              required:
                                - urls
                                - items
                              properties:
                                urls:
                                  type: array
                                  items:
                                    type: string
                                    format: uri
                                items:
                                  type: array
                                  items:
                                    type: object
                                    required:
                                      - id
                                      - urls
                                      - last_frame_url
                                      - draft
                                      - draft_expires_at
                                    properties:
                                      id:
                                        type: string
                                        format: uuid
                                      urls:
                                        type: array
                                        items:
                                          type: string
                                          format: uri
                                      last_frame_url:
                                        type:
                                          - string
                                          - 'null'
                                        format: uri
                                      draft:
                                        type: boolean
                                      draft_expires_at:
                                        type:
                                          - string
                                          - 'null'
                                        format: date-time
                    example:
                      code: 200
                      msg: success
                      data:
                        task_id: c6adbc82-8b9a-4d6f-8b60-1114c8c4aafb
                        model: seedance-2.0-mini
                        status: succeeded
                        created_at: '2026-11-13T08:30:00.000Z'
                        completed_at: '2026-11-13T08:31:20.000Z'
                        duration: 80000
                        charged_credits: 100
                        message: ''
                        input: '{"prompt":"A quiet mountain lake at sunrise"}'
                        result:
                          urls:
                            - https://cdn.example.com/generated/video.mp4
                          items:
                            - id: e7aacd19-819a-4747-bbbf-46fb6f2995a5
                              urls:
                                - https://cdn.example.com/generated/video.mp4
                              last_frame_url: null
                              draft: false
                              draft_expires_at: null
              responses:
                2XX:
                  description: Webhook acknowledged.
              method: post
              type: path
            path: '{$request.body#/callback_url}'
      security:
        - bearerAuth: []
components:
  schemas:
    Error:
      type: object
      required:
        - code
        - msg
        - data
      properties:
        code:
          type: integer
        msg:
          type: string
        data:
          type: 'null'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Sign in to APIstable, then create and copy a key from [API Key
        management](https://apistable.ai/console/keys).


        Send this HTTP header with every request:


        ```http

        Authorization: Bearer YOUR_API_KEY

        ```


        Replace YOUR_API_KEY with the key you created.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.