Configuration
Lygotype is configured via environment variables in server/.env. Copy server/.env.example to get started.
Required variables
| Variable | Required | Description |
|---|---|---|
| BETTER_AUTH_SECRET | required | A random secret string used to sign sessions. Generate with: openssl rand -base64 32 |
| VITE_API_URL | required | The public URL of your API server. Used by the client at build time. Example: https://lygo.yourdomain.com |
| PORT | required | Port for the Express server. Default: 3001 |
Stripe variables
Required only if you use the payment question type.
| Variable | Required | Description |
|---|---|---|
| STRIPE_SECRET_KEY | optional | Your Stripe secret key (sk_live_... or sk_test_...). Never exposed to the client. |
| STRIPE_WEBHOOK_SECRET | optional | The webhook signing secret from your Stripe dashboard. Used to verify incoming webhook events. |
Never commit your .env file to version control. Your .gitignore already excludes it — keep it that way.
Example .env
``bash
server/.env