-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Workspace manager configurations #23133
Merged
tadelesh
merged 9 commits into
Azure:release-Sentinel-2023-04-01-preview
from
rheabansal:feature-Sentinel-2023-04-01-preview-WorkspaceManager-Configurations
Mar 21, 2023
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
7f2e914
Adds base for updating Microsoft.SecurityInsights from version previe…
rheabansal 80cb67b
Updates readme
rheabansal 5e21417
Updates API version in new specs and examples
rheabansal dbc4728
adding april configurations swagger
rheabansal e345fad
update pattern
rheabansal 46c7c57
prettier update
rheabansal 7e1aa46
Merge to update to april
rheabansal ea46da1
update readme
rheabansal f8844a5
Merge branch 'release-Sentinel-2023-04-01-preview' into feature-Senti…
rheabansal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
323 changes: 323 additions & 0 deletions
323
...Microsoft.SecurityInsights/preview/2023-04-01-preview/WorkspaceManagerConfigurations.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,323 @@ | ||
{ | ||
"swagger": "2.0", | ||
"info": { | ||
"title": "Security Insights", | ||
"description": "API spec for Microsoft.SecurityInsights (Azure Security Insights) resource provider", | ||
"version": "2023-04-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/Microsoft.OperationalInsights/workspaces/{workspaceName}/providers/Microsoft.SecurityInsights/workspaceManagerConfigurations": { | ||
"get": { | ||
"x-ms-examples": { | ||
"Get all workspace manager configurations for a Sentinel workspace.": { | ||
"$ref": "./examples/workspaceManagerConfigurations/GetAllWorkspaceManagerConfigurations.json" | ||
} | ||
}, | ||
"tags": [ | ||
"workspaceManagerConfigurations" | ||
], | ||
"description": "Gets all workspace manager configurations for a Sentinel workspace.", | ||
"operationId": "WorkspaceManagerConfigurations_List", | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/WorkspaceName" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/ODataOrderBy" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/ODataTop" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/ODataSkipToken" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "OK", | ||
"schema": { | ||
"$ref": "#/definitions/WorkspaceManagerConfigurationList" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"x-ms-pageable": { | ||
"nextLinkName": "nextLink" | ||
} | ||
} | ||
}, | ||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/providers/Microsoft.SecurityInsights/workspaceManagerConfigurations/{workspaceManagerConfigurationName}": { | ||
"get": { | ||
"x-ms-examples": { | ||
"Get a workspace manager configuration.": { | ||
"$ref": "./examples/workspaceManagerConfigurations/GetWorkspaceManagerConfiguration.json" | ||
} | ||
}, | ||
"tags": [ | ||
"workspaceManagerConfigurations" | ||
], | ||
"description": "Gets a workspace manager configuration", | ||
"operationId": "WorkspaceManagerConfigurations_Get", | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/WorkspaceName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/WorkspaceManagerConfigurationName" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "OK", | ||
"schema": { | ||
"$ref": "#/definitions/WorkspaceManagerConfiguration" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
} | ||
}, | ||
"delete": { | ||
"x-ms-examples": { | ||
"Delete a workspace manager configuration.": { | ||
"$ref": "./examples/workspaceManagerConfigurations/DeleteWorkspaceManagerConfiguration.json" | ||
} | ||
}, | ||
"tags": [ | ||
"workspaceManagerConfigurations" | ||
], | ||
"description": "Deletes a workspace manager configuration", | ||
"operationId": "WorkspaceManagerConfigurations_Delete", | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/WorkspaceName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/WorkspaceManagerConfigurationName" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "OK" | ||
}, | ||
"204": { | ||
"description": "No Content" | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
} | ||
}, | ||
"put": { | ||
"x-ms-examples": { | ||
"Create or Update a workspace manager Configuration": { | ||
"$ref": "./examples/workspaceManagerConfigurations/CreateOrUpdateWorkspaceManagerConfiguration.json" | ||
} | ||
}, | ||
"tags": [ | ||
"workspaceManagerConfigurations" | ||
], | ||
"description": "Creates or updates a workspace manager configuration.", | ||
"operationId": "WorkspaceManagerConfigurations_CreateOrUpdate", | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "../../../common/2.0/types.json#/parameters/WorkspaceName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/WorkspaceManagerConfigurationName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/WorkspaceManagerConfiguration" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "OK", | ||
"schema": { | ||
"$ref": "#/definitions/WorkspaceManagerConfiguration" | ||
} | ||
}, | ||
"201": { | ||
"description": "Created", | ||
"schema": { | ||
"$ref": "#/definitions/WorkspaceManagerConfiguration" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"definitions": { | ||
"WorkspaceManagerConfiguration": { | ||
"allOf": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/AzureEntityResource" | ||
} | ||
], | ||
"description": "The workspace manager configuration", | ||
"properties": { | ||
"properties": { | ||
"$ref": "#/definitions/WorkspaceManagerConfigurationProperties", | ||
"description": "The workspace manager configuration object", | ||
"x-ms-client-flatten": true | ||
} | ||
}, | ||
"type": "object" | ||
}, | ||
"WorkspaceManagerConfigurationProperties": { | ||
"description": "The workspace manager configuration properties", | ||
"properties": { | ||
"mode": { | ||
"description": "The current mode of the workspace manager configuration", | ||
"enum": [ | ||
"Enabled", | ||
"Disabled" | ||
], | ||
"type": "string", | ||
"x-ms-enum": { | ||
"modelAsString": true, | ||
"name": "mode", | ||
"values": [ | ||
{ | ||
"description": "The workspace manager configuration is enabled", | ||
"value": "Enabled" | ||
}, | ||
{ | ||
"description": "The workspace manager configuration is disabled", | ||
"value": "Disabled" | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
"required": [ | ||
"mode" | ||
], | ||
"type": "object" | ||
}, | ||
"WorkspaceManagerConfigurationList": { | ||
"description": "List all the workspace manager configurations for the workspace.", | ||
"type": "object", | ||
"properties": { | ||
"nextLink": { | ||
"description": "URL to fetch the next set of workspace manager configurations.", | ||
"readOnly": true, | ||
"type": "string" | ||
}, | ||
"value": { | ||
"description": "Array of workspace manager configurations.", | ||
"items": { | ||
"$ref": "#/definitions/WorkspaceManagerConfiguration" | ||
}, | ||
"type": "array" | ||
} | ||
}, | ||
"required": [ | ||
"value" | ||
] | ||
} | ||
}, | ||
"parameters": { | ||
"WorkspaceManagerConfigurationName": { | ||
"description": "The name of the workspace manager configuration", | ||
"in": "path", | ||
"name": "workspaceManagerConfigurationName", | ||
"required": true, | ||
"type": "string", | ||
"pattern": "^[A-Za-z0-9][A-Za-z0-9-]+[A-Za-z0-9]$", | ||
"x-ms-parameter-location": "method" | ||
}, | ||
"WorkspaceManagerConfiguration": { | ||
"description": "The workspace manager configuration", | ||
"in": "body", | ||
"name": "workspaceManagerConfiguration", | ||
"required": true, | ||
"schema": { | ||
"$ref": "#/definitions/WorkspaceManagerConfiguration" | ||
}, | ||
"x-ms-parameter-location": "method" | ||
} | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
.../examples/workspaceManagerConfigurations/CreateOrUpdateWorkspaceManagerConfiguration.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2023-04-01-preview", | ||
"subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", | ||
"resourceGroupName": "myRg", | ||
"workspaceName": "myWorkspace", | ||
"workspaceManagerConfigurationName": "default", | ||
"workspaceManagerConfiguration": { | ||
"properties": { | ||
"mode": "Enabled" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalInsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/workspaceManagerConfigurations/default", | ||
"etag": "\"3f6451dd-1b58-4bef-bce7-72eba6b354d7\"", | ||
"name": "default", | ||
"type": "Microsoft.SecurityInsights/workspaceManagerConfigurations", | ||
"properties": { | ||
"mode": "Enabled" | ||
rheabansal marked this conversation as resolved.
Show resolved
Hide resolved
|
||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalInsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/workspaceManagerConfigurations/default", | ||
"etag": "\"3f6451dd-1b58-4bef-bce7-72eba6b354d7\"", | ||
"name": "default", | ||
"type": "Microsoft.SecurityInsights/workspaceManagerConfigurations", | ||
"properties": { | ||
"mode": "Enabled" | ||
} | ||
} | ||
} | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...-preview/examples/workspaceManagerConfigurations/DeleteWorkspaceManagerConfiguration.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2023-04-01-preview", | ||
"subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0", | ||
"resourceGroupName": "myRg", | ||
"workspaceName": "myWorkspace", | ||
"workspaceManagerConfigurationName": "default" | ||
}, | ||
"responses": { | ||
"200": {}, | ||
"204": {} | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you intend to make this a singleton ? https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/common-api-contracts.md#singleton-resources
If so you can update the definition to remove the {workspaceManagerConfigurationName} variable and only allow default