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

# Install the CLI

> Get the ontora CLI running on your machine or in CI.

The Ontora CLI is a Python tool that wraps the REST API. It's the fastest way to launch campaigns, pull transcripts, and run GraphRAG queries from a terminal or CI pipeline.

## Install

<CodeGroup>
  ```bash pip theme={null}
  pip install ontora-cli
  ```

  ```bash uv theme={null}
  uv tool install ontora-cli
  ```

  ```bash from source theme={null}
  git clone https://github.com/ontora-ai/ontora.git
  cd ontora/cli
  pip install -e .
  ```
</CodeGroup>

After install, the `ontora` command is on your `PATH`.

```bash theme={null}
ontora --version
```

## First-time setup

Authenticate once and the CLI will remember your key:

```bash theme={null}
ontora auth login --api-key ont_live_...
```

Optional flags: `--workspace WS_ID` to set a default workspace, `--base-url URL` if you're hitting a non-default API host. Verify the connection:

```bash theme={null}
ontora auth status
```

## How config is stored

Configuration lives at `~/.ontora/config.yaml` with permissions `0600`:

```yaml theme={null}
api_key: ont_live_...
base_url: https://api.ontora.com
workspace_id: ws_...
```

You can override any value at call time with environment variables:

```bash theme={null}
export ONTORA_API_KEY=ont_live_...
export ONTORA_BASE_URL=https://api.ontora.com
export ONTORA_WORKSPACE_ID=ws_...
```

This is the recommended pattern in CI — store the API key as a secret, set `ONTORA_API_KEY`, and skip `ontora auth login` entirely.

## Next steps

<CardGroup cols={2}>
  <Card title="Commands" icon="terminal" href="/cli/commands">
    Full reference for every CLI command.
  </Card>

  <Card title="Campaign YAML" icon="file" href="/cli/campaign-yaml">
    Define an entire campaign in a single YAML file and launch it with one command.
  </Card>
</CardGroup>
