Per-engineer attribution by design
Every receipt issued from a Claude Code session is tagged with the human DID of the engineer at the keyboard. This matters when a security review later asks "which engineer ran which tool calls during the incident on June 14th?" — your answer is a filterable receipt query, not a guess from Slack logs. Per-engineer attribution costs zero extra config: the human DID lives in ~/.genzagents-mcp-env (mode 600) and the MCP server reads it on every tool call.
Auto-receipt on git commit
Install the post-commit hook from `scripts/auto-receipt-on-commit.sh`. Every commit emits a receipt that includes: commit SHA, commit body (the rationale, not just the diff), the files touched, and the project tag. Run it with `--since=<rev>` to backfill previous commits — useful when you join GenZAgents mid-way through a project and want the past 3 months of work to show up on the agent's receipt feed.
Stop-hook session capture
Claude Code emits a Stop event when the user ends a session (Cmd-K → /quit or just closes the window). The GenZAgents MCP server hooks this event and issues a single summary receipt covering the whole session. The summary includes: total tool calls made, files read, files written, commits issued, runtime cost. One receipt per session keeps the receipt-per-tool-call noise manageable while preserving an end-of-session audit trail.
Per-project tagging via .mcp.json
Drop the .mcp.json in the repo root with a `GENZAGENTS_PROJECT=acme-checkout` env var. Every receipt from sessions opened in that directory inherits the project tag. When you have 50 repos and 12 engineers, this is the only way to keep the receipt feed legible — "show me everything tagged acme-checkout in the last 30 days" beats scrolling through 4,000 entries.
Org-wide de-dup on conversation start
The `org_context_lookup` MCP tool fires at the start of every Claude Code conversation. It queries the org's receipt pool against the first user prompt and surfaces matches: "Sarah did this on May 3rd — see receipt rcpt_01XK… Want to start from her work?" Maria saves a day of redundant work. This is how the v0.6+ proactive de-dup loop pays back its cost on the first month of use.
Cost attribution per repo and per engineer
Every receipt logs the model used and the runtime cost in USD. The dashboard rolls these up: "Bob spent $187 on Claude Code this month, $142 on acme-checkout and $45 on internal tools." This is the per-team per-project cost ledger that AI spend reports want — your CFO stops asking "what is the Anthropic invoice paying for?" because the answer is one filtered receipt query away.
Install
Per-project: create .mcp.json in repo root:
{
"mcpServers": {
"genzagents": {
"command": "npx",
"args": ["-y", "@genzagentsio/mcp-server"]
}
}
}
Global: same block in ~/.claude.json. Restart Claude Code.What we capture
Stop-hook session events, auto-receipt-on-commit hook commits, every MCP tool call, and (optionally) the first user prompt of the session.
Verify it works
Open Claude Code on any repo with the .mcp.json above → ask Claude to read a file → end the session → check /dashboard for a session-completed receipt.