diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 3cabe03bba..db0bdfdf15 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -189930,7 +189930,7 @@ paths: data: attributes: enabled: true - name: Rule 1 + name: Rule selectors: query: (source:production_service OR env:prod) rule_types: @@ -190111,7 +190111,7 @@ paths: data: attributes: enabled: true - name: Rule 1 + name: Rule selectors: query: (source:production_service OR env:prod) rule_types: @@ -190753,7 +190753,7 @@ paths: data: attributes: enabled: true - name: Rule 1 + name: Rule selectors: query: (source:production_service OR env:prod) rule_types: @@ -190936,7 +190936,7 @@ paths: data: attributes: enabled: true - name: Rule 1 + name: Rule selectors: query: (source:production_service OR env:prod) rule_types: diff --git a/examples/v2/security-monitoring/CreateSignalNotificationRule.py b/examples/v2/security-monitoring/CreateSignalNotificationRule.py index a3f1391caf..0719218308 100644 --- a/examples/v2/security-monitoring/CreateSignalNotificationRule.py +++ b/examples/v2/security-monitoring/CreateSignalNotificationRule.py @@ -19,7 +19,7 @@ data=CreateNotificationRuleParametersData( attributes=CreateNotificationRuleParametersDataAttributes( enabled=True, - name="Rule 1", + name="Rule 9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", selectors=Selectors( query="(source:production_service OR env:prod)", rule_types=[ diff --git a/examples/v2/security-monitoring/CreateVulnerabilityNotificationRule.py b/examples/v2/security-monitoring/CreateVulnerabilityNotificationRule.py index e51c1cbea8..dc09496284 100644 --- a/examples/v2/security-monitoring/CreateVulnerabilityNotificationRule.py +++ b/examples/v2/security-monitoring/CreateVulnerabilityNotificationRule.py @@ -19,7 +19,7 @@ data=CreateNotificationRuleParametersData( attributes=CreateNotificationRuleParametersDataAttributes( enabled=True, - name="Rule 1", + name="Rule 9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", selectors=Selectors( query="(source:production_service OR env:prod)", rule_types=[ diff --git a/examples/v2/security-monitoring/PatchSignalNotificationRule.py b/examples/v2/security-monitoring/PatchSignalNotificationRule.py index d58df7717b..7bcf91f7a2 100644 --- a/examples/v2/security-monitoring/PatchSignalNotificationRule.py +++ b/examples/v2/security-monitoring/PatchSignalNotificationRule.py @@ -23,7 +23,7 @@ data=PatchNotificationRuleParametersData( attributes=PatchNotificationRuleParametersDataAttributes( enabled=True, - name="Rule 1", + name="Rule 9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", selectors=Selectors( query="(source:production_service OR env:prod)", rule_types=[ diff --git a/examples/v2/security-monitoring/PatchVulnerabilityNotificationRule.py b/examples/v2/security-monitoring/PatchVulnerabilityNotificationRule.py index 1b635a1339..a39fc1f11e 100644 --- a/examples/v2/security-monitoring/PatchVulnerabilityNotificationRule.py +++ b/examples/v2/security-monitoring/PatchVulnerabilityNotificationRule.py @@ -23,7 +23,7 @@ data=PatchNotificationRuleParametersData( attributes=PatchNotificationRuleParametersDataAttributes( enabled=True, - name="Rule 1", + name="Rule 9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", selectors=Selectors( query="(source:production_service OR env:prod)", rule_types=[ diff --git a/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen b/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen index 594e432cb6..63badec3e1 100644 --- a/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen @@ -1 +1 @@ -2025-02-05T13:45:37.454Z \ No newline at end of file +2026-08-18T08:25:48.962Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml b/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml index dd6d9468e0..7d2229f982 100644 --- a/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_create_a_new_signalbased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Rule 1","selectors":{"query":"(source:production_service + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704154800","selectors":{"query":"(source:production_service OR env:prod)","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: @@ -11,8 +11,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"hvb-for-lpm","type":"notification_rules","attributes":{"created_at":1738763137979,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763137979,"modified_by":{"name":"","handle":""},"name":"Rule - 1","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + string: '{"data":{"id":"lro-dlc-wg9","type":"notification_rules","attributes":{"created_at":1787041551054,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041551054,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704154800","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: @@ -26,7 +27,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/hvb-for-lpm + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/lro-dlc-wg9 response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen b/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen index e3138e7d62..3ca7ed7833 100644 --- a/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.frozen @@ -1 +1 @@ -2025-02-05T13:45:38.493Z \ No newline at end of file +2026-08-18T08:25:51.223Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml b/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml index 3a643f303a..3cd9688d90 100644 --- a/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_create_a_new_vulnerabilitybased_notification_rule_returns_successfully_created_the_notification_rule_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Rule 1","selectors":{"query":"(source:production_service + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"query":"(source:production_service OR env:prod)","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: @@ -11,8 +11,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"iwz-k3b-tpk","type":"notification_rules","attributes":{"created_at":1738763138982,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763138982,"modified_by":{"name":"","handle":""},"name":"Rule - 1","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + string: '{"data":{"id":"ieg-wc2-qal","type":"notification_rules","attributes":{"created_at":1787041551334,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041551334,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: @@ -26,7 +27,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/iwz-k3b-tpk + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/ieg-wc2-qal response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.frozen b/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.frozen index f51e67baf3..4717508373 100644 --- a/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.frozen @@ -1 +1 @@ -2025-02-05T13:45:44.348Z \ No newline at end of file +2026-08-18T08:25:51.547Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.yaml b/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.yaml index 6e57899f1e..2494247883 100644 --- a/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_delete_a_signalbased_notification_rule_returns_rule_successfully_deleted_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Delete_a_signal_based_notification_rule_returns_Rule_successfully_deleted_response-1738763144","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"x4n-qps-p3w","type":"notification_rules","attributes":{"created_at":1738763144838,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763144838,"modified_by":{"name":"","handle":""},"name":"Test-Delete_a_signal_based_notification_rule_returns_Rule_successfully_deleted_response-1738763144","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"faz-jrz-vdw","type":"notification_rules","attributes":{"created_at":1787041551643,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041551643,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -23,7 +25,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/x4n-qps-p3w + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/faz-jrz-vdw response: body: string: '' @@ -37,10 +39,10 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/x4n-qps-p3w + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/faz-jrz-vdw response: body: - string: '{"errors":["not_found(Notification rule with id ''x4n-qps-p3w'' not + string: '{"errors":["not_found(Notification rule with id ''faz-jrz-vdw'' not found)"]}' headers: content-type: diff --git a/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.frozen b/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.frozen index c5f1ae2212..0efe8051b3 100644 --- a/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.frozen @@ -1 +1 @@ -2025-02-05T13:45:47.393Z \ No newline at end of file +2026-08-18T08:25:51.881Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.yaml b/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.yaml index fa3c116fc1..b1d0449262 100644 --- a/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_delete_a_vulnerabilitybased_notification_rule_returns_rule_successfully_deleted_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Delete_a_vulnerability_based_notification_rule_returns_Rule_successfully_deleted_response-1738763147","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"p3z-nij-ygf","type":"notification_rules","attributes":{"created_at":1738763147765,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763147765,"modified_by":{"name":"","handle":""},"name":"Test-Delete_a_vulnerability_based_notification_rule_returns_Rule_successfully_deleted_response-1738763147","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"bpb-oos-ppt","type":"notification_rules","attributes":{"created_at":1787041551965,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041551965,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155100","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -23,7 +25,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/p3z-nij-ygf + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/bpb-oos-ppt response: body: string: '' @@ -37,10 +39,10 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/p3z-nij-ygf + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/bpb-oos-ppt response: body: - string: '{"errors":["not_found(Notification rule with id ''p3z-nij-ygf'' not + string: '{"errors":["not_found(Notification rule with id ''bpb-oos-ppt'' not found)"]}' headers: content-type: diff --git a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.frozen b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.frozen index 51dd6f9175..b64851789f 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:01.602Z \ No newline at end of file +2026-08-18T08:25:52.299Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.yaml b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.yaml index f4d88a440b..21e4bef8e3 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_signalbased_notification_rule_returns_notification_rule_details_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Get_details_of_a_signal_based_notification_rule_returns_Notification_rule_details_response-1738763161","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"tcf-juk-5tr","type":"notification_rules","attributes":{"created_at":1738763162076,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763162076,"modified_by":{"name":"","handle":""},"name":"Test-Get_details_of_a_signal_based_notification_rule_returns_Notification_rule_details_response-1738763161","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"we4-vwn-ub3","type":"notification_rules","attributes":{"created_at":1787041552392,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041552392,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -23,10 +25,12 @@ interactions: accept: - application/json method: GET - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/tcf-juk-5tr + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/we4-vwn-ub3 response: body: - string: '{"data":{"id":"tcf-juk-5tr","type":"notification_rules","attributes":{"created_at":1738763162076,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763162076,"modified_by":{"name":"","handle":""},"name":"Test-Get_details_of_a_signal_based_notification_rule_returns_Notification_rule_details_response-1738763161","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"we4-vwn-ub3","type":"notification_rules","attributes":{"created_at":1787041552392,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041552392,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -39,7 +43,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/tcf-juk-5tr + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/we4-vwn-ub3 response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.frozen b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.frozen index 5c0ebad972..8ad2aa3c3a 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:03.335Z \ No newline at end of file +2026-08-18T08:25:52.650Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.yaml b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.yaml index 2ac57c6424..104308534a 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_get_details_of_a_vulnerability_notification_rule_returns_notification_rule_details_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Get_details_of_a_vulnerability_notification_rule_returns_Notification_rule_details_response-1738763163","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"ryn-rs2-tef","type":"notification_rules","attributes":{"created_at":1738763163705,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763163705,"modified_by":{"name":"","handle":""},"name":"Test-Get_details_of_a_vulnerability_notification_rule_returns_Notification_rule_details_response-1738763163","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"54b-raw-0dt","type":"notification_rules","attributes":{"created_at":1787041552745,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041552745,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -23,10 +25,12 @@ interactions: accept: - application/json method: GET - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/ryn-rs2-tef + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/54b-raw-0dt response: body: - string: '{"data":{"id":"ryn-rs2-tef","type":"notification_rules","attributes":{"created_at":1738763163705,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763163705,"modified_by":{"name":"","handle":""},"name":"Test-Get_details_of_a_vulnerability_notification_rule_returns_Notification_rule_details_response-1738763163","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"54b-raw-0dt","type":"notification_rules","attributes":{"created_at":1787041552745,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041552745,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155200","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -39,7 +43,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/ryn-rs2-tef + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/54b-raw-0dt response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.frozen b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.frozen index 2c353113bd..c2aed0ebbe 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:04.585Z \ No newline at end of file +2026-08-18T08:25:53.057Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.yaml b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.yaml index 78449a1931..0213d0e7ab 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_signalbased_notification_rules_returns_the_list_of_notification_rules_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Get_the_list_of_signal_based_notification_rules_returns_The_list_of_notification_rules_response-1738763164","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"btd-udo-vn7","type":"notification_rules","attributes":{"created_at":1738763164939,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763164939,"modified_by":{"name":"","handle":""},"name":"Test-Get_the_list_of_signal_based_notification_rules_returns_The_list_of_notification_rules_response-1738763164","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"yc8-i7q-9be","type":"notification_rules","attributes":{"created_at":1787041553174,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041553174,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -26,7 +28,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":[{"id":"btd-udo-vn7","type":"notification_rules","attributes":{"created_at":1738763164939,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763164939,"modified_by":{"name":"","handle":""},"name":"Test-Get_the_list_of_signal_based_notification_rules_returns_The_list_of_notification_rules_response-1738763164","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}]}' + string: '{"data":[{"id":"yja-vtn-jr9","type":"notification_rules","attributes":{"created_at":1755115900029,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1755115900029,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Test-Delete_a_signal_based_notification_rule_returns_Rule_successfully_deleted_response-1755115899","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}},{"id":"yc8-i7q-9be","type":"notification_rules","attributes":{"created_at":1787041553174,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041553174,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}]}' headers: content-type: - application/vnd.api+json @@ -39,7 +43,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/btd-udo-vn7 + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/yc8-i7q-9be response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.frozen b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.frozen index a29f84ee45..557296bdaa 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:05.871Z \ No newline at end of file +2026-08-18T08:25:53.433Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.yaml b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.yaml index 74df3453b5..89fb556497 100644 --- a/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_get_the_list_of_vulnerability_notification_rules_returns_the_list_of_notification_rules_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Get_the_list_of_vulnerability_notification_rules_returns_The_list_of_notification_rules_response-1738763165","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"jl2-gq4-vr0","type":"notification_rules","attributes":{"created_at":1738763166229,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763166229,"modified_by":{"name":"","handle":""},"name":"Test-Get_the_list_of_vulnerability_notification_rules_returns_The_list_of_notification_rules_response-1738763165","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"bpd-ytx-gr7","type":"notification_rules","attributes":{"created_at":1787041553522,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041553522,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -26,7 +28,22 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":[{"id":"jl2-gq4-vr0","type":"notification_rules","attributes":{"created_at":1738763166229,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763166229,"modified_by":{"name":"","handle":""},"name":"Test-Get_the_list_of_vulnerability_notification_rules_returns_The_list_of_notification_rules_response-1738763165","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}]}' + string: '{"data":[{"id":"k41-pa4-6wc","type":"notification_rules","attributes":{"created_at":1739223055334,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1739223055759,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Rule + 1","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":9}},{"id":"o8d-quc-x6c","type":"notification_rules","attributes":{"created_at":1739972529211,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1754569022707,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"My + vulnerability notification rule 2","selectors":{"severities":["high","critical"],"rule_types":["iac_misconfiguration","host_vulnerability"],"query":"","trigger_source":"security_findings"},"targets":["john@email.com"],"time_aggregation":36000,"version":10}},{"id":"euw-tg7-zrp","type":"notification_rules","attributes":{"created_at":1755114943037,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1755114943037,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Test-Get_the_list_of_vulnerability_notification_rules_returns_The_list_of_notification_rules_response-1755114942","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":8}},{"id":"cd2-sth-brq","type":"notification_rules","attributes":{"created_at":1776474749079,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1776474749079,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Test-Go-Get_the_list_of_vulnerability_notification_rules_returns_The_list_of_notification_rules_response-1776474748","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":2}},{"id":"std-aoa-qzn","type":"notification_rules","attributes":{"created_at":1777511746262,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1777511746262,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Test-Go-Delete_a_vulnerability_based_notification_rule_returns_Rule_successfully_deleted_response-1777511746","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}},{"id":"ced-ocu-dbc","type":"notification_rules","attributes":{"created_at":1786467545634,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1786467545993,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Rule + 1786467545","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":2}},{"id":"fzb-0zu-hwz","type":"notification_rules","attributes":{"created_at":1786467569620,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1786467569956,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Rule + 1786467569","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":2}},{"id":"l3e-nqw-ero","type":"notification_rules","attributes":{"created_at":1786467603254,"created_by":{"name":"frog","handle":"frog@datadoghq.com"},"enabled":true,"modified_at":1786467603614,"modified_by":{"name":"frog","handle":"frog@datadoghq.com"},"name":"Rule + 1786467602","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":2}},{"id":"bpd-ytx-gr7","type":"notification_rules","attributes":{"created_at":1787041553522,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041553522,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}]}' headers: content-type: - application/vnd.api+json @@ -39,7 +56,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/jl2-gq4-vr0 + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/bpd-ytx-gr7 response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.frozen b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.frozen index 3ba9d1b93a..6d7fbe70a4 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:11.165Z \ No newline at end of file +2026-08-18T08:25:53.852Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.yaml b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.yaml index 1dc91880c6..3c9017dee7 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_bad_request_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Patch_a_signal_based_notification_rule_returns_Bad_Request_response-1738763171","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"uwx-6n1-x2z","type":"notification_rules","attributes":{"created_at":1738763171531,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763171531,"modified_by":{"name":"","handle":""},"name":"Test-Patch_a_signal_based_notification_rule_returns_Bad_Request_response-1738763171","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"cih-ioz-u8b","type":"notification_rules","attributes":{"created_at":1787041553943,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041553943,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155300","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -26,7 +28,7 @@ interactions: content-type: - application/json method: PATCH - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/uwx-6n1-x2z + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/cih-ioz-u8b response: body: string: '{"errors":["input_validation_error(Field ''data.attributes.version'' @@ -44,7 +46,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/uwx-6n1-x2z + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/cih-ioz-u8b response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.frozen b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.frozen index 4a31995547..dc50984e54 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:12.789Z \ No newline at end of file +2026-08-18T08:25:54.184Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.yaml b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.yaml index 1eea996f54..3e599ebee1 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_signalbased_notification_rule_returns_notification_rule_successfully_patched_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Patch_a_signal_based_notification_rule_returns_Notification_rule_successfully_patched_response-1738763172","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"query":"env:test","rule_types":["signal_correlation"],"severities":["critical"],"trigger_source":"security_signals"},"targets":["@email@email.com"]},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules response: body: - string: '{"data":{"id":"ob0-6ru-hc6","type":"notification_rules","attributes":{"created_at":1738763173259,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763173259,"modified_by":{"name":"","handle":""},"name":"Test-Patch_a_signal_based_notification_rule_returns_Notification_rule_successfully_patched_response-1738763172","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' + string: '{"data":{"id":"v6q-o1k-aul","type":"notification_rules","attributes":{"created_at":1787041554291,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041554291,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"severities":["critical"],"rule_types":["signal_correlation"],"query":"env:test","trigger_source":"security_signals"},"targets":["@email@email.com"],"time_aggregation":0,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -18,7 +20,7 @@ interactions: code: 201 message: Created - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Rule 1","selectors":{"query":"(source:production_service + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"query":"(source:production_service OR env:prod)","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":1},"id":"aaa-bbb-ccc","type":"notification_rules"}}' headers: accept: @@ -26,11 +28,12 @@ interactions: content-type: - application/json method: PATCH - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/ob0-6ru-hc6 + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/v6q-o1k-aul response: body: - string: '{"data":{"id":"ob0-6ru-hc6","type":"notification_rules","attributes":{"created_at":1738763173259,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763173722,"modified_by":{"name":"","handle":""},"name":"Rule - 1","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + string: '{"data":{"id":"v6q-o1k-aul","type":"notification_rules","attributes":{"created_at":1787041554291,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041554426,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":2}}}' headers: content-type: @@ -44,7 +47,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/ob0-6ru-hc6 + uri: https://api.datadoghq.com/api/v2/security/signals/notification_rules/v6q-o1k-aul response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.frozen b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.frozen index 9c16ba59f0..afbe0ec03d 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:14.056Z \ No newline at end of file +2026-08-18T08:25:54.566Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.yaml b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.yaml index a4d83c0475..4d6c3a81b6 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_bad_request_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Patch_a_vulnerability_based_notification_rule_returns_Bad_Request_response-1738763174","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"flc-8up-dya","type":"notification_rules","attributes":{"created_at":1738763174531,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763174531,"modified_by":{"name":"","handle":""},"name":"Test-Patch_a_vulnerability_based_notification_rule_returns_Bad_Request_response-1738763174","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"fjt-abw-hko","type":"notification_rules","attributes":{"created_at":1787041554666,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041554666,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -26,7 +28,7 @@ interactions: content-type: - application/json method: PATCH - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/flc-8up-dya + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/fjt-abw-hko response: body: string: '{"errors":["input_validation_error(Field ''data.attributes.version'' @@ -44,7 +46,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/flc-8up-dya + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/fjt-abw-hko response: body: string: '' diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.frozen b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.frozen index f3adcb384c..31dc78bdc7 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.frozen +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.frozen @@ -1 +1 @@ -2025-02-05T13:46:15.824Z \ No newline at end of file +2026-08-18T08:25:54.935Z \ No newline at end of file diff --git a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.yaml b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.yaml index 6f21469dd0..a5b3fe2165 100644 --- a/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.yaml +++ b/tests/v2/cassettes/test_scenarios/test_patch_a_vulnerabilitybased_notification_rule_returns_notification_rule_successfully_patched_response.yaml @@ -1,6 +1,6 @@ interactions: - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Test-Patch_a_vulnerability_based_notification_rule_returns_Notification_rule_successfully_patched_respons-1738763175","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"query":"env:test","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400},"type":"notification_rules"}}' headers: accept: - application/json @@ -10,7 +10,9 @@ interactions: uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules response: body: - string: '{"data":{"id":"tnd-jgq-yl5","type":"notification_rules","attributes":{"created_at":1738763176297,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763176297,"modified_by":{"name":"","handle":""},"name":"Test-Patch_a_vulnerability_based_notification_rule_returns_Notification_rule_successfully_patched_respons-1738763175","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' + string: '{"data":{"id":"9be-hlt-vgl","type":"notification_rules","attributes":{"created_at":1787041555020,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041555020,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"env:test","trigger_source":"security_findings"},"targets":["@email@email.com"],"time_aggregation":86400,"version":1}}}' headers: content-type: - application/vnd.api+json @@ -18,7 +20,7 @@ interactions: code: 201 message: Created - request: - body: '{"data":{"attributes":{"enabled":true,"name":"Rule 1","selectors":{"query":"(source:production_service + body: '{"data":{"attributes":{"enabled":true,"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"query":"(source:production_service OR env:prod)","rule_types":["misconfiguration","attack_path"],"severities":["critical"],"trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":1},"id":"aaa-bbb-ccc","type":"notification_rules"}}' headers: accept: @@ -26,11 +28,12 @@ interactions: content-type: - application/json method: PATCH - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/tnd-jgq-yl5 + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/9be-hlt-vgl response: body: - string: '{"data":{"id":"tnd-jgq-yl5","type":"notification_rules","attributes":{"created_at":1738763176297,"created_by":{"name":"","handle":""},"enabled":true,"modified_at":1738763176649,"modified_by":{"name":"","handle":""},"name":"Rule - 1","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service + string: '{"data":{"id":"9be-hlt-vgl","type":"notification_rules","attributes":{"created_at":1787041555020,"created_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"enabled":true,"modified_at":1787041555144,"modified_by":{"name":"CI + Account","handle":"9919ec9b-ebc7-49ee-8dc8-03626e717cca"},"name":"Rule 17870415-0000-0000-0000-178704155400","selectors":{"severities":["critical"],"rule_types":["misconfiguration","attack_path"],"query":"(source:production_service OR env:prod)","trigger_source":"security_findings"},"targets":["@john.doe@email.com"],"time_aggregation":86400,"version":2}}}' headers: content-type: @@ -44,7 +47,7 @@ interactions: accept: - '*/*' method: DELETE - uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/tnd-jgq-yl5 + uri: https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/9be-hlt-vgl response: body: string: '' diff --git a/tests/v2/features/given.json b/tests/v2/features/given.json index 6e48ed1fc5..e4cee92d7a 100644 --- a/tests/v2/features/given.json +++ b/tests/v2/features/given.json @@ -1370,7 +1370,7 @@ "parameters": [ { "name": "body", - "value": "{\n \"data\": {\n \"type\": \"notification_rules\",\n \"attributes\": {\n \"name\": \"{{ unique }}\",\n \"selectors\": {\n \"rule_types\": [\"signal_correlation\"],\n \"trigger_source\": \"security_signals\",\n \"severities\": [\"critical\"],\n \"query\": \"env:test\"\n },\n \"targets\": [\"@email@email.com\"],\n \"enabled\": true\n }\n }\n}" + "value": "{\n \"data\": {\n \"type\": \"notification_rules\",\n \"attributes\": {\n \"name\": \"Rule {{ uuid }}\",\n \"selectors\": {\n \"rule_types\": [\"signal_correlation\"],\n \"trigger_source\": \"security_signals\",\n \"severities\": [\"critical\"],\n \"query\": \"env:test\"\n },\n \"targets\": [\"@email@email.com\"],\n \"enabled\": true\n }\n }\n}" } ], "step": "there is a valid \"valid_signal_notification_rule\" in the system", @@ -1382,7 +1382,7 @@ "parameters": [ { "name": "body", - "value": "{\n \"data\": {\n \"type\": \"notification_rules\",\n \"attributes\": {\n \"name\": \"{{ unique }}\",\n \"selectors\": {\n \"rule_types\": [\"misconfiguration\", \"attack_path\"],\n \"trigger_source\": \"security_findings\",\n \"severities\": [\"critical\"],\n \"query\": \"env:test\"\n },\n \"time_aggregation\": 86400,\n \"targets\": [\"@email@email.com\"],\n \"enabled\": true\n }\n }\n}" + "value": "{\n \"data\": {\n \"type\": \"notification_rules\",\n \"attributes\": {\n \"name\": \"Rule {{ uuid }}\",\n \"selectors\": {\n \"rule_types\": [\"misconfiguration\", \"attack_path\"],\n \"trigger_source\": \"security_findings\",\n \"severities\": [\"critical\"],\n \"query\": \"env:test\"\n },\n \"time_aggregation\": 86400,\n \"targets\": [\"@email@email.com\"],\n \"enabled\": true\n }\n }\n}" } ], "step": "there is a valid \"valid_vulnerability_notification_rule\" in the system", diff --git a/tests/v2/features/security_monitoring.feature b/tests/v2/features/security_monitoring.feature index 14f3d34a11..69917526a2 100644 --- a/tests/v2/features/security_monitoring.feature +++ b/tests/v2/features/security_monitoring.feature @@ -883,7 +883,7 @@ Feature: Security Monitoring @team:DataDog/cloud-security-posture-management Scenario: Create a new signal-based notification rule returns "Successfully created the notification rule." response Given new "CreateSignalNotificationRule" request - And body with value {"data": {"attributes": {"enabled": true, "name": "Rule 1", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400}, "type": "notification_rules"}} + And body with value {"data": {"attributes": {"enabled": true, "name": "Rule {{ uuid }}", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400}, "type": "notification_rules"}} When the request is sent Then the response status is 201 Successfully created the notification rule. @@ -897,7 +897,7 @@ Feature: Security Monitoring @team:DataDog/cloud-security-posture-management Scenario: Create a new vulnerability-based notification rule returns "Successfully created the notification rule." response Given new "CreateVulnerabilityNotificationRule" request - And body with value {"data": {"attributes": {"enabled": true, "name": "Rule 1", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400}, "type": "notification_rules"}} + And body with value {"data": {"attributes": {"enabled": true, "name": "Rule {{ uuid }}", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400}, "type": "notification_rules"}} When the request is sent Then the response status is 201 Successfully created the notification rule. @@ -2810,7 +2810,7 @@ Feature: Security Monitoring Given new "PatchSignalNotificationRule" request And there is a valid "valid_signal_notification_rule" in the system And request contains "id" parameter from "valid_signal_notification_rule.data.id" - And body with value {"data": {"attributes": {"enabled": true, "name": "Rule 1", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400, "version": 1}, "id": "aaa-bbb-ccc", "type": "notification_rules"}} + And body with value {"data": {"attributes": {"enabled": true, "name": "Rule {{ uuid }}", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400, "version": 1}, "id": "aaa-bbb-ccc", "type": "notification_rules"}} When the request is sent Then the response status is 200 Notification rule successfully patched. @@ -2844,7 +2844,7 @@ Feature: Security Monitoring Given new "PatchVulnerabilityNotificationRule" request And there is a valid "valid_vulnerability_notification_rule" in the system And request contains "id" parameter from "valid_vulnerability_notification_rule.data.id" - And body with value {"data": {"attributes": {"enabled": true, "name": "Rule 1", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400, "version": 1}, "id": "aaa-bbb-ccc", "type": "notification_rules"}} + And body with value {"data": {"attributes": {"enabled": true, "name": "Rule {{ uuid }}", "selectors": {"query": "(source:production_service OR env:prod)", "rule_types": ["misconfiguration", "attack_path"], "severities": ["critical"], "trigger_source": "security_findings"}, "targets": ["@john.doe@email.com"], "time_aggregation": 86400, "version": 1}, "id": "aaa-bbb-ccc", "type": "notification_rules"}} When the request is sent Then the response status is 200 Notification rule successfully patched.