Skip to main content
Glama

voice_clone

Create a voice clone from provided audio files using ElevenLabs technology to replicate a specific voice for text-to-speech applications.

Instructions

Create an instant voice clone of a voice using provided audio files.

⚠️ COST WARNING: This tool makes an API call to ElevenLabs which may incur costs. Only use when explicitly requested by the user.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
descriptionNo
filesYes
nameYes

Implementation Reference

  • The main handler function for the 'voice_clone' tool. It processes input files, calls the ElevenLabs API to create an instant voice clone (IVC), and returns success information including the new voice ID.
    def voice_clone(
        name: str, files: list[str], description: str | None = None
    ) -> TextContent:
        input_files = [str(handle_input_file(file).absolute()) for file in files]
        voice = client.voices.ivc.create(
            name=name, description=description, files=input_files
        )
    
        return TextContent(
            type="text",
            text=f"""Voice cloned successfully: Name: {voice.name}
            ID: {voice.voice_id}
            Category: {voice.category}
            Description: {voice.description or "N/A"}""",
        )
  • The @mcp.tool decorator registers the 'voice_clone' function as an MCP tool, including its description and parameters (name: str, files: list[str], description: str | None).
    @mcp.tool(
        description="""Create an instant voice clone of a voice using provided audio files.
    
        ⚠️ COST WARNING: This tool makes an API call to ElevenLabs which may incur costs. Only use when explicitly requested by the user.
        """
    )

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/projectservan8n/elevenlabs-mcp'

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