Borrowing it
Nothing to install: this file belongs to knishioka/cost-management-mcp. 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/knishioka/cost-management-mcp/main/CLAUDE.mdgit clone --depth 1 https://github.com/knishioka/cost-management-mcpWrote 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/knishioka/cost-management-mcp/claude-md)<a href="https://agentmods.dev/instructions/knishioka/cost-management-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/knishioka/cost-management-mcp/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/knishioka/cost-management-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/knishioka/cost-management-mcp/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.02172 | $0.02172 |
| Opus 5 | $0.01086 | $0.01086 |
| Sonnet 5 | $0.00434 | $0.00434 |
| Haiku 4.5 | $0.00217 | $0.00217 |
Grade A, and why
cost-management-mcp CLAUDE.md 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 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.
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 — 366 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Claude Development Guidelines for Cost Management MCP
Project Overview
This is a Model Context Protocol (MCP) server that provides unified cost monitoring across multiple cloud and API providers (AWS, OpenAI). The server allows users to retrieve cost data, monitor usage, and track expenses across different services through a consistent interface.
Key Commands
Development
npm run dev- Start development server with hot reloadnpm run build- Build TypeScript to JavaScriptnpm run test- Run all testsnpm run lint- Check code stylenpm run typecheck- Check TypeScript types
Before Committing
Pre-commit hooks are configured to automatically run checks:
- ESLint - Automatically fixes code style issues
- Prettier - Formats code for consistency
The hooks run automatically on git commit. To run checks manually:
npm run lint
npm run typecheck
npm test
If you need to bypass hooks temporarily (not recommended):
git commit --no-verify -m "your message"
Architecture Overview
Provider Structure
Each provider (AWS, OpenAI) has:
client.ts- API client implementationtypes.ts- TypeScript type definitionstransformer.ts- Transforms provider data to unified format
Unified Data Model
interface UnifiedCostData {
provider: 'aws' | 'openai';
period: { start: Date; end: Date };
costs: {
total: number;
currency: string;
breakdown: Array<{
service: string;
amount: number;
usage?: { quantity: number; unit: string };
}>;
};
metadata: {
lastUpdated: Date;
source: 'api' | 'cache' | 'manual';
};
}
Implementation Guidelines
Error Handling
- Always use custom error classes from
src/common/errors.ts - Implement retry logic with exponential backoff for API calls
- Log errors appropriately without exposing sensitive data
- Provide meaningful error messages to users
Caching Strategy
- Cache all API responses to minimize costs (especially AWS at $0.01/request)
- Default TTL: 1 hour (configurable via CACHE_TTL env var)
- Implement cache invalidation on demand
- Use separate cache keys for each provider/query combination
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 · 366 lines · 2,172 tokens per session scan A 81fe31faa7d7
cost-management-mcp CLAUDE.md is an instructions file published in the GitHub repository knishioka/cost-management-mcp (0 stars, last pushed 10d ago), licensed MIT. It adds 2,172 tokens to every session, about $0.0109 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-09-01.
Other instructions, from other repositories
plan-forge naming.instructions.md
Azure naming conventions — Microsoft CAF abbreviations, constraints, uniqueness, tagging.
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.
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.