Текст / Inspo / Эффекты / Теги
curl --request POST \
--url https://toapis.com/v1/music/generations/lyrics \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"prompt": "<string>",
"lyrics_model": "<string>",
"audio_urls": [
{}
],
"max_mode": true,
"type": "<string>",
"bpm": 123,
"key": "<string>",
"tags": "<string>"
}
'import requests
url = "https://toapis.com/v1/music/generations/lyrics"
payload = {
"model": "<string>",
"prompt": "<string>",
"lyrics_model": "<string>",
"audio_urls": [{}],
"max_mode": True,
"type": "<string>",
"bpm": 123,
"key": "<string>",
"tags": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
model: '<string>',
prompt: '<string>',
lyrics_model: '<string>',
audio_urls: [{}],
max_mode: true,
type: '<string>',
bpm: 123,
key: '<string>',
tags: '<string>'
})
};
fetch('https://toapis.com/v1/music/generations/lyrics', 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://toapis.com/v1/music/generations/lyrics",
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([
'model' => '<string>',
'prompt' => '<string>',
'lyrics_model' => '<string>',
'audio_urls' => [
[
]
],
'max_mode' => true,
'type' => '<string>',
'bpm' => 123,
'key' => '<string>',
'tags' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://toapis.com/v1/music/generations/lyrics"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://toapis.com/v1/music/generations/lyrics")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://toapis.com/v1/music/generations/lyrics")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"status": "<string>"
}Suno
Текст / Inspo / Эффекты / Теги
lyrics генерация текста, inspo по референсам, sounds эффекты, upsampleTags расширение
POST
/
v1
/
music
/
generations
/
lyrics
Текст / Inspo / Эффекты / Теги
curl --request POST \
--url https://toapis.com/v1/music/generations/lyrics \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"prompt": "<string>",
"lyrics_model": "<string>",
"audio_urls": [
{}
],
"max_mode": true,
"type": "<string>",
"bpm": 123,
"key": "<string>",
"tags": "<string>"
}
'import requests
url = "https://toapis.com/v1/music/generations/lyrics"
payload = {
"model": "<string>",
"prompt": "<string>",
"lyrics_model": "<string>",
"audio_urls": [{}],
"max_mode": True,
"type": "<string>",
"bpm": 123,
"key": "<string>",
"tags": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
model: '<string>',
prompt: '<string>',
lyrics_model: '<string>',
audio_urls: [{}],
max_mode: true,
type: '<string>',
bpm: 123,
key: '<string>',
tags: '<string>'
})
};
fetch('https://toapis.com/v1/music/generations/lyrics', 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://toapis.com/v1/music/generations/lyrics",
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([
'model' => '<string>',
'prompt' => '<string>',
'lyrics_model' => '<string>',
'audio_urls' => [
[
]
],
'max_mode' => true,
'type' => '<string>',
'bpm' => 123,
'key' => '<string>',
'tags' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://toapis.com/v1/music/generations/lyrics"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://toapis.com/v1/music/generations/lyrics")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://toapis.com/v1/music/generations/lyrics")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"lyrics_model\": \"<string>\",\n \"audio_urls\": [\n {}\n ],\n \"max_mode\": true,\n \"type\": \"<string>\",\n \"bpm\": 123,\n \"key\": \"<string>\",\n \"tags\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"status": "<string>"
}POST https://toapis.com/v1/music/generations/{operation}
string
обязательно
Фиксированное
"suno"lyrics — генерация текста($0.008)
string
обязательно
Тема или описание текста
string
Модель текста:
classic / remi(опционально)curl --request POST \
--url https://toapis.com/v1/music/generations/lyrics \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{"model":"suno","prompt":"песня про лето у моря"}'
inspo — генерация по референсам(0.068,Max0.136)
Новый трек, вдохновлённый 1-4 референсами.array
обязательно
1-4 публичных URL аудио
boolean
Max-тариф(поля
custom нет, применяется сразу)Не отправляйте
custom — upstream отклонит.sounds — звуковые эффекты($0.0096)
string
обязательно
Описание эффекта
string
Тип эффекта
number
Темп(диапазон 1-300)
string
Тональность
upsampleTags — расширение тегов($0.004)
Разворачивает краткий тег стиля в подробное описание.string
обязательно
Теги стиля, например
"lo-fi chill beats"Response
string
ID задачи
string
submitted