接口
clipId,可用于 添加伴奏 或 哼唱生成 等操作。
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
通过 URL 上传音频文件,获取 Clip ID 用于后续操作
POST /api/v1/music/upload
clipId,可用于 添加伴奏 或 哼唱生成 等操作。
| 字段 | 类型 | 是否必填 | 说明 |
|---|---|---|---|
audio_url | string | 必填 | 音频文件的可公开访问 URL |
{
"code": 0,
"message": "ok",
"request_id": "req-1710000000000",
"data": {
"clipId": "abc123def456",
"audioUrl": "https://cdn.example.com/audio/abc123def456.mp3",
"duration": 30,
"status": 1
}
}
| 字段 | 类型 | 说明 |
|---|---|---|
clipId | string | 后续操作使用的片段 ID |
audioUrl | string | 处理后的音频 URL |
duration | integer | 音频时长(秒) |
status | integer | 上传状态码,1 = 就绪 |
curl -X POST https://api.example.com/api/v1/music/upload \
-H "Authorization: Bearer sk-mm-your-key" \
-H "Content-Type: application/json" \
-d '{
"audio_url": "https://example.com/vocals.mp3"
}'