AWS_CloudGuardMCP
An intelligent AWS monitoring and incident response solution using Anthropic's Model Context Protocol (MCP). Enables users to monitor AWS resources, analyze CloudWatch logs and metrics, and automatically create Jira tickets with remediation steps.
README
AWS Incident Response with MCP Servers
🚨 WHAT'S NEW 🚨
CROSS-ACCOUNT MONITORING NOW AVAILABLE!
New Feature Alert: You can now monitor and create Jira tickets for resources across multiple AWS accounts! Simply provide your account ID and role name with cross-account access permissions once prompted by the host LLM, and the monitoring MCP server will assume that role to fetch data from other accounts.
How it works:
- Specify that you want to use cross-account access
- Provide the target AWS account ID (12-digit number)
- Provide the IAM role name with necessary permissions
- The system automatically handles role assumption and data retrieval
This enhancement allows centralized monitoring and incident management across your AWS organization! Build centralized dashboards, custom analysis and more, all through Natural Language.
An intelligent AWS monitoring and incident response solution using Anthropic's Model Context Protocol (MCP). This solution empowers users to monitors AWS resources, analyzes CloudWatch logs and metrics for various services (Amazon Bedrock, EC2, IAM, CloudTrail, VPC, RDS, etc), identifies trends, patterns and issues, and creates comprehensive Jira tickets with remediation steps. This eliminates hours of manual analysis and sifting through dashboards and log chunks by interacting with your MCP system in real time in natural language.
YouTube demo: https://www.youtube.com/watch?v=BNoEMFc2Rv4

What is Model Context Protocol (MCP)?
MCP provides a standardized way to connect AI models to virtually any data source or tool. Using a client-server architecture, MCP enables developers to expose their data through lightweight MCP servers while building AI applications as MCP clients that connect to these servers. Through this architecture, MCP enables users to build more powerful, context-aware AI agents that can seamlessly access the information and tools they need.
Overview
This tool provides an intelligent interface to AWS CloudWatch logs, metrics, and alarms using Anthropic's Claude model. It functions as a multi-MCP server solution that can:
-
Monitor AWS Services: Analyze CloudWatch logs and metrics for various AWS services
-
Detect Issues: Identify patterns, errors, and anomalies in your AWS environment
-
Create Jira Tickets: Automatically generate well-structured Jira tickets with detailed information
-
Recommend Solutions: Include remediation steps in tickets based on AWS best practices
Features
-
Multi-Server Architecture: Separate MCP servers for monitoring and ticketing
-
Natural Language Interface: Interact with your AWS environment using plain English
-
Comprehensive AWS Service Coverage: Monitor EC2, Lambda, RDS, Bedrock, S3, and more
-
Intelligent Analysis: Detect patterns and anomalies in logs and metrics
-
Automatic Jira Integration: Create detailed tickets with proper formatting
-
Solution Recommendations: Tickets include AWS-recommended remediation steps
Requirements
- Python 3.12
- AWS credentials with CloudWatch access
- Jira account with API access
- Anthropic API access (for Claude integration)
- Claude Desktop (optional)
## Solution structure
MCP_AWS_Incident_Response/
├── README.md
├── client.py
├── globals.py
├── main.py
├── pyproject.toml
├── server_scripts/
│ ├── monitoring_agent_server.py
│ └── diagnosis_agent_server.py
└── uv.lock
Installation
-
Install uv (Python package manager):
# On macOS and Linux curl -LsSf https://astral.sh/uv/install.sh | sh # On Windows powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex" -
Clone this repository:
git clone https://github.com/madhurprash/AWS_CloudGuardMCP.git cd AWS_CloudGuardMCP -
Set up the Python virtual environment and install dependencies:
uv venv --python 3.12 source .venv/bin/activate # On Windows: .venv\Scripts\activate uv pip install --requirement pyproject.toml -
Configure your AWS credentials if not done already:
mkdir -p ~/.aws # Set up your credentials in ~/.aws/credentials and ~/.aws/config
Usage
- Export the environment variables:
export JIRA_API_TOKEN="<your-jira-api-token" && export JIRA_USERNAME="<your-jira-username>" && export JIRA_INSTANCE_URL="<your-jira-instance-url>" && export JIRA_CLOUD="True" && export PROJECT_KEY="<jira-project-key>" && echo "Jira environment variables exported successfully"
-
Running with the Client: The simplest way to use the solution is through the provided client:
# this is the MCP client, connects to the servers, lists the available tools # and allows a ReACT agent to be run and interact with the server tools based # on the user query uv run client.py --model-id=<bedrock-model>
- This will start an interactive chat interface where you can:
- Ask about AWS logs and metrics
- Request analysis of specific services
- Create Jira tickets for identified issues
Configuration with Claude Desktop
You can also use this solution directly with Claude Desktop by adding the following to your Claude Desktop configuration file:
{
"mcpServers": {
"aws_monitoring": {
"command": "/path/to/your/venv/bin/python3 [this is in your virutal environment built from the `uv` commands above]",
"args": [
"/path/to/your/repo/server_scripts/monitoring_agent_server.py"
],
"env": {
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_ID",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY",
"AWS_REGION": "<your-aws-region>",
"BEDROCK_LOG_GROUP": "<your-bedrock-log-group> [optional]",
"MCP_TRANSPORT": "stdio"
}
},
"jira_server": {
"command": "/path/to/your/venv/bin/python3 [this is in your virutal environment built from the `uv` commands above]",
"args": [
"/path/to/your/repo/server_scripts/diagnosis_agent_server.py"
],
"env": {
"JIRA_API_TOKEN": "YOUR_JIRA_API_TOKEN",
"JIRA_USERNAME": "your.username@example.com",
"JIRA_INSTANCE_URL": "https://your-instance.atlassian.net",
"JIRA_CLOUD": "True",
"PROJECT_KEY": "YOUR_PROJECT_KEY",
"MCP_TRANSPORT": "stdio"
}
}
}
}
The configuration file path depends on your operating system:
macOS:~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:%APPDATA%\Claude\claude_desktop_config.jsonLinux:~/.config/Claude/claude_desktop_config.json
Available Tools
Monitoring Server Tools
| Tool | Description |
|---|---|
list_cloudwatch_dashboards() |
Lists all CloudWatch dashboards in your AWS account |
fetch_cloudwatch_logs_for_service(service_name, days, filter_pattern) |
Retrieves CloudWatch logs for a specified service |
get_cloudwatch_alarms_for_service(service_name) |
Fetches CloudWatch alarms for a specific service |
get_dashboard_summary(dashboard_name) |
Retrieves and summarizes the configuration of a dashboard |
list_log_groups(prefix) |
Lists all CloudWatch log groups, optionally filtered by prefix |
analyze_log_group(log_group_name, days, max_events, filter_pattern) |
Analyzes a specific CloudWatch log group for insights |
Jira Server Tools
| Tool | Description |
|---|---|
create_jira_issue(summary, description) |
Creates a new issue in Jira with the specified details |
Supported AWS Services
This solution supports monitoring and analysis of the following AWS services:
- EC2/Compute Instances [ec2]
- Lambda Functions [lambda]
- RDS Databases [rds]
- CloudTrail [cloudtrail]
- S3 Storage [s3]
- VPC Networking [vpc]
- WAF Web Security [waf]
- Bedrock [bedrock/generative AI]
- IAM Logs [iam]
Example Queries
Once connected through the client or Claude Desktop, you can ask questions like:
- "Show me the CloudWatch logs for EC2 in the last 24 hours"
- "Are there any errors in the Lambda logs?"
- "List all active CloudWatch alarms"
- "Create a Jira ticket for the EC2 memory utilization issue"
- "What remediation steps does AWS recommend for RDS performance issues?"
Workflow
-
Monitoring Phase:
- Request logs and metrics for specific AWS services
- Analyze data for patterns, errors, and anomalies
- Identify potential issues requiring attention
-
Diagnosis Phase:
- Investigate identified issues in depth
- Determine root causes and impact
- Search for AWS-recommended remediation steps
-
Ticketing Phase:
- Create detailed Jira tickets with all necessary information
- Include evidence, impact assessment, and remediation steps
- Track issues through to resolution
Security Considerations
- Store your AWS credentials and Jira API tokens securely
- Never commit credentials to version control
- Use IAM roles with minimum required permissions
- Consider using AWS Secrets Manager for credential management
Development
To extend the functionality:
- Add new monitoring tools to
monitoring_agent_server.py - Add new diagnostic tools to
diagnosis_agent_server.py - Update the client to utilize new features
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。