Cloudofficial

azure-cost

microsoft/GitHub-Copilot-for-Azure · updated Apr 8, 2026

MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.

$npx skills add https://github.com/microsoft/GitHub-Copilot-for-Azure --skill azure-cost
0 commentsdiscussion
summary

Unified Azure cost management: query historical costs, forecast future spending, and optimize to reduce waste. WHEN: \"Azure costs\", \"Azure spending\", \"Azure bill\", \"cost breakdown\", \"cost by service\", \"cost by resource\", \"how much am I spending\", \"show my bill\", \"monthly cost summary\", \"cost trends\", \"top cost drivers\", \"actual cost\", \"amortized cost\", \"forecast spending\", \"projected costs\", \"estimate bill\", \"future costs\", \"budget forecast\", \"end of month co

skill.md
name
azure-cost
description
"Unified Azure cost management: query historical costs, forecast future spending, and optimize to reduce waste. WHEN: \"Azure costs\", \"Azure spending\", \"Azure bill\", \"cost breakdown\", \"cost by service\", \"cost by resource\", \"how much am I spending\", \"show my bill\", \"monthly cost summary\", \"cost trends\", \"top cost drivers\", \"actual cost\", \"amortized cost\", \"forecast spending\", \"projected costs\", \"estimate bill\", \"future costs\", \"budget forecast\", \"end of month costs\", \"how much will I spend\", \"optimize costs\", \"reduce spending\", \"find cost savings\", \"orphaned resources\", \"rightsize VMs\", \"cost analysis\", \"reduce waste\", \"unused resources\", \"optimize Redis costs\", \"cost by tag\", \"cost by resource group\", \"AKS cost analysis add-on\", \"namespace cost\", \"cost spike\", \"anomaly\", \"budget alert\", \"AKS cost visibility\". DO NOT USE FOR: deploying resources, provisioning infrastructure, diagnostics, security audits, or estimating costs for new resources not yet deployed."
license
MIT
metadata
author: Microsoft version: "1.0.0"

Azure Cost Management Skill

Unified skill for all Azure cost management tasks: querying historical costs, forecasting future spending, and optimizing to reduce waste.

When to Use This Skill

Activate this skill when user wants to:

  • Query or analyze Azure costs (how much am I spending, show my bill, cost breakdown)
  • Break down costs by service, resource, location, or tag
  • Analyze cost trends over time
  • Forecast future Azure spending or project end-of-month costs
  • Optimize Azure costs, reduce spending, or find savings
  • Find orphaned or unused resources
  • Rightsize Azure VMs, containers, or services
  • Generate cost optimization reports

Quick Reference

PropertyValue
Query API EndpointPOST {scope}/providers/Microsoft.CostManagement/query?api-version=2023-11-01
Forecast API EndpointPOST {scope}/providers/Microsoft.CostManagement/forecast?api-version=2023-11-01
MCP Toolsazure__documentation, azure__extension_cli_generate, azure__get_azure_bestpractices
CLIaz rest, az monitor metrics list, az resource list
Required RoleCost Management Reader + Monitoring Reader + Reader on scope

MCP Tools

ToolDescriptionParametersWhen to Use
azure__documentationSearch Azure documentationquery (Required): search termsResearch Cost Management API parameters and options
azure__extension_cli_generateGenerate Azure CLI commandsintent (Required): task description, cli-type (Required): "az"Construct az rest commands for cost queries
azure__get_azure_bestpracticesGet Azure best practicesintent (Required): optimization contextInform query design with cost management best practices
azure__extension_azqrRun Azure Quick Review compliance scansubscription (Required): subscription ID, resource-group (Optional): resource group nameFind orphaned resources and cost optimization opportunities
azure__aksAzure Kubernetes Service operationsvaries by sub-commandAKS cost analysis: list clusters, get node pools, inspect configuration

💡 Tip: Prefer MCP tools over direct CLI commands. Use az rest only when MCP tools don't cover the specific operation.


Routing

Read the user's request and follow the appropriate workflow below.

User IntentWorkflowExample Prompts
Understand current costsCost Query Workflow"how much am I spending", "cost by service", "show my bill"
Reduce costs / find wasteCost Optimization Workflow"optimize costs", "find orphaned resources", "reduce spending"
Project future costsCost Forecast Workflow"forecast costs", "end of month estimate", "how much will I spend"
Full cost pictureAll three workflows combined"give me the full picture of my Azure costs"

Important: When optimizing costs, always present the total bill and cost breakdown alongside optimization recommendations.


Scope Reference (Shared Across All Workflows)

ScopeURL Pattern
Subscription/subscriptions/<subscription-id>
Resource Group/subscriptions/<subscription-id>/resourceGroups/<resource-group-name>
Management Group/providers/Microsoft.Management/managementGroups/<management-group-id>
Billing Account/providers/Microsoft.Billing/billingAccounts/<billing-account-id>
Billing Profile/providers/Microsoft.Billing/billingAccounts/<billing-account-id>/billingProfiles/<billing-profile-id>

💡 Tip: These are scope paths only — not complete URLs. Combine with the API endpoint and version.


Part 1: Cost Query Workflow

For the full cost query workflow (scope selection, report types, timeframes, dataset configuration, API calls, pagination, guardrails, examples, and error handling), see:

📄 Cost Query Workflow


Part 2: Cost Optimization Workflow

For the full cost optimization workflow (prerequisites, best practices, Redis/AKS-specific analysis, Azure Quick Review, resource discovery, cost queries, pricing validation, utilization metrics, and report generation), see:

📄 Cost Optimization Workflow


Part 3: Cost Forecast Workflow

For the full cost forecast workflow (scope selection, time period rules, dataset configuration, forecast-specific options, API calls, response interpretation, guardrails, and error handling), see:

📄 Cost Forecast Workflow


Data Classification

  • ACTUAL DATA = Retrieved from Azure Cost Management API
  • ACTUAL METRICS = Retrieved from Azure Monitor
  • VALIDATED PRICING = Retrieved from official Azure pricing pages
  • ESTIMATED SAVINGS = Calculated based on actual data and validated pricing

Best Practices

  • Always query actual costs first — never estimate or assume
  • Always present the total bill alongside optimization recommendations
  • Validate pricing from official sources — account for free tiers
  • Use REST API for cost queries (more reliable than az costmanagement query)
  • Save audit trail — include all queries and responses
  • Include Azure Portal links for all resources
  • For costs < $10/month, emphasize operational improvements over financial savings
  • Never execute destructive operations without explicit approval

Common Pitfalls

  • Assuming costs: Always query actual data from Cost Management API
  • Ignoring free tiers: Many services have generous allowances
  • Using wrong date ranges: 30 days for costs, 14 days for utilization
  • Not showing the bill: Always present cost breakdown alongside optimization recommendations
  • Cost query failures: Use az rest with JSON body, not az costmanagement query

Safety Requirements

  • Get approval before deleting resources
  • Test changes in non-production first
  • Provide dry-run commands for validation
  • Include rollback procedures

SDK Quick References

  • Redis Management: .NET
how to use azure-cost

How to use azure-cost on Cursor

AI-first code editor with Composer

1

Prerequisites

Before installing skills in Cursor, ensure your development environment meets these requirements:

  • Cursor installed and configured on your development machine
  • Node.js version 16.0+ with npm package manager (verify with node --version)
  • Active project directory or workspace where you want to add azure-cost
2

Execute installation command

Execute the skills CLI command in your project's root directory to begin installation:

$npx skills add https://github.com/microsoft/GitHub-Copilot-for-Azure --skill azure-cost

The skills CLI fetches azure-cost from GitHub repository microsoft/GitHub-Copilot-for-Azure and configures it for Cursor.

3

Select Cursor when prompted

The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:

◆ Which agents do you want to install to?
│ ── Universal (.agents/skills) ── always included ────
│ • Amp
│ • Antigravity
│ • Cline
│ • Codex
│ ●Cursor(selected)
│ • Cursor
│ • Windsurf
4

Verify installation

Confirm successful installation by checking the skill directory location:

.cursor/skills/azure-cost

Reload or restart Cursor to activate azure-cost. Access the skill through slash commands (e.g., /azure-cost) or your agent's skill management interface.

Security & Verification Notice

We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.

Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.

List & Monetize Your Skill

Submit your Claude Code skill and start earning

GET_STARTED →

Use Cases

Task Automation & Efficiency

Automate repetitive workflows and reduce manual effort

Example

Generate reports, summarize documents, draft communications

Save 3-5 hours per week on routine tasks

Knowledge Enhancement

Learn new skills, understand complex topics, get expert guidance

Example

Explain concepts, provide examples, suggest learning resources

Accelerate learning and skill development by 2x

Quality Improvement

Enhance output quality through reviews, suggestions, and refinements

Example

Review drafts, suggest improvements, catch errors

Improve work quality by 30-40% with less effort

Implementation Guide

Prerequisites

  • Claude Desktop or compatible AI client with skill support
  • Clear understanding of task or problem to solve
  • Willingness to iterate and refine outputs

Time Estimate

15-45 minutes depending on use case complexity

Installation Steps

  1. 1.Install skill using provided installation command
  2. 2.Test with simple use case relevant to your work
  3. 3.Evaluate output quality and relevance
  4. 4.Iterate on prompts to improve results
  5. 5.Integrate into regular workflow if valuable

Common Pitfalls

  • Expecting perfect results without iteration
  • Not providing enough context in prompts
  • Using skill for tasks outside its intended scope
  • Accepting outputs without review and validation

Best Practices

✓ Do

  • +Start with clear, specific prompts
  • +Provide relevant context and constraints
  • +Review and refine all outputs before using
  • +Iterate to improve output quality
  • +Document successful prompt patterns

✗ Don't

  • Don't use without understanding skill limitations
  • Don't skip validation of outputs
  • Don't share sensitive information in prompts
  • Don't expect skill to replace human judgment

💡 Pro Tips

  • Be specific about desired format and style
  • Ask for multiple options to choose from
  • Request explanations to understand reasoning
  • Combine AI efficiency with human expertise

When to Use This

✓ Use When

Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.

✗ Avoid When

Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.

Learning Path

  1. 1Familiarize yourself with skill capabilities and limitations
  2. 2Start with low-risk, non-critical tasks
  3. 3Progress to more complex and valuable use cases
  4. 4Build expertise through regular use and experimentation

Discussion

Product Hunt–style comments (not star reviews)
  • No comments yet — start the thread.
general reviews

Ratings

4.744 reviews
  • Henry Sethi· Dec 24, 2024

    azure-cost fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Pratham Ware· Dec 20, 2024

    azure-cost is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Henry Sanchez· Dec 20, 2024

    azure-cost has been reliable in day-to-day use. Documentation quality is above average for community skills.

  • Olivia Gill· Dec 20, 2024

    azure-cost is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Henry Garcia· Nov 15, 2024

    We added azure-cost from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.

  • Layla Choi· Nov 15, 2024

    Registry listing for azure-cost matched our evaluation — installs cleanly and behaves as described in the markdown.

  • Sakshi Patil· Nov 11, 2024

    Keeps context tight: azure-cost is the kind of skill you can hand to a new teammate without a long onboarding doc.

  • Layla Park· Nov 11, 2024

    azure-cost reduced setup friction for our internal harness; good balance of opinion and flexibility.

  • Layla Huang· Nov 11, 2024

    Keeps context tight: azure-cost is the kind of skill you can hand to a new teammate without a long onboarding doc.

  • Henry Flores· Oct 6, 2024

    Solid pick for teams standardizing on skills: azure-cost is focused, and the summary matches what you get after install.

showing 1-10 of 44

1 / 5