Complete the code to create a budget alert in Azure Cost Management.
az consumption budget create --amount [1] --time-grain Monthly --name MyBudget --resource-group MyResourceGroupThe --amount parameter sets the budget limit. Here, 500 means the budget alert triggers when spending reaches $500.
Complete the code to list cost management exports in Azure.
az consumption export list --resource-group [1]The --resource-group parameter specifies the resource group name where exports are configured. 'MyResourceGroup' is the correct example here.
Fix the error in the command to create a cost alert rule for a subscription.
az monitor metrics alert create --name CostAlert --resource-group MyResourceGroup --scopes [1] --condition "total Cost > 100" --description "Alert when cost exceeds $100"
The --scopes parameter requires the full subscription ID path starting with '/subscriptions/'. This is the correct format.
Fill both blanks to create a cost management export with daily recurrence and CSV format.
az consumption export create --name DailyExport --resource-group MyResourceGroup --definition '{"type": "Usage", "timeframe": "[1]", "format": "[2]"}'
The timeframe should be 'Daily' for daily exports, and the format should be 'Csv' for CSV files.
Fill all three blanks to create a budget with a monthly time grain, a limit of 1000, and a notification threshold at 80%.
az consumption budget create --amount [1] --time-grain [2] --name MyBudget --resource-group MyResourceGroup --notifications '{"enabled": true, "threshold": [3]'
The budget amount is 1000, the time grain is Monthly, and the notification threshold is 0.8 (80%).