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

# Generate Media

> Create a personalized video generation request in real-time



## OpenAPI

````yaml POST /media/demo
openapi: 3.0.1
info:
  title: Charp.ai API
  description: >-
    API ecosystem for vendor management, authentication, campaign management,
    and tools for enhancing campaign execution including realtime media
    generation
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://whilter-api-host
security:
  - bearerAuth: []
tags:
  - name: Authentication
    description: Operations related to API authentication
  - name: Realtime Media
    description: Operations for generating personalized videos in real-time
  - name: Webhooks
    description: Webhook endpoints for receiving notifications
  - name: Virtual Try-On
    description: Operations related to virtual try-on functionality
  - name: Tasks
    description: Operations related to task management
paths:
  /media/demo:
    post:
      tags:
        - Realtime Media
      summary: Trigger New Video Generation
      description: Create a personalized video generation request in real-time
      operationId: createVideoRequest
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/VideoGenerationRequest'
      responses:
        '200':
          description: Video generation request accepted
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VideoGenerationResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    VideoGenerationRequest:
      type: object
      properties:
        client-request-id:
          type: string
          description: Unique identifier for the client request
        customer-id:
          type: string
          description: Customer identifier
        use-case-id:
          type: string
          description: Template identifier for the video generation use case
        user-id:
          type: string
          description: User identifier
        reference-record-id:
          type: string
          description: Optional reference record identifier
        data:
          type: object
          description: >-
            Media generation data containing assets, cohorts, personalization
            fields, and frame segments
          properties:
            global_assets:
              type: object
              description: Global media assets used across the generation
              properties:
                images:
                  type: array
                  items:
                    type: string
                  description: Array of image asset URLs
                videos:
                  type: array
                  items:
                    type: string
                  description: Array of video asset URLs
                icons:
                  type: array
                  items:
                    type: string
                  description: Array of icon asset URLs
            global_cohorts:
              type: array
              items:
                type: object
              description: Array of global cohort configurations
            personalization_fields:
              type: object
              additionalProperties:
                type: string
              description: Key-value pairs for personalizing the generated media
            frame_segments:
              type: array
              items:
                type: object
              description: Array of frame segment configurations
      required:
        - client-request-id
        - customer-id
        - use-case-id
        - user-id
        - data
    VideoGenerationResponse:
      type: object
      properties:
        status:
          type: string
          enum:
            - SUCCESS
            - FAILURE
          description: Status of the video generation request
        message:
          type: string
          description: Response message
          example: Request accepted
        client-request-id:
          type: string
          description: The original client request identifier
        whilter-request-id:
          type: string
          description: Generated request identifier for tracking
      required:
        - status
        - message
        - client-request-id
        - whilter-request-id
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````