# Connect Claude Code to Aisenhour

> Connect the Claude Code terminal CLI directly to your matrix

Connect Claude Code in your terminal so you can pull delegated tasks, review code requests, check off subtasks, and post deliverables straight from your development environment.

*Not yet verified*

## Setup Steps

### Step 1: Connect with URL and browser sign-in (Recommended)

Run the following command in your terminal to save the Aisenhour server configuration across every folder on your machine (`-s user` stores it in your user profile instead of only the current folder's `local` config):

After saving the server config, run `claude mcp login aisenhour` in your terminal — or start `claude`, run `/mcp`, select `aisenhour`, and choose **Authenticate** — to open your browser, sign in, and click **Allow access**. Claude Code stores your session tokens automatically.

```bash
claude mcp add --transport http -s user aisenhour https://aisenhour.com/api/mcp
```

### Step 2: Fallback: Connect with an API key

Alternatively, create an agent key in Aisenhour Settings > My agents and pass it via the authorization header (using `-s user` so the connection is available across all folders):

```bash
claude mcp add --transport http -s user aisenhour https://aisenhour.com/api/mcp --header "Authorization: Bearer YOUR_AH_LIVE_KEY"
```

### Step 3: Confirm the server is active

Start Claude Code by typing `claude` in your terminal. You can run `/mcp` inside Claude Code to verify that Aisenhour is connected and all tools are ready to use.

## Your First Handoff Prompt

Paste this prompt into Claude Code to complete your first handoff:

```text
Check my Aisenhour Delegate queue for active tasks assigned to me, or create a new task for me with assignTo: "me". Review what needs to be done and ask me before making any changes.
```

This starter prompt tests connectivity, allows task capture for yourself, and ensures your terminal assistant stays within the boundaries of delegated work.

## What Your Assistant Can See

- Tasks in your Delegate queue that you have explicitly enabled for assistant pickup
- Active board tasks across quadrants when whole-board reading is enabled
- Task checklist subtasks, categories, and progress notes on assigned tasks
- Executive summaries of your board when requested

## What Stays Private

- Private tasks in Do First, Decide, or Delete when whole-board reading is disabled
- Your account password, billing details, or payment history
- Tasks in your Archive or other personal boards

## Plan Access and Pricing

Connecting an external assistant is free on both Free and Pro plans (Free includes up to 25 active tasks, Pro includes unlimited active tasks). Claude Code runs on your own Anthropic API token.

## Troubleshooting

### Server already exists in local config or need to sign in again

Re-running `claude mcp add` fails if `aisenhour` is already registered. To redo browser sign-in without deleting the server, run `claude mcp logout aisenhour && claude mcp login aisenhour`. To replace an older local entry with the global `-s user` scope, remove it first and re-add:

```bash
claude mcp logout aisenhour && claude mcp login aisenhour
# Or remove an existing entry and re-add across all folders:
claude mcp remove aisenhour
claude mcp add --transport http -s user aisenhour https://aisenhour.com/api/mcp
```

### Server missing when opening another folder

Without `-s user`, `claude mcp add` defaults to `-s local` and only applies to the directory where you ran it. Remove the local entry and re-add with `-s user` so Aisenhour is available in every folder on your machine:

```bash
claude mcp remove aisenhour
claude mcp add --transport http -s user aisenhour https://aisenhour.com/api/mcp
```

### Connected in terminal, but editor chat still says disconnected

The `claude` CLI stores connections in `~/.claude.json`, which is separate from editor assistants. Google Antigravity reads `~/.gemini/config/mcp_config.json` (with `"serverUrl"`), Cursor reads `.cursor/mcp.json` (with `"url"`), and Claude Desktop keeps its own connector list. Connect whichever app you are chatting in.

## Disconnecting or Rotating Access

You can revoke or rotate this assistant's access at any time in Aisenhour Settings > My agents. Revoking an agent immediately invalidates all OAuth tokens and denies subsequent requests from Claude Code.
