Skip to main content

incident_comments

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

Overview

Nameincident_comments
TypeResource
Idazure.sentinel.incident_comments

Fields

NameDatatypeDescription
authortextfield from the properties object
created_time_utctextfield from the properties object
etagtextEtag of the azure resource
incidentCommentIdtextfield from the properties object
incidentIdtextfield from the properties object
last_modified_time_utctextfield from the properties object
messagetextfield from the properties object
resourceGroupNametextfield from the properties object
subscriptionIdtextfield from the properties object
workspaceNametextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTincidentCommentId, incidentId, resourceGroupName, subscriptionId, workspaceNameGets a comment for a given incident.
listSELECTincidentId, resourceGroupName, subscriptionId, workspaceNameGets all comments for a given incident.
create_or_updateINSERTincidentCommentId, incidentId, resourceGroupName, subscriptionId, workspaceNameCreates or updates a comment for a given incident.
deleteDELETEincidentCommentId, incidentId, resourceGroupName, subscriptionId, workspaceNameDeletes a comment for a given incident.

SELECT examples

Gets all comments for a given incident.

SELECT
author,
created_time_utc,
etag,
incidentCommentId,
incidentId,
last_modified_time_utc,
message,
resourceGroupName,
subscriptionId,
workspaceName
FROM azure.sentinel.vw_incident_comments
WHERE incidentId = '{{ incidentId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceName = '{{ workspaceName }}';

INSERT example

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

/*+ create */
INSERT INTO azure.sentinel.incident_comments (
incidentCommentId,
incidentId,
resourceGroupName,
subscriptionId,
workspaceName,
etag,
properties
)
SELECT
'{{ incidentCommentId }}',
'{{ incidentId }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ workspaceName }}',
'{{ etag }}',
'{{ properties }}'
;

DELETE example

Deletes the specified incident_comments resource.

/*+ delete */
DELETE FROM azure.sentinel.incident_comments
WHERE incidentCommentId = '{{ incidentCommentId }}'
AND incidentId = '{{ incidentId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceName = '{{ workspaceName }}';