Documentation

Environment Variables

Configure your project through environment variables to enable all required third-party integration services

Environment Variable System Overview

VibeAny supports two ways to configure environment variables:

  1. Via environment variable files — for values that rarely change, such as database connection URLs and auth secrets.
  2. Via the admin config panel — for values that change frequently. VibeAny provides a dynamic config panel where you can modify variables at any time, such as payment keys and email server settings.

Configuration via Environment Variable Files

Site URL Configuration

VariableDescription
VITE_APP_URLSite URL

Database

See the database setup documentation for more detailed instructions.

VariableDescription
DATABASE_URLDatabase connection URL

Authentication

See the authentication setup documentation for more detailed instructions.

VariableDescription
ADMIN_EMAILSAdmin email addresses
BETTER_AUTH_SECRETAuth secret key
BETTER_AUTH_URLAuth URL

BETTER_AUTH_SECRET can be generated on the better-auth website, or click the button below to generate one:

If you want to use OAuth (GitHub or Google login), configure the following:

VariableDescription
GITHUB_CLIENT_IDGitHub OAuth Client ID
GITHUB_CLIENT_SECRETGitHub OAuth Client Secret
GOOGLE_CLIENT_IDGoogle OAuth Client ID
GOOGLE_CLIENT_SECRETGoogle OAuth Client Secret

TURNSTILE

VibeAny uses TURNSTILE as a captcha service to protect your website. You need to register an account on the TURNSTILE website and create a site to get the site key. See the captcha setup documentation for more details.

VariableDescription
TURNSTILE_SECRET_KEYTURNSTILE secret key, can be generated in the Cloudflare Dashboard
VITE_TURNSTILE_SITE_KEYTURNSTILE site key, can be obtained from the Cloudflare Dashboard
VITE_TURNSTILE_CAPTCHA_ENABLEDEnable TURNSTILE captcha, true to enable, false to disable

Email

You can use the Resend service or a custom email server. VibeAny recommends using Resend. See the email setup documentation for more details.

Email verification is disabled by default. Configure an email provider so users can verify their accounts:

EMAIL_VERIFICATION_ENABLED=false

For Resend, you need to create an API key at Resend.

VariableDescription
EMAIL_PROVIDEREmail provider, resend or custom
EMAIL_FROMSender email, e.g.: VibeAny <[email protected]>
RESEND_API_KEYResend API key

For a custom email server, configure the following variables. Refer to your email provider's documentation for details:

VariableDescription
EMAIL_HOSTEmail server host
EMAIL_ADDRESSSender email address
EMAIL_USERSender username
EMAIL_PASSWORDSender password

Payment

See the payment setup documentation for more details.

Stripe

VariableDescription
VITE_STRIPE_PUBLISHABLE_KEYStripe publishable key
STRIPE_SECRET_KEYStripe API secret key
STRIPE_WEBHOOK_SECRETStripe webhook secret
VITE_STRIPE_PRO_MONTHLY_PRICE_IDStripe pro monthly price ID
VITE_STRIPE_PRO_YEARLY_PRICE_IDStripe pro yearly price ID
VITE_STRIPE_LIFETIME_PRICE_IDStripe lifetime price ID

Creem

VariableDescription
CREEM_X_API_KEYCreem API key
CREEM_TEST_MODECreem test mode, true to enable, false to disable
CREEM_WEBHOOK_SECRETCreem webhook secret
VITE_CREEM_PRO_MONTHLY_PRODUCT_IDCreem pro monthly product ID
VITE_CREEM_LIFETIME_PRODUCT_IDCreem lifetime product ID

Credits

To simplify developer configuration, VibeAny integrates the credit system into the admin panel. You can modify credit settings at any time in the admin config panel, such as credit amounts and expiration periods. See the credit setup documentation for more details.

Storage

See the storage setup documentation for more details.

VariableDescription
STORAGE_PROVIDERStorage provider, s3 or custom
S3_ACCESS_KEYS3 access key
S3_SECRET_KEYS3 secret key
S3_REGIONS3 region
S3_BUCKETS3 bucket

Configuration via Admin Panel

VibeAny provides a dynamic config panel where you can modify the following settings at any time without restarting the service.

Priority Note

Environment variable file configuration takes priority over the admin panel:

  • Server-side config: If .env has STRIPE_SECRET_KEY=sk_xxx, the admin panel's payment_stripe_secret_key will be ignored
  • Client-side config (public_ prefix): If .env has VITE_CREDIT_ENABLE=true, the admin panel's public_credit_enable will be ignored

Environment Variables

Payment

You can select the payment provider in the admin panel: stripe, creem, paypal, wechat, alipay

Stripe

Config ItemEnvironment Variable
Stripe Secret KeySTRIPE_SECRET_KEY
Stripe Webhook SecretSTRIPE_WEBHOOK_SECRET

Creem

Config ItemEnvironment Variable
Creem X API KeyCREEM_X_API_KEY
Creem Test ModeCREEM_TEST_MODE
Creem Webhook SecretCREEM_WEBHOOK_SECRET

PayPal

Config ItemEnvironment Variable
PayPal Client IDPAYPAL_CLIENT_ID
PayPal Client SecretPAYPAL_CLIENT_SECRET
PayPal Webhook IDPAYPAL_WEBHOOK_ID
PayPal Sandbox ModePAYPAL_SANDBOX

WeChat Pay

Config ItemEnvironment Variable
WeChat App IDWECHAT_APP_ID
WeChat Merchant IDWECHAT_MCH_ID
WeChat API KeyWECHAT_API_KEY
WeChat API v3 KeyWECHAT_API_V3_KEY
WeChat Certificate Serial NoWECHAT_SERIAL_NO
WeChat Private KeyWECHAT_PRIVATE_KEY

Alipay

Config ItemEnvironment Variable
Alipay App IDALIPAY_APP_ID
Alipay App Private KeyALIPAY_PRIVATE_KEY
Alipay Public KeyALIPAY_PUBLIC_KEY
Alipay Sandbox ModeALIPAY_SANDBOX

Credits

Basic Configuration

Config ItemEnvironment VariableDefault
Enable Credit SystemVITE_CREDIT_ENABLEfalse
Allow Free Users to PurchaseVITE_CREDIT_ALLOW_FREE_USER_PURCHASEfalse

Sign-up Bonus

Config ItemEnvironment VariableDefault
Enable Sign-up BonusVITE_CREDIT_SIGNUP_BONUS_ENABLEDfalse
Sign-up Bonus AmountVITE_CREDIT_SIGNUP_BONUS_AMOUNT0
Bonus Expiration (days)VITE_CREDIT_SIGNUP_BONUS_EXPIRE_DAYS30

Daily Bonus

Config ItemEnvironment VariableDefault
Enable Daily BonusVITE_CREDIT_DAILY_ENABLEDfalse
Daily Bonus AmountVITE_CREDIT_DAILY_AMOUNT0

Email

Config ItemEnvironment VariableDefault
Email ProviderEMAIL_PROVIDERresend
Sender EmailEMAIL_FROM-
Resend API KeyRESEND_API_KEY-

Storage

VibeAny supports S3-compatible storage services (e.g., AWS S3, Cloudflare R2, MinIO).

Config ItemEnvironment VariableDefault
Storage RegionSTORAGE_REGIONauto
Bucket NameSTORAGE_BUCKET_NAME-
Access Key IDSTORAGE_ACCESS_KEY_ID-
Secret Access KeySTORAGE_SECRET_ACCESS_KEY-
Storage EndpointSTORAGE_ENDPOINT-
Public Access URLSTORAGE_PUBLIC_URL-

On this page