-
-
Notifications
You must be signed in to change notification settings - Fork 23
Open
Labels
enhancementNew feature or requestNew feature or requestmoatUnique differentiating featureUnique differentiating featurepriority:mediumMedium priority itemMedium priority item
Description
Parent Epic
Description
Break down costs by MCP (Model Context Protocol) server, showing which integrations are costing the most.
The Vision
We're the only tool that monitors MCP servers. Let's also attribute costs to them:
MCP Server │ Calls │ Tokens │ Cost │ Share
────────────────┼───────┼─────────┼────────┼──────
filesystem │ 234 │ 456K │ $5.67 │ 45%
github │ 123 │ 234K │ $3.45 │ 28%
sqlite │ 89 │ 167K │ $2.34 │ 19%
context7 │ 45 │ 78K │ $1.00 │ 8%
How It Works
- Parse MCP tool calls from JSONL files
- Associate token usage with MCP server
- Calculate proportional cost
JSONL Entry Example
{
"type": "assistant",
"timestamp": "2026-01-22T15:30:00Z",
"message": {
"content": [
{
"type": "tool_use",
"name": "mcp__filesystem__read_file",
"input": {"path": "/etc/hosts"}
}
],
"usage": {
"input_tokens": 1234,
"output_tokens": 567
}
}
}Command
./statusline.sh --mcp-costs
╭──────────────────────────────────────────────────────────────╮
│ MCP Cost Attribution │
│ This Session │
╰──────────────────────────────────────────────────────────────╯
MCP Server │ Calls │ Avg Tokens │ Total Cost │ Share
────────────────┼───────┼────────────┼────────────┼──────
filesystem │ 234 │ 1,950 │ $5.67 │ 45%
github │ 123 │ 1,902 │ $3.45 │ 28%
sqlite │ 89 │ 1,876 │ $2.34 │ 19%
context7 │ 45 │ 1,733 │ $1.00 │ 8%
────────────────┴───────┴────────────┴────────────┴──────
TOTAL │ 491 │ 1,865 │ $12.46 │ 100%
Most Expensive: filesystem (45% of costs)
Recommendation: Consider caching filesystem reads to reduce costsStatusline Integration
MCP: fs(234) gh(123) sql(89) c7(45) │ Top: filesystem $5.67
Why This Matters
- Unique to our tool (we have MCP monitoring)
- Helps optimize MCP usage
- Identifies expensive integrations
- No competitor tracks this
Acceptance Criteria
- Parse MCP calls from JSONL
- Attribute costs to MCP servers
- MCP costs report command
- Integration with statusline
- Optimization recommendations
- Tests added
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestmoatUnique differentiating featureUnique differentiating featurepriority:mediumMedium priority itemMedium priority item