ElevenLabs Extension
This tutorial covers how to add the ElevenLabs MCP Server as a zai extension to enable AI-powered voice generation, voice cloning, audio editing, and speech-to-text transcription.
- zai Desktop
- zai CLI
Command
uvx elevenlabs-mcp
Environment Variable
ELEVENLABS_API_KEY: <YOUR_API_KEY>
Configuration
Note that you'll need uv installed on your system to run this command, as it uses uvx.
- zai Desktop
- zai CLI
- Launch the installer
- Click
Yesto confirm the installation - Get your ElevenLabs API Key and paste it in
- Click
Add Extension - Click the button in the top-left to open the sidebar
- Navigate to the chat
- Run the
configurecommand:
zai configure
- Choose to add a
Command-line Extension.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◆ What type of extension would you like to add?
│ ○ Built-in Extension
│ ● Command-line Extension (Run a local command or script)
│ ○ Remote Extension (Streamable HTTP)
└
- Give your extension a name.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◇ What type of extension would you like to add?
│ Command-line Extension
│
◆ What would you like to call this extension?
│ ElevenLabs
└
- Enter the command to run when this extension is used.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◇ What type of extension would you like to add?
│ Command-line Extension
│
◇ What would you like to call this extension?
│ ElevenLabs
│
◆ What command should be run?
│ uvx elevenlabs-mcp
└
- Enter the number of seconds zai should wait for actions to complete before timing out. Default is
300seconds.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◇ What type of extension would you like to add?
│ Command-line Extension
│
◇ What would you like to call this extension?
│ ElevenLabs
│
◇ What command should be run?
│ uvx elevenlabs-mcp
│
◆ Please set the timeout for this tool (in secs):
│ 300
└
- Enter a description for this extension.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◇ What type of extension would you like to add?
│ Command-line Extension
│
◇ What would you like to call this extension?
│ ElevenLabs
│
◇ What command should be run?
│ uvx elevenlabs-mcp
│
◇ Please set the timeout for this tool (in secs):
│ 300
│
◆ Enter a description for this extension:
│ ElevenLabs voice synthesis server
└
- Add an environment variable for this extension.
┌ zai-configure
│
◇ What would you like to configure?
│ Add Extension
│
◇ What type of extension would you like to add?
│ Command-line Extension
│
◇ What would you like to call this extension?
│ ElevenLabs
│
◇ What command should be run?
│ uvx elevenlabs-mcp
│
◇ Please set the timeout for this tool (in secs):
│ 300
│
◇ Enter a description for this extension:
│ ElevenLabs voice synthesis server
│
◆ Would you like to add environment variables?
│ Yes
│
◇ Environment variable name:
│ ELEVENLABS_API_KEY
│
◇ Environment variable value:
│ ▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪▪
│
◇ Add another environment variable?
│ No
│
└ Added ElevenLabs extension
Example Usage
In this example, I’ll show you how to use zai with the ElevenLabs Extension to create AI-generated voiceovers for a YouTube Short. zai will take a sample script I provided, generate a narrated version using different AI voices, and seamlessly switch tones mid-script to match the content flow.
By connecting to the ElevenLabs MCP server, zai can transform plain text into natural-sounding speech, offering multiple voice styles and character options — all without any manual recording or editing.
zai Prompt
Hey zai, create a script for me for my youtube short video, I want there to be two different voices. The first voice should cut me off and be a human narrator style and then switch to a casual AI tone after I read the prompt. Here's an example of a YT short script I've done in the past:
Wait… Within Seconds, zai performed Security Audits Across Multiple Projects?! 🔥
Lets, plug & play to find out how
Let’s provide zai with the command it needs to connect to the Filesystem MCP server extension…
Now lets play prompt: "Hey zai, I need to perform a security audit across multiple projects. Let's check for…🔹 Hardcoded Credentials – API keys, passwords, and secrets left in the code.🔹 SQL Injection Risks – Unsafe queries that could expose data.🔹 Insecure Cryptographic Practices – Weak encryption methods that put data at risk.AND🔹 Exposed Config Files – Sensitive information that shouldn't be public.🔹 Outdated Dependencies – Security vulnerabilities in third-party libraries."
Go zai, go zai!
✅ zai scanned the entire codebase across 3 different projects, identified security risks, generated a detailed report with fixes and provided me with step by step instructions on how I can test and verify these code fixes!
If that’s not amazing idk what is …
🚀 to get started visit https://zunchuang.tech/zai/docs_
zai Output
I'll create your YouTube script for you using the given script as reference.
───────────── Text To Speech ─────────────
───────────── Text To Speech ─────────────
───────────── Text To Speech ─────────────
───────────── Text To Speech ─────────────
───────────── Text To Speech ─────────────
───────────── Play Audio ────────────────
───────────── Play Audio ────────────────
The script has been created and read aloud using the specified voices and style. The audio files have been saved to your desktop.
Press play and hear it for yourself! 🔊