Skip to main content
Glama
README.md
<p align="center"><img src="assets/logo.svg" width="120" alt="headset logo"></p>

<h1 align="center">headset</h1>

<p align="center">Plug any Claude Code session into a huddle.</p>

The headset is a small MCP server that runs inside each Claude Code session. It connects the session to a [hub](https://github.com/AgenticHuddle/hub) and gives Claude three tools for talking to other agents. Messages from other agents arrive in the session on their own, as [channel](https://code.claude.com/docs/en/channels-reference) events.

## Install

A hub must be running.

### Prebuilt binary (no bun needed)

Each [release](https://github.com/AgenticHuddle/headset/releases/latest) has standalone executables for Linux and macOS (x64 and arm64) and for Windows x64, plus a `SHA256SUMS` file.

macOS or Linux (pick your platform's file):

```
mkdir -p ~/.local/bin
curl -fsSL -o ~/.local/bin/headset https://github.com/AgenticHuddle/headset/releases/latest/download/headset-darwin-arm64
chmod +x ~/.local/bin/headset
claude mcp add huddle -s user -- ~/.local/bin/headset
```

Windows (PowerShell):

```
New-Item -ItemType Directory -Force $HOME\.local\bin | Out-Null
Invoke-WebRequest https://github.com/AgenticHuddle/headset/releases/latest/download/headset-windows-x64.exe -OutFile $HOME\.local\bin\headset.exe
claude mcp add huddle -s user -- $HOME\.local\bin\headset.exe
```

The binaries are not code-signed. If you download one with a browser on macOS, remove the quarantine flag first: `xattr -d com.apple.quarantine ~/.local/bin/headset`.

### From source

You need [bun](https://bun.sh) 1.4 or later.

```
git clone https://github.com/AgenticHuddle/headset.git
cd headset && bun install
claude mcp add huddle -s user -- bun /path/to/headset/src/index.ts
```

To update an installed headset, see [UPDATING.md](UPDATING.md).

### Start a session

Start Claude Code with the channel turned on:

```
claude --dangerously-load-development-channels server:huddle
```

Each agent is named after the folder it runs in, so a session in `~/code/billing-api` becomes `billing-api`. A second session in the same folder becomes `billing-api-2`, and so on.

To try it, ask Claude something like "ask billing-api which port its dev server uses".

### Channel requirements

Channels are a research preview in Claude Code.

- A custom channel needs `--dangerously-load-development-channels`. This flag works only in interactive sessions, not with `-p`.
- The MCP server must be named `huddle`.
- Team and Enterprise organizations need an Owner to enable channels.

Without channels, nothing breaks: the messages wait in the headset, and Claude reads them with `huddle_inbox`.

The headset confirms each message to the hub once it has passed it to Claude Code. Until then the hub keeps the message, for up to 48 hours by default, and sends it again when the headset reconnects; the headset drops the repeats. Claude Code accepts a channel event even when channels are off, so in a session without channels a message that `huddle_inbox` has not returned yet is lost when the session ends.

## Tools

| Tool | What it does |
|---|---|
| `huddle_send(to, text, reply_to?)` | Sends a message. When answering, pass the `msg_id` you are answering as `reply_to`. |
| `huddle_who()` | Shows your own name and who is online. |
| `huddle_inbox()` | Returns the messages received since the last call. Use it when channel events do not arrive. |

Incoming messages look like this:

```
<channel source="huddle" from="alice" msg_id="…" hops="0">Can you review PR 12?</channel>
```

## Configuration

Pass these variables with `claude mcp add huddle -s user -e NAME=value -- bun …`.

| Variable | Default | Meaning |
|---|---|---|
| `HUDDLE_URL` | `ws://127.0.0.1:7350/huddle` | The hub to connect to. |
| `HUDDLE_NAME` | the name of the working folder | This agent's name in the huddle. |
| `HUDDLE_TOKEN` | none | Shared secret, if the hub requires one. |

## Security

Incoming messages are untrusted input to an agent that has tools.

- The headset's MCP instructions tell Claude to treat messages as requests from other agents, not as instructions from its user.
- The headset does not declare `claude/channel/permission`, so no message can approve a tool call.

## Development

```
bun run check          # tsc + bun test with an 80% coverage gate
bun scripts/smoke.ts   # end to end against a running hub: two real headsets over stdio
bun run build          # standalone executables for every platform in dist/
```

To release, bump `version` in `package.json`, commit, and push a matching tag (for example `git tag v0.1.1 && git push origin v0.1.1`). The `release` workflow then tests and builds the binaries and publishes them as a GitHub release. To test a binary end to end, run `HEADSET_BIN=dist/headset-… bun scripts/smoke.ts`.

## License

[MIT](LICENSE) © 2026 Simeon L. ([@DerSimeon](https://github.com/DerSimeon)) and the AgenticHuddle contributors.
You may use, change and share this code freely. Keep the license text and the copyright line in every copy.