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

# Генерация видео

> Загрузите собственное аудио и выполните последующую обработку.



## OpenAPI

````yaml openapi/ru/producer.json POST /producer/v1/generate-video
openapi: 3.1.0
info:
  title: Документация Producer API
  version: 1.0.0
  description: TTAPI Producer API сервис
servers:
  - url: https://api.ttapi.io
security: []
paths:
  /producer/v1/generate-video:
    post:
      description: Загрузите собственное аудио и выполните последующую обработку.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GeneratevideoRequest'
      responses:
        '200':
          description: Запрос выполнен успешно
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - 'PENDING_QUEUE '
                      - ON_QUEUE
                      - SUCCESS
                      - FAILED
                  message:
                    type: string
                    description: Сообщение ответа
                  data:
                    type: object
                    description: Результат задачи
                    properties:
                      videoUrl:
                        type: string
                        description: >-
                          URL видео. Срок действия: см. [Хранение и
                          устойчивость](/grids/ru/faq/storage)
                      status:
                        type: string
                        description: Статус
                example:
                  status: SUCCESS
                  message: success
                  data:
                    videoUrl: >-
                      https://storage.googleapis.com/corpusant-app-public/song-videos/77ce096c-22c2-442b-a868-4100867a45df:0835e01ecc5ae00a000cc5a9b8f3035dea48508645a6142cbd1d7e5b72e0d4d7.mp4
                    status: complete
                required:
                  - status
                  - message
        '400':
          $ref: '#/components/responses/400Response'
        '401':
          $ref: '#/components/responses/401Response'
      security:
        - CustomApiKey: []
components:
  schemas:
    GeneratevideoRequest:
      type: object
      properties:
        music_id:
          type: string
          description: Идентификатор музыки родительской задачи
        preset:
          type: string
          enum:
            - modern
            - player
            - simple
          default: simple
          description: Предустановленный тип генерации видео, доступны три варианта
      required:
        - music_id
  responses:
    400Response:
      description: Ошибка параметров
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: string
                example: FAILED
              message:
                type: string
                example: '"prompt" cannot be empty.'
              data:
                type: object
            required:
              - status
              - message
    401Response:
      description: Ошибка авторизации
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: string
                example: FAILED
              message:
                type: string
                example: Wrong TT-API-KEY or email is not activated.
            required:
              - status
              - message
  securitySchemes:
    CustomApiKey:
      type: apiKey
      in: header
      name: TT-API-KEY
      description: >-
        Вы можете получить API-ключ в <a href='https://dashboard.ttapi.io'
        target='_blank'>панель управления TTAPI</a>.

````