Skip to main content
Glama

generate_music

Create AI-generated music from text descriptions using Suno V5. Specify genre, mood, instruments, tempo, and vocal style to produce custom audio tracks.

Instructions

Generate AI music from text description using VAP (Suno V5). Returns a task ID for async tracking. Cost: $0.68.

IMPORTANT: Send ONLY the music description. Do NOT include any instructions or meta-text.

Describe: genre, mood, instruments, tempo, vocal style (or specify instrumental).

Example prompt: "Upbeat indie folk song with acoustic guitar, warm vocals, and light percussion. Feel-good summer vibes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYesMusic description (200-500 chars recommended). Include genre, mood, instruments, tempo.
instrumentalNoGenerate without vocals (instrumental only)
durationNoTarget duration in seconds (30-480, default 120 = 2 min)
loudness_presetNoLoudness normalization. streaming=-14 LUFS (YouTube/Spotify), apple=-16 LUFS, broadcast=-23 LUFS (TV/EBU R128)streaming
audio_formatNoOutput format. WAV for enterprise/lossless (+$0.10)mp3

Implementation Reference

  • The tool call handler which routes 'generate_music' to the default make_request fallback (line 214). Other specific tools like 'generate_video' are handled in custom functions.
    def handle_tools_call(params: Dict) -> Dict:
        """
        Handle tools/call request.
    
        Directive #240: Special handlers for video tools.
        """
        tool_name = params.get("name", "")
        arguments = params.get("arguments", {})
    
        # ═══════════════════════════════════════════════════════════════════
        # VIDEO TOOL HANDLERS (Directive #240)
        # ═══════════════════════════════════════════════════════════════════
    
        if tool_name == "generate_video":
            return _handle_generate_video(arguments)
    
        if tool_name == "estimate_video_cost":
            return _handle_estimate_video_cost(arguments)
    
        if tool_name == "get_task":
            return _handle_get_task(arguments)
    
        # Default: forward to MCP API
        response = make_request("/tools/call", {
            "name": tool_name,
            "arguments": arguments
        })
        return response

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/elestirelbilinc-sketch/Media-infrastructure'

If you have feedback or need assistance with the MCP directory API, please join our Discord server