Skip to content

Commit

Permalink
Added missing PATCH operation to Api Issue resource (#4440)
Browse files Browse the repository at this point in the history
  • Loading branch information
promoisha authored and annatisch committed Nov 14, 2018
1 parent 10ec74f commit 7df0ce5
Show file tree
Hide file tree
Showing 4 changed files with 258 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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": {
Expand All @@ -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",
Expand Down Expand Up @@ -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": {
Expand Down
Original file line number Diff line number Diff line change
@@ -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": { }
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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": {
Expand All @@ -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",
Expand Down Expand Up @@ -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": {
Expand Down
Original file line number Diff line number Diff line change
@@ -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": { }
}
}

0 comments on commit 7df0ce5

Please sign in to comment.