From 9040d22543beb8e9a348dae23281add414b63dd7 Mon Sep 17 00:00:00 2001 From: Usman Hasan Date: Tue, 22 Feb 2022 09:24:14 -0800 Subject: [PATCH] adding back source type for backwards compatibility, added response descriptions, corrected PR comments --- .../2022-01-01-preview/Watchlists.json | 39 +++++++++++++++---- .../examples/watchlists/CreateWatchlist.json | 3 ++ .../CreateWatchlistAndWatchlistItems.json | 4 ++ .../watchlists/CreateWatchlistItem.json | 1 + .../examples/watchlists/DeleteWatchlist.json | 1 + .../watchlists/DeleteWatchlistItem.json | 1 + .../watchlists/GetWatchlistByAlias.json | 2 + .../watchlists/GetWatchlistItemById.json | 1 + .../watchlists/GetWatchlistItems.json | 1 + .../examples/watchlists/GetWatchlists.json | 4 +- 10 files changed, 49 insertions(+), 8 deletions(-) diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/Watchlists.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/Watchlists.json index c15629dd0ec7..1c533dd17ef4 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/Watchlists.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/Watchlists.json @@ -155,6 +155,17 @@ "200": { "description": "OK" }, + "202": { + "description": "Accepted", + "schema": { + "$ref": "#/definitions/Watchlist" + }, + "headers": { + "Azure-AsyncOperation": { + "description": "Contains the status URL on which clients are expected to poll the status of the delete operation.", + "type": "string" + } + }, "204": { "description": "No Content" }, @@ -178,7 +189,7 @@ "tags": [ "Watchlists" ], - "description": "Creates or updates a watchlist and its watchlist items (bulk creation, e.g. through text/csv content type). To create a Watchlist and its items, we should call this endpoint with rawContent and contentType properties.", + "description": "Create or update a Watchlist and its Watchlist Items (bulk creation, e.g. through text/csv content type). To create a Watchlist and its Items, we should call this endpoint with either rawContent or a valid SAR URI and contentType properties. The rawContent is mainly used for small watchlist (content size below 3.8 MB). The SAS URI enables the creation of large watchlist, where the content size can go up to 500 MB. The status of processing such large file can be polled through the URL returned in Azure-AsyncOperation header.", "operationId": "Watchlists_CreateOrUpdate", "parameters": [ { @@ -208,9 +219,15 @@ } }, "201": { - "description": "Created", + "description": "Created. The response includes the Provisioning State and the Azure-AsyncOperation header. To get the progress of the operation, call GET operation on the URL in Azure-AsyncOperation header field.", "schema": { "$ref": "#/definitions/Watchlist" + }, + "headers": { + "Azure-AsyncOperation": { + "description": "Contains the status URL on which clients are expected to poll the status of the operation.", + "type": "string" + } } }, "default": { @@ -473,6 +490,18 @@ "description": "The provider of the watchlist", "type": "string" }, + "source": { + "description": "The filename of the watchlist, called 'source'", + "enum": [ + "Local file", + "Remote storage" + ], + "type": "string", + "x-ms-enum": { + "modelAsString": true, + "name": "source" + } + }, "sourceType": { "description": "The sourceType of the watchlist", "enum": [ @@ -557,15 +586,11 @@ "uploadStatus": { "description": "The status of the Watchlist upload : New, InProgress or Complete. Pls note : When a Watchlist upload status is equal to InProgress, the Watchlist cannot be deleted", "type": "string" - }, - "watchlistItemsCount": { - "description": "The number of Watchlist Items in the Watchlist", - "type": "integer", - "format": "int32" } }, "required": [ "displayName", + "source", "sourceType", "provider", "itemsSearchKey" diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlist.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlist.json index 09cfa32b591c..53a85bf4a886 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlist.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlist.json @@ -9,6 +9,7 @@ "etag": "\"0300bf09-0000-0000-0000-5c37296e0000\"", "properties": { "displayName": "High Value Assets Watchlist", + "source": "watchlist.csv", "sourceType": "Local file", "provider": "Microsoft", "description": "Watchlist from CSV content", @@ -27,6 +28,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00", @@ -59,6 +61,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00", diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistAndWatchlistItems.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistAndWatchlistItems.json index e61375075c58..de608f715fa7 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistAndWatchlistItems.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistAndWatchlistItems.json @@ -4,11 +4,13 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset", "watchlist": { "etag": "\"0300bf09-0000-0000-0000-5c37296e0000\"", "properties": { "displayName": "High Value Assets Watchlist", + "source": "watchlist.csv", "sourceType": "Local file", "provider": "Microsoft", "description": "Watchlist from CSV content", @@ -30,6 +32,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00", @@ -62,6 +65,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00", diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistItem.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistItem.json index cf785e2b622d..ae3c2ebbeb1e 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistItem.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/CreateWatchlistItem.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset", "watchlistItemId": "82ba292c-dc97-4dfc-969d-d4dd9e666842", "watchlistItem": { diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlist.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlist.json index b52ca2d128a5..ecd64b092ba5 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlist.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlist.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset" }, "responses": { diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlistItem.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlistItem.json index cfa94f258fe7..3162e6f61bf0 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlistItem.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/DeleteWatchlistItem.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset", "watchlistItemId": "4008512e-1d30-48b2-9ee2-d3612ed9d3ea" }, diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistByAlias.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistByAlias.json index 47770e2b0d6a..e9df61adb2ba 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistByAlias.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistByAlias.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset" }, "responses": { @@ -17,6 +18,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00", diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItemById.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItemById.json index 4d96c2bdaf3d..9ea82d53be83 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItemById.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItemById.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset", "watchlistItemId": "3f8901fe-63d9-4875-9ad5-9fb3b8105797" }, diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItems.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItems.json index d6473ebae6f8..369b9919aa40 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItems.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlistItems.json @@ -4,6 +4,7 @@ "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights", "alias": "highValueAsset" }, "responses": { diff --git a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlists.json b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlists.json index 91892ce4a803..7b524188d93d 100644 --- a/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlists.json +++ b/specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/examples/watchlists/GetWatchlists.json @@ -3,7 +3,8 @@ "api-version": "2022-01-01-preview", "subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", "resourceGroupName": "myRg", - "workspaceName": "myWorkspace" + "workspaceName": "myWorkspace", + "operationalInsightsResourceProvider": "Microsoft.OperationalInsights" }, "responses": { "200": { @@ -18,6 +19,7 @@ "watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017", "displayName": "High Value Assets Watchlist", "provider": "Microsoft", + "source": "watchlist.csv", "sourceType": "Local file", "created": "2020-09-28T00:26:54.7746089+00:00", "updated": "2020-09-28T00:26:57+00:00",