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

> ## Agent Instructions
> Send API requests to https://api.ttapi.io with the TT-API-KEY header. Midjourney account hosting uses https://hold.ttapi.io. Claude Code uses https://cc.ttapi.io.
> Most generation endpoints are asynchronous. The submit response returns a job id. Poll that product's fetch endpoint, or pass a webhook on the submit request. A fetch call does not start a new generation.
> 1 USD = 100 quota. Check the pricing page for that product before estimating cost.
> This file lists the English docs. Follow every /_llms/ link recursively for the API reference, Chinese, and Russian. Open a page's .md URL for the endpoint schema.

# Изображение-в-видео (base64)

> изображение-в-видео。на основе одного референсного изображения иТекстовый промптсоздатьвидео。поддерживается base64 формат кодирования。Все 4 модели. Отправьте асинхронную задачу ивернуть id，используйте эндпоинт для получения результата。

Эндпоинт изображение-в-видео **Seedance API генерации видео**. Генерация видео на основе референсного изображения и текстового промпта. Поддерживает base64. Отправьте асинхронную задачу и верните id.

**Использование**: Включите `text` и `image_url` (без role, поддерживает base64) в `content`. ratio = adaptive.


## OpenAPI

````yaml openapi/ru/seedance-image-to-video.json POST /sd/api/v3/contents/generations/tasks
openapi: 3.1.0
info:
  title: Seedance API генерации видео (Изображение-в-видео)
  version: 1.0.0
  description: Генерация видео из референсного изображения.
servers:
  - url: https://api.ttapi.io
security: []
paths:
  /sd/api/v3/contents/generations/tasks:
    post:
      description: >-
        изображение-в-видео。на основе одного референсного изображения иТекстовый
        промптсоздатьвидео。поддерживается base64 формат кодирования。Все 4
        модели. Отправьте асинхронную задачу ивернуть id，используйте эндпоинт
        для получения результата。
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateRequest'
            example:
              model: doubao-seedance-2-0-260128
              content:
                - type: text
                  text: Девушка гуляет по пляжу, бриз развевает её волосы
                - type: image_url
                  image_url:
                    url: data:image/png;base64,aHR0cHM6Ly9leGFtcGxlLmNvbS9yZWYucG5n
              ratio: adaptive
              duration: 10
              generate_audio: true
              watermark: true
      responses:
        '200':
          description: Задача успешно отправлена
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: ID задачи
                example:
                  id: cgt-20261021120000-xxxxx
                required:
                  - id
      security:
        - CustomApiKey: []
components:
  schemas:
    CreateRequest:
      type: object
      properties:
        model:
          type: string
          enum:
            - doubao-seedance-2-5-260628
            - doubao-seedance-2-0-260128
            - doubao-seedance-2-0-fast-260128
            - doubao-seedance-2-0-mini-260615
          description: ID модели
        content:
          type: array
          items:
            $ref: '#/components/schemas/ContentItem'
          description: >-
            Список входного контента. Включает text и image_url (без поля role,
            поддерживает base64)
        resolution:
          type: string
          enum:
            - 480p
            - 720p
            - 1080p
            - 4k
          default: 720p
          description: >-
            Разрешение видео. Seedance 2.0: 480p, 720p, 1080p, 4k, по умолчанию
            720p; 2.0 fast/mini: 480p, 720p
        ratio:
          type: string
          enum:
            - adaptive
          description: >-
            Соотношение сторон видео, adaptive авто-соответствие референсному
            изображению
        duration:
          type: integer
          default: -1
          description: >-
            Длительность видео (сек). Диапазон [4, 15] или -1 (умный выбор).
            Seedance 2.0 fast/mini: [4, 15]
        generate_audio:
          type: boolean
          default: true
          description: Генерировать синхронизированный звук
        watermark:
          type: boolean
          default: false
          description: Добавить водяной знак
        return_last_frame:
          type: boolean
          default: false
          description: Вернуть изображение последнего кадра
        callback_url:
          type: string
          description: URL обратного вызова
        execution_expires_after:
          type: integer
          default: 172800
          description: Тайм-аут задачи (сек). Диапазон [3600, 259200]
        priority:
          type: integer
          default: 0
          description: Приоритет выполнения. Диапазон [0, 9]
        safety_identifier:
          type: string
          description: Идентификатор конечного пользователя, макс. 64 символа
        tools:
          type: array
          items:
            type: object
            properties:
              type:
                type: string
                enum:
                  - web_search
          description: Конфигурация инструментов
        service_tier:
          type: string
          enum:
            - default
          default: default
          description: Уровень обслуживания
      required:
        - model
        - content
    ContentItem:
      type: object
      description: Элемент входного контента
      oneOf:
        - type: object
          properties:
            type:
              type: string
              enum:
                - text
            text:
              type: string
              description: Текстовый промпт
          required:
            - type
            - text
        - type: object
          properties:
            type:
              type: string
              enum:
                - image_url
            image_url:
              type: object
              properties:
                url:
                  type: string
                  description: >-
                    URL референсного изображения / Base64. Форматы:
                    jpeg/png/webp/bmp/tiff/gif/heic/heif，Соотношение сторон
                    [0.4, 2.5]，размер < 30MB
            role:
              type: string
              enum:
                - first_frame
              description: >-
                Назначение изображения. Role = first_frame для
                изображения-в-видео или оставьте пустым
          required:
            - type
            - image_url
  securitySchemes:
    CustomApiKey:
      type: apiKey
      in: header
      name: TT-API-KEY
      description: >-
        Получите API-ключ в <a href='https://dashboard.ttapi.io'
        target='_blank'>панели TTAPI</a>.

````

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