Authentication
FreeGate separates how you sign in to the dashboard from how your code authenticates to the API. There are exactly two browser sign-in methods · Discord and passkeys · and no token-based login or recovery fallback.
Dashboard: Discord or a passkey
Sign in at /login. Discord is the default; linking it also sets your
account name to your Discord username. The gateway sets an HttpOnly,
SameSite=Lax session cookie that expires after 30 days; signing out deletes the
server-side session.
Passkeys
Once signed in, add a passkey from Dashboard → Passkeys. It uses WebAuthn · Touch ID, Windows Hello, or a hardware security key · and then appears as Sign in with a passkey on the login page. Passkeys are discoverable, so you do not type a username first.
- An account can hold up to five passkeys; register one per device.
- Passkeys are verified with user verification required (biometric or device PIN).
- Remove a lost device from the same dashboard section; it stops working immediately.
- There is no key-based or token-based recovery. If you lose every passkey and Discord access, ask the operator to restore the account.
API: bearer keys
Authorization: Bearer fg_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx - Keys start with
fg_live_and are shown once, at redemption or issuance. - Only a SHA-256 hash is stored; the plaintext cannot be recovered.
- An account can hold up to three active keys. Revoke a lost one from the dashboard; revoked keys stop working immediately and disappear from the list.
- Keys are account-scoped: suspending the account invalidates every key immediately.
- Multiple keys on one account draw from the same per-model allowance.
- API keys are never a dashboard login method.
Keep the key out of shell history
export FREEGATE_API_KEY="fg_live_…" export FREEGATE_API_KEY="fg_live_…" $env:FREEGATE_API_KEY = "fg_live_…" Key hygiene
- Never ship a key in browser code or a mobile bundle · it is a server credential.
- One key per machine or service makes revocation surgical.
- If a key leaks, revoke it first and investigate second; there is no grace period.
What the gateway never does
It does not log prompts or completions, and it does not send your key anywhere except the upstream provider that serves the model. Provider credentials live on the server and are never exposed through the API.