API reference
🇺🇸 English
  • 🇨🇳 Chinese
  • 🇺🇸 English
  1. Udio
API reference
🇺🇸 English
  • 🇨🇳 Chinese
  • 🇺🇸 English
  • Chat Models
    • Chat
      • Create chat completion
      • vision
    • OpenAI-Realtime
    • Completions
      • Instruct
    • Audio
      • Transcriptions
      • Translations
      • Speech
    • Image generation
      • DALL·E 3
    • Embeddings
      • Create
    • Models
      • model list
    • Help
      • 常见问题及解决办法
  • Anthropic
    • Anthropic Claude
      POST
  • Suno
    • Generate music
      POST
    • Generate lyrics
      POST
    • Upload music
      POST
    • Music concat
      POST
    • Fetch task
      GET
    • Fetch batch tasks
      POST
  • Udio
    • Generate music
      POST
    • Fetch task
      GET
  • Midjourney API
    • Quick
    • Task Submit
      • Imagine
      • Action
      • Modal
      • Blend
      • Describe
      • Shorten
      • Upload discord
    • Get Task
      • Fetch task by ids
      • Fetch task by id
      • Get seed
  • Flux
    • Official
      • Generate
      • Finetune
      • Fetch task
    • OpenAI Dalle3
      POST
  • Recraft
    • Official
      • Generate Image
      • Vectorize Image
      • Remove Background
      • Clarity Upscale
      • Generative Upscale
      • Create style
    • OpenAI Dalle3
      POST
  • Ideogram
    • Generate
    • Remix
    • Edit
    • Upscale
    • Describe
  • Luma
    • Official
      • Generate
      • Fetch task
    • Own format
      • Submit
        • Generate
        • Get video of no mark
        • 扩展视频
      • Get task
        • Get task
        • Get batch task
  • Runway
    • Official
      • image to video
      • get task
    • reverse
      • text to video
      • image to video
      • video2video
      • Act-one
      • Get task
  • Kling-API
    • Callback
    • Generate image
    • Text 2 Video
    • Image 2 Video
    • Video extend
    • Get task
    • lip-sync
    • kolors-virtual-try-on
  • Replicate
    • Generate
    • Get
  • MiniMax
    • Generate video
    • Get task
    • Get file
  1. Udio

Generate music

POST
/udio/generate-proxy
Last modified:2025-02-05 11:20:12

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Header Params
Authorization
string 
optional
Example:
Bearer
Body Params application/json
gen_params
object 
required
prompt
string 
required
音乐生成的提示词
Example:
rock, pop soul, electronic
lyrics
string 
required
歌词内容
Example:
[Verse 1] In the silence, echoes fade, footsteps in the ground Time's slipping, memories made, with whispers all around As the stars dim, shadows play, we take our final bow
lyrics_type
enum<string> 
required
歌词类型
Allowed values:
userinstrumentalgenerate
Example:
user
model_type
enum<string> 
required
模型类型
Allowed values:
udio32-v1.5udio130-v1.5
Example:
udio130-v1.5
config
object 
required
negative_prompt
string 
optional
负面提示词
Example:
song_section_start
number 
required
歌曲片段开始位置
>= 0<= 1
Default:
0
Example:
0
song_section_end
number 
required
歌曲片段结束位置
>= 0<= 1
Default:
1
Example:
1
lyrics_placement_start
number 
required
歌词放置开始位置
>= 0<= 1
Example:
0
lyrics_placement_end
number 
required
歌词放置结束位置
>= 0<= 1
Example:
0.95
prompt_strength
number 
required
提示词强度
>= 0<= 1
Default:
0.5
Example:
0.5
clarity_strength
number 
required
清晰度强度
>= 0<= 1
Default:
0.25
Example:
0.25
lyrics_strength
number 
required
歌词强度
>= 0<= 1
Default:
0.5
Example:
0.5
generation_quality
enum<number> 
required
生成质量
Allowed values:
0.250.50.751
Default:
0.75
Example:
0.75
seed
number 
required
随机种子
Default:
-1
Example:
-1
bypass_prompt_optimization
boolean 
required
是否跳过提示词优化
Default:
false
Example:
false
Example
{
  "gen_params": {
    "prompt": "The last song ever sung on the planet earth",
    "lyrics": "",
    "lyrics_type": "generate",
    "bypass_prompt_optimization": false,
    "seed": -1,
    "song_section_start": 0.4,
    "prompt_strength": 0.5,
    "clarity_strength": 0.25,
    "lyrics_strength": 0.5,
    "generation_quality": 0.75,
    "negative_prompt": "",
    "model_type": "udio32-v1.5",
    "config": {
      "mode": "regular"
    }
  }
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location -g --request POST '/udio/generate-proxy' \
--header 'Authorization: Bearer' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
  "gen_params": {
    "prompt": "The last song ever sung on the planet earth",
    "lyrics": "",
    "lyrics_type": "generate",
    "bypass_prompt_optimization": false,
    "seed": -1,
    "song_section_start": 0.4,
    "prompt_strength": 0.5,
    "clarity_strength": 0.25,
    "lyrics_strength": 0.5,
    "generation_quality": 0.75,
    "negative_prompt": "",
    "model_type": "udio32-v1.5",
    "config": {
      "mode": "regular"
    }
  }
}'

Responses

🟢200成功
application/json
Body
code
string 
required
message
string 
required
data
string 
required
task_id
Example
{
  "code": "success",
  "message": "",
  "data": "736a6f88-bd29-4b1e-b110-37132a5325ac"
}
Previous
Fetch batch tasks
Next
Fetch task
Built with