Pixazo APIModelsStable Audio
Pixazo APIModelsStable Audio

Stable Audio 3 API - AI Music and Audio Generation APIs: Pricing, Documentation

by Stability AI

Stable Audio 3 API delivers a powerful and direct way to build high-quality music and sound effects right into your own apps. Created by Stability AI, this cutting-edge tool uses advanced artificial intelligence to turn simple text prompts into clear, commercial-grade audio tracks. Users can easily control the style, rhythm, and length of the music to match their exact needs without relying on any outside middleware or extra software layers. It gives developers a smooth, reliable pipeline to generate custom audio on demand, making it perfect for video games, content creation tools, and modern digital media platforms.

Get API Key
Stable Audio 3 API

Models Version

LIMITED TIME OFFER

Get $5 Free Credit on First Payment

No strings attached — add funds and get $5 bonus instantly

Claim Your $5 →

Stable Audio 3 API Documentation

https://gateway.pixazo.ai/stable-audio-3-small-music-text-to-audio/v1/stable-audio-3-small-music-text-to-audio-request

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Stable Audio 3 Small Music Text to Audio generate request

Request Code

POST https://gateway.pixazo.ai/stable-audio-3-small-music-text-to-audio/v1/stable-audio-3-small-music-text-to-audio-request
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_API_KEY

{
  "prompt": "Upbeat lo-fi hip hop with mellow piano, warm bassline, and crisp drums",
  "negative_prompt": "",
  "duration": 30,
  "num_inference_steps": 8,
  "guidance_scale": 1,
  "output_format": "mp3",
  "bitrate": "192k",
  "enable_prompt_expansion": false,
  "enable_safety_checker": true,
  "sync_mode": false
}
import requests

url = "https://gateway.pixazo.ai/stable-audio-3-small-music-text-to-audio/v1/stable-audio-3-small-music-text-to-audio-request"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_API_KEY"
}
data = {
    "prompt": "Upbeat lo-fi hip hop with mellow piano, warm bassline, and crisp drums",
    "negative_prompt": "",
    "duration": 30,
    "num_inference_steps": 8,
    "guidance_scale": 1,
    "output_format": "mp3",
    "bitrate": "192k",
    "enable_prompt_expansion": false,
    "enable_safety_checker": true,
    "sync_mode": false
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/stable-audio-3-small-music-text-to-audio/v1/stable-audio-3-small-music-text-to-audio-request";

const data = {
  prompt: "Upbeat lo-fi hip hop with mellow piano, warm bassline, and crisp drums",
  negative_prompt: "",
  duration: 30,
  num_inference_steps: 8,
  guidance_scale: 1,
  output_format: "mp3",
  bitrate: "192k",
  enable_prompt_expansion: false,
  enable_safety_checker: true,
  sync_mode: false
};

fetch(url, {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_API_KEY"
  },
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data));
curl -X POST "https://gateway.pixazo.ai/stable-audio-3-small-music-text-to-audio/v1/stable-audio-3-small-music-text-to-audio-request" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  --data-raw '{
    "prompt": "Upbeat lo-fi hip hop with mellow piano, warm bassline, and crisp drums",
    "negative_prompt": "",
    "duration": 30,
    "num_inference_steps": 8,
    "guidance_scale": 1,
    "output_format": "mp3",
    "bitrate": "192k",
    "enable_prompt_expansion": false,
    "enable_safety_checker": true,
    "sync_mode": false
  }'

Output

{
  "request_id": "stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your generate request to receive a POST callback instead of polling.

X-Webhook-URL: https://your-server.com/webhook/callback

Request Parameters - Stable Audio 3 Small Music Text to Audio generate request

Parameter Required Type Default Allowed values / range Description
promptYesstringText description of the audio to generate. Must be descriptive and specific for best results.
negative_promptNostring""Qualities to avoid in the output, such as "distorted vocals" or "heavy reverb".
durationNofloat301–120Output length in seconds. Allowed range: 1 to 120.
num_inference_stepsNointeger81–100Number of sampling steps during generation. Higher values improve quality at the cost of speed.
guidance_scaleNofloat10–25Classifier-free guidance scale. Controls how closely the output follows the prompt.
output_formatNoenum"mp3""mp3", "wav", "flac", "ogg", "opus", "m4a", "aac"Audio file format.
bitrateNostring"192k"Audio bitrate. Examples: "192k", "320k", "128k". Higher bitrates improve quality but increase file size.
enable_prompt_expansionNobooleanfalseEnables LLM-based prompt enhancement to enrich and expand the input description.
enable_safety_checkerNobooleantrueEnables NSFW content filtering. Disabling may allow inappropriate content.
seedNointegerRandom seed for reproducible results. Use the same seed with identical parameters to generate identical outputs.
sync_modeNobooleanfalseIf true, returns the audio as a base64-encoded data URI inline in the response. If false, returns a request_id for asynchronous polling.

Example Request

{
  "prompt": "Upbeat lo-fi hip hop with mellow piano, warm bassline, and crisp drums",
  "negative_prompt": "",
  "duration": 30,
  "num_inference_steps": 8,
  "guidance_scale": 1,
  "output_format": "mp3",
  "bitrate": "192k",
  "enable_prompt_expansion": false,
  "enable_safety_checker": true,
  "sync_mode": false
}

Response

{
  "request_id": "stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYOUR_API_KEY

Response Handling

Common status codes.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'stable-audio-3-small-music-text-to-audio' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "stable-audio-3-small-music-text-to-audio",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "stable-audio-3-small-music-text-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "stable-audio-3-small-music-text-to-audio",
  "error": null,
  "output": {
    "media_url": ["https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/stable-audio-3-small-music-text-to-audio_019dxxxx/output.mp3"],
    "media_type": "audio/mpeg"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstringWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Stable Audio 3 API Pricing

No data available

Could not load current pricing

Stable Audio 3 API Documentation

https://gateway.pixazo.ai/stable-audio-3-small-music-audio-to-audio/v1/stable-audio-3-small-music-audio-to-audio-request

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Stable Audio 3 Small Music Audio to Audio generate request

Request Code

POST https://gateway.pixazo.ai/stable-audio-3-small-music-audio-to-audio/v1/stable-audio-3-small-music-audio-to-audio-request
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_API_KEY

{
  "prompt": "Transform this into a cinematic orchestral arrangement with sweeping strings",
  "audio_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/Audio.mp3"
}
import requests

url = "https://gateway.pixazo.ai/stable-audio-3-small-music-audio-to-audio/v1/stable-audio-3-small-music-audio-to-audio-request"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_API_KEY"
}
data = {
    "prompt": "Transform this into a cinematic orchestral arrangement with sweeping strings",
    "audio_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/Audio.mp3"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/stable-audio-3-small-music-audio-to-audio/v1/stable-audio-3-small-music-audio-to-audio-request";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_API_KEY"
};
const data = {
  "prompt": "Transform this into a cinematic orchestral arrangement with sweeping strings",
  "audio_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/Audio.mp3"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data));
curl -X POST "https://gateway.pixazo.ai/stable-audio-3-small-music-audio-to-audio/v1/stable-audio-3-small-music-audio-to-audio-request" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  --data-raw '{
    "prompt": "Transform this into a cinematic orchestral arrangement with sweeping strings",
    "audio_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/Audio.mp3"
  }'

Output

{
  "request_id": "stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your generate request to receive a POST callback instead of polling.

X-Webhook-URL: https://your-server.com/webhook/callback

Request Parameters - Stable Audio 3 Small Music Audio to Audio generate request

Parameter Required Type Default Allowed values / range Description
promptYesstringText description guiding how the source audio should be transformed.
audio_urlYesstringURL of the source audio to transform. Supported formats: mp3, ogg, wav, m4a, aac.
init_noise_levelNofloat0.90–1How much noise to add to the source audio (0-1). Lower values keep the output closer to the source; higher values allow more creative deviation.
negative_promptNostring""Qualities to avoid in the output.
durationNofloat301–120 (seconds)Output length in seconds (1-120).
num_inference_stepsNointeger81–100Number of sampling steps (1-100).
guidance_scaleNofloat10–25Classifier-free guidance scale (0-25).
output_formatNoenum"mp3""mp3", "wav", "flac", "ogg", "opus", "m4a", "aac"Audio output format. Allowed: mp3, wav, flac, ogg, opus, m4a, aac.
bitrateNostring"192k"Audio bitrate for compressed formats (e.g., "128k", "192k", "320k").
enable_prompt_expansionNobooleanfalseEnable LLM-based prompt enhancement for improved semantic richness.
enable_safety_checkerNobooleantrueEnable NSFW content filter to block inappropriate outputs.
seedNointegerRandom seed for reproducibility. If omitted, a random seed is used.
sync_modeNobooleanfalseIf true, returns the audio as a data URI inline in the response instead of a URL.

Example Request

{
  "prompt": "Transform this into a cinematic orchestral arrangement with sweeping strings",
  "audio_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/Audio.mp3",
  "init_noise_level": 0.9,
  "negative_prompt": "",
  "duration": 30,
  "num_inference_steps": 8,
  "guidance_scale": 1,
  "output_format": "mp3",
  "bitrate": "192k",
  "enable_prompt_expansion": false,
  "enable_safety_checker": true,
  "sync_mode": false
}

Response

{
  "request_id": "stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYOUR_API_KEY

Response Handling

Common status codes.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'stable-audio-3-small-music-audio-to-audio' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "stable-audio-3-small-music-audio-to-audio",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "stable-audio-3-small-music-audio-to-audio_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "stable-audio-3-small-music-audio-to-audio",
  "error": null,
  "output": {
    "media_url": ["https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/stable-audio-3-small-music-audio-to-audio_019dxxxx/output.mp3"],
    "media_type": "audio/mpeg"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstringWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Stable Audio 3 API Pricing

No data available

Could not load current pricing