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
In Host, open the app, go to Environment variables and click Add. Enter the key and value; add as many as you need before redeploying.
For Ambassadors
Open the Ambassador in Host and add variables the same way.
Via the CLI
Apps and Ambassadors each have env set, env list and env delete commands — see the command reference in the developer docs.
Via MCP
"Set the API_KEY environment variable on my customer-portal app to sk-abc123"
Listing Variables
Open Environment variables on the app or Ambassador in Host, or list them from the CLI.
Values may be masked depending on your access level:
- Creators and collaborators see full values
- Viewers see masked values (e.g.,
••••••••)
Deleting Variables
Remove a variable from Environment variables in Host, or delete it by key from the CLI.
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.