AnyInt Docs
Media & Music

Music Tasks and Webhooks

Most AI Music routes are asynchronous. Your application should always store the returned taskId, keep polling as a fallback, and treat webhooks as the main completion signal.

Most AI Music routes are asynchronous. Your application should always store the returned taskId, keep polling as a fallback, and treat webhooks as the main completion signal.

Query routes

RoutePurpose
GET /suno/query/task?taskId={taskId}Song generation and cover tasks
GET /suno/query/lyrics?taskId={taskId}Lyrics tasks
GET /suno/query/vocal-removal?taskId={taskId}Stem or vocal-removal tasks
GET /suno/query/wav?taskId={taskId}WAV conversion tasks
GET /suno/query/mp4?taskId={taskId}MV generation tasks
GET /suno/query/cover?taskId={taskId}Cover-art tasks

Music task states

StatusMeaning
PENDINGqueued
TEXT_SUCCESStext or lyric stage completed
FIRST_SUCCESSfirst audio finished
SUCCESSfull job completed
CREATE_TASK_FAILEDtask creation failed
GENERATE_AUDIO_FAILEDgeneration failed

Webhook callbacks

All async music routes can call your callBackUrl.

Current callback phases

callbackTypeMeaning
texttext or lyric stage completed
firstfirst audio result is ready
completefull workflow completed

Callback example

{
  "callbackType": "complete",
  "task_id": "5c79****be8e",
  "data": [
    {
      "id": "e231****8cad",
      "audio_url": "https://cdn.example.com/track1.mp3",
      "stream_audio_url": "https://cdn.example.com/stream/track1.mp3",
      "image_url": "https://cdn.example.com/cover1.jpeg",
      "title": "Summer Breeze",
      "tags": "pop, R&B",
      "duration": 91.2
    }
  ]
}

Common AI Music error codes

CodeMeaning
400invalid parameters
401authentication failed
405frequency limit exceeded
413text too long
429quota exhausted
430request rate too high
455system maintenance
500server error
  1. store every submitted taskId
  2. accept webhook callbacks idempotently
  3. keep polling as a fallback if the webhook is delayed
  4. only mark the asset ready after SUCCESS or the final callback

Practical webhook advice

  • verify webhook source before trusting the payload
  • store callback receipts with the same task record you use for polling
  • keep your callback handler fast and queue heavy post-processing work separately

On this page