#Claude Code Teams

coterm claude-teams launches Claude Code with agent teams enabled. When Claude spawns teammate agents, they appear as native coterm splits instead of tmux panes, with full sidebar metadata and notifications.

#Usage

coterm claude-teams
coterm claude-teams --continue
coterm claude-teams --model sonnet

All arguments after claude-teams are forwarded to Claude Code. The command defaults teammate mode to auto and sets the environment so Claude uses coterm splits.

#How it works

coterm claude-teams creates a tmux shim script and configures the environment so Claude Code thinks it's running inside tmux. When Claude issues tmux commands to manage teammate panes, the shim translates them into coterm socket API calls.

  • Creates a tmux shim at ~/.coterm/claude-teams-bin/tmux that redirects to coterm __tmux-compat
  • Sets TMUX and TMUX_PANE environment variables to simulate a tmux session
  • Prepends the shim directory to PATH so Claude finds the shim before real tmux
  • Enables CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 and sets teammate mode to auto

#Environment variables

VariablePurpose
TMUXFake tmux socket path encoding the current coterm workspace and pane
TMUX_PANEFake tmux pane identifier mapped to the current coterm pane
CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMSEnables Claude Code agent teams feature
COTERM_SOCKET_PATHPath to the coterm control socket for the shim to connect to

#Directories

PathPurpose
~/.coterm/claude-teams-bin/Contains the tmux shim script that translates tmux commands to coterm API calls
~/.coterm/tmux-compat-store.jsonPersistent storage for tmux-compat buffers and hooks

#Supported tmux commands

The shim translates these tmux commands into coterm operations:

  • new-session, new-windowcreates a new coterm workspace
  • split-windowsplits the current coterm pane
  • send-keyssends text to a coterm surface
  • capture-panereads terminal text from a coterm surface
  • select-pane, select-windowfocuses a coterm pane or workspace
  • kill-pane, kill-windowcloses a coterm surface or workspace
  • list-panes, list-windowslists coterm panes or workspaces