MusicAPI
HomeDocs
HomeDocs
  1. sonic
  • Introduction
  • Credits Usage Guide
  • Music API FAQ & Troubleshooting
  • Special Scenarios
  • Error handling
  • Webhook Integration Guide
  • Get Your Suno API Key
  • API Changelog
  • sonic
    • Sonic Instructions
    • create / extend / cover / remaster / add vocals / add instrumental
      POST
    • upload and extend music
      POST
    • upload and cover music
      POST
    • create persona
      POST
    • sample
      POST
    • mashup
      POST
    • get BPM
      POST
    • get VOX
      POST
    • get wav
      POST
    • get midi
      POST
    • get lyrics timeline
      POST
    • upsample tags
      POST
    • stems basic
      POST
    • stems full
      POST
    • replace section
      POST
    • upload music
      POST
    • create voice
      POST
    • get music
      GET
    • download (mp3 / m4a / wav)
      POST
    • speech
      POST
  • producer
    • Producer instructions
    • Complete Request Examples
    • create music
    • upload
    • download
    • get music
    • Extend an existing music track
    • Replace a section of an existing music track
    • Cover an existing music track
  • studio(Unavailable)
    • Studio Instructions
    • description mode (Use case1)
    • extend mode (Use case2)
    • custom mode (Use case3)
    • instrumental mode (Use case4)
    • get music
  • lyrics generation
    • Make Lyrics
  • nuro
    • Nuro Instruction
    • Error handling
    • create vocal music
    • create instrument music
    • get music
  • get-credits
    GET
  1. sonic

speech

POST
https://api.musicapi.ai/api/v1/sonic/speech
Generate spoken audio: a narrator, a news read, an ad voice-over, a character line. Direct the delivery with tone, pacing and emotion, with or without background music.
This is an async endpoint — submit the request, receive a task_id, then poll for the result.
Credits cost: 20 per request (two takes are returned). Credits are refunded automatically if the task fails.
Two modes, chosen by custom_mode:
custom_mode: true — your script. prompt is read aloud as written. Use tags to direct the voice: tone, pacing, emotion, scene (for example calm, warm, steady pace, evening news).
custom_mode: false — from a description. A script is written and read from gpt_description_prompt (for example Read an evening news segment in a calm male voice at a steady pace). tags, background_music, vocal_gender and variety are not accepted in this mode.
Workflow:
1.
Submit the request
2.
Receive a task_id in the response
3.
Poll GET /api/v1/sonic/task/{task_id} until the task completes, or pass webhook_url
4.
The completed task returns two clips, each with audio_url, duration, title and tags
Audio is delivered as MP3.

Polling Result
{
  "code": 200,
  "data": [
    {
      "clip_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "state": "succeeded",
      "title": "Good Evening",
      "tags": "Warm mid-range female voice, calm evening newsreader, steady measured pace",
      "lyrics": "Good evening. Here is tonight's news.",
      "audio_url": "https://files.musicapi.ai/media/xxxxxxxx-audio_url.mp3",
      "duration": 13.6
    },
    {
      "clip_id": "yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy",
      "state": "succeeded",
      "title": "Good Evening",
      "audio_url": "https://files.musicapi.ai/media/yyyyyyyy-audio_url.mp3",
      "duration": 13.2
    }
  ],
  "message": "success"
}

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Body Params application/json

Example
{
  "custom_mode": true,
  "prompt": "Good evening. Here is tonight's news.",
  "tags": "calm, warm, steady pace, evening news",
  "background_music": false,
  "vocal_gender": "f"
}

Request Code 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 'https://api.musicapi.ai/api/v1/sonic/speech' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
  "custom_mode": true,
  "prompt": "Good evening. Here is tonight'\''s news.",
  "tags": "calm, warm, steady pace, evening news",
  "background_music": false,
  "vocal_gender": "f"
}'

Responses

🟢200OK
application/json
Bodyapplication/json

Example
{
    "message": "string",
    "task_id": "string"
}
Modified at 2026-11-13 12:55:55
Previous
download (mp3 / m4a / wav)
Next
Producer instructions
Built with