Generate music from a text prompt

Table of contents

June 24, 2026

  1. Model Comparison Matrix
  2. Output modes
  3. Request Headers
  4. Request Body
  5. Parameters
  6. Responses
  7. Model
  8. Examples
  9. Try It

Use a pixverse.ai account to generate music. A prompt describes the track, and you can produce three kinds of output β€” an instrumental, a vocal track with model-written lyrics, or a vocal track with your own lyrics.

Generation is asynchronous. The call returns an audio_id immediately, then poll GET music/audio_id until audio_status_final is true, or pass a replyUrl to receive the result by callback.

Model Comparison Matrix
Model Prompt max Custom lyrics Reference images PixVerse
Credits / Cost
Provider cost*
MiniMax
music-2.6 (default)
2,000 yes, up to 3,500 chars β€” 40 cr / $0.16 ~$0.15 / track (≀5 min)
ElevenLabs
music-v1
4,000 yes, up to 3,500 chars β€” 150 cr / $0.60 $0.15-$0.18 / min β†’ ~$0.60-$0.90
Google Lyria
lyria-3-pro-preview
5,000 β€” 1-10 via image_path_1…10 20 cr / $0.08 $0.08 / song (up to 3 min)

PixVerse cost is for a $60/m Premium plan ($0.004 per credit, as of June 2026) β€” use the cost calculator for other plans. *Provider cost is going direct to the model’s own provider; prices change, check their pages.

All models generate at an automatic duration (the model chooses the length, typically 2-5 minutes). lyria-3-pro-preview does not accept custom lyrics, but it can still produce vocals with model-written lyrics β€” see instrumental and lyrics below.

Lyria 3 Pro is also available through Flow Music, which runs the same model at a lower price with many more features β€” cover and restyle, lyrics-adjust remix, extend and replace, and audio effects.

Output modes

The output is determined by instrumental and lyrics β€” there is no separate auto_lyrics flag, it is derived:

Request Result
instrumental: true instrumental, no vocals
lyrics provided vocals sung from your lyrics (music-2.6 / music-v1 only)
neither vocals with lyrics written by the model

To retrieve generated music, use:

To cancel a track that is still generating, use DEL scheduler/id.

https://api.useapi.net/v2/pixverse/music/create

Request Headers
Authorization: Bearer {API token}
Content-Type: application/json
# Alternatively you can use multipart/form-data
# Content-Type: multipart/form-data
Request Body
{
    "email": "Optional PixVerse API account email",
    "prompt": "Required text prompt",
    "model": "music-2.6",
    "instrumental": false,
    "lyrics": "Optional custom lyrics",
    "image_path_1": "upload/eb20c63d-2a1a-5be6-a562-d3578a2831e3.png",
    "replyUrl": "Place your call back URL here",
    "replyRef": "Place your reference id here",
    "maxJobs": 3
}
Parameters
  • email is optional, if not specified API will randomly select account from available accounts.

  • prompt is required, describe the track you want. Maximum length is model-specific β€” music-2.6 2,000, music-v1 4,000, lyria-3-pro-preview 5,000 characters.

  • model is optional. Default: music-2.6. See Model Comparison Matrix for the full list.

  • instrumental is optional, default false. When true the track has no vocals. Cannot be combined with lyrics.

  • lyrics is optional and supported by music-2.6 and music-v1 only β€” providing it on lyria-3-pro-preview is rejected with 400. The vocals are sung from the text you supply. Cannot be combined with instrumental. Maximum length 3,500 characters.

  • image_path_1 through image_path_10 are optional and supported by lyria-3-pro-preview only. Reference image file paths uploaded via POST files that condition the music. Reference images must be provided sequentially β€” image_path_2 requires image_path_1, etc.

  • replyUrl is optional, place here your callback URL. This is the preferred and most optimal way to receive results quickly β€” the API polls every 10 seconds and will call the provided replyUrl once the track is completed or failed. We recommend using sites like webhook.site to test callback URL functionality. Maximum length 1024 characters. Callback body has the same JSON shape as GET music/audio_id response.

  • replyRef is optional, place here your reference id which will be stored and returned along with this music response / result. Maximum length 1024 characters.

  • maxJobs is optional, if not specified value from selected accounts/email will be used. It should not exceed the number of concurrent generations supported by your account subscription plan. Valid range: 1…8

Responses
  • 200 OK

    Use the returned audio_id to retrieve status and results using GET music/audio_id. Check audio_status_name for COMPLETED and url for the generated .mp3 link.

    If you specify the optional parameter replyUrl, the API will call the provided replyUrl with progress updates until the track is complete or fails.

    {
        "audio_id": "user:<userid>-pixverse:<email>-music:<number>",
        "asset_id": 409848161653065,
        "asset_type": 2,
        "asset_source": 1,
        "create_mode": "music",
        "status": "making",
        "audio_status": 5,
        "credits": 40,
        "audio_status_name": "QUEUED",
        "audio_status_final": false
    }
    
  • 400 Bad Request

    Returned when a parameter is invalid, for example a prompt longer than the model allows, lyrics on lyria-3-pro-preview, or lyrics combined with instrumental.

    {
      "error": "<Error message>",
      "code": 400
    }
    
  • 401 Unauthorized

    {
      "error": "Unauthorized"
    }
    
  • 412 Insufficient credits

    Insufficient credits. All Credits have been used up. Please upgrade your membership or purchase credits.

    {
      "error": "All Credits have been used up. Please upgrade your membership or purchase credits."
    }
    
  • 429 Too Many Requests

    Wait in a loop for at least 10..30 seconds and retry again.

    The API query is full and can not accept new music/create requests. Size of the query is defined by the maxJobs optional parameter.

    {
        "error":
          "Account <email> is busy executing <maxJobs> tasks."
          "All configured accounts are running at maximum capacity."
    }
    
  • 596 Pending mod message

    Your PixVerse.ai account has a pending error. Most likely, you changed your account password or your PixVerse.ai account was placed on hold. Once the issue is resolved, update your account to clear the error by executing POST accounts/email before making any new API calls.

    {
      "error":
        "Your PixVerse account has pending error."
        "Please address this issue at https://useapi.net/docs/api-pixverse-v2/post-pixverse-accounts-email before making any new API calls."
    }
    
Model
{ // TypeScript, all fields are optional
    audio_id: string
    asset_id: number
    asset_type: number
    asset_source: number
    create_mode: string
    status: string
    audio_status: number
    credits: number
    error: string
    code: number
    // added
    audio_status_name: string
    audio_status_final: boolean
}
Examples
  • curl -H "Accept: application/json" \
         -H "Content-Type: application/json" \
         -H "Authorization: Bearer …" \
         -X POST "https://api.useapi.net/v2/pixverse/music/create" \
         -d '{"prompt": "An upbeat synthwave track with a clear female vocal"}'
    
  • const prompt = "An upbeat synthwave track with a clear female vocal";
    const apiUrl = `https://api.useapi.net/v2/pixverse/music/create`;
    const token = "API token";
    const data = {
      method: 'POST',
      headers: {
        'Authorization': `Bearer ${token}`,
        'Content-Type': 'application/json' }
    };
    data.body = JSON.stringify({
      prompt
    });
    const response = await fetch(apiUrl, data);
    const result = await response.json();
    console.log("response", {response, result});
    
  • import requests
    prompt = "An upbeat synthwave track with a clear female vocal"
    apiUrl = f"https://api.useapi.net/v2/pixverse/music/create"
    token = "API token"
    headers = {
        "Content-Type": "application/json",
        "Authorization" : f"Bearer {token}"
    }
    body = {
        "prompt": f"{prompt}"
    }
    response = requests.post(apiUrl, headers=headers, json=body)
    print(response, response.json())
    
Try It