cc-notify-hooks CLAUDE.md

cc-notify-hooks CLAUDE.md is an instructions file for Claude Code, Codex from MarioZZJ/cc-notify-hooks. It costs 2,573 tokens per session, scanned B, original, MIT.

Repository instructions for cc-notify-hooks, a notification system that sends updates from coding-agent events through several channels. It includes the project layout, supported agent integrations, setup guidance, and test commands.

In plain words
What is it for?
Use it when developing, configuring, installing, or testing cc-notify-hooks for Claude Code, Codex CLI, Reasonix, or dsh.
Why use it?
It gives a coding agent the project-specific rules needed to find the right files, install the system, and test notification delivery without guessing.

Instructions file for Claude CodeCodex

Written for Claude Code and Codex: ${CLAUDE_PLUGIN_DATA} variable, but also reads ~/.codex or $CODEX_HOME. Also seen: reads .claude/ paths; names the AskUserQuestion tool; positional $N argument.

Runs only inside a plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else, and the catalogue could not identify which plugin ships it.

Install

Getting it into your agent

There is no command for this one: it runs only inside a plugin, and the catalogue could not identify which plugin ships it. The source is linked below.

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for cc-notify-hooks CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/mariozzj/cc-notify-hooks/claude-md.svg)](https://agentmods.dev/instructions/mariozzj/cc-notify-hooks/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/mariozzj/cc-notify-hooks/claude-md"><img src="https://agentmods.dev/badge/instructions/mariozzj/cc-notify-hooks/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 2,573 This file is loaded in full into every session.
When invoked 2,573 The same file — it is already loaded in full.
Security scan B 2 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.02573 $0.02573
Opus 5 $0.01287 $0.01287
Sonnet 5 $0.00515 $0.00515
Haiku 4.5 $0.00257 $0.00257

Measured 6d ago against content hash be14a9c244f5, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade B, and why

cc-notify-hooks CLAUDE.md scanned grade B with 2 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 6d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

- 启用 hooks 需要 `~/.codex/config.toml` 添加 `[features]\ncodex_hooks = true`

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

- **依赖**: `jq`(JSON 解析)、`curl`(HTTP 请求)、`osascript`(macOS 通知)
CLAUDE.md · 151 lines

How it starts

The opening of the file, as written. The whole thing — 151 lines — stays where its author put it; the contents beside it link to each section on GitHub.

cc-notify-hooks

Claude Code、Codex CLI、Reasonix 与 dsh(DeepSeek Harness)的分级推送通知系统。通过 hook/拦截点触发多渠道通知,用户响应后自动取消排队中的推送。

技术栈

  • 语言: Bash(核心脚本)+ JavaScript(dsh 宿主插件,零依赖)
  • 依赖: jq(JSON 解析)、curl(HTTP 请求)、osascript(macOS 通知)
  • 集成: Claude Code / Codex CLI / Reasonix 的 hooks 插件机制 + dsh 的 cordis 拦截点

项目结构

plugins/cc-notify-hooks/    # 真实插件根目录(根目录的 scripts/hooks/config 是软链)
├── scripts/notify.sh       # 主调度器:事件过滤、延迟排队、渠道分发(兼容 4 个 agent 字段)
├── scripts/clear_pending.sh# 清除待发通知(用户交互时触发)
├── scripts/pre_tool_use.sh # 提问工具 dispatcher(request_user_input / ask / AskUserQuestion)
├── scripts/channels/*.sh   # 11 个渠道实现
├── hooks/hooks.json        # Claude Code hook 事件定义
├── hooks/codex-hooks.json  # Codex CLI hook 事件定义
├── reasonix-plugin.json    # Reasonix 原生插件清单(v2,payloadFormat=claude)
├── dsh-plugin/             # dsh 宿主插件(cordis,订阅 5 个拦截点)
├── .claude-plugin/         # Claude Code 插件清单
├── .codex-plugin/          # Codex CLI 插件清单
├── config/notify.example.json
└── skills/config/SKILL.md  # 交互式配置 skill(Claude Code 专属)
install.sh                  # 独立安装入口(路由)
install/{claude,codex,reasonix,dsh}.sh
test_notify.sh              # 渠道连通性 + 模板/agent 识别测试

常用命令

# 安装
bash install.sh                  # 交互式选择 Claude Code / Codex / Reasonix / dsh
bash install.sh claude|codex|reasonix|dsh

# 测试
bash test_notify.sh              # 测试所有已启用渠道
bash test_notify.sh bark         # 测试单个渠道
bash test_notify.sh hook         # 模拟 Claude Code hook 流程
bash test_notify.sh codex        # 模拟 Codex CLI PermissionRequest 事件
bash test_notify.sh agents       # 验证 Reasonix / dsh agent 识别
node plugins/cc-notify-hooks/dsh-plugin/test/plugin.test.mjs  # dsh 插件单元测试

# 插件模式运行
claude --plugin-dir ./cc-notify-hooks
reasonix plugin install ./plugins/cc-notify-hooks --link --yes

核心机制

  • 分级延迟: 短通知(秒级:macOS/Bark/Telegram)→ 长通知(分钟级:微信/飞书/钉钉/Slack)
  • Pending 取消: 发送前创建标记文件,用户响应时清除,后台进程检查标记决定是否发送
  • 速率限制: 同类事件默认 10 秒内不重复推送
  • 事件过滤: 跳过子 agent、Stop 循环保护、/exit 静默

配置

Read the full file on GitHub · 151 lines

Changes

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.

  1. 6d ago First seen · 151 lines · 2,573 tokens per session scan B be14a9c244f5

Subscribe to this mod's changes

cc-notify-hooks CLAUDE.md is an instructions file published in the GitHub repository MarioZZJ/cc-notify-hooks (19 stars, last pushed 18d ago), licensed MIT. It adds 2,573 tokens to every session, about $0.0129 per session on Opus 5. A static security scan graded it B with 2 findings (reads agent configuration directories, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories