Usage Guide
- This endpoint allows you to extend existing music tracks
- You can choose to use original parameters or set new custom parameters
- Extended music will maintain style consistency with the source track
Parameter Details
-
With Custom Parameters (
defaultParamFlag: true):prompt,style,titleandcontinueAtare requiredpromptlength limit: 3000 charactersstylelength limit: 200 characterstitlelength limit: 80 characters
-
With Original Parameters (
defaultParamFlag: false):- Only
audioIdis required - Other parameters will be inherited from the source audio
- Only
Developer Notes
- Generated files are retained for 14 days
- Model version must match the source audio’s model version
- Callback process follows the same pattern as the music generation endpoint
Optional parameters
vocalGender(string): Vocal gender preference. Usemfor male,ffor female.styleWeight(number): Strength of adherence to style. Range 0–1, up to 2 decimals. Example:0.65.weirdnessConstraint(number): Controls creative deviation. Range 0–1, up to 2 decimals. Example:0.65.audioWeight(number): Balance weight for audio features. Range 0–1, up to 2 decimals. Example:0.65.personaId(string): Persona ID to apply to the generated music. Only available when Custom Mode is enabled. To create one, use Generate Persona.
Authorizations
All APIs require authentication via Bearer Token.
Get API Key:
- Visit API Key Management Page to get your API Key
Usage: Add to request header: Authorization: Bearer YOUR_API_KEY
Note:
- Keep your API Key secure and do not share it with others
- If you suspect your API Key has been compromised, reset it immediately in the management page
Body
Controls parameter source for extension.
- If
true: Use custom parameters specified in this request. RequirescontinueAt,prompt,style, andtitle. - If
false: Use original audio parameters. OnlyaudioIdis required, other parameters are inherited.
true
Unique identifier of the audio track to extend. Required for all extension requests.
"e231****-****-****-****-****8cadc7dc"
Description of the desired audio extension content.
- Required when
defaultParamFlagistrue. - Max length: 3000 characters.
- Describes how the music should continue or change in the extension.
"Extend the music with more relaxing notes and a gentle bridge section"
The AI model version to use for generation.
- Required for all requests.
- Available options:
V5: Superior musical expression, faster generation.V4_5PLUS: V4.5+ is richer sound, new waysto create, max 8 min.V4_5: V4.5 is smarter prompts, fastergenerations, max 8 min.V4: V4 is improved vocal quality,max 4 min.V3_5: V3.5 is better song structure,max 4 min.
V3_5, V4, V4_5, V4_5PLUS, V5 "V3_5"
The URL to receive music extension task completion updates. Required for all music extension requests.
- System will POST task status and results to this URL when extension completes
- Callback process has three stages:
text(text generation),first(first track complete),complete(all tracks complete) - Your callback endpoint should accept POST requests with JSON payload containing extended track results and audio URLs
- For detailed callback format and implementation guide, see Music Extension Callbacks
- Alternatively, use the Get Music Details endpoint to poll task status
"https://api.example.com/callback"
Music style specification for the extended audio.
- Required when
defaultParamFlagistrue. - Max length: 200 characters.
- Should typically align with the original audio's style for best results.
"Classical"
Title for the extended music track.
- Required when
defaultParamFlagistrue. - Max length: 80 characters.
- Will be displayed in player interfaces and filenames.
"Peaceful Piano Extended"
The time point (in seconds) from which to start extending the music.
- Required when
defaultParamFlagistrue. - Value range: greater than 0 and less than the total duration of the generated audio.
- Specifies the position in the original track where the extension should begin.
60
Music styles or traits to exclude from the extended audio. Optional. Use to avoid specific undesired characteristics.
"Heavy Metal, Upbeat Drums"
Vocal gender preference for the singing voice. Optional. Use 'm' for male and 'f' for female. Based on practice, this parameter can only increase the probability but cannot guarantee adherence to male/female voice instructions.
m, f "m"
Strength of adherence to the specified style. Optional. Range 0–1, up to 2 decimal places.
0 <= x <= 1Must be a multiple of 0.010.65
Controls experimental/creative deviation. Optional. Range 0–1, up to 2 decimal places.
0 <= x <= 1Must be a multiple of 0.010.65
Balance weight for audio features vs. other factors. Optional. Range 0–1, up to 2 decimal places.
0 <= x <= 1Must be a multiple of 0.010.65
Only available when Custom Mode (customMode: true) is enabled. Persona ID to apply to the generated music. Optional. Use this to apply a specific persona style to your music generation.
To generate a persona ID, use the Generate Persona endpoint to create a personalized music Persona based on generated music.
"persona_123"
Response
Request successful
Response status code
- 200: Success - Request has been processed successfully
- 401: Unauthorized - Authentication credentials are missing or invalid
- 402: Insufficient Credits - Account does not have enough credits to perform the operation
- 404: Not Found - The requested resource or endpoint does not exist
- 409: Conflict - WAV record already exists
- 422: Validation Error - The request parameters failed validation checks
- 429: Rate Limited - Request limit has been exceeded for this resource
- 451: Unauthorized - Failed to fetch the image. Kindly verify any access limits set by you or your service provider.
- 455: Service Unavailable - System is currently undergoing maintenance
- 500: Server Error - An unexpected error occurred while processing the request
200, 401, 402, 404, 409, 422, 429, 451, 455, 500 Error message when code != 200
"success"
