diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 90e97c4cc9de..075f40ce1592 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -37239,7 +37239,7 @@ components: - data type: object DueDateRuleDataCreate: - description: The data object for a due date rule create or update request. + description: The data object for a due date rule create request. properties: attributes: $ref: "#/components/schemas/DueDateRuleAttributesCreate" @@ -37266,6 +37266,23 @@ components: - type - attributes type: object + DueDateRuleDataUpdate: + description: The data object for a due date rule update request. The `id` must match the `rule_id` path parameter. + properties: + attributes: + $ref: "#/components/schemas/DueDateRuleAttributesCreate" + id: + description: The ID of the due date rule to update. + example: "00000000-0000-0000-0000-000000000000" + format: uuid + type: string + type: + $ref: "#/components/schemas/DueDateRuleType" + required: + - id + - type + - attributes + type: object DueDateRuleReorderData: description: The ordered list of all due date rules. Every rule must be included. items: @@ -37286,7 +37303,15 @@ components: - id type: object DueDateRuleReorderRequest: - description: The body of the due date rule reorder request. + description: The body of a due date rule reorder request. + properties: + data: + $ref: "#/components/schemas/DueDateRuleReorderData" + required: + - data + type: object + DueDateRuleReorderResponse: + description: The response of a due date rule reorder request. properties: data: $ref: "#/components/schemas/DueDateRuleReorderData" @@ -37313,7 +37338,7 @@ components: description: The body of a due date rule update request. properties: data: - $ref: "#/components/schemas/DueDateRuleDataCreate" + $ref: "#/components/schemas/DueDateRuleDataUpdate" required: - data type: object @@ -73704,7 +73729,7 @@ components: - data type: object MuteRuleDataCreate: - description: The data object for a mute rule create or update request. + description: The data object for a mute rule create request. properties: attributes: $ref: "#/components/schemas/MuteRuleAttributesCreate" @@ -73731,6 +73756,23 @@ components: - type - attributes type: object + MuteRuleDataUpdate: + description: The data object for a mute rule update request. The `id` must match the `rule_id` path parameter. + properties: + attributes: + $ref: "#/components/schemas/MuteRuleAttributesCreate" + id: + description: The ID of the mute rule to update. + example: "00000000-0000-0000-0000-000000000000" + format: uuid + type: string + type: + $ref: "#/components/schemas/MuteRuleType" + required: + - id + - type + - attributes + type: object MuteRuleReorderData: description: The ordered list of all mute rules. Every rule must be included. items: @@ -73751,7 +73793,15 @@ components: - id type: object MuteRuleReorderRequest: - description: The body of the mute rule reorder request. + description: The body of a mute rule reorder request. + properties: + data: + $ref: "#/components/schemas/MuteRuleReorderData" + required: + - data + type: object + MuteRuleReorderResponse: + description: The response of a mute rule reorder request. properties: data: $ref: "#/components/schemas/MuteRuleReorderData" @@ -73778,7 +73828,7 @@ components: description: The body of a mute rule update request. properties: data: - $ref: "#/components/schemas/MuteRuleDataCreate" + $ref: "#/components/schemas/MuteRuleDataUpdate" required: - data type: object @@ -110641,7 +110691,7 @@ components: - data type: object SeverityModifierRuleDataCreate: - description: The data object for a severity modifier rule create or update request. + description: The data object for a severity modifier rule create request. properties: attributes: $ref: "#/components/schemas/SeverityModifierRuleAttributesCreate" @@ -110668,6 +110718,23 @@ components: - type - attributes type: object + SeverityModifierRuleDataUpdate: + description: The data object for a severity modifier rule update request. The `id` must match the `rule_id` path parameter. + properties: + attributes: + $ref: "#/components/schemas/SeverityModifierRuleAttributesCreate" + id: + description: The ID of the severity modifier rule to update. + example: "00000000-0000-0000-0000-000000000000" + format: uuid + type: string + type: + $ref: "#/components/schemas/SeverityModifierRuleType" + required: + - id + - type + - attributes + type: object SeverityModifierRuleReorderData: description: The ordered list of all severity modifier rules. Every rule must be included. items: @@ -110771,7 +110838,7 @@ components: description: The body of a severity modifier rule update request. properties: data: - $ref: "#/components/schemas/SeverityModifierRuleDataCreate" + $ref: "#/components/schemas/SeverityModifierRuleDataUpdate" required: - data type: object @@ -123805,7 +123872,7 @@ components: - data type: object TicketCreationRuleDataCreate: - description: The data object for a ticket creation rule create or update request. + description: The data object for a ticket creation rule create request. properties: attributes: $ref: "#/components/schemas/TicketCreationRuleAttributesCreate" @@ -123832,6 +123899,23 @@ components: - type - attributes type: object + TicketCreationRuleDataUpdate: + description: The data object for a ticket creation rule update request. The `id` must match the `rule_id` path parameter. + properties: + attributes: + $ref: "#/components/schemas/TicketCreationRuleAttributesCreate" + id: + description: The ID of the ticket creation rule to update. + example: "00000000-0000-0000-0000-000000000000" + format: uuid + type: string + type: + $ref: "#/components/schemas/TicketCreationRuleType" + required: + - id + - type + - attributes + type: object TicketCreationRuleReorderData: description: The ordered list of all ticket creation rules. Every rule must be included. items: @@ -123852,7 +123936,15 @@ components: - id type: object TicketCreationRuleReorderRequest: - description: The body of the ticket creation rule reorder request. + description: The body of a ticket creation rule reorder request. + properties: + data: + $ref: "#/components/schemas/TicketCreationRuleReorderData" + required: + - data + type: object + TicketCreationRuleReorderResponse: + description: The response of a ticket creation rule reorder request. properties: data: $ref: "#/components/schemas/TicketCreationRuleReorderData" @@ -123879,7 +123971,7 @@ components: description: The body of a ticket creation rule update request. properties: data: - $ref: "#/components/schemas/TicketCreationRuleDataCreate" + $ref: "#/components/schemas/TicketCreationRuleDataUpdate" required: - data type: object @@ -205416,7 +205508,7 @@ paths: - id: "11111111-1111-1111-1111-111111111111" type: due_date_rules schema: - $ref: "#/components/schemas/DueDateRuleReorderRequest" + $ref: "#/components/schemas/DueDateRuleReorderResponse" description: Successfully reordered the due date rules "400": content: @@ -205589,6 +205681,7 @@ paths: finding_types: - misconfiguration query: "env:prod" + id: "00000000-0000-0000-0000-000000000000" type: due_date_rules schema: $ref: "#/components/schemas/DueDateRuleUpdateRequest" @@ -206300,7 +206393,7 @@ paths: - id: "11111111-1111-1111-1111-111111111111" type: mute_rules schema: - $ref: "#/components/schemas/MuteRuleReorderRequest" + $ref: "#/components/schemas/MuteRuleReorderResponse" description: Successfully reordered the mute rules "400": content: @@ -206463,6 +206556,7 @@ paths: finding_types: - misconfiguration query: "env:dev" + id: "00000000-0000-0000-0000-000000000000" type: mute_rules schema: $ref: "#/components/schemas/MuteRuleUpdateRequest" @@ -206915,6 +207009,7 @@ paths: finding_types: - misconfiguration query: "env:dev" + id: "00000000-0000-0000-0000-000000000000" type: severity_modifier_rules schema: $ref: "#/components/schemas/SeverityModifierRuleUpdateRequest" @@ -207190,7 +207285,7 @@ paths: - id: "11111111-1111-1111-1111-111111111111" type: ticket_creation_rules schema: - $ref: "#/components/schemas/TicketCreationRuleReorderRequest" + $ref: "#/components/schemas/TicketCreationRuleReorderResponse" description: Successfully reordered the ticket creation rules "400": content: @@ -207355,6 +207450,7 @@ paths: finding_types: - misconfiguration query: "env:prod" + id: "00000000-0000-0000-0000-000000000000" type: ticket_creation_rules schema: $ref: "#/components/schemas/TicketCreationRuleUpdateRequest" diff --git a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationDueDateRule.rb b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationDueDateRule.rb index 673bfb1eb96b..1ca860beb5c4 100644 --- a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationDueDateRule.rb +++ b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationDueDateRule.rb @@ -11,7 +11,7 @@ VALID_DUE_DATE_RULE_DATA_ID = ENV["VALID_DUE_DATE_RULE_DATA_ID"] body = DatadogAPIClient::V2::DueDateRuleUpdateRequest.new({ - data: DatadogAPIClient::V2::DueDateRuleDataCreate.new({ + data: DatadogAPIClient::V2::DueDateRuleDataUpdate.new({ attributes: DatadogAPIClient::V2::DueDateRuleAttributesCreate.new({ action: DatadogAPIClient::V2::DueDateRuleAction.new({ due_days_per_severity: [ @@ -31,6 +31,7 @@ query: "env:staging", }), }), + id: VALID_DUE_DATE_RULE_DATA_ID, type: DatadogAPIClient::V2::DueDateRuleType::DUE_DATE_RULES, }), }) diff --git a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationMuteRule.rb b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationMuteRule.rb index 01ed3a55acec..d64c79d7afc4 100644 --- a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationMuteRule.rb +++ b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationMuteRule.rb @@ -11,7 +11,7 @@ VALID_MUTE_RULE_DATA_ID = ENV["VALID_MUTE_RULE_DATA_ID"] body = DatadogAPIClient::V2::MuteRuleUpdateRequest.new({ - data: DatadogAPIClient::V2::MuteRuleDataCreate.new({ + data: DatadogAPIClient::V2::MuteRuleDataUpdate.new({ attributes: DatadogAPIClient::V2::MuteRuleAttributesCreate.new({ action: DatadogAPIClient::V2::MuteRuleAction.new({ reason: DatadogAPIClient::V2::MuteReason::FALSE_POSITIVE, @@ -25,6 +25,7 @@ query: "env:staging", }), }), + id: VALID_MUTE_RULE_DATA_ID, type: DatadogAPIClient::V2::MuteRuleType::MUTE_RULES, }), }) diff --git a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationSeverityModifierRule.rb b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationSeverityModifierRule.rb index 81291ab473cf..6220c1a68794 100644 --- a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationSeverityModifierRule.rb +++ b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationSeverityModifierRule.rb @@ -11,7 +11,7 @@ VALID_SEVERITY_MODIFIER_RULE_DATA_ID = ENV["VALID_SEVERITY_MODIFIER_RULE_DATA_ID"] body = DatadogAPIClient::V2::SeverityModifierRuleUpdateRequest.new({ - data: DatadogAPIClient::V2::SeverityModifierRuleDataCreate.new({ + data: DatadogAPIClient::V2::SeverityModifierRuleDataUpdate.new({ attributes: DatadogAPIClient::V2::SeverityModifierRuleAttributesCreate.new({ action: DatadogAPIClient::V2::SeverityModifierRuleSetAction.new({ description: "Lower severity for dev environment noise", @@ -27,6 +27,7 @@ query: "env:prod team:platform", }), }), + id: VALID_SEVERITY_MODIFIER_RULE_DATA_ID, type: DatadogAPIClient::V2::SeverityModifierRuleType::SEVERITY_MODIFIER_RULES, }), }) diff --git a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationTicketCreationRule.rb b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationTicketCreationRule.rb index 1368643cb972..1e7ff042b9a3 100644 --- a/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationTicketCreationRule.rb +++ b/examples/v2/security-monitoring/UpdateSecurityFindingsAutomationTicketCreationRule.rb @@ -11,7 +11,7 @@ VALID_TICKET_CREATION_RULE_DATA_ID = ENV["VALID_TICKET_CREATION_RULE_DATA_ID"] body = DatadogAPIClient::V2::TicketCreationRuleUpdateRequest.new({ - data: DatadogAPIClient::V2::TicketCreationRuleDataCreate.new({ + data: DatadogAPIClient::V2::TicketCreationRuleDataUpdate.new({ attributes: DatadogAPIClient::V2::TicketCreationRuleAttributesCreate.new({ action: DatadogAPIClient::V2::TicketCreationRuleAction.new({ max_tickets_per_day: 5, @@ -27,6 +27,7 @@ query: "env:staging", }), }), + id: VALID_TICKET_CREATION_RULE_DATA_ID, type: DatadogAPIClient::V2::TicketCreationRuleType::TICKET_CREATION_RULES, }), }) diff --git a/features/v2/security_monitoring.feature b/features/v2/security_monitoring.feature index cf9a335e2219..4a3d03be1c66 100644 --- a/features/v2/security_monitoring.feature +++ b/features/v2/security_monitoring.feature @@ -1049,7 +1049,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 400 Bad Request - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Create an inbox rule returns "Successfully created the inbox rule" response Given operation "CreateSecurityFindingsAutomationInboxRule" enabled And new "CreateSecurityFindingsAutomationInboxRule" request @@ -1493,7 +1493,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Delete an inbox rule returns "Successfully deleted the inbox rule" response Given operation "DeleteSecurityFindingsAutomationInboxRule" enabled And there is a valid "valid_inbox_rule" in the system @@ -1531,7 +1531,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Disable a default inbox rule returns "Successfully disabled the default inbox rule" response Given operation "DisableSecurityFindingsAutomationDefaultInboxRule" enabled And new "DisableSecurityFindingsAutomationDefaultInboxRule" request @@ -1550,7 +1550,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Enable a default inbox rule returns "Successfully enabled the default inbox rule" response Given operation "EnableSecurityFindingsAutomationDefaultInboxRule" enabled And new "EnableSecurityFindingsAutomationDefaultInboxRule" request @@ -1784,7 +1784,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Get a default inbox rule returns "Successfully retrieved the default inbox rule" response Given operation "GetSecurityFindingsAutomationDefaultInboxRule" enabled And new "GetSecurityFindingsAutomationDefaultInboxRule" request @@ -2159,7 +2159,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 200 OK - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Get all default inbox rules returns "Successfully retrieved the list of default inbox rules" response Given operation "ListSecurityFindingsAutomationDefaultInboxRules" enabled And new "ListSecurityFindingsAutomationDefaultInboxRules" request @@ -2176,7 +2176,7 @@ Feature: Security Monitoring Then the response status is 200 Successfully retrieved the list of due date rules And the response "data" has item with field "id" with value "{{ valid_due_date_rule.data.id }}" - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Get all inbox rules returns "Successfully retrieved the list of inbox rules" response Given operation "ListSecurityFindingsAutomationInboxRules" enabled And there is a valid "valid_inbox_rule" in the system @@ -2291,7 +2291,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Get an inbox rule returns "Successfully retrieved the inbox rule" response Given operation "GetSecurityFindingsAutomationInboxRule" enabled And there is a valid "valid_inbox_rule" in the system @@ -3180,7 +3180,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 400 Bad Request - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Reorder inbox rules returns "Successfully reordered the inbox rules" response Given operation "ReorderSecurityFindingsAutomationInboxRules" enabled And there is a valid "valid_inbox_rule" in the system @@ -3622,7 +3622,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationDueDateRule" enabled And new "UpdateSecurityFindingsAutomationDueDateRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "due_date_rules"}} + And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "due_date_rules"}} When the request is sent Then the response status is 400 Bad Request @@ -3631,7 +3631,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationDueDateRule" enabled And new "UpdateSecurityFindingsAutomationDueDateRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "due_date_rules"}} + And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "due_date_rules"}} When the request is sent Then the response status is 404 Not Found @@ -3641,7 +3641,7 @@ Feature: Security Monitoring And there is a valid "valid_due_date_rule" in the system And new "UpdateSecurityFindingsAutomationDueDateRule" request And request contains "rule_id" parameter from "valid_due_date_rule.data.id" - And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 14, "severity": "critical"}], "due_from": "first_seen"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "type": "due_date_rules"}} + And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 14, "severity": "critical"}], "due_from": "first_seen"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "id": "{{ valid_due_date_rule.data.id }}", "type": "due_date_rules"}} When the request is sent Then the response status is 200 Successfully updated the due date rule And the response "data.id" is equal to "{{ valid_due_date_rule.data.id }}" @@ -3652,7 +3652,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationDueDateRule" enabled And new "UpdateSecurityFindingsAutomationDueDateRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "due_date_rules"}} + And body with value {"data": {"attributes": {"action": {"due_days_per_severity": [{"due_in_days": 7, "severity": "critical"}], "due_from": "first_seen", "reason_description": "Applied for production findings only"}, "enabled": true, "name": "Critical findings due in 7 days", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "due_date_rules"}} When the request is sent Then the response status is 422 Unprocessable Entity @@ -3661,7 +3661,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationMuteRule" enabled And new "UpdateSecurityFindingsAutomationMuteRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "mute_rules"}} + And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "mute_rules"}} When the request is sent Then the response status is 400 Bad Request @@ -3670,7 +3670,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationMuteRule" enabled And new "UpdateSecurityFindingsAutomationMuteRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "mute_rules"}} + And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "mute_rules"}} When the request is sent Then the response status is 404 Not Found @@ -3680,7 +3680,7 @@ Feature: Security Monitoring And there is a valid "valid_mute_rule" in the system And new "UpdateSecurityFindingsAutomationMuteRule" request And request contains "rule_id" parameter from "valid_mute_rule.data.id" - And body with value {"data": {"attributes": {"action": {"reason": "false_positive"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "type": "mute_rules"}} + And body with value {"data": {"attributes": {"action": {"reason": "false_positive"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "id": "{{ valid_mute_rule.data.id }}", "type": "mute_rules"}} When the request is sent Then the response status is 200 Successfully updated the mute rule And the response "data.id" is equal to "{{ valid_mute_rule.data.id }}" @@ -3691,7 +3691,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationMuteRule" enabled And new "UpdateSecurityFindingsAutomationMuteRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "mute_rules"}} + And body with value {"data": {"attributes": {"action": {"expire_at": 4070908800000, "reason": "risk_accepted", "reason_description": "Accepted for dev environments only"}, "enabled": true, "name": "Mute accepted risks in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "mute_rules"}} When the request is sent Then the response status is 422 Unprocessable Entity @@ -3736,7 +3736,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationSeverityModifierRule" enabled And new "UpdateSecurityFindingsAutomationSeverityModifierRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "severity_modifier_rules"}} + And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "severity_modifier_rules"}} When the request is sent Then the response status is 400 Bad Request @@ -3745,7 +3745,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationSeverityModifierRule" enabled And new "UpdateSecurityFindingsAutomationSeverityModifierRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "severity_modifier_rules"}} + And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "severity_modifier_rules"}} When the request is sent Then the response status is 404 Not Found @@ -3755,7 +3755,7 @@ Feature: Security Monitoring And there is a valid "valid_severity_modifier_rule" in the system And new "UpdateSecurityFindingsAutomationSeverityModifierRule" request And request contains "rule_id" parameter from "valid_severity_modifier_rule.data.id" - And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "severity_modifier_rules"}} + And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "{{ valid_severity_modifier_rule.data.id }}", "type": "severity_modifier_rules"}} When the request is sent Then the response status is 200 Successfully updated the severity modifier rule @@ -3764,7 +3764,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationSeverityModifierRule" enabled And new "UpdateSecurityFindingsAutomationSeverityModifierRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "severity_modifier_rules"}} + And body with value {"data": {"attributes": {"action": {"description": "Lower severity for dev environment noise", "severity": "low", "type": "set"}, "enabled": true, "name": "Downgrade misconfigurations in dev", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "severity_modifier_rules"}} When the request is sent Then the response status is 422 Unprocessable Entity @@ -3809,7 +3809,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationTicketCreationRule" enabled And new "UpdateSecurityFindingsAutomationTicketCreationRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "ticket_creation_rules"}} + And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "ticket_creation_rules"}} When the request is sent Then the response status is 400 Bad Request @@ -3818,7 +3818,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationTicketCreationRule" enabled And new "UpdateSecurityFindingsAutomationTicketCreationRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "ticket_creation_rules"}} + And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "ticket_creation_rules"}} When the request is sent Then the response status is 404 Not Found @@ -3828,7 +3828,7 @@ Feature: Security Monitoring And there is a valid "valid_ticket_creation_rule" in the system And new "UpdateSecurityFindingsAutomationTicketCreationRule" request And request contains "rule_id" parameter from "valid_ticket_creation_rule.data.id" - And body with value {"data": {"attributes": {"action": {"max_tickets_per_day": 5, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "type": "ticket_creation_rules"}} + And body with value {"data": {"attributes": {"action": {"max_tickets_per_day": 5, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": false, "name": "{{ unique }}", "rule": {"finding_types": ["misconfiguration"], "query": "env:staging"}}, "id": "{{ valid_ticket_creation_rule.data.id }}", "type": "ticket_creation_rules"}} When the request is sent Then the response status is 200 Successfully updated the ticket creation rule And the response "data.id" is equal to "{{ valid_ticket_creation_rule.data.id }}" @@ -3839,7 +3839,7 @@ Feature: Security Monitoring Given operation "UpdateSecurityFindingsAutomationTicketCreationRule" enabled And new "UpdateSecurityFindingsAutomationTicketCreationRule" request And request contains "rule_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "type": "ticket_creation_rules"}} + And body with value {"data": {"attributes": {"action": {"assignee_id": "22222222-2222-2222-2222-222222222222", "fields": {"labels": ["security"]}, "max_tickets_per_day": 100, "project_id": "11111111-1111-1111-1111-111111111111", "target": "jira"}, "enabled": true, "name": "Auto-create Jira tickets for critical findings", "rule": {"finding_types": ["misconfiguration"], "query": "env:prod team:platform"}}, "id": "00000000-0000-0000-0000-000000000000", "type": "ticket_creation_rules"}} When the request is sent Then the response status is 422 Unprocessable Entity @@ -3916,7 +3916,7 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found - @skip @team:DataDog/k9-automation + @team:DataDog/k9-automation Scenario: Update an inbox rule returns "Successfully updated the inbox rule" response Given operation "UpdateSecurityFindingsAutomationInboxRule" enabled And there is a valid "valid_inbox_rule" in the system diff --git a/generated-test/test-runner-data/manifest.json b/generated-test/test-runner-data/manifest.json index 499ab3da1e1b..875e8dad19d0 100644 --- a/generated-test/test-runner-data/manifest.json +++ b/generated-test/test-runner-data/manifest.json @@ -9541,6 +9541,13 @@ "scenario": "Create a ticket creation rule returns \"Successfully created the ticket creation rule\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/create-an-inbox-rule-returns-successfully-created-the-inbox-rule-response.json", + "scenario": "Create an inbox rule returns \"Successfully created the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9709,6 +9716,13 @@ "scenario": "Delete an existing rule returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/delete-an-inbox-rule-returns-successfully-deleted-the-inbox-rule-response.json", + "scenario": "Delete an inbox rule returns \"Successfully deleted the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9730,6 +9744,20 @@ "scenario": "Detach security findings from their case returns \"Not Found\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/disable-a-default-inbox-rule-returns-successfully-disabled-the-default-inbox-rule-response.json", + "scenario": "Disable a default inbox rule returns \"Successfully disabled the default inbox rule\" response", + "version": "v2" + }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/enable-a-default-inbox-rule-returns-successfully-enabled-the-default-inbox-rule-response.json", + "scenario": "Enable a default inbox rule returns \"Successfully enabled the default inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9786,6 +9814,13 @@ "scenario": "Get a custom framework returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/get-a-default-inbox-rule-returns-successfully-retrieved-the-default-inbox-rule-response.json", + "scenario": "Get a default inbox rule returns \"Successfully retrieved the default inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9933,6 +9968,13 @@ "scenario": "Get all critical assets returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/get-all-default-inbox-rules-returns-successfully-retrieved-the-list-of-default-inbox-rules-response.json", + "scenario": "Get all default inbox rules returns \"Successfully retrieved the list of default inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9940,6 +9982,13 @@ "scenario": "Get all due date rules returns \"Successfully retrieved the list of due date rules\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/get-all-inbox-rules-returns-successfully-retrieved-the-list-of-inbox-rules-response.json", + "scenario": "Get all inbox rules returns \"Successfully retrieved the list of inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -9989,6 +10038,13 @@ "scenario": "Get all ticket creation rules returns \"Successfully retrieved the list of ticket creation rules\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/get-an-inbox-rule-returns-successfully-retrieved-the-inbox-rule-response.json", + "scenario": "Get an inbox rule returns \"Successfully retrieved the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -10297,6 +10353,13 @@ "scenario": "Reorder due date rules returns \"Successfully reordered the due date rules\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/reorder-inbox-rules-returns-successfully-reordered-the-inbox-rules-response.json", + "scenario": "Reorder inbox rules returns \"Successfully reordered the inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", @@ -10514,6 +10577,13 @@ "scenario": "Update an existing rule returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "feature_file": "../../features/v2/security_monitoring.feature", + "file": "v2/security-monitoring/update-an-inbox-rule-returns-successfully-updated-the-inbox-rule-response.json", + "scenario": "Update an inbox rule returns \"Successfully updated the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "feature_file": "../../features/v2/security_monitoring.feature", diff --git a/generated-test/test-runner-data/v2/security-monitoring/create-an-inbox-rule-returns-successfully-created-the-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/create-an-inbox-rule-returns-successfully-created-the-inbox-rule-response.json new file mode 100644 index 000000000000..032647e423dc --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/create-an-inbox-rule-returns-successfully-created-the-inbox-rule-response.json @@ -0,0 +1,43 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 201, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Create an inbox rule returns \"Successfully created the inbox rule\" response", + "operation_id": "CreateSecurityFindingsAutomationInboxRule", + "request": { + "body": { + "schema": { + "format": null, + "ref": "InboxRuleCreateRequest", + "type": "object" + }, + "source": "inline", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "{{ unique }}", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "pagination": false, + "parameters": [], + "path": "/api/v2/security/findings/automation/inbox_rules" + }, + "scenario": "Create an inbox rule returns \"Successfully created the inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/delete-an-inbox-rule-returns-successfully-deleted-the-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/delete-an-inbox-rule-returns-successfully-deleted-the-inbox-rule-response.json new file mode 100644 index 000000000000..c00c2842a4af --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/delete-an-inbox-rule-returns-successfully-deleted-the-inbox-rule-response.json @@ -0,0 +1,35 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 204, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Delete an inbox rule returns \"Successfully deleted the inbox rule\" response", + "operation_id": "DeleteSecurityFindingsAutomationInboxRule", + "request": { + "body": null, + "content_type": null, + "method": "DELETE", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": "uuid", + "ref": null, + "type": "string" + }, + "source": { + "path": "valid_inbox_rule.data.id", + "type": "fixture" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/inbox_rules/{rule_id}" + }, + "scenario": "Delete an inbox rule returns \"Successfully deleted the inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/disable-a-default-inbox-rule-returns-successfully-disabled-the-default-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/disable-a-default-inbox-rule-returns-successfully-disabled-the-default-inbox-rule-response.json new file mode 100644 index 000000000000..9e1ab4378f7d --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/disable-a-default-inbox-rule-returns-successfully-disabled-the-default-inbox-rule-response.json @@ -0,0 +1,35 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Disable a default inbox rule returns \"Successfully disabled the default inbox rule\" response", + "operation_id": "DisableSecurityFindingsAutomationDefaultInboxRule", + "request": { + "body": null, + "content_type": null, + "method": "POST", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": null, + "ref": null, + "type": "string" + }, + "source": { + "type": "literal", + "value": "secret_default_rule" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/default_inbox_rules/{rule_id}/disable" + }, + "scenario": "Disable a default inbox rule returns \"Successfully disabled the default inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/enable-a-default-inbox-rule-returns-successfully-enabled-the-default-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/enable-a-default-inbox-rule-returns-successfully-enabled-the-default-inbox-rule-response.json new file mode 100644 index 000000000000..5626359ceabb --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/enable-a-default-inbox-rule-returns-successfully-enabled-the-default-inbox-rule-response.json @@ -0,0 +1,35 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Enable a default inbox rule returns \"Successfully enabled the default inbox rule\" response", + "operation_id": "EnableSecurityFindingsAutomationDefaultInboxRule", + "request": { + "body": null, + "content_type": null, + "method": "POST", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": null, + "ref": null, + "type": "string" + }, + "source": { + "type": "literal", + "value": "secret_default_rule" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/default_inbox_rules/{rule_id}/enable" + }, + "scenario": "Enable a default inbox rule returns \"Successfully enabled the default inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/get-a-default-inbox-rule-returns-successfully-retrieved-the-default-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/get-a-default-inbox-rule-returns-successfully-retrieved-the-default-inbox-rule-response.json new file mode 100644 index 000000000000..c99cd903c4c0 --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/get-a-default-inbox-rule-returns-successfully-retrieved-the-default-inbox-rule-response.json @@ -0,0 +1,35 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Get a default inbox rule returns \"Successfully retrieved the default inbox rule\" response", + "operation_id": "GetSecurityFindingsAutomationDefaultInboxRule", + "request": { + "body": null, + "content_type": null, + "method": "GET", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": null, + "ref": null, + "type": "string" + }, + "source": { + "type": "literal", + "value": "secret_default_rule" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/default_inbox_rules/{rule_id}" + }, + "scenario": "Get a default inbox rule returns \"Successfully retrieved the default inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/get-all-default-inbox-rules-returns-successfully-retrieved-the-list-of-default-inbox-rules-response.json b/generated-test/test-runner-data/v2/security-monitoring/get-all-default-inbox-rules-returns-successfully-retrieved-the-list-of-default-inbox-rules-response.json new file mode 100644 index 000000000000..5f8a1d802b06 --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/get-all-default-inbox-rules-returns-successfully-retrieved-the-list-of-default-inbox-rules-response.json @@ -0,0 +1,18 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Get all default inbox rules returns \"Successfully retrieved the list of default inbox rules\" response", + "operation_id": "ListSecurityFindingsAutomationDefaultInboxRules", + "request": { + "body": null, + "content_type": null, + "method": "GET", + "pagination": false, + "parameters": [], + "path": "/api/v2/security/findings/automation/default_inbox_rules" + }, + "scenario": "Get all default inbox rules returns \"Successfully retrieved the list of default inbox rules\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/get-all-inbox-rules-returns-successfully-retrieved-the-list-of-inbox-rules-response.json b/generated-test/test-runner-data/v2/security-monitoring/get-all-inbox-rules-returns-successfully-retrieved-the-list-of-inbox-rules-response.json new file mode 100644 index 000000000000..b44008ee6efd --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/get-all-inbox-rules-returns-successfully-retrieved-the-list-of-inbox-rules-response.json @@ -0,0 +1,18 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Get all inbox rules returns \"Successfully retrieved the list of inbox rules\" response", + "operation_id": "ListSecurityFindingsAutomationInboxRules", + "request": { + "body": null, + "content_type": null, + "method": "GET", + "pagination": false, + "parameters": [], + "path": "/api/v2/security/findings/automation/inbox_rules" + }, + "scenario": "Get all inbox rules returns \"Successfully retrieved the list of inbox rules\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/get-an-inbox-rule-returns-successfully-retrieved-the-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/get-an-inbox-rule-returns-successfully-retrieved-the-inbox-rule-response.json new file mode 100644 index 000000000000..dd03b20aa865 --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/get-an-inbox-rule-returns-successfully-retrieved-the-inbox-rule-response.json @@ -0,0 +1,35 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Get an inbox rule returns \"Successfully retrieved the inbox rule\" response", + "operation_id": "GetSecurityFindingsAutomationInboxRule", + "request": { + "body": null, + "content_type": null, + "method": "GET", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": "uuid", + "ref": null, + "type": "string" + }, + "source": { + "path": "valid_inbox_rule.data.id", + "type": "fixture" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/inbox_rules/{rule_id}" + }, + "scenario": "Get an inbox rule returns \"Successfully retrieved the inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/reorder-inbox-rules-returns-successfully-reordered-the-inbox-rules-response.json b/generated-test/test-runner-data/v2/security-monitoring/reorder-inbox-rules-returns-successfully-reordered-the-inbox-rules-response.json new file mode 100644 index 000000000000..f6c22d3558f0 --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/reorder-inbox-rules-returns-successfully-reordered-the-inbox-rules-response.json @@ -0,0 +1,33 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Reorder inbox rules returns \"Successfully reordered the inbox rules\" response", + "operation_id": "ReorderSecurityFindingsAutomationInboxRules", + "request": { + "body": { + "schema": { + "format": null, + "ref": "InboxRuleReorderRequest", + "type": "object" + }, + "source": "inline", + "value": { + "data": [ + { + "id": "{{ valid_inbox_rule.data.id }}", + "type": "inbox_rules" + } + ] + } + }, + "content_type": "application/json", + "method": "POST", + "pagination": false, + "parameters": [], + "path": "/api/v2/security/findings/automation/inbox_rules/reorder" + }, + "scenario": "Reorder inbox rules returns \"Successfully reordered the inbox rules\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-runner-data/v2/security-monitoring/update-a-due-date-rule-returns-successfully-updated-the-due-date-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/update-a-due-date-rule-returns-successfully-updated-the-due-date-rule-response.json index 46ce5b101a48..cfd691fbc912 100644 --- a/generated-test/test-runner-data/v2/security-monitoring/update-a-due-date-rule-returns-successfully-updated-the-due-date-rule-response.json +++ b/generated-test/test-runner-data/v2/security-monitoring/update-a-due-date-rule-returns-successfully-updated-the-due-date-rule-response.json @@ -33,6 +33,7 @@ "query": "env:staging" } }, + "id": "{{ valid_due_date_rule.data.id }}", "type": "due_date_rules" } } diff --git a/generated-test/test-runner-data/v2/security-monitoring/update-a-mute-rule-returns-successfully-updated-the-mute-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/update-a-mute-rule-returns-successfully-updated-the-mute-rule-response.json index 3c363125e9b1..1d892dd7afe4 100644 --- a/generated-test/test-runner-data/v2/security-monitoring/update-a-mute-rule-returns-successfully-updated-the-mute-rule-response.json +++ b/generated-test/test-runner-data/v2/security-monitoring/update-a-mute-rule-returns-successfully-updated-the-mute-rule-response.json @@ -27,6 +27,7 @@ "query": "env:staging" } }, + "id": "{{ valid_mute_rule.data.id }}", "type": "mute_rules" } } diff --git a/generated-test/test-runner-data/v2/security-monitoring/update-a-severity-modifier-rule-returns-successfully-updated-the-severity-modifier-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/update-a-severity-modifier-rule-returns-successfully-updated-the-severity-modifier-rule-response.json index 755f467322fa..2ccc8d6881a5 100644 --- a/generated-test/test-runner-data/v2/security-monitoring/update-a-severity-modifier-rule-returns-successfully-updated-the-severity-modifier-rule-response.json +++ b/generated-test/test-runner-data/v2/security-monitoring/update-a-severity-modifier-rule-returns-successfully-updated-the-severity-modifier-rule-response.json @@ -29,6 +29,7 @@ "query": "env:prod team:platform" } }, + "id": "{{ valid_severity_modifier_rule.data.id }}", "type": "severity_modifier_rules" } } diff --git a/generated-test/test-runner-data/v2/security-monitoring/update-a-ticket-creation-rule-returns-successfully-updated-the-ticket-creation-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/update-a-ticket-creation-rule-returns-successfully-updated-the-ticket-creation-rule-response.json index e5ab343959c7..0cc29f75d3f5 100644 --- a/generated-test/test-runner-data/v2/security-monitoring/update-a-ticket-creation-rule-returns-successfully-updated-the-ticket-creation-rule-response.json +++ b/generated-test/test-runner-data/v2/security-monitoring/update-a-ticket-creation-rule-returns-successfully-updated-the-ticket-creation-rule-response.json @@ -29,6 +29,7 @@ "query": "env:staging" } }, + "id": "{{ valid_ticket_creation_rule.data.id }}", "type": "ticket_creation_rules" } } diff --git a/generated-test/test-runner-data/v2/security-monitoring/update-an-inbox-rule-returns-successfully-updated-the-inbox-rule-response.json b/generated-test/test-runner-data/v2/security-monitoring/update-an-inbox-rule-returns-successfully-updated-the-inbox-rule-response.json new file mode 100644 index 000000000000..9e72e2db0047 --- /dev/null +++ b/generated-test/test-runner-data/v2/security-monitoring/update-an-inbox-rule-returns-successfully-updated-the-inbox-rule-response.json @@ -0,0 +1,61 @@ +{ + "api": "SecurityMonitoring", + "expected_status": 200, + "feature": "Security Monitoring", + "id": "v2/Security Monitoring/Update an inbox rule returns \"Successfully updated the inbox rule\" response", + "operation_id": "UpdateSecurityFindingsAutomationInboxRule", + "request": { + "body": { + "schema": { + "format": null, + "ref": "InboxRuleUpdateRequest", + "type": "object" + }, + "source": "inline", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": false, + "name": "{{ unique }}", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "id": "{{ valid_inbox_rule.data.id }}", + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "PUT", + "pagination": false, + "parameters": [ + { + "explode": null, + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "format": "uuid", + "ref": null, + "type": "string" + }, + "source": { + "path": "valid_inbox_rule.data.id", + "type": "fixture" + }, + "style": null + } + ], + "path": "/api/v2/security/findings/automation/inbox_rules/{rule_id}" + }, + "scenario": "Update an inbox rule returns \"Successfully updated the inbox rule\" response", + "schema_version": 1, + "version": "v2" +} diff --git a/generated-test/test-server-data/v2/security-monitoring.json b/generated-test/test-server-data/v2/security-monitoring.json index d73c2d96ce39..4aaa1af1cf55 100644 --- a/generated-test/test-server-data/v2/security-monitoring.json +++ b/generated-test/test-server-data/v2/security-monitoring.json @@ -3572,6 +3572,75 @@ "scenario": "Create a ticket creation rule returns \"Successfully created the ticket creation rule\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:27.938Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "Test-Create_an_inbox_rule_returns_Successfully_created_the_inbox_rule_response-1790612067", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"dc57dc85-6aca-47bf-b8b3-28898cb0b855\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612069795,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612069795,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Create_an_inbox_rule_returns_Successfully_created_the_inbox_rule_response-1790612067\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Created", + "status": 201 + } + }, + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "DELETE", + "path": "/api/v2/security/findings/automation/inbox_rules/dc57dc85-6aca-47bf-b8b3-28898cb0b855", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "" + }, + "headers": {}, + "reason": "No Content", + "status": 204 + } + } + ], + "scenario": "Create an inbox rule returns \"Successfully created the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2025-12-12T14:46:23.960Z", @@ -5287,6 +5356,98 @@ "scenario": "Delete an existing rule returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:30.420Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "Test-Delete_an_inbox_rule_returns_Successfully_deleted_the_inbox_rule_response-1790612070", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"4801a0e2-68ad-4a78-a19c-1ed461044144\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612070593,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612070593,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Delete_an_inbox_rule_returns_Successfully_deleted_the_inbox_rule_response-1790612070\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Created", + "status": 201 + } + }, + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "DELETE", + "path": "/api/v2/security/findings/automation/inbox_rules/4801a0e2-68ad-4a78-a19c-1ed461044144", + "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/security/findings/automation/inbox_rules/4801a0e2-68ad-4a78-a19c-1ed461044144", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"rule does not exist\"}]}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Not Found", + "status": 404 + } + } + ], + "scenario": "Delete an inbox rule returns \"Successfully deleted the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2025-11-20T16:07:27.292Z", @@ -5415,6 +5576,68 @@ "scenario": "Detach security findings from their case returns \"Not Found\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:31.398Z", + "interactions": [ + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "POST", + "path": "/api/v2/security/findings/automation/default_inbox_rules/secret_default_rule/disable", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"secret_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":false,\"modified_at\":1790612071580,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Secrets\",\"rule\":{\"finding_types\":[\"secret\"],\"query\":\"@git.repository_visibility:public OR @secret.validation_status:valid\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "OK", + "status": 200 + } + } + ], + "scenario": "Disable a default inbox rule returns \"Successfully disabled the default inbox rule\" response", + "version": "v2" + }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:31.756Z", + "interactions": [ + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "POST", + "path": "/api/v2/security/findings/automation/default_inbox_rules/secret_default_rule/enable", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"secret_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1790612071928,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Secrets\",\"rule\":{\"finding_types\":[\"secret\"],\"query\":\"@git.repository_visibility:public OR @secret.validation_status:valid\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "OK", + "status": 200 + } + } + ], + "scenario": "Enable a default inbox rule returns \"Successfully enabled the default inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2026-04-10T08:56:17.310Z", @@ -6034,6 +6257,37 @@ "scenario": "Get a custom framework returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:32.107Z", + "interactions": [ + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "GET", + "path": "/api/v2/security/findings/automation/default_inbox_rules/secret_default_rule", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"secret_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1790612071928,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Secrets\",\"rule\":{\"finding_types\":[\"secret\"],\"query\":\"@git.repository_visibility:public OR @secret.validation_status:valid\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "OK", + "status": 200 + } + } + ], + "scenario": "Get a default inbox rule returns \"Successfully retrieved the default inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2026-06-16T15:41:07.946Z", @@ -7407,6 +7661,37 @@ "scenario": "Get all critical assets returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:32.340Z", + "interactions": [ + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "GET", + "path": "/api/v2/security/findings/automation/default_inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":[{\"id\":\"attack_path_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1788857644518,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Attack Paths\",\"rule\":{\"finding_types\":[\"attack_path\"],\"query\":\"@severity:(high OR critical)\"}}},{\"id\":\"host_and_container_vulnerability_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1787094752823,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Host \\u0026 Container Vulnerabilities\",\"rule\":{\"finding_types\":[\"host_and_container_vulnerability\"],\"query\":\"-@risk.is_image_running:false @risk.has_exploit_available:true @remediation.is_available:true @risk.has_high_exploitability_chance:true @risk_details.has_exploit_available.evidence.exploit_sources:CISA @risk.is_publicly_accessible:true @severity:(high OR critical)\"}}},{\"id\":\"iac_misconfiguration_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1787094752823,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"IaC Misconfigurations\",\"rule\":{\"finding_types\":[\"iac_misconfiguration\"],\"query\":\"@vulnerability.confidence:high @iac_resource.platform:cicd @rule.type:(insecure_configurations OR insecure_defaults) @git.repository_visibility:public @severity:(critical OR high)\"}}},{\"id\":\"identity_risk_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1788468727122,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1788468727122,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Identity Risks\",\"rule\":{\"finding_types\":[\"identity_risk\"],\"query\":\"@rule.default_rule_id:(def-000-65w OR def-000-k6r)\"}}},{\"id\":\"library_vulnerability_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1787094752823,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Library Vulnerabilities\",\"rule\":{\"finding_types\":[\"library_vulnerability\"],\"query\":\"@risk.is_emerging:true OR ((@risk.is_function_reachable:true OR (@risk.is_exposed_to_attacks:true @risk.is_production:true)) @risk.has_exploit_available:true @severity:critical)\"}}},{\"id\":\"misconfiguration_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1788468727122,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1788468727122,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Misconfigurations\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"@rule.default_rule_id:(542-ddc-8ba OR 5yq-fi1-8pn OR 7hk-tff-0fv OR 8yh-cqk-qbn OR a7e-e88-302 OR def-000-0f1 OR def-000-1u4 OR def-000-5g7 OR def-000-5zq OR def-000-6vi OR def-000-7qa OR def-000-8nn OR def-000-8zx OR def-000-936 OR def-000-9vv OR def-000-ag8 OR def-000-ag9 OR def-000-ee1 OR def-000-fdu OR def-000-glk OR def-000-hrv OR def-000-imu OR def-000-m2r OR def-000-ma8 OR def-000-mcz OR def-000-mwf OR def-000-ny3 OR def-000-ocr OR def-000-ont OR def-000-oru OR def-000-p1v OR def-000-pgo OR def-000-ph2 OR def-000-pp0 OR def-000-q4w OR def-000-qk5 OR def-000-rdc OR def-000-rtu OR def-000-u48 OR def-000-ua9 OR def-000-vcf OR def-000-xog OR def-000-y7k OR dsk-1y0-pv3 OR ee4-ngx-bwr OR exe-9ow-gwv OR fcc-nsq-vkn OR fo0-6re-l0f OR fu0-rtv-2rb OR g1t-jj4-k8k OR rl5-ki5-ja8 OR tzw-4b4-bz5 OR w95-9o2-mw0)\"}}},{\"id\":\"runtime_code_vulnerability_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1787094752823,\"modified_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"name\":\"Runtime Code Vulnerabilities\",\"rule\":{\"finding_types\":[\"runtime_code_vulnerability\"],\"query\":\"@risk.is_production:true @risk.is_exposed_to_attacks:true @severity:(critical OR high)\"}}},{\"id\":\"secret_default_rule\",\"type\":\"default_inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Maintained by Datadog Security Research. Customize your inbox by adding your own rules, cloning this rule, or disabling it.\"},\"created_at\":1787094752823,\"created_by\":{\"type\":\"system\",\"id\":\"datadog.security_research\",\"name\":\"Datadog Security Research\"},\"enabled\":true,\"modified_at\":1790612071928,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Secrets\",\"rule\":{\"finding_types\":[\"secret\"],\"query\":\"@git.repository_visibility:public OR @secret.validation_status:valid\"}}}]}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "OK", + "status": 200 + } + } + ], + "scenario": "Get all default inbox rules returns \"Successfully retrieved the list of default inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2026-06-16T15:41:11.482Z", @@ -7505,6 +7790,98 @@ "scenario": "Get all due date rules returns \"Successfully retrieved the list of due date rules\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:32.563Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "Test-Get_all_inbox_rules_returns_Successfully_retrieved_the_list_of_inbox_rules_response-1790612072", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"619001a4-e643-4b0c-a984-2f8823a408c3\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612072728,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612072728,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_inbox_rules_returns_Successfully_retrieved_the_list_of_inbox_rules_response-1790612072\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Created", + "status": 201 + } + }, + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "GET", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":[{\"id\":\"619001a4-e643-4b0c-a984-2f8823a408c3\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612072728,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612072728,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_inbox_rules_returns_Successfully_retrieved_the_list_of_inbox_rules_response-1790612072\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}],\"meta\":{\"page\":{\"total_filtered_count\":1}},\"links\":{\"first\":\"/api/v2/security/findings/automation/inbox_rules?page[size]=1000\\u0026page[number]=0\",\"last\":\"/api/v2/security/findings/automation/inbox_rules?page[size]=1000\\u0026page[number]=0\"}}" + }, + "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/findings/automation/inbox_rules/619001a4-e643-4b0c-a984-2f8823a408c3", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "" + }, + "headers": {}, + "reason": "No Content", + "status": 204 + } + } + ], + "scenario": "Get all inbox rules returns \"Successfully retrieved the list of inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2026-06-16T15:41:12.599Z", @@ -8100,25 +8477,149 @@ "source:cloudtrail" ] }, - "type": "suppressions" + "type": "suppressions" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security_monitoring/configuration/suppressions", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"qjl-xxu-vlo\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707163,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression2 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707163,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "OK", + "status": 200 + } + }, + { + "request": { + "body": { + "type": "empty", + "value": null + }, + "content_type": "", + "method": "GET", + "path": "/api/v2/security_monitoring/configuration/suppressions", + "query": [ + [ + "query", + "id:mru-avx-npf OR id:qjl-xxu-vlo" + ], + [ + "sort", + "-name" + ] + ] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":[{\"id\":\"qjl-xxu-vlo\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707163,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression2 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707163,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}},{\"id\":\"mru-avx-npf\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707069,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707069,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}}],\"meta\":{\"page\":{\"totalCount\":2,\"pageSize\":2,\"pageNumber\":0}}}" + }, + "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/configuration/suppressions/qjl-xxu-vlo", + "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/security_monitoring/configuration/suppressions/mru-avx-npf", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "" + }, + "headers": {}, + "reason": "No Content", + "status": 204 + } + } + ], + "scenario": "Get all suppression rules returns \"OK\" response with sort descending", + "version": "v2" + }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-06-16T15:41:13.714Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "max_tickets_per_day": 10, + "project_id": "11111111-1111-1111-1111-111111111111", + "target": "jira" + }, + "enabled": true, + "name": "Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "ticket_creation_rules" } } }, "content_type": "application/json", "method": "POST", - "path": "/api/v2/security_monitoring/configuration/suppressions", + "path": "/api/v2/security/findings/automation/ticket_creation_rules", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"qjl-xxu-vlo\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707163,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression2 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707163,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}}}" + "value": "{\"data\":{\"id\":\"399d69c3-6fcd-4538-b0cc-05e6db5aac38\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1781624473944,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624473944,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" }, - "reason": "OK", - "status": 200 + "reason": "Created", + "status": 201 } }, { @@ -8129,22 +8630,13 @@ }, "content_type": "", "method": "GET", - "path": "/api/v2/security_monitoring/configuration/suppressions", - "query": [ - [ - "query", - "id:mru-avx-npf OR id:qjl-xxu-vlo" - ], - [ - "sort", - "-name" - ] - ] + "path": "/api/v2/security/findings/automation/ticket_creation_rules", + "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":[{\"id\":\"qjl-xxu-vlo\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707163,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression2 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707163,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}},{\"id\":\"mru-avx-npf\",\"type\":\"suppressions\",\"attributes\":{\"creation_date\":1769009707069,\"creator\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"data_exclusion_query\":\"\",\"description\":\"Test-Get_all_suppression_rules_returns_OK_response_with_sort_descending-1769009707\",\"editable\":true,\"enabled\":true,\"name\":\"suppression 4668d111f32d9934\",\"rule_query\":\"source:cloudtrail\",\"suppression_query\":\"env:test\",\"tags\":[\"source:cloudtrail\",\"technique:T1110-brute-force\"],\"update_date\":1769009707069,\"updater\":{\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"version\":1}}],\"meta\":{\"page\":{\"totalCount\":2,\"pageSize\":2,\"pageNumber\":0}}}" + "value": "{\"data\":[{\"id\":\"399d69c3-6fcd-4538-b0cc-05e6db5aac38\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1781624473944,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624473944,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}],\"meta\":{\"page\":{\"total_filtered_count\":1}},\"links\":{\"first\":\"/api/v2/security/findings/automation/ticket_creation_rules?page[size]=1000\\u0026page[number]=0\",\"last\":\"/api/v2/security/findings/automation/ticket_creation_rules?page[size]=1000\\u0026page[number]=0\"}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -8161,28 +8653,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security_monitoring/configuration/suppressions/qjl-xxu-vlo", - "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/security_monitoring/configuration/suppressions/mru-avx-npf", + "path": "/api/v2/security/findings/automation/ticket_creation_rules/399d69c3-6fcd-4538-b0cc-05e6db5aac38", "query": [] }, "response": { @@ -8196,12 +8667,12 @@ } } ], - "scenario": "Get all suppression rules returns \"OK\" response with sort descending", + "scenario": "Get all ticket creation rules returns \"Successfully retrieved the list of ticket creation rules\" response", "version": "v2" }, { "feature": "Security Monitoring", - "frozen_at": "2026-06-16T15:41:13.714Z", + "frozen_at": "2026-09-28T16:14:33.495Z", "interactions": [ { "request": { @@ -8211,12 +8682,10 @@ "data": { "attributes": { "action": { - "max_tickets_per_day": 10, - "project_id": "11111111-1111-1111-1111-111111111111", - "target": "jira" + "description": "Needs triage" }, "enabled": true, - "name": "Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473", + "name": "Test-Get_an_inbox_rule_returns_Successfully_retrieved_the_inbox_rule_response-1790612073", "rule": { "finding_types": [ "misconfiguration" @@ -8224,19 +8693,19 @@ "query": "env:staging" } }, - "type": "ticket_creation_rules" + "type": "inbox_rules" } } }, "content_type": "application/json", "method": "POST", - "path": "/api/v2/security/findings/automation/ticket_creation_rules", + "path": "/api/v2/security/findings/automation/inbox_rules", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"399d69c3-6fcd-4538-b0cc-05e6db5aac38\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1781624473944,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624473944,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"32688e34-1328-4675-923a-e80d74041e62\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612073668,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612073668,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_an_inbox_rule_returns_Successfully_retrieved_the_inbox_rule_response-1790612073\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -8253,13 +8722,13 @@ }, "content_type": "", "method": "GET", - "path": "/api/v2/security/findings/automation/ticket_creation_rules", + "path": "/api/v2/security/findings/automation/inbox_rules/32688e34-1328-4675-923a-e80d74041e62", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":[{\"id\":\"399d69c3-6fcd-4538-b0cc-05e6db5aac38\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1781624473944,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624473944,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_all_ticket_creation_rules_returns_Successfully_retrieved_the_list_of_ticket_creation_rules_respo-1781624473\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}],\"meta\":{\"page\":{\"total_filtered_count\":1}},\"links\":{\"first\":\"/api/v2/security/findings/automation/ticket_creation_rules?page[size]=1000\\u0026page[number]=0\",\"last\":\"/api/v2/security/findings/automation/ticket_creation_rules?page[size]=1000\\u0026page[number]=0\"}}" + "value": "{\"data\":{\"id\":\"32688e34-1328-4675-923a-e80d74041e62\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612073668,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612073668,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Get_an_inbox_rule_returns_Successfully_retrieved_the_inbox_rule_response-1790612073\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -8276,7 +8745,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security/findings/automation/ticket_creation_rules/399d69c3-6fcd-4538-b0cc-05e6db5aac38", + "path": "/api/v2/security/findings/automation/inbox_rules/32688e34-1328-4675-923a-e80d74041e62", "query": [] }, "response": { @@ -8290,7 +8759,7 @@ } } ], - "scenario": "Get all ticket creation rules returns \"Successfully retrieved the list of ticket creation rules\" response", + "scenario": "Get an inbox rule returns \"Successfully retrieved the inbox rule\" response", "version": "v2" }, { @@ -10990,6 +11459,105 @@ "scenario": "Reorder due date rules returns \"Successfully reordered the due date rules\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:34.474Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "Test-Reorder_inbox_rules_returns_Successfully_reordered_the_inbox_rules_response-1790612074", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"600fac73-3dc3-4f7e-81ad-bb841ab820e6\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612074649,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612074649,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Reorder_inbox_rules_returns_Successfully_reordered_the_inbox_rules_response-1790612074\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Created", + "status": 201 + } + }, + { + "request": { + "body": { + "type": "json", + "value": { + "data": [ + { + "id": "600fac73-3dc3-4f7e-81ad-bb841ab820e6", + "type": "inbox_rules" + } + ] + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules/reorder", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":[{\"type\":\"inbox_rules\",\"id\":\"600fac73-3dc3-4f7e-81ad-bb841ab820e6\"}]}" + }, + "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/findings/automation/inbox_rules/600fac73-3dc3-4f7e-81ad-bb841ab820e6", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "" + }, + "headers": {}, + "reason": "No Content", + "status": 204 + } + } + ], + "scenario": "Reorder inbox rules returns \"Successfully reordered the inbox rules\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2026-06-16T15:41:16.028Z", @@ -12777,7 +13345,7 @@ }, { "feature": "Security Monitoring", - "frozen_at": "2026-06-16T15:41:18.417Z", + "frozen_at": "2026-09-28T16:14:35.560Z", "interactions": [ { "request": { @@ -12796,7 +13364,7 @@ "due_from": "first_seen" }, "enabled": true, - "name": "Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1781624478", + "name": "Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1790612075", "rule": { "finding_types": [ "misconfiguration" @@ -12816,7 +13384,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"22df6980-9710-496d-bf46-85e0ac181dc0\",\"type\":\"due_date_rules\",\"attributes\":{\"action\":{\"due_days_per_severity\":[{\"severity\":\"critical\",\"due_in_days\":7}],\"due_from\":\"first_seen\"},\"created_at\":1781624478629,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624478629,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1781624478\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"d1c57af8-441e-40ad-861c-8f72e0590d1e\",\"type\":\"due_date_rules\",\"attributes\":{\"action\":{\"due_days_per_severity\":[{\"severity\":\"critical\",\"due_in_days\":7}],\"due_from\":\"first_seen\"},\"created_at\":1790612075728,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612075728,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1790612075\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -12842,7 +13410,7 @@ "due_from": "first_seen" }, "enabled": false, - "name": "Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1781624478", + "name": "Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1790612075", "rule": { "finding_types": [ "misconfiguration" @@ -12850,19 +13418,20 @@ "query": "env:staging" } }, + "id": "d1c57af8-441e-40ad-861c-8f72e0590d1e", "type": "due_date_rules" } } }, "content_type": "application/json", "method": "PUT", - "path": "/api/v2/security/findings/automation/due_date_rules/22df6980-9710-496d-bf46-85e0ac181dc0", + "path": "/api/v2/security/findings/automation/due_date_rules/d1c57af8-441e-40ad-861c-8f72e0590d1e", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"22df6980-9710-496d-bf46-85e0ac181dc0\",\"type\":\"due_date_rules\",\"attributes\":{\"action\":{\"due_days_per_severity\":[{\"severity\":\"critical\",\"due_in_days\":14}],\"due_from\":\"first_seen\"},\"created_at\":1781624478629,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1781624479036,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1781624478\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"d1c57af8-441e-40ad-861c-8f72e0590d1e\",\"type\":\"due_date_rules\",\"attributes\":{\"action\":{\"due_days_per_severity\":[{\"severity\":\"critical\",\"due_in_days\":14}],\"due_from\":\"first_seen\"},\"created_at\":1790612075728,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1790612076079,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_due_date_rule_returns_Successfully_updated_the_due_date_rule_response-1790612075\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -12879,7 +13448,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security/findings/automation/due_date_rules/22df6980-9710-496d-bf46-85e0ac181dc0", + "path": "/api/v2/security/findings/automation/due_date_rules/d1c57af8-441e-40ad-861c-8f72e0590d1e", "query": [] }, "response": { @@ -12898,7 +13467,7 @@ }, { "feature": "Security Monitoring", - "frozen_at": "2026-06-16T15:41:19.612Z", + "frozen_at": "2026-09-28T16:14:36.693Z", "interactions": [ { "request": { @@ -12911,7 +13480,7 @@ "reason": "risk_accepted" }, "enabled": true, - "name": "Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1781624479", + "name": "Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1790612076", "rule": { "finding_types": [ "misconfiguration" @@ -12931,7 +13500,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"9a1d22ad-558c-4c4e-bdf5-72cd264cf7a9\",\"type\":\"mute_rules\",\"attributes\":{\"action\":{\"reason\":\"risk_accepted\"},\"created_at\":1781624479894,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624479894,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1781624479\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"47ebb4d1-b4f1-4519-b864-a977c307f7ae\",\"type\":\"mute_rules\",\"attributes\":{\"action\":{\"reason\":\"risk_accepted\"},\"created_at\":1790612076862,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612076862,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1790612076\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -12951,7 +13520,7 @@ "reason": "false_positive" }, "enabled": false, - "name": "Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1781624479", + "name": "Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1790612076", "rule": { "finding_types": [ "misconfiguration" @@ -12959,19 +13528,20 @@ "query": "env:staging" } }, + "id": "47ebb4d1-b4f1-4519-b864-a977c307f7ae", "type": "mute_rules" } } }, "content_type": "application/json", "method": "PUT", - "path": "/api/v2/security/findings/automation/mute_rules/9a1d22ad-558c-4c4e-bdf5-72cd264cf7a9", + "path": "/api/v2/security/findings/automation/mute_rules/47ebb4d1-b4f1-4519-b864-a977c307f7ae", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"9a1d22ad-558c-4c4e-bdf5-72cd264cf7a9\",\"type\":\"mute_rules\",\"attributes\":{\"action\":{\"reason\":\"false_positive\"},\"created_at\":1781624479894,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1781624480318,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1781624479\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"47ebb4d1-b4f1-4519-b864-a977c307f7ae\",\"type\":\"mute_rules\",\"attributes\":{\"action\":{\"reason\":\"false_positive\"},\"created_at\":1790612076862,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1790612077230,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_mute_rule_returns_Successfully_updated_the_mute_rule_response-1790612076\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -12988,7 +13558,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security/findings/automation/mute_rules/9a1d22ad-558c-4c4e-bdf5-72cd264cf7a9", + "path": "/api/v2/security/findings/automation/mute_rules/47ebb4d1-b4f1-4519-b864-a977c307f7ae", "query": [] }, "response": { @@ -13112,7 +13682,7 @@ }, { "feature": "Security Monitoring", - "frozen_at": "2026-08-18T07:21:01.200Z", + "frozen_at": "2026-09-28T16:14:37.824Z", "interactions": [ { "request": { @@ -13126,7 +13696,7 @@ "type": "set" }, "enabled": true, - "name": "Test-Update_a_severity_modifier_rule_returns_Successfully_updated_the_severity_modifier_rule_response-1787037661", + "name": "Test-Update_a_severity_modifier_rule_returns_Successfully_updated_the_severity_modifier_rule_response-1790612077", "rule": { "finding_types": [ "misconfiguration" @@ -13146,7 +13716,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"c58887bd-5c87-497c-adb8-db08a3593bbb\",\"type\":\"severity_modifier_rules\",\"attributes\":{\"action\":{\"type\":\"set\",\"severity\":\"low\"},\"created_at\":1787037661319,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1787037661319,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_severity_modifier_rule_returns_Successfully_updated_the_severity_modifier_rule_response-1787037661\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"ee58047b-5859-4ebc-9b21-55ff99109f13\",\"type\":\"severity_modifier_rules\",\"attributes\":{\"action\":{\"type\":\"set\",\"severity\":\"low\"},\"created_at\":1790612078013,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612078013,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_severity_modifier_rule_returns_Successfully_updated_the_severity_modifier_rule_response-1790612077\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -13176,19 +13746,20 @@ "query": "env:prod team:platform" } }, + "id": "ee58047b-5859-4ebc-9b21-55ff99109f13", "type": "severity_modifier_rules" } } }, "content_type": "application/json", "method": "PUT", - "path": "/api/v2/security/findings/automation/severity_modifier_rules/c58887bd-5c87-497c-adb8-db08a3593bbb", + "path": "/api/v2/security/findings/automation/severity_modifier_rules/ee58047b-5859-4ebc-9b21-55ff99109f13", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"c58887bd-5c87-497c-adb8-db08a3593bbb\",\"type\":\"severity_modifier_rules\",\"attributes\":{\"action\":{\"type\":\"set\",\"severity\":\"low\",\"description\":\"Lower severity for dev environment noise\"},\"created_at\":1787037661319,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1787037661614,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Downgrade misconfigurations in dev\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:prod team:platform\"}}}}" + "value": "{\"data\":{\"id\":\"ee58047b-5859-4ebc-9b21-55ff99109f13\",\"type\":\"severity_modifier_rules\",\"attributes\":{\"action\":{\"type\":\"set\",\"severity\":\"low\",\"description\":\"Lower severity for dev environment noise\"},\"created_at\":1790612078013,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612078376,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Downgrade misconfigurations in dev\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:prod team:platform\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -13205,7 +13776,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security/findings/automation/severity_modifier_rules/c58887bd-5c87-497c-adb8-db08a3593bbb", + "path": "/api/v2/security/findings/automation/severity_modifier_rules/ee58047b-5859-4ebc-9b21-55ff99109f13", "query": [] }, "response": { @@ -13321,7 +13892,7 @@ }, { "feature": "Security Monitoring", - "frozen_at": "2026-06-16T15:41:20.880Z", + "frozen_at": "2026-09-28T16:14:38.945Z", "interactions": [ { "request": { @@ -13336,7 +13907,7 @@ "target": "jira" }, "enabled": true, - "name": "Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1781624480", + "name": "Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1790612078", "rule": { "finding_types": [ "misconfiguration" @@ -13356,7 +13927,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"d3fcec39-567f-4450-967e-ca83bb29dbe4\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1781624481109,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1781624481109,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1781624480\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"ce00a58f-5bfd-4325-9cb7-0ce1fc3c632b\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":10},\"created_at\":1790612079182,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612079182,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1790612078\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -13378,7 +13949,7 @@ "target": "jira" }, "enabled": false, - "name": "Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1781624480", + "name": "Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1790612078", "rule": { "finding_types": [ "misconfiguration" @@ -13386,19 +13957,20 @@ "query": "env:staging" } }, + "id": "ce00a58f-5bfd-4325-9cb7-0ce1fc3c632b", "type": "ticket_creation_rules" } } }, "content_type": "application/json", "method": "PUT", - "path": "/api/v2/security/findings/automation/ticket_creation_rules/d3fcec39-567f-4450-967e-ca83bb29dbe4", + "path": "/api/v2/security/findings/automation/ticket_creation_rules/ce00a58f-5bfd-4325-9cb7-0ce1fc3c632b", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"d3fcec39-567f-4450-967e-ca83bb29dbe4\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":5},\"created_at\":1781624481109,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1781624481511,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1781624480\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + "value": "{\"data\":{\"id\":\"ce00a58f-5bfd-4325-9cb7-0ce1fc3c632b\",\"type\":\"ticket_creation_rules\",\"attributes\":{\"action\":{\"project_id\":\"11111111-1111-1111-1111-111111111111\",\"target\":\"jira\",\"max_tickets_per_day\":5},\"created_at\":1790612079182,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1790612079544,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_a_ticket_creation_rule_returns_Successfully_updated_the_ticket_creation_rule_response-1790612078\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -13415,7 +13987,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/security/findings/automation/ticket_creation_rules/d3fcec39-567f-4450-967e-ca83bb29dbe4", + "path": "/api/v2/security/findings/automation/ticket_creation_rules/ce00a58f-5bfd-4325-9cb7-0ce1fc3c632b", "query": [] }, "response": { @@ -13743,6 +14315,116 @@ "scenario": "Update an existing rule returns \"OK\" response", "version": "v2" }, + { + "feature": "Security Monitoring", + "frozen_at": "2026-09-28T16:14:40.089Z", + "interactions": [ + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": true, + "name": "Test-Update_an_inbox_rule_returns_Successfully_updated_the_inbox_rule_response-1790612080", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "POST", + "path": "/api/v2/security/findings/automation/inbox_rules", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"9c1e6995-7c04-403a-9cb0-62f8cc94e25a\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612080262,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":true,\"modified_at\":1790612080262,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_an_inbox_rule_returns_Successfully_updated_the_inbox_rule_response-1790612080\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "headers": { + "content-type": "application/vnd.api+json" + }, + "reason": "Created", + "status": 201 + } + }, + { + "request": { + "body": { + "type": "json", + "value": { + "data": { + "attributes": { + "action": { + "description": "Needs triage" + }, + "enabled": false, + "name": "Test-Update_an_inbox_rule_returns_Successfully_updated_the_inbox_rule_response-1790612080", + "rule": { + "finding_types": [ + "misconfiguration" + ], + "query": "env:staging" + } + }, + "id": "9c1e6995-7c04-403a-9cb0-62f8cc94e25a", + "type": "inbox_rules" + } + } + }, + "content_type": "application/json", + "method": "PUT", + "path": "/api/v2/security/findings/automation/inbox_rules/9c1e6995-7c04-403a-9cb0-62f8cc94e25a", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "{\"data\":{\"id\":\"9c1e6995-7c04-403a-9cb0-62f8cc94e25a\",\"type\":\"inbox_rules\",\"attributes\":{\"action\":{\"description\":\"Needs triage\"},\"created_at\":1790612080262,\"created_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"enabled\":false,\"modified_at\":1790612080636,\"modified_by\":{\"type\":\"user\",\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\"},\"name\":\"Test-Update_an_inbox_rule_returns_Successfully_updated_the_inbox_rule_response-1790612080\",\"rule\":{\"finding_types\":[\"misconfiguration\"],\"query\":\"env:staging\"}}}}" + }, + "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/findings/automation/inbox_rules/9c1e6995-7c04-403a-9cb0-62f8cc94e25a", + "query": [] + }, + "response": { + "body": { + "encoding": "text", + "value": "" + }, + "headers": {}, + "reason": "No Content", + "status": 204 + } + } + ], + "scenario": "Update an inbox rule returns \"Successfully updated the inbox rule\" response", + "version": "v2" + }, { "feature": "Security Monitoring", "frozen_at": "2025-05-15T09:52:48.266Z", diff --git a/lib/datadog_api_client/inflector.rb b/lib/datadog_api_client/inflector.rb index 00e349025c39..56a4fbd80943 100644 --- a/lib/datadog_api_client/inflector.rb +++ b/lib/datadog_api_client/inflector.rb @@ -3254,8 +3254,10 @@ def overrides "v2.due_date_rule_create_request" => "DueDateRuleCreateRequest", "v2.due_date_rule_data_create" => "DueDateRuleDataCreate", "v2.due_date_rule_data_response" => "DueDateRuleDataResponse", + "v2.due_date_rule_data_update" => "DueDateRuleDataUpdate", "v2.due_date_rule_reorder_item" => "DueDateRuleReorderItem", "v2.due_date_rule_reorder_request" => "DueDateRuleReorderRequest", + "v2.due_date_rule_reorder_response" => "DueDateRuleReorderResponse", "v2.due_date_rule_response" => "DueDateRuleResponse", "v2.due_date_rules_response" => "DueDateRulesResponse", "v2.due_date_rule_type" => "DueDateRuleType", @@ -5522,8 +5524,10 @@ def overrides "v2.mute_rule_create_request" => "MuteRuleCreateRequest", "v2.mute_rule_data_create" => "MuteRuleDataCreate", "v2.mute_rule_data_response" => "MuteRuleDataResponse", + "v2.mute_rule_data_update" => "MuteRuleDataUpdate", "v2.mute_rule_reorder_item" => "MuteRuleReorderItem", "v2.mute_rule_reorder_request" => "MuteRuleReorderRequest", + "v2.mute_rule_reorder_response" => "MuteRuleReorderResponse", "v2.mute_rule_response" => "MuteRuleResponse", "v2.mute_rules_response" => "MuteRulesResponse", "v2.mute_rule_type" => "MuteRuleType", @@ -7880,6 +7884,7 @@ def overrides "v2.severity_modifier_rule_create_request" => "SeverityModifierRuleCreateRequest", "v2.severity_modifier_rule_data_create" => "SeverityModifierRuleDataCreate", "v2.severity_modifier_rule_data_response" => "SeverityModifierRuleDataResponse", + "v2.severity_modifier_rule_data_update" => "SeverityModifierRuleDataUpdate", "v2.severity_modifier_rule_reorder_item" => "SeverityModifierRuleReorderItem", "v2.severity_modifier_rule_reorder_request" => "SeverityModifierRuleReorderRequest", "v2.severity_modifier_rule_reorder_response" => "SeverityModifierRuleReorderResponse", @@ -8692,8 +8697,10 @@ def overrides "v2.ticket_creation_rule_create_request" => "TicketCreationRuleCreateRequest", "v2.ticket_creation_rule_data_create" => "TicketCreationRuleDataCreate", "v2.ticket_creation_rule_data_response" => "TicketCreationRuleDataResponse", + "v2.ticket_creation_rule_data_update" => "TicketCreationRuleDataUpdate", "v2.ticket_creation_rule_reorder_item" => "TicketCreationRuleReorderItem", "v2.ticket_creation_rule_reorder_request" => "TicketCreationRuleReorderRequest", + "v2.ticket_creation_rule_reorder_response" => "TicketCreationRuleReorderResponse", "v2.ticket_creation_rule_response" => "TicketCreationRuleResponse", "v2.ticket_creation_rules_response" => "TicketCreationRulesResponse", "v2.ticket_creation_rule_type" => "TicketCreationRuleType", diff --git a/lib/datadog_api_client/v2/api/security_monitoring_api.rb b/lib/datadog_api_client/v2/api/security_monitoring_api.rb index cec21ba13ed3..21f9a95a8f4c 100644 --- a/lib/datadog_api_client/v2/api/security_monitoring_api.rb +++ b/lib/datadog_api_client/v2/api/security_monitoring_api.rb @@ -10915,7 +10915,7 @@ def reorder_security_findings_automation_due_date_rules(body, opts = {}) # # @param body [DueDateRuleReorderRequest] # @param opts [Hash] the optional parameters - # @return [Array<(DueDateRuleReorderRequest, Integer, Hash)>] DueDateRuleReorderRequest data, response status code and response headers + # @return [Array<(DueDateRuleReorderResponse, Integer, Hash)>] DueDateRuleReorderResponse data, response status code and response headers def reorder_security_findings_automation_due_date_rules_with_http_info(body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.reorder_security_findings_automation_due_date_rules".to_sym] if unstable_enabled @@ -10951,7 +10951,7 @@ def reorder_security_findings_automation_due_date_rules_with_http_info(body, opt post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type - return_type = opts[:debug_return_type] || 'DueDateRuleReorderRequest' + return_type = opts[:debug_return_type] || 'DueDateRuleReorderResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] @@ -11061,7 +11061,7 @@ def reorder_security_findings_automation_mute_rules(body, opts = {}) # # @param body [MuteRuleReorderRequest] # @param opts [Hash] the optional parameters - # @return [Array<(MuteRuleReorderRequest, Integer, Hash)>] MuteRuleReorderRequest data, response status code and response headers + # @return [Array<(MuteRuleReorderResponse, Integer, Hash)>] MuteRuleReorderResponse data, response status code and response headers def reorder_security_findings_automation_mute_rules_with_http_info(body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.reorder_security_findings_automation_mute_rules".to_sym] if unstable_enabled @@ -11097,7 +11097,7 @@ def reorder_security_findings_automation_mute_rules_with_http_info(body, opts = post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type - return_type = opts[:debug_return_type] || 'MuteRuleReorderRequest' + return_type = opts[:debug_return_type] || 'MuteRuleReorderResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] @@ -11207,7 +11207,7 @@ def reorder_security_findings_automation_ticket_creation_rules(body, opts = {}) # # @param body [TicketCreationRuleReorderRequest] # @param opts [Hash] the optional parameters - # @return [Array<(TicketCreationRuleReorderRequest, Integer, Hash)>] TicketCreationRuleReorderRequest data, response status code and response headers + # @return [Array<(TicketCreationRuleReorderResponse, Integer, Hash)>] TicketCreationRuleReorderResponse data, response status code and response headers def reorder_security_findings_automation_ticket_creation_rules_with_http_info(body, opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.reorder_security_findings_automation_ticket_creation_rules".to_sym] if unstable_enabled @@ -11243,7 +11243,7 @@ def reorder_security_findings_automation_ticket_creation_rules_with_http_info(bo post_body = opts[:debug_body] || @api_client.object_to_http_body(body) # return_type - return_type = opts[:debug_return_type] || 'TicketCreationRuleReorderRequest' + return_type = opts[:debug_return_type] || 'TicketCreationRuleReorderResponse' # auth_names auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] diff --git a/lib/datadog_api_client/v2/models/due_date_rule_create_request.rb b/lib/datadog_api_client/v2/models/due_date_rule_create_request.rb index cec96f54cdf7..08cf316bc421 100644 --- a/lib/datadog_api_client/v2/models/due_date_rule_create_request.rb +++ b/lib/datadog_api_client/v2/models/due_date_rule_create_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class DueDateRuleCreateRequest include BaseGenericModel - # The data object for a due date rule create or update request. + # The data object for a due date rule create request. attr_reader :data attr_accessor :additional_properties diff --git a/lib/datadog_api_client/v2/models/due_date_rule_data_create.rb b/lib/datadog_api_client/v2/models/due_date_rule_data_create.rb index 70c55691906a..3b8fdc6b4259 100644 --- a/lib/datadog_api_client/v2/models/due_date_rule_data_create.rb +++ b/lib/datadog_api_client/v2/models/due_date_rule_data_create.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The data object for a due date rule create or update request. + # The data object for a due date rule create request. class DueDateRuleDataCreate include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/due_date_rule_data_update.rb b/lib/datadog_api_client/v2/models/due_date_rule_data_update.rb new file mode 100644 index 000000000000..bbdfeeb0c14e --- /dev/null +++ b/lib/datadog_api_client/v2/models/due_date_rule_data_update.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The data object for a due date rule update request. The `id` must match the `rule_id` path parameter. + class DueDateRuleDataUpdate + include BaseGenericModel + + # Attributes for creating or updating a due date rule. + attr_reader :attributes + + # The ID of the due date rule to update. + attr_reader :id + + # The JSON:API type for due date rules. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'DueDateRuleAttributesCreate', + :'id' => :'UUID', + :'type' => :'DueDateRuleType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DueDateRuleDataUpdate` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/due_date_rule_reorder_request.rb b/lib/datadog_api_client/v2/models/due_date_rule_reorder_request.rb index 1bca560fc103..f155d262e9a0 100644 --- a/lib/datadog_api_client/v2/models/due_date_rule_reorder_request.rb +++ b/lib/datadog_api_client/v2/models/due_date_rule_reorder_request.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The body of the due date rule reorder request. + # The body of a due date rule reorder request. class DueDateRuleReorderRequest include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/due_date_rule_reorder_response.rb b/lib/datadog_api_client/v2/models/due_date_rule_reorder_response.rb new file mode 100644 index 000000000000..7c69900039fb --- /dev/null +++ b/lib/datadog_api_client/v2/models/due_date_rule_reorder_response.rb @@ -0,0 +1,125 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The response of a due date rule reorder request. + class DueDateRuleReorderResponse + include BaseGenericModel + + # The ordered list of all due date rules. Every rule must be included. + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'Array' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DueDateRuleReorderResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + if (value = attributes[:'data']).is_a?(Array) + self.data = value + end + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/due_date_rule_update_request.rb b/lib/datadog_api_client/v2/models/due_date_rule_update_request.rb index 4a2c6dccde06..12ca9f74bd35 100644 --- a/lib/datadog_api_client/v2/models/due_date_rule_update_request.rb +++ b/lib/datadog_api_client/v2/models/due_date_rule_update_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class DueDateRuleUpdateRequest include BaseGenericModel - # The data object for a due date rule create or update request. + # The data object for a due date rule update request. The `id` must match the `rule_id` path parameter. attr_reader :data attr_accessor :additional_properties @@ -38,7 +38,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { - :'data' => :'DueDateRuleDataCreate' + :'data' => :'DueDateRuleDataUpdate' } end diff --git a/lib/datadog_api_client/v2/models/mute_rule_create_request.rb b/lib/datadog_api_client/v2/models/mute_rule_create_request.rb index 6e564df42c8b..85d1de5f7da0 100644 --- a/lib/datadog_api_client/v2/models/mute_rule_create_request.rb +++ b/lib/datadog_api_client/v2/models/mute_rule_create_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class MuteRuleCreateRequest include BaseGenericModel - # The data object for a mute rule create or update request. + # The data object for a mute rule create request. attr_reader :data attr_accessor :additional_properties diff --git a/lib/datadog_api_client/v2/models/mute_rule_data_create.rb b/lib/datadog_api_client/v2/models/mute_rule_data_create.rb index e2155d86ca11..189b473522e7 100644 --- a/lib/datadog_api_client/v2/models/mute_rule_data_create.rb +++ b/lib/datadog_api_client/v2/models/mute_rule_data_create.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The data object for a mute rule create or update request. + # The data object for a mute rule create request. class MuteRuleDataCreate include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/mute_rule_data_update.rb b/lib/datadog_api_client/v2/models/mute_rule_data_update.rb new file mode 100644 index 000000000000..42e027ed19b3 --- /dev/null +++ b/lib/datadog_api_client/v2/models/mute_rule_data_update.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The data object for a mute rule update request. The `id` must match the `rule_id` path parameter. + class MuteRuleDataUpdate + include BaseGenericModel + + # Attributes for creating or updating a mute rule. + attr_reader :attributes + + # The ID of the mute rule to update. + attr_reader :id + + # The JSON:API type for mute rules. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'MuteRuleAttributesCreate', + :'id' => :'UUID', + :'type' => :'MuteRuleType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::MuteRuleDataUpdate` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/mute_rule_reorder_request.rb b/lib/datadog_api_client/v2/models/mute_rule_reorder_request.rb index de680a6847de..0caa3a82c57c 100644 --- a/lib/datadog_api_client/v2/models/mute_rule_reorder_request.rb +++ b/lib/datadog_api_client/v2/models/mute_rule_reorder_request.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The body of the mute rule reorder request. + # The body of a mute rule reorder request. class MuteRuleReorderRequest include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/mute_rule_reorder_response.rb b/lib/datadog_api_client/v2/models/mute_rule_reorder_response.rb new file mode 100644 index 000000000000..c1ecc15d04e5 --- /dev/null +++ b/lib/datadog_api_client/v2/models/mute_rule_reorder_response.rb @@ -0,0 +1,125 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The response of a mute rule reorder request. + class MuteRuleReorderResponse + include BaseGenericModel + + # The ordered list of all mute rules. Every rule must be included. + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'Array' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::MuteRuleReorderResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + if (value = attributes[:'data']).is_a?(Array) + self.data = value + end + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/mute_rule_update_request.rb b/lib/datadog_api_client/v2/models/mute_rule_update_request.rb index 1e01fe66a125..7058b0db0050 100644 --- a/lib/datadog_api_client/v2/models/mute_rule_update_request.rb +++ b/lib/datadog_api_client/v2/models/mute_rule_update_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class MuteRuleUpdateRequest include BaseGenericModel - # The data object for a mute rule create or update request. + # The data object for a mute rule update request. The `id` must match the `rule_id` path parameter. attr_reader :data attr_accessor :additional_properties @@ -38,7 +38,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { - :'data' => :'MuteRuleDataCreate' + :'data' => :'MuteRuleDataUpdate' } end diff --git a/lib/datadog_api_client/v2/models/severity_modifier_rule_create_request.rb b/lib/datadog_api_client/v2/models/severity_modifier_rule_create_request.rb index ece7e4de8f19..943e0824c694 100644 --- a/lib/datadog_api_client/v2/models/severity_modifier_rule_create_request.rb +++ b/lib/datadog_api_client/v2/models/severity_modifier_rule_create_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class SeverityModifierRuleCreateRequest include BaseGenericModel - # The data object for a severity modifier rule create or update request. + # The data object for a severity modifier rule create request. attr_reader :data attr_accessor :additional_properties diff --git a/lib/datadog_api_client/v2/models/severity_modifier_rule_data_create.rb b/lib/datadog_api_client/v2/models/severity_modifier_rule_data_create.rb index 492fda51c48c..93427925fcd5 100644 --- a/lib/datadog_api_client/v2/models/severity_modifier_rule_data_create.rb +++ b/lib/datadog_api_client/v2/models/severity_modifier_rule_data_create.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The data object for a severity modifier rule create or update request. + # The data object for a severity modifier rule create request. class SeverityModifierRuleDataCreate include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/severity_modifier_rule_data_update.rb b/lib/datadog_api_client/v2/models/severity_modifier_rule_data_update.rb new file mode 100644 index 000000000000..ce0b5803ffe4 --- /dev/null +++ b/lib/datadog_api_client/v2/models/severity_modifier_rule_data_update.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The data object for a severity modifier rule update request. The `id` must match the `rule_id` path parameter. + class SeverityModifierRuleDataUpdate + include BaseGenericModel + + # Attributes for creating or updating a severity modifier rule. + attr_reader :attributes + + # The ID of the severity modifier rule to update. + attr_reader :id + + # The JSON:API type for severity modifier rules. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'SeverityModifierRuleAttributesCreate', + :'id' => :'UUID', + :'type' => :'SeverityModifierRuleType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::SeverityModifierRuleDataUpdate` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/severity_modifier_rule_update_request.rb b/lib/datadog_api_client/v2/models/severity_modifier_rule_update_request.rb index a8e095c17fd5..526a00655999 100644 --- a/lib/datadog_api_client/v2/models/severity_modifier_rule_update_request.rb +++ b/lib/datadog_api_client/v2/models/severity_modifier_rule_update_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class SeverityModifierRuleUpdateRequest include BaseGenericModel - # The data object for a severity modifier rule create or update request. + # The data object for a severity modifier rule update request. The `id` must match the `rule_id` path parameter. attr_reader :data attr_accessor :additional_properties @@ -38,7 +38,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { - :'data' => :'SeverityModifierRuleDataCreate' + :'data' => :'SeverityModifierRuleDataUpdate' } end diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_create_request.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_create_request.rb index bfb5dc6ce760..92bce6f487df 100644 --- a/lib/datadog_api_client/v2/models/ticket_creation_rule_create_request.rb +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_create_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class TicketCreationRuleCreateRequest include BaseGenericModel - # The data object for a ticket creation rule create or update request. + # The data object for a ticket creation rule create request. attr_reader :data attr_accessor :additional_properties diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_data_create.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_data_create.rb index 2a70b4941416..8bcdfd4f3d39 100644 --- a/lib/datadog_api_client/v2/models/ticket_creation_rule_data_create.rb +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_data_create.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The data object for a ticket creation rule create or update request. + # The data object for a ticket creation rule create request. class TicketCreationRuleDataCreate include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_data_update.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_data_update.rb new file mode 100644 index 000000000000..a95d74121ad7 --- /dev/null +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_data_update.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The data object for a ticket creation rule update request. The `id` must match the `rule_id` path parameter. + class TicketCreationRuleDataUpdate + include BaseGenericModel + + # Attributes for creating or updating a ticket creation rule. + attr_reader :attributes + + # The ID of the ticket creation rule to update. + attr_reader :id + + # The JSON:API type for ticket creation rules. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'TicketCreationRuleAttributesCreate', + :'id' => :'UUID', + :'type' => :'TicketCreationRuleType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::TicketCreationRuleDataUpdate` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_request.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_request.rb index 190e819e317b..fd18f981c192 100644 --- a/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_request.rb +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_request.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V2 - # The body of the ticket creation rule reorder request. + # The body of a ticket creation rule reorder request. class TicketCreationRuleReorderRequest include BaseGenericModel diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_response.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_response.rb new file mode 100644 index 000000000000..179ae741bc44 --- /dev/null +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_reorder_response.rb @@ -0,0 +1,125 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The response of a ticket creation rule reorder request. + class TicketCreationRuleReorderResponse + include BaseGenericModel + + # The ordered list of all ticket creation rules. Every rule must be included. + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'Array' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::TicketCreationRuleReorderResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + if (value = attributes[:'data']).is_a?(Array) + self.data = value + end + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/ticket_creation_rule_update_request.rb b/lib/datadog_api_client/v2/models/ticket_creation_rule_update_request.rb index 64e10f1a0bd7..7abf3356cef9 100644 --- a/lib/datadog_api_client/v2/models/ticket_creation_rule_update_request.rb +++ b/lib/datadog_api_client/v2/models/ticket_creation_rule_update_request.rb @@ -21,7 +21,7 @@ module DatadogAPIClient::V2 class TicketCreationRuleUpdateRequest include BaseGenericModel - # The data object for a ticket creation rule create or update request. + # The data object for a ticket creation rule update request. The `id` must match the `rule_id` path parameter. attr_reader :data attr_accessor :additional_properties @@ -38,7 +38,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { - :'data' => :'TicketCreationRuleDataCreate' + :'data' => :'TicketCreationRuleDataUpdate' } end