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

# Grok Text-to-Video

> Generate videos from text using xAI Grok model (async)

Generate short videos from text using [xAI](https://x.ai)'s Grok Imagine model.

**Key Features:**

* **Ultra-Fast Generation** - Complete video generation within 15 seconds, faster than Sora 2
* **Audio-Video Sync** - Native integrated audio generation with automatic sound effects and background music
* **Smooth Motion** - 24fps smooth framerate with no distortion in complex movements
* **Smart Camera Work** - Dynamic camera effects and intelligent focus shifting


## OpenAPI

````yaml /en/openapi.yaml POST /generate/k/grok-text-to-video
openapi: 3.0.0
info:
  contact:
    email: support@sinancode.com
    name: API Support
    url: https://sinancode.com/support
  description: AI Model Task Scheduling Platform API
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
  termsOfService: https://sinancode.com/terms-of-service
  title: TikTomato API
  version: '1.0'
servers:
  - url: https://api.sinancode.com/v1
    description: Production server
security: []
paths:
  /generate/k/grok-text-to-video:
    post:
      tags:
        - public
      summary: Grok Text-to-Video
      description: Generate videos from text using xAI Grok model (async)
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ka.CreateGrokTextToVideoTaskRequest'
        description: Task parameters
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/dto.CreateTaskResponse'
        '400':
          description: Invalid parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
        '500':
          description: Server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apierror.ErrorResponse'
      security:
        - AccessToken: []
components:
  schemas:
    ka.CreateGrokTextToVideoTaskRequest:
      properties:
        aspect_ratio:
          default: '2:3'
          description: aspect ratio（optional，default 2:3）
          enum:
            - '2:3'
            - '3:2'
            - '1:1'
          example: '2:3'
          type: string
        mode:
          default: normal
          description: Mode (optional, default normal)
          enum:
            - fun
            - normal
            - spicy
          example: normal
          type: string
        prompt:
          description: prompt（required）
          example: A cat playing with a ball in slow motion
          maxLength: 5000
          minLength: 1
          type: string
      required:
        - prompt
      type: object
    dto.CreateTaskResponse:
      properties:
        task_id:
          description: Task ID
          example: 01234567-89ab-cdef-0123-456789abcdef
          type: string
      required:
        - task_id
      type: object
    apierror.ErrorResponse:
      properties:
        error_code:
          description: Machine-readable error code (e.g., TASK.INVALID_PARAMS)
          type: string
        message:
          description: User-friendly error message
          type: string
      type: object
  securitySchemes:
    AccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Please use your API Token for authentication

````