Extract stems from a song
October 9, 2026
Table of contents
https://api.useapi.net/v1/mureka/music/stems
Split a song you generated into separate tracks, the same as Extract Stems on mureka.ai. There are two modes:
all_stems | What you get | Cost |
|---|---|---|
true (default) | All detected stems — up to 12 separate instrument and vocal tracks, plus MIDI | 100 Mureka Gold |
false | Vocals + Instrumental | 20 Mureka Gold |
Each stem comes back as a .wav and an .mp3 link. Extraction takes about a minute for a 3-minute song (40 to 70 seconds in our tests).
Every call starts a new extraction and is charged again, even for a song you already extracted. Keep the stems_id of a finished extraction and use it with POST /music/stems-download instead of extracting the same song twice.
Once the job is completed, pass its stems_id to POST /music/stems-download for a single stem with its MIDI, ZIP archives of all stems and all MIDI, or a ready-made session for Ableton Live, Logic Pro, Pro Tools or Cubase. Those downloads are free.
POST /music/download with type stem still returns the basic stems package of a song, with no extraction job.
Request Headers
Authorization: Bearer {API token}
Content-Type: application/json
# Alternatively you can use multipart/form-data
# Content-Type: multipart/form-data
API tokenis required, see Setup useapi.net for details.
Request Body
{
"song_id": "user:777-mureka:12345678901234-song:33445566",
"all_stems": true
}
song_idis required.
Thesong_idvalue returned by one of the following endpoints:- GET /music
- GET /music/
song_id - POST /music/create
- POST /music/create-advanced
- POST /music/create-instrumental
- POST /music/extend
- POST /music/regenerate
- POST /music/edit
The song’s own account runs the extraction, so there is no
accountparameter.-
all_stemsis optional (default:true).
trueextracts all detected stems, up to 12 tracks plus MIDI, for 100 Mureka Gold. The stems Mureka finds depend on the song. Names seen so far arebass,brass_and_winds,drums,guitar,other(shown as FX on mureka.ai),piano(Keyboard on mureka.ai),strings,synthandvocal.
falseextracts Vocals + Instrumental only, for 20 Mureka Gold. It returns two stems,instrumentalandvocal, and both have MIDI. -
asyncis optional, enables fire-and-forget mode (default:false). Whentrue, returns immediately with201 Createdand job metadata. Poll GET /jobs/jobidfor completion status.
Withoutasyncthe call waits for the extraction to finish and returns200with thecompletedjob. If the extraction is still running after about 4 minutes, it returns201with the job stillcreated— keep polling GET /jobs/jobiduntil it completes.
A failed extraction returns thefailedjob, with itscodeas the HTTP status. A job still extracting after 10 minutes is markedfailed. -
replyUrlis optional, webhook URL for job status callbacks. Receives a POST request when the job ends ascompletedorfailed. The JSON payload shape matches GET /jobs/jobidresponse.
If no callback arrives within about 5 minutes, poll GET /jobs/jobid— an extraction that runs that long is finished by the poll, not by a callback. replyRefis optional, custom reference string passed back in webhook callbacks. Useful for tracking jobs on your end.
Responses
-
Extraction completed. Each stem has a
.wavand an.mp3link.Real response, ids shortened (a 3:15 song, 9 stems, 67 seconds).
{ "jobid": "j1010023903143042515m-u777-a12345678901234-bot:mureka", "verb": "music/stems", "jobType": "music", "status": "completed", "created": "2026-10-10T02:39:03.143Z", "request": { "song_id": 33445566, "all_stems": true, "account": "12345678901234" }, "response": { "stems_id": "user:777-mureka:12345678901234-song:33445566-stems:55667788", "song_id": "user:777-mureka:12345678901234-song:33445566", "all_stems": true, "bpm": 120, "status": "completed", "generate_state": 1, "stems": [ { "stem_name": "bass", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/bass.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "brass_and_winds", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/brass_and_winds.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "drums", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/drums.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "guitar", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/guitar.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "other", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/other.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "piano", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/piano.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "strings", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/strings.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "synth", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/synth.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" }, { "stem_name": "vocal", "wav": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/vocal.wav", "mp3": "https://static-cos.mureka.ai/cos-prod/song/audio/20261010/<id>/<id>.mp3" } ] }, "updated": "2026-10-10T02:40:09.871Z" } -
Job created in async mode (
async: true), or a sync call that was still extracting after about 4 minutes. The extraction is processing in the background.Use GET /jobs/
jobidto poll for completion status.{ "jobid": "j1009123456789475905m-u777-a12345678901234-bot:mureka", "verb": "music/stems", "jobType": "music", "status": "created", "created": "2026-10-09T12:34:56.789Z", "request": { "song_id": 33445566, "all_stems": true, "async": true, "replyUrl": "https://your-domain.com/webhook", "replyRef": "my-custom-ref-123", "account": "12345678901234" }, "response": { "stems_id": "user:777-mureka:12345678901234-song:33445566-stems:55667788", "song_id": "user:777-mureka:12345678901234-song:33445566", "all_stems": true, "status": "processing", "generate_state": 3 } } -
{ "error": "<Error message>", "code": 400 } -
{ "error": "Wrong username/password combination.", "code": 401 } -
The account does not have enough Mureka Gold for the extraction (100 for all stems, 20 for Vocals + Instrumental).
{ "error": "User balance is not enough to operate (6310)", "code": 412 } -
596 Account Error
Returned when the account has an error state preventing API calls.
{ "error": "Session refresh failed 2026-01-19T14:31:15.000Z, manual update required", "code": "REFRESH_FAILED" }Possible error codes:
ACCOUNT_ERROR- Account has a blocking errorREFRESH_FAILED- Automatic token refresh failedREFRESH_IN_PROGRESS- Token refresh already in progress, retry shortlySESSION_EXPIRED- Session expired and no auto-refresh availableCOOKIE_EXPIRED- Google cookie has expired
To resolve, update your account configuration via POST /accounts.
Model
-
Both sync and async calls return the job record. Structure matches GET /jobs/
jobidresponse.{ jobid: string // Job identifier verb: 'music/stems' // Job verb jobType: 'music' // Job type status: 'created' | 'completed' | 'failed' created: string // ISO 8601 timestamp updated?: string // ISO 8601 timestamp, once the job ends request: { song_id: number // Decoded Mureka id, not the user:…-song:… form all_stems: boolean account: string async?: boolean replyUrl?: string replyRef?: string } response?: { stems_id: string // Pass to POST /music/stems-download song_id: string all_stems?: boolean bpm?: number status: 'processing' | 'completed' generate_state?: number // Mureka's own state: 3 while extracting, 1 when done stems?: { // Present when completed stem_name: string // e.g. vocal, drums, bass, other wav: string | null mp3: string | null }[] } error?: string // Present when failed code?: number // Present when failed } -
Error response structure (applies to both sync and async modes).
{ jobid?: string // Present for job-related errors error: string // Error summary message code?: number // HTTP status code or error code msg?: string // Additional error message }
Examples
-
curl -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer …" \ -X POST https://api.useapi.net/v1/mureka/music/stems \ -d '{"song_id": "…", "all_stems": true}' -
const song_id = "user:777-mureka:12345678901234-song:33445566"; const all_stems = true; const apiUrl = `https://api.useapi.net/v1/mureka/music/stems`; const api_token = "API token"; const data = { method: 'POST', headers: { 'Authorization': `Bearer ${api_token}`, 'Content-Type': 'application/json' } }; data.body = JSON.stringify({ song_id, all_stems }); const response = await fetch(apiUrl, data); const result = await response.json(); console.log("response", {response, result}); -
import requests song_id = "user:777-mureka:12345678901234-song:33445566" all_stems = True apiUrl = f"https://api.useapi.net/v1/mureka/music/stems" api_token = "API token" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {api_token}" } body = { "song_id": song_id, "all_stems": all_stems } response = requests.post(apiUrl, headers=headers, json=body) print(response, response.json())
Try It
Extraction takes about a minute for a 3-minute song (40 to 70 seconds in our tests).