ElevenLabs Voice Manager
Voice library browsing, subscription monitoring, and TTS playground with model and voice settings controls
ElevenLabs Voice Manager
The ElevenLabs page at /admin/elevenlabs provides voice library browsing, subscription usage monitoring, and a text-to-speech playground. It connects to the ElevenLabs REST API via xi-api-key header authentication.
Architecture
Admin UI → /api/admin/elevenlabs-manage → ElevenLabs REST API
├── /v1/voices (library)
├── /v1/models (model list)
├── /v1/user/subscription (usage)
└── /v1/text-to-speech/:voiceId (generate)
All requests go through /api/admin/elevenlabs-manage. The generate-speech action returns raw audio/mpeg binary directly to the browser for playback.
Page Layout
Stats Row
Four stat cards:
- Tier — subscription tier name (e.g., “free”)
- Characters — used / limit with visual progress
- Voices — number of available voices
- Models — number of TTS models
Voice Library Tab
Grid of voice cards showing:
- Voice name and category (e.g., “premade”, “cloned”)
- Labels: accent, gender, age, description, use case
- Preview button — plays the voice’s sample audio from ElevenLabs CDN
Voices are fetched from /v1/voices and include both premade library voices and any custom/cloned voices on the account.
TTS Playground Tab
Interactive speech generation form:
- Text — textarea for the text to synthesize
- Voice — dropdown populated from the voice library
- Model — dropdown of available TTS models (default:
eleven_turbo_v2_5) - Stability — slider (0.0 to 1.0, default 0.5) — lower = more expressive, higher = more consistent
- Similarity Boost — slider (0.0 to 1.0, default 0.75) — higher = closer to original voice
- Generate button with loading state
- Audio player — appears after generation, plays the synthesized audio
The generated audio is returned as audio/mpeg binary and loaded into a <audio> element via URL.createObjectURL().
API Route
Route: /api/admin/elevenlabs-manage
Auth: Admin-only (CF Access JWT validation)
GET
Health check — returns connection status, subscription tier, character count, and character limit.
POST Actions
All POST requests take { "action": "...", ...params }:
| Action | Parameters | Returns |
|---|---|---|
list-voices | none | voices[] (id, name, category, labels, preview_url) |
list-models | none | models[] (id, name, description, can_do_text_to_speech) |
get-subscription | none | tier, characterCount, characterLimit, voiceCount, voiceLimit, nextReset |
generate-speech | text, voiceId, modelId (optional), stability (optional), similarityBoost (optional) | Raw audio/mpeg binary |
Error Handling
- Missing API key → 500 with configuration error
- Missing required params (text, voiceId) → 400
- ElevenLabs API errors → 502 with error text
- Health check and list actions have 5-10 second timeouts; speech generation has a 30-second timeout
Environment Variables
| Variable | Required | Description |
|---|---|---|
ELEVENLABS_API_KEY | Yes | ElevenLabs API key (sk_...) |
Set in production via npx wrangler pages secret put. For local dev, add to .env or .dev.vars.
Free Tier Limits
The free tier provides 10,000 characters per month with monthly reset. Character count includes all text sent to the TTS endpoint — both from the admin playground and from agent tools (OpenClaw voice-call). Monitor usage via the stats row or the get-subscription action.
Voice Usage Across Arcturus-Prime
ElevenLabs voices are used in multiple places:
| Feature | Location | How |
|---|---|---|
| TTS Playground | /admin/elevenlabs | Direct API call, audio returned to browser |
| Argonaut voice mode | /admin/argonaut chat | Browser STT (Whisper) → AI → ElevenLabs TTS → speaker |
| OpenClaw voice-call | Agent tool | Generates audio but currently falls back to Polly (needs public audio URL hosting) |
The default voice is Adam (pNInz6obpgDQGcFmaJgB) with the eleven_turbo_v2_5 model.
Related
- Twilio Dashboard (
/admin/twilio) — phone calls using Polly voices via TwiML - Argonaut Hub (
/admin/argonaut) — voice chat mode using ElevenLabs TTS - OpenClaw Gateway (
/admin/openclaw) — agent with voice-call tool capability