FOCUSCurrently working on ScheduleSomething and LayerdEvents algorithmsLearn More
FOCUSCurrently working on ScheduleSomething and LayerdEvents algorithmsLearn More
FOCUSCurrently working on ScheduleSomething and LayerdEvents algorithmsLearn More
FOCUSCurrently working on ScheduleSomething and LayerdEvents algorithmsLearn More
MetapilotGetting Started
System Configuration
DocsmetapilotGetting StartedSystem Configuration
GitHub Live Sync

System Configuration

Live technical documentation fetched from GitHub repository omghante/metapilot/docs/getting-started/configuration.md

Environment Variables Configuration

MetaPilot uses environment variables for security, multi-tenancy secrets, database configuration, Redis channel layers, and OpenRouter AI integrations.
Environment variables are loaded automatically from
services/api/.env
via
python-dotenv
.

Core Variables Reference Table

Variable NameRequired?Default (Dev)Description
SECRET_KEY
Yes
django-insecure-dev-key...
Django core cryptographic signing key
DEBUG
Yes
True
Debug mode (
True
in dev,
False
in prod)
ALLOWED_HOSTS
Yes
localhost,127.0.0.1
Comma-separated list of allowed hostnames
FERNET_KEY
YesDev fallback key32 url-safe base64-encoded bytes key for AES-256 tenant secret encryption
DATABASE_URL
No(Empty -> Uses SQLite)PostgreSQL connection URL e.g.
postgresql://user:pass@localhost:5432/metapilot
CELERY_BROKER_URL
Yes
redis://localhost:6379/0
Redis database URL for Celery task queue
CELERY_RESULT_BACKEND
Yes
redis://localhost:6379/0
Redis database URL for Celery task results
CHANNEL_REDIS_URL
Yes
redis://localhost:6379/1
Redis database URL for Django Channels WebSockets
META_GRAPH_API_VERSION
No
v22.0
Meta WhatsApp Graph API version
WEBHOOK_BASE_URL
No
https://your-domain.com
Public base URL for receiving Meta webhooks
OPENROUTER_API_KEY
No
""
OpenRouter API Key for AI Chatbot and Vision models
WA_CHATBOT_ENABLED
No
True
Enables/Disables WhatsApp AI Auto-responder
WA_CHATBOT_TEXT_MODEL
No
stepfun/step-3.5-flash
LLM model name for text responses
WA_CHATBOT_VISION_MODEL
No
openai/gpt-4o
Vision model name for analyzing images
SCHEDULER_BATCH_SIZE
No
20
Batch size for broadcast job processing
SCHEDULER_RATE_LIMIT_TOKENS
No
50
Maximum messages per second limit

Fernet Key Generation

To generate a production Fernet key, execute:
bash
python scripts/generate_fernet_key.py --write-env
Or via Python directly:
python
python -c "from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())"
[!WARNING] In production (
DEBUG=False
), starting MetaPilot without a valid 32 url-safe base64-encoded
FERNET_KEY
will raise a
ValueError
during initialization to prevent storing unencrypted tenant secrets.