-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy path.env.example
More file actions
95 lines (82 loc) · 5.02 KB
/
Copy path.env.example
File metadata and controls
95 lines (82 loc) · 5.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# Copy to .env and fill in. Used by bot (npm run bot:local) and optionally by Expo.
# Do not commit .env.
# Telegram bot (required for local bot; optional for Expo app)
# Get token from @BotFather on Telegram
BOT_TOKEN=1234567890:ABCdefGHIjklMNOpqrsTUVwxyz-EXAMPLE
# Neon/Postgres connection string (from Neon dashboard)
DATABASE_URL=postgresql://user:password@ep-xxx-xxx.region.aws.neon.tech/neondb?sslmode=require
# OpenAI API key for /api/ai (required for AI responses). Get from https://platform.openai.com/api-keys
OPENAI=sk-proj-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
# Optional: TinyModel sidecar (classify + RAG) — hybrid with OpenAI for chat mode.
# Run from TinyModel repo: python scripts/phase3_reference_server.py --model HyperlinksSpace/TinyModel1 --port 8765
# TINYMODEL_API_URL=http://127.0.0.1:8765
# TINYMODEL_TIMEOUT_MS=8000
# AI_PROVIDER=hybrid
# Optional: base URL for calling APIs in dev (used by app and bot).
# Example for local Vercel dev: http://localhost:3000
# EXPO_PUBLIC_API_BASE_URL=http://localhost:3000
# Set automatically on Vercel builds (matches deployment id in the Vercel dashboard URL).
# EXPO_PUBLIC_VERCEL_DEPLOYMENT_ID=7xdsFT59DsLvHWPQ9uaaVBW35mzx
# Monotonic counter incremented in Postgres on each Vercel build (see scripts/stamp-deploy-version.ts).
# EXPO_PUBLIC_DEPLOY_VERSION=42
# Optional: Swap.Coffee API key for TON token info and routing.
# COFFEE=your-swap-coffee-api-key
# COFFEE_BASE_URL=https://api.swap.coffee
# COFFEE_TOKENS_BASE_URL=https://tokens.swap.coffee
# Google OAuth (Sign in with Google on welcome page). Web client from Google Cloud Console.
# GOOGLE_OAUTH_CLIENT_ID=....apps.googleusercontent.com
# GOOGLE_OAUTH_CLIENT_SECRET=...
# Optional override when API origin differs from redirect host:
# GOOGLE_OAUTH_REDIRECT_URI=https://hsbexpo.vercel.app/api/auth/google/callback
# GitHub OAuth (Sign in with GitHub on welcome page).
# Create an OAuth App: https://github.com/settings/developers
# Authorization callback URL must match redirect below (path is fixed in code).
# GITHUB_OAUTH_CLIENT_ID=Ov23li...
# GITHUB_OAUTH_CLIENT_SECRET=...
# Optional: force callback host when API public URL differs from request origin (Vercel/proxy).
# GITHUB_OAUTH_REDIRECT_URI=https://hsbexpo.vercel.app/api/auth/github/callback
#
# Sign in with Apple (Services ID + Sign in with Apple key from Apple Developer).
# APPLE_OAUTH_CLIENT_ID=com.example.app.web
# APPLE_OAUTH_TEAM_ID=ABCDE12345
# APPLE_OAUTH_KEY_ID=ABC123DEFG
# APPLE_OAUTH_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----"
# Optional:
# APPLE_OAUTH_REDIRECT_URI=https://hsbexpo.vercel.app/api/auth/apple/callback
#
# Also set EXPO_PUBLIC_API_BASE_URL to the same API origin the welcome page calls
# (e.g. https://hsbexpo.vercel.app) so /api/auth/github/start uses the matching redirect.
# Email OTP sign-in (welcome page). Uses Resend for delivery — no Railway server needed.
# Sign up at https://resend.com, verify your sending domain, add DNS records (SPF/DKIM).
# RESEND_API_KEY=re_...
# AUTH_EMAIL_FROM=Hyperlinks Space Program <noreply@yourdomain.com>
# Optional display name in the email subject/body:
# AUTH_EMAIL_FROM=Hyperlinks Space Program <noreply@hyperlinks.space>
# AUTH_EMAIL_APP_NAME=Hyperlinks Space Program
# Without RESEND_API_KEY + AUTH_EMAIL_FROM, local dev logs the OTP code to the API console.
# Telegram browser OIDC (Sign in with Telegram outside Mini App). In @BotFather → your bot → Web Login:
# register site origin AND callback URL exactly (see texts/telegram-login-outside-telegram.md).
# TELEGRAM_CLIENT_ID=1234567890
# TELEGRAM_CLIENT_SECRET=...
# Must match the live site (update when moving off *.vercel.app):
# TELEGRAM_OIDC_REDIRECT_URI=https://program.hyperlinks.space/api/auth/telegram/callback
# TELEGRAM_CLIENT_ID must be the numeric bot id (digits only), e.g. 1234567890 from BOT_TOKEN before ":".
# Cloud KMS: full service-account JSON for /api/wallet/register (wraps DEK). See README § GCP_SERVICE_ACCOUNT_JSON.
# GCP_SERVICE_ACCOUNT_JSON={"type":"service_account",...}
# Ops-only: POST /api/wallet/envelope-verify proves Neon+KMS round-trip (never returns mnemonic). Set a long random secret.
# WALLET_ENVELOPE_VERIFY_SECRET=your-long-random-string
# Optional: log non-secret envelope persistence diagnostics from wallet-register.
# WALLET_ENVELOPE_DEBUG=1
# TDLib user-session gateway (real Telegram messages connect — QR login).
# Create an app at https://my.telegram.org/apps (api_id + api_hash). Server-only — never EXPO_PUBLIC_*.
# TELEGRAM_API_ID=12345678
# TELEGRAM_API_HASH=0123456789abcdef0123456789abcdef
# Local gateway (npm run tdlib:gateway): listens on 127.0.0.1:8787 by default.
# TDLIB_GATEWAY_PORT=8787
# TDLIB_GATEWAY_SECRET=change-me-long-random
# TDLIB_DB_ROOT=.tdlib-data
# Production: deploy gateway on Fly/Railway/GCP and point Vercel at it:
# TDLIB_GATEWAY_URL=https://your-tdlib-gateway.example.com
# GCP one-command deploy (after billing enabled): npm run gcp:tdlib-gateway
# GCP Console steps: deploy/gcp/CONSOLE.md
# No credit card: run gateway on your PC + tunnel — deploy/no-card/README.md