API REFERENCE
Separate audio stems
On this page
/api/music/stem-separationSeparate an audio file into individual stems (vocals, drums, bass, etc.). Upload an audio file via multipart/form-data. Choose between two-stem separation (vocals + instrumental) or six-stem separation (vocals, drums, bass, guitar, piano, other). Returns a ZIP archive containing the separated stems.
Authentication
x-api-key in header
bearerAuth bearer
Request
curl --request POST \
--url 'https://api.recoupable.dev/api/music/stem-separation' \
--header 'x-api-key: YOUR_API_KEY' \
--form 'file=@YOUR_FILE_PATH'Try it
Fill in the fields, send the request from your browser, and read the live response. The curl below updates as you type.
Kept in this browser tab only and cleared when it closes.
curl --request POST \
--url 'https://recoup-api.vercel.app/api/music/stem-separation' \
--header 'Content-Type: multipart/form-data' \
--data '{
"file": "string"
}'Run this one from the terminal with the curl above.
Request body required
Audio file and separation parameters
multipart/form-data
filestringrequiredAudio file to separate into stems
format: binary
stem_variation_idstring · enumStem separation mode. two_stems_v1 produces vocals + instrumental. six_stems_v1 produces vocals, drums, bass, guitar, piano, and other.
Values: "two_stems_v1", "six_stems_v1"
Default: "six_stems_v1"
sign_with_c2pabooleanSign the output with C2PA content credentials
Default: false
output_formatstringAudio output format (e.g. mp3_44100_192)
Responses
200Stems separated successfully. Returns a ZIP archive containing the individual stems.+
application/zip
string
400Validation failed — invalid or missing request body fields+
application/json
errorstringrequiredError message describing what went wrong.
401Unauthorized — invalid or missing API key+
application/json
errorstringrequiredError message describing what went wrong.
500Internal server error+
application/json
errorstringrequiredError message describing what went wrong.
Full specification
Download the OpenAPI file for complete schemas, constraints, and examples.
Download content.jsonView operation source
{
"description": "Separate an audio file into individual stems (vocals, drums, bass, etc.). Upload an audio file via multipart/form-data. Choose between two-stem separation (vocals + instrumental) or six-stem separation (vocals, drums, bass, guitar, piano, other). Returns a ZIP archive containing the separated stems.",
"security": [
{
"apiKeyAuth": []
},
{
"bearerAuth": []
}
],
"requestBody": {
"description": "Audio file and separation parameters",
"required": true,
"content": {
"multipart/form-data": {
"schema": {
"type": "object",
"properties": {
"file": {
"type": "string",
"format": "binary",
"description": "Audio file to separate into stems"
},
"stem_variation_id": {
"type": "string",
"enum": [
"two_stems_v1",
"six_stems_v1"
],
"default": "six_stems_v1",
"description": "Stem separation mode. `two_stems_v1` produces vocals + instrumental. `six_stems_v1` produces vocals, drums, bass, guitar, piano, and other."
},
"sign_with_c2pa": {
"type": "boolean",
"default": false,
"description": "Sign the output with C2PA content credentials"
},
"output_format": {
"type": "string",
"description": "Audio output format (e.g. mp3_44100_192)"
}
},
"required": [
"file"
]
}
}
}
},
"responses": {
"200": {
"description": "Stems separated successfully. Returns a ZIP archive containing the individual stems.",
"content": {
"application/zip": {
"schema": {
"type": "string",
"format": "binary"
}
}
}
},
"400": {
"description": "Validation failed — invalid or missing request body fields",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MusicErrorResponse"
}
}
}
},
"401": {
"description": "Unauthorized — invalid or missing API key",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MusicErrorResponse"
}
}
}
},
"500": {
"description": "Internal server error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MusicErrorResponse"
}
}
}
}
}
}