Get the insight you need to cut Azure spend — without decoding the bill yourself.
Run these commands in Azure Cloud Shell or any terminal with the Azure CLI installed. They create a service principal with read-only access to resources and costs.
SUB=$(az account show --query id -o tsv) && az ad sp create-for-rbac --name "dillonsview-reader" --role "Reader" --scopes "/subscriptions/$SUB" && APP=$(az ad sp list --display-name "dillonsview-reader" --query "[0].appId" -o tsv) && az role assignment create --role "Cost Management Reader" --assignee $APP --scope "/subscriptions/$SUB" && az role assignment create --role "Monitoring Reader" --assignee $APP --scope "/subscriptions/$SUB"
The output JSON from the first command will contain:
Roles assigned: Reader (all resources) + Cost Management Reader (billing & cost data) + Monitoring Reader (VM metrics)