MCP Server AWS
kernelpanic09/mcp-server-aws
Acesso seguro a AWS via Claude com leitura por padrão
Ver no GitHubServidor MCP que integra Claude e outros agentes de IA com recursos AWS (EC2, S3, IAM, CloudWatch, EKS, custos). Oferece consultas seguras apenas-leitura por padrão, com operações de escrita opcionais e controladas por token de confirmação.
Instalação
npx convez-ai kernelpanic09/mcp-server-aws1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.
Métricas
Casos de uso
- Consultar estado de instâncias EC2 e recursos AWS em linguagem natural
- Monitorar custos e métricas CloudWatch sem escrever código
- Auditar permissões IAM e políticas de segurança automaticamente
- Gerenciar EKS e buckets S3 através de conversas com Claude
Veredito

Ferramenta sólida e bem-mantida que democratiza acesso a AWS via IA. Implementação cuidadosa de segurança (leitura-primeiro, confirmação para escrita) torna-a confiável para ambientes produção. Excelente para times que querem consultas naturais em infraestrutura.
README
A tradução para o português deste README ainda está na fila.
mcp-server-aws
An MCP server that lets Claude and other AI clients query AWS resources over stdio.
Connect it to Claude Desktop or Claude Code and you can ask questions like "which EC2 instances are running in us-west-2?" or "what did I spend on RDS last month?" without writing any glue code. Everything is read-only by default. Write operations require an explicit flag at startup and a confirmation token for destructive actions.
Installation
pip install mcp-server-aws
Or with uv:
uv pip install mcp-server-aws
Quick start
Install with uv:
uv pip install mcp-server-aws
Or for local development:
git clone https://github.com/kernelpanic09/mcp-server-aws
cd mcp-server-aws
uv pip install -e ".[dev]"
Make sure AWS credentials are available (env vars, ~/.aws/credentials, or an
instance role). Then add the server to your AI client.
Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS)
or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"aws": {
"command": "mcp-server-aws",
"args": []
}
}
}
Claude Code
Create or merge into .claude/mcp.json in your project:
{
"mcpServers": {
"aws": {
"command": "mcp-server-aws",
"args": [],
"env": {
"AWS_PROFILE": "your-profile"
}
}
}
}
Options
mcp-server-aws [--allow-writes] [--region REGION] [--profile PROFILE] [--max-items N]
| Flag | Default | Notes |
|---|---|---|
--allow-writes | off | Enables tag, stop, and restart tools |
--region | us-east-1 | Default region for calls that don't specify one |
--profile | boto3 default | AWS credential profile |
--max-items | 100 | Max items per paginated list |
Available tools
EC2
| Tool | Description |
|---|---|
list_ec2_instances | List instances with optional filters |
describe_ec2_instance | Full details for one instance |
stop_ec2_instance | Stop an instance (write, confirmation required) |
get_stop_confirmation_token | Get the token needed to stop an instance |
S3
| Tool | Description |
|---|---|
list_s3_buckets | All buckets with region and creation date |
get_s3_bucket_policy | Bucket policy as parsed JSON |
IAM
| Tool | Description |
|---|---|
list_iam_users | Users with last-login timestamps |
list_iam_roles | All roles |
get_iam_role | Role details with trust policy and attached policies |
Observability
| Tool | Description |
|---|---|
get_cloudwatch_metric | Fetch metric datapoints |
query_cloudwatch_logs | Run a Logs Insights query |
Compute
| Tool | Description |
|---|---|
list_eks_clusters | EKS cluster names in a region |
describe_eks_cluster | Cluster version, endpoint, VPC config |
list_lambda_functions | Functions with runtime and memory |
list_rds_instances | RDS instances with engine and connection info |
Cost
| Tool | Description |
|---|---|
get_cost_and_usage | Cost Explorer query by date range and dimension |
Networking
| Tool | Description |
|---|---|
describe_security_group | Inbound and outbound rules for a security group |
CloudFormation
| Tool | Description |
|---|---|
list_cloudformation_stacks | Active stacks (excludes deleted) |
describe_cloudformation_stack | Stack with outputs and parameters |
Write tools (require --allow-writes)
| Tool | Description |
|---|---|
tag_resource | Add or update tags on any ARN-addressable resource |
restart_ecs_service | Force a new ECS service deployment |
get_ecs_restart_confirmation_token | Get the token needed to restart a service |
Resources
| URI | Description |
|---|---|
aws://account/identity | Account ID and caller identity |
aws://regions | All enabled regions |
aws://cost/current-month | Current month's spend by service |
Safety
The server is read-only by default. All write tools check the --allow-writes
flag at call time and return a structured error if it's not set. No credentials
are ever logged or returned in tool output.
Destructive operations (stopping instances, restarting services) require a confirmation token. The token encodes the operation and target, so you can't reuse a token across different resources.
Every tool call writes a structured JSON audit line to stderr:
{"ts": "2024-01-15T10:23:45+00:00", "tool": "list_ec2_instances", "params": {"region": "us-east-1"}, "result": "12 instances"}
See docs/safety.md for the IAM policy recommendation and full security model.
Example prompts
Once connected:
- "Find me all EC2 instances tagged env=prod that are stopped."
- "What's the most expensive AWS service this month?"
- "Show me IAM users who haven't logged in since January."
- "Are any RDS instances publicly accessible?"
- "Search /aws/lambda/my-function logs for errors in the last hour."
- "List all CloudFormation stacks in eu-west-1 that are in ROLLBACK state."
- "Describe the trust policy for the EKS node role. Does anything look off?"
- "What security groups allow inbound SSH from 0.0.0.0/0?"
IAM policy
Minimal read-only policy:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"ec2:DescribeInstances",
"ec2:DescribeRegions",
"ec2:DescribeSecurityGroups",
"s3:ListAllMyBuckets",
"s3:GetBucketLocation",
"s3:GetBucketPolicy",
"iam:ListUsers",
"iam:ListRoles",
"iam:GetRole",
"iam:ListAttachedRolePolicies",
"logs:StartQuery",
"logs:GetQueryResults",
"cloudwatch:GetMetricStatistics",
"eks:ListClusters",
"eks:DescribeCluster",
"lambda:ListFunctions",
"ce:GetCostAndUsage",
"cloudformation:ListStacks",
"cloudformation:DescribeStacks",
"rds:DescribeDBInstances",
"sts:GetCallerIdentity"
],
"Resource": "*"
}
]
}
Development
# Install dev dependencies
make install
# Run tests
make test
# Format and lint
make fmt
make lint
# Type check
make typecheck
# Run the server locally
make run
make run-with-writes
Tests use moto for AWS mocking - no real AWS account needed.
Roadmap
Features worth adding:
- Secrets Manager: read secret metadata (not values) and rotation status
- KMS: list keys, key policies, key rotation status
- Route 53: list hosted zones and records
- VPC: describe VPCs, subnets, route tables
- SSM Parameter Store: read parameters by path (non-SecureString only)
- ECS: list clusters, services, tasks
- ECR: list repositories and image tags
- Step Functions: list and describe state machines
- SNS/SQS: list topics/queues, queue depth
- Config: query AWS Config rules and compliance state
- Trusted Advisor: read advisor findings
- Multi-account: assume-role support for querying member accounts in an org
Related Projects
- agents-platform - an AI agent orchestration platform that can consume MCP servers like this one to give agents tool access to infrastructure without granting them broad shell permissions.
- terraform-aws-modules - includes an
iam-rolesmodule that can provision the read-only IAM role this server needs, with permission boundaries and the right trust policy already wired in. - k8s-ai-operator - exposes Bedrock models as cluster resources; complements this server's read-only AWS access for in-cluster agent workflows.
- bedrock-cli - a terminal client for Bedrock Knowledge Bases, Agents, and Guardrails when you want a CLI instead of an MCP transport.
License
MIT. See LICENSE.