A sample MCP server for understanding cloud spend
@aws-samples
关于 A sample MCP server for understanding cloud spend
MCP for AWS Cost Explorer and CloudWatch logs
基本信息
配置
工具
未检测到工具
工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。
概览
What is A sample MCP server for understanding cloud spend?
This MCP server provides AWS cost data via Cost Explorer and Amazon Bedrock usage data from CloudWatch model invocation logs, enabling natural language queries through Claude. It is intended for users who want to analyze and visualize their AWS cloud spending interactively.
How to use A sample MCP server for understanding cloud spend?
Install Python 3.12 and uv, clone the repository, set up a virtual environment, and configure AWS credentials. Run server.py with MCP_TRANSPORT=stdio for local use, then add the configuration to Claude Desktop (either via Docker or UV). For remote deployment, set MCP_TRANSPORT=sse, run on EC2, and connect using a CLI client or a Chainlit LangGraph agent.
Key features of A sample MCP server for understanding cloud spend
- Amazon EC2 spend analysis for the last day
- Amazon Bedrock usage breakdown by region, users, and models
- Service spend reports across all AWS services for 30 days
- Detailed cost breakdown per day, region, service, and instance type
- Interactive natural‑language interface via Claude
Use cases of A sample MCP server for understanding cloud spend
- Ask “What was my EC2 spend yesterday?” and receive a structured answer
- Analyze Bedrock usage over the last few weeks by model and user
- Identify the top five AWS services by cost for the previous month
- Monitor spending patterns by region over the past 14 days
- Determine which EC2 instance types are driving the highest costs
FAQ from A sample MCP server for understanding cloud spend
What are the requirements to run this server?
Python 3.12, AWS credentials with Cost Explorer access, and Anthropic API access. Optionally, Amazon Bedrock access (for LangGraph Agent) and an EC2 instance for remote deployment.
How is data accessed and stored?
The server queries AWS Cost Explorer and CloudWatch Logs live via API calls. No data is stored locally; all information is fetched on demand.
Can I run the server remotely?
Yes. Set MCP_TRANSPORT=sse and run on EC2. Note that Claude Desktop does not support remote MCP servers; use a LangGraph agent or the provided CLI client instead.
How do I secure a remote MCP server?
Use nginx as a reverse proxy with HTTPS. Obtain an SSL certificate (e.g., from Let’s Encrypt) and configure nginx to proxy to the local MCP server on port 8000.
What tools does the server expose?
Four tools: get_ec2_spend_last_day, get_detailed_breakdown_by_day, get_bedrock_daily_usage_stats, and get_bedrock_hourly_usage_stats. Each returns spending or usage data in a readable format.
其他 分类下的更多 MCP 服务器
Awesome Mcp Servers
punkpeyeA collection of MCP servers.
Awesome Mlops
visengerA curated list of references for MLOps
ghidraMCP
LaurieWiredMCP Server for Ghidra
Inbox Zero AI MCP
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
AutoBrowser MCP
autobrowser-aiBrowser MCP is a Model Context Provider (MCP) server that allows AI applications to control your browser
评论