Sign In
Authenticate with Circuit.- The CLI generates a unique auth handoff ID via the Circuit API.
- Opens your browser to the Circuit login page with the handoff ID.
- In the browser, your passkey signs a CLI-scoped permit (and a one-time KMS pktoken is stored on the api side, keyed to that permit, so hosted-execution signing works without an extra token).
- The CLI polls the API for the permit until the browser deposits it, then stores it in
~/.circuit/auth.tomlunder the[<env>]section matchingCIRCUIT_ENV.
permit is a passkey-signed permit. The CLI treats it as an opaque bearer string and sends it as Authorization: Bearer <permit>. There is no separate wallet-execution authority token — the api resolves signing material server-side from the permit’s wallet.sign capability.
Local Sign-In (offline)
Authorize local signing —circuit run / circuit unwind against wallets in your local keystore — without a browser, a Circuit account, or any network.
circuit wallet add, stored under ~/.circuit/local/) and writes it to ~/.circuit/local/permit.
When you need it:
- Local
circuit run/circuit unwindrequire a local session — they verify this permit and refuse if it’s missing or expired, pointing you back tocircuit auth login --local. circuit wallet *(add / list / delete / export) do not need it — they only use the local identity.- Hosted commands (
circuit publish,circuit run --hosted …) use the browser sign-in above, not this.
circuit auth login --local.
Sign Out
Sign out from Circuit.- Removes the
[<env>]section from~/.circuit/auth.toml(only the env matchingCIRCUIT_ENV; other envs stay logged in). Deletes the file entirely if no envs remain. - No parameters required
Logged In User Info
Show current authenticated user.key: value lines; --json serializes the same fields):
username— who you’re signed in as.environment— the active env (production/staging/local, fromCIRCUIT_ENVor--env), andapi— the endpoint it resolves to.source— where the active credential came from: theauth.tomlpath (e.g.~/.circuit/auth.toml), orCIRCUIT_TOKEN (env var)when set.permit— the decoded permit payload (issuedAt,expiresAt,capabilities): the full grant itself, not a summary.
circuit auth token.
Token
Print your bearer token for capture intoCIRCUIT_TOKEN.
- Default prints nothing but the bare token, so
TOKEN=$(circuit auth token)captures it directly. The only command that prints the credential —circuit auth whoaminever does. --jsonwraps the same value as{ "token": "..." }for scripts that read structured output.--decodeprints the pre-b64 contents instead of the wire string: both base64url segments parsed —payload(issuedAt,expiresAt,capabilities) and the WebAuthnproof— raw, with no schema reshaping. A decode, not a verification (the CLI can’t check a passkey signature locally); it mirrorsopenssl x509 -text/step crypto jwt inspect. Combine with--jsonfor one JSON document.
circuit auth whoami — the same way gh auth token prints the token and gh auth status shows what it’s good for.