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

# Video status (Beta)

> Check the status of a video generation request.

Fetches the current state of a video generation job and returns the latest provider status payload.

Use this endpoint for polling while the job is running.

Common response fields include:

* `id`
* `object`
* `status`
* `output_access`
* `progress`
* `progress_source`
* `polling_url`
* `poll_after_seconds`
* `generation_id`
* `created_at`
* `started_at`
* `completed_at`
* `provider`
* `model`
* `seconds`
* `size`
* `audio`
* `asset`
* `outputs`
* `usage`
* `billing`
* `error`

Output-access fields are conditional:

* `content_url` is present when `output_access` is `bytes` or `both`.
* `download_url` and `expires_at` are present when `output_access` is `signed_url` or `both`.

Each entry in `outputs` includes:

* `index`
* `mime_type`
* `bytes_available`
* `content_url` when unsigned byte access is enabled
* `download_url` and `expires_at` when signed download access is enabled

When the job becomes terminal, this response is also where billing, asset metadata, output access, and any final provider error payload become most useful.


## OpenAPI

````yaml GET /videos/{video_id}
openapi: 3.0.3
info:
  title: AI Stats Gateway API
  description: >-
    A gateway API for accessing various AI models with OpenAI-compatible
    endpoints.
  version: 1.0.0
  contact:
    name: AI Stats
    url: https://docs.ai-stats.phaseo.app
    email: danielbutler500@gmail.com
servers:
  - url: https://api.phaseo.app/v1
security:
  - BearerAuth: []
tags:
  - name: Gateway
    description: Core AI Stats Gateway operations.
paths:
  /videos/{video_id}:
    get:
      tags:
        - Gateway
      summary: Get video status
      description: >-
        Retrieves the status for a video generation request. Poll every 20
        seconds unless you are using webhooks.
      operationId: getVideo
      parameters:
        - name: video_id
          in: path
          required: true
          description: The ID of the video generation request.
          schema:
            type: string
      responses:
        '200':
          description: Video status response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VideoGenerationResponse'
components:
  schemas:
    VideoGenerationResponse:
      type: object
      properties:
        id:
          type: string
        polling_url:
          type: string
        model:
          type: string
        request_id:
          type: string
        session_id:
          type: string
        status:
          type: string
          enum:
            - queued
            - processing
            - completed
            - failed
            - cancelled
            - expired
        output_access:
          type: string
          enum:
            - bytes
            - signed_url
            - both
        generation_id:
          type: string
          nullable: true
        created_at:
          oneOf:
            - type: integer
            - type: string
        started_at:
          nullable: true
          oneOf:
            - type: integer
            - type: string
        completed_at:
          nullable: true
          oneOf:
            - type: integer
            - type: string
        object:
          type: string
          example: video
        poll_after_seconds:
          type: integer
          example: 20
        provider:
          type: string
        seconds:
          type: number
        size:
          type: string
        audio:
          type: boolean
        content_url:
          type: string
          description: Present when output_access includes bytes (authenticated endpoint).
        download_url:
          type: string
          nullable: true
          description: Signed first-party URL for direct download when status is completed.
        expires_at:
          type: integer
          nullable: true
          description: Unix timestamp (seconds) when the signed download_url expires.
        progress:
          type: integer
          nullable: true
        progress_source:
          type: string
        asset:
          type: object
          nullable: true
          properties:
            id:
              type: string
            mime_type:
              type: string
            bytes:
              type: integer
            sha256:
              type: string
            width:
              type: integer
            height:
              type: integer
            duration_seconds:
              type: number
        outputs:
          type: array
          items:
            $ref: '#/components/schemas/VideoOutput'
        billing:
          type: object
          additionalProperties: true
        usage:
          type: object
          properties:
            cost:
              type: number
            is_byok:
              type: boolean
          additionalProperties: true
        error:
          nullable: true
    VideoOutput:
      type: object
      properties:
        index:
          type: integer
        mime_type:
          type: string
        bytes_available:
          type: boolean
        content_url:
          type: string
          description: Present when output_access includes bytes.
        download_url:
          type: string
          description: Signed first-party URL for this output.
        expires_at:
          type: integer
          description: Unix timestamp (seconds) when this output URL expires.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: Bearer token authentication

````