From 1e5c20f0cb60e1730de28ac7e727c28b790cba6e Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 12:51:59 +0300 Subject: [PATCH 01/19] Add Sentinel onboarding states resource type --- .../2021-03-01-preview/OnboardingStates.json | 256 ++++++++++++++++++ .../CreateSentinelOnboardingState.json | 25 ++ .../DeleteSentinelOnboardingState.json | 14 + .../GetSentinelOnboardingState.json | 17 ++ 4 files changed, 312 insertions(+) create mode 100644 specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json create mode 100644 specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json create mode 100644 specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json create mode 100644 specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json new file mode 100644 index 000000000000..75c5bbadf86b --- /dev/null +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -0,0 +1,256 @@ +{ + "swagger": "2.0", + "info": { + "title": "Security Insights", + "description": "API spec for Microsoft.SecurityInsights (Azure Security Insights) resource provider", + "version": "2021-03-01-preview" + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ], + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "flow": "implicit", + "description": "Azure Active Directory OAuth2 Flow", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + }, + "paths": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{operationalInsightsResourceProvider}/workspaces/{workspaceName}/providers/Microsoft.SecurityInsights/onboardingStates/{sentinelOnboardingStateName}": { + "get": { + "x-ms-examples": { + "Get Sentinel onboarding state": { + "$ref": "./examples/onboardingStates/GetSentinelOnboardingState.json" + } + }, + "tags": [ + "SentinelOnboardingState" + ], + "description": "Get Sentinel onboarding state", + "operationId": "SentinelOnboardingState_Get", + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/OperationalInsightsResourceProvider" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/WorkspaceName" + }, + { + "$ref": "#/parameters/SentinelOnboardingStateName" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SentinelOnboardingState" + } + }, + "default": { + "description": "Error in getting the Sentinel onboarding state", + "schema": { + "$ref": "../../../common/1.0/types.json#/definitions/CloudError" + } + } + } + }, + "put": { + "x-ms-examples": { + "Create Sentinel Defintion": { + "$ref": "./examples/onboardingStates/CreateSentinelOnboardingState.json" + } + }, + "tags": [ + "SentinelOnboardingState" + ], + "description": "Create Sentinel onboarding state", + "operationId": "SentinelOnboardingState_Update", + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/OperationalInsightsResourceProvider" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/WorkspaceName" + }, + { + "$ref": "#/parameters/SentinelOnboardingStateName" + }, + { + "$ref": "#/parameters/SentinelOnboardingStateParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SentinelOnboardingState" + } + }, + "201": { + "description": "Created", + "schema": { + "$ref": "#/definitions/SentinelOnboardingState" + } + }, + "default": { + "description": "Error in creating the Sentinel onboarding state", + "schema": { + "$ref": "../../../common/1.0/types.json#/definitions/CloudError" + } + } + } + }, + "delete": { + "x-ms-examples": { + "Delete Sentinel onboarding state": { + "$ref": "./examples/onboardingStates/DeleteSentinelOnboardingState.json" + } + }, + "tags": [ + "SentinelOnboardingState" + ], + "description": "Delete Sentinel onboarding state", + "operationId": "SentinelOnboardingState_Delete", + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/OperationalInsightsResourceProvider" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/WorkspaceName" + }, + { + "$ref": "#/parameters/SentinelOnboardingStateName" + } + ], + "responses": { + "200": { + "description": "OK" + }, + "204": { + "description": "No Content" + }, + "default": { + "description": "Error in deleting the Sentinel onboarding state", + "schema": { + "$ref": "../../../common/1.0/types.json#/definitions/CloudError" + } + } + } + } + } + }, + "definitions": { + "SentinelOnboardingState": { + "description": "Sentinel onboarding state", + "properties": { + "customerManagedKey": { + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" + } + }, + "type": "object" + } + }, + "parameters": { + "SubscriptionId": { + "description": "Azure subscription ID", + "in": "path", + "name": "subscriptionId", + "pattern": "^[0-9A-Fa-f]{8}-([0-9A-Fa-f]{4}-){3}[0-9A-Fa-f]{12}$", + "required": true, + "type": "string" + }, + "ResourceGroupName": { + "description": "The name of the resource group within the user's subscription. The name is case insensitive.", + "in": "path", + "maxLength": 90, + "minLength": 1, + "name": "resourceGroupName", + "pattern": "^[-\\w\\._\\(\\)]+$", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "WorkspaceName": { + "description": "The name of the workspace.", + "in": "path", + "name": "workspaceName", + "maxLength": 90, + "minLength": 1, + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "OperationalInsightsResourceProvider": { + "description": "The namespace of workspaces resource provider- Microsoft.OperationalInsights.", + "in": "path", + "name": "operationalInsightsResourceProvider", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "SentinelOnboardingStateName": { + "description": "The Sentinel onboarding state name. Supports - default", + "in": "path", + "name": "sentinelOnboardingStateName", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "SentinelOnboardingStateParameter": { + "description": "The Sentinel onboarding state parameter", + "in": "body", + "name": "sentinelOnboardingStateParameter", + "required": false, + "schema": { + "$ref": "#/definitions/SentinelOnboardingState" + }, + "x-ms-parameter-location": "method" + } + } +} \ No newline at end of file diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json new file mode 100644 index 000000000000..7825c988fe2b --- /dev/null +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -0,0 +1,25 @@ +{ + "parameters": { + "api-version": "2021-03-01-preview", + "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", + "resourceGroupName": "myRg", + "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", + "SentinelOnboardingStateName": "default", + "SentinelOnboardingStateParameter": { + "customerManagedKey": false + } + }, + "responses": { + "200": { + "body": { + "customerManagedKey": false + } + }, + "201": { + "body": { + "customerManagedKey": false + } + } + } +} \ No newline at end of file diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json new file mode 100644 index 000000000000..b2902568fc6d --- /dev/null +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json @@ -0,0 +1,14 @@ +{ + "parameters": { + "api-version": "2021-03-01-preview", + "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", + "resourceGroupName": "myRg", + "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", + "SentinelOnboardingStateName": "default" + }, + "responses": { + "200": {}, + "204": {} + } +} \ No newline at end of file diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json new file mode 100644 index 000000000000..09d30d7b624f --- /dev/null +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json @@ -0,0 +1,17 @@ +{ + "parameters": { + "api-version": "2021-03-01-preview", + "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", + "resourceGroupName": "myRg", + "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", + "SentinelOnboardingStateName": "default" + }, + "responses": { + "200": { + "body": { + "customerManagedKey": false + } + } + } +} \ No newline at end of file From 4bd78ac008cecc9ef585d9d9fe9eba442b04b976 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 12:56:45 +0300 Subject: [PATCH 02/19] Fix param name --- .../onboardingStates/CreateSentinelOnboardingState.json | 4 ++-- .../onboardingStates/DeleteSentinelOnboardingState.json | 2 +- .../examples/onboardingStates/GetSentinelOnboardingState.json | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index 7825c988fe2b..287831f26736 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -5,8 +5,8 @@ "resourceGroupName": "myRg", "workspaceName": "myWorkspace", "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", - "SentinelOnboardingStateName": "default", - "SentinelOnboardingStateParameter": { + "sentinelOnboardingStateName": "default", + "sentinelOnboardingStateParameter": { "customerManagedKey": false } }, diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json index b2902568fc6d..ac1bdf6134c7 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json @@ -5,7 +5,7 @@ "resourceGroupName": "myRg", "workspaceName": "myWorkspace", "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", - "SentinelOnboardingStateName": "default" + "sentinelOnboardingStateName": "default" }, "responses": { "200": {}, diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json index 09d30d7b624f..3ee728db92cb 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json @@ -5,7 +5,7 @@ "resourceGroupName": "myRg", "workspaceName": "myWorkspace", "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", - "SentinelOnboardingStateName": "default" + "sentinelOnboardingStateName": "default" }, "responses": { "200": { From c1aed980c2bfc01b8e79fea5df36b66fb99a4e05 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 13:20:19 +0300 Subject: [PATCH 03/19] Fix Avocado --- specification/securityinsights/resource-manager/readme.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/specification/securityinsights/resource-manager/readme.md b/specification/securityinsights/resource-manager/readme.md index 2e3d16cc64ba..677cbaf22d70 100644 --- a/specification/securityinsights/resource-manager/readme.md +++ b/specification/securityinsights/resource-manager/readme.md @@ -52,12 +52,17 @@ These settings apply only when `--tag=package-2021-03-preview-only` is specified ```yaml $(tag) == 'package-2021-03-preview-only' input-file: - Microsoft.SecurityInsights/preview/2021-03-01-preview/Settings.json +- Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json - Microsoft.SecurityInsights/preview/2021-03-01-preview/operations.json directive: - suppress: R4017 from: Microsoft.SecurityInsights/preview/2021-03-01-preview/Settings.json where: $.definitions.Settings - reason: The Setting does not support list by subscription. It's not a top-level resource. To get the Watchlist, we should have a subscription as well as a resource group and Log Analytics workspace. + reason: The Setting does not support list by subscription. It's not a top-level resource. To get the Setting, we should have a subscription as well as a resource group and Log Analytics workspace. + - suppress: R4017 + from: Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json + where: $.definitions.OnboardingStates + reason: The SentinelOnboardingState does not support list by subscription. It's not a top-level resource. To get the SentinelOnboardingState, we should have a subscription as well as a resource group and Log Analytics workspace. ``` --- From ee76cda2b4b6304ee0620c90cc7434698fa51d38 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 13:26:58 +0300 Subject: [PATCH 04/19] Fix spell check --- .../preview/2021-03-01-preview/OnboardingStates.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 75c5bbadf86b..fe2ebbc9cee3 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -83,7 +83,7 @@ }, "put": { "x-ms-examples": { - "Create Sentinel Defintion": { + "Create Sentinel onboarding state": { "$ref": "./examples/onboardingStates/CreateSentinelOnboardingState.json" } }, From 744997ddc9f16c477d29c2e7811d58cecd79665a Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 13:30:50 +0300 Subject: [PATCH 05/19] Fix prettier --- .../preview/2021-03-01-preview/OnboardingStates.json | 2 +- .../onboardingStates/CreateSentinelOnboardingState.json | 2 +- .../onboardingStates/DeleteSentinelOnboardingState.json | 2 +- .../examples/onboardingStates/GetSentinelOnboardingState.json | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index fe2ebbc9cee3..e11971484ddb 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -253,4 +253,4 @@ "x-ms-parameter-location": "method" } } -} \ No newline at end of file +} diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index 287831f26736..99c759c0b2e0 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -22,4 +22,4 @@ } } } -} \ No newline at end of file +} diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json index ac1bdf6134c7..f35e9c9c2e78 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/DeleteSentinelOnboardingState.json @@ -11,4 +11,4 @@ "200": {}, "204": {} } -} \ No newline at end of file +} diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json index 3ee728db92cb..a80f222b4aa1 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json @@ -14,4 +14,4 @@ } } } -} \ No newline at end of file +} From f8a0b944175a923ddf21f57041dd3b20e4e93f65 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 14:14:20 +0300 Subject: [PATCH 06/19] Fix LintDiff --- .../2021-03-01-preview/OnboardingStates.json | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index e11971484ddb..f462d0f4c2e8 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -42,7 +42,7 @@ } }, "tags": [ - "SentinelOnboardingState" + "SentinelOnboardingStates" ], "description": "Get Sentinel onboarding state", "operationId": "SentinelOnboardingState_Get", @@ -88,10 +88,10 @@ } }, "tags": [ - "SentinelOnboardingState" + "SentinelOnboardingStates" ], "description": "Create Sentinel onboarding state", - "operationId": "SentinelOnboardingState_Update", + "operationId": "SentinelOnboardingState_Create", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" @@ -143,7 +143,7 @@ } }, "tags": [ - "SentinelOnboardingState" + "SentinelOnboardingStates" ], "description": "Delete Sentinel onboarding state", "operationId": "SentinelOnboardingState_Delete", @@ -186,6 +186,11 @@ }, "definitions": { "SentinelOnboardingState": { + "allOf": [ + { + "$ref": "../../../common/1.0/types.json#/definitions/ResourceWithEtag" + } + ], "description": "Sentinel onboarding state", "properties": { "customerManagedKey": { From 07d08bf70b828248f0d837a619af3ee0db08072d Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 14:32:42 +0300 Subject: [PATCH 07/19] Fix lintDiff 2 --- .../2021-03-01-preview/OnboardingStates.json | 14 +++++++------ .../CreateSentinelOnboardingState.json | 20 ++++++++++++++++--- .../GetSentinelOnboardingState.json | 7 ++++++- .../resource-manager/readme.md | 2 +- 4 files changed, 32 insertions(+), 11 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index f462d0f4c2e8..580fbe1677dd 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -45,7 +45,7 @@ "SentinelOnboardingStates" ], "description": "Get Sentinel onboarding state", - "operationId": "SentinelOnboardingState_Get", + "operationId": "SentinelOnboardingStates_Get", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" @@ -91,7 +91,7 @@ "SentinelOnboardingStates" ], "description": "Create Sentinel onboarding state", - "operationId": "SentinelOnboardingState_Create", + "operationId": "SentinelOnboardingStates_Create", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" @@ -146,7 +146,7 @@ "SentinelOnboardingStates" ], "description": "Delete Sentinel onboarding state", - "operationId": "SentinelOnboardingState_Delete", + "operationId": "SentinelOnboardingStates_Delete", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" @@ -193,9 +193,11 @@ ], "description": "Sentinel onboarding state", "properties": { - "customerManagedKey": { - "description": "Flag that indicates the status of the CMK setting", - "type": "boolean" + "properties": { + "customerManagedKey": { + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" + } } }, "type": "object" diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index 99c759c0b2e0..0dd021db67a7 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -7,18 +7,32 @@ "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "sentinelOnboardingStateName": "default", "sentinelOnboardingStateParameter": { - "customerManagedKey": false + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } } }, "responses": { "200": { "body": { - "customerManagedKey": false + "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } } }, "201": { "body": { - "customerManagedKey": false + "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } } } } diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json index a80f222b4aa1..723a842aae67 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetSentinelOnboardingState.json @@ -10,7 +10,12 @@ "responses": { "200": { "body": { - "customerManagedKey": false + "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } } } } diff --git a/specification/securityinsights/resource-manager/readme.md b/specification/securityinsights/resource-manager/readme.md index 677cbaf22d70..351889bde487 100644 --- a/specification/securityinsights/resource-manager/readme.md +++ b/specification/securityinsights/resource-manager/readme.md @@ -61,7 +61,7 @@ directive: reason: The Setting does not support list by subscription. It's not a top-level resource. To get the Setting, we should have a subscription as well as a resource group and Log Analytics workspace. - suppress: R4017 from: Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json - where: $.definitions.OnboardingStates + where: $.definitions.SentinelOnboardingState reason: The SentinelOnboardingState does not support list by subscription. It's not a top-level resource. To get the SentinelOnboardingState, we should have a subscription as well as a resource group and Log Analytics workspace. ``` From b5c63882b48f270392f0f781e8b2ffbe8fc13a1f Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 14:48:38 +0300 Subject: [PATCH 08/19] Fix lintDiff 3 --- .../onboardingStates/CreateSentinelOnboardingState.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index 0dd021db67a7..eade28e2b8e2 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -7,8 +7,6 @@ "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "sentinelOnboardingStateName": "default", "sentinelOnboardingStateParameter": { - "name": "default", - "type": "Microsoft.SecurityInsights/onboardingStates", "properties": { "customerManagedKey": false } From 5860ff3c3a291d7685f6f6b8ca52a820a9d483fd Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 15:26:08 +0300 Subject: [PATCH 09/19] Fix lintDiff 4 --- .../examples/onboardingStates/CreateSentinelOnboardingState.json | 1 + 1 file changed, 1 insertion(+) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index eade28e2b8e2..a3bb90f889a4 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -7,6 +7,7 @@ "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "sentinelOnboardingStateName": "default", "sentinelOnboardingStateParameter": { + "type": "Microsoft.SecurityInsights/onboardingStates", "properties": { "customerManagedKey": false } From 7bde37d59537e6beeb3f9add2748e5967a58114a Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 15:35:55 +0300 Subject: [PATCH 10/19] Fix lintDiff 5 --- .../preview/2021-03-01-preview/OnboardingStates.json | 3 ++- .../onboardingStates/CreateSentinelOnboardingState.json | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 580fbe1677dd..afea8959e80d 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -197,7 +197,8 @@ "customerManagedKey": { "description": "Flag that indicates the status of the CMK setting", "type": "boolean" - } + }, + "x-ms-client-flatten": true } }, "type": "object" diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json index a3bb90f889a4..eade28e2b8e2 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/CreateSentinelOnboardingState.json @@ -7,7 +7,6 @@ "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "sentinelOnboardingStateName": "default", "sentinelOnboardingStateParameter": { - "type": "Microsoft.SecurityInsights/onboardingStates", "properties": { "customerManagedKey": false } From c19053dd373201a79128861c578d67fd55343c75 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 15:41:30 +0300 Subject: [PATCH 11/19] Fix lintDiff 6 --- .../2021-03-01-preview/OnboardingStates.json | 20 +++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index afea8959e80d..269fe7f4901d 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -193,12 +193,20 @@ ], "description": "Sentinel onboarding state", "properties": { - "properties": { - "customerManagedKey": { - "description": "Flag that indicates the status of the CMK setting", - "type": "boolean" - }, - "x-ms-client-flatten": true + }, + "type": "object" + }, + "DefaultSentinelOnboardingState": { + "allOf": [ + { + "$ref": "#/definitions/SentinelOnboardingState" + } + ], + "description": "Default Sentinel onboarding state", + "properties": { + "customerManagedKey": { + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" } }, "type": "object" From b0805d1283646b1c48f60c41e654a13c38d794a5 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 16:06:06 +0300 Subject: [PATCH 12/19] Fix lintDiff 7 --- .../preview/2021-03-01-preview/OnboardingStates.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 269fe7f4901d..a6cf77be17b3 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -192,8 +192,6 @@ } ], "description": "Sentinel onboarding state", - "properties": { - }, "type": "object" }, "DefaultSentinelOnboardingState": { @@ -204,9 +202,11 @@ ], "description": "Default Sentinel onboarding state", "properties": { - "customerManagedKey": { - "description": "Flag that indicates the status of the CMK setting", - "type": "boolean" + "properties": { + "customerManagedKey": { + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" + } } }, "type": "object" From 0c306fe543367164096fcd96ee7e7fb829b1004e Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 17:57:17 +0300 Subject: [PATCH 13/19] Fix lintDiff 8 --- .../2021-03-01-preview/OnboardingStates.json | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index a6cf77be17b3..9eb3724774e3 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -185,6 +185,16 @@ } }, "definitions": { + "CustomerManagedKey": { + "description": "The CMK setting object", + "type": "object", + "properties": { + "customerManagedKey": { + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" + } + } + }, "SentinelOnboardingState": { "allOf": [ { @@ -192,21 +202,11 @@ } ], "description": "Sentinel onboarding state", - "type": "object" - }, - "DefaultSentinelOnboardingState": { - "allOf": [ - { - "$ref": "#/definitions/SentinelOnboardingState" - } - ], - "description": "Default Sentinel onboarding state", "properties": { "properties": { - "customerManagedKey": { - "description": "Flag that indicates the status of the CMK setting", - "type": "boolean" - } + "$ref": "#/definitions/CustomerManagedKey", + "description": "The Sentinel onboarding state object", + "x-ms-client-flatten": true } }, "type": "object" From 47b2fac82db7bf4dcd97012abb5b49344fec09a6 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 17:59:56 +0300 Subject: [PATCH 14/19] Fix prettier --- .../preview/2021-03-01-preview/OnboardingStates.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 9eb3724774e3..6a0e9d19a956 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -190,9 +190,9 @@ "type": "object", "properties": { "customerManagedKey": { - "description": "Flag that indicates the status of the CMK setting", - "type": "boolean" - } + "description": "Flag that indicates the status of the CMK setting", + "type": "boolean" + } } }, "SentinelOnboardingState": { From 0f9e1294e36808d3ee941f95c23d3a9ed6eebdd0 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 18:06:01 +0300 Subject: [PATCH 15/19] Rename onboarding state properties --- .../preview/2021-03-01-preview/OnboardingStates.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 6a0e9d19a956..aaf588d35084 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -185,8 +185,8 @@ } }, "definitions": { - "CustomerManagedKey": { - "description": "The CMK setting object", + "SentinelOnboardingStateProperties": { + "description": "The Sentinel onboarding state properties", "type": "object", "properties": { "customerManagedKey": { @@ -204,7 +204,7 @@ "description": "Sentinel onboarding state", "properties": { "properties": { - "$ref": "#/definitions/CustomerManagedKey", + "$ref": "#/definitions/SentinelOnboardingStateProperties", "description": "The Sentinel onboarding state object", "x-ms-client-flatten": true } From 3fe0ff6a44debe54c4d4f6d75ca1fd0d8e53a5d3 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 18:20:48 +0300 Subject: [PATCH 16/19] Add GetAll --- .../2021-03-01-preview/OnboardingStates.json | 60 +++++++++++++++++++ .../GetAllSentinelOnboardingStates.json | 23 +++++++ 2 files changed, 83 insertions(+) create mode 100644 specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index aaf588d35084..84dbbe7d7e15 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -182,6 +182,51 @@ } } } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{operationalInsightsResourceProvider}/workspaces/{workspaceName}/providers/Microsoft.SecurityInsights/onboardingStates": { + "get": { + "x-ms-examples": { + "Get all Sentinel onboarding states": { + "$ref": "./examples/alertRules/GetAllSentinelOnboardingStates.json" + } + }, + "tags": [ + "SentinelOnboardingStates" + ], + "description": "Gets all Sentinel onboarding states", + "operationId": "SentinelOnboardingStates_List", + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/OperationalInsightsResourceProvider" + }, + { + "$ref": "../../../common/1.0/types.json#/parameters/WorkspaceName" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SentinelOnboardingStatesList" + } + }, + "default": { + "description": "Error in listing the Sentinel onboarding states", + "schema": { + "$ref": "#/definitions/CloudError" + } + } + } + } } }, "definitions": { @@ -210,6 +255,21 @@ } }, "type": "object" + }, + "SentinelOnboardingStatesList": { + "description": "List of the Sentinel onboarding states", + "properties": { + "value": { + "description": "Array of Sentinel onboarding states", + "items": { + "$ref": "#/definitions/SentinelOnboardingState" + }, + "type": "array" + } + }, + "required": [ + "value" + ] } }, "parameters": { diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json new file mode 100644 index 000000000000..a9828c1b97af --- /dev/null +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "api-version": "2021-03-01-preview", + "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", + "resourceGroupName": "myRg", + "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights" + }, + "responses": { + "200": { + "value": [ + { + "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } + } + ] + } + } +} From e6db17db14b594c906aedc9ba1e0a7cc4f874279 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 18:25:21 +0300 Subject: [PATCH 17/19] Fix example file name --- .../preview/2021-03-01-preview/OnboardingStates.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index 84dbbe7d7e15..af142f6affa1 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -187,7 +187,7 @@ "get": { "x-ms-examples": { "Get all Sentinel onboarding states": { - "$ref": "./examples/alertRules/GetAllSentinelOnboardingStates.json" + "$ref": "./examples/onboardingStates/GetAllSentinelOnboardingStates.json" } }, "tags": [ From 06e0124eb157bf3b05beaff830804353382fe2ae Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 18:35:21 +0300 Subject: [PATCH 18/19] Fix incorrect cloud error ref --- .../preview/2021-03-01-preview/OnboardingStates.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json index af142f6affa1..2687fa244506 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/OnboardingStates.json @@ -222,7 +222,7 @@ "default": { "description": "Error in listing the Sentinel onboarding states", "schema": { - "$ref": "#/definitions/CloudError" + "$ref": "../../../common/1.0/types.json#/definitions/CloudError" } } } From 58f5030d83fa03db55a0d399c0d52bed6040c183 Mon Sep 17 00:00:00 2001 From: Laith Hisham Date: Sun, 4 Apr 2021 18:42:03 +0300 Subject: [PATCH 19/19] Fix GetAll example --- .../GetAllSentinelOnboardingStates.json | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json index a9828c1b97af..18ce172dd023 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2021-03-01-preview/examples/onboardingStates/GetAllSentinelOnboardingStates.json @@ -8,16 +8,18 @@ }, "responses": { "200": { - "value": [ - { - "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", - "name": "default", - "type": "Microsoft.SecurityInsights/onboardingStates", - "properties": { - "customerManagedKey": false + "body": { + "value": [ + { + "id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/onboardingStates/default", + "name": "default", + "type": "Microsoft.SecurityInsights/onboardingStates", + "properties": { + "customerManagedKey": false + } } - } - ] + ] + } } } }