upload audio to suno
curl --request POST \
--url https://api.mountsea.ai/suno/v2/upload \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"audioUrl": "<string>"
}
'import requests
url = "https://api.mountsea.ai/suno/v2/upload"
payload = { "audioUrl": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({audioUrl: '<string>'})
};
fetch('https://api.mountsea.ai/suno/v2/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mountsea.ai/suno/v2/upload",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'audioUrl' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.mountsea.ai/suno/v2/upload"
payload := strings.NewReader("{\n \"audioUrl\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.mountsea.ai/suno/v2/upload")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"audioUrl\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mountsea.ai/suno/v2/upload")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"audioUrl\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"taskId": "15c257ff-43f7-4678-bd41-202ad6b8488b"
}Suno
上传音频
上传音频文件到 Suno 以进行后续处理
POST
/
suno
/
v2
/
upload
upload audio to suno
curl --request POST \
--url https://api.mountsea.ai/suno/v2/upload \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"audioUrl": "<string>"
}
'import requests
url = "https://api.mountsea.ai/suno/v2/upload"
payload = { "audioUrl": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({audioUrl: '<string>'})
};
fetch('https://api.mountsea.ai/suno/v2/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mountsea.ai/suno/v2/upload",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'audioUrl' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.mountsea.ai/suno/v2/upload"
payload := strings.NewReader("{\n \"audioUrl\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.mountsea.ai/suno/v2/upload")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"audioUrl\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mountsea.ai/suno/v2/upload")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"audioUrl\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"taskId": "15c257ff-43f7-4678-bd41-202ad6b8488b"
}通过提供音频的 URL 上传音频文件。Suno 将下载并处理该文件。上传的音频随后可在 Generate 端点中配合
upload_extend 或 upload_cover 任务使用。
这是一个异步任务。响应包含一个
taskId — 使用获取任务状态轮询上传结果,结果将包含后续操作所需的 clip_id。audioUrl 必须是我们服务器可以下载的公开可访问 URL。支持的格式包括 MP3、WAV 和其他常见音频格式。单次上传每次可能落在不同 Suno 账号。若需多个文件同账号(Inspiration、Persona 等),请使用 批量上传 Session。
授权
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
请求体
application/json
The audio url to upload, must be a url that we can download
响应
201 - application/json
task id. Use this id to query task status.
示例:
"15c257ff-43f7-4678-bd41-202ad6b8488b"