Documentation / Team mode

Coordinate agents across separate clones.

Team mode moves structured coordination to a shared service. Git still carries code; PACT carries intent, presence, events, evidence, and resumable cursors.

How the pieces connect

Clone ACodex + Team CLI
HTTPS
PACT TeamAPI + PostgreSQL
HTTPS
Clone BClaude + Team CLI

The server does not need repository access. It identifies a project and stores only the structured collaboration record scoped to that project.

1. Share the project

Start from a repository that already contains a committed .pact/project.json.

export PACT_TEAM_ADMIN_TOKEN="your-private-admin-token"

pact team share \
  --url https://pact.example.com \
  --member "Tim"

The Team endpoint is written to .pact/project.json. The owner credential stays in the ignored .pact/state/team-auth.json file.

2. Invite a collaborator

# Owner
pact team invite --expires 86400

# Collaborator, after cloning or pulling the repository
pact team accept --invite "$PACT_TEAM_INVITE" --member "Steve"

The invitation is private, expires, and can be used once. Each member receives a distinct credential.

3. Declare each agent's work

Clone A

pact team join \
  --runtime codex \
  --objective "Update authentication" \
  --surface file://src/auth \
  --surface contract://SessionResponse

Clone B

pact team join \
  --runtime claude \
  --objective "Adapt the UI" \
  --surface file://src/ui \
  --surface contract://SessionResponse

PACT detects the branch, base revision, and current HEAD. Save the returned session IDs.

4. Publish, synchronize, and leave

pact team publish \
  --session ses_... \
  --type activity.reported \
  --subject file://src/auth/session.mjs \
  --data '{"summary":"Added token rotation"}'

pact team sync --session ses_...
pact team status
pact team leave --session ses_... --outcome completed --summary "Tests pass"

Handoffs move through detected → delivered → acknowledged → implemented → verified → resolved. Verification requires an evidence reference; the service rejects invalid state jumps.

What lives where

DataLocation
Code and branchesGit remote and local clones
Project endpoint and protocol profileCommitted .pact/project.json
Member/session credentials and cursorsIgnored .pact/state/ in each clone
Intent, presence, events, handoffs, evidencePACT Team + PostgreSQL
Prompts, conversations, provider keysNever stored by PACT