CQTAI
Suno · Music

Replace Section

📌 What is thisRedo only one part of a song (e.g. the second verse), keeping the rest.
💡 When to useUse when most of a song is fine but one section needs redoing.

Endpoints

UsageMethodPath
Submit taskPOST/api/cqt/generator/suno
Query ResultGET/api/cqt/info/suno?id={taskId}

Request Parameters

ParamTypeRequiredDescription
taskstringRequiredFixed value: replace_section
taskIdstringRequiredTask ID the source song belongs to
clipIdstringRequiredSource song clip ID
rangeStartSnumberRequiredStart second of the section to replace
rangeEndSnumberRequiredEnd second of the section to replace
infillLyricsstringRequiredNew lyrics for the replaced section
tagsstringStyle tags
titlestringSong title
infillTypeenumsmart (default) / classic / fixed

Request Example

curl -X POST https://api.cqtai.com/api/cqt/generator/suno \
  -H 'Authorization: Bearer <API_KEY>' \
  -H 'Content-Type: application/json' \
  -d '{
    "task": "replace_section",
    "taskId": "d649231618784ee4b9cfa059ac50be5e",
    "clipId": "eb1c6c96-a102-4bbb-82c2-87c3b126a44e",
    "tags": "Happy",
    "title": "两只老虎(聪明)",
    "infillLyrics": "两只老虎 两只老虎跑得快 一只没有耳朵 一只没有尾巴 真奇怪",
    "rangeStartS": 7.56,
    "rangeEndS": 15.98
  }'
# -> { "code":200, "data":"<taskId>" }

Response Example

{
  "code": 200,
  "msg": "success",
  "data": {
    "id": "c8d1e607b5a84c41889e23981ffd6305",
    "taskType": "replace_section",
    "status": "succeeded",
    "errorMsg": "",
    "param": {
      "task": "replace_section",
      "taskId": "d649231618784ee4b9cfa059ac50be5e",
      "clipId": "eb1c6c96-a102-4bbb-82c2-87c3b126a44e",
      "tags": "Happy",
      "title": "两只老虎(聪明)",
      "infillLyrics": "两只老虎 两只老虎跑得快 …(完整歌词已省略)",
      "rangeStartS": 7.56,
      "rangeEndS": 15.98
    },
    "result": [
      {
        "id": "ad924885-4655-4ca4-ab36-e67c12e3f7e5",
        "title": "两只老虎(聪明)",
        "handle": "rositabadgercldrq",
        "status": "complete",
        "user_id": "8338d85e-0591-4277-a134-cc1080a107f5",
        "metadata": {
          "tags": "Happy",
          "task": "infill",
          "type": "gen",
          "infill": true,
          "prompt": "两只老虎 两只老虎跑得快 …(完整歌词已省略)",
          "duration": 14.44,
          "is_remix": true,
          "infill_lyrics": "两只老虎 两只老虎跑得快 …(完整歌词已省略)",
          "edited_clip_id": "eb1c6c96-a102-4bbb-82c2-87c3b126a44e",
          "lyrics_updated": false,
          "history": [
            {
              "id": "eb1c6c96-a102-4bbb-82c2-87c3b126a44e",
              "type": "gen",
              "infill": true,
              "infill_start_s": 7.56,
              "infill_end_s": 15.98,
              "infill_dur_s": 8.42,
              "infill_context_start_s": 0,
              "infill_context_end_s": 61,
              "include_history_s": 2,
              "include_future_s": 2
            }
          ]
        },
        "audio_url": "https://cdn1.suno.ai/ad924885-4655-4ca4-ab36-e67c12e3f7e5.mp3",
        "image_url": "https://cdn2.suno.ai/image_ad924885-4655-4ca4-ab36-e67c12e3f7e5.jpeg",
        "image_large_url": "https://cdn2.suno.ai/image_large_ad924885-4655-4ca4-ab36-e67c12e3f7e5.jpeg",
        "video_url": "",
        "clip_roots": {
          "clips": [
            { "user_handle": "playfulsubtlety0358", "user_display_name": "PlayfulSubtlety0358" }
          ],
          "clip_attribution_type": "remix"
        },
        "media_urls": [
          { "url": "https://d2lwuy8qc234o3.cloudfront.net/1/clip/ad924885-4655-4ca4-ab36-e67c12e3f7e5.m4a", "delivery": "progressive", "content_type": "m4a-opus" },
          { "url": "https://cdn1.suno.ai/ad924885-4655-4ca4-ab36-e67c12e3f7e5.mp3", "delivery": "progressive", "content_type": "mp3" }
        ],
        "model_name": "chirp-crow",
        "batch_index": 0,
        "created_at": "2026-07-08T07:27:11.972Z",
        "major_model_version": "v5"
      },
      {
        "id": "764ee8ad-5c6f-4d99-8b78-c6054712094d",
        "title": "两只老虎(聪明)",
        "status": "complete",
        "metadata": {
          "task": "infill",
          "infill": true,
          "duration": 17.52,
          "is_remix": true,
          "edited_clip_id": "eb1c6c96-a102-4bbb-82c2-87c3b126a44e"
        },
        "audio_url": "https://cdn1.suno.ai/764ee8ad-5c6f-4d99-8b78-c6054712094d.mp3",
        "image_url": "https://cdn2.suno.ai/image_764ee8ad-5c6f-4d99-8b78-c6054712094d.jpeg",
        "batch_index": 1,
        "major_model_version": "v5"
      }
    ],
    "createTime": "2026-07-08 15:27:09",
    "completeTime": "2026-07-08 15:27:44"
  }
}

Response Fields

FieldTypeDescription
codenumberStatus code; 200 = success
msgstringMessage
data.idstringTask ID (the taskId returned on submit; used to poll)
data.taskTypestringTask type; matches the submitted task
data.statusstringStatus: pending / succeeded / failed
data.errorMsgstringFailure reason; empty on success
data.paramobjectEcho of the request params you submitted
data.resultarrayResults; returns 2 candidate clips
data.result[].idstringThe generated clipId; reusable for further extend / cover, etc.
data.result[].audio_urlstringAudio file URL (mp3)
data.result[].video_urlstringVideo file URL (mp4); may be empty, re-query later
data.result[].image_urlstringCover image URL (image_large_url is the large one)
data.result[].titlestringSong title
data.result[].statusstringClip status; "complete" = ready to download
data.result[].metadata.durationnumberTotal audio duration (seconds)
data.result[].metadata.tagsstringStyle tags
data.result[].metadata.taskstringFor replace_section, the clip metadata.task shows "infill" (section inpaint)
data.result[].metadata.infillboolWhether it is a section inpaint; always true here
data.result[].metadata.infill_lyricsstringNew lyrics for the replaced section (echo of infillLyrics)
data.result[].metadata.edited_clip_idstringEdited source clip ID (= the clipId you passed)
data.result[].metadata.history[].infill_start_s / infill_end_s / infill_dur_snumberStart/end second and duration of the replaced section
data.result[].metadata.history[].infill_context_start_s / infill_context_end_snumberContext range (seconds) referenced during generation
data.result[].metadata.is_remixboolWhether it is a remix; always true for replace_section
data.result[].clip_rootsobjectSource (parent) clip info: title / cover / author
data.result[].media_urlsarrayMulti-format audio URLs (m4a-opus / mp3)
data.result[].batch_indexnumberCandidate index (0, 1)
data.result[].major_model_versionstringModel version used, e.g. v4.5 / v5.5
data.createTime / completeTimestringTask submit time / completion time
其它字段action_config / model_badges / secondary_badges / ownership / avatar_image_url, etc. are for Suno UI and can be ignored

Billing & Credits

30 credits (x your user rate). Auto-refunded on failure.