mcp-cloudwatch-explorer

mcp-cloudwatch-explorer

Enables AI agents to query AWS CloudWatch metrics, alarms, and logs read-only via MCP, providing rapid health snapshots and triage without console navigation.

Category
Visit Server

README

mcp-cloudwatch-explorer

MCP-native AWS CloudWatch explorer. Lets an AI agent (Claude, etc) query metrics, alarms, and logs over MCP — read-only by design — so you can ask "what's wrong with prod?" in a chat and get a useful answer instead of a 4-tab CloudWatch console session.

flowchart LR
    A[Claude / MCP client] -- tool call --> S[mcp-cloudwatch-explorer]
    S -- boto3 cloudwatch / logs --> CW[CloudWatch metrics<br/>alarms · logs]
    CW --> S
    S -- ranked findings --> A

Tools exposed (implemented)

Tool Returns
list_alarms_in_alarm(region) All CloudWatch alarms currently in ALARM state
get_metric_stats(namespace, metric, dimensions, period_min, hours) Datapoints for a metric over the last N hours
recent_log_errors(log_group, hours) Recent ERROR / Exception lines from a log group
summarize_health(region) One-shot health snapshot: alarms in ALARM + count by namespace

Roadmap

  • top_metrics_by_breach(region, hours) — metrics that breached their threshold most in last N hours (needs CloudWatch metric history aggregation)

Why MCP

Standard CloudWatch usage:

  1. SSH or open Console.
  2. Click through dashboards.
  3. Filter by service.
  4. Try to remember the metric name.
  5. Eyeball the graph.

With MCP:

> Hey, looks like prod is slow. Anything alarming?

[claude calls list_alarms_in_alarm + summarize_health]

Yes — 2 alarms in ALARM right now in us-east-1:
- ALB-5xx-rate (api-prod) breached 3 times in last hour
- RDS-CPUUtilization (db-prod-1) at 87% sustained

Top recent log errors in /aws/lambda/api-prod:
- ConnectionPool exhausted (47x)
- DDB throttling on Users.GetItem (12x)

Probable root cause: connection pool saturation under high traffic
caused by the 5xx rate.

That's a 30-second triage instead of 5 minutes of console-clicking.

Quick start

pip install -e .

# AWS creds via your usual mechanism
export AWS_PROFILE=mycompany-readonly

python -m mcp_cloudwatch_explorer.server

For Claude Desktop, add to your MCP config:

{
  "mcpServers": {
    "cloudwatch-explorer": {
      "command": "python",
      "args": ["-m", "mcp_cloudwatch_explorer.server"],
      "env": {"AWS_PROFILE": "mycompany-readonly"}
    }
  }
}

Safety

  • Scoped IAM: needs only cloudwatch:Describe*, cloudwatch:Get*, logs:Describe*, logs:FilterLogEvents. Never write.
  • No mutation tools. By design.
  • Pagination + AWS API throttle handling on every describe_* call.

Related projects

The three together cover Postgres + AWS cost + AWS observability for one agent session — a single Claude conversation can audit your DB, your spend, and your alarms.

License

MIT

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured