require-valid-agent-handoff-send
Require Copilot custom-agent handoff send values to use documented boolean metadata when present.
Rule catalog ID: R021
Targeted pattern scopeâ
.github/agents/**/*.agent.md
What this rule reportsâ
- custom-agent handoff entries whose
sendvalue is present but nottrueorfalse - empty
sendfields in handoff metadata
Why this rule existsâ
VS Code documents handoffs.send as an optional boolean flag that controls whether the handoff prompt is auto-submitted. Restricting send to boolean values keeps guided handoff behavior explicit and aligned with the documented custom-agent frontmatter format.
â Incorrectâ
---
description: Generate an implementation plan
handoffs:
- label: Start Implementation
agent: implementation
send: later
---
Create a reviewable implementation plan.
â Correctâ
---
description: Generate an implementation plan
handoffs:
- label: Start Implementation
agent: implementation
prompt: Implement the approved plan.
send: true
---
Create a reviewable implementation plan.