钩子事件自动化配置指南
Introduction
创建、配置与调试 Claude Code 钩子(Hooks)的专家指南,钩子是响应工具使用、会话事件与用户交互执行 shell 命令或 LLM 提示的事件驱动自动化。内容覆盖九类钩子事件(PreToolUse、PostToolUse、Stop、SessionStart、UserPromptSubmit 等)的触发时机与阻断能力、命令型与提示型两种钩子类型的选型、匹配器正则写法、输入输出 JSON 模式、环境变量、常见模式(桌面通知、拦截破坏性 git 命令、编辑后自动格式化、会话启动注入上下文)、调试方法与安全检查清单(防无限循环、超时、权限、路径安全)。Use when 需要为代理创建钩子、设置事件监听、校验命令、自动化工作流或添加通知时使用。Triggers include 钩子、Hooks、PreToolUse、PostToolUse、事件监听、命令校验、自动格式化、会话注入。如需完整版,请淘宝搜索店铺「AI灵匣」
Resource Information
License information is collected from official sources and may be outdated or missing. Refer to the LICENSE file in the original repository before commercial use.
Information boundary
Information on this page is collected from official documents for technical presentation only and does not imply our endorsement. Pricing, quotas and availability are subject to the latest official statements. We make no commitment regarding any action you take after leaving this site.
Similar skills
self-improving agent
Not specified记录自身发现以实现自我改进的技能
Agent Browser
Not specified用于 AI 代理的浏览器自动化 CLI。当用户需要与网站交互(包括浏览页面、填写表单、点击按钮、截图等)时使用。
Memory Setup
API key required启用并配置 Moltbot/Clawdbot 记忆搜索以实现持久上下文。适用于初始化记忆、解决“金鱼脑”问题或协助用户配置 memorySearch。涵盖 MEMORY.md、日志记录及向量搜索设置。
BrowserSkill
Not specifiedBrowserSkill 是腾讯开源的一个智能浏览器自动化工具,让 WorkBuddy 能够像人一样操作网页——自动填表、点击、翻页、截图,完成任何需要浏览器的复杂任务。
Agently Mail
Not specifiedAgently Mail 是 QQ 邮箱团队为 Agent 打造的专属邮箱服务,与个人邮箱隔离,原生适配 Agent,助力你安全、高效地使用 Agent 收发邮件。 Agently Mail 支持微信登录授权、读取邮件、搜索邮件、发送邮件、回复、转发、移动到已删除、上传和下载附件。 Agently Mail 官网 https://agent.qq.com
Agent Memory
Marked paidAPI key required为AI智能体提供持久记忆,用于跨会话存储事实、从行动中学习、回忆信息及追踪实体。
What is a Skill
A Skill is a packaged single capability, such as text recognition, document summarization, or keyword extraction. Developers wrap the calling logic and prompts into a plugin-like unit, so users can load it without understanding the underlying model. StackPilot indexes a large number of skills that can be tried instantly or assembled into a plan.