SITUATION
Your security team has requested a Hook system for Claude Code. They need to block sensitive file access and automate code quality checks. The project has incomplete hooks that you need to fix and extend.
Hooks intercept Claude's tool usage. Use exit code 2 to block dangerous operations.
Document your learnings in CLAUDE.md using the # command!
PROJECT SETUP
Click to download hooks-challenge.zip directly
# 1. Extract the downloaded zip
unzip hooks-challenge.zip -d my-hooks
# 2. Navigate to project
cd my-hooks
# 3. Install dependencies
npm install
# 4. Copy settings (IMPORTANT!)
cp .claude/settings.example.json .claude/settings.json
Run /init to analyze the project. Check hooks/ directory for existing hooks.
Challenge Details Locked
Start your timer to reveal the challenge requirements, scoring rubric, and submission form.
Your time will be recorded for the leaderboard ranking.
WHAT YOU'LL PRACTICE
PreToolUse Hooks
Intercept and control tool execution before it happens.
exit(2) to block
PostToolUse Hooks
Automate actions after tool execution completes.
tool_response data
Claude Agent SDK
Call Claude programmatically from hooks.
@anthropic-ai/claude-agent-sdk
settings.json
Configure hook matchers and commands.
Write|Edit|MultiEdit
Challenge Not Yet Started
Admin has not started this week's challenge yet. Please wait.
SUBMIT YOUR WORK
📋 How to Submit
- 1 Push your code to a GitHub repository
- 2 Make sure CLAUDE.md and hooks/ are included
- 3 Enter your repository URL below and click Submit