LearnOS docs
CLI

Auth

Sign in to the LearnOS CLI with browser OAuth or a personal access token.

The CLI authenticates as you. With learnos login, every command runs under the same row-level security as the web app.

learnos login

This opens a browser, runs OAuth 2.1 + PKCE against Supabase Auth, and stores access + refresh tokens in ~/.config/learnos/credentials.json (mode 0600).

learnos whoami
learnos logout

Fallback: personal access token

export LEARNOS_TOKEN=los_...

Issue a token from Settings → Personal access tokens. Useful for CI.

Personal access tokens carry full access to your account, expire after 90 days, and are checked by the app rather than by row-level security — use them only where OAuth isn't possible, and revoke them from Settings when you're done.

Resolution order

  1. LEARNOS_TOKEN environment variable
  2. Stored OAuth credentials from learnos login

On this page

Command Palette

Search for a command to run...