# ==============================================
# LLMHosts.com -- Environment Variables
# ==============================================
# USAGE: cp .env.example .env && edit .env with real values
# WARNING: .env is gitignored. NEVER commit real secret values.
#
# Variable types:
#   [required]  — must be set for production
#   [optional]  — service works without it, feature disabled
#   [dev-only]  — only needed for development workflows

# ---- Domain & TLS ----
# [required] Hostname for Traefik routing + Let's Encrypt
DOMAIN=llmhosts.com
# [required] Email for Let's Encrypt registration
ACME_EMAIL=admin@llmhosts.com

# ---- Application ----
# [required] Bind to all interfaces inside Docker
LLMHOSTS_SERVER_HOST=0.0.0.0
# [required] Require API key for /v1/* endpoints
LLMHOSTS_SECURITY_REQUIREAUTH=true
# [optional] Log level: debug, info, warning, error (default: info)
LLMHOSTS_SERVER_LOGLEVEL=info
# [optional] Log format: json or text (default: json in production)
LLMHOSTS_OBSERVABILITY_LOGFORMAT=json

# ---- Cache ----
# [optional] Enable response caching (default: true)
LLMHOSTS_CACHE_ENABLED=true
# [optional] Max cache size in MB (default: 512)
LLMHOSTS_CACHE_MAXSIZEMB=1024

# ---- Frontend Auth (Next.js / Auth.js) ----
# [required] Generate with: openssl rand -base64 32
NEXTAUTH_SECRET=REPLACE_ME_WITH_RANDOM_SECRET

# ---- Email (Resend) ----
# [optional] Required for contact form + email verification
# Get from: https://resend.com/api-keys
# RESEND_API_KEY=re_REPLACE_ME

# ---- Stripe Billing ----
# [optional] Required for paid plan subscriptions
# Get from: https://dashboard.stripe.com/apikeys
# STRIPE_SECRET_KEY=sk_test_REPLACE_ME
# NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_test_REPLACE_ME
# STRIPE_WEBHOOK_SECRET=whsec_REPLACE_ME
# Price IDs from Stripe Dashboard > Products > Prices
# STRIPE_PRO_PRICE_ID=price_REPLACE_ME
# STRIPE_TEAM_PRICE_ID=price_REPLACE_ME
# STRIPE_ENTERPRISE_PRICE_ID=price_REPLACE_ME

# ---- AI Provider Keys (BYOK proxy) ----
# [optional] Cloud provider keys managed via: llmhost keys add <provider> <key>
# OPENAI_API_KEY=sk-REPLACE_ME
# ANTHROPIC_API_KEY=sk-ant-REPLACE_ME

# ---- Ollama ----
# [optional] URL of Ollama instance for local inference
# LLMHOSTS_OLLAMA_HOST=http://host.docker.internal:11434

# ---- Tunnel ----
# [optional] For remote access without public IP
# TAILSCALE_AUTHKEY=tskey-REPLACE_ME
# CLOUDFLARE_TUNNEL_TOKEN=REPLACE_ME

# ---- Relay tunnel (ADR-009) ----
# [optional] Self-hosted Rust relay for device tunneling
RELAY_SERVER_URL=wss://llmhosts.com/api/relay/connect
RELAY_SERVER_PUBKEY=          # Base64 Noise NK public key (auto-fetched on first auth)

# ---- GitHub (dev-only) ----
# [dev-only] Fine-grained PAT for gh CLI + API
# GH_TOKEN=github_pat_REPLACE_ME
# [dev-only] Classic PAT for project board access
# GH_TOKEN_PROJECTS=ghp_REPLACE_ME

# ---- Observability ----
# [optional] Sentry error tracking DSN
# LLMHOSTS_OBSERVABILITY_SENTRYDSN=https://...@sentry.io/...
