#11463: feat(tts): add MiniMax as a core TTS provider
docs
channel: voice-call
gateway
Cluster:
Voice Call and TTS Improvements
## Summary
- Add **MiniMax TTS** as a fourth core provider alongside OpenAI, ElevenLabs, and Edge
- MiniMax offers 300+ system voices across 40+ languages with HD and Turbo model variants
- Configurable: model, voiceId, speed, vol, pitch, languageBoost, baseUrl
- API key resolves from config or `MINIMAX_API_KEY` env var
- Supports mp3 output (messages/Telegram) and pcm output (telephony/voice-call)
- Auto-detection priority when no provider is configured: openai → elevenlabs → minimax → edge
## Changes
**Core (5 files):**
- `src/config/types.tts.ts` — added `"minimax"` to `TtsProvider` union, added minimax config to `TtsConfig`
- `src/config/zod-schema.core.ts` — added `"minimax"` to `TtsProviderSchema`, added minimax Zod object
- `src/tts/tts.ts` — added `minimaxTTS()` function, updated output format maps, `ResolvedTtsConfig`, `TtsDirectiveOverrides`, `resolveTtsConfig()`, `resolveTtsApiKey()`, `getTtsProvider()`, `TTS_PROVIDERS`, `parseTtsDirectives()`, `textToSpeech()`, `textToSpeechTelephony()`
- `src/gateway/server-methods/tts.ts` — added minimax to provider validation, status, and provider list
- `src/auto-reply/reply/commands-tts.ts` — added minimax to `/tts provider` command
**Voice-call extension (3 files):**
- `extensions/voice-call/src/config.ts` — added minimax to TTS schema
- `extensions/voice-call/openclaw.plugin.json` — added minimax to JSON Schema
- `extensions/voice-call/index.ts` — added minimax config labels
**Docs + Tests (2 files):**
- `docs/tts.md` — added minimax config example and field documentation
- `src/tts/tts.test.ts` — added minimax config resolution tests, provider auto-detection test, directive parsing test
## Config example
```json5
{
messages: {
tts: {
provider: "minimax",
minimax: {
apiKey: "your-key", // or MINIMAX_API_KEY env var
model: "speech-2.8-hd", // default
voiceId: "Friendly_Person", // default
speed: 1.0,
languageBoost: "auto",
},
},
},
}
```
## MiniMax TTS API details
- Endpoint: `POST https://api.minimax.io/v1/t2a_v2`
- Auth: Bearer token
- Response: hex-encoded audio in `data.audio`
- Models: `speech-2.8-hd` (best quality), `speech-2.8-turbo` (faster)
- Formats: mp3, pcm, flac
## Test plan
- [x] `pnpm build` passes (types compile)
- [x] `pnpm check` passes (lint + format)
- [x] `pnpm test` passes (958 files, 6499 tests, 0 failures)
- [x] New minimax-specific tests: config resolution defaults, custom config values, provider auto-detection with MINIMAX_API_KEY, directive parsing with minimax_voice
- [ ] Manual test with real MiniMax API key (tested locally, audio output works)
Most Similar PRs
#11704: feat(tts): OpenAI TTS baseUrl support for local servers (Chatterbox...
by mateusz-michalik · 2026-02-08
67.5%
#7965: feat(tts): add Speechify as TTS provider
by chaerla · 2026-02-03
64.8%
#19351: fix: enable tool_use/result pairing repair for MiniMax models
by thebtf · 2026-02-17
64.4%
#4734: fix: auto-detect China region for MiniMax API endpoint selection
by akramcodez · 2026-01-30
62.9%
#20675: fix(minimax): enable tool-use/result repair and drop malformed assi...
by jamesbuddy-claw · 2026-02-19
62.6%
#9041: feat(tts): Add post-processing hook for voice modulation
by robottwo · 2026-02-04
62.1%
#10870: feat(tts): add pocket-tts provider for local CPU-based TTS
by fayrose · 2026-02-07
61.6%
#20794: feat(tts): add Fish Audio provider with full docs, tests & gateway ...
by twangodev · 2026-02-19
61.5%
#20904: feat: Cloud.ru FM proxy, MAX Messenger extension, AI Fabric integra...
by dzhechko · 2026-02-19
61.3%
#10356: TTS: add Typecast provider (emotion presets, audio tuning, Asian la...
by hmmhmmhm · 2026-02-06
60.7%