From f23d6ffef7c0a98fea31cc73aba23175cd5b07b0 Mon Sep 17 00:00:00 2001 From: Lana Shafik Date: Mon, 17 Sep 2018 22:38:54 +0200 Subject: [PATCH] Adding app version settings APIs to swagger file. (#3850) --- .../Authoring/stable/v2.0/LUIS-Authoring.json | 99 +++++++++++++++++++ ...lGetApplicationVersionSettingsRequest.json | 19 ++++ ...dateApplicationVersionSettingsRequest.json | 23 +++++ 3 files changed, 141 insertions(+) create mode 100644 specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulGetApplicationVersionSettingsRequest.json create mode 100644 specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulUpdateApplicationVersionSettingsRequest.json diff --git a/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/LUIS-Authoring.json b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/LUIS-Authoring.json index 79cc7879007f..a1a938652257 100644 --- a/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/LUIS-Authoring.json +++ b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/LUIS-Authoring.json @@ -7472,6 +7472,91 @@ } } } + }, + "/apps/{appId}/versions/{versionId}/settings": { + "get": { + "description": "Gets the application version settings.", + "operationId": "Settings_List", + "parameters": [ + { + "$ref": "#/parameters/AppIdInPath" + }, + { + "$ref": "#/parameters/VersionIdInPath" + } + ], + "responses": { + "200": { + "description": "A list of the application version settings.", + "schema": { + "type": "array", + "items": { + "$ref": "#/definitions/AppVersionSettingObject" + } + } + }, + "default": { + "description": "Error Response.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } + } + }, + "produces": [ + "application/json" + ], + "x-ms-examples": { + "Successful Get Application Version settings request": { + "$ref": "./examples/versions/SuccessfulGetApplicationVersionSettingsRequest.json" + } + } + }, + "put": { + "description": "Updates the application version settings.", + "operationId": "Settings_Update", + "parameters": [ + { + "$ref": "#/parameters/AppIdInPath" + }, + { + "$ref": "#/parameters/VersionIdInPath" + }, + { + "name": "listOfAppVersionSettingObject", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/AppVersionSettingObject" + }, + "description": "A list of the updated application version settings." + } + ], + "consumes": [ + "application/json" + ], + "responses": { + "200": { + "description": "Successful operation.", + "schema": { + "$ref": "#/definitions/OperationStatus" + } + }, + "default": { + "description": "Error Response.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } + } + }, + "produces": [ + "application/json" + ], + "x-ms-examples": { + "Successful Update Application Version settings request": { + "$ref": "./examples/versions/SuccessfulUpdateApplicationVersionSettingsRequest.json" + } + } + } } }, "definitions": { @@ -9723,6 +9808,20 @@ "type": "string" } } + }, + "AppVersionSettingObject": { + "description": "Object model of an application version setting.", + "type": "object", + "properties": { + "name": { + "description": "The application version setting name.", + "type": "string" + }, + "value": { + "description": "The application version setting value.", + "type": "string" + } + } } }, "parameters": { diff --git a/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulGetApplicationVersionSettingsRequest.json b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulGetApplicationVersionSettingsRequest.json new file mode 100644 index 000000000000..7eee4c9f5977 --- /dev/null +++ b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulGetApplicationVersionSettingsRequest.json @@ -0,0 +1,19 @@ +{ + "parameters": { + "Endpoint": "{Endpoint}", + "Ocp-Apim-Subscription-Key": "00000000000000000000000000000000", + "appId": "363187f1-c573-46b3-bc4c-ae01d686e68e", + "versionId": "0.1" + }, + "responses": { + "200": { + "headers": {}, + "body": [ + { + "name": "UseNegativeSampling", + "value": "false" + } + ] + } + } +} \ No newline at end of file diff --git a/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulUpdateApplicationVersionSettingsRequest.json b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulUpdateApplicationVersionSettingsRequest.json new file mode 100644 index 000000000000..4054da4022ae --- /dev/null +++ b/specification/cognitiveservices/data-plane/LUIS/Authoring/stable/v2.0/examples/versions/SuccessfulUpdateApplicationVersionSettingsRequest.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "Endpoint": "{Endpoint}", + "Ocp-Apim-Subscription-Key": "00000000000000000000000000000000", + "appId": "363187f1-c573-46b3-bc4c-ae01d686e68e", + "versionId": "0.1", + "listOfAppVersionSettingObject": [ + { + "name": "UseNegativeSampling", + "value": "false" + } + ] + }, + "responses": { + "200": { + "headers": {}, + "body": { + "code": "Success", + "message": "Operation Successful" + } + } + } +} \ No newline at end of file