K

Auth & Account

Login, account, profile, tenant, config, doctor, and update commands

This page collects the commands that decide "who" the CLI talks to axhub as. On a fresh install, one axhub auth login completes the browser OAuth login; in CI and agents, use a PAT (auth pat). Switch environments with profile and, if you belong to several companies, switch targets with tenants. When something looks off, doctor diagnoses install, auth, and connectivity in one pass. The full path from install to first login is covered step by step in the Quickstart.

axhub auth

Authentication: login, logout, status, PAT, OAuth, and IdP config.

axhub auth idp

Manage tenant identity providers (IdP config for SSO login).

axhub auth idp providers

List supported identity-provider types.

FlagTypeDescriptionDefault
--tenantstringTenant slug or ID used to scope the command.

axhub auth idp test

Test an identity provider's configuration.

FlagTypeDescriptionDefault
<provider_id>string (positional)
--tenantstringTenant slug or ID used to scope the command.

axhub auth login

Log in via the OAuth device flow.

FlagTypeDescriptionDefault
--device-codestringResume an already-issued AxHub OAuth device code (env: AXHUB_AUTH_DEVICE_CODE)
--forcebooleanBypass the normal safety prompt for this operation.
--no-browserbooleanDo not open a browser automatically.
--resourcestringValue for the --resource option. Can also be provided via AXHUB_OAUTH_RESOURCE.
--resume-lastbooleanResume the latest locally cached AxHub OAuth device flow for this profile
--scopesstringComma-separated OAuth or token scopes.
--tenantstringTenant slug or ID used to scope the command.
--wait-approvalstringKeep waiting for the user's approval inside this one command, up to the given duration (6s–10m; e.g. 90s). Without it the resume polls once and exits. Use it instead of re-running the resume in a loop. Use with --device-code or --resume-last

axhub auth logout

Log out and clear stored credentials.

FlagTypeDescriptionDefault
--dry-runbooleanPreview the operation without applying state changes.

axhub auth oauth

Manage OAuth tokens, clients, and consent.

axhub auth oauth client

Manage OAuth clients.

axhub auth oauth client create

Create a new OAuth client (dry-run by default; use --execute).

FlagTypeDescriptionDefault
--allowed-resourcestring
--appstringApp slug or ID to operate on.
--auth-methodstring
--copyboolean
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--grant-typestring
--namestringResource display name.
--redirect-uristring
--scopestring
--typestring
axhub auth oauth client get

Show one OAuth client's details.

FlagTypeDescriptionDefault
<client_id>string (positional)

Manage OAuth consent grants.

Revoke a consent grant for an OAuth client.

FlagTypeDescriptionDefault
<client_id>string (positional)
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.

axhub auth oauth revoke

Revoke an OAuth token (dry-run by default; use --execute).

FlagTypeDescriptionDefault
<token>string (positional)Token value or token identifier.
--client-idstring00000000-0000-4000-8000-000000000001
--client-secretstring
--client-secret-filestring
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--token-type-hintstring

axhub auth pat

Manage personal access tokens (PAT).

axhub auth pat issue

Issue a new personal access token.

FlagTypeDescriptionDefault
--expires-in-daysstringNumber of days before the generated credential expires.
--namestringResource display name.
--no-savebooleanPrint the credential without saving it locally.
--show-tokenbooleanPrint the generated token once after creation.
--useboolean

axhub auth pat list

List your personal access tokens.

FlagTypeDescriptionDefault
--reconcileboolean

axhub auth pat revoke

Revoke a personal access token (dry-run by default; use --execute).

FlagTypeDescriptionDefault
<id>string (positional)Resource identifier.
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.

axhub auth pat rotate

Rotate a personal access token (revoke and reissue; dry-run by default, use --execute).

FlagTypeDescriptionDefault
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--expires-in-daysstringNumber of days before the generated credential expires.
--namestringResource display name.
--show-tokenbooleanPrint the generated token once after creation.

axhub auth pat unset

Clear the locally stored active PAT.

(no options)

axhub auth pat use

Save a PAT as the active local credential.

FlagTypeDescriptionDefault
<id>string (positional)Resource identifier.

axhub auth pat whoami

Show the user the active PAT authenticates as.

(no options)

axhub auth refresh

Refresh the stored OAuth access token.

FlagTypeDescriptionDefault
--no-browserbooleanDo not open a browser automatically.
--resourcestringValue for the --resource option. Can also be provided via AXHUB_OAUTH_RESOURCE.
--scopesstringComma-separated OAuth or token scopes.

axhub auth status

Show the current authentication status.

(no options)

axhub auth whoami

Show the currently authenticated user.

(no options)


axhub profile

Manage local CLI profiles: add, list, switch, and remove.

axhub profile add

Add a new local CLI profile.

FlagTypeDescriptionDefault
<name>string (positional)Resource display name.
--defaultboolean
--endpointstringAxHub API endpoint URL.

axhub profile current

Show the currently active profile.

(no options)

axhub profile list

List configured profiles.

(no options)

axhub profile remove

Remove a local CLI profile.

FlagTypeDescriptionDefault
<name>string (positional)Resource display name.

axhub profile use

Switch the active profile.

FlagTypeDescriptionDefault
<name>string (positional)Resource display name.

axhub tenants

Manage tenants and the active-tenant selection.

axhub tenants get

Show one tenant's details by slug or id.

FlagTypeDescriptionDefault
<slug_or_id>string (positional)Stable slug or identifier for the resource.
--tenantstringTenant slug or ID used to scope the command.

Manage tenant invite links.

Accept a tenant invite link token (dry-run by default).

FlagTypeDescriptionDefault
<token>string (positional)Token value or token identifier.
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--yes -ybooleanAssume yes for non-destructive confirmation prompts.

Create a tenant invite link (dry-run by default).

FlagTypeDescriptionDefault
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--expires-atstringOptional RFC3339 expiry timestamp
--tenantstringTenant slug or ID used to scope the command.

List tenant invite links.

FlagTypeDescriptionDefault
--tenantstringTenant slug or ID used to scope the command.

Preview a tenant invite link token (read-only).

FlagTypeDescriptionDefault
<token>string (positional)Token value or token identifier.

Revoke a tenant invite link (dry-run by default).

FlagTypeDescriptionDefault
<link_id>string (positional)
--dry-runbooleanPreview the operation without applying state changes.true
--executebooleanApply the state-changing operation instead of previewing it.
--tenantstringTenant slug or ID used to scope the command.
--yes -ybooleanAssume yes for non-destructive confirmation prompts.

axhub tenants whoami

Show your membership and role in the active tenant.

FlagTypeDescriptionDefault
--tenantstringTenant slug or ID used to scope the command.

axhub config

Read and explain local CLI configuration.

axhub config explain

Explain the resolved CLI configuration and its sources.

(no options)


axhub doctor

Run local diagnostics against config, auth, and backend reachability.

FlagTypeDescriptionDefault
<args>string (positional)
--offlinebooleanSkip the network reachability probe

axhub update

Self-update the axhub CLI binary.

axhub update apply

Download and install the latest axhub release.

FlagTypeDescriptionDefault
--dry-runbooleanPreview mode: print the apply plan without downloading or swapping. Defaults true — destructive paths require explicit --execute per .claude/rules/product-development.md "Destructive Command Safety"true
--executebooleanCommit the apply plan: download, verify, and atomically swap the running binary. Conflicts with --dry-run
--forcebooleanAllow applying an older release that would otherwise be rejected by the downgrade gate. Does NOT bypass cosign verification — a signature/certificate failure still blocks the swap
--yes -ybooleanSkip the interactive confirmation shown before the binary swap during --execute. Already bypassed under --json, --no-input, --non-interactive, or a non-TTY stdin. No effect in dry-run

axhub update check

Check whether a newer axhub release is available.

FlagTypeDescriptionDefault
--plugin-versionstringAlso report whether the axhub Claude Code plugin is outdated. The caller (the plugin's skill) passes its installed plugin.json version here; the CLI fetches the published marketplace version and compares. Omitted ⇒ CLI-only check (backward compatible)