mirror of
https://github.com/jarrodwatts/claude-hud.git
synced 2026-05-17 21:18:36 +00:00
798 B
798 B
API Contracts
HUD Event Schema (v1)
All events written to the HUD FIFO must include schemaVersion: 1. The HUD
will ignore events with an unknown schema version.
Required fields
schemaVersion: number (current:1)event: string (e.g.,PreToolUse,PostToolUse,Stop)session: stringts: number (epoch seconds)
Optional fields
tool: string or nulltoolUseId: stringinput: object or nullresponse: object or nullpermissionMode: stringtranscriptPath: stringcwd: stringprompt: string
Example
{
"schemaVersion": 1,
"event": "PostToolUse",
"tool": "Read",
"toolUseId": "tool-1",
"input": { "file_path": "README.md" },
"response": { "duration_ms": 120 },
"session": "abc123",
"ts": 1700000000
}