Environment Variables
Learn about Environment Variables in WaymakerOS.
Environment variables store configuration and secrets for your apps and ambassadors. API keys, database URLs, feature flags — anything your code needs at build time or runtime.
Setting Variables
For Apps
waymaker host env set <app-id> --var API_KEY=sk-abc123 --var DB_URL=postgres://...
For Ambassadors
waymaker host ambassador-env set <ambassador-id> --var API_KEY=sk-abc123
Via MCP
"Set the API_KEY environment variable on my customer-portal app to sk-abc123"
Listing Variables
# Apps
waymaker host env list <app-id>
# Ambassadors
waymaker host ambassador-env list <ambassador-id>
Values may be masked depending on your access level:
- Creators and collaborators see full values
- Viewers see masked values (e.g.,
••••••••)
Deleting Variables
# Apps
waymaker host env delete <app-id> --key API_KEY
# Ambassadors
waymaker host ambassador-env delete <ambassador-id> --key API_KEY
Build-Time vs Runtime
Apps
Environment variables for apps are available at build time. This means:
VITE_*variables are embedded in the built JavaScriptNEXT_PUBLIC_*variables are available in client-side code- Server-side variables are available in SSR functions
- You must redeploy after changing variables for changes to take effect
Ambassadors
Environment variables for ambassadors are available at runtime. They are injected into the function's environment when it executes. Changes take effect on the next deployment.
Limits
| Limit | Value |
|---|---|
| Max variables per app/ambassador | 50 |
| Max key length | 256 characters |
| Max value length | 8,192 characters |
Security
- Variables are stored encrypted in the Waymaker database
- Internal variables (prefixed with
_) are hidden from listings - Only collaborators and creators can view full values
- Variables are transmitted over HTTPS to the build runner
Common Variables
Apps
| Variable | Purpose |
|---|---|
NEXT_PUBLIC_API_URL | Public API endpoint |
VITE_SUPABASE_URL | Platform API URL |
VITE_CLERK_PUBLISHABLE_KEY | Authentication key |
DATABASE_URL | Server-side database connection |
Ambassadors
| Variable | Purpose |
|---|---|
API_KEY | External API authentication |
WEBHOOK_SECRET | Webhook signature verification |
SLACK_WEBHOOK_URL | Slack notification URL |
DATABASE_URL | Database connection string |
Bulk Operations
Set multiple variables at once using the MCP tools:
"Set these environment variables on my app: API_KEY=abc123, DATABASE_URL=postgres://..., ENABLE_CACHE=true"
The set_env_vars action accepts an object of key-value pairs and merges them with existing variables.