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.
npx agentmods add skills/joris887/exosuit/custom-hooksnpx skills add joris887/exosuit --skill custom-hooksgit clone --depth 1 https://github.com/joris887/exosuitWrote 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.
[](https://agentmods.dev/skills/joris887/exosuit/custom-hooks)<a href="https://agentmods.dev/skills/joris887/exosuit/custom-hooks"><img src="https://agentmods.dev/badge/skills/joris887/exosuit/custom-hooks.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00023 | $0.01215 |
| Opus 5 | $0.00012 | $0.00607 |
| Sonnet 5 | $0.00005 | $0.00243 |
| Haiku 4.5 | $0.00002 | $0.00121 |
Grade A, and why
custom-hooks 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 5d ago.
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.
How it starts
The opening of the file, as written. The whole thing — 143 lines — stays where its author put it; the contents beside it link to each section on GitHub.
custom-hooks
Creating a custom hook: $ARGUMENTS
Supported Hook Events
Present available Claude Code hook events:
| Event | When It Fires | Can Block? | Input Fields |
|---|---|---|---|
SessionStart |
Once at session start | No | session data |
PreToolUse |
Before any tool call | Yes (exit 2) | tool_name, tool_input |
PostToolUse |
After any tool call | No | tool_name, tool_input, tool_output |
Stop |
When model wants to stop | Yes (exit 2) | last_assistant_message |
UserPromptSubmit |
When user submits prompt | No | user_prompt |
SubagentStop |
When a subagent completes | No | last_assistant_message |
WorktreeCreate |
When a worktree is created | No | — |
WorktreeRemove |
When a worktree is removed | No | — |
Matchers (for PreToolUse and PostToolUse): Filter by tool name — Bash, Edit, Write, Read, Glob, Grep, or combinations with | (e.g., Edit|Write).
1. Understand Requirements
Parse $ARGUMENTS to determine:
- Event type: Which hook event to listen to
- Purpose: What the hook should do
- Blocking vs Advisory: Should it block (exit 2) or just warn (exit 0)?
If unclear, ask:
- "Should this hook block the action or just warn?"
- "Should it fire on specific tools only, or all tools?"
- "Should it run on subagents too?"
2. Generate Hook Script
Create a POSIX shell script following the framework's hook conventions:
#!/bin/sh
# [Event] handler: [description].
# [Blocking|Advisory] — [behavior summary].
# POSIX-compliant — no bash required.
#
# Input: JSON on stdin ([relevant fields])
# Output: exit 0 = allow, exit 2 = block (message on stderr)
HOOKS_DIR="$(cd "$(dirname "$0")" && pwd)"
# --- JSON field extraction ---
extract_json_string() {
_field="$1"
if command -v jq >/dev/null 2>&1; then
jq -r ".$_field // empty"
else
sed -n 's/.*"'"$_field"'"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' | head -1
fi
}
# Read stdin once
INPUT=$(cat)
# --- Hook logic ---
# [Custom logic here]
exit 0
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.
- 5d ago First seen · 143 lines · 23 tokens per session scan A 8929ca9c4e48
custom-hooks is a skill published in the GitHub repository joris887/exosuit (4 stars, last pushed 16d ago), licensed MIT. It adds 23 tokens to every session and 1,215 once invoked, about $0.0001 per session on Opus 5. 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-08-31.
Other skills, from other repositories
issue-triage
Issue triage: audit open issues, categorize, detect duplicates, cross-ref PRs, risk assessment, post comments. Args: "all" for deep analysis of all, issue numbers to focus (e.g. "42 57"), "en"/"fr" for language, no arg = audit only in French.
build-teaql-app
Build or change a TeaQL application in Java, Rust, Go, Swift, Python, C#/.NET, or TypeScript, including Kotlin/JVM applications that consume Java-generated libraries. Mandatory order: first draft and save a complete KSML model, then verify the client and evaluate that saved model, repair it through repeated evaluation…
moai-workflow-worktree
Git worktree management for parallel SPEC development with isolated workspaces, automatic branch registration, and seamless MoAI-ADK integration. Use when setting up parallel development environments.
moai-kanban-foreman
One unattended kanban foreman iteration: watch the backlog queue, dispatch the next operator-picked card to an isolated worker, collect completion evidence on read (not on claims), and report. This is the body the project's loop.md driver invokes each iteration of a bare /loop; it can also be invoked directly to test…
moai-workflow-thinking
Sequential Thinking MCP for structured step-by-step analysis via --deepthink flag. Separate from UltraThink which is Claude's native extended reasoning mode. Use for multi-step analysis or architecture decisions.
moai-domain-uiux
UI/UX design systems specialist covering accessibility, icons, theming, design tokens, and user experience patterns. Use when working on design systems, WCAG compliance, ARIA patterns, or dark mode theming.