Skip to content

Authentication

The auth command is used to manage your authentication state with the OneGuard Platform. The CLI uses API Keys to authenticate your requests securely.

Commands

login

Log in to the OneGuard CLI using your API Key.

Usage:

oneguard auth login <API_KEY>

Description: Verifies the provided API Key with the server and stores it securely in ~/.oneguard/credentials.json. You must run this command before using other CLI commands.


logout

Log out of the OneGuard CLI.

Usage:

oneguard auth logout

Description: Removes the stored API Key from your local machine, clearing your authentication state.