> ## Documentation Index
> Fetch the complete documentation index at: https://docs.littledemo.com/llms.txt
> Use this file to discover all available pages before exploring further.

# CLI login

Browser login, no-browser login, and API key auth for scripts.

## Browser flow

```bash
littledemo login
```

The CLI opens a browser page. Approve the device code and the CLI stores credentials locally.

## Remote shell

```bash
littledemo login --no-browser
```

The CLI prints a URL and short code. Open the URL on another device, approve the code, and return to the terminal.

## API key

```bash
littledemo login --api-key ld_live_xxx
```

Or use an environment variable:

```bash
export LITTLEDEMO_API_KEY=ld_live_xxx
littledemo whoami
```

## Local config

Credentials are stored in:

```text
~/.littledemo/config.json
```

Use `littledemo logout` to remove stored credentials.