Docs / Authentication

Authentication

Google OAuth

Lakecode uses Google OAuth as the primary sign-in method. There are two flows:

  • Web flow (default) — lakecode login opens a browser tab. Best for local development machines.
  • Device flowlakecode login --device prints a URL + code. Best for headless servers, SSH sessions, or CI environments.

Both flows result in a license key being saved to your local machine. You stay signed in until the key expires or you explicitly sign out.

License keys

After OAuth, Lakecode issues a license key in the format lk_<base64url>. The key is an Ed25519-signed payload containing your email, plan type, and expiry date. It is stored locally and sent with every request to the proxy, which verifies the signature server-side.

You can view your current key on the dashboard or by running:

lakecode config license

Bring Your Own Key (BYOK)

If you prefer to use your own Anthropic API key and bypass the Lakecode proxy entirely, set this environment variable:

export ANTHROPIC_API_KEY=sk-ant-...

When a BYOK key is set, Lakecode routes requests directly to Anthropic. No credits are consumed, no proxy is involved, and billing is handled entirely by your Anthropic account.