Authentication
All deploy and management commands require authentication. The CLI uses an OAuth-based flow that opens your browser to sign in securely.
leash login
Start the sign-in flow. The CLI opens your default browser and waits for authorization. Once complete, your session token is stored locally.
$ leash login
Opening browser...
✓ Logged in as arvin@example.com
How the OAuth flow works
The CLI starts a temporary local server on an available port. After you sign in through the browser, the callback delivers the session token to the local server. The token is then stored in ~/.leash/credentials.json and used for all subsequent requests.
leash logout
Sign out and remove stored credentials from your machine.
$ leash logout
✓ Logged out successfully
leash whoami
Check which account is currently authenticated.
$ leash whoami
arvin@example.com (free plan)