Skip to content

Agent Teams API

Saved rosters for launching or reusing local Claude Code and Codex CLI sessions.

Presets

List Presets

http
GET /api/v1/agent-teams/presets

Returns saved team presets and their slots.

Get Preset

http
GET /api/v1/agent-teams/presets/{preset_id}

Returns one saved team preset with its slots.

Create Preset

http
POST /api/v1/agent-teams/presets
json
{
  "name": "Release validation",
  "description": "Agents used to validate a release branch",
  "slots": [
    {
      "provider": "codex-cli",
      "repo_path": "/home/user/repo",
      "display_name": "Reviewer",
      "role": "planner-reviewer",
      "charter": "Review the plan and implementation against release goals.",
      "enabled": true
    }
  ]
}

Create From Current State

http
POST /api/v1/agent-teams/presets/from-agent-mail
POST /api/v1/agent-teams/presets/from-agent-bridge

from-agent-mail snapshots selected durable Agent Mail members. from-agent-bridge snapshots currently visible Agent Bridge tmux sessions and can keep multiple same-repo sessions as separate slots.

Update, Duplicate, And Delete

http
PATCH /api/v1/agent-teams/presets/{preset_id}
POST /api/v1/agent-teams/presets/{preset_id}/duplicate
DELETE /api/v1/agent-teams/presets/{preset_id}

Slots

http
POST /api/v1/agent-teams/presets/{preset_id}/slots
PATCH /api/v1/agent-teams/slots/{slot_id}
DELETE /api/v1/agent-teams/slots/{slot_id}
POST /api/v1/agent-teams/presets/{preset_id}/slots/reorder

Slots store provider, repository path, display name, role, charter, bootstrap prompt, launch mode, provider options, and enabled state.

Launch Planning

Plan Launch

http
POST /api/v1/agent-teams/presets/{preset_id}/plan-launch
json
{
  "requested_by": "OpenClaw"
}

The plan checks provider availability, Agent Mail MCP/hooks readiness, reusable Agent Bridge sessions, disabled slots, and launch-option validity.

Launch

http
POST /api/v1/agent-teams/presets/{preset_id}/launch
json
{
  "requested_by": "OpenClaw",
  "confirm_plan_hash": "returned-plan-hash"
}

Use confirm_plan_hash after reviewing a plan. Local automation can pass skip_plan_confirmation: true when it intentionally wants a one-step launch; stale plans return 409 with the updated plan.

After launch, agents register through Agent Mail and receive team-slot role and charter context.

Released under the MIT License.