callBackUrl parameter to set a callback URL. When the task is completed, the system will automatically push the results to your specified address.
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:- Text generation completed (
textstage) - First covered audio track generated (
firststage) - All covered audio tracks generated (
completestage) - Audio cover task failed
- Error occurred during task processing
Callback Method
- HTTP Method: POST
- Content Type: application/json
- Timeout: 15 seconds
Callback Request Format
When the task is completed, the system will send a POST request to yourcallBackUrl in the following format:
Status Code Description
Callback status code indicating task processing result:
| Status Code | Description |
|---|---|
| 200 | Success - Audio cover completed |
| 400 | Bad Request - Invalid upload source or parameter error |
| 401 | Unauthorized - Invalid API key |
| 413 | Content Too Long - Prompt or style description exceeds limit |
| 429 | Insufficient Credits - Account credit balance insufficient |
| 500 | Server Error - Please retry later |
Status message providing detailed status description
Callback type indicating the current callback stage:
text: Text generation completedfirst: First covered audio track generatedcomplete: All covered audio tracks generatedfailed: Task failed
Task ID, consistent with the taskId returned when you submitted the task
Audio cover result information, returned on success
Audio unique identifier (audioId)
Covered audio file download link
Original covered audio file download link
Streaming audio playback link
Music cover image link
Cover prompt used
AI model name used for cover generation
Covered music title
Music style tags
Creation time
Covered audio duration (seconds)
Best Practices
Alternative Solutions
If you cannot use the callback mechanism, you can also use polling:Poll Cover Results
Use the Get Music Generation Details interface to regularly query cover task status. Recommend querying every 30 seconds.
