diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertMultipleResource.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertMultipleResource.json new file mode 100644 index 000000000000..fba5379d0fb2 --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertMultipleResource.json @@ -0,0 +1,103 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest", + "ruleName": "MetricAlertOnMultipleResources", + "api-version": "2018-03-01", + "parameters": { + "location": "global", + "tags": {}, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/providers/microsoft.insights/metricalerts/MetricAlertOnMultipleResources", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate":false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertResourceGroup.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertResourceGroup.json new file mode 100644 index 000000000000..907f73e9c2f8 --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertResourceGroup.json @@ -0,0 +1,103 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest1", + "ruleName": "MetricAlertAtResourceGroupLevel", + "api-version": "2018-03-01", + "parameters": { + "location": "global", + "tags": {}, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest1/providers/providers/microsoft.insights/metricalerts/MetricAlertAtResourceGroupLevel", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate":false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlert.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertSingleResource.json similarity index 100% rename from specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlert.json rename to specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertSingleResource.json diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertSubscription.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertSubscription.json new file mode 100644 index 000000000000..09c9cf710d19 --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/createOrUpdateMetricAlertSubscription.json @@ -0,0 +1,101 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest", + "ruleName": "MetricAlertAtSubscriptionLevel", + "api-version": "2018-03-01", + "parameters": { + "location": "global", + "tags": {}, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/providers/microsoft.insights/metricalerts/MetricAlertAtSubscriptionLevel", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate":false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertMultipleResource.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertMultipleResource.json new file mode 100644 index 000000000000..789b5b34b10e --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertMultipleResource.json @@ -0,0 +1,60 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest", + "ruleName": "MetricAlertOnMultipleResources", + "api-version": "2018-03-01" + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/providers/microsoft.insights/metricalerts/MetricAlertOnMultipleResources", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/Microsoft.Compute/virtualMachines/gigwadme2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertResourceGroup.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertResourceGroup.json new file mode 100644 index 000000000000..9ab3285b8179 --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertResourceGroup.json @@ -0,0 +1,60 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest1", + "ruleName": "MetricAlertAtResourceGroupLevel", + "api-version": "2018-03-01" + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest1/providers/providers/microsoft.insights/metricalerts/MetricAlertAtResourceGroupLevel", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest1", + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest2" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlert.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertSingleResource.json similarity index 100% rename from specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlert.json rename to specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertSingleResource.json diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertSubscription.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertSubscription.json new file mode 100644 index 000000000000..1fb0e39afe36 --- /dev/null +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/examples/getMetricAlertSubscription.json @@ -0,0 +1,59 @@ +{ + "parameters": { + "subscriptionId": "14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7", + "resourceGroupName": "gigtest", + "ruleName": "MetricAlertAtSubscriptionLevel", + "api-version": "2018-03-01" + }, + "responses": { + "200": { + "headers": {}, + "body": { + "id": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourceGroups/gigtest/providers/providers/microsoft.insights/metricalerts/MetricAlertAtSubscriptionLevel", + "type": "Microsoft.Insights/metricAlerts", + "location": "global", + "tags": { + "hidden-link:/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/leoalerttest": "Resource" + }, + "properties": { + "description": "This is the description of the rule1", + "severity": 3, + "enabled": true, + "scopes": [ + "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7" + ], + "evaluationFrequency": "PT1M", + "windowSize": "PT15M", + "targetResourceType":"Microsoft.Compute/virtualMachines", + "targetResourceRegion":"southcentralus", + "criteria": { + "odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "allOf": [ + { + "criterionType": "StaticThresholdCriterion", + "name": "High_CPU_80", + "metricName": "Percentage CPU", + "metricNamespace": "microsoft.compute/virtualmachines", + "dimensions": [ + ], + "operator": "GreaterThan", + "threshold": 80.50, + "timeAggregation": "Average" + } + ] + }, + "autoMitigate": false, + "actions": [ + { + "actionGroupId": "/subscriptions/14ddf0c5-77c5-4b53-84f6-e1fa43ad68f7/resourcegroups/gigtest/providers/microsoft.insights/notificationgroups/group2", + "webhookProperties": { + "key11": "value11", + "key12": "value12" + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/metricAlert_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/metricAlert_API.json index 3bed1aba4066..e3dcb173e5d5 100644 --- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/metricAlert_API.json +++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-03-01/metricAlert_API.json @@ -114,7 +114,10 @@ } }, "x-ms-examples": { - "Get an alert rule": { "$ref": "./examples/getMetricAlert.json" } + "Get an alert rule for single resource": { "$ref": "./examples/getMetricAlertSingleResource.json" }, + "Get an alert rule for multiple resources": { "$ref": "./examples/getMetricAlertMultipleResource.json" }, + "Get an alert rule on resource group(s)": { "$ref": "./examples/getMetricAlertResourceGroup.json" }, + "Get an alert rule on subscription": { "$ref": "./examples/getMetricAlertSubscription.json" } } }, "put": { @@ -149,7 +152,10 @@ } }, "x-ms-examples": { - "Create or update an alert rule": { "$ref": "./examples/createOrUpdateMetricAlert.json" } + "Create or update an alert rule for Single Resource": { "$ref": "./examples/createOrUpdateMetricAlertSingleResource.json" }, + "Create or update an alert rule for Multiple Resource": { "$ref": "./examples/createOrUpdateMetricAlertMultipleResource.json" }, + "Create or update an alert rule on Resource group(s)": { "$ref": "./examples/createOrUpdateMetricAlertResourceGroup.json" }, + "Create or update an alert rule on Subscription ": { "$ref": "./examples/createOrUpdateMetricAlertSubscription.json" } } }, "patch": { @@ -363,6 +369,14 @@ "format": "duration", "description": "the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold." }, + "targetResourceType" :{ + "type" : "string", + "description" : "the resource type of the target resource(s) on which the alert is created/updated. Mandatory for MultipleResourceMultipleMetricCriteria." + }, + "targetResourceRegion" : { + "type" : "string", + "description" : "the region of the target resource(s) on which the alert is created/updated. Mandatory for MultipleResourceMultipleMetricCriteria." + }, "criteria": { "$ref": "#/definitions/MetricAlertCriteria", "description": "defines the specific alert criteria information." @@ -498,7 +512,8 @@ "properties": { "odata.type": { "enum": [ - "Microsoft.Azure.Monitor.SingleResourceMultipleMetricCriteria" + "Microsoft.Azure.Monitor.SingleResourceMultipleMetricCriteria", + "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria" ], "x-ms-enum": { "name": "odatatype", @@ -530,7 +545,14 @@ "description": "Specifies the metric alert criteria for a single resource that has multiple metric criteria." }, "MetricCriteria": { - "required": [ + "x-ms-discriminator-value": "StaticThresholdCriterion", + "type": "object", + "allOf": [ + { + "$ref": "#/definitions/MultiMetricCriteria" + } + ], + "required": [ "name", "metricName", "operator", @@ -606,7 +628,7 @@ }, "operator": { "type": "string", - "description": "the dimension operator." + "description": "the dimension operator. Only 'Include' and 'Exclude' are supported" }, "values": { "type": "array", @@ -617,7 +639,47 @@ } }, "description": "Specifies a metric dimension." - } + }, + "MetricAlertMultipleResourceMultipleMetricCriteria":{ + "x-ms-discriminator-value": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria", + "type": "object", + "allOf":[ + { + "$ref":"#/definitions/MetricAlertCriteria" + } + ], + "properties":{ + "allOf":{ + "type": "array", + "items":{ + "$ref":"#/definitions/MultiMetricCriteria" + }, + "description": "the list of multiple metric criteria for this 'all of' operation. " + } + }, + "description": "Speficies the metric alert criteria for multiple resource that has multiple metric criteria." + }, + "MultiMetricCriteria": { + "type": "object", + "additionalProperties": { + "type": "object" + }, + "discriminator":"criterionType", + "properties":{ + "criterionType" : { + "enum":[ + "StaticThresholdCriterion" + ], + "x-ms-enum" : { + "name" : "criterionType", + "modelAsString": true + }, + "description":" Specifies the type of threshold criteria" + } + }, + "required": ["criterionType"], + "description": "The types of conditions for a multi resource alert" + } }, "parameters": { "SubscriptionIdParameter": {