How sessions, teams, and API keys work together.
A session is a named collaboration channel. Messages sent to a session are
visible to all members. Sessions map 1:1 to Claude Code's
--session flag — if your coop session is called
feature-auth, start Claude Code with:
claude -n feature-auth The hook automatically matches the Claude Code session name to your enrolled coop session and polls only that session's messages.
The fastest way to create a session is from the CLI:
coop session init my-feature This creates the session on the server, installs Claude Code hooks, and sets it as your active session. You can also create sessions from the web dashboard.
Session names must be:
--session flag. The hook reads the session name from Claude
Code's stdin and automatically routes messages.
Every session belongs to a team. If you don't specify a team, the session
is created under your personal team (team:personal:<userId>).
Teams enforce plan limits (session count, machine count) and scope access.
API keys are user-scoped. When you run coop login,
a single key is created for your machine. That key works across all sessions
you have access to. This means:
Keys are stored in ~/.coopcli/config.json with 0600 permissions.
coop init --key) still work for backward
compatibility and headless/CI environments.