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

# Create Video

> Start a video generation job.

Send `model` as `provider/model` (see GET /v3/videos/models), a `prompt`,
and optionally `seconds`, `size` and an `input_reference` image. The job
runs asynchronously: poll GET /v3/videos/{video_id} until `status` is
`completed`, then download the mp4 from GET /v3/videos/{video_id}/content.
Accepts `application/json`, or `multipart/form-data` with the reference
image as the `input_reference` file part.



## OpenAPI

````yaml https://api.edenai.run/v3/docs/openapi.json post /v3/videos
openapi: 3.1.0
info:
  title: Eden AI API V3
  version: 3.0.0
servers:
  - url: https://api.edenai.run
    description: Production server
security: []
paths:
  /v3/videos:
    post:
      tags:
        - Videos
      summary: Create Video
      description: >-
        Start a video generation job.


        Send `model` as `provider/model` (see GET /v3/videos/models), a
        `prompt`,

        and optionally `seconds`, `size` and an `input_reference` image. The job

        runs asynchronously: poll GET /v3/videos/{video_id} until `status` is

        `completed`, then download the mp4 from GET
        /v3/videos/{video_id}/content.

        Accepts `application/json`, or `multipart/form-data` with the reference

        image as the `input_reference` file part.
      operationId: create_video_v3_videos_post
      requestBody:
        required: true
        content:
          application/json:
            schema:
              additionalProperties: false
              description: >-
                Request body for ``POST /v3/videos``.


                OpenAI's video creation shape (`model`, `prompt`, `seconds`,
                `size`,

                `input_reference`) plus Eden extensions (`seed`,
                `provider_params`,

                `webhook_receiver`, `user_webhook_parameters`).
              properties:
                model:
                  description: >-
                    Video model as `provider/model`, e.g. `pruna/p-video` or
                    `openai/sora-2`. List the available ids with GET
                    /v3/videos/models.
                  minLength: 1
                  title: Model
                  type: string
                prompt:
                  description: Text describing the video to generate.
                  minLength: 1
                  title: Prompt
                  type: string
                seconds:
                  anyOf:
                    - type: integer
                      minimum: 1
                    - type: 'null'
                  description: >-
                    Clip length in seconds. Accepts OpenAI's string form ("4",
                    "8", "12") or an integer. Omit to use the model's default
                    duration.
                  title: Seconds
                size:
                  anyOf:
                    - pattern: ^\d+x\d+$
                      type: string
                    - type: 'null'
                  description: >-
                    Output resolution as `WIDTHxHEIGHT`, e.g. `1280x720` or
                    `1920x1080`. Omitted uses the provider's default; each
                    provider maps it to its nearest tier.
                  title: Size
                seed:
                  anyOf:
                    - maximum: 2147483646
                      minimum: 0
                      type: integer
                    - type: 'null'
                  description: 'Eden extension: random seed for reproducible output.'
                  title: Seed
                provider_params:
                  anyOf:
                    - additionalProperties: true
                      type: object
                    - type: 'null'
                  description: >-
                    Eden extension: provider-native parameters merged into the
                    provider request, subject to the per-provider allow-list.
                  title: Provider Params
                webhook_receiver:
                  anyOf:
                    - type: string
                      maxLength: 2083
                      minLength: 1
                      format: uri
                    - type: 'null'
                  description: 'Eden extension: URL notified when the job finishes.'
                  title: Webhook Receiver
                user_webhook_parameters:
                  anyOf:
                    - additionalProperties: true
                      type: object
                    - type: 'null'
                  description: 'Eden extension: custom fields echoed in the webhook payload.'
                  title: User Webhook Parameters
                input_reference:
                  anyOf:
                    - $ref: '#/components/schemas/VideoInputReference'
                    - type: 'null'
                  description: >-
                    Optional reference image that seeds an image-to-video
                    generation.
              required:
                - model
                - prompt
              title: VideoGenerationBody
              type: object
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VideoObject'
      security:
        - AuthBearer: []
components:
  schemas:
    VideoInputReference:
      additionalProperties: false
      description: >-
        Reference image for image-to-video generation.


        Set exactly one of ``file_id`` (an image uploaded to ``POST
        /v3/upload``)

        or ``image_url`` (a public http(s) URL to a JPEG or PNG). Base64 data
        URLs

        are not accepted: upload the image and pass its ``file_id`` instead.
      properties:
        file_id:
          anyOf:
            - type: string
            - type: 'null'
          description: Id of an image previously uploaded to /v3/upload.
          title: File Id
        image_url:
          anyOf:
            - type: string
            - type: 'null'
          description: Public http(s) URL of a JPEG or PNG image.
          title: Image Url
      title: VideoInputReference
      type: object
    VideoObject:
      properties:
        id:
          type: string
          title: Id
          description: Job id. Use it to poll, download and delete.
        object:
          type: string
          const: video
          title: Object
          default: video
        status:
          type: string
          enum:
            - queued
            - in_progress
            - completed
            - failed
          title: Status
          description: queued, in_progress, completed or failed.
        progress:
          anyOf:
            - type: integer
            - type: 'null'
          title: Progress
          description: 0 while running or failed, 100 when completed.
        created_at:
          type: integer
          title: Created At
          description: Unix timestamp (seconds) of job creation.
        completed_at:
          anyOf:
            - type: integer
            - type: 'null'
          title: Completed At
          description: Unix timestamp (seconds) when the job finished.
        expires_at:
          anyOf:
            - type: integer
            - type: 'null'
          title: Expires At
          description: 'Always null: Eden AI keeps the result.'
        model:
          type: string
          title: Model
          description: The `provider/model` that ran the job.
        seconds:
          anyOf:
            - type: string
            - type: 'null'
          title: Seconds
          description: Clip length in seconds, as a string.
        size:
          anyOf:
            - type: string
            - type: 'null'
          title: Size
          description: Requested resolution as `WIDTHxHEIGHT`.
        remixed_from_video_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Remixed From Video Id
          description: 'Always null: remix is not supported.'
        error:
          anyOf:
            - $ref: '#/components/schemas/VideoError'
            - type: 'null'
          description: Set when status is failed.
        provider:
          type: string
          title: Provider
          description: 'Eden extension: provider that ran the job.'
        cost:
          type: number
          title: Cost
          description: >-
            Eden extension: cost in USD. 0 while the job is queued or in
            progress (the reserved estimate is not surfaced); the settled amount
            once the job completes or fails.
      type: object
      required:
        - id
        - status
        - created_at
        - model
        - provider
        - cost
      title: VideoObject
      description: >-
        A video generation job, in OpenAI's video object shape.


        `provider` and `cost` are Eden extensions. Download the finished video
        from

        ``GET /v3/videos/{video_id}/content``.
    VideoError:
      properties:
        code:
          type: string
          title: Code
          description: Machine-readable error code.
        message:
          type: string
          title: Message
          description: Human-readable error message.
      type: object
      required:
        - code
        - message
      title: VideoError
      description: Why a video job failed.
  securitySchemes:
    AuthBearer:
      type: http
      scheme: bearer

````