zeon login and zeon auth

Sign in, check the active credentials, sign out.

zeon login / zeon auth login

zeon login [--token TEXT] [--name TEXT] [--expires-in-days N] [--local]

Signs in through the browser and stores a new API token in ~/.zeon/.env as ZEON_API_TOKEN. zeon login and zeon auth login are the same command.

OptionDefaultMeaning
--token TEXTStore an existing token and skip the browser.
--name TEXTcli-<host>-<timestamp>Token name shown on the API tokens page.
--expires-in-days N90Token lifetime, 1 to 365.
--localoffWrite to ./.env (this directory) instead of ~/.zeon/.env. A ./.env takes precedence there.

The browser flow listens on localhost:8765 for the redirect and waits up to five minutes. The .env file is made readable only by you. After writing the token, the command checks it with the server and prints signed in as <email>; it exits with 1 if the check fails.

zeon commit, zeon push and zeon sync never take a .env or .env.* file, so a token written with --local inside a project folder is not synced. See Signing in.

zeon auth status

zeon auth status
zeon auth

Prints a table of the settings in use and where each came from (env, a .env path, ~/.zeon/.env, ~/.zeon/config.toml or default), with the token masked. Then checks the token with the server and reports that you are authenticated, with your user_id, email and org_id. Exits with 1 when no token is configured (no token configured. Run zeon auth login.) or the server rejects it.

zeon logout / zeon auth logout

zeon logout [--local]

zeon logout and zeon auth logout are the same command. In order:

  1. Ends the browser sessions that this token's login links (zeon app) started.
  2. If the token was created by a browser zeon login of CLI 1.5.5 or newer, revokes it on the server. The token stops working on every machine. It prints Signed out: revoked the api token and removed it from <path>.
  3. Removes the token from ~/.zeon/.env (with --local, from ./.env); other keys in the file stay. Without step 2 it prints Signed out: removed the api token from <path>.

A token stored with zeon login --token, or written by an older CLI, is only removed locally and stays valid on the server until it expires; revoke it on the API tokens page to end it now. A server that cannot be reached, or does not offer steps 1 and 2 yet, gives one notice: line; the local copy is removed anyway. See Login links from the CLI.


Did this page help you?