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

# Videogenerierung erstellen und auf Ergebnis warten

> Erstellt eine Videoaufgabe und wartet bis zur konfigurierten maximalen Wartezeit auf den Abschluss der Aufgabe.



## OpenAPI

````yaml /de/openapi.json post /v1/videos/generations/sync
openapi: 3.1.0
info:
  title: APIAny.AI Öffentliche API
  version: 1.0.0
  description: >-
    Öffentliche API von APIAny.AI für Modellaggregation, asynchrone
    Medienaufgaben, Chat-Generierung, Guthabenabfrage und Aufgabenabfrage.
servers:
  - url: https://apiany.ai
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Models
    description: Öffentlicher Modellkatalog.
  - name: Chat
    description: Endpunkte für Textgenerierung und chatkompatible Funktionen.
  - name: Images
    description: Endpunkte für Bildgenerierung und Bildbearbeitung.
  - name: Videos
    description: Endpunkte für Videogenerierung.
  - name: Moderation
    description: Image safety and moderation endpoints.
  - name: Tasks
    description: Abfrage asynchroner Aufgaben.
  - name: Account
    description: Konto- und Guthabenabfrage.
  - name: Free APIs
    description: Free utility APIs protected by API key rate limits.
paths:
  /v1/videos/generations/sync:
    post:
      tags:
        - Videos
      summary: Videogenerierung erstellen und auf Ergebnis warten
      description: >-
        Erstellt eine Videoaufgabe und wartet bis zur konfigurierten maximalen
        Wartezeit auf den Abschluss der Aufgabe.
      operationId: createVideoGenerationSync
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/VideoGenerationRequest'
      responses:
        '200':
          description: Abgeschlossene Videoaufgabe.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskResponse'
        '202':
          description: >-
            Aufgabe wird nach Erreichen der maximalen Wartezeit weiterhin
            verarbeitet.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AsyncTaskCreateResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
components:
  schemas:
    VideoGenerationRequest:
      type: object
      properties:
        model:
          type: string
          example: seedance-2.0
        prompt:
          type: string
        duration:
          type: string
          example: 10s
        resolution:
          type: string
          example: 720p
        ratio:
          type: string
          example: '16:9'
        input_images:
          type: array
          items:
            type: string
            format: uri
        input_videos:
          type: array
          items:
            type: string
            format: uri
        input_audio:
          type: array
          items:
            type: string
            format: uri
        callback_url:
          type: string
          format: uri
      required:
        - model
        - prompt
    TaskResponse:
      type: object
      properties:
        task_id:
          type: string
          example: task_123
        status:
          type: string
          enum:
            - pending
            - processing
            - completed
            - failed
            - expired
        model:
          type: string
        created_at:
          type: string
          format: date-time
        completed_at:
          type:
            - string
            - 'null'
          format: date-time
        result:
          oneOf:
            - $ref: '#/components/schemas/MediaResult'
            - type: 'null'
        error:
          oneOf:
            - 8d836be4-6730-462b-87e7-6fd5a859c79c
            - type: 'null'
      required:
        - task_id
        - status
    AsyncTaskCreateResponse:
      type: object
      properties:
        task_id:
          type: string
          example: task_123
        status:
          type: string
          enum:
            - pending
            - processing
        model:
          type: string
        poll_url:
          type: string
          example: /v1/tasks/task_123
      required:
        - task_id
        - status
        - poll_url
    MediaResult:
      description: >-
        Ergebnis einer abgeschlossenen Aufgabe. Bildaufgaben verwenden das
        OpenAI-Bildformat (Bildadresse unter data[0].url); Video- und
        Audioaufgaben stellen video_url/audio_url sowie ein urls[]-Array bereit.
      oneOf:
        - $ref: '#/components/schemas/ImageTaskResult'
        - $ref: '#/components/schemas/MediaUrlResult'
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - invalid_request
                - auth_error
                - rate_limit
                - insufficient_quota
                - content_policy
                - timeout
                - network_error
                - service_error
                - billable_error
                - unknown
            message:
              type: string
            param:
              type:
                - string
                - 'null'
            code:
              type:
                - string
                - 'null'
          required:
            - type
            - message
      required:
        - error
    ImageTaskResult:
      type: object
      description: >-
        Ergebnis einer Bildaufgabe (OpenAI-Bildformat); die Bildadresse befindet
        sich unter data[0].url.
      properties:
        created:
          type: integer
        data:
          type: array
          items:
            type: object
            properties:
              url:
                type: string
                format: uri
              b64_json:
                type: string
              revised_prompt:
                type: string
      required:
        - data
    MediaUrlResult:
      type: object
      description: >-
        Ergebnis einer Video- oder Audioaufgabe. Die Hauptadresse ist video_url
        oder audio_url; alle Ausgaben sind zugleich in urls[] aufgeführt.
      properties:
        status:
          type: string
        video_url:
          type: string
          format: uri
        audio_url:
          type: string
          format: uri
        output_url:
          type: string
          format: uri
        urls:
          type: array
          items:
            type: string
            format: uri
  responses:
    BadRequest:
      description: Ungültige Anfrageparameter.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key

````