From 5a6c783eecd38a114acd855c3c57022ca3cc56bd Mon Sep 17 00:00:00 2001 From: Todd Moscinski Date: Tue, 3 Aug 2021 09:15:15 -0700 Subject: [PATCH] Changing error response to use common definition --- .../stable/2021-07-01/reservations.json | 86 ++++--------------- 1 file changed, 18 insertions(+), 68 deletions(-) diff --git a/specification/reservations/resource-manager/Microsoft.Capacity/stable/2021-07-01/reservations.json b/specification/reservations/resource-manager/Microsoft.Capacity/stable/2021-07-01/reservations.json index 0d1650740891..8d64c4405100 100644 --- a/specification/reservations/resource-manager/Microsoft.Capacity/stable/2021-07-01/reservations.json +++ b/specification/reservations/resource-manager/Microsoft.Capacity/stable/2021-07-01/reservations.json @@ -65,7 +65,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -110,7 +110,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -147,7 +147,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -184,7 +184,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -221,7 +221,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -271,7 +271,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -316,7 +316,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -366,7 +366,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -416,7 +416,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -456,7 +456,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -499,7 +499,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -545,7 +545,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -588,7 +588,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -625,7 +625,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -684,7 +684,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -743,7 +743,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -815,7 +815,7 @@ "default": { "description": "Error response describing why the operation failed.", "schema": { - "$ref": "#/definitions/ErrorResponse" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } }, @@ -858,7 +858,7 @@ "default": { "description": "Unexpected error", "schema": { - "$ref": "#/definitions/Error" + "$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse" } } } @@ -2291,56 +2291,6 @@ } } }, - "ErrorResponse": { - "description": "Error response indicates that the service is not able to process the incoming request. The reason is provided in the error message.", - "type": "object", - "properties": { - "error": { - "description": "The details of the error.", - "$ref": "#/definitions/ErrorDetails" - } - } - }, - "Error": { - "type": "object", - "properties": { - "error": { - "$ref": "#/definitions/ExtendedErrorInfo" - } - } - }, - "ExtendedErrorInfo": { - "type": "object", - "properties": { - "code": { - "$ref": "#/definitions/ErrorResponseCode" - }, - "message": { - "type": "string" - } - } - }, - "ErrorDetails": { - "type": "object", - "description": "The details of the error.", - "properties": { - "code": { - "description": "Error code.", - "type": "string", - "readOnly": true - }, - "message": { - "description": "Error message indicating why the operation failed.", - "type": "string", - "readOnly": true - }, - "target": { - "description": "The target of the particular error.", - "type": "string", - "readOnly": true - } - } - }, "AppliedReservations": { "type": "object", "properties": {