Mirage Meta Text Overlays API

The Meta Text Overlays API from Mirage — 2 operation(s) for meta text overlays.

OpenAPI Specification

mirage-meta-text-overlays-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Mirage Video Audio Meta Text Overlays API
  description: API for AI-powered video generation
  version: 0.0.1
tags:
- name: Meta Text Overlays
paths:
  /v1/meta/text_overlays:
    post:
      tags:
      - Meta Text Overlays
      summary: Create Meta Text Overlay
      operationId: create_meta_text_overlay_v1_meta_text_overlays_post
      parameters:
      - name: x-api-key
        in: header
        required: true
        schema:
          type: string
          description: API Key for authentication
          title: X-Api-Key
        description: API Key for authentication
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/Body_create_meta_text_overlay_v1_meta_text_overlays_post'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MetaTextOverlay'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /v1/meta/text_overlays/{text_overlay_id}:
    get:
      tags:
      - Meta Text Overlays
      summary: Retrieve Meta Text Overlay
      operationId: get_meta_text_overlay_v1_meta_text_overlays__text_overlay_id__get
      parameters:
      - name: text_overlay_id
        in: path
        required: true
        schema:
          type: string
          title: Text Overlay Id
      - name: x-api-key
        in: header
        required: true
        schema:
          type: string
          description: API Key for authentication
          title: X-Api-Key
        description: API Key for authentication
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MetaTextOverlay'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
            - type: string
            - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
      - loc
      - msg
      - type
      title: ValidationError
    Body_create_meta_text_overlay_v1_meta_text_overlays_post:
      properties:
        video:
          type: string
          contentMediaType: application/octet-stream
          title: Video
          description: Source video file (MP4 or MOV). Upload once and render up to 4 related text variants against the same input video.
        texts:
          anyOf:
          - items:
              type: string
            type: array
          - type: 'null'
          title: Texts
          description: Ordered text variants to render as static overlays for the uploaded video (max 4).
        items:
          anyOf:
          - type: string
          - type: 'null'
          title: Items
          description: Optional JSON array of item objects. Each item must contain text and may contain style.font, style.size, and style.color.
        fonts:
          anyOf:
          - items:
              type: string
            type: array
          - type: 'null'
          title: Fonts
          description: Optional ordered font overrides aligned by index with texts. Blank items mean auto-decide.
        sizes:
          anyOf:
          - items:
              type: string
            type: array
          - type: 'null'
          title: Sizes
          description: Optional ordered font size overrides in pixels aligned by index with texts. Blank items mean auto-decide.
        colors:
          anyOf:
          - items:
              type: string
            type: array
          - type: 'null'
          title: Colors
          description: Optional ordered text color overrides (#RRGGBB) aligned by index with texts. Blank items mean auto-decide.
      type: object
      required:
      - video
      title: Body_create_meta_text_overlay_v1_meta_text_overlays_post
    MetaTextOverlay:
      properties:
        id:
          type: string
          title: Id
          description: Text overlay job ID
        object:
          type: string
          const: text_overlay
          title: Object
          default: text_overlay
        status:
          type: string
          enum:
          - QUEUED
          - PROCESSING
          - COMPLETE
          - FAILED
          - CANCELLED
          title: Status
          description: Current state of the text overlay job
        created_at:
          type: integer
          title: Created At
          description: When the job was created (unix timestamp)
        completed_at:
          anyOf:
          - type: integer
          - type: 'null'
          title: Completed At
          description: When processing reached a terminal state (unix timestamp)
        results:
          items:
            $ref: '#/components/schemas/MetaTextOverlayResult'
          type: array
          title: Results
          description: Ordered per-text render results for this job
        error:
          anyOf:
          - $ref: '#/components/schemas/MAVideoError'
          - type: 'null'
          description: Error details if the job failed before itemized completion
      type: object
      required:
      - id
      - status
      - created_at
      title: MetaTextOverlay
      description: Represents a Meta text overlay job.
      examples:
      - created_at: 1730822400
        id: d7f76ec6-2500-4d23-a2bc-648f4e904555
        object: text_overlay
        results: []
        status: QUEUED
    MAVideoError:
      properties:
        code:
          type: string
          title: Code
          description: Error code
          examples:
          - rate_limit_exceeded
        message:
          type: string
          title: Message
          description: Error message
          examples:
          - Rate limit exceeded. Please try again later.
      type: object
      required:
      - code
      - message
      title: MAVideoError
      description: Error payload that explains why generation failed, if applicable
    MetaTextOverlayResult:
      properties:
        index:
          type: integer
          title: Index
          description: Zero-based index matching the input texts order
        text:
          type: string
          title: Text
          description: Input text for this rendered output
        status:
          type: string
          enum:
          - COMPLETE
          - FAILED
          title: Status
          description: Terminal status for this item
        video_url:
          anyOf:
          - type: string
          - type: 'null'
          title: Video Url
          description: Resolved output video URL when this item completed successfully
        error:
          anyOf:
          - $ref: '#/components/schemas/MAVideoError'
          - type: 'null'
          description: Error details when this item failed
      type: object
      required:
      - index
      - text
      - status
      title: MetaTextOverlayResult
      description: Per-text result for a Meta text overlay job.