Skip to main content

incidents

Creates, updates, deletes, gets or lists an incidents resource.

Overview

Nameincidents
TypeResource
Idazure.sentinel.incidents

Fields

The following fields are returned by SELECT queries:

OK, Operation successfully completed

NameDatatypeDescription
etagstringEtag of the azure resource
propertiesobjectIncident properties

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, workspaceName, incidentIdGets a given incident.
listselectsubscriptionId, resourceGroupName, workspaceName$filter, $orderby, $top, $skipTokenGets all incidents.
create_or_updateinsertsubscriptionId, resourceGroupName, workspaceName, incidentIdCreates or updates an incident.
deletedeletesubscriptionId, resourceGroupName, workspaceName, incidentIdDeletes a given incident.
run_playbookexecsubscriptionId, resourceGroupName, workspaceName, incidentIdentifier, logicAppsResourceIdTriggers playbook on a specific incident

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
incidentIdstringIncident ID
incidentIdentifierstringIncident ID
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
subscriptionIdstringThe ID of the target subscription.
workspaceNamestringThe name of the workspace.
$filterstringFilters the results, based on a Boolean condition. Optional.
$orderbystringSorts the results. Optional.
$skipTokenstringSkiptoken is only used if a previous operation returned a partial result. If a previous response contains a nextLink element, the value of the nextLink element will include a skiptoken parameter that specifies a starting point to use for subsequent calls. Optional.
$topinteger (int32)Returns only the first n results. Optional.

SELECT examples

Gets a given incident.

SELECT
etag,
properties
FROM azure.sentinel.incidents
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND workspaceName = '{{ workspaceName }}' -- required
AND incidentId = '{{ incidentId }}' -- required
;

INSERT examples

Creates or updates an incident.

INSERT INTO azure.sentinel.incidents (
data__etag,
data__properties,
subscriptionId,
resourceGroupName,
workspaceName,
incidentId
)
SELECT
'{{ etag }}',
'{{ properties }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ workspaceName }}',
'{{ incidentId }}'
RETURNING
etag,
properties
;

DELETE examples

Deletes a given incident.

DELETE FROM azure.sentinel.incidents
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND workspaceName = '{{ workspaceName }}' --required
AND incidentId = '{{ incidentId }}' --required
;

Lifecycle Methods

Triggers playbook on a specific incident

EXEC azure.sentinel.incidents.run_playbook 
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@workspaceName='{{ workspaceName }}' --required,
@incidentIdentifier='{{ incidentIdentifier }}' --required
@@json=
'{
"tenantId": "{{ tenantId }}",
"logicAppsResourceId": "{{ logicAppsResourceId }}"
}'
;