Overview
Vaani uses environment variables for all configuration. Variables are loaded viapydantic-settings with optional .env file support.
.env file loading: Automatic in local, dev, and development environments. Disabled in production (use Docker env_file or system env vars).
Backend Variables
- Core
- Database
- Auth & Security
- LiveKit
- AI Providers
- Telephony
- Storage
| Variable | Required | Example | Description |
|---|---|---|---|
ENV | ✅ | local | Environment: local, dev, stage, prod |
LOAD_DOTENV | ✅ | 1 | Enable .env file loading |
FRONTEND_URL | — | http://localhost:3000 | CORS allowed origin |
LOG_DIR | ✅ | /var/log/vaani | Log file directory |
LOG_LEVEL | ✅ | INFO | Logging level |
LOG_RETENTION_DAYS | ✅ | 30 | Log file retention |
MAX_AGENT_SESSIONS | ✅ | 10 | Max concurrent voice calls |
CELERY_TIMEZONE | ✅ | UTC | Timezone for Celery Beat |
UI Variables
| Variable | Required | Example | Description |
|---|---|---|---|
NEXT_PUBLIC_ML_BACKEND_URL | ✅ | http://localhost:8000 | Backend API URL |
JWT_API_SECRET | ✅ | Same as backend | JWT secret (must match) |
ALLOWED_BOT_ORIGINS | — | http://localhost:5173 | Allowed widget origins |