callBackUrl parameter to set a callback URL. The system will automatically push the results to your specified address when the task is completed.
Callback Mechanism Overview
The callback mechanism eliminates the need to poll the API for task status. The system will proactively push task completion results to your server.
Callback Timing
The system will send callback notifications in the following situations:- Vocal separation task completed successfully
- Vocal separation task failed
- Errors occurred during task processing
Callback Method
- HTTP Method: POST
- Content Type: application/json
- Timeout Setting: 15 seconds
Callback Request Format
When the task is completed, the system will send a POST request to yourcallBackUrl based on the separation type you selected. Different separation types correspond to different callback data structures:
separate_vocal Type Callbacks
split_stem Type Callbacks
Status Code Description
integer
required
Callback status code indicating task processing result:
string
required
Status message providing detailed status description
string
required
Task ID, consistent with the task_id returned when you submitted the task
object
Vocal separation result information, returned on success. The returned fields depend on the separation type (type parameter)
separate_vocal Type Callback Fields
string
Instrumental part audio URL (separate_vocal type only)
string
Original audio URL
string
Vocal part audio URL
split_stem Type Callback Fields
string
Original audio URL
string
Main vocal audio URL
string
Backing vocals audio URL (split_stem type only)
string
Drums part audio URL (split_stem type only)
string
Bass part audio URL (split_stem type only)
string
Guitar part audio URL (split_stem type only)
string
Keyboard part audio URL (split_stem type only)
string
Percussion part audio URL (split_stem type only)
string
Strings part audio URL (split_stem type only)
string
Synthesizer part audio URL (split_stem type only)
string
Effects part audio URL (split_stem type only)
string
Brass part audio URL (split_stem type only)
string
Woodwinds part audio URL (split_stem type only)
Callback Reception Examples
Below are example codes for receiving callbacks in popular programming languages:- Node.js
- Python
- PHP
Best Practices
Troubleshooting
If you are not receiving callback notifications, please check the following:Network Connection Issues
Network Connection Issues
- Confirm callback URL is accessible from public internet
- Check firewall settings to ensure inbound requests are not blocked
- Verify domain name resolution is correct
Server Response Issues
Server Response Issues
- Ensure server returns HTTP 200 status code within 15 seconds
- Check server logs for error messages
- Verify endpoint path and HTTP method are correct
Content Format Issues
Content Format Issues
- Confirm received POST request body is in JSON format
- Check if Content-Type is application/json
- Verify JSON parsing is correct
File Processing Issues
File Processing Issues
- Confirm all audio file URLs are accessible
- Check file download permissions and network connection
- Verify file save path and permissions
- Note that some instrument separation results may be empty
- Note the field differences between separate_vocal and split_stem types
Alternative Solutions
If you cannot use the callback mechanism, you can also use polling:Poll Query Results
Use the Get Vocal Separation Details endpoint to periodically query task status. We recommend querying every 30 seconds.
