Skip to main content

The official Cartesia MCP server

Project description

Cartesia MCP Server

PyPI version

The Cartesia MCP server exposes Cartesia APIs over the Model Context Protocol (MCP) so clients such as Cursor, Claude Desktop, and OpenAI Agents can list voices, run TTS and STT, manage pronunciation dictionaries, clone voices, and more—without one-off scripts.

Documentation: Cartesia docs — MCP

Requirements

  • uv — runs the server via uvx with no global install
  • Python 3.13+ (installed automatically by uvx)
  • A Cartesia API key for TTS, STT, voices, and related APIs
  • Optionally, an admin API key (Keys → Admin) for management tools such as get_credit_usage. Admin keys and standard keys are separate credentials; each only works on its own route class.

Setup

Get an API key. Full instructions: Cartesia docs — MCP.

CLI (recommended)npx add-mcp "uvx cartesia-mcp" --name cartesia-mcp --env 'CARTESIA_API_KEY=${CARTESIA_API_KEY}'

CursorInstall Cartesia MCP, then set CARTESIA_API_KEY in Settings → MCP.

Claude Codeclaude mcp add -e CARTESIA_API_KEY=<your-api-key> cartesia-mcp -- uvx cartesia-mcp

Manual setup

Add to .cursor/mcp.json, .mcp.json (Claude Code), or your client’s MCP config:

{
  "mcpServers": {
    "cartesia-mcp": {
      "command": "uvx",
      "args": ["cartesia-mcp"],
      "env": {
        "CARTESIA_API_KEY": "<your-api-key>"
      }
    }
  }
}

Try it

Ask your agent things like:

  • List all available Cartesia voices
  • Convert text to audio with a chosen voice (speed, volume, emotion)
  • Transcribe an audio file to text
  • Create a pronunciation dictionary and use it in TTS
  • Check credit usage for your account
  • Localize an existing voice into another language
  • Change an audio file to use a different voice

Tools

Tool Description
text_to_speech Convert text to audio; optional speed, volume, emotion, and pronunciation dict
speech_to_text Batch-transcribe an audio file (ink-whisper)
list_voices List available voices (filter by language, search, gender, etc.)
get_voice Fetch metadata for a voice by ID
clone_voice Clone a voice from an audio sample
update_voice Update a cloned voice's name or description
delete_voice Delete a cloned voice
voice_change Re-render audio with a different voice
localize_voice Adapt a voice to another language or dialect
list_pronunciation_dicts List pronunciation dictionaries
create_pronunciation_dict Create a pronunciation dictionary
get_pronunciation_dict Get a pronunciation dictionary by ID
update_pronunciation_dict Update a pronunciation dictionary
delete_pronunciation_dict Delete a pronunciation dictionary
get_credit_usage Credit usage over time (CARTESIA_ADMIN_API_KEY)

See cartesia_mcp/server.py for parameters and return types.

Releases

Versions and PyPI publishes are driven by Conventional Commits on main via release-please. Use PR titles like feat: … or fix: … (especially when squash merging). See CONTRIBUTING.md.

Testing

Unit tests (no API keys):

uv sync --dev
uv run pytest

Smoke-test all tools (requires CARTESIA_API_KEY):

uv run python scripts/test_all_tools.py

The script creates temporary cloned/localized voices and pronunciation dictionaries, then deletes only those. It does not delete catalog or other existing resources.

Advanced

Output directory

By default, generated audio is written to the server's working directory. To choose a fixed folder, add OUTPUT_DIRECTORY to env:

"env": {
  "CARTESIA_API_KEY": "<your-api-key>",
  "OUTPUT_DIRECTORY": "~/cartesia-output"
}

Local audio files

Tools like speech_to_text and voice_change need paths to existing audio files on disk. Pass the full path to each file when prompting your agent.

Admin API key

Some tools call management endpoints that accept admin API keys only (sk_car_admin_...). Set CARTESIA_ADMIN_API_KEY in env alongside CARTESIA_API_KEY:

  • CARTESIA_API_KEY — TTS, STT, voices, pronunciation dictionaries, voice changer, etc.
  • CARTESIA_ADMIN_API_KEY — optional; required for get_credit_usage today. Admin keys do not work on generation routes, and standard keys do not work on admin routes.

Mint admin keys in the Playground under Keys → Admin (org admins only).

API version

All tools send Cartesia-Version (default 2026-03-01, the latest in Cartesia docs). Override with CARTESIA_VERSION in env if you pin an older integration date.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cartesia_mcp-0.6.1.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cartesia_mcp-0.6.1-py3-none-any.whl (14.8 kB view details)

Uploaded Python 3

File details

Details for the file cartesia_mcp-0.6.1.tar.gz.

File metadata

  • Download URL: cartesia_mcp-0.6.1.tar.gz
  • Upload date:
  • Size: 14.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for cartesia_mcp-0.6.1.tar.gz
Algorithm Hash digest
SHA256 2137d8230ae6ca8af8ad90c25269053cb5fa1ba38e3b72bf9027b3bec23132c3
MD5 4047f66cbc75a12975cebf21d83f0789
BLAKE2b-256 3ceb90ba7d365a05affc8175dfbf7806d0907d4a91afbf21439c587049501fba

See more details on using hashes here.

File details

Details for the file cartesia_mcp-0.6.1-py3-none-any.whl.

File metadata

  • Download URL: cartesia_mcp-0.6.1-py3-none-any.whl
  • Upload date:
  • Size: 14.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for cartesia_mcp-0.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fcd26a438f6a092fc18f2e9eafbe694c14da37dfd9231aa85a83f1dabf2805be
MD5 dd6d1c96214ef6acf8b1042fbae2e721
BLAKE2b-256 f740deab23f1c9f9be36e73b106c2722211df1f5b9bbfdde78fd4ae152987001

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page