Azure Cost Guardian Toolkit
Comprehensive Azure cost management toolkit covering the entire data platform. 50+ API queries, anomaly detection, RI calculator, and FinOps playbook.
📁 File Structure 15 files
📖 Documentation Preview README excerpt
Azure Cost Guardian Toolkit
By [Datanest Digital](https://datanest.dev) | Version 1.0.0 | $59
---
Overview
The Azure Cost Guardian Toolkit is a comprehensive, production-ready collection of scripts,
queries, policies, notebooks, and templates designed to give engineering and FinOps teams
complete visibility and control over Azure cloud spend.
Whether you are a platform engineer implementing cost guardrails, a FinOps practitioner
building chargeback models, or a team lead trying to eliminate waste, this toolkit provides
the building blocks to operationalize cloud cost management from day one.
What's Included
| Component | Description |
|---|---|
| Cost Management Queries | 50+ Python functions wrapping Azure Cost Management APIs for programmatic spend analysis |
| Budget Alert Policies | Ready-to-deploy budget alert configurations at subscription, resource group, and tag levels |
| Tagging Enforcement Policies | Azure Policy definitions to enforce consistent resource tagging across your organization |
| Cost Anomaly Detection Notebook | Databricks notebook for daily cost anomaly detection with configurable alerting thresholds |
| Reserved Instance Calculator | Databricks notebook for RI sizing analysis and break-even calculations |
| Idle Resource Detector | Script to find and report unused disks, unattached NICs, stopped VMs, and other waste |
| Storage Lifecycle Manager | Automated storage tier management (hot -> cool -> archive) based on access patterns |
| Advisor Automation | Script to fetch, filter, and act on Azure Advisor cost recommendations |
| Terraform Modules | Infrastructure-as-code for budget alerts, action groups, and cost management resources |
| FinOps Review Templates | Monthly executive review and chargeback/showback report templates |
| FinOps Playbook | Comprehensive guide covering crawl-walk-run FinOps adoption |
Prerequisites
- Python 3.9+
- Azure SDK for Python (
azure-mgmt-costmanagement,azure-mgmt-consumption,azure-identity) - Terraform 1.5+ (for infrastructure modules)
- Databricks Runtime 13.x+ (for notebooks)
- Azure subscription with Cost Management Reader (minimum) role
Quick Start
1. Install Dependencies
pip install azure-identity azure-mgmt-costmanagement azure-mgmt-consumption \
azure-mgmt-resource azure-mgmt-compute azure-mgmt-network azure-mgmt-storage \
azure-mgmt-advisor azure-mgmt-monitor pandas numpy scipy requests
2. Authenticate
from azure.identity import DefaultAzureCredential
credential = DefaultAzureCredential()
3. Run Your First Query
*... continues with setup instructions, usage examples, and more.*