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

# Kling-V3 Text to Video

> - Kling-V3 Text to Video (kling-v3-text-to-video) model supports text-to-video generation
- Supports single-shot and multi-shot modes, capable of generating videos with sound effects
- Asynchronous processing mode, use the returned task ID to [query status](/en/api-manual/task-management/get-task-detail)
- Generated video links are valid for 24 hours, please save them promptly



## OpenAPI

````yaml en/api-manual/video-series/kling/kling-v3-text-to-video.json post /v1/videos/generations
openapi: 3.1.0
info:
  title: kling-v3-text-to-video API
  description: Create text-to-video tasks using AI models
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.evolink.ai
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Video Generation
    description: AI video generation APIs
paths:
  /v1/videos/generations:
    post:
      tags:
        - Video Generation
      summary: kling-v3-text-to-video API
      description: >-
        - Kling-V3 Text to Video (kling-v3-text-to-video) model supports
        text-to-video generation

        - Supports single-shot and multi-shot modes, capable of generating
        videos with sound effects

        - Asynchronous processing mode, use the returned task ID to [query
        status](/en/api-manual/task-management/get-task-detail)

        - Generated video links are valid for 24 hours, please save them
        promptly
      operationId: createVideoGeneration
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/VideoGenerationRequest'
            examples:
              basic:
                summary: Basic Text to Video
                value:
                  model: kling-v3-text-to-video
                  prompt: A cat running on a grass field under bright sunshine
                  duration: 5
                  aspect_ratio: '16:9'
                  quality: 720p
              pro_with_sound:
                summary: 1080P with Sound Effects
                value:
                  model: kling-v3-text-to-video
                  prompt: >-
                    Waves crashing against rocks during a thunderstorm, thunder
                    rumbling
                  duration: 10
                  aspect_ratio: '16:9'
                  quality: 1080p
                  sound: 'on'
              multi_shot:
                summary: Multi-shot (Custom Segmentation)
                value:
                  model: kling-v3-text-to-video
                  duration: 10
                  aspect_ratio: '16:9'
                  quality: 1080p
                  sound: 'on'
                  model_params:
                    multi_shot: true
                    shot_type: customize
                    multi_prompt:
                      - index: 1
                        prompt: >-
                          A person standing on a mountaintop gazing at the
                          sunrise
                        duration: '5'
                      - index: 2
                        prompt: >-
                          Camera pulls back to reveal the magnificent mountain
                          landscape
                        duration: '5'
              negative_prompt:
                summary: With Negative Prompt
                value:
                  model: kling-v3-text-to-video
                  prompt: A serene lake with mountains in the distance
                  negative_prompt: people, text, watermark
                  duration: 5
                  aspect_ratio: '16:9'
                  quality: 1080p
      responses:
        '200':
          description: Video generation task created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VideoGenerationResponse'
        '400':
          description: Invalid request parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: invalid_request
                  message: Invalid request parameters
                  type: invalid_request_error
        '401':
          description: Unauthenticated, token is invalid or expired
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: unauthorized
                  message: Invalid or expired token
                  type: authentication_error
        '402':
          description: Insufficient quota, top-up required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: insufficient_quota
                  message: Insufficient quota. Please top up your account.
                  type: insufficient_quota
        '403':
          description: Access denied
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: model_access_denied
                  message: 'Token does not have access to model: kling-v3-text-to-video'
                  type: invalid_request_error
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: rate_limit_exceeded
                  message: Too many requests, please try again later
                  type: rate_limit_error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: internal_error
                  message: Internal server error
                  type: api_error
components:
  schemas:
    VideoGenerationRequest:
      type: object
      required:
        - model
        - prompt
      properties:
        model:
          type: string
          description: Video generation model name
          enum:
            - kling-v3-text-to-video
          default: kling-v3-text-to-video
          example: kling-v3-text-to-video
        prompt:
          type: string
          description: >-
            Text prompt describing what video to generate


            **Note:**

            - Maximum `2500` characters

            - Can be empty when `multi_shot=true` and `shot_type=customize`
            (content provided by `multi_prompt`)

            - **Required** when `multi_shot=false` or `shot_type=intelligence`
          example: A cat running on a grass field under bright sunshine
          maxLength: 2500
        negative_prompt:
          type: string
          description: Negative prompt describing what should not appear in the video
          example: people, text, watermark
        duration:
          type: integer
          description: >-
            Video duration in seconds, defaults to `5` seconds


            **Note:**

            - Range: integer from `3` to `15`

            - Billing is based on the `duration` value, longer duration costs
            more
          minimum: 3
          maximum: 15
          default: 5
          example: 5
        aspect_ratio:
          type: string
          description: |-
            Video aspect ratio

            **Options:**
            - `16:9`: Landscape video
            - `9:16`: Portrait video
            - `1:1`: Square video
          enum:
            - '16:9'
            - '9:16'
            - '1:1'
          example: '16:9'
        quality:
          type: string
          description: |-
            Resolution quality

            **Options:**
            - `720p`: Standard quality (std)
            - `1080p`: High quality (pro)
          enum:
            - 720p
            - 1080p
          default: 720p
          example: 720p
        sound:
          type: string
          description: |-
            Sound effect control

            **Options:**
            - `on`: Generate sound effects
            - `off`: No sound effects
          enum:
            - 'on'
            - 'off'
          default: 'off'
          example: 'off'
        model_params:
          type: object
          description: Model extension parameters for multi-shot and watermark control
          properties:
            multi_shot:
              type: boolean
              description: >-
                Whether to use multi-shot mode


                **Options:**

                - `true`: Multi-shot mode, must be used with `shot_type`. When
                `shot_type=customize`, **the `prompt` parameter will be
                ignored** — use `multi_prompt` to define content for each shot
                instead; when `shot_type=intelligence`, `prompt` remains
                effective. **The sum of all shot `duration` values must equal
                the total video duration**

                - `false`: Single-shot mode (default)
              default: false
              example: false
            shot_type:
              type: string
              description: >-
                Shot segmentation method, **required** when `multi_shot=true`


                **Options:**

                - `customize`: Custom segmentation, requires `multi_prompt`

                - `intelligence`: Intelligent segmentation, model automatically
                segments shots
              enum:
                - customize
                - intelligence
              example: customize
            multi_prompt:
              type: array
              description: >-
                Shot information list, **required** when `multi_shot=true` and
                `shot_type=customize`


                **Note:**

                - Maximum `6` shots, minimum `1`

                - Each shot prompt supports up to `512` characters

                - Each shot duration must be >= 1 and <= total duration

                - **The sum of all shot durations must equal the total task
                duration**
              items:
                type: object
                properties:
                  index:
                    type: integer
                    description: Shot sequence number, starting from 1
                  prompt:
                    type: string
                    description: Text description for this shot
                    maxLength: 512
                  duration:
                    type: string
                    description: Duration of this shot (seconds)
                required:
                  - index
                  - prompt
                  - duration
              minItems: 1
              maxItems: 6
            watermark_info:
              type: object
              description: Watermark configuration
              properties:
                enabled:
                  type: boolean
                  description: Whether to enable watermark
        callback_url:
          type: string
          description: >-
            HTTPS callback URL for task completion


            **Callback Timing:**

            - Triggered when task is completed, failed, or cancelled

            - Sent after billing confirmation


            **Security Restrictions:**

            - HTTPS protocol only

            - Internal IP addresses are prohibited (127.0.0.1, 10.x.x.x,
            172.16-31.x.x, 192.168.x.x, etc.)

            - URL length must not exceed `2048` characters


            **Callback Mechanism:**

            - Timeout: `10` seconds

            - Maximum `3` retries after failure (at `1`/`2`/`4` seconds after
            failure)

            - Callback response format is consistent with task query API

            - 2xx status code is considered successful, other codes trigger
            retry
          format: uri
          example: https://your-domain.com/webhooks/video-task-completed
    VideoGenerationResponse:
      type: object
      properties:
        created:
          type: integer
          description: Task creation timestamp
          example: 1757169743
        id:
          type: string
          description: Task ID
          example: task-unified-1757169743-7cvnl5zw
        model:
          type: string
          description: Actual model name used
          example: kling-v3-text-to-video
        object:
          type: string
          enum:
            - video.generation.task
          description: Task type
        progress:
          type: integer
          description: Task progress percentage (0-100)
          minimum: 0
          maximum: 100
          example: 0
        status:
          type: string
          description: Task status
          enum:
            - pending
            - processing
            - completed
            - failed
          example: pending
        task_info:
          $ref: '#/components/schemas/VideoTaskInfo'
          description: Video task details
        type:
          type: string
          enum:
            - text
            - image
            - audio
            - video
          description: Task output type
          example: video
        usage:
          $ref: '#/components/schemas/VideoUsage'
          description: Usage and billing information
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              description: Error code identifier
            message:
              type: string
              description: Error description message
            type:
              type: string
              description: Error type
    VideoTaskInfo:
      type: object
      properties:
        can_cancel:
          type: boolean
          description: Whether the task can be cancelled
          example: true
        estimated_time:
          type: integer
          description: Estimated completion time (seconds)
          minimum: 0
          example: 300
        video_duration:
          type: integer
          description: Video duration (seconds)
          example: 5
    VideoUsage:
      type: object
      description: Usage and billing information
      properties:
        billing_rule:
          type: string
          description: Billing rule
          enum:
            - per_call
            - per_token
            - per_second
          example: per_second
        credits_reserved:
          type: number
          description: Estimated credits consumed
          minimum: 0
          example: 270000
        user_group:
          type: string
          description: User group category
          example: default
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        ## All APIs require Bearer Token authentication ##


        **Get API Key:**


        Visit [API Key Management Page](https://evolink.ai/dashboard/keys) to
        get your API Key


        **Add to request header:**

        ```

        Authorization: Bearer YOUR_API_KEY

        ```

````




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

# Query Task Status

> Query the status, progress, and result information of asynchronous tasks by task ID



## OpenAPI

````yaml en/api-manual/task-management/get-task-detail.json get /v1/tasks/{task_id}
openapi: 3.1.0
info:
  title: Get Task Details API
  description: >-
    Query the status, progress, and result information of asynchronous tasks by
    task ID
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.evolink.ai
    description: Production environment
security:
  - bearerAuth: []
tags:
  - name: Task Management
    description: Asynchronous task management related APIs
paths:
  /v1/tasks/{task_id}:
    get:
      tags:
        - Task Management
      summary: Query Task Status
      description: >-
        Query the status, progress, and result information of asynchronous tasks
        by task ID
      operationId: getTaskDetail
      parameters:
        - name: task_id
          in: path
          required: true
          schema:
            type: string
          description: >-
            Task ID, ignore {} when querying, append the id from the async task
            response body at the end of the path
          example: task-unified-1756817821-4x3rx6ny
      responses:
        '200':
          description: Task status details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskDetailResponse'
        '400':
          description: Request parameter error, format error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: invalid_task_id
                  message: Invalid task ID format, must start with 'task-unified-'
                  type: invalid_request_error
                  param: task_id
        '401':
          description: Unauthenticated, token invalid or expired
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: unauthorized
                  message: Authentication required
                  type: authentication_error
        '402':
          description: Insufficient quota, recharge required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: quota_exceeded
                  message: Insufficient quota. Please top up your account.
                  type: insufficient_quota
        '403':
          description: No permission to access
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: permission_denied
                  message: You don't have permission to access this task
                  type: invalid_request_error
        '404':
          description: Resource does not exist
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: task_not_found
                  message: The requested task could not be found
                  type: invalid_request_error
        '429':
          description: Request rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: rate_limit_exceeded
                  message: Rate limit exceeded
                  type: evo_api_error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: internal_error
                  message: Failed to retrieve task status
                  type: api_error
components:
  schemas:
    TaskDetailResponse:
      type: object
      properties:
        created:
          type: integer
          description: Task creation timestamp
          example: 1756817821
        id:
          type: string
          description: Task ID
          example: task-unified-1756817821-4x3rx6ny
        model:
          type: string
          description: Model used
          example: gemini-3.1-flash-image-preview
        object:
          type: string
          description: Task type
          enum:
            - image.generation.task
            - video.generation.task
            - audio.generation.task
          example: image.generation.task
        progress:
          type: integer
          minimum: 0
          maximum: 100
          description: Task progress percentage
          example: 100
        results:
          type: array
          items:
            type: string
            format: uri
          description: Task result list (provided when completed)
          example:
            - http://example.com/image.jpg
        status:
          type: string
          description: Task status
          enum:
            - pending
            - processing
            - completed
            - failed
          example: completed
        error:
          type: object
          nullable: true
          description: >-
            Error information when the task fails (only present when status is
            "failed"). Note: error.code here is a string-type business error
            code, different from HTTP status codes. See the Error Codes
            Reference for the complete list.
          properties:
            code:
              type: string
              description: Business error code (string type)
              example: content_policy_violation
            message:
              type: string
              description: User-friendly error description with troubleshooting tips
              example: |-
                Content policy violation.
                Your request was blocked by safety filters.
            type:
              type: string
              description: Error type identifier, always "task_error"
              example: task_error
        task_info:
          type: object
          description: Task detailed information
          properties:
            can_cancel:
              type: boolean
              description: Whether the task can be cancelled
              example: false
        type:
          type: string
          description: Task type
          enum:
            - image
            - video
            - audio
            - text
          example: image
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              description: Error code (string type)
              example: invalid_task_id
            message:
              type: string
              description: Error description message
              example: Invalid task ID format
            type:
              type: string
              description: Error type
              example: invalid_request_error
            param:
              type: string
              description: Related parameter name
              example: task_id
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        ##All APIs require Bearer Token authentication##


        **Get API Key:**


        Visit [API Key Management Page](https://evolink.ai/dashboard/keys) to
        get your API Key


        **Add to request header:**

        ```

        Authorization: Bearer YOUR_API_KEY

        ```

````
