Summary
Add a new costmanagement toolset starting with azmcp costmanagement query run that retrieves actual Azure costs from the Cost Management Query/Usage API for a subscription or resource group.
Motivation
Azure MCP Server has no tool to retrieve actual Azure costs today. The only cost-adjacent tool is azmcp pricing get, which queries the public retail catalog (estimates, not actual spend). This gap was previously surfaced in:
AWS Billing MCP and GCP have analogous tools; Azure does not.
Scope of this issue (PR1)
azmcp costmanagement query run — read-only, scoped to subscription (optionally narrowed to a resource group). Backed by the GA SDK Azure.ResourceManager.CostManagement 1.0.3.
azmcp costmanagement query run --subscription <sub> \
[--resource-group <rg>] \
[--timeframe <MonthToDate|BillingMonthToDate|TheCurrentMonth|TheLastBillingMonth|WeekToDate|Custom>] \
[--from <YYYY-MM-DD>] [--to <YYYY-MM-DD>] \
[--granularity <None|Daily|Monthly>] \
[--group-by <ServiceName|ResourceGroupName|ResourceLocation|ResourceId|MeterCategory|MeterSubCategory|ChargeType|BillingPeriod>]
Caller must have Cost Management Reader or Reader role on the scope.
PR is ready and will be opened from francesco1501/mcp:feature/add-costmanagement-query shortly.
cc @anannya03 (CODEOWNER of tools/Azure.Mcp.Tools.Pricing/ and original assignee of #1420) — would appreciate a sanity check on the design before review.
Summary
Add a new
costmanagementtoolset starting withazmcp costmanagement query runthat retrieves actual Azure costs from the Cost Management Query/Usage API for a subscription or resource group.Motivation
Azure MCP Server has no tool to retrieve actual Azure costs today. The only cost-adjacent tool is
azmcp pricing get, which queries the public retail catalog (estimates, not actual spend). This gap was previously surfaced in:[ONBOARD] finops recommenders(closed Done 2026-02 with no follow-up PR)Create CostManagement Tool File Structure(closed without merge 2025-10 due to inactivity)AWS Billing MCP and GCP have analogous tools; Azure does not.
Scope of this issue (PR1)
azmcp costmanagement query run— read-only, scoped to subscription (optionally narrowed to a resource group). Backed by the GA SDKAzure.ResourceManager.CostManagement1.0.3.Caller must have
Cost Management ReaderorReaderrole on the scope.PR is ready and will be opened from
francesco1501/mcp:feature/add-costmanagement-queryshortly.cc @anannya03 (CODEOWNER of
tools/Azure.Mcp.Tools.Pricing/and original assignee of #1420) — would appreciate a sanity check on the design before review.