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

# Video Download

> Returns a video generation task by id.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/videos/{id}
openapi: 3.1.0
info:
  title: Octen API
  description: >-
    Octen API provides Broad Search, Web Search, Image Search, Video Search,
    Extract, Embeddings, VL Embeddings, Answer, and Deep Research services. The
    Web Search API searches ranked web results with optional filters,
    highlights, and full content. The Image Search API searches for images from
    a text query or an image, with an optional design mode that returns a
    structured summary and a reusable HTML snippet for each result. The Video
    Search API searches for videos from a text query. The Broad Search API
    decomposes a query into multiple sub-queries, searches them in parallel, and
    returns results grouped by sub-query. The Extract API extracts clean content
    from URLs, with optional query-focused highlights, page classification, and
    multimedia resources. The Embeddings API converts text into vector
    representations. The VL Embeddings API converts multimodal inputs into
    vector representations. The Answer API decomposes queries into multiple
    sub-queries for comprehensive search and synthesis. The Deep Research API
    runs a multi-round adaptive research pipeline that produces a structured
    research plan, executes iterative searches, and streams a final long-form
    report.
  version: 1.0.0
servers:
  - url: https://api.octen.ai
security:
  - bearerAuth: []
  - apiKeyAuth: []
paths:
  /v1/videos/{id}:
    get:
      summary: Download a video
      description: Returns a video generation task by id.
      operationId: get-video
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          example: video-1756789012-abc123
          description: The task id returned by the Video Generation API.
      responses:
        '200':
          description: Successful video task response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VideoTask'
        '401':
          description: Invalid API Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Video task not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
        '429':
          description: Exceeding the rate limit
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
        '500':
          description: Internal error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
components:
  schemas:
    VideoTask:
      type: object
      required:
        - id
        - model
        - status
        - created
      properties:
        id:
          type: string
          description: Unique task id, used to download the video.
        model:
          type: string
          description: The model used for this task.
        status:
          type: string
          enum:
            - queued
            - in_progress
            - completed
            - failed
          description: Task state.
        created:
          type: integer
          description: Unix timestamp in seconds when the task was created.
        video_url:
          type: string
          description: >-
            Signed download URL for the video file, present when `status` is
            `completed`. Valid for 7 days after generation.
        expires_at:
          type: integer
          description: >-
            Unix timestamp in seconds when `video_url` expires. Present when
            `status` is `completed`.
        duration:
          type: integer
          description: >-
            Length of the generated video in seconds. Present when `status` is
            `completed`.
        resolution:
          type: string
          description: >-
            Resolution of the generated video. Present when `status` is
            `completed`.
        usage:
          $ref: '#/components/schemas/VideoUsage'
        error:
          type: string
          description: Failure reason, present when `status` is `failed`.
        code:
          type: string
          description: Machine-readable failure code, present when `status` is `failed`.
    ErrorResponse:
      type: object
      properties:
        code:
          type: integer
          description: Business status code. Non-zero values indicate an error.
        msg:
          type: string
          description: A message describing the error.
        request_id:
          type: string
          description: Unique identifier for the request.
      required:
        - code
        - msg
        - request_id
    OpenAIErrorResponse:
      type: object
      description: Error body in the OpenAI protocol format.
      required:
        - error
      properties:
        error:
          type: object
          properties:
            message:
              type: string
              description: A human-readable description of the error.
            type:
              type: string
              description: The error category, e.g. `invalid_request_error`.
            param:
              type: string
              nullable: true
              description: The parameter related to the error, if any.
            code:
              type: string
              nullable: true
              description: A machine-readable error code, if any.
          required:
            - message
            - type
    VideoUsage:
      type: object
      description: Metering for the task. Present only when `status` is `completed`.
      properties:
        video_seconds:
          type: integer
          description: Video length in seconds.
        video_tokens:
          type: integer
          description: Billed token count.
        input_image_count:
          type: integer
          description: Number of input images, returned when images were supplied.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer token used for request authentication. Alternatively, you can
        send the API key in the `x-api-key` header. Note: A payment method is
        required to use the API.
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key used for request authentication. Alternatively, you can send the
        key as a Bearer token in the `Authorization` header. Note: A payment
        method is required to use the API.

````