music-2.0
A fast and cost-efficient music generator optimized for high-quality music production. The model creates full-length songs (up to 4 minutes) featuring natural-sounding vocals and detailed instrumental arrangements.
Setup your API Key
If you donβt have an API key for the AI/ML API yet, feel free to use our Quickstart guide.
API Schemas
Generate music sample
This endpoint generates a music piece based on the prompt (which includes style instructions) and the provided lyrics. It returns a generation task ID, its status, and related metadata.
A description of the music, specifying style, mood, and scenario. Length: 10β2000 characters.
Lyrics of the song. Use ( ) to separate lines. You may add structure tags like [Intro], [Verse], [Chorus], [Bridge], [Outro] to enhance the arrangement. Length: 10β3000 characters.
[Verse] Streetlights flicker, the night breeze sighs Shadows stretch as I walk alone An old coat wraps my silent sorrow Wandering, longing, where should I go [Chorus] Pushing the wooden door, the aroma spreads In a familiar corner, a stranger gazesRetrieve the generated music sample from the server
After sending a request for music generation, this task is added to the queue. This endpoint lets you check the status of a audio generation task using its id, obtained from the endpoint described above.
If the video generation task status is complete, the response will include the final result β with the generated audio URL and additional metadata.
Bearer key
<REPLACE_WITH_YOUR_GENERATION_ID>Quick Code Example
Hereβs an example of generating an audio file using a prompt with style instructions and a separate parameter for the lyrics.
Listen to the track we generated:
Last updated
Was this helpful?