Optimize Azure resource usage and analyze Reservation or Savings Plan utilization to reduce cloud spending.
- GitHub stars
- 1,636
- Files
- 9
- Last commit
- Nov 11, 2026
- License
- MIT
- Allowed tools
- —
What does the cost-optimization skill do?
cost-optimization is an agent skill. Optimize Azure resource usage and analyze Reservation or Savings Plan utilization to reduce cloud spending.
Summary generated from the skill's SKILL.md.
About the cost-optimization skill
Reducing Azure cloud spending and identifying wasted resources is the primary function of this skill. It helps developers and cloud administrators find idle resources, orphaned disks, or public IPs that continue to incur charges even after a virtual machine is deleted. By using Cost and Resource Graph tools, an agent can identify opportunities to rightsize existing infrastructure to better match actual usage patterns.
Beyond simple resource management, the skill analyzes commitment-based savings through tools like list_benefit_utilization and get_benefit_recommendations. This allows users to review Reservation and Savings Plan utilization to ensure they are maximizing their existing commitments. The skill is designed to recommend changes rather than performing actions like deleting, resizing, or purchasing resources directly. It focuses strictly on optimization and commitment review, meaning it should not be used for forecasting, budgeting, or analyzing sudden cost spikes.
What an agent can do with it
- 1Rightsize existing infrastructureAnalyze current Azure resource usage to determine if resources should be resized to reduce unnecessary spending.
Written from the skill's SKILL.md. Every use case is checked against a quote from it.
How to install the cost-optimization skill
Each command copies the skill folder into the client's skills directory. Restart the client or start a new session to load it.Install the cost-optimization skill in Plugin
/plugin marketplace add microsoft/azure-skills /plugin install azure-cost@azure-skills
Install the cost-optimization skill in Claude Code
~/.claude/skills/cost-optimization/SKILL.md
$ npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization ~/.claude/skills/cost-optimizationInstall the cost-optimization skill in Claude Code (project)
.claude/skills/cost-optimization/SKILL.md
$ npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization .claude/skills/cost-optimizationInstall the cost-optimization skill in Codex
~/.agents/skills/cost-optimization/SKILL.md
$ npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization ~/.agents/skills/cost-optimizationInstall the cost-optimization skill in Gemini CLI
~/.gemini/skills/cost-optimization/SKILL.md
$ npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization ~/.gemini/skills/cost-optimizationInstall the cost-optimization skill in Claude.ai
npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization cost-optimization && zip -r cost-optimization.zip cost-optimization # claude.ai → Customize → Skills → + → Create skill → Upload a skill → cost-optimization.zip
Automated checks
Ran Nov 14, 2026Full report →Passed our automated checks. That is not a security audit: read the scripts before you let an agent run them. How checks work
- Source repository linked and reachablemicrosoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization is public and reachablegithub.com/microsoft/azure-skills/tree/HEAD/.github/plugins/ ↗Pass
- Open source license (OSI)MITspdx.org/licenses/MIT.html ↗Pass
- Commit or release in the last yearLast commit 2026-11-11github.com/microsoft/azure-skills/commits ↗Pass
- No download-and-run or credential theft in scriptsNo scripts in the skill folderPass
- No hidden instructions in SKILL.mdNo override phrases, safeguard switches, credential requests or hidden charactersgithub.com/microsoft/azure-skills/blob/HEAD/.github/plugins/ ↗Pass
- Pre-approved tools are scopedNo pre-approved tools; the agent asks before using onegithub.com/microsoft/azure-skills/blob/HEAD/.github/plugins/ ↗Pass
SKILL.md
View on GitHubAzure Cost Optimization
Quick Reference
| Intent | Workflow | Primary tools |
|---|---|---|
| Reduce waste or rightsize | Optimization | Cost and Resource Graph tools |
| Review commitments | Commitments | list_benefit_utilization, list_reservation_transactions, get_benefit_recommendations |
When to Use This Skill
Use for waste, rightsizing, and commitments.
MCP Tools
Use cost and Resource Graph tools for optimization and benefit tools for commitments. Validate queries. Fallback: API mappings.
Workflow
- Confirm scope, period, currency, and commitment intent.
- Load only the matching workflow above.
- Never transform MCP results in a shell or interpreter; request validated server-side projection, aggregation, or bounded follow-up queries.
- Separate measured cost, reported savings, and qualitative opportunities.
- Recommend changes only; do not delete, resize, purchase, or deploy resources.
Error Handling
| Error | Action |
|---|---|
| Access denied | Name the scope and permission. |
| Multiple currencies | Group and report each currency separately. |
| Missing evidence | State the gap; do not invent values. |
| Server error | Retry once; then report the trace ID. |
Files in this skill
9cost-optimization skill questions
How do I install the cost-optimization skill in Claude Code?
Run npx degit microsoft/azure-skills/.github/plugins/azure-cost/skills/cost-optimization ~/.claude/skills/cost-optimization. Claude Code loads skills from ~/.claude/skills (all projects) or .claude/skills (one project) and uses a skill when its description matches the task.
Which clients can use the cost-optimization skill?
Any client that reads the Agent Skills format: Claude Code, Codex, Gemini CLI and claude.ai (upload as a ZIP). Scripts in the skill run only where the client allows code execution.
What should I use this skill for?
The skill is intended for reducing waste, rightsizing resources, and reviewing commitments like Reservations or Savings Plans.
Can this skill be used to forecast future costs or manage budgets?
No, the skill should not be used for cost spikes, forecasts, pricing estimates, budgets, or governance.
Is the agent allowed to delete or resize resources directly?
No, the agent should only recommend changes and must not delete, resize, purchase, or deploy resources.