opensite-ai/opensite-skills / aws-billing-and-cost-management
aws-billing-and-cost-management
VerifiedAnalyze AWS costs, find savings, manage budgets, evaluate Savings Plans and Reserved Instances, right-size EC2/Lambda/RDS/EBS with Compute Optimizer, look up service pricing, query CUR with Athena, detect cost anomalies, scope costs to billing views, and monitor Free Tier usage. Triggers on: AWS bill, cost analysis, reduce spend, savings plan, reserved instance, right-size, budget alert, cost optimization, pricing, free tier, cost anomaly, CUR, cost audit, billing view, billing view ARN.
| File | Kind | Size |
|---|---|---|
| .aws-skill-metadata | other | 18 B |
| SKILL.md | skill md | 8.9 KB |
| references/budgets.md | markdown | 2.4 KB |
| references/cost-audit.md | markdown | 3.2 KB |
| references/cost-explorer.md | markdown | 7.3 KB |
| references/cost-optimization-hub.md | markdown | 7.2 KB |
| references/cur-athena.md | markdown | 7.0 KB |
| references/deterministic-calculations.md | markdown | 2.5 KB |
| references/ebs-optimization.md | markdown | 2.7 KB |
| references/ec2-rightsizing.md | markdown | 3.3 KB |
| references/free-tier.md | markdown | 1.6 KB |
| references/lambda-optimization.md | markdown | 2.2 KB |
| references/pricing-lookup.md | markdown | 3.8 KB |
| references/rds-optimization.md | markdown | 1.8 KB |
| references/reserved-instances.md | markdown | 2.3 KB |
| references/savings-plans.md | markdown | 3.3 KB |
| references/service-optimization.md | markdown | 3.0 KB |
references/cost-audit.md
View on GitHub# Cost Audit Workflow
> **Pricing note:** All prices shown are us-east-1 approximate as of early 2026. Prices vary by region and may change. Always verify current pricing via the Price List API before reporting to users.
Execute when a user asks to audit costs, reduce their bill, or find savings. Prioritize: immediate (delete unused) → short-term (right-size, configure) → long-term (commitments).
## Step 1: Top Cost Drivers
```bash
aws ce get-cost-and-usage \
--time-period Start=2026-03-01,End=2026-04-01 \
--granularity MONTHLY --metrics UnblendedCost \
--group-by Type=DIMENSION,Key=SERVICE
```
## Step 2: Month-over-Month Comparison
Run the same query for the previous month. Calculate percent change per service **using a script** (see `references/deterministic-calculations.md`). Flag services with >20% increase.
## Step 3: Optimization Recommendations (Start with COH)
Use Cost Optimization Hub to get all recommendations, prioritized by savings. COH consolidates and de-duplicates across Compute Optimizer, Cost Explorer rightsizing, SPs, RIs, and idle resources. See `references/cost-optimization-hub.md` for CLI commands and correct parameter syntax.
## Step 4: Find Idle/Unused Resources
```bash
# Unattached EBS volumes
aws ec2 describe-volumes --filters Name=status,Values=available \
--query "Volumes[].{ID:VolumeId,Size:Size,Type:VolumeType}" --output table
# Unattached Elastic IPs (~$3.65/month each — all public IPv4 addresses cost $0.005/hr whether in-use or idle)
aws ec2 describe-addresses \
--query "Addresses[?!InstanceId && !NetworkInterfaceId]"
```
## Step 5: Check Commitment Coverage
```bash
aws ce get-savings-plans-coverage \
--time-period Start=2026-03-01,End=2026-04-01 --granularity MONTHLY
aws ce get-savings-plans-utilization \
--time-period Start=2026-03-01,End=2026-04-01 --granularity MONTHLY
# Reserved Instance coverage & utilization
aws ce get-reservation-coverage \
--time-period Start=2026-03-01,End=2026-04-01 --granularity MONTHLY
aws ce get-reservation-utilization \
--time-period Start=2026-03-01,End=2026-04-01 --granularity MONTHLY
```
## Step 6: Per-Service Quick Wins
```bash
# Log groups without retention
aws logs describe-log-groups \
--query "logGroups[?!retentionInDays].{Name:logGroupName,StoredBytes:storedBytes}" --output table
# Lambda functions still on x86_64
aws lambda list-functions \
--query "Functions[?Architectures[0]=='x86_64'].{Name:FunctionName,Memory:MemorySize}" --output table
# Existing S3 gateway endpoints (cross-reference against all VPCs to find missing ones)
aws ec2 describe-vpc-endpoints --filters Name=service-name,Values=*s3* \
--query "VpcEndpoints[].{VPC:VpcId,Service:ServiceName}"
# Existing DynamoDB gateway endpoints
aws ec2 describe-vpc-endpoints --filters Name=service-name,Values=*dynamodb* \
--query "VpcEndpoints[].{VPC:VpcId,Service:ServiceName}"
```
## Step 7: Generate Report
Structure findings as: Top Cost Drivers (table) → Immediate Savings (delete unused) → Short-Term (right-size, configure) → Long-Term (commitments) → Estimated Total Monthly Savings.
Label all figures as ACTUAL DATA (from API) or ESTIMATED SAVINGS (calculated via script). NEVER hallucinate cost numbers.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |