ToAPIsToAPIs
Suno 음악

음악 생성

Suno 음악 생성 — 영감/커스텀 가사 모드, Max 티어 지원

POST
/v1/music/generations/generation
  • 텍스트 설명 또는 커스텀 가사로 완성곡 생성(요청당 2개 후보)
  • 비동기 태스크, 태스크 ID로 결과 폴링
  • custom이 prompt의 의미를 결정: 커스텀 가사 vs 영감 설명

Authorizations

Authorizationstring헤더필수

Bearer Token. API Key:API Key 관리 페이지

Body

modelstring본문필수
고정값 "suno"
customboolean본문

모드 스위치, 기본 false

  • false: 영감 모드 — gpt_description(또는 prompt)에 음악 설명
  • true: 커스텀 가사 모드 — prompt가 가사 본문, title/style/negative_tags 적용
gpt_descriptionstring본문

영감 모드의 음악 설명. 예:"비 오는 밤 카페에 어울리는 lo-fi". 커스텀 모드에서는 불필요

promptstring본문

커스텀 모드의 가사 본문([Verse]/[Chorus] 구조 태그 지원)

titlestring본문
곡 제목(커스텀 모드)
stylestring본문
스타일 태그(커스텀 모드). 예:"dreamy synthwave, female vocal"
negative_tagsstring본문
피할 요소(커스텀 모드)
instrumentalboolean본문
보컬 없는 연주곡 생성
versionstring본문
엔진 버전:v6 / v6-wild / v6-mini
max_modeboolean본문
Max 품질 티어(2배 $0.10). custom=true 필요
persona_idstring본문
생성된 보컬 페르소나 ID. custom_model_id와 상호 배타
custom_model_idstring본문
커스텀 학습 모델 ID. version·persona_id와 상호 배타

선택적 튜닝 파라미터

style_weight, weirdness, audio_weight, vocal_gender, auto_lyrics, variety는 모두 선택 사항이며 생략 시 업스트림 기본값 적용.

Response

task_idstring

태스크 ID(tsk_aud_ 접두사). 태스크 상태 조회로 폴링

statusstring
submitted / queued / in_progress

완료 후 result.music[]에 2개 후보가 반환되며 각각 audio_url, image_url, title, tags, lyrics, duration 포함. 미디어 URL은 CDN에 미러링됩니다.

요청 예시

curl --request POST \
  --url https://toapis.com/v1/music/generations/generation \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
    "model": "suno",
    "gpt_description": "비 오는 밤 카페에 어울리는 lo-fi 재즈",
    "instrumental": false,
    "version": "v6"
  }'
import requests

resp = requests.post(
    "https://toapis.com/v1/music/generations/generation",
    headers={"Authorization": "Bearer <token>"},
    json={
        "model": "suno",
        "custom": True,
        "prompt": "[Verse]\n네온이 켜진다\n[Chorus]\n새벽까지 달려간다",
        "title": "네온 라이드",
        "style": "synthwave",
        "max_mode": True
    }
)
print(resp.json())
const resp = await fetch("https://toapis.com/v1/music/generations/generation", {
  method: "POST",
  headers: {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    model: "suno",
    gpt_description: "dreamy synthwave with female vocals",
    version: "v6-wild"
  })
});
console.log(await resp.json());