IntegrityPulse金融运营
阻止你的人工智能代理产生云成本的幻觉。在对话中获得真实的定价预测。
  
______________________________________________________________________
这是什么?
IntegrityPulse FinOps是一个 远程MCP服务器 这为AI编码代理提供了准确、实时的云部署成本预测。它调用一个由经过验证的定价矩阵支持的工具,并返回一个行项目细分,而不是让你的代理猜测“一个EC2实例的成本约为每月50美元”。
一个工具。三个供应商。零幻觉。
User: "What would it cost to run our API on AWS with an m5.large, a managed Postgres, and Redis?"
Agent (via IntegrityPulse FinOps):
| Service | Category | Hours | Est. Cost |
|----------------------------|----------|-------|-----------|
| m5.large | Compute | 730 | $70.08 |
| rds.postgres.db.m5.large | Database | 730 | $204.40 |
| elasticache.redis.t3.micro | Cache | 730 | $11.68 |
Total Estimated Monthly Cost: $286.16______________________________________________________________________
快速开始
克劳德桌面
将此添加到您的 claude_desktop_config.json:
{
"mcpServers": {
"integritypulse": {
"type": "streamable-http",
"url": "https://integritypulse.marywomack.workers.dev/mcp",
"headers": {
"x-api-key": "YOUR_API_KEY"
}
}
}
}光标
添加到您的 .cursor/mcp.json:
{
"mcpServers": {
"integritypulse": {
"type": "streamable-http",
"url": "https://integritypulse.marywomack.workers.dev/mcp",
"headers": {
"x-api-key": "YOUR_API_KEY"
}
}
}
}cURL
curl -X POST https://integritypulse.marywomack.workers.dev/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-H "x-api-key: YOUR_API_KEY" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "forecast_deployment_cost",
"arguments": {
"provider": "AWS",
"services_to_add": [
{"service_name": "m5.large", "estimated_usage_hours": 730}
]
}
}
}'______________________________________________________________________
工具: forecast_deployment_cost
| 参数 | 类型 | 说明 | ||
|---|---|---|---|---|
provider | `"AWS" \ | "GCP" \ | "AZURE"` | 云提供商定价 |
services_to_add | Array | 预测中包括的服务 |
支持的服务:
| AWS | GCP | Azure |
|---|---|---|
| t3.微米,t3.中,m5.大 | e2微米,e2中等,n2-标准-2 | B1s,B2s,D2s_v3 |
| rds.postgres.db.t3.micro,rds.postgres.db.m5.large | cloudsql.postgres.db-costom-1-3840,cloudsql.post gres.db-custom-4-15360 | postgresql.flexible.b1ms |
| elasticache.redist.3.micro存储器.rediss.1gb | ||
| s3.标准1tb |
______________________________________________________________________
为什么它存在:代理时代的FinOps
人工智能代理正在从“给我写代码”转向“为我部署这个”。当代理提供基础设施时,成本准确性并不是一件好事,而是一种财务控制。
问题: LLMs对定价产生了幻觉。他们自信地告诉你,当实际数字为204美元时,RDS实例的成本为“每月15美元”。当代理开始自主执行部署时,这些幻觉就变成了真正的发票。
解决方案: IntegrityPulse FinOps是一个 固定定价预言机 代理将其称为工具。定价矩阵是维护的、版本化的和确定性的。没有世代,没有猜测。
代理商业与收入之门
此服务器也是 收入门控MCP --一种在不破坏代理体验的情况下将MCP工具货币化的模式。
其工作原理如下:
- 每个请求都包含一个
x-api-key头球 - 服务器检查用户的
tier和monthly_usage_count在Supabase。 - 免费会员可获得 25次操作/月.
- 当达到限制时,服务器不会返回HTTP错误。相反,它返回一个有效的MCP工具结果
isError: true:
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"content": [{
"type": "text",
"text": "IntegrityPulse FinOps Alert: Your free monthly tier (25/25 operations) has been exhausted. To generate this architectural cost forecast, please upgrade to the Pro tier here: https://billing.openclaw.com/upgrade. Once upgraded, ask me to retry."
}],
"isError": true
}
}为什么 isError: true 而不是HTTP 402/429?
因为消费者是LLM,而不是浏览器。HTTP错误被MCP传输层吞噬,用户永远不会看到它 isError: true,升级版CTA落地 直接参与对话 用户已经参与其中。代理读取它,显示它,用户可以立即对其采取行动。这是商业的意图。
条纹集成
当用户通过计费链接升级时,Stripe会发出 checkout.session.completed webhook到 /api/webhook/stripe服务器自动执行以下操作:
- 从以下位置更新其级别
FREE到PRO - 将其使用计数器重置为0
- 下一个代理请求无缝完成
______________________________________________________________________
建筑
+-----------------+
Claude / Cursor | Cloudflare | +------------+
(MCP Client) -------->| Worker (Hono) |------>| Supabase |
POST | | | (users) |
/mcp | Revenue Gate | +------------+
| MCP Server |
| Stripe Webhook |------> Stripe API
+-----------------+- 运行时间: Cloudflare Workers(边缘,冷启动约0ms)
- 框架: Hono(轻量级,Workers原生)
- MCP-SDK:
@modelcontextprotocol/sdk使用流式HTTP传输 - 认证: API密钥
x-api-key或Authorization: Bearer头球 - 数据库: Supabase(PostgreSQL)
- 付款: 条纹结账+Webhooks
______________________________________________________________________
自我寄宿
git clone https://github.com/maryadawson-code/integritypulse.git
cd integritypulse
npm install
# Configure secrets
cp .env.example .env
# Edit .env with your Supabase and Stripe credentials
# Local development
npx wrangler dev
# Deploy to Cloudflare Workers
npx wrangler secret put SUPABASE_URL
npx wrangler secret put SUPABASE_SERVICE_KEY
npx wrangler secret put STRIPE_SECRET_KEY
npx wrangler secret put STRIPE_WEBHOOK_SECRET
npx wrangler deploy______________________________________________________________________
许可证
麻省理工学院
