A paid credit pack or an active paid subscription is required; gifted credits alone do not unlock the API. A 503 response means the service is not activated or is temporarily unavailable.
1. Quick start
Run these examples in a server terminal. Python requires pip install requests; JavaScript uses Node.js 22 or later.
cURL
export SEEDAUDIO_ORIGIN='https://seedaudio.now'
export SEEDAUDIO_API_KEY='YOUR_API_KEY'
curl --fail-with-body "$SEEDAUDIO_ORIGIN/api/v1/audio/generations" \
-H "Authorization: Bearer $SEEDAUDIO_API_KEY" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: rain-scene-001' \
-d '{"model":"seed-audio-1.0","prompt":"Gentle rain against a window.","output_format":"mp3"}'
# Replace TASK_ID with the returned id. Poll every 5 seconds until terminal.
curl --fail-with-body "$SEEDAUDIO_ORIGIN/api/v1/audio/generations/TASK_ID" \
-H "Authorization: Bearer $SEEDAUDIO_API_KEY"
# After status is succeeded, download using the same account's active key.
curl --fail-with-body "$SEEDAUDIO_ORIGIN/api/v1/audio/generations/TASK_ID/content" \
-H "Authorization: Bearer $SEEDAUDIO_API_KEY" -o audio.mp3
JavaScript (Node.js)
const origin = "https://seedaudio.now";
const headers = { Authorization: 'Bearer ' + process.env.SEEDAUDIO_API_KEY };
async function json(response) {
const data = await response.json();
if (!response.ok) throw new Error(data.error?.message || 'Request failed');
return data;
}
// Persist this key with your request; reuse it if the POST response is lost.
const idempotencyKey = 'rain-scene-001';
let task = await json(await fetch(origin + '/api/v1/audio/generations', {
method: 'POST',
headers: { ...headers, 'Content-Type': 'application/json', 'Idempotency-Key': idempotencyKey },
body: JSON.stringify({ prompt: 'Gentle rain against a window.' })
}));
const deadline = Date.now() + 65 * 60 * 1000;
while (['queued', 'processing'].includes(task.status) && Date.now() < deadline) {
await new Promise(resolve => setTimeout(resolve, 5000));
task = await json(await fetch(origin + '/api/v1/audio/generations/' + task.id, { headers }));
}
if (task.status !== 'succeeded') throw new Error(task.error?.message || 'Poll deadline reached; keep the task id.');
const response = await fetch(task.output.url, { headers });
if (!response.ok) throw new Error('Download failed');
const { writeFile } = await import('node:fs/promises');
await writeFile('audio.mp3', new Uint8Array(await response.arrayBuffer()));
Python
import os, time, requests
origin = "https://seedaudio.now"
headers = {"Authorization": "Bearer " + os.environ["SEEDAUDIO_API_KEY"]}
# Keep this key with your request; a new scene needs a new key.
response = requests.post(origin + "/api/v1/audio/generations", timeout=45,
headers={**headers, "Idempotency-Key": "rain-scene-001"},
json={"prompt": "Gentle rain against a window."})
response.raise_for_status()
task = response.json()
deadline = time.monotonic() + 65 * 60
while task["status"] in ("queued", "processing") and time.monotonic() < deadline:
time.sleep(5)
response = requests.get(origin + "/api/v1/audio/generations/" + task["id"], headers=headers, timeout=90)
response.raise_for_status()
task = response.json()
if task["status"] != "succeeded":
raise RuntimeError(task.get("error") or "Poll deadline reached; keep the task id.")
with requests.get(task["output"]["url"], headers=headers, stream=True, timeout=60) as response:
response.raise_for_status()
with open("audio.mp3", "wb") as audio:
for chunk in response.iter_content(65536):
audio.write(chunk)
2. Endpoints and identity
https://seedaudio.now
POST /api/v1/audio/generations → 202
GET /api/v1/audio/generations/{id} → 200
GET / HEAD /api/v1/audio/generations/{id}/content → 200 / 206
All endpoints require Authorization: Bearer. Tasks belong to the account and may be accessed using another active key from that account. Download URLs are stable but private. Never put keys in a URL. Signed-in history uses session authentication.
3. Request parameters
Content-Type: application/json; maximum 32 KiB. Unknown fields are rejected. Reference URLs must use public HTTPS, not internal addresses.
Parameter
Values
Notes
model
seed-audio-1.0
Default and only model.
prompt
string
Required: 1–2048 Unicode characters, not whitespace only; line breaks are preserved.
audio_references
string[]
Up to 3 public HTTPS audio URLs, referenced in order as @Audio1/2/3. Each reference: at most 10 MB and 30 seconds, checked by the generation service.
voice
string
A preset listed below; consumes one audio reference slot.
image_url
string
One public HTTPS image URL; cannot be combined with voice or audio references.
output_format
mp3 / wav / pcm / ogg_opus
Default mp3. PCM is a raw file and may not play in a browser.
sample_rate
8000 / 16000 / 24000 / 32000 / 44100 / 48000
Default 24000 Hz.
speed / volume
0.5–2
Both default to 1; finite numbers only.
pitch
-12–12
Integer; default 0.
multilingual
boolean
Default false; an API extension that does not follow the page language.
At 75 credits per minute, charges are rounded up by second, with a 10-credit minimum and 150-credit cap. Creation reserves 150; success returns the difference and failure returns the reservation. Original credit expiration dates remain unchanged.
8 / 30 / 60 / 120 seconds cost 10 / 38 / 75 / 150 credits respectively. A refunded or disputed purchase no longer unlocks new API tasks. For a subscription this applies to the current period's payment and lasts until the next period is paid. Other paid purchases still unlock access.
queued → processing → succeeded / failed
succeeded means both private storage and billing are complete. Recovery lasts up to 60 minutes; delivery or reliable duration failure returns the reserved credits. Errors contain only site-facing information.
Idempotency-Key is required: 1–128 letters, digits or ._:-. Use a new key for each new task and preserve the key and body when retrying. Keys are unique within an account and API version for the record lifetime. Same key and body returns the original task; a changed body returns 409. A timeout does not mean creation failed: do not retry with a new key.
Per account: 6 creation requests per minute, 60 combined queries and downloads per minute, and 2 tasks in flight. All keys share these limits. Site capacity may also return 429. Poll every 5 seconds.
6. Errors and downloading
HTTP
code
Action
400
invalid_request
Missing idempotency key, invalid input or unknown fields.
401
invalid_api_key
Missing, invalid or revoked key.
402
insufficient_credits
Fewer than 150 available credits.
403
purchase_required
No paid credit pack or active paid subscription unlocks access, for example because its payment was refunded or disputed.
404
not_found
Not found or not owned by this account.
409
idempotency_conflict / not_ready
Same key with different input, or audio not ready.
413
request_too_large
JSON exceeds 32 KiB.
416
Range
Invalid byte range; multiple ranges are unsupported.
429
rate_limit / concurrency_limit
Wait for Retry-After before retrying.
503
api_unavailable / temporarily_unavailable
Service disabled, configuration incomplete or temporarily unavailable. Keep the task id and idempotency key.
Downloads support a single byte range, suffix ranges and HEAD. Responses are not cached or redirected to external media. Examples use MP3; use the appropriate extension for other formats. Client cancellation and customer-defined callbacks are not offered; query for results.