Text-to-Speech MCP

by nakamurau1

Not rated
GitHub

About

High-quality text-to-speech generation using the OpenAI TTS API.

Details

Author
nakamurau1
Categories
Communication, Other

Setup

Install Text-to-Speech MCP in your MCP client (Claude Desktop, Cursor, Windsurf, and others).

Repository: https://github.com/nakamurau1/tts-mcp

Follow the installation instructions in the repository README, then restart your MCP client.

A Model Context Protocol (MCP) server and command-line tool for high-quality text-to-speech generation using the OpenAI TTS API.

- MCP Server: Integrate text-to-speech capabilities with Claude Desktop and other MCP-compatible clients
- Voice Options: Support for multiple voice characters (alloy, nova, echo, etc.)
- High-Quality Audio: Support for various output formats (MP3, WAV, OPUS, AAC)
- Customizable: Configure speech speed, voice character, and additional instructions
- CLI Tool: Also available as a command-line utility for direct text-to-speech conversion

# Clone the repository git clone https://github.com/nakamurau1/tts-mcp.git cd tts-mcp # Install dependencies npm install # Optional: Install globally npm install -g .

Method 2: Run Directly with npx (No Installation Required)

# Start the MCP server directly npx tts-mcp tts-mcp-server --voice nova --model tts-1-hd # Use the CLI tool directly npx tts-mcp -t "Hello, world" -o hello.mp3

The MCP server allows you to integrate text-to-speech functionality with Model Context Protocol (MCP) compatible clients like Claude Desktop.

# Start with default settings npm run server # Start with custom settings npm run server -- --voice nova --model tts-1-hd # Or directly with API key node bin/tts-mcp-server.js --voice echo --api-key your-openai-api-key
Options: -V, --version Display version information -m, --model <model> TTS model to use (default: "gpt-4o-mini-tts") -v, --voice <voice> Voice character (default: "alloy") -f, --format <format> Audio format (default: "mp3") --api-key <key> OpenAI API key (can also be set via environment variable) -h, --help Display help information

The MCP server can be used with Claude Desktop and other MCP-compatible clients. For Claude Desktop integration:
- Open the Claude Desktop configuration file (typically at~/Library/Application Support/Claude/claude_desktop_config.json)
- Add the following configuration, including your OpenAI API key:

{ "mcpServers": { "tts-mcp": { "command": "node", "args": ["full/path/to/bin/tts-mcp-server.js", "--voice", "nova", "--api-key", "your-openai-api-key"], "env": { "OPENAI_API_KEY": "your-openai-api-key" } } } }

Alternatively, you can use npx for easier setup:

{ "mcpServers": { "tts-mcp": { "command": "npx", "args": ["-p", "tts-mcp", "tts-mcp-server", "--voice", "nova", "--model", "gpt-4o-mini-tts"], "env": { "OPENAI_API_KEY": "your-openai-api-key" } } } }

You can provide the API key in two ways:
- Direct method(recommended for testing): Include it in theargsarray using the--api-keyparameter
- Environment variable method(more secure): Set it in theenvobject as shown above

Security Note: Make sure to secure your configuration file when including API keys.
- Restart Claude Desktop
- When you ask Claude to "read this text aloud" or similar requests, the text will be converted to speech

- text-to-speech: Tool for converting text to speech and playing it

You can also use tts-mcp as a standalone command-line tool:

# Convert text directly tts-mcp -t "Hello, world" -o hello.mp3 # Convert from a text file tts-mcp -f speech.txt -o speech.mp3 # Specify custom voice tts-mcp -t "Welcome to the future" -o welcome.mp3 -v nova
Options: -V, --version Display version information -t, --text <text> Text to convert -f, --file <path> Path to input text file -o, --output <path> Path to output audio file (required) -m, --model <n> Model to use (default: "gpt-4o-mini-tts") -v, --voice <n> Voice character (default: "alloy") -s, --speed <number> Speech speed (0.25-4.0) (default: 1) --format <format> Output format (default: "mp3") -i, --instructions <text> Additional instructions for speech generation --api-key <key> OpenAI API key (can also be set via environment variable) -h, --help Display help information

The following voice characters are supported:

- alloy (default)
- ash
- coral
- echo
- fable
- onyx
- nova
- sage
- shimmer

- tts-1
- tts-1-hd
- gpt-4o-mini-tts (default)

The following output formats are supported:

You can also configure the tool using system environment variables:

Text-to-speech generation with conversation history features using the ElevenLabs API.

Generate high-quality text-to-speech and text-to-voice outputs using the DAISYS platform.

Interact with MiniMax's powerful Text-to-Speech, image, and video generation APIs.

Hosted MCP server for AudioPod's audio AI: text-to-speech, voice cloning, music generation, stem and speaker separation, transcription, denoise, and voice conversion.

Interact with MiniMax's powerful APIs for text-to-speech, voice cloning, and video/image generation.

A JavaScript/TypeScript server for MiniMax MCP, offering image/video generation, text-to-speech, and voice cloning.

AI transcription from URLs or local files: 119 languages, speaker diarization, word-level timestamps, SRT/VTT/text export.

A simple text-to-speech server that plays audio from text, supporting multiple voice models.

Cinema-grade video production MCP server — 8 tools for recording, editing, effects, captions, TTS, and smart screenshots. Built on ffmpeg + Playwright.

Converts text summaries to speech using OpenAI's Text-to-Speech API and plays them in the background.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.