azure-cost by microsoft/azure-skills
npx skills add https://github.com/microsoft/azure-skills --skill azure-cost适用于所有 Azure 成本管理任务的统一技能:查询历史成本、预测未来支出以及优化以减少浪费。
当用户想要执行以下操作时,请激活此技能:
| 属性 | 值 |
|---|---|
| 查询 API 端点 | POST {scope}/providers/Microsoft.CostManagement/query?api-version=2023-11-01 |
| 预测 API 端点 | POST {scope}/providers/Microsoft.CostManagement/forecast?api-version=2023-11-01 |
| MCP 工具 | azure__documentation, , |
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
azure__extension_cli_generateazure__get_azure_bestpractices| CLI | az rest, az monitor metrics list, az resource list |
| 所需角色 | 成本管理读取者 + 监视读取者 + 作用域上的读取者 |
| 工具 | 描述 | 参数 | 何时使用 |
|---|---|---|---|
azure__documentation | 搜索 Azure 文档 | query (必需): 搜索词 | 研究成本管理 API 参数和选项 |
azure__extension_cli_generate | 生成 Azure CLI 命令 | intent (必需): 任务描述, cli-type (必需): "az" | 为成本查询构建 az rest 命令 |
azure__get_azure_bestpractices | 获取 Azure 最佳实践 | intent (必需): 优化上下文 | 使用成本管理最佳实践指导查询设计 |
azure__extension_azqr | 运行 Azure 快速审查合规性扫描 | subscription (必需): 订阅 ID, resource-group (可选): 资源组名称 | 查找孤立资源和成本优化机会 |
azure__aks | Azure Kubernetes 服务操作 | 因子命令而异 | AKS 成本分析:列出集群、获取节点池、检查配置 |
💡 提示: 优先使用 MCP 工具而非直接 CLI 命令。仅当 MCP 工具未涵盖特定操作时,才使用
az rest。
阅读用户的请求并遵循以下相应的工作流程。
重要: 优化成本时,务必在优化建议旁边展示总账单和成本明细。
| 作用域 | URL 模式 |
|---|---|
| 订阅 | /subscriptions/<subscription-id> |
| 资源组 | /subscriptions/<subscription-id>/resourceGroups/<resource-group-name> |
| 管理组 | /providers/Microsoft.Management/managementGroups/<management-group-id> |
| 计费账户 | /providers/Microsoft.Billing/billingAccounts/<billing-account-id> |
| 计费配置文件 | /providers/Microsoft.Billing/billingAccounts/<billing-account-id>/billingProfiles/<billing-profile-id> |
💡 提示: 这些仅是作用域路径,并非完整 URL。需要与 API 端点和版本结合使用。
有关完整的成本查询工作流程(作用域选择、报告类型、时间范围、数据集配置、API 调用、分页、防护措施、示例和错误处理),请参阅:
📄 成本查询工作流程
有关完整的成本优化工作流程(先决条件、最佳实践、Redis/AKS 特定分析、Azure 快速审查、资源发现、成本查询、定价验证、利用率指标和报告生成),请参阅:
📄 成本优化工作流程
有关完整的成本预测工作流程(作用域选择、时间段规则、数据集配置、预测特定选项、API 调用、响应解释、防护措施和错误处理),请参阅:
📄 成本预测工作流程
az costmanagement query 更可靠)az rest,而非 az costmanagement query每周安装量
4.7K
代码仓库
GitHub 星标数
577
首次出现
1 天前
安全审计
安装于
github-copilot4.7K
amp10
cline10
opencode10
cursor10
kimi-cli10
Unified skill for all Azure cost management tasks: querying historical costs, forecasting future spending, and optimizing to reduce waste.
Activate this skill when user wants to:
| Property | Value |
|---|---|
| Query API Endpoint | POST {scope}/providers/Microsoft.CostManagement/query?api-version=2023-11-01 |
| Forecast API Endpoint | POST {scope}/providers/Microsoft.CostManagement/forecast?api-version=2023-11-01 |
| MCP Tools | azure__documentation, azure__extension_cli_generate, azure__get_azure_bestpractices |
| CLI | az rest, az monitor metrics list, az resource list |
| Required Role | Cost Management Reader + Monitoring Reader + Reader on scope |
| Tool | Description | Parameters | When to Use |
|---|---|---|---|
azure__documentation | Search Azure documentation | query (Required): search terms | Research Cost Management API parameters and options |
azure__extension_cli_generate | Generate Azure CLI commands | intent (Required): task description, cli-type (Required): "az" | Construct az rest commands for cost queries |
💡 Tip: Prefer MCP tools over direct CLI commands. Use
az restonly when MCP tools don't cover the specific operation.
Read the user's request and follow the appropriate workflow below.
| User Intent | Workflow | Example Prompts |
|---|---|---|
| Understand current costs | Cost Query Workflow | "how much am I spending", "cost by service", "show my bill" |
| Reduce costs / find waste | Cost Optimization Workflow | "optimize costs", "find orphaned resources", "reduce spending" |
| Project future costs | Cost Forecast Workflow | "forecast costs", "end of month estimate", "how much will I spend" |
| Full cost picture | All 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 | URL 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.
For the full cost query workflow (scope selection, report types, timeframes, dataset configuration, API calls, pagination, guardrails, examples, and error handling), see:
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:
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:
az costmanagement query)az rest with JSON body, not az costmanagement queryWeekly Installs
4.7K
Repository
GitHub Stars
577
First Seen
1 day ago
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
github-copilot4.7K
amp10
cline10
opencode10
cursor10
kimi-cli10
AI工具合规自动化技能 - 一键扫描、验证与修复,确保AI项目部署安全
6,700 周安装
Kubernetes安全策略实战指南:NetworkPolicy、PodSecurityPolicy、RBAC配置与Pod安全标准
7,000 周安装
Baseline UI - 提升AI生成界面质量的Tailwind CSS与React开发规范工具
7,100 周安装
Google 联系人导出到 Sheets 自动化脚本 | 批量同步联系人数据
6,900 周安装
Claude代码简化专家 - 自动优化代码清晰度与可维护性,保持功能不变
6,800 周安装
LLM监控仪表板 - 实时追踪API成本、令牌使用与延迟,自动生成数据驱动报告
6,800 周安装
azure__get_azure_bestpractices | Get Azure best practices | intent (Required): optimization context | Inform query design with cost management best practices |
azure__extension_azqr | Run Azure Quick Review compliance scan | subscription (Required): subscription ID, resource-group (Optional): resource group name | Find orphaned resources and cost optimization opportunities |
azure__aks | Azure Kubernetes Service operations | varies by sub-command | AKS cost analysis: list clusters, get node pools, inspect configuration |