Skip to main content

governance_controls

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

Overview

Namegovernance_controls
TypeResource
Iddatadog.organization.governance_controls

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe detection type that uniquely identifies the control. (example: unused_api_keys)
attributesobjectThe attributes of a governance control.
typestringJSON:API resource type for a governance control. (governance_control) (example: governance_control)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_governance_controlselectdetection_typeRetrieve a single governance control by its detection type, including the organization's current<br />detection, notification, and mitigation configuration and detection counts.
list_governance_controlsselectRetrieve the list of governance controls configured for the organization. Each control pairs a<br />detection definition with the organization's current detection, notification, and mitigation<br />configuration, along with counts of active and mitigated detections.
update_governance_controlupdatedetection_type, dataUpdate the detection, notification, and mitigation configuration of a governance control. Only<br />the attributes present in the request are modified. Changing the mitigation type or its<br />parameters may require additional permissions.

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
detection_typestringThe detection type that identifies the control, for example unused_api_keys. (example: unused_api_keys)
sitestringThe Datadog site (region) for your organization, for example datadoghq.com, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, datadoghq.eu, ddog-gov.com. Resolved from the DD_SITE environment variable when set. Optional: defaults to datadoghq.com, or the value of the DD_SITE environment variable when set; a WHERE value overrides both.

SELECT examples

Retrieve a single governance control by its detection type, including the organization's current<br />detection, notification, and mitigation configuration and detection counts.

SELECT
id,
attributes,
type
FROM datadog.organization.governance_controls
WHERE detection_type = '{{ detection_type }}' -- required
;

UPDATE examples

Update the detection, notification, and mitigation configuration of a governance control. Only<br />the attributes present in the request are modified. Changing the mitigation type or its<br />parameters may require additional permissions.

UPDATE datadog.organization.governance_controls
SET
data = '{{ data }}'
WHERE
detection_type = '{{ detection_type }}' --required
AND data = '{{ data }}' --required
RETURNING
data;