aws-billing-mcp
aws-billing-mcp
MCP server(stdio)——通过本机 AWS CLI 访问 <目标AWS 账号> 的Billing and Cost Management 数据,供 Quick Desktop 等 MCP 客户端做消费用量分析。
前置条件
Node.js ≥ 18(本机已装 v24)
AWS CLI v2,且 default profile(或
AWS_PROFILE指定的 profile)的凭证属于<目标AWS 账号>IAM 权限:
ce:Get*、budgets:ViewBudget、sts:GetCallerIdentity
服务器在第一次调用工具时会用 sts get-caller-identity 校验当前凭证确实属于<目标AWS 账号>,不匹配时直接报错,防止误查其他账号。
Related MCP server: aws-cost-mcp
安装
cd ~/aws-billing-mcp
npm install冒烟测试
node test-client.mjs会列出全部工具、查询本月按服务分组的成本 Top5,并做一次月末成本预测。
接入 Quick Desktop
在 Quick Desktop 的 MCP 服务器配置(Settings → 集成/MCP servers,或其 JSON 配置文件)中添加:
{
"mcpServers": {
"aws-billing": {
"command": "node",
"args": ["~/aws-billing-mcp/index.mjs"],
"env": {
"AWS_PROFILE": "default"
}
}
}
}注意:node 通过 nvm 安装(
~/.nvm/versions/node/v24.8.0/bin/node)。如果 Quick Desktop 启动时找不到node或aws,把command换成 node 的绝对路径,并在env里加"PATH": "/usr/local/bin:/usr/bin:/bin:/opt/homebrew/bin"(包含 aws 所在目录)。
工具列表
工具 | 用途 |
| 核心查询:任意时间段的成本/用量,支持按 SERVICE、USAGE_TYPE、REGION、TAG 等分组(最多 2 个),支持 Cost Explorer filter 表达式,自动翻页 |
| 枚举某维度实际产生费用的取值(服务名、区域等),用于确定精确的过滤值 |
| 未来时间段的成本预测(含 80% 置信区间) |
| Cost Anomaly Detection 检测到的成本异常及根因 |
| 账号下的 Budgets 及实际/预测执行情况 |
| 计费数据中的成本分配标签 key/value,配合 TAG 分组使用 |
| Savings Plans / RI 的 utilization 与 coverage |
典型分析提问(在 Quick Desktop 中)
“这个账号本月花了多少钱?按服务排一下 Top 10。”
“最近 30 天每天的 Bedrock 消费趋势,有没有异常尖峰?”
“预测一下 8 月底的总账单。”
“EC2 的费用按 usage type 拆开看,哪部分涨得最快?”
环境变量
变量 | 默认值 | 说明 |
|
| 允许访问的 AWS 账号,凭证不匹配即拒绝 |
| (系统默认) | 使用的 AWS CLI profile |
|
| AWS CLI 可执行文件路径 |
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAWS Cost Explorer + Anomaly Detection exposed as MCP tools. Surface unusual spend by service/account/tag, pull cost breakdowns, forecasts, savings recommendations. Read-only IAM — refuses to start if the role can modify resources. Curated by Archimedes Market with a verified Trust Report.MIT
- AlicenseNot gradedqualityDmaintenanceEnables querying AWS Cost and Usage Report data via Amazon Athena for cost-effective and detailed cost analysis.1MIT
- AlicenseNot gradedqualityDmaintenanceEnables management and analysis of AWS security groups, S3 buckets, and VPC connections via MCP.7MIT
- AlicenseNot gradedqualityCmaintenanceEnables analysis of AWS costs and usage through the AWS Cost Explorer API, supporting multi-account architectures with role assumption and cost comparison, forecasting, and anomaly detection.Apache 2.0
Related MCP Connectors
Remote MCP for Copilot CLI switch gate MCP, structured receipts, audit logs, and reviewer-ready evid
A paid remote MCP for AI SDK data query MCP, built to return verdicts, receipts, usage logs, and aud
Remote MCP for MCP tool deprecation receipt, structured receipts, audit logs, and reviewer-ready evi
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/symeta/aws-billing-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server