Documentation
App config (environment)
Publishable frontend keys injected into TestFlight, Play, and QR previews — never committed to GitHub.
Settings → Environment. This is for keys your website needs at build time, usually VITE_ or NEXT_PUBLIC_.
Lovable / Vite inlines these into the JavaScript bundle when the site is built. If they are missing, TestFlight can open a white screen because the API URL is empty.
How to fill them
- Scan repository — CapWrap reads
.env.example(and siblings) and lists key names. - Or Import .env from your computer (the file never stays in Git through this form).
- Or add a variable by hand.
- Save environment. Values live in CapWrap’s server vault. The dashboard only remembers names and “has a value.”
Reserved GitHub / CapWrap names are rejected. Values that look like private server keys are refused — Capacitor builds should only get publishable keys.
How they reach a phone build
When the native GitHub Action runs, it fetches this map with the same short-lived token as Apple / Google credentials, then writes .env.local / .env.production.local before npm run build. QR previews that CapWrap builds itself use the same map.
Reinstall the pipeline
If you installed the native pipeline before Environment existed, reinstall it from Settings → Pipelines so the fetch-secrets step is present.
What not to put here
- App Store
.p8or Play JSON (use App Store / Play Store settings) - Database admin keys, Stripe secret keys, SSH keys
- Capgo tokens
If a key must stay on a server, keep it on the server. The phone app should call your backend.