# Detect cloud cost anomalies with AWS Cost Explorer, GCP Billing and GPT-4o-mini

> Quick overview This workflow runs daily to detect AWS and optional GCP cost spikes, enriches AWS anomalies with CloudTrail context and an OpenAI explanation, posts actionable alerts and a run summary to Slack, and logs anomalies plus approve/ignore decisions to Google Sheets via one-time webhook links. How it works 1. Runs every day on a schedule (9 AM IST) and loads threshold/config values plus the existing anomaly log from Google Sheets. 2. Pulls recent daily AWS spend by service and region from AWS Cost Explorer (and optionally queries GCP costs from a BigQuery billing export) and normalizes both into a common structure. 3. Detects day-over-day cost anomalies using dollar, percent, and z-score thresholds while skipping already-seen anomalies and those muted by prior “ignore” decisions. 4. Posts a one-message run summary to Slack listing the anomalies alerted in this run. 5. For each anomaly, fetches recent AWS CloudTrail write events for the affected region when available and sends 

- **Domain**: `n8n-workflow-20793.n8n.io`
- **Provider**: n8n.io (https://n8n.io)
- **Kind**: workflow
- **Live-responds (last probe)**: None
- **Signed card**: False
- **Streaming**: False
- **Quality score**: 40%

## URLs
- Agent card: https://n8n.io/workflows/20793
- Page (HTML): https://agenstry.com/agents/n8n-workflow-20793.n8n.io
- Documentation: https://n8n.io/workflows/20793
