Environment variables
Below you can find a comprehensive list of environment variables used in particular services.
If you would like to find how to set correct environment on AWS check this guide.
backend
service
Required variables:
Name | Description | Example |
---|---|---|
DJANGO_DEBUG | docs | True |
DJANGO_SECRET_KEY | docs | Zs639zRcb5!9om2@tW2H6XG#Znj^TB^I |
HASHID_FIELD_SALT | docs | t5$^r\*xsMRXn1xjzhRSl8I5Hb3BUW$4U |
ADMIN_EMAIL | Will be used to create first super admin user | [email protected] |
ADMIN_DEFAULT_PASSWORD | Will be used to create first super admin user | AvPZpabgj9Z8 |
Required variables for Stripe usage:
Name | Description | Example |
---|---|---|
STRIPE_TEST_SECRET_KEY | Use this one for Stripe test mode. docs | sk_test_4dEFRCLCgCb |
STRIPE_LIVE_SECRET_KEY | Use this one for Stripe live mode. docs | sk_4dEFRCLCgCbMy6O4FX |
DJSTRIPE_WEBHOOK_SECRET | docs | whsec_12345 |
STRIPE_LIVE_MODE | (bool) Set true or false to toggle between live and test Stripe mode. By default set to False | true |
Optional variables:
Name | Description | Example |
---|---|---|
SENTRY_DSN | Sentry client key | https://(...)@(...).ingest.sentry.io/(...) |
SOCIAL_AUTH_ALLOWED_REDIRECT_HOSTS | Allowed hosts for OAuth redirection. Check Python Social Auth package documentation for more details | app.demo.saas.apptoku.com |
SOCIAL_AUTH_FACEBOOK_KEY | Client key for Facebook OAuth integration | |
SOCIAL_AUTH_FACEBOOK_SECRET | Client secret for Facebook OAuth integration | |
SOCIAL_AUTH_GOOGLE_OAUTH2_KEY | Client key for Google OAuth integration | |
SOCIAL_AUTH_GOOGLE_OAUTH2_SECRET | Client secret for Google OAuth integration | |
SUBSCRIPTION_TRIAL_PERIOD_DAYS | Number of days for subscription trial. By default set to 7 | 1 |
OPENAI_API_KEY | OpenAI API for generative AI module |
workers
service
Required variables:
Name | Description | Example |
---|---|---|
FROM_EMAIL | Email used in From email field | [email protected] |
HASHID_SALT | docs | t5$^r\*xsMRXn1xjzhRSl8I5Hb3BUW$4U |
JWT_SECRET | Secret used to decode JWT used in subscriptions. The value needs to be the same as DJANGO_SECRET_KEY backend environment variable | |
WEB_APP_URL | https://app.demo.saas.apptoku.com |
Optional variables (in order to use contentful or sentry services):
Name | Description |
---|---|
CONTENTFUL_ACCESS_TOKEN | Contentful API access token |
CONTENTFUL_ENVIRONMENT | Contentful environment name |
CONTENTFUL_SPACE_ID | Contentful Space ID |
SENTRY_DSN | Sentry client key |
webapp
service
Required variables:
Name | Description | Example |
---|---|---|
VITE_BASE_API_URL | Path to access backend API | /api |
WEB_APP_URL | ||
VITE_EMAIL_ASSETS_URL | Absolute URL to application | https://example.com |
Optional variables (in order to use contentful or stripe services):
Name | Description |
---|---|
VITE_CONTENTFUL_SPACE | Contentful Space ID |
VITE_CONTENTFUL_TOKEN | Contentful API access token |
VITE_CONTENTFUL_ENV | Contentful environment name |
VITE_STRIPE_PUBLISHABLE_KEY | Stripe Publishable key |
VITE_SENTRY_DSN | Sentry client key |
VITE_GOOGLE_ANALYTICS_TRACKING_ID | Google Analytics 4 GTM ID |