ElevenLabs CLI
Overview
The ElevenLabs CLI allows you to access your ElevenLabs agents from your terminal, unlocking new ways to manage them:
- Store agents as code in your version control system
- Set up CI/CD integration to automatically deploy your agents
- Let your coding agent access and manage your voice agents
Prefer to jump straight to the code?
Installation
The CLI requires Node.js version 16.0.0 or higher.
After installation, the elevenlabs command will be available globally in your terminal.
Quick start
Initialize a new project
This creates the project structure with configuration directories and registry files.
Project structure
The CLI creates a structured project directory:
Authentication
The CLI stores API keys in ~/.agents/api_keys.json file with restricted permissions (600).
Authentication commands
Agent management
Creating agents
Create agents using pre-built templates:
Options:
--template <type>: Choose from available templates (default: default)--env <env>: Target environment (default: prod)--skip-upload: Create locally without uploading to platform
Example:
Templates
The CLI provides six pre-built templates for common use cases:
default
Complete configuration with all available fields, sensible defaults, full voice/text support, widget customization, and evaluation criteria.
minimal
Essential fields only including basic prompt, language, TTS, and conversation settings.
voice-only
Optimized for voice interactions with disabled text input and advanced voice settings.
text-only
customer-service
Professional empathetic prompts, low temperature (0.1), 30-minute duration, and evaluation criteria.
assistant
General-purpose AI assistant with balanced creativity (temperature 0.3) and versatile voice/text support.
Template commands
Synchronization
Keep your local configurations synchronized with the ElevenLabs platform:
Status and monitoring
Import and export
Tool management
The CLI supports two types of tools for extending agent capabilities:
Webhook tools
HTTP API integrations with authentication and timeout configuration:
Client tools
Direct client-side integrations:
Widget generation
Generate HTML embed code for web integration:
This outputs HTML code like:
Configuration files
Agent configuration structure
Each agent configuration includes:
Environment management
Currently, only one environment is supported per account. Native support for environment separation is coming soon.
Meanwhile, this tool allows for virtual environment separation using different accounts as different virtual environments.