From 7df0ce599e8d6579acd109ed9f4805954304969f Mon Sep 17 00:00:00 2001 From: promoisha Date: Wed, 14 Nov 2018 07:46:31 -0800 Subject: [PATCH] Added missing PATCH operation to Api Issue resource (#4440) --- .../preview/2018-06-01-preview/apimapis.json | 121 ++++++++++++++++-- .../examples/ApiManagementUpdateApiIssue.json | 18 +++ .../stable/2018-01-01/apimapis.json | 121 ++++++++++++++++-- .../examples/ApiManagementUpdateApiIssue.json | 18 +++ 4 files changed, 258 insertions(+), 20 deletions(-) create mode 100644 specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/examples/ApiManagementUpdateApiIssue.json create mode 100644 specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/examples/ApiManagementUpdateApiIssue.json diff --git a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/apimapis.json b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/apimapis.json index 89326eeb3b1f..73019ac93c17 100644 --- a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/apimapis.json +++ b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/apimapis.json @@ -2645,6 +2645,65 @@ } } }, + "patch": { + "tags": [ + "ApiIssues" + ], + "operationId": "ApiIssue_Update", + "description": "Updates an existing issue for an API.", + "x-ms-examples": { + "ApiManagementUpdateApiIssue": { + "$ref": "./examples/ApiManagementUpdateApiIssue.json" + } + }, + "parameters": [ + { + "$ref": "./apimanagement.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "./apimanagement.json#/parameters/ServiceNameParameter" + }, + { + "$ref": "#/parameters/ApiIdParameter" + }, + { + "$ref": "#/parameters/IssueIdParameter" + }, + { + "name": "parameters", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/IssueUpdateContract" + }, + "description": "Update parameters." + }, + { + "name": "If-Match", + "in": "header", + "required": false, + "description": "ETag of the Issue Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update.", + "type": "string" + }, + { + "$ref": "./apimanagement.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./apimanagement.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "204": { + "description": "The Issue was successfully updated." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./apimanagement.json#/definitions/ErrorResponse" + } + } + } + }, "delete": { "tags": [ "ApiIssues" @@ -4341,6 +4400,16 @@ ], "description": "Issue Contract details." }, + "IssueUpdateContract": { + "properties": { + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/IssueUpdateContractProperties", + "description": "Issue entity Update contract properties." + } + }, + "description": "Issue update Parameters." + }, "IssueContractProperties": { "properties": { "title": { @@ -4351,6 +4420,47 @@ "type": "string", "description": "Text describing the issue." }, + "userId": { + "type": "string", + "description": "A resource identifier for the user created the issue." + } + }, + "required": [ + "title", + "description", + "userId" + ], + "allOf": [ + { + "$ref": "#/definitions/IssueContractBaseProperties" + } + ], + "description": "Issue contract Properties." + }, + "IssueUpdateContractProperties": { + "properties": { + "title": { + "type": "string", + "description": "The issue title." + }, + "description": { + "type": "string", + "description": "Text describing the issue." + }, + "userId": { + "type": "string", + "description": "A resource identifier for the user created the issue." + } + }, + "allOf": [ + { + "$ref": "#/definitions/IssueContractBaseProperties" + } + ], + "description": "Issue contract Update Properties." + }, + "IssueContractBaseProperties": { + "properties": { "createdDate": { "type": "string", "format": "date-time", @@ -4393,21 +4503,12 @@ ] } }, - "userId": { - "type": "string", - "description": "A resource identifier for the user created the issue." - }, "apiId": { "type": "string", "description": "A resource identifier for the API the issue was created for." } }, - "required": [ - "title", - "description", - "userId" - ], - "description": "Issue contract Properties." + "description": "Issue contract Base Properties." }, "IssueCommentCollection": { "properties": { diff --git a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/examples/ApiManagementUpdateApiIssue.json b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/examples/ApiManagementUpdateApiIssue.json new file mode 100644 index 000000000000..36f3f70fe42c --- /dev/null +++ b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2018-06-01-preview/examples/ApiManagementUpdateApiIssue.json @@ -0,0 +1,18 @@ +{ + "parameters": { + "serviceName": "apimService1", + "resourceGroupName": "rg1", + "api-version": "2018-06-01-preview", + "subscriptionId": "subid", + "issueId": "57d2ef278aa04f0ad01d6cdc", + "apiId": "57d1f7558aa04f15146d9d8a", + "parameters": { + "properties": { + "state": "closed" + } + } + }, + "responses": { + "204": { } + } + } \ No newline at end of file diff --git a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/apimapis.json b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/apimapis.json index bdedca08bd5a..16286cb719e9 100644 --- a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/apimapis.json +++ b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/apimapis.json @@ -2857,6 +2857,65 @@ } } }, + "patch": { + "tags": [ + "ApiIssues" + ], + "operationId": "ApiIssue_Update", + "description": "Updates an existing issue for an API.", + "x-ms-examples": { + "ApiManagementUpdateApiIssue": { + "$ref": "./examples/ApiManagementUpdateApiIssue.json" + } + }, + "parameters": [ + { + "$ref": "./apimanagement.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "./apimanagement.json#/parameters/ServiceNameParameter" + }, + { + "$ref": "#/parameters/ApiIdParameter" + }, + { + "$ref": "#/parameters/IssueIdParameter" + }, + { + "name": "parameters", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/IssueUpdateContract" + }, + "description": "Update parameters." + }, + { + "name": "If-Match", + "in": "header", + "required": false, + "description": "ETag of the Issue Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update.", + "type": "string" + }, + { + "$ref": "./apimanagement.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./apimanagement.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "204": { + "description": "The Issue was successfully updated." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./apimanagement.json#/definitions/ErrorResponse" + } + } + } + }, "delete": { "tags": [ "ApiIssues" @@ -4549,6 +4608,16 @@ ], "description": "Issue Contract details." }, + "IssueUpdateContract": { + "properties": { + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/IssueUpdateContractProperties", + "description": "Issue entity Update contract properties." + } + }, + "description": "Issue update Parameters." + }, "IssueContractProperties": { "properties": { "title": { @@ -4559,6 +4628,47 @@ "type": "string", "description": "Text describing the issue." }, + "userId": { + "type": "string", + "description": "A resource identifier for the user created the issue." + } + }, + "required": [ + "title", + "description", + "userId" + ], + "allOf": [ + { + "$ref": "#/definitions/IssueContractBaseProperties" + } + ], + "description": "Issue contract Properties." + }, + "IssueUpdateContractProperties": { + "properties": { + "title": { + "type": "string", + "description": "The issue title." + }, + "description": { + "type": "string", + "description": "Text describing the issue." + }, + "userId": { + "type": "string", + "description": "A resource identifier for the user created the issue." + } + }, + "allOf": [ + { + "$ref": "#/definitions/IssueContractBaseProperties" + } + ], + "description": "Issue contract Update Properties." + }, + "IssueContractBaseProperties": { + "properties": { "createdDate": { "type": "string", "format": "date-time", @@ -4601,21 +4711,12 @@ ] } }, - "userId": { - "type": "string", - "description": "A resource identifier for the user created the issue." - }, "apiId": { "type": "string", "description": "A resource identifier for the API the issue was created for." } }, - "required": [ - "title", - "description", - "userId" - ], - "description": "Issue contract Properties." + "description": "Issue contract Base Properties." }, "IssueCommentCollection": { "properties": { diff --git a/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/examples/ApiManagementUpdateApiIssue.json b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/examples/ApiManagementUpdateApiIssue.json new file mode 100644 index 000000000000..03cfa07b7ce3 --- /dev/null +++ b/specification/apimanagement/resource-manager/Microsoft.ApiManagement/stable/2018-01-01/examples/ApiManagementUpdateApiIssue.json @@ -0,0 +1,18 @@ +{ + "parameters": { + "serviceName": "apimService1", + "resourceGroupName": "rg1", + "api-version": "2018-01-01", + "subscriptionId": "subid", + "issueId": "57d2ef278aa04f0ad01d6cdc", + "apiId": "57d1f7558aa04f15146d9d8a", + "parameters": { + "properties": { + "state": "closed" + } + } + }, + "responses": { + "204": { } + } + } \ No newline at end of file