diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/common-types.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/common-types.json index c9dbec0c1395..5a53d4c8c527 100644 --- a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/common-types.json +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/common-types.json @@ -87,7 +87,8 @@ "properties": { "code": { "description": "Error code.", - "type": "string", + "type": "integer", + "format": "int32", "readOnly": true }, "message": { @@ -111,7 +112,7 @@ "readOnly": true, "description": "The additional details of the error.", "items": { - "$ref": "#/definitions/ErrorDetails" + "$ref": "#/definitions/ErrorDetailsWithNestedDetails" }, "x-ms-identifiers": [] } @@ -165,22 +166,12 @@ "CostManagementProxyResource": { "description": "The Resource model definition.", "type": "object", + "allOf": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ProxyResource" + } + ], "properties": { - "id": { - "readOnly": true, - "type": "string", - "description": "Resource Id." - }, - "name": { - "readOnly": true, - "type": "string", - "description": "Resource name." - }, - "type": { - "readOnly": true, - "type": "string", - "description": "Resource type." - }, "eTag": { "type": "string", "description": "eTag of the resource. To handle concurrent update scenario, this field will be used to determine whether the user is updating the latest version or not." diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/costmanagement.budgets.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/costmanagement.budgets.json index 54534ad6feac..bdecff29c10d 100644 --- a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/costmanagement.budgets.json +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/costmanagement.budgets.json @@ -83,6 +83,9 @@ }, "CustomerBudgetsList-MCA-CSP": { "$ref": "./examples/Budgets/List/MCA/CustomerBudgetsList.json" + }, + "CustomerBudgetsList-MCA-CSP-CategoryTypeFilter": { + "$ref": "./examples/Budgets/List/MCA/CustomerBudgetsList-CategoryTypeFilter.json" } }, "parameters": [ @@ -187,8 +190,17 @@ "CreateOrUpdate-ReservationUtilization-BillingProfileMCA-AlertRule-ReservedResourceTypeFilter": { "$ref": "./examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-BillingProfile-AlertRule-ReservedResourceTypeFilter.json" }, - "CreateOrUpdate-ReservationUtilization-BillingProfile-AlertRule-ReservationIdFilter": { + "CreateOrUpdate-ReservationUtilization-BillingProfileMCA-AlertRule-ReservationIdFilter": { "$ref": "./examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-BillingProfile-AlertRule-ReservationIdFilter.json" + }, + "CreateOrUpdate-ReservationUtilization-CustomerCSP-AlertRule.json": { + "$ref": "./examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule.json" + }, + "CreateOrUpdate-ReservationUtilization-CustomerCSP-AlertRule-ReservedResourceTypeFilter": { + "$ref": "./examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservedResourceTypeFilter.json" + }, + "CreateOrUpdate-ReservationUtilization-CustomerCSP-AlertRule-ReservationIdFilter": { + "$ref": "./examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservationIdFilter.json" } }, "parameters": [ @@ -729,7 +741,7 @@ "in": "path", "required": true, "type": "string", - "description": "The scope associated with budget operations.\n\n Supported scopes for **CategoryType: Cost**\n\n Azure RBAC Scopes:\n- '/subscriptions/{subscriptionId}/' for subscription scope\n- '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope\n- '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group scope\n\n EA (Enterprise Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for Department scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount scope\n\n MCA (Modern Customer Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}' for billingProfile scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}/invoiceSections/{invoiceSectionId}' for invoiceSection scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/customers/{customerId}' for customer scope (CSP only)\n\n Supported scopes for **CategoryType: ReservationUtilization**\n\n EA (Enterprise Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account Scope\n\nMCA (Modern Customer Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}' for billingProfile scope", + "description": "The scope associated with budget operations.\n\n Supported scopes for **CategoryType: Cost**\n\n Azure RBAC Scopes:\n- '/subscriptions/{subscriptionId}/' for subscription scope\n- '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope\n- '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group scope\n\n EA (Enterprise Agreement) Scopes:\n\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for Department scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount scope\n\n MCA (Modern Customer Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}' for billingProfile scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}/invoiceSections/{invoiceSectionId}' for invoiceSection scope\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/customers/{customerId}' for customer scope (CSP only)\n\n Supported scopes for **CategoryType: ReservationUtilization**\n\n EA (Enterprise Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account Scope\n\nMCA (Modern Customer Agreement) Scopes:\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}' for billingProfile scope (non-CSP only)\n- '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/customers/{customerId}' for customer scope (CSP only)", "x-ms-parameter-location": "method", "x-ms-skip-url-encoding": true }, diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservationIdFilter.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservationIdFilter.json new file mode 100644 index 000000000000..97df91ca0469 --- /dev/null +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservationIdFilter.json @@ -0,0 +1,126 @@ +{ + "parameters": { + "api-version": "2023-04-01-preview", + "billingAccountId": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01", + "customerId": "000000-1111-2222-3333-444444444444", + "budgetName": "TestAlertRule", + "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444", + "parameters": { + "eTag": "\"1d34d016a593709\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservationId", + "operator": "In", + "values": [ + "00000000-0000-0000-0000-000000000000", + "00000000-0000-0000-0000-000000000001", + "00000000-0000-0000-0000-000000000002" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "responses": { + "201": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservationId", + "operator": "In", + "values": [ + "00000000-0000-0000-0000-000000000000", + "00000000-0000-0000-0000-000000000001", + "00000000-0000-0000-0000-000000000002" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "200": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservationId", + "operator": "In", + "values": [ + "00000000-0000-0000-0000-000000000000", + "00000000-0000-0000-0000-000000000001", + "00000000-0000-0000-0000-000000000002" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + } + } +} diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservedResourceTypeFilter.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservedResourceTypeFilter.json new file mode 100644 index 000000000000..dc0b03da67e4 --- /dev/null +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule-ReservedResourceTypeFilter.json @@ -0,0 +1,126 @@ +{ + "parameters": { + "api-version": "2023-04-01-preview", + "billingAccountId": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01", + "customerId": "000000-1111-2222-3333-444444444444", + "budgetName": "TestAlertRule", + "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444", + "parameters": { + "eTag": "\"1d34d016a593709\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservedResourceType", + "operator": "In", + "values": [ + "VirtualMachines", + "SqlDatabases", + "CosmosDb" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "responses": { + "201": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservedResourceType", + "operator": "In", + "values": [ + "VirtualMachines", + "SqlDatabases", + "CosmosDb" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "200": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservedResourceType", + "operator": "In", + "values": [ + "VirtualMachines", + "SqlDatabases", + "CosmosDb" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + } + } +} diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule.json new file mode 100644 index 000000000000..a7c11d086e6b --- /dev/null +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/CreateOrUpdate/ReservationUtilization/MCA/CreateOrUpdate-ReservationUtilization-Customer-AlertRule.json @@ -0,0 +1,96 @@ +{ + "parameters": { + "api-version": "2023-04-01-preview", + "billingAccountId": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01", + "customerId": "000000-1111-2222-3333-444444444444", + "budgetName": "TestAlertRule", + "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444", + "parameters": { + "eTag": "\"1d34d016a593709\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": {}, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "responses": { + "201": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": {}, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + }, + "200": { + "body": { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestAlertRule", + "name": "TestAlertRule", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": {}, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + } + } +} diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList-CategoryTypeFilter.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList-CategoryTypeFilter.json new file mode 100644 index 000000000000..7f827df0b78c --- /dev/null +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList-CategoryTypeFilter.json @@ -0,0 +1,83 @@ +{ + "parameters": { + "api-version": "2023-04-01-preview", + "billingAccountId": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01", + "customerId": "000000-1111-2222-3333-444444444444", + "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444", + "$filter": "properties/category eq 'ReservationUtilization'" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestRUAlert1", + "name": "TestRUAlert1", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": {}, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + }, + { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestRUAlert2", + "name": "TestRUAlert2", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last7Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservationId", + "operator": "In", + "values": [ + "00000000-0000-0000-0000-000000000000", + "00000000-0000-0000-0000-000000000001", + "00000000-0000-0000-0000-000000000002" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 80, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + } + ] + } + } + } +} diff --git a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList.json b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList.json index 56bf6ab2bfe5..98da0b4667af 100644 --- a/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList.json +++ b/specification/cost-management/resource-manager/Microsoft.CostManagement/preview/2023-04-01-preview/examples/Budgets/List/MCA/CustomerBudgetsList.json @@ -2,15 +2,15 @@ "parameters": { "api-version": "2023-04-01-preview", "billingAccountId": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01", - "customerId": "00000000-0000-0000-0000-000000000000", - "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/00000000-0000-0000-0000-000000000000" + "customerId": "000000-1111-2222-3333-444444444444", + "scope": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444" }, "responses": { "200": { "body": { "value": [ { - "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/00000000-0000-0000-0000-000000000000", + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444", "name": "TestBudget1", "type": "Microsoft.CostManagement/budgets", "eTag": "\"1d34d012214157c\"", @@ -41,7 +41,7 @@ } }, { - "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/00000000-0000-0000-0000-000000000000/providers/Microsoft.CostManagement/budgets/TestBudget2", + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestBudget2", "name": "TestBudget2", "type": "Microsoft.CostManagement/budgets", "eTag": "\"1d34d012214157d\"", @@ -70,6 +70,72 @@ } } } + }, + { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestRUAlert1", + "name": "TestRUAlert1", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last30Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": {}, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 99, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } + }, + { + "id": "providers/Microsoft.Billing/billingAccounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee:ffffffff-gggg-hhhh-iiii-jjjjjjjjjjjj_2023-04-01/customers/000000-1111-2222-3333-444444444444/providers/Microsoft.CostManagement/budgets/TestRUAlert2", + "name": "TestRUAlert2", + "type": "Microsoft.CostManagement/budgets", + "eTag": "\"1d34d012214157f\"", + "properties": { + "category": "ReservationUtilization", + "timeGrain": "Last7Days", + "timePeriod": { + "startDate": "2023-04-01T00:00:00Z", + "endDate": "2025-04-01T00:00:00Z" + }, + "filter": { + "dimensions": { + "name": "ReservationId", + "operator": "In", + "values": [ + "00000000-0000-0000-0000-000000000000", + "00000000-0000-0000-0000-000000000001", + "00000000-0000-0000-0000-000000000002" + ] + } + }, + "notifications": { + "Actual_LessThan_99_Percent": { + "enabled": true, + "operator": "LessThan", + "threshold": 80, + "frequency": "Daily", + "locale": "en-us", + "contactEmails": [ + "johndoe@contoso.com", + "janesmith@contoso.com" + ] + } + } + } } ] } diff --git a/specification/cost-management/resource-manager/readme.md b/specification/cost-management/resource-manager/readme.md index 8eab8d240275..298f5d155570 100644 --- a/specification/cost-management/resource-manager/readme.md +++ b/specification/cost-management/resource-manager/readme.md @@ -401,7 +401,7 @@ This is not used by Autorest itself. ``` yaml $(swagger-to-sdk) swagger-to-sdk: - - repo: azure-sdk-for-net + - repo: azure-sdk-for-net-track2 - repo: azure-sdk-for-go - repo: azure-sdk-for-python-track2 - repo: azure-sdk-for-node