diff --git a/examples/v2/csm-threats/CreateCloudWorkloadSecurityAgentRule.rb b/examples/v2/csm-threats/CreateCloudWorkloadSecurityAgentRule.rb index 5c4d5c693a9c..5b30d384defb 100644 --- a/examples/v2/csm-threats/CreateCloudWorkloadSecurityAgentRule.rb +++ b/examples/v2/csm-threats/CreateCloudWorkloadSecurityAgentRule.rb @@ -9,11 +9,29 @@ body = DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleCreateRequest.new({ data: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleCreateData.new({ attributes: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleCreateAttributes.new({ + actions: [ + DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleAction.new({ + coredump: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionCoreDump.new({}), + disabled: false, + _hash: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionHash.new({}), + kill: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleKill.new({}), + log: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionLog.new({}), + metadata: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionMetadata.new({}), + network_filter: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionNetworkFilter.new({}), + set: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionSet.new({}), + }), + ], + blocking: [], description: "My Agent rule", + disabled: [], enabled: true, expression: 'exec.file.name == "sh"', filters: [], - name: "examplecsmthreat", + monitoring: [], + name: "my_agent_rule", + policy_id: "a8c8e364-6556-434d-b798-a4c23de29c0b", + product_tags: [], + silent: false, }), type: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleType::AGENT_RULE, }), diff --git a/examples/v2/csm-threats/DeleteCloudWorkloadSecurityAgentRule.rb b/examples/v2/csm-threats/DeleteCloudWorkloadSecurityAgentRule.rb index 4c25a3cc1820..c0a2e2196ada 100644 --- a/examples/v2/csm-threats/DeleteCloudWorkloadSecurityAgentRule.rb +++ b/examples/v2/csm-threats/DeleteCloudWorkloadSecurityAgentRule.rb @@ -5,7 +5,4 @@ config.access_token = ENV["DD_BEARER_TOKEN"] end api_instance = DatadogAPIClient::V2::CSMThreatsAPI.new - -# there is a valid "agent_rule" in the system -AGENT_RULE_DATA_ID = ENV["AGENT_RULE_DATA_ID"] -api_instance.delete_cloud_workload_security_agent_rule(AGENT_RULE_DATA_ID) +api_instance.delete_cloud_workload_security_agent_rule("agent_rule_id") diff --git a/examples/v2/csm-threats/GetCloudWorkloadSecurityAgentRule.rb b/examples/v2/csm-threats/GetCloudWorkloadSecurityAgentRule.rb index d3a2342428ca..870d27cec4cc 100644 --- a/examples/v2/csm-threats/GetCloudWorkloadSecurityAgentRule.rb +++ b/examples/v2/csm-threats/GetCloudWorkloadSecurityAgentRule.rb @@ -5,7 +5,4 @@ config.access_token = ENV["DD_BEARER_TOKEN"] end api_instance = DatadogAPIClient::V2::CSMThreatsAPI.new - -# there is a valid "agent_rule" in the system -AGENT_RULE_DATA_ID = ENV["AGENT_RULE_DATA_ID"] -p api_instance.get_cloud_workload_security_agent_rule(AGENT_RULE_DATA_ID) +p api_instance.get_cloud_workload_security_agent_rule("agent_rule_id") diff --git a/examples/v2/csm-threats/UpdateCloudWorkloadSecurityAgentRule.rb b/examples/v2/csm-threats/UpdateCloudWorkloadSecurityAgentRule.rb index a08e14e3f5d7..31ca7fa59ac6 100644 --- a/examples/v2/csm-threats/UpdateCloudWorkloadSecurityAgentRule.rb +++ b/examples/v2/csm-threats/UpdateCloudWorkloadSecurityAgentRule.rb @@ -6,17 +6,33 @@ end api_instance = DatadogAPIClient::V2::CSMThreatsAPI.new -# there is a valid "agent_rule" in the system -AGENT_RULE_DATA_ID = ENV["AGENT_RULE_DATA_ID"] - body = DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleUpdateRequest.new({ data: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleUpdateData.new({ attributes: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleUpdateAttributes.new({ - description: "Updated Agent rule", + actions: [ + DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleAction.new({ + coredump: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionCoreDump.new({}), + disabled: false, + _hash: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionHash.new({}), + kill: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleKill.new({}), + log: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionLog.new({}), + metadata: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionMetadata.new({}), + network_filter: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionNetworkFilter.new({}), + set: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleActionSet.new({}), + }), + ], + blocking: [], + description: "My Agent rule", + disabled: [], + enabled: true, expression: 'exec.file.name == "sh"', + monitoring: [], + policy_id: "a8c8e364-6556-434d-b798-a4c23de29c0b", + product_tags: [], + silent: false, }), - id: AGENT_RULE_DATA_ID, + id: "3dd-0uc-h1s", type: DatadogAPIClient::V2::CloudWorkloadSecurityAgentRuleType::AGENT_RULE, }), }) -p api_instance.update_cloud_workload_security_agent_rule(AGENT_RULE_DATA_ID, body) +p api_instance.update_cloud_workload_security_agent_rule("agent_rule_id", body) diff --git a/features/v2/csm_threats.feature b/features/v2/csm_threats.feature index 1efbace75c81..912ae39091bd 100644 --- a/features/v2/csm_threats.feature +++ b/features/v2/csm_threats.feature @@ -13,27 +13,24 @@ Feature: CSM Threats And a valid "appKeyAuth" key in the system And an instance of "CSMThreats" API - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Create a Workload Protection agent rule (US1-FED) returns "Bad Request" response - Given there is a valid "policy_rc" in the system - And new "CreateCloudWorkloadSecurityAgentRule" request - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name", "filters": [], "name": "my_agent_rule"}, "type": "agent_rule"}} + Given new "CreateCloudWorkloadSecurityAgentRule" request + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "filters": [], "monitoring": [], "name": "my_agent_rule", "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "type": "agent_rule"}} When the request is sent Then the response status is 400 Bad Request - @skip @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Create a Workload Protection agent rule (US1-FED) returns "Conflict" response - Given there is a valid "policy_rc" in the system - And new "CreateCloudWorkloadSecurityAgentRule" request - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name == \"sh\"", "filters": [], "name": "my_agent_rule"}, "type": "agent_rule"}} + Given new "CreateCloudWorkloadSecurityAgentRule" request + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "filters": [], "monitoring": [], "name": "my_agent_rule", "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "type": "agent_rule"}} When the request is sent Then the response status is 409 Conflict - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Create a Workload Protection agent rule (US1-FED) returns "OK" response - Given there is a valid "policy_rc" in the system - And new "CreateCloudWorkloadSecurityAgentRule" request - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name == \"sh\"", "filters": [], "name": "{{ unique_lower_alnum }}"}, "type": "agent_rule"}} + Given new "CreateCloudWorkloadSecurityAgentRule" request + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "filters": [], "monitoring": [], "name": "my_agent_rule", "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "type": "agent_rule"}} When the request is sent Then the response status is 200 OK @@ -98,18 +95,17 @@ Feature: CSM Threats When the request is sent Then the response status is 201 Created - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Delete a Workload Protection agent rule (US1-FED) returns "Not Found" response Given new "DeleteCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter with value "non-existent-rule-id" + And request contains "agent_rule_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 404 Not Found - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Delete a Workload Protection agent rule (US1-FED) returns "OK" response - Given there is a valid "agent_rule" in the system - And new "DeleteCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter from "agent_rule.data.id" + Given new "DeleteCloudWorkloadSecurityAgentRule" request + And request contains "agent_rule_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 204 OK @@ -164,11 +160,10 @@ Feature: CSM Threats When the request is sent Then the response status is 404 Not Found - @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Get a Workload Protection agent rule (US1-FED) returns "OK" response - Given there is a valid "agent_rule" in the system - And new "GetCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter from "agent_rule.data.id" + Given new "GetCloudWorkloadSecurityAgentRule" request + And request contains "agent_rule_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 200 OK @@ -222,38 +217,35 @@ Feature: CSM Threats When the request is sent Then the response status is 200 OK - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Update a Workload Protection agent rule (US1-FED) returns "Bad Request" response - Given there is a valid "agent_rule" in the system - And new "UpdateCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter from "agent_rule.data.id" - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name"}, "id": "{{ agent_rule.data.id }}", "type": "agent_rule"}} + Given new "UpdateCloudWorkloadSecurityAgentRule" request + And request contains "agent_rule_id" parameter from "REPLACE.ME" + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "monitoring": [], "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "id": "3dd-0uc-h1s", "type": "agent_rule"}} When the request is sent Then the response status is 400 Bad Request - @skip @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Update a Workload Protection agent rule (US1-FED) returns "Concurrent Modification" response - Given there is a valid "agent_rule" in the system - And new "UpdateCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter from "agent_rule.data.id" - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name == \"sh\""}, "id": "{{ agent_rule.data.id }}", "type": "agent_rule"}} + Given new "UpdateCloudWorkloadSecurityAgentRule" request + And request contains "agent_rule_id" parameter from "REPLACE.ME" + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "monitoring": [], "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "id": "3dd-0uc-h1s", "type": "agent_rule"}} When the request is sent Then the response status is 409 Concurrent Modification - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Update a Workload Protection agent rule (US1-FED) returns "Not Found" response Given new "UpdateCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter with value "non-existent-rule-id" - And body with value {"data": {"attributes": {"description": "My Agent rule", "enabled": true, "expression": "exec.file.name == \"sh\""}, "id": "invalid-agent-rule-id", "type": "agent_rule"}} + And request contains "agent_rule_id" parameter from "REPLACE.ME" + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "monitoring": [], "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "id": "3dd-0uc-h1s", "type": "agent_rule"}} When the request is sent Then the response status is 404 Not Found - @replay-only @team:ddoghq/k9-cws-backend + @generated @skip @team:ddoghq/k9-cws-backend Scenario: Update a Workload Protection agent rule (US1-FED) returns "OK" response - Given there is a valid "agent_rule" in the system - And new "UpdateCloudWorkloadSecurityAgentRule" request - And request contains "agent_rule_id" parameter from "agent_rule.data.id" - And body with value {"data": {"attributes": {"description": "Updated Agent rule", "expression": "exec.file.name == \"sh\""}, "id": "{{ agent_rule.data.id }}", "type": "agent_rule"}} + Given new "UpdateCloudWorkloadSecurityAgentRule" request + And request contains "agent_rule_id" parameter from "REPLACE.ME" + And body with value {"data": {"attributes": {"actions": [{"coredump": {}, "disabled": false, "hash": {}, "kill": {}, "log": {}, "metadata": {}, "network_filter": {}, "set": {}}], "blocking": [], "description": "My Agent rule", "disabled": [], "enabled": true, "expression": "exec.file.name == \"sh\"", "monitoring": [], "policy_id": "a8c8e364-6556-434d-b798-a4c23de29c0b", "product_tags": [], "silent": false}, "id": "3dd-0uc-h1s", "type": "agent_rule"}} When the request is sent Then the response status is 200 OK diff --git a/generated-test/test-runner-data/manifest.json b/generated-test/test-runner-data/manifest.json index 2c68906d492e..55135040cb06 100644 --- a/generated-test/test-runner-data/manifest.json +++ b/generated-test/test-runner-data/manifest.json @@ -4529,20 +4529,6 @@ "scenario": "Get the CSM Serverless Coverage Analysis returns \"OK\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json", - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json", - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "feature_file": "../../features/v2/csm_threats.feature", @@ -4585,20 +4571,6 @@ "scenario": "Create a Workload Protection policy returns \"Created\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json", - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json", - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "feature_file": "../../features/v2/csm_threats.feature", @@ -4648,13 +4620,6 @@ "scenario": "Get a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/get-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json", - "scenario": "Get a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "feature_file": "../../features/v2/csm_threats.feature", @@ -4704,27 +4669,6 @@ "scenario": "Get all Workload Protection policies returns \"OK\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json", - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json", - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "feature_file": "../../features/v2/csm_threats.feature", - "file": "v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json", - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "feature_file": "../../features/v2/csm_threats.feature", diff --git a/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json b/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json deleted file mode 100644 index b4b70d5396ba..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 400, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Create a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "operation_id": "CreateCloudWorkloadSecurityAgentRule", - "request": { - "body": { - "schema": { - "format": null, - "ref": "CloudWorkloadSecurityAgentRuleCreateRequest", - "type": "object" - }, - "source": "inline", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name", - "filters": [], - "name": "my_agent_rule" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "pagination": false, - "parameters": [], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules" - }, - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json b/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json deleted file mode 100644 index c7e6001f2337..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/create-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 200, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Create a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "operation_id": "CreateCloudWorkloadSecurityAgentRule", - "request": { - "body": { - "schema": { - "format": null, - "ref": "CloudWorkloadSecurityAgentRuleCreateRequest", - "type": "object" - }, - "source": "inline", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "filters": [], - "name": "{{ unique_lower_alnum }}" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "pagination": false, - "parameters": [], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules" - }, - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json b/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json deleted file mode 100644 index 962e6bb7cd35..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 404, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Delete a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "operation_id": "DeleteCloudWorkloadSecurityAgentRule", - "request": { - "body": null, - "content_type": null, - "method": "DELETE", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "type": "literal", - "value": "non-existent-rule-id" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json b/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json deleted file mode 100644 index f3a04e63c479..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/delete-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 204, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Delete a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "operation_id": "DeleteCloudWorkloadSecurityAgentRule", - "request": { - "body": null, - "content_type": null, - "method": "DELETE", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "path": "agent_rule.data.id", - "type": "fixture" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/get-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json b/generated-test/test-runner-data/v2/csm-threats/get-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json deleted file mode 100644 index a267c13c742f..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/get-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 200, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Get a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "operation_id": "GetCloudWorkloadSecurityAgentRule", - "request": { - "body": null, - "content_type": null, - "method": "GET", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "path": "agent_rule.data.id", - "type": "fixture" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Get a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json b/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json deleted file mode 100644 index 0b1d46936638..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-bad-request-response.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 400, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Update a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "operation_id": "UpdateCloudWorkloadSecurityAgentRule", - "request": { - "body": { - "schema": { - "format": null, - "ref": "CloudWorkloadSecurityAgentRuleUpdateRequest", - "type": "object" - }, - "source": "inline", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name" - }, - "id": "{{ agent_rule.data.id }}", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "path": "agent_rule.data.id", - "type": "fixture" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json b/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json deleted file mode 100644 index dae086133304..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-not-found-response.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 404, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Update a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "operation_id": "UpdateCloudWorkloadSecurityAgentRule", - "request": { - "body": { - "schema": { - "format": null, - "ref": "CloudWorkloadSecurityAgentRuleUpdateRequest", - "type": "object" - }, - "source": "inline", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"" - }, - "id": "invalid-agent-rule-id", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "type": "literal", - "value": "non-existent-rule-id" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json b/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json deleted file mode 100644 index 7d24620cc3ed..000000000000 --- a/generated-test/test-runner-data/v2/csm-threats/update-a-workload-protection-agent-rule-us1-fed-returns-ok-response.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "api": "CSMThreats", - "expected_status": 200, - "feature": "CSM Threats", - "id": "v2/CSM Threats/Update a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "operation_id": "UpdateCloudWorkloadSecurityAgentRule", - "request": { - "body": { - "schema": { - "format": null, - "ref": "CloudWorkloadSecurityAgentRuleUpdateRequest", - "type": "object" - }, - "source": "inline", - "value": { - "data": { - "attributes": { - "description": "Updated Agent rule", - "expression": "exec.file.name == \"sh\"" - }, - "id": "{{ agent_rule.data.id }}", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "pagination": false, - "parameters": [ - { - "explode": null, - "in": "path", - "name": "agent_rule_id", - "required": true, - "schema": { - "format": null, - "ref": null, - "type": "string" - }, - "source": { - "path": "agent_rule.data.id", - "type": "fixture" - }, - "style": null - } - ], - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/{agent_rule_id}" - }, - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "schema_version": 1, - "version": "v2" -} diff --git a/generated-test/test-server-data/v2/csm-threats.json b/generated-test/test-server-data/v2/csm-threats.json index 77c5a4f64a12..caf1759c1815 100644 --- a/generated-test/test-server-data/v2/csm-threats.json +++ b/generated-test/test-server-data/v2/csm-threats.json @@ -1,223 +1,6 @@ { "feature": "CSM Threats", "recordings": [ - { - "feature": "CSM Threats", - "frozen_at": "2026-10-09T22:19:58.579Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My agent policy", - "enabled": false, - "hostTags": [ - "env:staging" - ], - "name": "testcreateaworkloadprotectionagentruleus1fedreturnsbadrequestresponse1791584398" - }, - "type": "policy" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/remote_config/products/cws/policy", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"rcu-vlu-ths\",\"type\":\"policy\",\"attributes\":{\"blockingRulesCount\":0,\"contentPackUpdateAvailable\":null,\"datadogManaged\":false,\"description\":\"My agent policy\",\"disabledRulesCount\":0,\"enabled\":false,\"hostTagsLists\":[[\"env:staging\"]],\"monitoringRulesCount\":260,\"name\":\"testcreateaworkloadprotectionagentruleus1fedreturnsbadrequestresponse1791584398\",\"pinned\":false,\"policyType\":\"custom\",\"policyVersion\":\"1\",\"ruleCount\":260,\"updateDate\":1791584400171,\"updater\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"}}}}" - }, - "headers": { - "content-type": "application/vnd.api+json" - }, - "reason": "Created", - "status": 201 - } - }, - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name", - "filters": [], - "name": "my_agent_rule" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"errors\":[\"input_validation_error(Field 'expression' is invalid: rule `my_agent_rule` error: rule syntax error: bool expected: 1:1: exec.file.name\\n^)\"]}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "Bad Request", - "status": 400 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/remote_config/products/cws/policy/rcu-vlu-ths", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - } - ], - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "frozen_at": "2026-10-09T22:20:02.057Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My agent policy", - "enabled": false, - "hostTags": [ - "env:staging" - ], - "name": "testcreateaworkloadprotectionagentruleus1fedreturnsokresponse1791584402" - }, - "type": "policy" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/remote_config/products/cws/policy", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"rva-ljb-ty3\",\"type\":\"policy\",\"attributes\":{\"blockingRulesCount\":0,\"contentPackUpdateAvailable\":null,\"datadogManaged\":false,\"description\":\"My agent policy\",\"disabledRulesCount\":0,\"enabled\":false,\"hostTagsLists\":[[\"env:staging\"]],\"monitoringRulesCount\":260,\"name\":\"testcreateaworkloadprotectionagentruleus1fedreturnsokresponse1791584402\",\"pinned\":false,\"policyType\":\"custom\",\"policyVersion\":\"1\",\"ruleCount\":260,\"updateDate\":1791584402268,\"updater\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"}}}}" - }, - "headers": { - "content-type": "application/vnd.api+json" - }, - "reason": "Created", - "status": 201 - } - }, - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "filters": [], - "name": "testcreateaworkloadprotectionagentruleus1fedreturnsokresponse1791584402" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"sb9-egs-p1s\",\"attributes\":{\"version\":1,\"name\":\"testcreateaworkloadprotectionagentruleus1fedreturnsokresponse1791584402\",\"description\":\"My Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"30924c52-076c-4642-b292-7c122aaced8d\",\"creationDate\":1791584402827,\"updateAuthorUuId\":\"30924c52-076c-4642-b292-7c122aaced8d\",\"updateDate\":1791584402827,\"filters\":[],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"},\"updater\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/sb9-egs-p1s", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/remote_config/products/cws/policy/rva-ljb-ty3", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - } - ], - "scenario": "Create a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "frozen_at": "2026-10-13T11:39:15.370Z", @@ -817,7 +600,7 @@ }, { "feature": "CSM Threats", - "frozen_at": "2025-05-27T10:34:26.931Z", + "frozen_at": "2025-12-11T16:09:27.159Z", "interactions": [ { "request": { @@ -827,13 +610,13 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/non-existent-rule-id", + "path": "/api/v2/remote_config/products/cws/agent_rules/non-existent-rule-id", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"errors\":[\"Not found\"]}\n" + "value": "{\"errors\":[{\"title\":\"failed to delete rule\"}]}\n" }, "headers": { "content-type": "application/json" @@ -843,12 +626,12 @@ } } ], - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", + "scenario": "Delete a Workload Protection agent rule returns \"Not Found\" response", "version": "v2" }, { "feature": "CSM Threats", - "frozen_at": "2025-05-27T10:34:16.102Z", + "frozen_at": "2026-10-13T11:39:24.018Z", "interactions": [ { "request": { @@ -857,148 +640,32 @@ "value": { "data": { "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "name": "testdeleteaworkloadprotectionagentruleus1fedreturnsokresponse1748342056" + "description": "My agent policy", + "enabled": false, + "hostTags": [ + "env:staging" + ], + "name": "testdeleteaworkloadprotectionagentrulereturnsokresponse1791891564" }, - "type": "agent_rule" + "type": "policy" } } }, "content_type": "application/json", "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", + "path": "/api/v2/remote_config/products/cws/policy", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"3mv-eeb-jbf\",\"attributes\":{\"version\":1,\"name\":\"testdeleteaworkloadprotectionagentruleus1fedreturnsokresponse1748342056\",\"description\":\"My Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1748342056786,\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1748342056786,\"filters\":[\"os == \\\"linux\\\"\"],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" + "value": "{\"data\":{\"id\":\"ilo-ejm-glm\",\"type\":\"policy\",\"attributes\":{\"blockingRulesCount\":0,\"contentPackUpdateAvailable\":null,\"datadogManaged\":false,\"description\":\"My agent policy\",\"disabledRulesCount\":0,\"enabled\":false,\"hostTagsLists\":[[\"env:staging\"]],\"monitoringRulesCount\":92,\"name\":\"testdeleteaworkloadprotectionagentrulereturnsokresponse1791891564\",\"pinned\":false,\"policyType\":\"custom\",\"policyVersion\":\"1\",\"ruleCount\":92,\"updateDate\":1791891564121,\"updater\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"}}}}" }, "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/3mv-eeb-jbf", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" + "content-type": "application/vnd.api+json" }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/3mv-eeb-jbf", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"errors\":[\"not_found(Agent rule not found: agentRuleId=3mv-eeb-jbf)\"]}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "Not Found", - "status": 404 - } - } - ], - "scenario": "Delete a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "frozen_at": "2025-12-11T16:09:27.159Z", - "interactions": [ - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/remote_config/products/cws/agent_rules/non-existent-rule-id", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"errors\":[{\"title\":\"failed to delete rule\"}]}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "Not Found", - "status": 404 - } - } - ], - "scenario": "Delete a Workload Protection agent rule returns \"Not Found\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "frozen_at": "2026-10-13T11:39:24.018Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My agent policy", - "enabled": false, - "hostTags": [ - "env:staging" - ], - "name": "testdeleteaworkloadprotectionagentrulereturnsokresponse1791891564" - }, - "type": "policy" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/remote_config/products/cws/policy", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"ilo-ejm-glm\",\"type\":\"policy\",\"attributes\":{\"blockingRulesCount\":0,\"contentPackUpdateAvailable\":null,\"datadogManaged\":false,\"description\":\"My agent policy\",\"disabledRulesCount\":0,\"enabled\":false,\"hostTagsLists\":[[\"env:staging\"]],\"monitoringRulesCount\":92,\"name\":\"testdeleteaworkloadprotectionagentrulereturnsokresponse1791891564\",\"pinned\":false,\"policyType\":\"custom\",\"policyVersion\":\"1\",\"ruleCount\":92,\"updateDate\":1791891564121,\"updater\":{\"name\":\"C\u00e9dric Van Rompay\",\"handle\":\"cedric.vanrompay@datadoghq.com\"}}}}" - }, - "headers": { - "content-type": "application/vnd.api+json" - }, - "reason": "Created", - "status": 201 + "reason": "Created", + "status": 201 } }, { @@ -1336,91 +1003,6 @@ "scenario": "Get a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "frozen_at": "2025-12-11T16:09:37.390Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "name": "testgetaworkloadprotectionagentruleus1fedreturnsokresponse1765469377" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"gdb-grp-c2f\",\"attributes\":{\"version\":1,\"name\":\"testgetaworkloadprotectionagentruleus1fedreturnsokresponse1765469377\",\"description\":\"My Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1765469377827,\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1765469377827,\"filters\":[\"os == \\\"linux\\\"\"],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "GET", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/gdb-grp-c2f", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"gdb-grp-c2f\",\"type\":\"agent_rule\",\"attributes\":{\"actions\":[],\"agentConstraint\":\"\",\"category\":\"Process Activity\",\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1765469377827,\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"defaultRule\":false,\"description\":\"My Agent rule\",\"enabled\":true,\"expression\":\"exec.file.name == \\\"sh\\\"\",\"filters\":[\"os == \\\"linux\\\"\"],\"name\":\"testgetaworkloadprotectionagentruleus1fedreturnsokresponse1765469377\",\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1765469377827,\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"version\":1}}}" - }, - "headers": { - "content-type": "application/vnd.api+json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/gdb-grp-c2f", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - } - ], - "scenario": "Get a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "frozen_at": "2025-12-11T16:09:38.988Z", @@ -1826,236 +1408,6 @@ "scenario": "Get all Workload Protection policies returns \"OK\" response", "version": "v2" }, - { - "feature": "CSM Threats", - "frozen_at": "2025-05-27T10:34:05.620Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "name": "testupdateaworkloadprotectionagentruleus1fedreturnsbadrequestresponse1748342045" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"q58-cpj-dtw\",\"attributes\":{\"version\":1,\"name\":\"testupdateaworkloadprotectionagentruleus1fedreturnsbadrequestresponse1748342045\",\"description\":\"My Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1748342046325,\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1748342046325,\"filters\":[\"os == \\\"linux\\\"\"],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name" - }, - "id": "q58-cpj-dtw", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/q58-cpj-dtw", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"errors\":[\"input_validation_error(Field 'expression' is invalid: rule `testupdateaworkloadprotectionagentruleus1fedreturnsbadrequestresponse1748342045` error: rule syntax error: bool expected: 1:1: exec.file.name\\n^)\"]}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "Bad Request", - "status": 400 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/q58-cpj-dtw", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - } - ], - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Bad Request\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "frozen_at": "2025-05-27T10:33:55.255Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"" - }, - "id": "invalid-agent-rule-id", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/non-existent-rule-id", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"errors\":[\"Not found\"]}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "Not Found", - "status": 404 - } - } - ], - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"Not Found\" response", - "version": "v2" - }, - { - "feature": "CSM Threats", - "frozen_at": "2025-05-27T10:33:43.912Z", - "interactions": [ - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "My Agent rule", - "enabled": true, - "expression": "exec.file.name == \"sh\"", - "name": "testupdateaworkloadprotectionagentruleus1fedreturnsokresponse1748342023" - }, - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "POST", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"dz8-9mj-136\",\"attributes\":{\"version\":1,\"name\":\"testupdateaworkloadprotectionagentruleus1fedreturnsokresponse1748342023\",\"description\":\"My Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1748342024616,\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1748342024616,\"filters\":[\"os == \\\"linux\\\"\"],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "json", - "value": { - "data": { - "attributes": { - "description": "Updated Agent rule", - "expression": "exec.file.name == \"sh\"" - }, - "id": "dz8-9mj-136", - "type": "agent_rule" - } - } - }, - "content_type": "application/json", - "method": "PATCH", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/dz8-9mj-136", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "{\"data\":{\"id\":\"dz8-9mj-136\",\"attributes\":{\"version\":2,\"name\":\"testupdateaworkloadprotectionagentruleus1fedreturnsokresponse1748342023\",\"description\":\"Updated Agent rule\",\"expression\":\"exec.file.name == \\\"sh\\\"\",\"category\":\"Process Activity\",\"defaultRule\":false,\"enabled\":true,\"creationAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"creationDate\":1748342024616,\"updateAuthorUuId\":\"3ad549bf-eba0-11e9-a77a-0705486660d0\",\"updateDate\":1748342024959,\"filters\":[\"os == \\\"linux\\\"\"],\"actions\":[],\"agentConstraint\":\"\",\"creator\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"},\"updater\":{\"name\":\"frog\",\"handle\":\"frog@datadoghq.com\"}},\"type\":\"agent_rule\"}}\n" - }, - "headers": { - "content-type": "application/json" - }, - "reason": "OK", - "status": 200 - } - }, - { - "request": { - "body": { - "type": "empty", - "value": null - }, - "content_type": "", - "method": "DELETE", - "path": "/api/v2/security_monitoring/cloud_workload_security/agent_rules/dz8-9mj-136", - "query": [] - }, - "response": { - "body": { - "encoding": "text", - "value": "" - }, - "headers": {}, - "reason": "No Content", - "status": 204 - } - } - ], - "scenario": "Update a Workload Protection agent rule (US1-FED) returns \"OK\" response", - "version": "v2" - }, { "feature": "CSM Threats", "frozen_at": "2026-10-13T11:39:30.785Z",