@tokenzero/mcp 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,21 @@
1
+ # @tokenzero/mcp
2
+
3
+ A stdio [MCP](https://modelcontextprotocol.io) server from [TokenZero](https://tokenzero.sh) that lets coding agents find and fix LLM cost waste.
4
+
5
+ ```sh
6
+ claude mcp add tokenzero -- npx -y @tokenzero/mcp # Claude Code
7
+ ```
8
+
9
+ ```json
10
+ { "mcpServers": { "tokenzero": { "command": "npx", "args": ["-y", "@tokenzero/mcp"] } } }
11
+ ```
12
+
13
+ | Tool | Runs | What it does |
14
+ |---|---|---|
15
+ | `audit_repo_token_waste` | locally | Static audit of a local directory (default: the working directory), a public GitHub repo, or a diff. Nothing from a local directory is uploaded. |
16
+ | `calculate_model_arbitrage` | locally | Prices a workload across models at list prices, with and without prompt caching. |
17
+ | `optimize_prompt_payload` | TokenZero service | Rewrites a request body so its static prefix is cacheable. Sends the body you pass to the service at `TOKENZERO_URL`; do not include secrets. |
18
+
19
+ Optional environment: `TOKENZERO_URL` (needed only for `optimize_prompt_payload`), `GITHUB_TOKEN` (raises GitHub rate limits for repo audits).
20
+
21
+ Audits are static heuristics: estimates at list prices, not measurements. Node >= 18. Single file, no dependencies. Apache-2.0.
@@ -528,7 +528,7 @@ function manifests(root) {
528
528
  }
529
529
 
530
530
  // mcp/src/main.ts
531
- var VERSION = "0.1.0";
531
+ var VERSION = "0.1.1";
532
532
  var BAKED_URL = typeof __TOKENZERO_BAKED__ === "string" ? __TOKENZERO_BAKED__ : "__TOKENZERO_DEFAULT_URL__";
533
533
  var SUPPORTED = ["2025-11-25", "2025-06-18", "2025-03-26"];
534
534
  var serviceUrl = () => (process.env.TOKENZERO_URL || (BAKED_URL.startsWith("http") ? BAKED_URL : "")).replace(/\/+$/, "");
package/package.json CHANGED
@@ -1,13 +1,30 @@
1
1
  {
2
2
  "name": "@tokenzero/mcp",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "TokenZero MCP server (stdio): audit LLM token waste in your project locally, price model alternatives, and make prompts cache-friendly from Claude Code, Cursor, Windsurf or Cline.",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
7
7
  "author": "TokenZero Contributors <support@tokenzero.sh>",
8
8
  "homepage": "https://tokenzero.sh",
9
- "bin": { "tokenzero-mcp": "bin/tokenzero-mcp.mjs" },
10
- "files": ["bin/tokenzero-mcp.mjs"],
11
- "engines": { "node": ">=18" },
12
- "keywords": ["mcp", "model-context-protocol", "llm", "cost", "finops", "prompt-caching", "claude-code", "cursor"]
9
+ "bin": {
10
+ "tokenzero-mcp": "bin/tokenzero-mcp.mjs"
11
+ },
12
+ "files": [
13
+ "bin/tokenzero-mcp.mjs",
14
+ "README.md",
15
+ "LICENSE"
16
+ ],
17
+ "engines": {
18
+ "node": ">=18"
19
+ },
20
+ "keywords": [
21
+ "mcp",
22
+ "model-context-protocol",
23
+ "llm",
24
+ "cost",
25
+ "finops",
26
+ "prompt-caching",
27
+ "claude-code",
28
+ "cursor"
29
+ ]
13
30
  }