# Connecting your client

**Available on:** every plan

Cabin's MCP server lives at `https://withcabin.com/mcp` and authenticates with OAuth: your client opens a browser window where you sign in to Cabin and approve access.

```
Set up the Cabin analytics MCP server for me by fetching and following the instructions at https://withcabin.com/mcp/setup.md
```

Or set it up by hand. Find your client below.

## Claude (claude.ai)

Cabin is listed in the Claude connector directory, so the quickest way is:

1. Open [Cabin in the Claude directory](https://claude.ai/directory/cabin)
2. Click to connect it, then sign in to Cabin and approve access

Once connected, enable the Cabin connector in any conversation via the **+** button in the chat input, then **Connectors**.

### Add it by URL

If you can't use the directory (some Team and Enterprise workspaces turn it off), add Cabin as a custom connector instead:

1. Open [claude.ai](https://claude.ai), click your profile icon, then select **Settings**
2. In the sidebar, click **Connectors**
3. Scroll down and click **Add custom connector**
4. Enter the URL: `https://withcabin.com/mcp`
5. Click **Add**, and you'll be redirected through the OAuth flow to grant Cabin access

## Claude Code

Run the following command in your terminal:

```bash
claude mcp add --transport http cabin https://withcabin.com/mcp
```

Claude Code will open your browser to complete the OAuth flow. Verify the server was added with `claude mcp list`.

## Cursor

Add the following to your MCP config file at `~/.cursor/mcp.json`:

```json
{
  "mcpServers": {
    "cabin": {
      "type": "http",
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

Restart Cursor, then open **Settings → MCP**. The Cabin server will appear. Click it to complete the OAuth authentication flow.

## ChatGPT

1. Open [chatgpt.com](https://chatgpt.com) and go to **Settings → Apps & Connectors**
2. Click **Advanced settings** and enable **Developer Mode**
3. Go back to the **Connectors** tab and click **Create**
4. Enter a name (e.g. "Cabin Analytics") and the URL: `https://withcabin.com/mcp`
5. Set Authentication to **OAuth**
6. Click **Save**, and you'll be redirected through the OAuth flow to grant Cabin access

## Codex

Run the following command in your terminal:

```bash
codex mcp add cabin --url https://withcabin.com/mcp
```

Then authenticate with `codex mcp login cabin` to complete the OAuth flow. Verify the server was added with `codex mcp list`.

Prefer editing config directly? Add this to `~/.codex/config.toml`:

```toml
[mcp_servers.cabin]
url = "https://withcabin.com/mcp"
```

Streamable HTTP MCP servers require Codex CLI 0.121.0 or newer.

## VS Code (Copilot)

Add the following to `.vscode/mcp.json` in your workspace:

```json
{
  "servers": {
    "cabin": {
      "type": "http",
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

Open Copilot Chat in Agent mode and click the tools icon and the Cabin server will appear. On first use, VS Code opens your browser to complete the OAuth flow.

## Windsurf

Windsurf uses the `mcp-remote` proxy to handle OAuth. Add the following to `~/.codeium/windsurf/mcp_config.json`:

```json
{
  "mcpServers": {
    "cabin": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://withcabin.com/mcp"]
    }
  }
}
```

Requires Node.js. On first connection, `mcp-remote` opens your browser to complete the OAuth flow.

## Gemini CLI

Add the following to your Gemini CLI settings file at `~/.gemini/settings.json`:

```json
{
  "mcpServers": {
    "cabin": {
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

Then run `/mcp auth cabin` in the Gemini CLI to complete the OAuth flow. The Gemini web app doesn't currently support custom MCP servers, so use the Gemini CLI or Gemini Enterprise.

## Zed

Add the following to your Zed settings (`cmd+,`):

```json
{
  "context_servers": {
    "cabin": {
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

Zed automatically triggers the OAuth flow when you first use the server.

## JetBrains (IntelliJ, WebStorm, etc.)

1. Open **Settings → Tools → AI Assistant → Model Context Protocol (MCP)**
2. Click **Add** and choose the **HTTP** connection type
3. Enter the following config:

```json
{
  "mcpServers": {
    "cabin": {
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

4. Click **OK**, then **Apply**. The server will show "Authorization required". Click **Authorize** to complete the OAuth flow. Requires AI Assistant plugin 2025.2+.

## Cline

1. Open Cline in VS Code and click the MCP icon (plug icon) in the top bar
2. Click **Configure MCP Servers** to open `cline_mcp_settings.json`
3. Add the following:

```json
{
  "mcpServers": {
    "cabin": {
      "url": "https://withcabin.com/mcp",
      "type": "streamableHttp",
      "disabled": false,
      "autoApprove": [],
      "timeout": 60
    }
  }
}
```

4. Save the file. Cline will prompt with an **Authenticate** button. Click it to complete the OAuth flow.

## Le Chat (Mistral)

1. Open [chat.mistral.ai](https://chat.mistral.ai), expand **Intelligence** in the left sidebar, then select **Connectors**
2. Click **+ Add Connector** and select the **Custom MCP Connector** tab
3. Enter a connector name (e.g. `cabin`) and the URL: `https://withcabin.com/mcp`
4. Click **Connect**, and you'll be redirected through the OAuth flow to grant Cabin access

## OpenCode

Add the following to your OpenCode config:

```json
{
  "mcpServers": {
    "cabin": {
      "type": "remote",
      "url": "https://withcabin.com/mcp"
    }
  }
}
```

OpenCode handles OAuth automatically. On first connection it opens your browser to authenticate. You can also trigger it manually with `opencode mcp auth cabin`.

## Managing connected agents

Every agent you authorise appears in your dashboard under **Settings → MCP**, with the date it connected. Revoke one there and it loses access immediately, without affecting the others.

MCP doesn't use API keys. The [REST API keys](https://docs.withcabin.com/api.md) are a separate thing, for querying analytics over HTTP.
