diff --git a/specification/monitor/resource-manager/Microsoft.Insights/stable/2016-03-01/alertRules_API.json b/specification/monitor/resource-manager/Microsoft.Insights/stable/2016-03-01/alertRules_API.json index 0e7576026b5d..bebf3d9d1c0c 100644 --- a/specification/monitor/resource-manager/Microsoft.Insights/stable/2016-03-01/alertRules_API.json +++ b/specification/monitor/resource-manager/Microsoft.Insights/stable/2016-03-01/alertRules_API.json @@ -36,7 +36,7 @@ } }, "paths": { - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/microsoft.insights/alertrules/{ruleName}": { + "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Insights/alertrules/{ruleName}": { "put": { "description": "Creates or updates a classic metric alert rule.", "tags": [ @@ -118,6 +118,12 @@ }, "200": { "description": "Successful request to delete an alert rule" + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } } }, "x-ms-examples": { @@ -152,6 +158,12 @@ "schema": { "$ref": "#/definitions/AlertRuleResource" } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } } }, "x-ms-examples": { @@ -187,12 +199,6 @@ } ], "responses": { - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/ErrorResponse" - } - }, "200": { "description": "Successful request to update an alert rule", "schema": { @@ -204,6 +210,12 @@ "schema": { "$ref": "#/definitions/AlertRuleResource" } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } } }, "x-ms-examples": { @@ -213,7 +225,7 @@ } } }, - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/microsoft.insights/alertrules": { + "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Insights/alertrules": { "get": { "tags": [ "AlertRules" @@ -237,6 +249,12 @@ "schema": { "$ref": "#/definitions/AlertRuleResourceCollection" } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } } }, "x-ms-pageable": { @@ -249,7 +267,7 @@ } } }, - "/subscriptions/{subscriptionId}/providers/microsoft.insights/alertrules": { + "/subscriptions/{subscriptionId}/providers/Microsoft.Insights/alertrules": { "get": { "tags": [ "AlertRules" @@ -270,6 +288,12 @@ "schema": { "$ref": "#/definitions/AlertRuleResourceCollection" } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } } }, "x-ms-pageable": { diff --git a/specification/monitor/resource-manager/readme.md b/specification/monitor/resource-manager/readme.md index c49b8742f138..14f9381db5db 100644 --- a/specification/monitor/resource-manager/readme.md +++ b/specification/monitor/resource-manager/readme.md @@ -599,6 +599,13 @@ directive: - suppress: R4007 from: metricBaselines_API.json reason: 'Updating the error response to the new format would be a breaking change.' + - suppress: R4007 + from: alertRules_API.json + reason: 'Updating the error response to the new format would be a breaking change.' + - suppress: OBJECT_ADDITIONAL_PROPERTIES + from: alertRules_API.json + where: $.definitions.AlertRuleResource + reason: 'Action is expected to receive a subclass of Resource' - suppress: OBJECT_ADDITIONAL_PROPERTIES from: metricAlert_API.json where: $.definitions.MetricAlertResource