From f1340f645111671f4448ece2b718e867a251d6ff Mon Sep 17 00:00:00 2001 From: ranisha2 Date: Thu, 24 Jan 2019 15:17:11 +0200 Subject: [PATCH 1/3] Add Disable/Enable recommended sensitivity label APIs Add Disable/Enable recommended sensitivity label APIs --- ...ommendedColumnSensitivityLabelDisable.json | 15 +++ ...commendedColumnSensitivityLabelEnable.json | 15 +++ .../2017-03-01-preview/sensitivityLabels.json | 115 +++++++++++++--- ...ommendedColumnSensitivityLabelDisable.json | 15 +++ ...commendedColumnSensitivityLabelEnable.json | 15 +++ .../managedDatabaseSensitivityLabels.json | 125 +++++++++++++++--- 6 files changed, 263 insertions(+), 37 deletions(-) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json new file mode 100644 index 000000000000..ac4fd0a7faba --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json @@ -0,0 +1,15 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "myRG", + "serverName": "myServer", + "databaseName": "myDatabase", + "schemaName": "dbo", + "tableName": "myTable", + "columnName": "myColumn", + "api-version": "2017-03-01-preview" + }, + "responses": { + "200": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json new file mode 100644 index 000000000000..ac4fd0a7faba --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json @@ -0,0 +1,15 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "myRG", + "serverName": "myServer", + "databaseName": "myDatabase", + "schemaName": "dbo", + "tableName": "myTable", + "columnName": "myColumn", + "api-version": "2017-03-01-preview" + }, + "responses": { + "200": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json index 61fb8763d07b..517e3d52f1e8 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json @@ -86,6 +86,13 @@ { "$ref": "#/parameters/DatabaseNameParameter" }, + { + "name": "showDisabledRecommendations", + "in": "query", + "description": "Specifies whether to return disabled recommendations or not.", + "required": false, + "type": "boolean" + }, { "name": "$filter", "in": "query", @@ -122,13 +129,13 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/sensitivityLabels": { - "get": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/enable": { + "post": { "tags": [ "SensitivityLabels" ], - "description": "Gets the sensitivity labels of a given database", - "operationId": "SensitivityLabels_ListByDatabase", + "description": "Enables sensitivity recommendations on a given column", + "operationId": "SensitivityLabels_Enable", "parameters": [ { "$ref": "#/parameters/ResourceGroupParameter" @@ -140,10 +147,24 @@ "$ref": "#/parameters/DatabaseNameParameter" }, { - "name": "$filter", - "in": "query", - "description": "An OData filter expression that filters elements in the collection.", - "required": false, + "name": "schemaName", + "in": "path", + "description": "The name of the schema.", + "required": true, + "type": "string" + }, + { + "name": "tableName", + "in": "path", + "description": "The name of the table.", + "required": true, + "type": "string" + }, + { + "name": "columnName", + "in": "path", + "description": "The name of the column.", + "required": true, "type": "string" }, { @@ -155,22 +176,75 @@ ], "responses": { "200": { - "description": "Successfully retrieved the sensitivity labels.", - "schema": { - "$ref": "#/definitions/SensitivityLabelListResult" - } + "description": "Successfully enabled the sensitivity recommendations on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 400 SensitivityLabelsInvalidODataQuery - The specified OData query is either not valid or not supported\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, - "x-ms-odata": "#/definitions/SensitivityLabel", - "x-ms-pageable": { - "nextLinkName": "nextLink" + "x-ms-examples": { + "Enables sensitivity recommendations on a given column": { + "$ref": "./examples/RecommendedColumnSensitivityLabelEnable.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/disable": { + "post": { + "tags": [ + "SensitivityLabels" + ], + "description": "Disables sensitivity recommendations on a given column", + "operationId": "SensitivityLabels_Disable", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ServerNameParameter" + }, + { + "$ref": "#/parameters/DatabaseNameParameter" + }, + { + "name": "schemaName", + "in": "path", + "description": "The name of the schema.", + "required": true, + "type": "string" + }, + { + "name": "tableName", + "in": "path", + "description": "The name of the table.", + "required": true, + "type": "string" + }, + { + "name": "columnName", + "in": "path", + "description": "The name of the column.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully disabled the sensitivity recommendation on the given column." + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + } }, "x-ms-examples": { - "Gets the current and recommended sensitivity labels of a given database": { - "$ref": "./examples/SensitivityLabelsListByDatabase.json" + "Disables sensitivity recommendations on a given column": { + "$ref": "./examples/RecommendedColumnSensitivityLabelDisable.json" } } } @@ -436,6 +510,11 @@ "informationTypeId": { "description": "The information type ID.", "type": "string" + }, + "isDisabled": { + "description": "Applicable for recommended sensitivity label source only. Specifies whether the recommended sensitivity label is disabled or not.", + "type": "boolean", + "readOnly": true } } }, diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json new file mode 100644 index 000000000000..37ea55472a3b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json @@ -0,0 +1,15 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "myRG", + "managedInstanceName": "myManagedInstanceName", + "databaseName": "myDatabase", + "schemaName": "dbo", + "tableName": "myTable", + "columnName": "myColumn", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json new file mode 100644 index 000000000000..37ea55472a3b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json @@ -0,0 +1,15 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "myRG", + "managedInstanceName": "myManagedInstanceName", + "databaseName": "myDatabase", + "schemaName": "dbo", + "tableName": "myTable", + "columnName": "myColumn", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json index 9ca6c46329f5..fdce51861401 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json @@ -168,7 +168,7 @@ } }, "default": { - "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 400 SensitivityLabelSourceNameNotSupported - The specified sensitivity label source is not valid\n\n * 400 InvalidSensitivityLabelResource - The specified sensitivity label resource is not valid\n\n * 400 SensitivityLabelLabelNameAndInfoTypeNotProvided - At least one of LabelName and InformationType must be specified\n\n * 400 LabelNameTooLong - Label name cannot exceed {0} characters\n\n * 400 InformationTypeTooLong - Information type cannot exceed {0} characters\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance.\n\n * 404 SensitivityLabelsLabelNotFound - The specified sensitivity label could not be found\n\n * 501 SensitivityLabelRecommendedSourceNameNotSupported - 'Recommended' sensitivity label source is not supported yet" + "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 400 SensitivityLabelSourceNameNotSupported - The specified sensitivity label source is not valid\n\n * 400 InvalidSensitivityLabelResource - The specified sensitivity label resource is not valid\n\n * 400 SensitivityLabelLabelNameAndInfoTypeNotProvided - At least one of LabelName and InformationType must be specified\n\n * 400 LabelNameTooLong - Label name cannot exceed {0} characters\n\n * 400 InformationTypeTooLong - Information type cannot exceed {0} characters\n\n * 400 LabelIdMustBeGuid - Label ID must be a GUID\n\n * 400 InformationTypeIdMustBeGuid - Information type ID must be a GUID\n\n * 400 LabelMissing - Label is missing\n\n * 400 InformationTypeMissing - Information Type is missing\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance.\n\n * 404 SensitivityLabelsLabelNotFound - The specified sensitivity label could not be found\n\n * 501 SensitivityLabelRecommendedSourceNameNotSupported - 'Recommended' sensitivity label source is not supported yet" }, "201": { "description": "Successfully created the sensitivity label.", @@ -256,13 +256,13 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/sensitivityLabels": { - "get": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/disable": { + "post": { "tags": [ "ManagedDatabaseSensitivityLabels" ], - "description": "Gets the sensitivity labels of a given database", - "operationId": "ManagedDatabaseSensitivityLabels_ListByDatabase", + "description": "Disables sensitivity recommendations on a given column", + "operationId": "ManagedDatabaseSensitivityLabels_DisableRecommendation", "parameters": [ { "$ref": "#/parameters/ResourceGroupParameter" @@ -274,10 +274,24 @@ "$ref": "#/parameters/DatabaseNameParameter" }, { - "name": "$filter", - "in": "query", - "description": "An OData filter expression that filters elements in the collection.", - "required": false, + "name": "schemaName", + "in": "path", + "description": "The name of the schema.", + "required": true, + "type": "string" + }, + { + "name": "tableName", + "in": "path", + "description": "The name of the table.", + "required": true, + "type": "string" + }, + { + "name": "columnName", + "in": "path", + "description": "The name of the column.", + "required": true, "type": "string" }, { @@ -289,22 +303,75 @@ ], "responses": { "200": { - "description": "Successfully retrieved the sensitivity labels.", - "schema": { - "$ref": "#/definitions/SensitivityLabelListResult" - } + "description": "Successfully disabled the sensitivity recommendations on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 400 SensitivityLabelsInvalidODataQuery - The specified OData query is either not valid or not supported\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, - "x-ms-odata": "#/definitions/SensitivityLabel", - "x-ms-pageable": { - "nextLinkName": "nextLink" + "x-ms-examples": { + "Disables the sensitivity recommendations on a given column": { + "$ref": "./examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/enable": { + "post": { + "tags": [ + "ManagedDatabaseSensitivityLabels" + ], + "description": "Enables sensitivity recommendations on a given column", + "operationId": "ManagedDatabaseSensitivityLabels_EnableRecommendation", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/DatabaseNameParameter" + }, + { + "name": "schemaName", + "in": "path", + "description": "The name of the schema.", + "required": true, + "type": "string" + }, + { + "name": "tableName", + "in": "path", + "description": "The name of the table.", + "required": true, + "type": "string" + }, + { + "name": "columnName", + "in": "path", + "description": "The name of the column.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully enabled the sensitivity recommendations on the given column." + }, + "default": { + "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + } }, "x-ms-examples": { - "Gets the current and recommended sensitivity labels of a given database": { - "$ref": "./examples/ManagedDatabaseSensitivityLabelsListByDatabase.json" + "Enables the sensitivity recommendations on a given column": { + "$ref": "./examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json" } } } @@ -379,6 +446,13 @@ { "$ref": "#/parameters/DatabaseNameParameter" }, + { + "name": "showDisabledRecommendations", + "in": "query", + "description": "Specifies whether to return disabled recommendations or not.", + "required": false, + "type": "boolean" + }, { "name": "$filter", "in": "query", @@ -425,9 +499,22 @@ "description": "The label name.", "type": "string" }, + "labelId": { + "description": "The label ID.", + "type": "string" + }, "informationType": { "description": "The information type.", "type": "string" + }, + "informationTypeId": { + "description": "The information type ID.", + "type": "string" + }, + "isDisabled": { + "description": "Applicable for recommended sensitivity label source only. Specifies whether the recommended sensitivity label is disabled or not.", + "type": "boolean", + "readOnly": true } } }, From 6819e90e995750f4b4262bdf60fa9cbefbb0c054 Mon Sep 17 00:00:00 2001 From: ranisha2 Date: Mon, 28 Jan 2019 20:01:45 +0200 Subject: [PATCH 2/3] SensitivityLabels - Update includeDisabledRecommendations parameter name and update descriptions --- .../2017-03-01-preview/sensitivityLabels.json | 12 ++++++------ .../managedDatabaseSensitivityLabels.json | 8 ++++---- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json index 517e3d52f1e8..567729b0b60c 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json @@ -87,9 +87,9 @@ "$ref": "#/parameters/DatabaseNameParameter" }, { - "name": "showDisabledRecommendations", + "name": "includeDisabledRecommendations", "in": "query", - "description": "Specifies whether to return disabled recommendations or not.", + "description": "Specifies whether to include disabled recommendations or not.", "required": false, "type": "boolean" }, @@ -134,8 +134,8 @@ "tags": [ "SensitivityLabels" ], - "description": "Enables sensitivity recommendations on a given column", - "operationId": "SensitivityLabels_Enable", + "description": "Enables sensitivity recommendations on a given column (recommendations are enabled by default on all columns)", + "operationId": "SensitivityLabels_EnableRecommendation", "parameters": [ { "$ref": "#/parameters/ResourceGroupParameter" @@ -195,7 +195,7 @@ "SensitivityLabels" ], "description": "Disables sensitivity recommendations on a given column", - "operationId": "SensitivityLabels_Disable", + "operationId": "SensitivityLabels_DisableRecommendation", "parameters": [ { "$ref": "#/parameters/ResourceGroupParameter" @@ -512,7 +512,7 @@ "type": "string" }, "isDisabled": { - "description": "Applicable for recommended sensitivity label source only. Specifies whether the recommended sensitivity label is disabled or not.", + "description": "Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.", "type": "boolean", "readOnly": true } diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json index fdce51861401..e66fc480061a 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json @@ -321,7 +321,7 @@ "tags": [ "ManagedDatabaseSensitivityLabels" ], - "description": "Enables sensitivity recommendations on a given column", + "description": "Enables sensitivity recommendations on a given column (recommendations are enabled by default on all columns)", "operationId": "ManagedDatabaseSensitivityLabels_EnableRecommendation", "parameters": [ { @@ -447,9 +447,9 @@ "$ref": "#/parameters/DatabaseNameParameter" }, { - "name": "showDisabledRecommendations", + "name": "includeDisabledRecommendations", "in": "query", - "description": "Specifies whether to return disabled recommendations or not.", + "description": "Specifies whether to include disabled recommendations or not.", "required": false, "type": "boolean" }, @@ -512,7 +512,7 @@ "type": "string" }, "isDisabled": { - "description": "Applicable for recommended sensitivity label source only. Specifies whether the recommended sensitivity label is disabled or not.", + "description": "Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.", "type": "boolean", "readOnly": true } From 11bd93aa708e84149b587a314932a87f0994dc23 Mon Sep 17 00:00:00 2001 From: ranisha2 Date: Wed, 27 Feb 2019 15:43:32 +0200 Subject: [PATCH 3/3] Update sensitivity labels enable/disable APIs --- ...ommendedColumnSensitivityLabelDisable.json | 1 + ...commendedColumnSensitivityLabelEnable.json | 1 + .../2017-03-01-preview/sensitivityLabels.json | 34 ++++++++++++++++--- ...ommendedColumnSensitivityLabelDisable.json | 1 + ...commendedColumnSensitivityLabelEnable.json | 1 + .../managedDatabaseSensitivityLabels.json | 34 ++++++++++++++++--- 6 files changed, 64 insertions(+), 8 deletions(-) diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json index ac4fd0a7faba..752baa5d065b 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelDisable.json @@ -7,6 +7,7 @@ "schemaName": "dbo", "tableName": "myTable", "columnName": "myColumn", + "sensitivityLabelSource": "recommended", "api-version": "2017-03-01-preview" }, "responses": { diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json index ac4fd0a7faba..752baa5d065b 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/examples/RecommendedColumnSensitivityLabelEnable.json @@ -7,6 +7,7 @@ "schemaName": "dbo", "tableName": "myTable", "columnName": "myColumn", + "sensitivityLabelSource": "recommended", "api-version": "2017-03-01-preview" }, "responses": { diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json index 1fc4f62dcbf7..c82a61199050 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2017-03-01-preview/sensitivityLabels.json @@ -135,7 +135,7 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/enable": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/enable": { "post": { "tags": [ "SensitivityLabels" @@ -173,6 +173,19 @@ "required": true, "type": "string" }, + { + "name": "sensitivityLabelSource", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "recommended" + ], + "x-ms-enum": { + "name": "SensitivityLabelSource", + "modelAsString": false + } + }, { "$ref": "#/parameters/SubscriptionIdParameter" }, @@ -185,7 +198,7 @@ "description": "Successfully enabled the sensitivity recommendations on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, "x-ms-examples": { @@ -195,7 +208,7 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/disable": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/disable": { "post": { "tags": [ "SensitivityLabels" @@ -233,6 +246,19 @@ "required": true, "type": "string" }, + { + "name": "sensitivityLabelSource", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "recommended" + ], + "x-ms-enum": { + "name": "SensitivityLabelSource", + "modelAsString": false + } + }, { "$ref": "#/parameters/SubscriptionIdParameter" }, @@ -245,7 +271,7 @@ "description": "Successfully disabled the sensitivity recommendation on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 400 DatawarehouseDatabaseIsDeactivated - Could not execute Data Classification operation because the database is paused. Please resume it.\n\n * 404 SensitivityLabelsColumnNotFound - The specified column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, "x-ms-examples": { diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json index 37ea55472a3b..7c5ee1962808 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelDisable.json @@ -7,6 +7,7 @@ "schemaName": "dbo", "tableName": "myTable", "columnName": "myColumn", + "sensitivityLabelSource": "recommended", "api-version": "2018-06-01-preview" }, "responses": { diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json index 37ea55472a3b..7c5ee1962808 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedDatabaseRecommendedColumnSensitivityLabelEnable.json @@ -7,6 +7,7 @@ "schemaName": "dbo", "tableName": "myTable", "columnName": "myColumn", + "sensitivityLabelSource": "recommended", "api-version": "2018-06-01-preview" }, "responses": { diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json index cc139d10be53..5b06a8876a12 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json @@ -256,7 +256,7 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/disable": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/disable": { "post": { "tags": [ "ManagedDatabaseSensitivityLabels" @@ -294,6 +294,19 @@ "required": true, "type": "string" }, + { + "name": "sensitivityLabelSource", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "recommended" + ], + "x-ms-enum": { + "name": "SensitivityLabelSource", + "modelAsString": false + } + }, { "$ref": "#/parameters/SubscriptionIdParameter" }, @@ -306,7 +319,7 @@ "description": "Successfully disabled the sensitivity recommendations on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, "x-ms-examples": { @@ -316,7 +329,7 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/recommended/enable": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/enable": { "post": { "tags": [ "ManagedDatabaseSensitivityLabels" @@ -354,6 +367,19 @@ "required": true, "type": "string" }, + { + "name": "sensitivityLabelSource", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "recommended" + ], + "x-ms-enum": { + "name": "SensitivityLabelSource", + "modelAsString": false + } + }, { "$ref": "#/parameters/SubscriptionIdParameter" }, @@ -366,7 +392,7 @@ "description": "Successfully enabled the sensitivity recommendations on the given column." }, "default": { - "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified schema/table/column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." + "description": "*** Error Responses: ***\n\n * 404 SensitivityLabelsColumnNotFound - The specified column could not be found\n\n * 404 SubscriptionDoesNotHaveServer - The requested server was not found\n\n * 404 DatabaseDoesNotExist - User has specified a database name that does not exist on this server instance." } }, "x-ms-examples": {