anthropics / anthropics/claude-plugins-official
docs(hook-development): tool_result should be tool_response
- Dominant language
- Python
- Stars
- 36.3k
- Forks
- 4.1k
- Avg merge
- 2d 14h
- Merged PRs (30d)
- 539
Description
## Bug
`plugins/plugin-dev/skills/hook-development/SKILL.md`, "Hook Input Format":
```md
**Event-specific fields:**
- **PreToolUse/PostToolUse:** `tool_name`, `tool_input`, `tool_result`
```
`PostToolUse` never receives a `tool_result` field. Per the [official hooks reference](https://code.claude.com/docs/en/hooks#posttooluse-input):
> `PostToolUse` hooks fire after a tool has already executed successfully. The input includes both `tool_input`, the arguments sent to the tool, and `tool_response`, the result it returned.
A hook written against this doc (`input_data.get("tool_result")`) silently gets nothing.
## Fix
```diff
- **PreToolUse/PostToolUse:** `tool_name`, `tool_input`, `tool_result`
+ **PreToolUse:** `tool_name`, `tool_input`
+ **PostToolUse:** `tool_name`, `tool_input`, `tool_response`
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Open plugins/plugin-dev/skills/hook-development/SKILL.md and read the “Hook Input Format” section alongside the linked PostToolUse reference. Separate the PreToolUse and PostToolUse field lists so PostToolUse names tool_response, then verify the documentation no longer claims that PostToolUse receives tool_result.
Written by the indexing model from the issue text.
Assessment
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 76/100