AudioSuno
Replace Section
Submit this Suno capability through POST /v1/music/generations with model: "suno-replace-section".
Authorization
BearerAuth
AuthorizationBearer <token>
使用 MAPI Bearer Token 认证。格式:Authorization: Bearer sk-xxxxxx。
In: header
Request Body
application/json
model*string
固定填写 suno-replace-section。
task_id*string
产出源音轨那次任务的 ID,必填。缺失或无法解析源时提交期直接返回 400。
audio_index?integer
源任务结果 music[] 中的第几首(1-based,默认 1;一次生成通常 2 首:索引 1 与 2)。
Default
1Range
1 <= valueinfill_lyrics?string
替换片段的新歌词。
start_s*number
替换起点(秒),必填。缺失直接返回 400。须满足 0 ≤ start_s < end_s。
Range
0 <= valueend_s*number
替换终点(秒),必填。必须满足 0 ≤ start_s < end_s;源时长已知时不能越界。缺失直接返回 400。
version?string
公共版本:v6 / v6-wild / v6-mini。省略默认 v6。使用 custom_model_id 时省略。
Default
"v6"Value in
"v6" | "v6-wild" | "v6-mini"custom_model_id?string
创建模型任务返回的完整 UUID,与 version 互斥。
prompt?string
原歌词上下文。与 infill_lyrics(替换片段的新歌词)含义不同。
title?string
标题。
tags?string
风格标签。
negative_tags?string
要排除的风格标签。
variety?string
风格变化程度:off / normal / high / extra / max。可省略。
Value in
"off" | "normal" | "high" | "extra" | "max"max_mode?boolean
是否启用 Max 模式;启用后按普通售价的 2 倍计费。
Default
falseaudio_format?string
输出音频格式:mp3 / m4a / wav。本接口不支持目标时长字段。
Value in
"mp3" | "m4a" | "wav"Response Body
application/json
application/json
curl -X POST "https://loading/v1/music/generations" \ -H "Content-Type: application/json" \ -d '{ "model": "suno-replace-section", "task_id": "task_01ABC", "audio_index": 1, "start_s": 30, "end_s": 45, "infill_lyrics": "新的一段歌词" }'{
"code": 200,
"message": "success",
"data": [
{
"status": "submitted",
"task_id": "task_01K8SGYNNNVBQTXNR4MM964S7K"
}
]
}{
"code": "invalid_request",
"message": "start_s is required",
"data": null
}Last updated on