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

# MiniMax Music 2.6

> The MiniMax Music 2.6 API generates a complete track from a style prompt, using supplied lyrics, lyrics generated from the prompt, or instrumental-only mode. Audio can be returned as MP3, WAV, or PCM at the documented sample rates and bitrates.

> [!TIP]
>
> 1. After submission, a `task_id` will be returned. If you provided a `callback_url`, when the task status becomes `finished` or `failed`, a POST request will be sent to the `callback_url`.
> 2. Regardless of whether `callback_url` is provided, you can retrieve the result through the unified [Query Task Status](https://docs.poyo.ai/api-manual/task-management/status.md) endpoint.

## Models

* **minimax-music-2.6** — MiniMax Music 2.6

## Features

* This endpoint generates complete tracks with singing, backing music, and detailed arrangements from a style prompt
* You can provide custom lyrics, let the model optimize lyrics from the prompt, or enable instrumental mode for music without vocals
* Final results are returned asynchronously through `callback_url` or [Query Task Status](https://docs.poyo.ai/api-manual/task-management/status.md)

## Required parameters

* `prompt` (required): Music prompt describing style, mood, genre, instrumentation, tempo, or scene
  * Length: `10-2000` characters
  * Be specific about the musical direction you want in the final track

## Optional parameters

* `lyrics`: Optional lyrics content for vocal generation
  * Required unless `is_instrumental` or `lyrics_optimizer` is `true`
  * Maximum length: `3500` characters

* `lyrics_optimizer`: Optional boolean
  * When `true` and `lyrics` is empty, the model auto-generates lyrics from the `prompt`
  * Use this when you want a vocal song but do not want to provide exact lyrics

* `is_instrumental`: Optional boolean
  * Set to `true` to generate instrumental-only music without vocals
  * When `true`, omit `lyrics` and do not enable `lyrics_optimizer`

* `audio_setting`: Optional output audio settings object
  * `sample_rate`: `16000`, `24000`, `32000`, `44100`
  * `bitrate`: `32000`, `64000`, `128000`, `256000`
  * `format`: `mp3`, `wav`, `pcm`
  * Only these three keys are supported

## Notes

* If both `is_instrumental` and `lyrics_optimizer` are `false`, provide `lyrics` to avoid validation errors
* `lyrics_optimizer` follows the upstream MiniMax Music 2.6 schema. If the upstream service rejects an optimized-lyrics request, retry with explicit `lyrics`
* Query status through the standard task status API, not the music detail endpoint
* Successful responses return `files`, where the generated music uses `file_type: audio`


## OpenAPI

````yaml api-manual/music-series/minimax-music-2.6.json POST /api/generate/submit
openapi: 3.0.0
info:
  title: PoYo AI - MiniMax Music 2.6 API
  description: >-
    The MiniMax Music 2.6 API generates a complete track from a style prompt,
    using supplied lyrics, lyrics generated from the prompt, or
    instrumental-only mode. Audio can be returned as MP3, WAV, or PCM at the
    documented sample rates and bitrates.
  version: 1.0.0
servers:
  - url: https://api.poyo.ai
    description: Production server
security:
  - BearerAuth: []
paths:
  /api/generate/submit:
    post:
      tags:
        - MiniMax Music 2.6
      summary: Submit MiniMax Music 2.6 Task
      description: >-
        Generate a complete music track from a style prompt, optional lyrics,
        lyrics optimization, or instrumental mode.
      operationId: submitMiniMaxMusic26Task
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SubmitRequest'
            examples:
              vocal-track:
                summary: Vocal music generation with lyrics
                value:
                  model: minimax-music-2.6
                  callback_url: https://your-domain.com/callback
                  input:
                    prompt: >-
                      City pop, 80s retro, groovy synth bass, warm female vocal,
                      nostalgic night drive
                    lyrics: |-
                      [Verse]
                      Streetlights flicker in the rearview glow
                      [Chorus]
                      We keep driving where the midnight winds blow
                    is_instrumental: false
                    audio_setting:
                      sample_rate: 44100
                      bitrate: 256000
                      format: mp3
              lyrics-optimize:
                summary: Vocal music generation with lyrics optimization
                value:
                  model: minimax-music-2.6
                  callback_url: https://your-domain.com/callback
                  input:
                    prompt: >-
                      Modern cinematic pop ballad, emotional male vocal, piano
                      intro, wide chorus, 92 BPM
                    lyrics_optimizer: true
                    is_instrumental: false
                    audio_setting:
                      sample_rate: 44100
                      bitrate: 256000
                      format: mp3
              instrumental-track:
                summary: Instrumental music generation
                value:
                  model: minimax-music-2.6
                  callback_url: https://your-domain.com/callback
                  input:
                    prompt: >-
                      Minimal piano and soft strings for a quiet sunrise over
                      the ocean
                    is_instrumental: true
                    audio_setting:
                      sample_rate: 32000
                      bitrate: 128000
                      format: wav
      responses:
        '200':
          description: Task submitted successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubmitResponse'
              examples:
                submitted:
                  summary: Submitted task
                  value:
                    code: 200
                    data:
                      task_id: task-unified-1757165031-uyujaw3d
                      status: not_started
                      created_time: '2026-04-15T10:30:00'
        '400':
          description: Invalid request parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized - Invalid API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    SubmitRequest:
      type: object
      required:
        - model
        - input
      properties:
        model:
          type: string
          description: |-
            Model identifier.

            Must be `minimax-music-2.6` for this endpoint.
          enum:
            - minimax-music-2.6
          example: minimax-music-2.6
        callback_url:
          type: string
          format: uri
          description: Webhook callback URL for result notifications
          example: https://your-domain.com/callback
        input:
          type: object
          required:
            - prompt
          description: >-
            Input parameters for music generation. If `lyrics` is empty, set
            either `is_instrumental` or `lyrics_optimizer` to `true`.
          additionalProperties: false
          properties:
            prompt:
              type: string
              description: >-
                Required music prompt describing style, mood, genre,
                instrumentation, tempo, vocal direction, or scene.
              minLength: 10
              maxLength: 2000
              example: >-
                City pop, 80s retro, groovy synth bass, warm female vocal,
                nostalgic night drive
            lyrics:
              type: string
              description: >-
                Optional lyrics for vocal generation. Required unless
                `is_instrumental` or `lyrics_optimizer` is `true`.
              maxLength: 3500
              example: |-
                [Verse]
                Streetlights flicker in the rearview glow
                [Chorus]
                We keep driving where the midnight winds blow
            lyrics_optimizer:
              type: boolean
              description: >-
                When `true` and `lyrics` is empty, the model auto-generates
                lyrics from the prompt.
              default: false
              example: true
            is_instrumental:
              type: boolean
              description: When `true`, generates instrumental-only music without vocals.
              default: false
              example: false
            audio_setting:
              type: object
              description: >-
                Optional audio output settings. Only `sample_rate`, `bitrate`,
                and `format` are supported.
              additionalProperties: false
              properties:
                sample_rate:
                  type: integer
                  description: Output sample rate.
                  enum:
                    - 16000
                    - 24000
                    - 32000
                    - 44100
                  default: 44100
                  example: 44100
                bitrate:
                  type: integer
                  description: Output bitrate.
                  enum:
                    - 32000
                    - 64000
                    - 128000
                    - 256000
                  default: 256000
                  example: 256000
                format:
                  type: string
                  description: Output audio format.
                  enum:
                    - mp3
                    - wav
                    - pcm
                  default: mp3
                  example: mp3
    SubmitResponse:
      type: object
      required:
        - code
        - data
      properties:
        code:
          type: integer
          example: 200
          description: >-
            Business status code. `200` means success; any other value means the
            request failed. Always check this field: some validation errors
            return HTTP 200 with `code: 400` in the body.


            - `200`: Success

            - `400`: Invalid request parameters

            - `401`: Missing or invalid API key

            - `402`: Insufficient credits

            - `403`: Permission denied

            - `404`: Resource not found

            - `408`: Request timeout

            - `429`: Rate limit exceeded

            - `500`: Internal server error

            - `502`: Upstream service error

            - `503`: Service unavailable


            See [Error Codes](/api-manual/error-codes) for details.
          enum:
            - 200
            - 400
            - 401
            - 402
            - 403
            - 404
            - 408
            - 429
            - 500
            - 502
            - 503
        data:
          type: object
          required:
            - task_id
            - status
            - created_time
          properties:
            task_id:
              type: string
              example: task-unified-1757165031-uyujaw3d
              description: Unique task identifier for status tracking
            status:
              type: string
              enum:
                - not_started
                - running
                - finished
                - failed
              example: not_started
              description: >-
                Task status. Always `not_started` right after submission. Use
                [Query Task Status](/api-manual/task-management/status) or
                `callback_url` to get later states.


                - `not_started`: Queued, waiting to be processed

                - `running`: Being generated

                - `finished`: Completed; results are in `files` or `output`

                - `failed`: Failed; details are in `error_message`
            created_time:
              type: string
              format: date-time
              example: '2026-04-15T10:30:00'
              description: ISO 8601 timestamp when the task was created
    ErrorResponse:
      type: object
      required:
        - code
        - error
      properties:
        code:
          type: integer
          example: 400
          enum:
            - 200
            - 400
            - 401
            - 402
            - 403
            - 404
            - 408
            - 429
            - 500
            - 502
            - 503
          description: >-
            Business status code. `200` means success; any other value means the
            request failed. Always check this field: some validation errors
            return HTTP 200 with `code: 400` in the body.


            - `200`: Success

            - `400`: Invalid request parameters

            - `401`: Missing or invalid API key

            - `402`: Insufficient credits

            - `403`: Permission denied

            - `404`: Resource not found

            - `408`: Request timeout

            - `429`: Rate limit exceeded

            - `500`: Internal server error

            - `502`: Upstream service error

            - `503`: Service unavailable


            See [Error Codes](/api-manual/error-codes) for details.
        error:
          type: object
          required:
            - message
            - type
          properties:
            message:
              type: string
              example: Invalid request parameters
            type:
              type: string
              example: invalid_request_error
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        All API endpoints require Bearer Token authentication.


        Create an API key: sign in to PoYo, open **Dashboard → API Key** at
        [poyo.ai/dashboard/api-key](https://poyo.ai/dashboard/api-key), and
        click to create a key.


        Add it to the request header:


        ```

        Authorization: Bearer YOUR_API_KEY

        ```

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.