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

# Pi

> Configure PI CLI, ~/.pi/agent/auth.json, and subscription auth.

Pi uses local `pi`. Auth and models stay in `~/.pi/`. Open **Settings → CLI configuration → PI CLI** to detect the version, install, and configure credentials.

## How to connect

1. Override the `pi` executable path on that page (optional)
2. In **Provider auth**, enter an API key, or click **Log in** for subscription auth
3. If it is not installed, click **Install** on that page, or install with the terminal commands below

<Note>
  Config stays on this computer. The app does not upload keys to a CC GUI server.
</Note>

## Provider auth

### API key

Writes `~/.pi/agent/auth.json` (mode `0600`). That file wins over environment variables.

Common entries include Anthropic, OpenAI, Google Gemini, DeepSeek, xAI, OpenRouter, Groq, Mistral, Zhipu, Kimi For Coding, Qwen, and MiniMax. Other providers are folded under **Show all**.

### Subscription auth

Click **Log in**: the app opens the built-in terminal, starts `pi`, then sends a command such as `/login anthropic`. You can also run `pi /login` in a system terminal.

The app does not run OAuth for you. It only reads `auth.json`. Supported:

* Claude Pro / Max (`pi /login anthropic`)
* ChatGPT Plus / Pro (Codex) (`pi /login openai`)
* GitHub Copilot
* xAI
* OpenRouter
* Radius

### Resolve order

`--api-key` → `auth.json` → environment variables → `models.json`

## Install

```bash theme={null}
curl -fsSL https://pi.dev/install.sh | sh
pi --version
```

Alternative:

```bash theme={null}
npm install -g @earendil-works/pi-coding-agent
```

In-app **Install** previews the fallback `npm install -g @earendil-works/pi-coding-agent`.

Docs: [https://pi.dev/docs/latest/usage](https://pi.dev/docs/latest/usage)

## Capability differences

Compared with Claude Code:

* No plan mode
* Does not use desktop MCP
* Supports reasoning strength, session continue, and image input
* Stop ends the `pi` child process
* History is isolated per runtime

## When detect fails

See [Detect and install](/en/desktop/providers/cli).

## Next steps

* [Provider overview](/en/desktop/providers/overview)
* [Send the first message](/en/desktop/start/first-task)
