I checked Microsoft documentations but couldn't find the Azure CLI or RESTful API equivalent of Get-AzStorageUsage.
I need it to query current quota limits of our subscription using Ansible playbooks so I need either Azure CLI or RESTful API equivalent.
CodePudding user response:
Azure CLI
az storage account show-usage --location
RESTful API
GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Storage/locations/{location}/usages?api-version=2021-04-01
https://docs.microsoft.com/en-us/rest/api/storagerp/usages/list-by-location
