curl --request POST \
--url https://api.poyo.ai/api/generate/submit \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "upload-and-extend-audio",
"callback_url": "https://your-domain.com/callback",
"input": {
"upload_url": "https://storage.example.com/audio.mp3",
"default_param_flag": true,
"instrumental": true,
"style": "Classical",
"title": "Peaceful Piano Extended",
"continue_at": 60,
"mv": "V5_5"
}
}
'{
"code": 200,
"data": {
"task_id": "task-unified-1757165031-uyujaw3d",
"status": "not_started",
"created_time": "2025-11-12T10:30:00"
}
}Suno AI
上传并延长音频
在保留原有风格的同时延长音轨
POST
/
api
/
generate
/
submit
curl --request POST \
--url https://api.poyo.ai/api/generate/submit \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "upload-and-extend-audio",
"callback_url": "https://your-domain.com/callback",
"input": {
"upload_url": "https://storage.example.com/audio.mp3",
"default_param_flag": true,
"instrumental": true,
"style": "Classical",
"title": "Peaceful Piano Extended",
"continue_at": 60,
"mv": "V5_5"
}
}
'{
"code": 200,
"data": {
"task_id": "task-unified-1757165031-uyujaw3d",
"status": "not_started",
"created_time": "2025-11-12T10:30:00"
}
}- 提交后会返回
task_id。如果提供了callback_url,当任务状态变为finished或failed时,系统会向callback_url发送 POST 请求。 - 无论是否提供
callback_url,都可以通过统一的查询音乐详情接口获取结果。
persona_model 接受 style_persona 或 voice_persona,需要 persona_id,且仅在 default_param_flag: true 并使用 V5、V5_5、V6、V6_MINI 或 V6_WILD 时支持。
使用指南
- 此接口始终为自定义模式。
default_param_flag: false会被拒绝 - 上传现有音轨,并指定从哪里继续
- AI 会生成与原曲无缝融合的新增内容
- 上传的音频文件时长不得超过 8 分钟(注意:V4_5ALL 模型最多 1 分钟)
参数详情
-
当
default_param_flag: true(自定义参数模式)时:- 完全控制风格、标题和其他参数
-
如果
instrumental: true:upload_url、mv、style、title和continue_at为必填 -
如果
instrumental: false:upload_url、mv、style、title和continue_at为必填。prompt为可选,提供时会被使用 -
字符限制因模型而异:
-
V4:
prompt3000 个字符,style200 个字符,title80 个字符 -
V4_5 和 V4_5PLUS:
prompt5000 个字符,style1000 个字符,title100 个字符 -
V4_5ALL:
prompt5000 个字符,style1000 个字符,title80 个字符 -
V5:
prompt5000 个字符,style1000 个字符,title100 个字符 -
V5_5:
prompt5000 个字符,style1000 个字符,title100 个字符 -
V6、V6_MINI 和 V6_WILD:
prompt5000 个字符,style1000 个字符,title100 个字符
-
V4:
开发者说明
default_param_flag必须省略或设为true。false会被拒绝。continue_at参数决定延长从哪里开始,请将其设为你希望新内容开始的位置
可选参数
-
prompt(string):可选,延长音频的描述或歌词。输出人声时如果省略,会自动生成歌词。 -
style(string):音乐风格说明。default_param_flag为true时必填。 -
title(string):延长音频的音轨标题。字符限制因模型而异(V4 和 V4_5ALL:80;V4_5、V4_5PLUS、V5、V5_5、V6、V6_MINI 和 V6_WILD:100)。 -
negative_tags(string):生成时要排除的音乐风格。 -
vocal_gender(string):人声性别偏好。m表示男声,f表示女声。注意:此参数只能提高概率,不能保证生成指定性别。 -
style_weight(number):对风格的遵循强度。范围 0-1,最多 2 位小数。 -
weirdness_constraint(number):控制创意偏离程度。范围 0-1,最多 2 位小数。 -
audio_weight(number):音频特征的平衡权重。范围 0-1,最多 2 位小数。 -
persona_id(string):应用于生成音乐的 Persona ID。仅在default_param_flag: true且使用 V5、V5_5、V6、V6_MINI 或 V6_WILD 时可用。如何生成 persona_id,请参阅 generate-persona。
授权
所有 API 接口都需要 Bearer Token 认证。
创建 API Key:登录 PoYo,进入 仪表盘 → API 密钥(poyo.ai/zh/dashboard/api-key),点击创建 Key。
在请求头中添加:
Authorization: Bearer YOUR_API_KEY
请求体
application/json
响应
200 - application/json
任务提交成功
Show child attributes
Show child attributes