AnyInt Docs
Media & Music

Music Generation

This page covers the routes you use to create new music assets rather than transform uploaded audio.

This page covers the routes you use to create new music assets rather than transform uploaded audio.

Core creation routes

RoutePurpose
POST /suno/generateCreate a new song
POST /suno/extendExtend an existing generated song
POST /suno/generate-lyricsGenerate lyrics from a short prompt
POST /suno/timestamped-lyricsFetch aligned word timings for a completed song
POST /suno/style-generateExpand a rough style hint into richer style text
POST /suno/generate-coverGenerate cover art for a completed music task

/suno/generate

Use /suno/generate for both one-line song creation and fully controlled lyric-based creation.

Key input fields

FieldRequiredNotes
customModeyesfalse for simple mode, true for custom mode
instrumentalyestrue for instrumental, false for vocals
modelyesone of V4, V4_5, V4_5PLUS, V4_5ALL, V5
callBackUrlyeswebhook endpoint for task completion
promptconditionaldescription in simple mode, lyric text in custom mode
styleconditionalrequired in custom mode
titleconditionalrequired in custom mode
personaIdnoreuse a saved voice identity

Simple mode example

curl -X POST "https://gateway.api.anyint.ai/suno/generate" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "customMode": false,
    "instrumental": false,
    "model": "V5",
    "prompt": "A bright summer pop song about travel and freedom",
    "callBackUrl": "https://your-domain.com/callback"
  }'

Custom mode example

curl -X POST "https://gateway.api.anyint.ai/suno/generate" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "customMode": true,
    "instrumental": false,
    "model": "V5",
    "title": "Summer Breeze",
    "style": "pop, acoustic, warm vocals",
    "prompt": "[Verse]\nThe city fades behind us\n\n[Chorus]\nWe keep driving toward the light",
    "personaId": "your-persona-id",
    "callBackUrl": "https://your-domain.com/callback"
  }'

/suno/extend

Use /suno/extend to continue a previously generated track.

Key input fields

FieldRequiredNotes
audioIdyessource audio to continue
modelyestarget model version
callBackUrlyesasync callback target
defaultParamFlagyesfalse to reuse original song settings, true to override
curl -X POST "https://gateway.api.anyint.ai/suno/extend" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "audioId": "your-audio-id",
    "model": "V4_5",
    "defaultParamFlag": false,
    "callBackUrl": "https://your-domain.com/callback"
  }'

/suno/generate-lyrics

Use this route when you want AI-written lyrics before starting song generation.

curl -X POST "https://gateway.api.anyint.ai/suno/generate-lyrics" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A late-night R&B song about city life",
    "callBackUrl": "https://your-domain.com/callback"
  }'

The callback returns multiple lyric variants, each with title and text.

/suno/timestamped-lyrics

Use this route after a song is complete when you need karaoke, subtitle, or lyric-sync output.

curl -X POST "https://gateway.api.anyint.ai/suno/timestamped-lyrics" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "taskId": "your-task-id",
    "audioId": "your-audio-id"
  }'

The response includes data.alignedWords, where each word includes startS and endS.

/suno/style-generate

This is a synchronous helper route for improving rough style tags before you submit a full generation request.

curl -X POST "https://gateway.api.anyint.ai/suno/style-generate" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "content": "Pop, Mysterious, Electronic" }'

/suno/generate-cover

Use this route after a music task is complete to create cover art options.

curl -X POST "https://gateway.api.anyint.ai/suno/generate-cover" \
  -H "Authorization: Bearer $ANYINT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "taskId": "your-task-id",
    "callBackUrl": "https://your-domain.com/callback"
  }'

The callback returns data.images, which is an array of generated cover URLs.

On this page