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

# MCP Installation

> Connect CapOut MCP from Codex, Claude Code, Gemini CLI, OpenCode, GitHub Copilot CLI, and agent installers using each client's documented remote MCP setup flow.

CapOut MCP is a hosted remote MCP server. Use the Streamable HTTP endpoint below, not the bare domain root:

```text theme={null}
https://mcp.capout.ai/mcp
```

## Copy to Codex

Run this in your terminal to add CapOut MCP to Codex:

```bash theme={null}
codex mcp add capout --url https://mcp.capout.ai/mcp
```

Codex starts the login flow automatically when the server needs authentication. Use `/mcp` inside Codex to confirm the server is connected.

## Install with `add-mcp`

For clients supported by the `add-mcp` installer, this command can detect installed coding agents and configure CapOut MCP for them:

```bash theme={null}
npx add-mcp --name capout --transport http https://mcp.capout.ai/mcp
```

Use `--all` to install to all detected agents, `-g` for a global install across projects, or `-y` to skip the confirmation prompt:

```bash theme={null}
npx add-mcp --name capout --transport http --all -g https://mcp.capout.ai/mcp
```

## Claude Code

Anthropic documents remote HTTP MCP servers with `claude mcp add --transport http <name> <url>`.

```bash theme={null}
claude mcp add --transport http capout https://mcp.capout.ai/mcp
claude mcp list
```

If Claude Code asks you to authenticate the server, use `/mcp` inside the session and complete the sign-in flow there.

## Gemini CLI

Gemini CLI documents remote HTTP MCP servers with `gemini mcp add --transport http <name> <url>`.

```bash theme={null}
gemini mcp add --transport http capout https://mcp.capout.ai/mcp
gemini mcp list
```

If Gemini marks the server as needing authentication, run this inside Gemini CLI:

```text theme={null}
/mcp auth capout
```

## OpenCode

OpenCode documents remote MCP servers in `opencode.json` or `opencode.jsonc`. For a user-wide setup, put this in `~/.config/opencode/opencode.json`. For a project-only setup, put it in `opencode.json` at your project root.

```json theme={null}
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "capout": {
      "type": "remote",
      "url": "https://mcp.capout.ai/mcp",
      "enabled": true
    }
  }
}
```

If OpenCode needs authentication, or if you want to trigger it manually:

```bash theme={null}
opencode mcp auth capout
opencode mcp list
```

## GitHub Copilot CLI

GitHub documents both interactive `/mcp add` setup and a non-interactive `copilot mcp add` command. The CLI reference also documents `--tools` for enabling all tools from the remote server.

```bash theme={null}
copilot mcp add capout --type http --url https://mcp.capout.ai/mcp --tools "*"
copilot mcp list
```

If Copilot CLI shows `needs-auth`, run this inside an interactive Copilot CLI session:

```text theme={null}
/mcp auth capout
```

If you prefer config instead of a command, GitHub documents `~/.copilot/mcp-config.json`:

```json theme={null}
{
  "mcpServers": {
    "capout": {
      "type": "http",
      "url": "https://mcp.capout.ai/mcp",
      "tools": ["*"]
    }
  }
}
```

## What the agent can do after install

* Process PDFs into Xactimate exports
* Poll export status until completion
* Check remaining CapOut claims
* List, save, assign profile codes, and delete XactNet recipient addresses
* Inspect and switch between live and test API keys

## How CapOut chooses the upload path

CapOut MCP is hosted remotely. That means it cannot read your local `/Users/...` paths, workspace paths, or other files from your machine directly.

The MCP uses different tools depending on where the PDF lives.

### Attachment, HTTPS URL, or inline bytes

When the client can provide a PDF attachment, a public `https://` PDF URL, or inline base64 bytes, the agent uses `capout_process_pdf`.

### Local CLI or workspace PDF

When the PDF lives on the local machine or workspace, the agent should not send a local path like `/Users/...` to the hosted server. Instead it should:

1. Call `capout_create_upload_url`
2. Run the returned `curl_command` locally
3. Call `capout_process_staged_upload` with `xn_address` and `profile_code`

## API key examples

Use `capout_api_keys` to see the current key and any other available live or test keys. Use `capout_select_api_key` to switch when needed.

Selecting a key updates which stored key is marked `mcp=true` for MCP-authenticated requests. The model does not receive raw API key values.

If no CapOut API key exists yet, create one in the CapOut app:

```text theme={null}
https://app.capout.ai/settings/api-keys
```

## Starter prompts

```text theme={null}
Use CapOut on this attached PDF and send it to matt@capout.prod
```

```text theme={null}
Use CapOut on /Users/me/Downloads/estimate.pdf and send it to matt@capout.prod
```

```text theme={null}
Show me which CapOut API key this MCP is using
```

```text theme={null}
Switch CapOut to the test API key
```
