1
---
2
name: team-communication-protocols
3
description: Structured messaging protocols for agent team communication including message type selection, plan approval, shutdown procedures, and anti-patterns to avoid. Use this skill when establishing communication norms for a newly spawned team, when deciding whether to send a direct message or a broadcast, when a team-lead needs to review and approve an implementer's plan before work begins, when orchestrating a graceful team shutdown after all tasks are complete, or when debugging why teammates are not coordinating correctly at integration points.
4
version: 1.0.2
5
---
6
7
# Team Communication Protocols
8
9
Protocols for effective communication between agent teammates, including message type selection, plan approval workflows, shutdown procedures, and common anti-patterns to avoid.
10
11
## When to Use This Skill
12
13
- Establishing communication norms for a new team
14
- Choosing between message types (message, broadcast, shutdown_request)
15
- Handling plan approval workflows
16
- Managing graceful team shutdown
17
- Discovering teammate identities and capabilities
18
19
## Message Type Selection
20
21
### `message` (Direct Message) — Default Choice
22
23
Send to a single specific teammate:
24
25
```json
26
{
27
"type": "message",
28
"recipient": "implementer-1",
29
"content": "Your API endpoint is ready. You can now build the frontend form.",
30
"summary": "API endpoint ready for frontend"
31
}
32
```
33
34
**Use for**: Task updates, coordination, questions, integration notifications.
35
36
### `broadcast` — Use Sparingly
37
38
Send to ALL teammates simultaneously:
39
40
```json
41
{
42
"type": "broadcast",
43
"content": "Critical: shared types file has been updated. Pull latest before continuing.",
44
"summary": "Shared types updated"
45
}
46
```
47
48
**Use ONLY for**: Critical blockers affecting everyone, major changes to shared resources.
49
50
**Why sparingly?**: Each broadcast sends N separate messages (one per teammate), consuming API resources proportional to team size.
51
52
### `shutdown_request` — Graceful Termination
53
54
Request a teammate to shut down:
55
56
```json
57
{
58
"type": "shutdown_request",
59
"recipient": "reviewer-1",
60
"content": "Review complete, shutting down team."
61
}
62
```
63
64
The teammate responds with `shutdown_response` (approve or reject with reason).
65
66
## Communication Anti-Patterns
67
68
| Anti-Pattern | Problem | Better Approach |
69
| --------------------------------------- | ---------------------------------------- | -------------------------------------- |
70
| Broadcasting routine updates | Wastes resources, noise | Direct message to affected teammate |
71
| Sending JSON status messages | Not designed for structured data | Use TaskUpdate to update task status |
72
| Not communicating at integration points | Teammates build against stale interfaces | Message when your interface is ready |
73
| Micromanaging via messages | Overwhelms teammates, slows work | Check in at milestones, not every step |
74
| Using UUIDs instead of names | Hard to read, error-prone | Always use teammate names |
75
| Ignoring idle teammates | Wasted capacity | Assign new work or shut down |
76
77
## Plan Approval Workflow
78
79
When a teammate is spawned with `plan_mode_required`:
80
81
1. Teammate creates a plan using read-only exploration tools
82
2. Teammate calls `ExitPlanMode` which sends a `plan_approval_request` to the lead
83
3. Lead reviews the plan
84
4. Lead responds with `plan_approval_response`:
85
86
**Approve**:
87
88
```json
89
{
90
"type": "plan_approval_response",
91
"request_id": "abc-123",
92
"recipient": "implementer-1",
93
"approve": true
94
}
95
```
96
97
**Reject with feedback**:
98
99
```json
100
{
101
"type": "plan_approval_response",
102
"request_id": "abc-123",
103
"recipient": "implementer-1",
104
"approve": false,
105
"content": "Please add error handling for the API calls"
106
}
107
```
108
109
## Shutdown Protocol
110
111
### Graceful Shutdown Sequence
112
113
1. **Lead sends shutdown_request** to each teammate
114
2. **Teammate receives request** as a JSON message with `type: "shutdown_request"`
115
3. **Teammate responds** with `shutdown_response`:
116
- `approve: true` — Teammate saves state and exits
117
- `approve: false` + reason — Teammate continues working
118
4. **Lead handles rejections** — Wait for teammate to finish, then retry
119
5. **After all teammates shut down** — Call `TeamDelete` to remove team resources
120
121
### Handling Rejections
122
123
If a teammate rejects shutdown:
124
125
- Check their reason (usually "still working on task")
126
- Wait for their current task to complete
127
- Retry shutdown request
128
- If urgent, user can force shutdown
129
130
## Teammate Discovery
131
132
Find team members by reading the config file:
133
134
**Location**: `~/.claude/teams/{team-name}/config.json`
135
136
**Structure**:
137
138
```json
139
{
140
"members": [
141
{
142
"name": "security-reviewer",
143
"agentId": "uuid-here",
144
"agentType": "team-reviewer"
145
},
146
{
147
"name": "perf-reviewer",
148
"agentId": "uuid-here",
149
"agentType": "team-reviewer"
150
}
151
]
152
}
153
```
154
155
**Always use `name`** for messaging and task assignment. Never use `agentId`, role names, or unsuffixed aliases directly. If a teammate was spawned as `team-lead-2`, send to `team-lead-2`, not `team-lead`.
156
157
## Troubleshooting
158
159
**A teammate is not responding to messages.**
160
Check the teammate's task status. If it is idle, it may have completed its task and is waiting to be assigned new work or shut down. If it is still active, it may be mid-execution and will process messages once the current operation finishes.
161
162
**A teammate says it cannot see SendMessage.**
163
Check the teammate agent's `tools:` frontmatter. Agent Teams communication tools such as `SendMessage`, `TaskList`, `TaskGet`, and `TaskUpdate` must be listed explicitly when an agent uses a restricted tool allowlist.
164
165
**The lead is sending broadcasts for every status update.**
166
This is a common anti-pattern. Broadcasts are expensive — each one sends N messages. Use direct messages (`type: "message"`) for point-to-point updates. Reserve broadcasts for critical shared-resource changes like an updated interface contract.
167
168
**A teammate rejected a shutdown request unexpectedly.**
169
The teammate is still working. Check the rejection reason in the `shutdown_response` content field, wait for the work to finish, then retry. Never force-terminate a teammate that has unsaved work.
170
171
**A plan_approval_request arrived but the request_id is missing.**
172
The teammate called `ExitPlanMode` without the required request context. Have the teammate re-enter plan mode, complete exploration, and call `ExitPlanMode` again. The `request_id` is generated automatically by the plan mode system.
173
174
**Two teammates are waiting on each other and neither is making progress.**
175
This is a deadlock: both are blocked waiting for the other to finish first. The lead should send a direct message to one teammate with a stub or partial result so it can unblock and proceed.
176
177
## Related Skills
178
179
- [team-composition-patterns](../team-composition-patterns/SKILL.md) — Select agent types and team size before establishing communication norms
180
- [parallel-feature-development](../parallel-feature-development/SKILL.md) — Use communication protocols to coordinate integration handoffs between parallel implementers
181