$npx -y skills add aws-samples/sample-agent-skills-for-builders --skill aws-cost-operationsAWS cost optimization, monitoring, and operational excellence expert. Use when analyzing AWS bills, estimating costs, setting up CloudWatch alarms, querying logs, auditing CloudTrail activity, or assessing security posture. Essential when user mentions AWS costs, spending, billin
| 1 | # AWS Cost & Operations |
| 2 | |
| 3 | This skill provides comprehensive guidance for AWS cost optimization, monitoring, observability, and operational excellence with integrated MCP servers. |
| 4 | |
| 5 | ## AWS Documentation Requirement |
| 6 | |
| 7 | Always verify AWS facts using MCP tools (`mcp__aws-mcp__*` or `mcp__*awsdocs*__*`) before answering. The `aws-mcp-setup` dependency is auto-loaded — if MCP tools are unavailable, guide the user through that skill's setup flow. |
| 8 | |
| 9 | ## Integrated MCP Servers |
| 10 | |
| 11 | This plugin provides 3 MCP servers: |
| 12 | |
| 13 | ### Bundled Servers |
| 14 | |
| 15 | #### 1. AWS Pricing MCP Server (`pricing`) |
| 16 | **Purpose**: Pre-deployment cost estimation and optimization |
| 17 | - Estimate costs before deploying resources |
| 18 | - Compare pricing across regions |
| 19 | - Calculate Total Cost of Ownership (TCO) |
| 20 | - Evaluate different service options for cost efficiency |
| 21 | |
| 22 | #### 2. AWS Cost Explorer MCP Server (`costexp`) |
| 23 | **Purpose**: Detailed cost analysis and reporting |
| 24 | - Analyze historical spending patterns |
| 25 | - Identify cost anomalies and trends |
| 26 | - Forecast future costs |
| 27 | - Analyze cost by service, region, or tag |
| 28 | |
| 29 | #### 3. Amazon CloudWatch MCP Server (`cw`) |
| 30 | **Purpose**: Metrics, alarms, and logs analysis |
| 31 | - Query CloudWatch metrics and logs |
| 32 | - Create and manage CloudWatch alarms |
| 33 | - Troubleshoot operational issues |
| 34 | - Monitor resource utilization |
| 35 | |
| 36 | > **Note**: The following servers are available separately via the Full AWS MCP Server (see `aws-mcp-setup` skill) and are not bundled with this plugin: |
| 37 | > - AWS Billing and Cost Management MCP — Real-time billing details |
| 38 | > - CloudWatch Application Signals MCP — APM and SLOs |
| 39 | > - AWS Managed Prometheus MCP — PromQL queries for containers |
| 40 | > - AWS CloudTrail MCP — API activity audit |
| 41 | > - AWS Well-Architected Security Assessment MCP — Security posture assessment |
| 42 | |
| 43 | ## When to Use This Skill |
| 44 | |
| 45 | Use this skill when: |
| 46 | - Optimizing AWS costs and reducing spending |
| 47 | - Estimating costs before deployment |
| 48 | - Monitoring application and infrastructure performance |
| 49 | - Setting up observability and alerting |
| 50 | - Analyzing spending patterns and trends |
| 51 | - Investigating operational issues |
| 52 | - Auditing AWS activity and changes |
| 53 | - Assessing security posture |
| 54 | - Implementing operational excellence |
| 55 | |
| 56 | ## Cost Optimization Best Practices |
| 57 | |
| 58 | ### Pre-Deployment Cost Estimation |
| 59 | |
| 60 | **Always estimate costs before deploying**: |
| 61 | 1. Use **AWS Pricing MCP** to estimate resource costs |
| 62 | 2. Compare pricing across different regions |
| 63 | 3. Evaluate alternative service options |
| 64 | 4. Calculate expected monthly costs |
| 65 | 5. Plan for scaling and growth |
| 66 | |
| 67 | **Example workflow**: |
| 68 | ``` |
| 69 | "Estimate the monthly cost of running a Lambda function with |
| 70 | 1 million invocations, 512MB memory, 3-second duration in us-east-1" |
| 71 | ``` |
| 72 | |
| 73 | ### Cost Analysis and Optimization |
| 74 | |
| 75 | **Regular cost reviews**: |
| 76 | 1. Use **Cost Explorer MCP** to analyze spending trends |
| 77 | 2. Identify cost anomalies and unexpected charges |
| 78 | 3. Review costs by service, region, and environment |
| 79 | 4. Compare actual vs. budgeted costs |
| 80 | 5. Generate cost optimization recommendations |
| 81 | |
| 82 | **Cost optimization strategies**: |
| 83 | - Right-size over-provisioned resources |
| 84 | - Use appropriate storage classes (S3, EBS) |
| 85 | - Implement auto-scaling for dynamic workloads |
| 86 | - Leverage Savings Plans and Reserved Instances |
| 87 | - Delete unused resources and snapshots |
| 88 | - Use cost allocation tags effectively |
| 89 | |
| 90 | ### Budget Monitoring |
| 91 | |
| 92 | **Track spending against budgets**: |
| 93 | 1. Use **Billing and Cost Management MCP** to monitor budgets |
| 94 | 2. Set up budget alerts for threshold breaches |
| 95 | 3. Review budget utilization regularly |
| 96 | 4. Adjust budgets based on trends |
| 97 | 5. Implement cost controls and governance |
| 98 | |
| 99 | ## Monitoring and Observability Best Practices |
| 100 | |
| 101 | ### CloudWatch Metrics and Alarms |
| 102 | |
| 103 | **Implement comprehensive monitoring**: |
| 104 | 1. Use **CloudWatch MCP** to query metrics and logs |
| 105 | 2. Set up alarms for critical metrics: |
| 106 | - CPU and memory utilization |
| 107 | - Error rates and latency |
| 108 | - Queue depths and processing times |
| 109 | - API gateway throttling |
| 110 | - Lambda errors and timeouts |
| 111 | 3. Create CloudWatch dashboards for visualization |
| 112 | 4. Use log insights for troubleshooting |
| 113 | |
| 114 | **Example alarm scenarios**: |
| 115 | - Lambda error rate > 1% |
| 116 | - EC2 CPU utilization > 80% |
| 117 | - |