> ## 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.5 Flash

> 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, reference\_video\_urls or reference\_audio\_urls array. |
| Edit a video | omni\_reference\_task\_type=edit, duration=-1, and a 4–30 second reference video. Use adaptive aspect ratio. |
| Extend a video | omni\_reference\_task\_type=extend and a nonempty reference\_video\_urls array. |

## 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.5-flash",
  "input": {
    "prompt": "Morning mist drifts across a mountain lake as the camera moves forward.",
    "duration": 5,
    "aspect_ratio": "16:9"
  }
}
```

```json Set both frames theme={null}
{
  "model": "seedance-2.5-flash",
  "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.5-flash",
  "input": {
    "reference_image_urls": [
      "https://cdn.example.com/cabin.jpg"
    ],
    "reference_video_urls": [
      "https://cdn.example.com/camera-motion.mp4"
    ],
    "duration": 5,
    "omni_reference_task_type": "reference",
    "prompt": "以 @图片1 中雾里的木屋门廊作为开场画面，沿用 @视频1 的第一人称运镜穿过走廊，推开门时逐渐拉高 @音频1 的背景音乐。",
    "reference_audio_urls": [
      "https://cdn.example.com/beat.mp3"
    ],
    "generate_audio": true
  }
}
```

```json Edit a reference video theme={null}
{
  "model": "seedance-2.5-flash",
  "input": {
    "prompt": "把 @视频1 中的橙色雨伞替换成深绿色，保留人物动作、镜头和环境声。",
    "reference_video_urls": [
      "https://cdn.example.com/rainy-street.mp4"
    ],
    "omni_reference_task_type": "edit",
    "aspect_ratio": "adaptive",
    "duration": -1
  }
}
```

```json Extend a reference video theme={null}
{
  "model": "seedance-2.5-flash",
  "input": {
    "prompt": "从 @视频1 的结尾向后续写。镜头继续跟随电车过桥，保持原来的夜景色调和运镜速度。",
    "reference_video_urls": [
      "https://cdn.example.com/tram.mp4"
    ],
    "omni_reference_task_type": "extend",
    "aspect_ratio": "adaptive",
    "duration": 5
  }
}
```

## Flash specifications and billing

Flash supports 480p and 720p, 4–30 seconds or automatic duration, up to 10 images, 5 videos and 5 audio inputs. No draft or final-from-draft operation is supported. Reference videos must each be 2–30 seconds (at least 4 seconds for editing) and total no more than 30 seconds.

Requests with reference videos bill input plus output seconds; failed outputs are free. Automatic duration holds 30 billable seconds and settles on the measured duration (the full hold if measurement is missing). The official rate applies only when you set `official_fallback: true` and the official route completes the 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.5-flash#try)
>
> Set your parameters and generate a video.

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


## OpenAPI

````yaml openapi-seedance-2.5-flash.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.5 Flash
      description: Create videos from a prompt, first and last frames, or reference media.
      operationId: seedance-2.5-flash
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - input
              additionalProperties: false
              properties:
                model:
                  type: string
                  enum:
                    - seedance-2.5-flash
                  example: seedance-2.5-flash
                  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: 20480
                      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–20480 characters after trimming.
                    resolution:
                      type: string
                      enum:
                        - 480p
                        - 720p
                      description: 'Output resolution. Allowed: 480p, 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. Use adaptive for frame-based generation,
                        editing, and extension.
                    generate_audio:
                      type: boolean
                      description: >-
                        Generate a synchronized soundtrack. Default true. Set
                        false for silent output.
                    seed:
                      type: integer
                      minimum: -1
                      maximum: 2147483647
                      description: >-
                        Integer from -1 to 2147483647. 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.
                    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_format:
                      type: string
                      enum:
                        - mp4
                        - mov
                      description: 'Output format: mp4 (default) or mov.'
                      default: mp4
                    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:
                      anyOf:
                        - type: number
                          const: -1
                        - type: integer
                          minimum: 4
                          maximum: 30
                      description: >-
                        Output duration in seconds. Integer from 4 to 30.
                        Default 5. Use -1 for automatic duration. Credits are
                        reserved for up to 30 output seconds and settled using
                        the actual output duration. Video editing requires -1
                        and follows the source duration.
                    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: 10
                      type: array
                      items:
                        type: string
                        format: uri
                      description: >-
                        Up to 10 images. The generation provider validates the
                        files. Keep URLs accessible and files unchanged until
                        the task finishes.
                    reference_video_urls:
                      maxItems: 5
                      type: array
                      items:
                        type: string
                        format: uri
                      description: >-
                        Up to 5 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: 5
                      type: array
                      items:
                        type: string
                        format: uri
                      description: >-
                        Up to 5 reference audio clips. The generation provider
                        validates the files. Audio may be the only reference
                        type. Keep URLs accessible and files unchanged until the
                        task finishes.
                    omni_reference_task_type:
                      type: string
                      enum:
                        - auto
                        - reference
                        - edit
                        - extend
                      description: >-
                        Only for reference inputs. auto (default) infers the
                        task type. reference generates a new video, edit changes
                        a reference video, and extend continues it. edit and
                        extend require a reference video and adaptive aspect
                        ratio. edit also requires duration=-1.
                  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.5-flash
              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.5-flash",
                      "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.5-flash
                            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.5-flash
                        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.