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

# Gemini CLI

> Install the Klarity extension in the Gemini CLI.

## Extension install (OAuth)

<Steps>
  <Step title="Install the extension from your shell">
    ```bash theme={null}
    gemini extensions install https://github.com/klarity-ai/klarity-mcp
    ```
  </Step>

  <Step title="Log in from a Gemini CLI session">
    ```text theme={null}
    /mcp auth klarity
    ```

    You'll be redirected to Klarity in your browser to authenticate.
  </Step>
</Steps>

## API key install

Use this for long-running background agents. Generate an API key from `Settings → MCP` in your Klarity workspace (see [Authentication](/authentication#api-key)) and configure your Gemini CLI's MCP block to send the `Authorization: Bearer <YOUR_API_KEY>` header for `klarity`.

<Warning>
  Treat the API key like a password. Rotate it from `Settings → MCP` in Klarity if it's exposed.
</Warning>

## Verify

In a Gemini CLI session, ask:

```text theme={null}
Search Klarity for AI transformation opportunities across our processes — where could we build skills or deploy agents?
```

The assistant should call `search` and return process results from your workspace.
