Skip to content

Commit

Permalink
Added Tags filter for budgets and updated the api version (Azure#2625)
Browse files Browse the repository at this point in the history
* Added Tags filter for budgets and updated the api version

Added Tags filter for budgets and updated the api version

* Updated comments

Updated comments

* Incorporated review comments

Incorporated review comments

* Incorporated review comments

Incorporated review comments

* Incorporated review comment

Incorporated review comment
  • Loading branch information
asarkar84 authored and marstr committed Mar 13, 2018
1 parent f6f1326 commit 5da5eeb
Show file tree
Hide file tree
Showing 20 changed files with 3,122 additions and 1 deletion.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
{
"parameters": {
"api-version": "2018-03-31",
"subscriptionId": "00000000-0000-0000-0000-000000000000",
"resourceGroupName": "MYDEVTESTRG",
"budgetName": "TestBudget"
},
"responses": {
"200": {
"body": {
"id": "subscriptions/{subscription-id}/providers/Microsoft.Consumption/budgets/TestBudget",
"name": "TestBudget",
"type": "Microsoft.Consumption/budgets",
"eTag": "\"1d34d012214157f\"",
"properties": {
"category": "Cost",
"amount": 100.65,
"timeGrain": "Monthly",
"timePeriod": {
"startDate": "2017-10-01T00:00:00Z",
"endDate": "2018-10-31T00:00:00Z"
},
"filters": {
"resourceGroups": [
"MPDEVTESTRG"
],
"resources": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/MSVM2",
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/platformcloudplatformGeneric1"
],
"meters": [
"00000000-0000-0000-0000-000000000000"
],
"tags": {
"category": [
"Dev",
"Prod"
],
"department": [
"engineering",
"sales"
]
}
},
"currentSpend": {
"amount": 80.89,
"unit": "USD"
},
"notifications": {
"Actual_GreaterThan_80_Percent": {
"enabled": true,
"operator": "GreaterThan",
"threshold": 80,
"contactEmails": [
"johndoe@contoso.com",
"janesmith@contoso.com"
],
"contactRoles": [
"Contributor",
"Reader"
],
"contactGroups": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/microsoft.insights/actionGroups/SampleActionGroup"
]
}
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
{
"parameters": {
"api-version": "2018-03-31",
"subscriptionId": "00000000-0000-0000-0000-000000000000",
"resourceGroupName": "MYDEVTESTRG"
},
"responses": {
"200": {
"body": {
"value": [
{
"id": "subscriptions/{subscription-id}/providers/Microsoft.Consumption/budgets/TestBudget",
"name": "TestBudget",
"type": "Microsoft.Consumption/budgets",
"eTag": "\"1d34d012214157f\"",
"properties": {
"category": "Cost",
"amount": 100.65,
"timeGrain": "Monthly",
"timePeriod": {
"startDate": "2017-10-01T00:00:00Z",
"endDate": "2018-10-31T00:00:00Z"
},
"filters": {
"resourceGroups": [
"MYDEVTESTRG"
],
"resources": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/MYVM2",
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/platformcloudplatformGeneric1"
],
"meters": [
"00000000-0000-0000-0000-000000000000"
],
"tags": {
"category": [
"Dev",
"Prod"
],
"department": [
"engineering",
"sales"
]
}
},
"currentSpend": {
"amount": 80.89,
"unit": "USD"
},
"notifications": {
"Actual_GreaterThan_80_Percent": {
"enabled": true,
"operator": "GreaterThan",
"threshold": 80,
"contactEmails": [
"johndoe@contoso.com",
"janesmith@contoso.com"
],
"contactRoles": [
"Contributor",
"Reader"
]
},
"Actual_GreaterThanOrEqualTo_90_Percent": {
"enabled": true,
"operator": "GreaterThanOrEqualTo",
"threshold": 90,
"contactEmails": [
"johndoe@contoso.com",
"janesmith@contoso.com"
],
"contactRoles": [
"Contributor",
"Reader"
],
"contactGroups": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/microsoft.insights/actionGroups/SampleActionGroup"
]
}
}
}
},
{
"id": "subscriptions/{subscription-id}/providers/Microsoft.Consumption/budgets/TestBudget",
"name": "TestBudget",
"type": "Microsoft.Consumption/budgets",
"eTag": "\"1d34d012214157f\"",
"properties": {
"category": "Cost",
"amount": 600.65,
"timeGrain": "Monthly",
"timePeriod": {
"startDate": "2017-10-01T00:00:00Z",
"endDate": "2018-10-31T00:00:00Z"
},
"filters": {
"resourceGroups": [
"MYDEVTESTRG"
],
"resources": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/MYVM2",
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/Microsoft.Compute/virtualMachines/platformcloudplatformGeneric1"
],
"meters": [
"00000000-0000-0000-0000-000000000000"
],
"tags": {
"category": [
"Dev",
"Prod"
],
"department": [
"engineering",
"sales"
]
}
},
"currentSpend": {
"amount": 120.89,
"unit": "USD"
},
"notifications": {
"Actual_GreaterThan_40_Percent": {
"enabled": true,
"operator": "GreaterThan",
"threshold": 40,
"contactEmails": [
"johndoe@contoso.com",
"janesmith@contoso.com"
],
"contactRoles": [
"Contributor",
"Reader"
]
},
"Actual_GreaterThanOrEqualTo_60_Percent": {
"enabled": true,
"operator": "GreaterThanOrEqualTo",
"threshold": 60,
"contactEmails": [
"johndoe@contoso.com",
"janesmith@contoso.com"
],
"contactRoles": [
"Contributor",
"Reader"
],
"contactGroups": [
"/subscriptions/{subscription-id}/resourceGroups/MYDEVTESTRG/providers/microsoft.insights/actionGroups/SampleActionGroup"
]
}
}
}
}
]
}
}
}
}
Loading

0 comments on commit 5da5eeb

Please sign in to comment.