Skip to content

Command Reference

gaard completion
gaard ctx
gaard login
gaard logout
gaard tenant
gaard token
gaard version
gaard whoami

Print build and runtime information:

Terminal window
gaard version

Open a browser sign-in flow and store a token in the selected context:

Terminal window
gaard login
gaard login --api http://127.0.0.1:8004 --name local
gaard login --api https://staging.gaard.ai --name staging

Clear the stored token from the current context:

Terminal window
gaard logout

Show the active user, roles, tenants, context, and selected tenant:

Terminal window
gaard whoami
gaard whoami -o json

Manage named environments:

Terminal window
gaard ctx list
gaard ctx add local --api http://127.0.0.1:8004
gaard ctx add prod --api https://vision.gaard.ai --tenant acme_prod
gaard ctx use prod
gaard ctx remove local

Manage the current session tenant for the active context:

Terminal window
gaard tenant list
gaard tenant use acme_prod
gaard tenant clear

tenant use validates tenant names and is primarily intended for super users who can move across multiple tenants.

Manage personal access tokens:

Terminal window
gaard token list
gaard token create --name ci-bot
gaard token create --name nightly-job --expires 720h
gaard token revoke <token-id>

When creating a token, the raw secret is printed only once. Copy it immediately if you need to use it outside the CLI config.

Generate shell completion scripts:

Terminal window
gaard completion bash
gaard completion zsh

Use built-in help for the latest flags and argument details:

Terminal window
gaard --help
gaard token --help
gaard token create --help
gaard ctx add --help