agent-handoff

agent-handoff is a command for Claude Code from DimitriGeelen/agentic-engineering-framework. It costs 0 tokens per session (1,589 once invoked), scanned A, original, Apache-2.0.

Wraps termlink agent contact so vendored Claude Code agents can hand off context to a peer agent in one command. Replaces the legacy remote push.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/dimitrigeelen/agentic-engineering-framework/agent-handoff
Clone the repo
git clone --depth 1 https://github.com/DimitriGeelen/agentic-engineering-framework

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for agent-handoff

README.md
[![agentmods](https://agentmods.dev/badge/commands/dimitrigeelen/agentic-engineering-framework/agent-handoff.svg)](https://agentmods.dev/commands/dimitrigeelen/agentic-engineering-framework/agent-handoff)
Your own site
<a href="https://agentmods.dev/commands/dimitrigeelen/agentic-engineering-framework/agent-handoff"><img src="https://agentmods.dev/badge/commands/dimitrigeelen/agentic-engineering-framework/agent-handoff.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,589 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01589
Opus 5 $0.00000 $0.00794
Sonnet 5 $0.00000 $0.00318
Haiku 4.5 $0.00000 $0.00159

Measured today against content hash 1da1e6032642, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

agent-handoff scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/agent-handoff.md · 168 lines

How it starts

The opening of the file, as written. The whole thing — 168 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/agent-handoff - Cross-Host Agent Contact (T-1429 wrapper)

Wraps termlink agent contact so vendored Claude Code agents can hand off context to a peer agent in one command. Replaces the legacy remote push

  • inbox.push improv pattern (T-1166 retired).

Invocation: /agent-handoff <target> <task-id> "<message>"

  • <target> — the peer agent's display_name, resolvable via local termlink session.discover (e.g., framework-agent, oss-dash).
  • <task-id> — the active task this handoff belongs to (e.g., T-1429). Must exist under .tasks/active/. Embedded as a [T-XXX] prefix in the message body so the receiver can route by thread.
  • <message> — the handoff summary in plain text. Quote it.

Protocol canon is documented on the topic itself — run termlink channel info agent-chat-arc to see the 5 invariants in-place (T-1430).

Step 1: Verify the task exists

Run:

ls .tasks/active/<task-id>-*.md 2>/dev/null

If no match, stop. Print:

agent-handoff: task <task-id> not found in .tasks/active/.
Create it first: fw work-on "topic" --type build

Exit non-zero. Do NOT post to a non-existent task.

Step 2: Capture self identity (for log visibility)

Run:

termlink whoami --json 2>/dev/null

If single candidate: capture sender_id. If multi-candidate (multiple sessions on this hub): prefer the one whose cwd matches $(pwd). If still ambiguous, fall back to the first candidate and note the ambiguity in the Update entry. If whoami fails: continue with sender_id=unknown — identity binding is enforced server-side once T-1427 ships, not here.

Step 3: Post to the peer

Run:

termlink agent contact "<target>" --message "[<task-id>] <message>" --json

Capture stdout. The actual JSON shape (T-1429 Phase-1, verified live 2026-05-01):

{
  "delivered": { "offset": <integer>, "ts": <ms-since-epoch> }
}

If exit code is non-zero or delivered is missing: stop. Print the verb's stderr and exit non-zero. The verb already prints actionable errors (peer offline, missing identity_fingerprint, etc.) — do not swallow them.

Read the full file on GitHub · 168 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 168 lines · 0 tokens per session scan A 1da1e6032642

Subscribe to this mod's changes

agent-handoff is a command published in the GitHub repository DimitriGeelen/agentic-engineering-framework (13 stars, last pushed today), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,589 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.