Skip to main content

source_controls

Creates, updates, deletes, gets or lists a source_controls resource.

Overview

Namesource_controls
TypeResource
Idazure.sentinel.source_controls

Fields

NameDatatypeDescription
idtextfield from the properties object
descriptiontextfield from the properties object
content_typestextfield from the properties object
display_nametextfield from the properties object
etagtextEtag of the azure resource
last_deployment_infotextfield from the properties object
pull_requesttextfield from the properties object
repo_typetextfield from the properties object
repositorytextfield from the properties object
repository_accesstextfield from the properties object
repository_resource_infotextfield from the properties object
resourceGroupNametextfield from the properties object
service_principaltextfield from the properties object
sourceControlIdtextfield from the properties object
subscriptionIdtextfield from the properties object
versiontextfield from the properties object
workspaceNametextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTresourceGroupName, sourceControlId, subscriptionId, workspaceNameGets a source control byt its identifier.
listSELECTresourceGroupName, subscriptionId, workspaceNameGets all source controls, without source control items.
createINSERTresourceGroupName, sourceControlId, subscriptionId, workspaceName, data__propertiesCreates a source control.
deleteDELETEresourceGroupName, sourceControlId, subscriptionId, workspaceName, data__propertiesDelete a source control.

SELECT examples

Gets all source controls, without source control items.

SELECT
id,
description,
content_types,
display_name,
etag,
last_deployment_info,
pull_request,
repo_type,
repository,
repository_access,
repository_resource_info,
resourceGroupName,
service_principal,
sourceControlId,
subscriptionId,
version,
workspaceName
FROM azure.sentinel.vw_source_controls
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceName = '{{ workspaceName }}';

INSERT example

Use the following StackQL query and manifest file to create a new source_controls resource.

/*+ create */
INSERT INTO azure.sentinel.source_controls (
resourceGroupName,
sourceControlId,
subscriptionId,
workspaceName,
data__properties,
etag,
properties
)
SELECT
'{{ resourceGroupName }}',
'{{ sourceControlId }}',
'{{ subscriptionId }}',
'{{ workspaceName }}',
'{{ data__properties }}',
'{{ etag }}',
'{{ properties }}'
;

DELETE example

Deletes the specified source_controls resource.

/*+ delete */
DELETE FROM azure.sentinel.source_controls
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND sourceControlId = '{{ sourceControlId }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceName = '{{ workspaceName }}'
AND data__properties = '{{ data__properties }}';