Why teams evaluate this API
A strong fit for teams building AI music generation, creative experimentation, or end-user composition experiences.
Create full songs from prompts with support for lyrics or instrumental workflows, making it easier to ship music generation inside your product.
A strong fit for teams building AI music generation, creative experimentation, or end-user composition experiences.
Set OMNAPI_KEY on your server and create REQUEST_ID once for this logical request. Reuse that ID on transport retries. A new generation can incur a charge; review current pricing first.
curl --fail-with-body --max-time 60 -X POST "https://api.omnapi.com/api/v1/producer/generate/music/compose" \
-H "x-api-key: $OMNAPI_KEY" \
-H "Idempotency-Key: $REQUEST_ID" \
-H "Content-Type: application/json" \
--data '{
"soundPrompt": "Warm instrumental indie pop, jangly guitars and brushed drums",
"instrumental": true,
"length": 60
}'soundPrompt is required and allows up to 500 characters. length accepts 1–600 seconds. Add approved lyrics when you want a vocal song instead of this instrumental example.
See the authentication and task quickstart and complete request schema.
Use this endpoint when your application needs to turn a musical brief into audio. Save the task ID, handle terminal errors, and review the result before publishing.
Longer-running media jobs are easier to manage reliably with queueing, status tracking, and result retrieval patterns.