Borrowing it
Nothing to install: this file belongs to sputnicyoji/dingtalk-workspace. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/sputnicyoji/dingtalk-workspace/main/CLAUDE.mdgit clone --depth 1 https://github.com/sputnicyoji/dingtalk-workspaceWrote 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/instructions/sputnicyoji/dingtalk-workspace/claude-md)<a href="https://agentmods.dev/instructions/sputnicyoji/dingtalk-workspace/claude-md"><img src="https://agentmods.dev/badge/instructions/sputnicyoji/dingtalk-workspace/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/sputnicyoji/dingtalk-workspace/claude-md"><img src="https://agentmods.dev/badge/instructions/sputnicyoji/dingtalk-workspace/claude-md.svg" alt="Reviewed on agentmods" width="80" 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.01575 | $0.01575 |
| Opus 5 | $0.00788 | $0.00788 |
| Sonnet 5 | $0.00315 | $0.00315 |
| Haiku 4.5 | $0.00158 | $0.00158 |
Grade A, and why
dingtalk-workspace CLAUDE.md scanned grade A with 1 finding 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 10d 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.
Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
- 不引入 `execa`/`cross-spawn`,用 Node 原生 `child_process` How it starts
The opening of the file, as written. The whole thing — 129 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md — dingtalk-workspace-mcp 项目指令
本文件是项目级 agent 指令。优先级高于 ~/.claude/CLAUDE.md,但不覆盖用户显式请求。
这是什么项目
核心目标:交付一个 dws-driven 动态全覆盖的钉钉 MCP server。和现存 5+ 个 DingTalk MCP(手写固定 tool 子集)形成差异化——dws 升级新增能力时,本项目不改一行代码即自动暴露。
适用对象:任何 MCP host(Claude Desktop / Cursor / Codex / 其他)。host-agnostic 是不可妥协的红线。
仓库历史:早期试过"通用 MCP + 单一 host 专属扩展"双轨设计,扩展代码已归档至 legacy/(封档点 git tag milestone-v0.2)。npm 包名 @sputnicyoji/dingtalk-workspace-mcp 是项目本体。
不是:
- 不是 DingTalk 官方 SDK 再造
- 不是把 dws 用 Rust/Go/Python 重写一遍
- 不是通用 IM 接入框架(不考虑飞书/Slack/Teams)
- 不是任何 host 的专用集成方案(早期方向,已废弃,相关代码归档在
legacy/)
上游依赖:
- dws CLI(Go,用户本机自装)
- 钉钉官方走 "CLI + MCP 广场" 路径,不会自己出官方 MCP(这是本项目长期价值的护城河)
目录约定
dingtalk-workspace/
├── CLAUDE.md # 本文件
├── docs/
│ ├── ARCHITECTURE.md # 架构 + 设计决策
│ ├── ROADMAP.md # 版本节奏
│ ├── COMPARISON.md # vs 其他 DingTalk MCP 对比
│ └── decisions/ # ADR
├── packages/
│ └── dingtalk-workspace-mcp/ # 唯一活跃 package
│ ├── src/
│ ├── dist/ # tsc 输出,不进 git
│ ├── package.json
│ └── README.md
├── legacy/ # 已归档代码与文档(不再迭代)
│ ├── hermes-extensions/ # 早期 host 专属扩展(v0.2 milestone 封档)
│ └── docs/ # 配套调研文档
├── ref-git/ # 参考仓库(dws 等),.gitignore 排除
└── LICENSE
禁止:
- 在
packages/dingtalk-workspace-mcp/中写任何业务逻辑(身份解析、报告模板、告警规则) - 主包反向依赖
legacy/ - 给
legacy/加新代码或新模块(只接受 bug 修复) - 任何形式的 host 假设(代码路径里出现 host 名字就是 red flag)
技术栈约束
| 模块 | 语言/运行时 | 理由 |
|---|---|---|
| dingtalk-workspace-mcp | TypeScript + Node.js ≥20 | 对齐 npx -y 发行约定,MCP SDK 最成熟 |
| legacy/ | Python(冻结) | 历史选型,保留原状不动 |
不用:
- Rust(性能优势用不上,发行方式和
npx生态冲突) - Go(除非 schema 解析硬瓶颈才考虑重写)
编码风格
TypeScript(主包)
strict: true,不开any逃生舱- 不写 class,纯函数 + 闭包状态
- 不引入
execa/cross-spawn,用 Node 原生child_process - 错误用
Result<T, E>风格({ ok: true, value } | { ok: false, error }),不滥用 throw - 所有和 dws 的交互走
src/dispatch.ts唯一入口
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.
- 10d ago First seen · 129 lines · 1,575 tokens per session scan A ff78c9add83b
dingtalk-workspace CLAUDE.md is an instructions file published in the GitHub repository sputnicyoji/dingtalk-workspace (4 stars, last pushed 4mo ago), licensed MIT. It adds 1,575 tokens to every session, about $0.0079 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.