1

I have a Kusto query that can help me list a few resources:

ResourceContainers
| where type=='microsoft.resources/subscriptions/resourcegroups' | project name, type  | limit 5
| union  (Resources | project name, type | limit 5)

I would like to add for each resource the cost of the last 30 days.

I know I can do that through Workbooks but I don't know how to do that from the Azure Resource Graph Explorer.

I know that form the Azure Resource Graph Explorer I can query the Azure Advisor, which is something similar to what I want to do.

But how can I reach the Cost Management API?

Francesco Mantovani
  • 10,216
  • 13
  • 73
  • 113

1 Answers1

1

It isn't possible to retrieve cost details of each resource using ARG as of now.

SwathiDhanwada
  • 518
  • 3
  • 9
  • Thank you, so what is the alternative for having resources and costs in the same query? – Francesco Mantovani Dec 23 '22 at 09:16
  • do both of them separately, and then use the "merge" data source in workbooks to merge the results of the 2 queries (unfortunately the ARM data source only lets you query one resource at a time, so it might not get you want you need if you need MANY calls to arm) – John Gardner Jan 06 '23 at 00:15