diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 6bc8997cfde4..05ce562f5e20 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -5270,6 +5270,79 @@ components: example: _latest type: string type: object + AttachCaseRequest: + description: Request for attaching security findings to a case. + properties: + data: + $ref: '#/components/schemas/AttachCaseRequestData' + type: object + AttachCaseRequestData: + description: Data of the case to attach security findings to. + properties: + id: + description: The unique identifier of the case. + example: c1234567-89ab-cdef-0123-456789abcdef + type: string + relationships: + $ref: '#/components/schemas/AttachCaseRequestDataRelationships' + type: + $ref: '#/components/schemas/CaseDataType' + required: + - type + - id + type: object + AttachCaseRequestDataRelationships: + description: Relationships of the case to attach security findings to. + properties: + findings: + $ref: '#/components/schemas/Findings' + description: Security findings to attach to the case. + required: + - findings + type: object + AttachJiraIssueRequest: + description: Request for attaching security findings to a Jira issue. + properties: + data: + $ref: '#/components/schemas/AttachJiraIssueRequestData' + type: object + AttachJiraIssueRequestData: + description: Data of the Jira issue to attach security findings to. + properties: + attributes: + $ref: '#/components/schemas/AttachJiraIssueRequestDataAttributes' + id: + description: The unique identifier of the Jira issue attachment request. + example: j1234567-89ab-cdef-0123-456789abcdef + type: string + relationships: + $ref: '#/components/schemas/AttachJiraIssueRequestDataRelationships' + type: + $ref: '#/components/schemas/JiraIssuesDataType' + required: + - type + type: object + AttachJiraIssueRequestDataAttributes: + description: Attributes of the Jira issue to attach security findings to. + properties: + jira_issue_url: + description: The URL of the Jira issue to attach security findings to. + example: https://domain.atlassian.net/browse/PROJ-123 + type: string + required: + - jira_issue_url + type: object + AttachJiraIssueRequestDataRelationships: + description: Relationships of the Jira issue to attach security findings to. + properties: + findings: + $ref: '#/components/schemas/Findings' + project: + $ref: '#/components/schemas/CaseManagementProject' + required: + - findings + - project + type: object AuditLogsEvent: description: Object description of an Audit Logs event after it is processed and stored by Datadog. @@ -8942,6 +9015,15 @@ components: required: - data type: object + CaseDataType: + default: cases + description: Cases resource type. + enum: + - cases + example: cases + type: string + x-enum-varnames: + - CASES CaseEmpty: description: Case empty request data properties: @@ -8958,6 +9040,53 @@ components: required: - data type: object + CaseInsightsItems: + description: An insight of the case. + properties: + ref: + description: The reference of the insight. + example: /security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static + type: string + resource_id: + description: The unique identifier of the resource. For example, the unique + identifier of a security finding. + example: ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw== + type: string + type: + description: The type of the resource. For example, the type of a security + finding is "SECURITY_FINDING". + example: SECURITY_FINDING + type: string + type: object + CaseManagementProject: + description: Case management project. + properties: + data: + $ref: '#/components/schemas/CaseManagementProjectData' + required: + - data + type: object + CaseManagementProjectData: + properties: + id: + description: The unique identifier of the case management project. + example: aeadc05e-98a8-11ec-ac2c-da7ad0900001 + type: string + type: + $ref: '#/components/schemas/CaseManagementProjectDataType' + required: + - type + - id + type: object + CaseManagementProjectDataType: + default: projects + description: Projects resource type. + enum: + - projects + example: projects + type: string + x-enum-varnames: + - PROJECTS CaseObjectAttributes: additionalProperties: items: @@ -12602,6 +12731,68 @@ components: required: - type type: object + CreateCaseRequestArray: + description: List of requests to create cases for security findings. + properties: + data: + items: + $ref: '#/components/schemas/CreateCaseRequestData' + type: array + required: + - data + type: object + CreateCaseRequestData: + description: Data of the case to create. + properties: + attributes: + $ref: '#/components/schemas/CreateCaseRequestDataAttributes' + id: + description: The unique identifier of the case. + example: c1234567-89ab-cdef-0123-456789abcdef + type: string + relationships: + $ref: '#/components/schemas/CreateCaseRequestDataRelationships' + type: + $ref: '#/components/schemas/CaseDataType' + required: + - type + type: object + CreateCaseRequestDataAttributes: + description: Attributes of the case to create. + properties: + assignee_id: + description: The unique identifier of the user assigned to the case. + example: f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0 + type: string + description: + description: The description of the case. If not provided, the description + will be automatically generated. + example: A description of the case. + type: string + priority: + $ref: '#/components/schemas/CasePriority' + description: The priority of the case. If not provided, the priority will + be automatically set to "NOT_DEFINED". + example: P4 + title: + description: The title of the case. If not provided, the title will be automatically + generated. + example: A title for the case. + type: string + type: object + CreateCaseRequestDataRelationships: + description: Relationships of the case to create. + properties: + findings: + $ref: '#/components/schemas/Findings' + description: Security findings of the case to create. + project: + $ref: '#/components/schemas/CaseManagementProject' + description: Project of the case to create. + required: + - findings + - project + type: object CreateConnectionRequest: example: data: @@ -12873,6 +13064,89 @@ components: required: - data type: object + CreateJiraIssueRequestArray: + description: List of requests to create Jira issues for security findings. + properties: + data: + items: + $ref: '#/components/schemas/CreateJiraIssueRequestData' + type: array + included: + items: + $ref: '#/components/schemas/CreateJiraIssueRequestArrayIncluded' + type: array + required: + - data + type: object + CreateJiraIssueRequestArrayIncluded: + description: 'Attributes and relationships of the case linked to the Jira issue. + Should contain all of the following: case, project, and security findings.' + oneOf: + - $ref: '#/components/schemas/CreateCaseRequestData' + - $ref: '#/components/schemas/CaseManagementProjectData' + - $ref: '#/components/schemas/FindingData' + CreateJiraIssueRequestData: + description: Data of the Jira issue to create. + properties: + attributes: + $ref: '#/components/schemas/CreateJiraIssueRequestDataAttributes' + id: + description: The unique identifier of the Jira issue creation request. + example: j1234567-89ab-cdef-0123-456789abcdef + type: string + relationships: + $ref: '#/components/schemas/CreateJiraIssueRequestDataRelationships' + type: + $ref: '#/components/schemas/JiraIssuesDataType' + required: + - type + type: object + CreateJiraIssueRequestDataAttributes: + description: Attributes of the Jira issue to create. + properties: + fields: + $ref: '#/components/schemas/CreateJiraIssueRequestDataAttributesFields' + type: object + CreateJiraIssueRequestDataAttributesFields: + description: Custom fields of the Jira issue to create. For the list of available + fields, see [Jira documentation](https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-createmeta-projectidorkey-issuetypes-issuetypeid-get). + properties: + fields: + example: + customfield_10001: Value 1 + customfield_10002: + - Value 2 + - Value 3 + type: object + type: object + CreateJiraIssueRequestDataRelationships: + description: Relationships of the Jira issue to create. + properties: + case: + $ref: '#/components/schemas/CreateJiraIssueRequestDataRelationshipsCase' + required: + - case + type: object + CreateJiraIssueRequestDataRelationshipsCase: + description: Case linked to the Jira issue. + properties: + data: + $ref: '#/components/schemas/CreateJiraIssueRequestDataRelationshipsCaseData' + required: + - data + type: object + CreateJiraIssueRequestDataRelationshipsCaseData: + description: Case linked to the Jira issue. + properties: + id: + example: c1234567-89ab-cdef-0123-456789abcdef + type: string + type: + $ref: '#/components/schemas/CaseDataType' + required: + - type + - id + type: object CreateNotificationRuleParameters: description: Body of the notification rule create request. properties: @@ -16862,6 +17136,35 @@ components: oneOf: - $ref: '#/components/schemas/DeploymentRuleOptionsFaultyDeploymentDetection' - $ref: '#/components/schemas/DeploymentRuleOptionsMonitor' + DetachCaseRequest: + description: Request for detaching security findings from their case. + properties: + data: + $ref: '#/components/schemas/DetachCaseRequestData' + type: object + DetachCaseRequestData: + description: Data for detaching security findings from their case. + properties: + id: + description: The unique identifier of the detachment request. + example: f8b9e3b1-24ec-4413-8be5-1b12b98533c6 + type: string + relationships: + $ref: '#/components/schemas/DetachCaseRequestDataRelationships' + type: + $ref: '#/components/schemas/CaseDataType' + required: + - type + type: object + DetachCaseRequestDataRelationships: + description: Relationships detaching security findings from their case. + properties: + findings: + $ref: '#/components/schemas/Findings' + description: Security findings to detach from their case. + required: + - findings + type: object DetailedFinding: description: A single finding with with message and resource configuration. properties: @@ -20712,6 +21015,153 @@ components: vulnerability_type: $ref: '#/components/schemas/FindingVulnerabilityType' type: object + FindingCaseResponse: + description: Case response. + properties: + data: + $ref: '#/components/schemas/FindingCaseResponseData' + type: object + FindingCaseResponseArray: + description: List of case responses. + properties: + data: + items: + $ref: '#/components/schemas/FindingCaseResponseData' + type: array + required: + - data + type: object + FindingCaseResponseData: + description: Data of the case. + properties: + attributes: + $ref: '#/components/schemas/FindingCaseResponseDataAttributes' + id: + description: The unique identifier of the case. + example: c1234567-89ab-cdef-0123-456789abcdef + type: string + relationships: + $ref: '#/components/schemas/FindingCaseResponseDataRelationships' + type: + $ref: '#/components/schemas/CaseDataType' + required: + - type + type: object + FindingCaseResponseDataAttributes: + description: Attributes of the case. + properties: + archived_at: + description: Timestamp of when the case was archived. + example: '2025-01-01T00:00:00.000Z' + format: date-time + type: string + assigned_to: + $ref: '#/components/schemas/RelationshipToUser' + description: User assigned to the case. + attributes: + additionalProperties: + items: + type: string + type: array + type: object + closed_at: + description: Timestamp of when the case was closed. + example: '2025-01-01T00:00:00.000Z' + format: date-time + type: string + created_at: + description: Timestamp of when the case was created. + example: '2025-01-01T00:00:00.000Z' + format: date-time + type: string + creation_source: + description: Source of the case creation. + example: CS_SECURITY_FINDING + type: string + description: + description: Description of the case. + example: A description of the case. + type: string + due_date: + description: Due date of the case. + example: '2025-01-01' + type: string + insights: + description: Insights of the case. + items: + $ref: '#/components/schemas/CaseInsightsItems' + type: array + jira_issue: + $ref: '#/components/schemas/FindingJiraIssue' + description: Jira issue associated with the case. + key: + description: Key of the case. + example: PROJ-123 + type: string + modified_at: + description: Timestamp of when the case was last modified. + example: '2025-01-01T00:00:00.000Z' + format: date-time + type: string + priority: + description: Priority of the case. + example: P4 + type: string + status: + description: Status of the case. + example: OPEN + type: string + status_group: + description: Status group of the case. + example: SG_OPEN + type: string + status_name: + description: Status name of the case. + example: Open + type: string + title: + description: Title of the case. + example: A title for the case. + type: string + type: + description: Type of the case. For security cases, this is always "SECURITY". + example: SECURITY + type: string + type: object + FindingCaseResponseDataRelationships: + description: Relationships of the case. + properties: + created_by: + $ref: '#/components/schemas/RelationshipToUser' + description: User who created the case. + modified_by: + $ref: '#/components/schemas/RelationshipToUser' + description: User who last modified the case. + project: + $ref: '#/components/schemas/CaseManagementProject' + description: Project in which the case was created. + type: object + FindingData: + properties: + id: + description: The unique identifier of the security finding. + example: ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw== + type: string + type: + $ref: '#/components/schemas/FindingDataType' + required: + - type + - id + type: object + FindingDataType: + default: findings + description: Security findings resource type. + enum: + - findings + example: findings + type: string + x-enum-varnames: + - FINDINGS FindingDatadogLink: description: The Datadog relative link for this finding. example: /security/compliance?panels=cpfinding%7Cevent%7CruleId%3Adef-000-u5t%7CresourceId%3Ae8c9ab7c52ebd7bf2fdb4db641082d7d%7CtabId%3Aoverview @@ -20753,6 +21203,42 @@ components: description: The unique ID for this finding. example: ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw== type: string + FindingJiraIssue: + description: Jira issue associated with the case. + properties: + error_message: + description: The error message if the Jira issue creation failed. + example: '{"errorMessages":["An error occured."],"errors":{}}' + type: string + result: + $ref: '#/components/schemas/FindingJiraIssueResult' + status: + description: The status of the Jira issue creation. Can be "COMPLETED" if + the Jira issue was created successfully, or "FAILED" if the Jira issue + creation failed. + example: COMPLETED + type: string + type: object + FindingJiraIssueResult: + description: Result of the Jira issue creation. + properties: + account_id: + description: The account ID of the Jira issue. + example: 463a8631-680e-455c-bfd3-3ed04d326eb7 + type: string + issue_id: + description: The unique identifier of the Jira issue. + example: '2871276' + type: string + issue_key: + description: The key of the Jira issue. + example: PROJ-123 + type: string + issue_url: + description: The URL of the Jira issue. + example: https://domain.atlassian.net/browse/PROJ-123 + type: string + type: object FindingMute: additionalProperties: false description: Information about the mute status of this finding. @@ -20878,6 +21364,14 @@ components: - ATTACK_PATH - IDENTITY_RISK - API_SECURITY + Findings: + description: A list of security findings. + properties: + data: + items: + $ref: '#/components/schemas/FindingData' + type: array + type: object FlakyTest: description: A flaky test object. properties: @@ -28295,6 +28789,15 @@ components: description: Jira project key type: string type: object + JiraIssuesDataType: + default: jira_issues + description: Jira issues resource type. + enum: + - jira_issues + example: jira_issues + type: string + x-enum-varnames: + - JIRA_ISSUES JobCreateResponse: description: Run a threat hunting job response. properties: @@ -74543,10 +75046,16 @@ paths: security: - apiKeyAuth: [] appKeyAuth: [] + - AuthZ: [] summary: Mute or unmute a batch of findings tags: - Security Monitoring x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write x-unstable: '**Note**: This endpoint is in public beta. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).' @@ -78230,6 +78739,208 @@ paths: operator: OR permissions: - security_monitoring_cws_agent_rules_read + /api/v2/security/findings/cases: + delete: + description: Detach security findings from their case. This operation dissociates + security findings from their associated cases without deleting the cases themselves. + You can detach security findings from multiple different cases in a single + request, with a limit of 50 security findings per request. Security findings + that are not currently attached to any case will be ignored. + operationId: DetachCase + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DetachCaseRequest' + required: true + responses: + '204': + description: No Content + '400': + $ref: '#/components/responses/BadRequestResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Detach security findings from their case + tags: + - Security Monitoring + x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write + post: + description: Create cases for security findings. You can create up to 50 cases + per request and associate up to 50 security findings per case. Security findings + that are already attached to another case will be detached from their previous + case and attached to the newly created case. + operationId: CreateCases + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CreateCaseRequestArray' + required: true + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/FindingCaseResponseArray' + description: Created + '400': + $ref: '#/components/responses/BadRequestResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Create cases for security findings + tags: + - Security Monitoring + x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write + /api/v2/security/findings/cases/{case_id}: + patch: + description: Attach security findings to a case. You can attach up to 50 security + findings per case. Security findings that are already attached to another + case will be detached from their previous case and attached to the specified + case. + operationId: AttachCase + parameters: + - description: The unique identifier of the case to attach security findings + to + in: path + name: case_id + required: true + schema: + type: string + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AttachCaseRequest' + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FindingCaseResponse' + description: OK + '400': + $ref: '#/components/responses/BadRequestResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Attach security findings to a case + tags: + - Security Monitoring + x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write + /api/v2/security/findings/jira_issues: + patch: + description: Attach security findings to a Jira issue by providing the Jira + issue URL. You can attach up to 50 security findings per Jira issue. If the + Jira issue is not linked to any case, this operation will create a case for + the security findings and link the Jira issue to the newly created case. Security + findings that are already attached to another Jira issue will be detached + from their previous Jira issue and attached to the specified Jira issue. + operationId: AttachJiraIssue + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AttachJiraIssueRequest' + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FindingCaseResponse' + description: OK + '400': + $ref: '#/components/responses/BadRequestResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Attach security findings to a Jira issue + tags: + - Security Monitoring + x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write + post: + description: Create Jira issues for security findings. This operation creates + a case in Datadog and a Jira issue linked to that case for bidirectional sync + between Datadog and Jira. You can create up to 50 Jira issues per request + and associate up to 50 security findings per Jira issue. Security findings + that are already attached to another Jira issue will be detached from their + previous Jira issue and attached to the newly created Jira issue. + operationId: CreateJiraIssues + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CreateJiraIssueRequestArray' + required: true + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/FindingCaseResponseArray' + description: Created + '400': + $ref: '#/components/responses/BadRequestResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Create Jira issues for security findings + tags: + - Security Monitoring + x-codegen-request-body-name: body + x-permission: + operator: OR + permissions: + - security_monitoring_findings_write + - appsec_vm_write /api/v2/security/sboms: get: description: 'Get a list of assets SBOMs for an organization. diff --git a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/frozen.json index b26b17aa48aa..4c9b6ca09520 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:39.297Z" +"2025-12-02T17:11:57.622Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/recording.har index 21d53e6ea974..d61dead3467b 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-Bad-Request-response_2824092514/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "805bca15e7f08cce6b78232a51416eb0", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 191, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testcreatedeploymentrulereturnsbadrequestresponse1764326919\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 575, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 575, - "text": "{\"data\":{\"id\":\"64de7180-ffd3-417b-beb6-c6ea469b5b5f\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:39.863066Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testcreatedeploymentrulereturnsbadrequestresponse1764326919\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:39.863066Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"daadd697-95f4-4608-b6cc-8e6337d692ab\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:58.225449Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:11:58.225449Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -51,17 +51,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 683, + "headersSize": 682, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:39.749Z", - "time": 167 + "startedDateTime": "2025-12-02T17:11:58.069Z", + "time": 195 }, { - "_id": "bc3a9ac91b3741fdcfbdcbf054301e0a", + "_id": "a16b8105dc198442190c72d42b8c7473", "_order": 0, "cache": {}, "request": { @@ -88,7 +88,7 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"test\",\"options\":{\"excluded_resources\":[]},\"type\":\"fdd\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/64de7180-ffd3-417b-beb6-c6ea469b5b5f/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/daadd697-95f4-4608-b6cc-8e6337d692ab/rules" }, "response": { "bodySize": 136, @@ -104,17 +104,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 682, + "headersSize": 681, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 400, "statusText": "Bad Request" }, - "startedDateTime": "2025-11-28T10:48:39.926Z", - "time": 120 + "startedDateTime": "2025-12-02T17:11:58.275Z", + "time": 144 }, { - "_id": "8ed8a1333531e991076ed010c62eb341", + "_id": "227b4564ccc3b0f72d53fe1e4001c5be", "_order": 0, "cache": {}, "request": { @@ -131,7 +131,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/64de7180-ffd3-417b-beb6-c6ea469b5b5f" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/daadd697-95f4-4608-b6cc-8e6337d692ab" }, "response": { "bodySize": 0, @@ -141,14 +141,14 @@ }, "cookies": [], "headers": [], - "headersSize": 623, + "headersSize": 622, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:40.053Z", - "time": 136 + "startedDateTime": "2025-12-02T17:11:58.425Z", + "time": 128 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/frozen.json index 75b31f365af5..5cf132b31e7d 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:40.199Z" +"2025-12-02T17:11:58.561Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/recording.har index 198359f063db..6a424e43cb45 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Create-deployment-rule-returns-OK-response_36464608/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "70d8a20edaaf6ee64c3055d976ec6c9b", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 183, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testcreatedeploymentrulereturnsokresponse1764326920\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 567, + "bodySize": 513, "content": { "mimeType": "application/vnd.api+json", - "size": 567, - "text": "{\"data\":{\"id\":\"2abe97e8-438e-410e-9630-185bd3634d4d\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:40.314903Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testcreatedeploymentrulereturnsokresponse1764326920\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:40.314903Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 513, + "text": "{\"data\":{\"id\":\"b998ebca-01ad-4db8-96e6-a2beb54f497a\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:58.67035Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:11:58.67035Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -51,17 +51,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 683, + "headersSize": 682, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:40.202Z", - "time": 144 + "startedDateTime": "2025-12-02T17:11:58.564Z", + "time": 179 }, { - "_id": "a2fa7824d779a0d9f15a96378291fb9d", + "_id": "858b10329845140040777a2b2098be81", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/2abe97e8-438e-410e-9630-185bd3634d4d/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/b998ebca-01ad-4db8-96e6-a2beb54f497a/rules" }, "response": { "bodySize": 577, "content": { "mimeType": "application/vnd.api+json", "size": 577, - "text": "{\"data\":{\"id\":\"3370e167-8ad1-4cce-8efe-4688ff6d862e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:40.464432Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"2abe97e8-438e-410e-9630-185bd3634d4d\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:40.464432Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "text": "{\"data\":{\"id\":\"3feb569f-bb55-47cb-990f-7bc0c4c076f4\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:58.877828Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"b998ebca-01ad-4db8-96e6-a2beb54f497a\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:11:58.877828Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -104,17 +104,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 682, + "headersSize": 681, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:40.351Z", - "time": 135 + "startedDateTime": "2025-12-02T17:11:58.750Z", + "time": 193 }, { - "_id": "a4030f938a6e559967172e6d42bad0f3", + "_id": "e7215262d4435d95845dca7938047f4a", "_order": 0, "cache": {}, "request": { @@ -127,11 +127,11 @@ "value": "*/*" } ], - "headersSize": 587, + "headersSize": 586, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/2abe97e8-438e-410e-9630-185bd3634d4d/rules/3370e167-8ad1-4cce-8efe-4688ff6d862e" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/b998ebca-01ad-4db8-96e6-a2beb54f497a/rules/3feb569f-bb55-47cb-990f-7bc0c4c076f4" }, "response": { "bodySize": 0, @@ -141,17 +141,17 @@ }, "cookies": [], "headers": [], - "headersSize": 623, + "headersSize": 622, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:40.490Z", - "time": 139 + "startedDateTime": "2025-12-02T17:11:58.948Z", + "time": 133 }, { - "_id": "26b8761c30659a6c3f9b9e3caf6a8ae1", + "_id": "1840bf916f8ad711045474872823635f", "_order": 0, "cache": {}, "request": { @@ -168,7 +168,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/2abe97e8-438e-410e-9630-185bd3634d4d" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/b998ebca-01ad-4db8-96e6-a2beb54f497a" }, "response": { "bodySize": 0, @@ -178,14 +178,14 @@ }, "cookies": [], "headers": [], - "headersSize": 623, + "headersSize": 622, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:40.632Z", - "time": 139 + "startedDateTime": "2025-12-02T17:11:59.085Z", + "time": 135 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/frozen.json index 9a6c5b859e90..4f3090a0e8d5 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:40.779Z" +"2025-12-02T17:11:59.228Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/recording.har index c1b2e5c99390..f113e05114d9 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-gate-returns-No-Content-response_2018192270/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "67a945a070d1baa8c7e5b4f428bf52e0", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 190, + "bodySize": 131, "cookies": [], "headers": [ { @@ -26,23 +26,23 @@ "value": "application/json" } ], - "headersSize": 571, + "headersSize": 570, "httpVersion": "HTTP/1.1", "method": "POST", "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testdeletedeploymentgatereturnsnocontentresponse1764326920\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 574, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 574, - "text": "{\"data\":{\"id\":\"86e38caf-0d2a-4e72-93ac-9850957d2c6b\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:40.909837Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testdeletedeploymentgatereturnsnocontentresponse1764326920\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:40.909837Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"0d6b54a5-70ad-4e9a-9ee4-f7d99f25a3d5\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:59.349857Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:11:59.349857Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -51,17 +51,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 683, + "headersSize": 682, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:40.781Z", - "time": 158 + "startedDateTime": "2025-12-02T17:11:59.231Z", + "time": 179 }, { - "_id": "3e123064488b434dcd2de8d0c7cb4f34", + "_id": "f64556f17830ddbb9db59662399ee781", "_order": 0, "cache": {}, "request": { @@ -74,11 +74,11 @@ "value": "*/*" } ], - "headersSize": 544, + "headersSize": 543, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/86e38caf-0d2a-4e72-93ac-9850957d2c6b" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/0d6b54a5-70ad-4e9a-9ee4-f7d99f25a3d5" }, "response": { "bodySize": 0, @@ -88,17 +88,17 @@ }, "cookies": [], "headers": [], - "headersSize": 623, + "headersSize": 622, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:40.944Z", - "time": 136 + "startedDateTime": "2025-12-02T17:11:59.414Z", + "time": 133 }, { - "_id": "3e123064488b434dcd2de8d0c7cb4f34", + "_id": "f64556f17830ddbb9db59662399ee781", "_order": 1, "cache": {}, "request": { @@ -111,11 +111,11 @@ "value": "*/*" } ], - "headersSize": 544, + "headersSize": 543, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/86e38caf-0d2a-4e72-93ac-9850957d2c6b" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/0d6b54a5-70ad-4e9a-9ee4-f7d99f25a3d5" }, "response": { "bodySize": 80, @@ -131,14 +131,14 @@ "value": "application/vnd.api+json" } ], - "headersSize": 683, + "headersSize": 682, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 404, "statusText": "Not Found" }, - "startedDateTime": "2025-11-28T10:48:41.085Z", - "time": 125 + "startedDateTime": "2025-12-02T17:11:59.552Z", + "time": 128 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/frozen.json index 681e9e3fc7b6..43d553813bf4 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:41.219Z" +"2025-12-02T17:11:59.690Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/recording.har index b4adae6956b3..3d13a2e3fb25 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Delete-deployment-rule-returns-No-Content-response_3926285415/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "64f2a0d46a85693f0327545fe7a0534b", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 190, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testdeletedeploymentrulereturnsnocontentresponse1764326921\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 574, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 574, - "text": "{\"data\":{\"id\":\"32ff7c01-1f90-4ae4-bef0-b759f1ad280f\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:41.325741Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testdeletedeploymentrulereturnsnocontentresponse1764326921\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:41.325741Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"051490b0-1383-4dd4-b719-fb17ab089898\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:59.799293Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:11:59.799293Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -51,17 +51,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 683, + "headersSize": 682, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:41.222Z", - "time": 132 + "startedDateTime": "2025-12-02T17:11:59.694Z", + "time": 147 }, { - "_id": "459cdaaa82d95680601b1a23b6a2c352", + "_id": "6bd5203e04e0c90f6f84b04b848997cf", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/32ff7c01-1f90-4ae4-bef0-b759f1ad280f/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/051490b0-1383-4dd4-b719-fb17ab089898/rules" }, "response": { - "bodySize": 577, + "bodySize": 575, "content": { "mimeType": "application/vnd.api+json", - "size": 577, - "text": "{\"data\":{\"id\":\"8229075f-8014-432c-9597-ba549ae5cd83\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:41.470358Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"32ff7c01-1f90-4ae4-bef0-b759f1ad280f\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:41.470358Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 575, + "text": "{\"data\":{\"id\":\"29fb1e0d-d3f4-4f3a-a4de-1bd65cf57c16\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:11:59.98839Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"051490b0-1383-4dd4-b719-fb17ab089898\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:11:59.98839Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -104,17 +104,17 @@ "value": "application/vnd.api+json" } ], - "headersSize": 682, + "headersSize": 681, "httpVersion": "HTTP/1.1", "redirectURL": "", "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:41.361Z", - "time": 126 + "startedDateTime": "2025-12-02T17:11:59.847Z", + "time": 157 }, { - "_id": "03877ee6c8bc166d4865705e41312634", + "_id": "c9a60e1fd8e8687e20b665f7b1d70e11", "_order": 0, "cache": {}, "request": { @@ -127,11 +127,11 @@ "value": "*/*" } ], - "headersSize": 587, + "headersSize": 586, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/32ff7c01-1f90-4ae4-bef0-b759f1ad280f/rules/8229075f-8014-432c-9597-ba549ae5cd83" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/051490b0-1383-4dd4-b719-fb17ab089898/rules/29fb1e0d-d3f4-4f3a-a4de-1bd65cf57c16" }, "response": { "bodySize": 0, @@ -147,11 +147,11 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:41.492Z", + "startedDateTime": "2025-12-02T17:12:00.010Z", "time": 157 }, { - "_id": "03877ee6c8bc166d4865705e41312634", + "_id": "c9a60e1fd8e8687e20b665f7b1d70e11", "_order": 1, "cache": {}, "request": { @@ -168,7 +168,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/32ff7c01-1f90-4ae4-bef0-b759f1ad280f/rules/8229075f-8014-432c-9597-ba549ae5cd83" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/051490b0-1383-4dd4-b719-fb17ab089898/rules/29fb1e0d-d3f4-4f3a-a4de-1bd65cf57c16" }, "response": { "bodySize": 80, @@ -190,11 +190,11 @@ "status": 404, "statusText": "Not Found" }, - "startedDateTime": "2025-11-28T10:48:41.654Z", - "time": 119 + "startedDateTime": "2025-12-02T17:12:00.172Z", + "time": 123 }, { - "_id": "2a6238b842949c964507a7aa98426abc", + "_id": "cfe2dedc795691a60c99f4ee245c8f38", "_order": 0, "cache": {}, "request": { @@ -211,7 +211,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/32ff7c01-1f90-4ae4-bef0-b759f1ad280f" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/051490b0-1383-4dd4-b719-fb17ab089898" }, "response": { "bodySize": 0, @@ -227,8 +227,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:41.777Z", - "time": 116 + "startedDateTime": "2025-12-02T17:12:00.300Z", + "time": 114 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/frozen.json index f381f0042d6d..5bcbe140c3fb 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:41.902Z" +"2025-12-02T17:12:00.422Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/recording.har index bd6daffecd36..d6baa74b588a 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-gate-returns-OK-response_1812155259/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "2ee257aa1daf56f98edd6761ae9bdd50", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 180, + "bodySize": 131, "cookies": [], "headers": [ { @@ -26,23 +26,23 @@ "value": "application/json" } ], - "headersSize": 571, + "headersSize": 570, "httpVersion": "HTTP/1.1", "method": "POST", "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentgatereturnsokresponse1764326921\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 564, + "bodySize": 513, "content": { "mimeType": "application/vnd.api+json", - "size": 564, - "text": "{\"data\":{\"id\":\"6fc0d64b-aa76-49f9-804b-5ba224951b53\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:42.011911Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentgatereturnsokresponse1764326921\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:42.011911Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 513, + "text": "{\"data\":{\"id\":\"a71a41f7-e7b9-4c51-8af0-397c8e99aaf9\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:00.52354Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:00.52354Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:41.908Z", - "time": 120 + "startedDateTime": "2025-12-02T17:12:00.428Z", + "time": 112 }, { - "_id": "74d7566cab6a8e98c8b675d6475e1010", + "_id": "7a1714b6c4d989fa0a6f7c0023d67164", "_order": 0, "cache": {}, "request": { @@ -74,18 +74,18 @@ "value": "application/json" } ], - "headersSize": 551, + "headersSize": 550, "httpVersion": "HTTP/1.1", "method": "GET", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/6fc0d64b-aa76-49f9-804b-5ba224951b53" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/a71a41f7-e7b9-4c51-8af0-397c8e99aaf9" }, "response": { - "bodySize": 564, + "bodySize": 513, "content": { "mimeType": "application/vnd.api+json", - "size": 564, - "text": "{\"data\":{\"id\":\"6fc0d64b-aa76-49f9-804b-5ba224951b53\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:42.011911Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentgatereturnsokresponse1764326921\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:42.011911Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 513, + "text": "{\"data\":{\"id\":\"a71a41f7-e7b9-4c51-8af0-397c8e99aaf9\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:00.52354Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:00.52354Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -100,11 +100,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:42.033Z", - "time": 170 + "startedDateTime": "2025-12-02T17:12:00.545Z", + "time": 175 }, { - "_id": "a388cf9dc776cfee96c48e7bb5d6ae5b", + "_id": "b2ac5be2bfad4104b2122c28f0abe7ae", "_order": 0, "cache": {}, "request": { @@ -117,11 +117,11 @@ "value": "*/*" } ], - "headersSize": 544, + "headersSize": 543, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/6fc0d64b-aa76-49f9-804b-5ba224951b53" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/a71a41f7-e7b9-4c51-8af0-397c8e99aaf9" }, "response": { "bodySize": 0, @@ -137,8 +137,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:42.208Z", - "time": 122 + "startedDateTime": "2025-12-02T17:12:00.724Z", + "time": 135 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/frozen.json index 8f5886533d56..3425883d0c17 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:42.334Z" +"2025-12-02T17:12:00.864Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/recording.har index 1e5add20c51e..6db6ed815fab 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-Bad-Request-response_2127960932/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "8b77471841083f1ab4d0bc37683f09ed", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 188, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentrulereturnsbadrequestresponse1764326922\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 572, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 572, - "text": "{\"data\":{\"id\":\"10bfb87d-3e15-4889-895c-28fd41d71837\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:42.440107Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentrulereturnsbadrequestresponse1764326922\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:42.440107Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"241e9292-911a-4eea-90e0-83b5f27a468c\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:00.969748Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:00.969748Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:42.336Z", - "time": 132 + "startedDateTime": "2025-12-02T17:12:00.866Z", + "time": 153 }, { - "_id": "3faa6627bba0f7aacc404ba107a049a2", + "_id": "46c6cd47c13b157d94b822aee9e7ae3c", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/10bfb87d-3e15-4889-895c-28fd41d71837/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/241e9292-911a-4eea-90e0-83b5f27a468c/rules" }, "response": { "bodySize": 577, "content": { "mimeType": "application/vnd.api+json", "size": 577, - "text": "{\"data\":{\"id\":\"e8c6d6c6-c529-4c30-92f9-8d965a68b120\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:42.588675Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"10bfb87d-3e15-4889-895c-28fd41d71837\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:42.588675Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "text": "{\"data\":{\"id\":\"48d335e3-7744-4aef-af75-7c6d0bb9e24e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:01.161979Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"241e9292-911a-4eea-90e0-83b5f27a468c\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:01.161979Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -110,8 +110,8 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:42.473Z", - "time": 131 + "startedDateTime": "2025-12-02T17:12:01.023Z", + "time": 202 }, { "_id": "fb33a6dc801c60adbeedde2e3d4a63f4", @@ -153,11 +153,11 @@ "status": 400, "statusText": "Bad Request" }, - "startedDateTime": "2025-11-28T10:48:42.609Z", - "time": 123 + "startedDateTime": "2025-12-02T17:12:01.230Z", + "time": 117 }, { - "_id": "fb4f86025f38691c7ffb6117e71f7219", + "_id": "9384928f864c0dbe39135428e689b7d6", "_order": 0, "cache": {}, "request": { @@ -174,7 +174,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/10bfb87d-3e15-4889-895c-28fd41d71837/rules/e8c6d6c6-c529-4c30-92f9-8d965a68b120" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/241e9292-911a-4eea-90e0-83b5f27a468c/rules/48d335e3-7744-4aef-af75-7c6d0bb9e24e" }, "response": { "bodySize": 0, @@ -190,11 +190,11 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:42.736Z", - "time": 119 + "startedDateTime": "2025-12-02T17:12:01.352Z", + "time": 125 }, { - "_id": "15673f07ede625f9982a8d77f5604805", + "_id": "6cc88ec81e873471c71c8dcc05d08e18", "_order": 0, "cache": {}, "request": { @@ -211,7 +211,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/10bfb87d-3e15-4889-895c-28fd41d71837" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/241e9292-911a-4eea-90e0-83b5f27a468c" }, "response": { "bodySize": 0, @@ -227,8 +227,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:42.857Z", - "time": 126 + "startedDateTime": "2025-12-02T17:12:01.479Z", + "time": 138 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/frozen.json index 2cf900b215f3..cccee43a1451 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:42.991Z" +"2025-12-02T17:12:01.624Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/recording.har index 0f7a46f987ee..dc151c7136a4 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Get-deployment-rule-returns-OK-response_3558316506/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "242a5e37735faf9061ace37f51523ec4", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 180, + "bodySize": 131, "cookies": [], "headers": [ { @@ -26,23 +26,23 @@ "value": "application/json" } ], - "headersSize": 571, + "headersSize": 569, "httpVersion": "HTTP/1.1", "method": "POST", "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentrulereturnsokresponse1764326922\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 564, + "bodySize": 513, "content": { "mimeType": "application/vnd.api+json", - "size": 564, - "text": "{\"data\":{\"id\":\"701d9655-8d81-43d0-9954-cf24b4959b60\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:43.092215Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testgetdeploymentrulereturnsokresponse1764326922\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:43.092215Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 513, + "text": "{\"data\":{\"id\":\"defa04e5-9bb2-4a40-b854-1c2378ffcc58\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:01.70723Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:01.70723Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:42.993Z", - "time": 115 + "startedDateTime": "2025-12-02T17:12:01.626Z", + "time": 102 }, { - "_id": "29f4be06bbc555c9b9705dd8735f48f9", + "_id": "56de325ff9cd0433e688e48e07c5750b", "_order": 0, "cache": {}, "request": { @@ -79,7 +79,7 @@ "value": "application/json" } ], - "headersSize": 614, + "headersSize": 613, "httpVersion": "HTTP/1.1", "method": "POST", "postData": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/701d9655-8d81-43d0-9954-cf24b4959b60/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/defa04e5-9bb2-4a40-b854-1c2378ffcc58/rules" }, "response": { "bodySize": 577, "content": { "mimeType": "application/vnd.api+json", "size": 577, - "text": "{\"data\":{\"id\":\"c96cd32f-5c92-4bc7-9483-85a824b394a7\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:43.237862Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"701d9655-8d81-43d0-9954-cf24b4959b60\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:43.237862Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "text": "{\"data\":{\"id\":\"c1009845-b7a4-4701-846b-df160891ab3d\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:01.871247Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"defa04e5-9bb2-4a40-b854-1c2378ffcc58\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:01.871247Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -110,11 +110,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:43.113Z", - "time": 174 + "startedDateTime": "2025-12-02T17:12:01.733Z", + "time": 155 }, { - "_id": "2221d4d11fbcffd5fd60ac9c4d1b23dd", + "_id": "ac25de481d87191f47754920915c1ae3", "_order": 0, "cache": {}, "request": { @@ -127,18 +127,18 @@ "value": "application/json" } ], - "headersSize": 594, + "headersSize": 592, "httpVersion": "HTTP/1.1", "method": "GET", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/701d9655-8d81-43d0-9954-cf24b4959b60/rules/c96cd32f-5c92-4bc7-9483-85a824b394a7" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/defa04e5-9bb2-4a40-b854-1c2378ffcc58/rules/c1009845-b7a4-4701-846b-df160891ab3d" }, "response": { "bodySize": 577, "content": { "mimeType": "application/vnd.api+json", "size": 577, - "text": "{\"data\":{\"id\":\"c96cd32f-5c92-4bc7-9483-85a824b394a7\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:43.237862Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"701d9655-8d81-43d0-9954-cf24b4959b60\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:43.237862Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "text": "{\"data\":{\"id\":\"c1009845-b7a4-4701-846b-df160891ab3d\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:01.871247Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"defa04e5-9bb2-4a40-b854-1c2378ffcc58\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:01.871247Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -153,11 +153,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:43.292Z", - "time": 159 + "startedDateTime": "2025-12-02T17:12:01.894Z", + "time": 128 }, { - "_id": "4a3781c22e9fafb1fd05a6da79f32abd", + "_id": "d76616cf2a9752635b9d5a90b190f24d", "_order": 0, "cache": {}, "request": { @@ -170,11 +170,11 @@ "value": "*/*" } ], - "headersSize": 587, + "headersSize": 586, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/701d9655-8d81-43d0-9954-cf24b4959b60/rules/c96cd32f-5c92-4bc7-9483-85a824b394a7" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/defa04e5-9bb2-4a40-b854-1c2378ffcc58/rules/c1009845-b7a4-4701-846b-df160891ab3d" }, "response": { "bodySize": 0, @@ -190,11 +190,11 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:43.456Z", + "startedDateTime": "2025-12-02T17:12:02.025Z", "time": 119 }, { - "_id": "a681b94303e56689c27e5468daf6b0f3", + "_id": "9b65b4bd320fa9f0d8f296113a4ccca3", "_order": 0, "cache": {}, "request": { @@ -207,11 +207,11 @@ "value": "*/*" } ], - "headersSize": 544, + "headersSize": 543, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/701d9655-8d81-43d0-9954-cf24b4959b60" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/defa04e5-9bb2-4a40-b854-1c2378ffcc58" }, "response": { "bodySize": 0, @@ -227,8 +227,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:43.578Z", - "time": 151 + "startedDateTime": "2025-12-02T17:12:02.146Z", + "time": 125 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/frozen.json index c54651799998..93b7ad21c6b2 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:43.738Z" +"2025-12-02T17:12:02.280Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/recording.har index 69814a786661..0263d7f5c3fb 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-gate-returns-OK-response_3515146080/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "0548f1b3e5e161fc86caaf51fa14e18e", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 183, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentgatereturnsokresponse1764326923\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 567, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 567, - "text": "{\"data\":{\"id\":\"6080b4ee-0fa6-4370-aafa-adb5b71c2fab\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:43.844073Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentgatereturnsokresponse1764326923\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:43.844073Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"010e234b-b358-463e-a44d-6fbe29ec3f6b\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:02.374479Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:02.374479Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:43.741Z", - "time": 168 + "startedDateTime": "2025-12-02T17:12:02.283Z", + "time": 133 }, { - "_id": "0f8e6b3d0b71b80dc2eff6209ecc98b2", + "_id": "78f3ddddbd3fcafdd7f0459709403df3", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false},\"id\":\"12345678-1234-1234-1234-123456789012\",\"type\":\"deployment_gate\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/6080b4ee-0fa6-4370-aafa-adb5b71c2fab" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/010e234b-b358-463e-a44d-6fbe29ec3f6b" }, "response": { - "bodySize": 567, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 567, - "text": "{\"data\":{\"id\":\"6080b4ee-0fa6-4370-aafa-adb5b71c2fab\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:43.844073Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentgatereturnsokresponse1764326923\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:44.028502Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"010e234b-b358-463e-a44d-6fbe29ec3f6b\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:02.374479Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:02.534024Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -110,11 +110,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:43.916Z", - "time": 140 + "startedDateTime": "2025-12-02T17:12:02.421Z", + "time": 129 }, { - "_id": "c62b2d4512872929a532a1944e2e9f30", + "_id": "0c4a62650194294d13cc02cd7a727d3a", "_order": 0, "cache": {}, "request": { @@ -131,7 +131,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/6080b4ee-0fa6-4370-aafa-adb5b71c2fab" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/010e234b-b358-463e-a44d-6fbe29ec3f6b" }, "response": { "bodySize": 0, @@ -147,8 +147,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:44.060Z", - "time": 162 + "startedDateTime": "2025-12-02T17:12:02.557Z", + "time": 157 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/frozen.json index 476183f01eca..83243ee8dc76 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:44.227Z" +"2025-12-02T17:12:02.719Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/recording.har index a53aa0931857..917f8bcd91a3 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-Bad-Request-response_1486779637/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "6673fcb47218e29c910d37b1db2b0e05", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 191, + "bodySize": 131, "cookies": [], "headers": [ { @@ -26,23 +26,23 @@ "value": "application/json" } ], - "headersSize": 571, + "headersSize": 570, "httpVersion": "HTTP/1.1", "method": "POST", "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentrulereturnsbadrequestresponse1764326924\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 575, + "bodySize": 513, "content": { "mimeType": "application/vnd.api+json", - "size": 575, - "text": "{\"data\":{\"id\":\"f7fc03e3-86d9-4731-9baf-9b3a2f9239c3\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:44.325367Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentrulereturnsbadrequestresponse1764326924\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:44.325367Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 513, + "text": "{\"data\":{\"id\":\"ef2fa0b3-0f6a-49a4-9043-1d8130cb7361\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:02.81563Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:02.81563Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:44.229Z", - "time": 116 + "startedDateTime": "2025-12-02T17:12:02.721Z", + "time": 160 }, { - "_id": "c3b1ad5ac08391959ae18c88d1a2402e", + "_id": "f83da15c7a67dfdd8dd0752cd21dc851", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/f7fc03e3-86d9-4731-9baf-9b3a2f9239c3/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/ef2fa0b3-0f6a-49a4-9043-1d8130cb7361/rules" }, "response": { - "bodySize": 577, + "bodySize": 575, "content": { "mimeType": "application/vnd.api+json", - "size": 577, - "text": "{\"data\":{\"id\":\"63e71fe3-f002-4e46-bc24-772c7a743e95\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:44.453112Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"f7fc03e3-86d9-4731-9baf-9b3a2f9239c3\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:44.453112Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 575, + "text": "{\"data\":{\"id\":\"c89bf1d3-5e6a-43b1-9009-cfaaaddf8518\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:02.99992Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"ef2fa0b3-0f6a-49a4-9043-1d8130cb7361\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:02.99992Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -110,8 +110,8 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:44.349Z", - "time": 119 + "startedDateTime": "2025-12-02T17:12:02.885Z", + "time": 148 }, { "_id": "7d25d788cd9d6480d8210f5a5ca31a95", @@ -163,11 +163,11 @@ "status": 400, "statusText": "Bad Request" }, - "startedDateTime": "2025-11-28T10:48:44.473Z", + "startedDateTime": "2025-12-02T17:12:03.038Z", "time": 119 }, { - "_id": "4a0d7b505521f81ef78f09278a52a46d", + "_id": "e19d5544ecf761581bfd8cbb60d0e164", "_order": 0, "cache": {}, "request": { @@ -184,7 +184,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/f7fc03e3-86d9-4731-9baf-9b3a2f9239c3/rules/63e71fe3-f002-4e46-bc24-772c7a743e95" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/ef2fa0b3-0f6a-49a4-9043-1d8130cb7361/rules/c89bf1d3-5e6a-43b1-9009-cfaaaddf8518" }, "response": { "bodySize": 0, @@ -200,11 +200,11 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:44.596Z", - "time": 118 + "startedDateTime": "2025-12-02T17:12:03.162Z", + "time": 129 }, { - "_id": "6cf68f1321057d46c5077feedda73fac", + "_id": "118fea1ff2068f733707ca2bf9229e27", "_order": 0, "cache": {}, "request": { @@ -221,7 +221,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/f7fc03e3-86d9-4731-9baf-9b3a2f9239c3" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/ef2fa0b3-0f6a-49a4-9043-1d8130cb7361" }, "response": { "bodySize": 0, @@ -237,8 +237,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:44.717Z", - "time": 131 + "startedDateTime": "2025-12-02T17:12:03.294Z", + "time": 135 } ], "pages": [], diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/frozen.json b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/frozen.json index e7461795985f..78a161da4f93 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/frozen.json +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/frozen.json @@ -1 +1 @@ -"2025-11-28T10:48:44.855Z" +"2025-12-02T17:12:03.436Z" diff --git a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/recording.har b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/recording.har index 862958200ac3..6d7d730ad659 100644 --- a/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/recording.har +++ b/cassettes/v2/Deployment-Gates_4242274226/Update-deployment-rule-returns-OK-response_2914944649/recording.har @@ -8,11 +8,11 @@ }, "entries": [ { - "_id": "1e7e74d6e487cecb0dd1aeccab1b7111", + "_id": "70acb264a190c9504530585b68c408be", "_order": 0, "cache": {}, "request": { - "bodySize": 183, + "bodySize": 131, "cookies": [], "headers": [ { @@ -32,17 +32,17 @@ "postData": { "mimeType": "application/json", "params": [], - "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentrulereturnsokresponse1764326924\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" + "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\"},\"type\":\"deployment_gate\"}}" }, "queryString": [], "url": "https://api.datadoghq.com/api/v2/deployment_gates" }, "response": { - "bodySize": 567, + "bodySize": 515, "content": { "mimeType": "application/vnd.api+json", - "size": 567, - "text": "{\"data\":{\"id\":\"b9fe1de0-ba29-4f86-abbb-09ec15047772\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:44.953026Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate-testupdatedeploymentrulereturnsokresponse1764326924\",\"service\":\"my-service\",\"updated_at\":\"2025-11-28T10:48:44.953026Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 515, + "text": "{\"data\":{\"id\":\"bfdae182-ee23-493c-a90b-05441a76ad73\",\"type\":\"deployment_gate\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:03.529101Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"env\":\"production\",\"identifier\":\"my-gate\",\"service\":\"my-service\",\"updated_at\":\"2025-12-02T17:12:03.529101Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -57,11 +57,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:44.857Z", - "time": 112 + "startedDateTime": "2025-12-02T17:12:03.438Z", + "time": 106 }, { - "_id": "b0126137927e4629cf38d776aee57722", + "_id": "a39e041f34ceb6f9492a015e652dafb3", "_order": 0, "cache": {}, "request": { @@ -88,14 +88,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"My deployment rule\",\"options\":{\"excluded_resources\":[]},\"type\":\"faulty_deployment_detection\"},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/b9fe1de0-ba29-4f86-abbb-09ec15047772/rules" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/bfdae182-ee23-493c-a90b-05441a76ad73/rules" }, "response": { - "bodySize": 577, + "bodySize": 575, "content": { "mimeType": "application/vnd.api+json", - "size": 577, - "text": "{\"data\":{\"id\":\"04207b55-28e1-46e6-9aa1-ed45dd022e3e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:45.086885Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"b9fe1de0-ba29-4f86-abbb-09ec15047772\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:45.086885Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 575, + "text": "{\"data\":{\"id\":\"93ed5e98-aeb8-4096-a035-0907f327019e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:03.68857Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"bfdae182-ee23-493c-a90b-05441a76ad73\",\"name\":\"My deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:03.68857Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -110,11 +110,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:44.974Z", - "time": 128 + "startedDateTime": "2025-12-02T17:12:03.548Z", + "time": 190 }, { - "_id": "4c42138e93258e81ecd36bc8be306431", + "_id": "73db724b34b923fb9147af57af849393", "_order": 0, "cache": {}, "request": { @@ -141,14 +141,14 @@ "text": "{\"data\":{\"attributes\":{\"dry_run\":false,\"name\":\"Updated deployment rule\",\"options\":{\"excluded_resources\":[]}},\"type\":\"deployment_rule\"}}" }, "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/b9fe1de0-ba29-4f86-abbb-09ec15047772/rules/04207b55-28e1-46e6-9aa1-ed45dd022e3e" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/bfdae182-ee23-493c-a90b-05441a76ad73/rules/93ed5e98-aeb8-4096-a035-0907f327019e" }, "response": { - "bodySize": 582, + "bodySize": 581, "content": { "mimeType": "application/vnd.api+json", - "size": 582, - "text": "{\"data\":{\"id\":\"04207b55-28e1-46e6-9aa1-ed45dd022e3e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-11-28T10:48:45.086885Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"b9fe1de0-ba29-4f86-abbb-09ec15047772\",\"name\":\"Updated deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-11-28T10:48:45.232653Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" + "size": 581, + "text": "{\"data\":{\"id\":\"93ed5e98-aeb8-4096-a035-0907f327019e\",\"type\":\"deployment_rule\",\"attributes\":{\"created_at\":\"2025-12-02T17:12:03.68857Z\",\"created_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"dry_run\":false,\"gate_id\":\"bfdae182-ee23-493c-a90b-05441a76ad73\",\"name\":\"Updated deployment rule\",\"options\":{},\"type\":\"faulty_deployment_detection\",\"updated_at\":\"2025-12-02T17:12:03.882016Z\",\"updated_by\":{\"id\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\",\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"}}}}" }, "cookies": [], "headers": [ @@ -163,11 +163,11 @@ "status": 200, "statusText": "OK" }, - "startedDateTime": "2025-11-28T10:48:45.108Z", - "time": 140 + "startedDateTime": "2025-12-02T17:12:03.754Z", + "time": 204 }, { - "_id": "5458cdb3ae6f24976faf223be805b5b5", + "_id": "bf7e48fc9eed3ef6ca339f9dd223876f", "_order": 0, "cache": {}, "request": { @@ -184,7 +184,7 @@ "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/b9fe1de0-ba29-4f86-abbb-09ec15047772/rules/04207b55-28e1-46e6-9aa1-ed45dd022e3e" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/bfdae182-ee23-493c-a90b-05441a76ad73/rules/93ed5e98-aeb8-4096-a035-0907f327019e" }, "response": { "bodySize": 0, @@ -200,11 +200,11 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:45.262Z", - "time": 124 + "startedDateTime": "2025-12-02T17:12:03.962Z", + "time": 118 }, { - "_id": "12c82fb6c02df84fcb70002de7cba1cc", + "_id": "cbada0b028a36291c1717d710fde6323", "_order": 0, "cache": {}, "request": { @@ -217,11 +217,11 @@ "value": "*/*" } ], - "headersSize": 544, + "headersSize": 543, "httpVersion": "HTTP/1.1", "method": "DELETE", "queryString": [], - "url": "https://api.datadoghq.com/api/v2/deployment_gates/b9fe1de0-ba29-4f86-abbb-09ec15047772" + "url": "https://api.datadoghq.com/api/v2/deployment_gates/bfdae182-ee23-493c-a90b-05441a76ad73" }, "response": { "bodySize": 0, @@ -237,8 +237,8 @@ "status": 204, "statusText": "No Content" }, - "startedDateTime": "2025-11-28T10:48:45.389Z", - "time": 125 + "startedDateTime": "2025-12-02T17:12:04.084Z", + "time": 135 } ], "pages": [], diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/frozen.json new file mode 100644 index 000000000000..b177921c4326 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:49:48.969Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/recording.har new file mode 100644 index 000000000000..7eb208eedbd7 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-Jira-issue-returns-OK-response_3128543316/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security finding to a Jira issue returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "264b82767e2ad329f00d3c08be5edd45", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 369, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"attributes\":{\"jira_issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"jira_issues\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 1124, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1124, + "text": "{\"data\":{\"id\":\"9efb1118-ed9c-4b02-b13b-f3acf8415f7c\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-20T15:22:44.644286Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/94762d2f0123331575cd81095e450f09?detection=static\",\"resource_id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2404808\",\"issue_key\":\"CSMSEC-105476\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-463\",\"modified_at\":\"2025-11-20T15:49:53.272293Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"modified_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2025-11-20T15:49:48.973Z", + "time": 4418 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/frozen.json new file mode 100644 index 000000000000..4b9b61ecc915 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/frozen.json @@ -0,0 +1 @@ +"2025-11-19T16:20:46.726Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/recording.har new file mode 100644 index 000000000000..ec43705f3e7f --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-finding-to-a-case-returns-OK-response_873849615/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security finding to a case returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "f77253d6b6e1a15c8bba935f7487c98f", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 606, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases/7d16945b-baf8-411e-ab2a-20fe43af1ea3" + }, + "response": { + "bodySize": 897, + "content": { + "mimeType": "application/vnd.api+json", + "size": 897, + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:54:23.634063Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"}],\"key\":\"CSMINV-459\",\"modified_at\":\"2025-11-19T16:20:51.754979Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"modified_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 525, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2025-11-19T16:20:46.731Z", + "time": 5074 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/frozen.json new file mode 100644 index 000000000000..ec2097a099b6 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:53:19.037Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/recording.har new file mode 100644 index 000000000000..2d6509d63672 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Bad-Request-response_2258003327/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a Jira issue returns \"Bad Request\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "1a1598f7b7463b12f967f4fd38f0fa52", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 254, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"attributes\":{\"jira_issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\"},\"relationships\":{\"findings\":{\"data\":[]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"jira_issues\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 82, + "content": { + "mimeType": "application/vnd.api+json", + "size": 82, + "text": "{\"errors\":[{\"status\":\"400\",\"title\":\"Bad Request\",\"detail\":\"no finding provided\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 400, + "statusText": "Bad Request" + }, + "startedDateTime": "2025-11-20T15:53:19.041Z", + "time": 736 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/frozen.json new file mode 100644 index 000000000000..657df17d3dc9 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:59:56.064Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/recording.har new file mode 100644 index 000000000000..a857ca0fc4f7 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-Not-Found-response_1347789144/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a Jira issue returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "b1091cc9c091d1720b0d8b3f6e867c72", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 297, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"attributes\":{\"jira_issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"wrong-finding-id\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"jira_issues\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 78, + "content": { + "mimeType": "application/vnd.api+json", + "size": 78, + "text": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"finding not found\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2025-11-20T15:59:56.068Z", + "time": 1598 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/frozen.json new file mode 100644 index 000000000000..30c3ac4919b5 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:52:21.664Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/recording.har new file mode 100644 index 000000000000..810f5db8dd5c --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-Jira-issue-returns-OK-response_1364337643/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a Jira issue returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "d56c2c70e68a0484470367cdb637611f", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 485, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"attributes\":{\"jira_issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\",\"type\":\"findings\"},{\"id\":\"MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"jira_issues\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 1357, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1357, + "text": "{\"data\":{\"id\":\"9efb1118-ed9c-4b02-b13b-f3acf8415f7c\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-20T15:22:44.644286Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/94762d2f0123331575cd81095e450f09?detection=static\",\"resource_id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\"},{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/13c7ffac3021be5d1bd4c5e07b575fca?detection=static\",\"resource_id\":\"MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2404808\",\"issue_key\":\"CSMSEC-105476\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-463\",\"modified_at\":\"2025-11-20T15:52:25.368628Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"modified_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2025-11-20T15:52:21.669Z", + "time": 3815 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/frozen.json new file mode 100644 index 000000000000..919a067e3fb6 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/frozen.json @@ -0,0 +1 @@ +"2025-11-19T16:16:38.781Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/recording.har new file mode 100644 index 000000000000..0dd6846be24a --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Bad-Request-response_1475227566/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a case returns \"Bad Request\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "f7157864476f6c1c361b63ac95bdf478", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 110, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 606, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"relationships\":{\"findings\":{\"data\":[]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases/7d16945b-baf8-411e-ab2a-20fe43af1ea3" + }, + "response": { + "bodySize": 82, + "content": { + "mimeType": "application/vnd.api+json", + "size": 82, + "text": "{\"errors\":[{\"status\":\"400\",\"title\":\"Bad Request\",\"detail\":\"no finding provided\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 400, + "statusText": "Bad Request" + }, + "startedDateTime": "2025-11-19T16:16:38.785Z", + "time": 874 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/frozen.json new file mode 100644 index 000000000000..bd2bba936e0a --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/frozen.json @@ -0,0 +1 @@ +"2025-11-19T16:17:49.938Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/recording.har new file mode 100644 index 000000000000..2be47c09b743 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-Not-Found-response_2525544597/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a case returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "fd2a19cdb852803c07eae82a40bbfcbc", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 202, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 583, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"wrong-case-id\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases/wrong-case-id" + }, + "response": { + "bodySize": 95, + "content": { + "mimeType": "application/vnd.api+json", + "size": 95, + "text": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"failed to get case: case not found\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2025-11-19T16:17:49.942Z", + "time": 1984 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/frozen.json new file mode 100644 index 000000000000..43a607ac6a56 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/frozen.json @@ -0,0 +1 @@ +"2025-11-19T16:23:42.957Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/recording.har new file mode 100644 index 000000000000..b36d46f5f4b2 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Attach-security-findings-to-a-case-returns-OK-response_3842768260/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Attach security findings to a case returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "fb0a6713d4ddbd8ea8febbb0f930458d", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 341, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 606, + "httpVersion": "HTTP/1.1", + "method": "PATCH", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"},{\"id\":\"MmUzMzZkODQ2YTI3NDU0OTk4NDk3NzhkOTY5YjU2Zjh-YWJjZGI1ODI4OTYzNWM3ZmUwZTBlOWRkYTRiMGUyOGQ=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases/7d16945b-baf8-411e-ab2a-20fe43af1ea3" + }, + "response": { + "bodySize": 1363, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1363, + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:54:23.634063Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"},{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/36d53183f8fefbbc2208878f3d2011f0?detection=static\",\"resource_id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\"},{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/2e336d846a2745499849778d969b56f8?detection=static\",\"resource_id\":\"MmUzMzZkODQ2YTI3NDU0OTk4NDk3NzhkOTY5YjU2Zjh-YWJjZGI1ODI4OTYzNWM3ZmUwZTBlOWRkYTRiMGUyOGQ=\"}],\"key\":\"CSMINV-459\",\"modified_at\":\"2025-11-19T16:23:22.109092Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"modified_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2025-11-19T16:23:42.962Z", + "time": 2523 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/frozen.json new file mode 100644 index 000000000000..05291f687697 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/frozen.json @@ -0,0 +1 @@ +"2025-11-19T17:01:11.179Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/recording.har new file mode 100644 index 000000000000..2564d188f56a --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-finding-returns-Created-response_2303345376/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create Jira issue for security finding returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "4744415743652eb0ec065e907eaf5d81", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 700, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"6a773295-8729-4034-aada-53b64cbe02e7\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"}],\"included\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"id\":\"6a773295-8729-4034-aada-53b64cbe02e7\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"},{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 1041, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1041, + "text": "{\"data\":[{\"id\":\"6a773295-8729-4034-aada-53b64cbe02e7\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T17:01:15.21452Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2402037\",\"issue_key\":\"CSMSEC-105473\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105473\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-461\",\"modified_at\":\"2025-11-19T17:01:16.621974Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-19T17:01:11.184Z", + "time": 5537 + }, + { + "_id": "d3dbab4a54236df36069407af8cb9daf", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"6a773295-8729-4034-aada-53b64cbe02e7\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-19T17:01:16.729Z", + "time": 2233 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/frozen.json new file mode 100644 index 000000000000..5c3c0a8bf61f --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/frozen.json @@ -0,0 +1 @@ +"2025-11-21T14:49:30.001Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/recording.har new file mode 100644 index 000000000000..c7a630ed666f --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issue-for-security-findings-returns-Created-response_3447621107/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create Jira issue for security findings returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "40dc36d3aff07a0ed962e4dbbff80b14", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 932, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"e469ceda-957a-4557-a607-9ff25032e9ca\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"}],\"included\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"id\":\"e469ceda-957a-4557-a607-9ff25032e9ca\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\",\"type\":\"findings\"},{\"id\":\"ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"},{\"id\":\"MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\",\"type\":\"findings\"},{\"id\":\"ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\",\"type\":\"findings\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 1275, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1275, + "text": "{\"data\":[{\"id\":\"e469ceda-957a-4557-a607-9ff25032e9ca\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-21T14:49:32.034826Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/f16db9b7fa42c8a047777b354d6ccfe7?detection=static\",\"resource_id\":\"ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\"},{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/3510289f2aa284ab44f86b66e1f64cc7?detection=static\",\"resource_id\":\"MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2407744\",\"issue_key\":\"CSMSEC-105481\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105481\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-468\",\"modified_at\":\"2025-11-21T14:49:33.306003Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-21T14:49:30.005Z", + "time": 3549 + }, + { + "_id": "878b806040e9b7da0c6b8c2abe8f6bc7", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"e469ceda-957a-4557-a607-9ff25032e9ca\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-21T14:49:33.571Z", + "time": 1223 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/frozen.json new file mode 100644 index 000000000000..2829227f0a77 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/frozen.json @@ -0,0 +1 @@ +"2025-11-20T12:01:47.295Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/recording.har new file mode 100644 index 000000000000..b7623f3b665c --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Bad-Request-response_3155678174/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create Jira issues for security findings returns \"Bad Request\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "dfc86e15f2908c6c327124698d3f3a50", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 406, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"a7c38bab-ae98-4113-878c-c98799f914c2\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"}],\"included\":[{\"id\":\"a7c38bab-ae98-4113-878c-c98799f914c2\",\"relationships\":{\"findings\":{\"data\":[]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 82, + "content": { + "mimeType": "application/vnd.api+json", + "size": 82, + "text": "{\"errors\":[{\"status\":\"400\",\"title\":\"Bad Request\",\"detail\":\"no finding provided\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 400, + "statusText": "Bad Request" + }, + "startedDateTime": "2025-11-20T12:01:47.299Z", + "time": 761 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/frozen.json new file mode 100644 index 000000000000..6cb444aef4b3 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:32:21.828Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/recording.har new file mode 100644 index 000000000000..82710e27dbc6 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Created-response_2903340780/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create Jira issues for security findings returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "81f0f4371280de2c7d8d05c23337939e", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 1313, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 581, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"53e242c6-a7d6-46ad-9680-b8d14753f716\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"},{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"195772b2-1f53-41d2-b81e-48c8e6c21d33\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"}],\"included\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"id\":\"53e242c6-a7d6-46ad-9680-b8d14753f716\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"id\":\"195772b2-1f53-41d2-b81e-48c8e6c21d33\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"},{\"id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\",\"type\":\"findings\"},{\"id\":\"MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=\",\"type\":\"findings\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 2073, + "content": { + "mimeType": "application/vnd.api+json", + "size": 2073, + "text": "{\"data\":[{\"id\":\"53e242c6-a7d6-46ad-9680-b8d14753f716\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-20T15:32:23.777159Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/94762d2f0123331575cd81095e450f09?detection=static\",\"resource_id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2404837\",\"issue_key\":\"CSMSEC-105480\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105480\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-467\",\"modified_at\":\"2025-11-20T15:32:25.088199Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}},{\"id\":\"195772b2-1f53-41d2-b81e-48c8e6c21d33\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-20T15:32:23.776904Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/13c7ffac3021be5d1bd4c5e07b575fca?detection=static\",\"resource_id\":\"MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=\"}],\"jira_issue\":{\"status\":\"COMPLETED\",\"result\":{\"issue_id\":\"2404836\",\"issue_key\":\"CSMSEC-105479\",\"issue_url\":\"https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105479\",\"account_id\":\"fdcffa62-24ab-4914-a195-a22bdc607030\"}},\"key\":\"CSMINV-466\",\"modified_at\":\"2025-11-20T15:32:24.96456Z\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-20T15:32:21.833Z", + "time": 3480 + }, + { + "_id": "d15df31a872599410c465c4c28433655", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"53e242c6-a7d6-46ad-9680-b8d14753f716\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-20T15:32:25.322Z", + "time": 1350 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/frozen.json new file mode 100644 index 000000000000..13a637bbe512 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/frozen.json @@ -0,0 +1 @@ +"2025-11-20T15:42:51.100Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/recording.har new file mode 100644 index 000000000000..535bf80f6b5b --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-Jira-issues-for-security-findings-returns-Not-Found-response_3263651173/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create Jira issues for security findings returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "f21ac68677c1ddb94c058bfdcaa7c533", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 700, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 580, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"case\":{\"data\":{\"id\":\"6ed1d7c2-e1a3-4369-b92b-a38d3cc75cf3\",\"type\":\"cases\"}}},\"type\":\"jira_issues\"}],\"included\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"id\":\"6ed1d7c2-e1a3-4369-b92b-a38d3cc75cf3\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"00000000-0000-0000-0000-000000000000\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"id\":\"00000000-0000-0000-0000-000000000000\",\"type\":\"projects\"},{\"id\":\"YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM=\",\"type\":\"findings\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/jira_issues" + }, + "response": { + "bodySize": 78, + "content": { + "mimeType": "application/vnd.api+json", + "size": 78, + "text": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"project not found\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2025-11-20T15:42:51.105Z", + "time": 4752 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/frozen.json new file mode 100644 index 000000000000..056d74711841 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/frozen.json @@ -0,0 +1 @@ +"2025-11-19T13:45:48.321Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/recording.har new file mode 100644 index 000000000000..2bec009a033b --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-finding-returns-Created-response_4143350075/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create case for security finding returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "51c4e4e0919313779424e52cd6a52681", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 329, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 569, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 771, + "content": { + "mimeType": "application/vnd.api+json", + "size": 771, + "text": "{\"data\":[{\"id\":\"639c5df7-2352-4fc6-9d39-7dc8bdb8af14\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:45:50.295906Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"}],\"key\":\"CSMINV-454\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 525, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-19T13:45:48.325Z", + "time": 1953 + }, + { + "_id": "c7a2f33b82d73106eebc42a4877be392", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"639c5df7-2352-4fc6-9d39-7dc8bdb8af14\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-19T13:45:50.293Z", + "time": 905 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/frozen.json new file mode 100644 index 000000000000..dd910783c911 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/frozen.json @@ -0,0 +1 @@ +"2025-11-19T13:46:07.661Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/recording.har new file mode 100644 index 000000000000..3d10e6afd227 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-case-for-security-findings-returns-Created-response_2030366502/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create case for security findings returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "d04ffa36418b582f47ed5b22a0b60827", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 445, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 569, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"},{\"id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 1004, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1004, + "text": "{\"data\":[{\"id\":\"2c1ac0c4-e8cf-4699-8781-09077b10d2a0\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:46:09.874194Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/36d53183f8fefbbc2208878f3d2011f0?detection=static\",\"resource_id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\"},{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"}],\"key\":\"CSMINV-455\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-19T13:46:07.666Z", + "time": 2295 + }, + { + "_id": "c198d5249355a9d47ab213b40ab22dc1", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"2c1ac0c4-e8cf-4699-8781-09077b10d2a0\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-19T13:46:09.976Z", + "time": 1255 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/frozen.json new file mode 100644 index 000000000000..e088d8a48f72 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/frozen.json @@ -0,0 +1 @@ +"2025-11-19T13:46:49.148Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/recording.har new file mode 100644 index 000000000000..6f31ec6613f2 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Bad-Request-response_2184371129/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create cases for security findings returns \"Bad Request\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "29bad7b97805685f1ae79b69cab3719f", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 167, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 569, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"findings\":{\"data\":[]},\"project\":{\"data\":{\"id\":\"7f198869-c7ef-4afc-97cf-da5cdc13b5c3\",\"type\":\"projects\"}}},\"type\":\"cases\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 82, + "content": { + "mimeType": "application/vnd.api+json", + "size": 82, + "text": "{\"errors\":[{\"status\":\"400\",\"title\":\"Bad Request\",\"detail\":\"no finding provided\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 400, + "statusText": "Bad Request" + }, + "startedDateTime": "2025-11-19T13:46:49.152Z", + "time": 539 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/frozen.json new file mode 100644 index 000000000000..7ba50f31c241 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/frozen.json @@ -0,0 +1 @@ +"2025-11-19T13:54:20.603Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/recording.har new file mode 100644 index 000000000000..ddcc3e9645c7 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Created-response_1523445951/recording.har @@ -0,0 +1,114 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create cases for security findings returns \"Created\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "196e43eec69868ccf6de26033389542a", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 648, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 569, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"},{\"attributes\":{\"description\":\"A description\",\"title\":\"A title\"},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}},\"type\":\"cases\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 1532, + "content": { + "mimeType": "application/vnd.api+json", + "size": 1532, + "text": "{\"data\":[{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:54:23.634063Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/dfa027f7c037b2f77159adc027fecb56?detection=static\",\"resource_id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\"}],\"key\":\"CSMINV-459\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}},{\"id\":\"601cab78-ef04-4bdf-901a-55533afbde0b\",\"type\":\"cases\",\"attributes\":{\"created_at\":\"2025-11-19T13:54:23.634552Z\",\"creation_source\":\"CS_SECURITY_FINDING\",\"description\":\"A description\",\"insights\":[{\"type\":\"SECURITY_FINDING\",\"ref\":\"/security/appsec/vm/library/vulnerability/36d53183f8fefbbc2208878f3d2011f0?detection=static\",\"resource_id\":\"MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=\"}],\"key\":\"CSMINV-458\",\"priority\":\"NOT_DEFINED\",\"status\":\"OPEN\",\"status_group\":\"SG_OPEN\",\"status_name\":\"Open\",\"title\":\"A title\",\"type\":\"SECURITY\"},\"relationships\":{\"created_by\":{\"data\":{\"id\":\"dc09afab-6ae7-11ef-92b1-828dac1b0195\",\"type\":\"users\"}},\"project\":{\"data\":{\"id\":\"959a6f71-bac8-4027-b1d3-2264f569296f\",\"type\":\"projects\"}}}}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 526, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 201, + "statusText": "Created" + }, + "startedDateTime": "2025-11-19T13:54:20.607Z", + "time": 3009 + }, + { + "_id": "11dbbde462ff4a3579f4e6a53babed00", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 225, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"id\":\"7d16945b-baf8-411e-ab2a-20fe43af1ea3\",\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-19T13:54:23.627Z", + "time": 1182 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/frozen.json new file mode 100644 index 000000000000..1c083caa8cc8 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/frozen.json @@ -0,0 +1 @@ +"2025-11-19T13:47:19.797Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/recording.har new file mode 100644 index 000000000000..612160b95688 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Create-cases-for-security-findings-returns-Not-Found-response_2082217698/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Create cases for security findings returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "fa1894af1c5a8cb9bf7d2aec7c5dd47b", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 282, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 569, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":[{\"attributes\":{},\"relationships\":{\"findings\":{\"data\":[{\"id\":\"ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=\",\"type\":\"findings\"}]},\"project\":{\"data\":{\"id\":\"00000000-0000-0000-0000-000000000000\",\"type\":\"projects\"}}},\"type\":\"cases\"}]}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 78, + "content": { + "mimeType": "application/vnd.api+json", + "size": 78, + "text": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"project not found\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2025-11-19T13:47:19.801Z", + "time": 2302 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/frozen.json new file mode 100644 index 000000000000..d42ecb4d2479 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/frozen.json @@ -0,0 +1 @@ +"2025-11-20T16:07:27.292Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/recording.har new file mode 100644 index 000000000000..8ab5df552b59 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Bad-Request-response_2671955878/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Detach security findings from their case returns \"Bad Request\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "8867f3aba8dd3d77389d7ce0a41008b2", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 66, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 556, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"relationships\":{\"findings\":{\"data\":[]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 82, + "content": { + "mimeType": "application/vnd.api+json", + "size": 82, + "text": "{\"errors\":[{\"status\":\"400\",\"title\":\"Bad Request\",\"detail\":\"no finding provided\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 400, + "statusText": "Bad Request" + }, + "startedDateTime": "2025-11-20T16:07:27.295Z", + "time": 799 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/frozen.json new file mode 100644 index 000000000000..21cd1c121f33 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/frozen.json @@ -0,0 +1 @@ +"2025-11-21T13:41:10.798Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/recording.har new file mode 100644 index 000000000000..392df5d0e6c0 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-No-Content-response_4005960220/recording.har @@ -0,0 +1,61 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Detach security findings from their case returns \"No Content\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "174509b68566c668aa99a0da232e4fcb", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 181, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 555, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"relationships\":{\"findings\":{\"data\":[{\"id\":\"YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM=\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 464, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2025-11-21T13:41:10.802Z", + "time": 2703 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/frozen.json b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/frozen.json new file mode 100644 index 000000000000..ba38d7d27da4 --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/frozen.json @@ -0,0 +1 @@ +"2025-11-20T16:06:53.415Z" diff --git a/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/recording.har b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/recording.har new file mode 100644 index 000000000000..82fa831f966f --- /dev/null +++ b/cassettes/v2/Security-Monitoring_1187227211/Detach-security-findings-from-their-case-returns-Not-Found-response_1214113773/recording.har @@ -0,0 +1,67 @@ +{ + "log": { + "_recordingName": "Security Monitoring/Detach security findings from their case returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "fb1bb6dc156a1af0cfcf6c91669ca655", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 109, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 557, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"data\":{\"relationships\":{\"findings\":{\"data\":[{\"id\":\"wrong-finding-id\",\"type\":\"findings\"}]}},\"type\":\"cases\"}}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/security/findings/cases" + }, + "response": { + "bodySize": 78, + "content": { + "mimeType": "application/vnd.api+json", + "size": 78, + "text": "{\"errors\":[{\"status\":\"404\",\"title\":\"Not Found\",\"detail\":\"finding not found\"}]}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/vnd.api+json" + } + ], + "headersSize": 524, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2025-11-20T16:06:53.420Z", + "time": 7318 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/features/v2/given.json b/features/v2/given.json index d1d4bce2f100..6c6d3bf98f4c 100644 --- a/features/v2/given.json +++ b/features/v2/given.json @@ -350,7 +350,7 @@ "parameters": [ { "name": "body", - "value": "{\n \"data\": {\n \"type\": \"deployment_gate\",\n \"attributes\": {\n \"service\": \"my-service\",\n \"env\": \"production\",\n \"identifier\": \"my-gate-{{ unique_lower_alnum }}\",\n \"dry_run\": false\n }\n }\n}" + "value": "{\n \"data\": {\n \"type\": \"deployment_gate\",\n \"attributes\": {\n \"service\": \"my-service\",\n \"env\": \"production\",\n \"identifier\": \"my-gate\",\n \"dry_run\": false\n }\n }\n}" } ], "step": "there is a valid \"deployment_gate\" in the system", diff --git a/features/v2/security_monitoring.feature b/features/v2/security_monitoring.feature index 531c84c19c11..5599d509afc2 100644 --- a/features/v2/security_monitoring.feature +++ b/features/v2/security_monitoring.feature @@ -5,9 +5,83 @@ Feature: Security Monitoring information. Background: - Given an instance of "SecurityMonitoring" API - And a valid "apiKeyAuth" key in the system + Given a valid "apiKeyAuth" key in the system And a valid "appKeyAuth" key in the system + And an instance of "SecurityMonitoring" API + + @team:DataDog/k9-investigation + Scenario: Attach security finding to a Jira issue returns "OK" response + Given new "AttachJiraIssue" request + And body with value {"data": {"attributes": {"jira_issue_url": "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476"}, "relationships": {"findings": {"data": [{"id": "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "jira_issues"}} + When the request is sent + Then the response status is 200 OK + And the response "data.attributes.status_group" is equal to "SG_OPEN" + And the response "data.attributes.insights" has item with field "resource_id" with value "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=" + And the response "data.attributes.jira_issue.result.issue_url" is equal to "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476" + + @team:DataDog/k9-investigation + Scenario: Attach security finding to a case returns "OK" response + Given new "AttachCase" request + And request contains "case_id" parameter with value "7d16945b-baf8-411e-ab2a-20fe43af1ea3" + And body with value {"data": {"id": "7d16945b-baf8-411e-ab2a-20fe43af1ea3", "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}]}}, "type": "cases"}} + When the request is sent + Then the response status is 200 OK + And the response "data.id" is equal to "7d16945b-baf8-411e-ab2a-20fe43af1ea3" + And the response "data.attributes.status_group" is equal to "SG_OPEN" + And the response "data.attributes.insights" has item with field "resource_id" with value "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a Jira issue returns "Bad Request" response + Given new "AttachJiraIssue" request + And body with value {"data": {"attributes": {"jira_issue_url": "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476"}, "relationships": {"findings": {"data": []}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "jira_issues"}} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a Jira issue returns "Not Found" response + Given new "AttachJiraIssue" request + And body with value {"data": {"attributes": {"jira_issue_url": "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476"}, "relationships": {"findings": {"data": [{"id": "wrong-finding-id", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "jira_issues"}} + When the request is sent + Then the response status is 404 Not Found + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a Jira issue returns "OK" response + Given new "AttachJiraIssue" request + And body with value {"data": {"attributes": {"jira_issue_url": "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476"}, "relationships": {"findings": {"data": [{"id": "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=", "type": "findings"}, {"id": "MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "jira_issues"}} + When the request is sent + Then the response status is 200 OK + And the response "data.attributes.status_group" is equal to "SG_OPEN" + And the response "data.attributes.insights" has item with field "resource_id" with value "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=" + And the response "data.attributes.insights" has item with field "resource_id" with value "MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=" + And the response "data.attributes.jira_issue.result.issue_url" is equal to "https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-105476" + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a case returns "Bad Request" response + Given new "AttachCase" request + And request contains "case_id" parameter with value "7d16945b-baf8-411e-ab2a-20fe43af1ea3" + And body with value {"data": {"id": "7d16945b-baf8-411e-ab2a-20fe43af1ea3", "relationships": {"findings": {"data": []}}, "type": "cases"}} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a case returns "Not Found" response + Given new "AttachCase" request + And request contains "case_id" parameter with value "wrong-case-id" + And body with value {"data": {"id": "wrong-case-id", "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}]}}, "type": "cases"}} + When the request is sent + Then the response status is 404 Not Found + + @team:DataDog/k9-investigation + Scenario: Attach security findings to a case returns "OK" response + Given new "AttachCase" request + And request contains "case_id" parameter with value "7d16945b-baf8-411e-ab2a-20fe43af1ea3" + And body with value {"data": {"id": "7d16945b-baf8-411e-ab2a-20fe43af1ea3", "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}, {"id": "MmUzMzZkODQ2YTI3NDU0OTk4NDk3NzhkOTY5YjU2Zjh-YWJjZGI1ODI4OTYzNWM3ZmUwZTBlOWRkYTRiMGUyOGQ=", "type": "findings"}]}}, "type": "cases"}} + When the request is sent + Then the response status is 200 OK + And the response "data.id" is equal to "7d16945b-baf8-411e-ab2a-20fe43af1ea3" + And the response "data.attributes.status_group" is equal to "SG_OPEN" + And the response "data.attributes.insights" has item with field "resource_id" with value "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + And the response "data.attributes.insights" has item with field "resource_id" with value "MmUzMzZkODQ2YTI3NDU0OTk4NDk3NzhkOTY5YjU2Zjh-YWJjZGI1ODI4OTYzNWM3ZmUwZTBlOWRkYTRiMGUyOGQ=" @team:DataDog/k9-cloud-security-platform Scenario: Cancel a historical job returns "Bad Request" response @@ -184,6 +258,78 @@ Feature: Security Monitoring Then the response status is 200 OK And the response "terraformContent" is equal to "resource \"datadog_security_monitoring_rule\" \"_{{ unique_hash }}\" {\n\tname = \"_{{ unique_hash }}\"\n\tenabled = true\n\tquery {\n\t\tquery = \"@test:true\"\n\t\tgroup_by_fields = []\n\t\thas_optional_group_by_fields = false\n\t\tdistinct_fields = []\n\t\taggregation = \"count\"\n\t\tname = \"\"\n\t\tdata_source = \"logs\"\n\t}\n\toptions {\n\t\tkeep_alive = 3600\n\t\tmax_signal_duration = 86400\n\t\tdetection_method = \"threshold\"\n\t\tevaluation_window = 900\n\t}\n\tcase {\n\t\tname = \"\"\n\t\tstatus = \"info\"\n\t\tnotifications = []\n\t\tcondition = \"a > 0\"\n\t}\n\tmessage = \"Test rule\"\n\ttags = []\n\thas_extended_title = false\n\ttype = \"log_detection\"\n}\n" + @team:DataDog/k9-investigation + Scenario: Create Jira issue for security finding returns "Created" response + Given new "CreateJiraIssues" request + And body with value {"data": [{"type": "jira_issues", "attributes": {}, "relationships": {"case": {"data": {"type": "cases", "id": "6a773295-8729-4034-aada-53b64cbe02e7"}}}}], "included": [{"type": "cases", "attributes": {"title": "A title", "description": "A description"}, "relationships": {"project": {"data": {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}}, "findings": {"data": [{"type": "findings", "id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y="}]}}, "id": "6a773295-8729-4034-aada-53b64cbe02e7"}, {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}, {"type": "findings", "id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y="}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 1 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 1 + And the response "data[0].attributes.insights[0].resource_id" is equal to "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + And the response "data[0].attributes.jira_issue.status" is equal to "COMPLETED" + + @team:DataDog/k9-investigation + Scenario: Create Jira issue for security findings returns "Created" response + Given new "CreateJiraIssues" request + And body with value {"data": [{"type": "jira_issues", "attributes": {}, "relationships": {"case": {"data": {"type": "cases", "id": "e469ceda-957a-4557-a607-9ff25032e9ca"}}}}], "included": [{"type": "cases", "attributes": {"title": "A title", "description": "A description"}, "relationships": {"project": {"data": {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}}, "findings": {"data": [{"type": "findings", "id": "MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY="}, {"type": "findings", "id": "ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY="}]}}, "id": "e469ceda-957a-4557-a607-9ff25032e9ca"}, {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}, {"type": "findings", "id": "MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY="}, {"type": "findings", "id": "ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY="}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 1 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 2 + And the response "data[0].attributes.insights[1].resource_id" is equal to "MzUxMDI4OWYyYWEyODRhYjQ0Zjg2YjY2ZTFmNjRjYzd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=" + And the response "data[0].attributes.insights[1].type" is equal to "SECURITY_FINDING" + And the response "data[0].attributes.insights[0].resource_id" is equal to "ZjE2ZGI5YjdmYTQyYzhhMDQ3Nzc3YjM1NGQ2Y2NmZTd-NDU2OWQyNTk1MjM5OGI2NzJjMTVhYjhiODY1ZDcwZWY=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + And the response "data[0].attributes.jira_issue.status" is equal to "COMPLETED" + + @team:DataDog/k9-investigation + Scenario: Create Jira issues for security findings returns "Bad Request" response + Given new "CreateJiraIssues" request + And body with value {"data": [{"type": "jira_issues", "attributes": {}, "relationships": {"case": {"data": {"type": "cases", "id": "a7c38bab-ae98-4113-878c-c98799f914c2"}}}}], "included": [{"type": "cases", "relationships": {"project": {"data": {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}}, "findings": {"data": []}}, "id": "a7c38bab-ae98-4113-878c-c98799f914c2"}, {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}]} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/k9-investigation + Scenario: Create Jira issues for security findings returns "Created" response + Given new "CreateJiraIssues" request + And body with value {"data": [{"type": "jira_issues", "attributes":{}, "relationships": {"case": {"data": {"type": "cases", "id":"53e242c6-a7d6-46ad-9680-b8d14753f716"}}}}, {"type": "jira_issues", "attributes": {}, "relationships": {"case": {"data": {"type": "cases", "id": "195772b2-1f53-41d2-b81e-48c8e6c21d33"}}}}], "included":[{"type":"cases", "attributes":{"title":"A title", "description":"A description"}, "relationships":{"project":{"data":{"type":"projects", "id":"959a6f71-bac8-4027-b1d3-2264f569296f"}}, "findings": {"data": [{"type": "findings", "id": "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI="}]}}, "id": "53e242c6-a7d6-46ad-9680-b8d14753f716"}, {"type": "cases", "attributes": {"title": "A title", "description": "A description"}, "relationships": {"project": {"data": {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}}, "findings": {"data":[{"type": "findings", "id": "MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM="}]}}, "id": "195772b2-1f53-41d2-b81e-48c8e6c21d33"}, {"type": "projects", "id": "959a6f71-bac8-4027-b1d3-2264f569296f"}, {"type": "findings", "id": "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI="}, {"type": "findings", "id": "MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM="}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 2 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 1 + And the response "data[0].attributes.insights[0].resource_id" is equal to "OTQ3NjJkMmYwMTIzMzMxNTc1Y2Q4MTA5NWU0NTBmMDl-ZjE3NjMxZWVkYzBjZGI1NDY2NWY2OGQxZDk4MDY4MmI=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + And the response "data[0].attributes.jira_issue.status" is equal to "COMPLETED" + And the response "data[1]" has field "id" + And the response "data[1].attributes.title" is equal to "A title" + And the response "data[1].attributes.description" is equal to "A description" + And the response "data[1].attributes.type" is equal to "SECURITY" + And the response "data[1].attributes.insights" has length 1 + And the response "data[1].attributes.insights[0].resource_id" is equal to "MTNjN2ZmYWMzMDIxYmU1ZDFiZDRjNWUwN2I1NzVmY2F-YTA3MzllMTUzNWM3NmEyZjdiNzEzOWM5YmViZTMzOGM=" + And the response "data[1].attributes.insights[0].type" is equal to "SECURITY_FINDING" + And the response "data[1].attributes.jira_issue.status" is equal to "COMPLETED" + + @team:DataDog/k9-investigation + Scenario: Create Jira issues for security findings returns "Not Found" response + Given new "CreateJiraIssues" request + And body with value {"data": [{"type": "jira_issues", "attributes": {}, "relationships": {"case": {"data": {"type": "cases", "id": "6ed1d7c2-e1a3-4369-b92b-a38d3cc75cf3"}}}}], "included": [{"type": "cases", "attributes": {"title": "A title", "description": "A description"}, "relationships": {"project": {"data": {"type": "projects", "id": "00000000-0000-0000-0000-000000000000"}}, "findings": {"data": [{"type": "findings", "id": "YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM="}]}}, "id": "6ed1d7c2-e1a3-4369-b92b-a38d3cc75cf3"}, {"type": "projects", "id": "00000000-0000-0000-0000-000000000000"}, {"type": "findings", "id": "YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM="}]} + When the request is sent + Then the response status is 404 Not Found + @skip-validation @team:DataDog/k9-cloud-security-platform Scenario: Create a cloud_configuration rule returns "OK" response Given new "CreateSecurityMonitoringRule" request @@ -408,6 +554,74 @@ Feature: Security Monitoring And the response "data.attributes.rule_query" is equal to "type:log_detection source:cloudtrail" And the response "data.attributes.data_exclusion_query" is equal to "account_id:12345" + @team:DataDog/k9-investigation + Scenario: Create case for security finding returns "Created" response + Given new "CreateCases" request + And body with value {"data": [{"attributes": {"title": "A title", "description": "A description"}, "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "cases"}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 1 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 1 + And the response "data[0].attributes.insights[0].resource_id" is equal to "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + + @team:DataDog/k9-investigation + Scenario: Create case for security findings returns "Created" response + Given new "CreateCases" request + And body with value {"data": [{"attributes": {"title": "A title", "description": "A description"}, "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}, {"id": "MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "cases"}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 1 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 2 + And the response "data[0].attributes.insights[1].resource_id" is equal to "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + And the response "data[0].attributes.insights[1].type" is equal to "SECURITY_FINDING" + And the response "data[0].attributes.insights[0].resource_id" is equal to "MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + + @team:DataDog/k9-investigation + Scenario: Create cases for security findings returns "Bad Request" response + Given new "CreateCases" request + And body with value {"data": [{"attributes": {}, "relationships": {"findings": {"data": []}, "project": {"data": {"id": "7f198869-c7ef-4afc-97cf-da5cdc13b5c3", "type": "projects"}}}, "type": "cases"}]} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/k9-investigation + Scenario: Create cases for security findings returns "Created" response + Given new "CreateCases" request + And body with value {"data": [{"attributes": {"title": "A title", "description": "A description"}, "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "cases"}, {"attributes": {"title": "A title", "description": "A description"}, "relationships": {"findings": {"data": [{"id": "MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=", "type": "findings"}]}, "project": {"data": {"id": "959a6f71-bac8-4027-b1d3-2264f569296f", "type": "projects"}}}, "type": "cases"}]} + When the request is sent + Then the response status is 201 Created + And the response "data" has length 2 + And the response "data[0]" has field "id" + And the response "data[0].attributes.title" is equal to "A title" + And the response "data[0].attributes.description" is equal to "A description" + And the response "data[0].attributes.type" is equal to "SECURITY" + And the response "data[0].attributes.insights" has length 1 + And the response "data[0].attributes.insights[0].resource_id" is equal to "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=" + And the response "data[0].attributes.insights[0].type" is equal to "SECURITY_FINDING" + And the response "data[1]" has field "id" + And the response "data[1].attributes.title" is equal to "A title" + And the response "data[1].attributes.description" is equal to "A description" + And the response "data[1].attributes.type" is equal to "SECURITY" + And the response "data[1].attributes.insights" has length 1 + And the response "data[1].attributes.insights[0].resource_id" is equal to "MzZkNTMxODNmOGZlZmJiYzIyMDg4NzhmM2QyMDExZjB-ZmY5NzUwNDQzYTE0MGIyNDM1MTg4YjkxZDNmMDU4OGU=" + And the response "data[1].attributes.insights[0].type" is equal to "SECURITY_FINDING" + + @team:DataDog/k9-investigation + Scenario: Create cases for security findings returns "Not Found" response + Given new "CreateCases" request + And body with value {"data": [{"attributes": {}, "relationships": {"findings": {"data": [{"id": "ZGZhMDI3ZjdjMDM3YjJmNzcxNTlhZGMwMjdmZWNiNTZ-MTVlYTNmYWU3NjNlOTNlYTE2YjM4N2JmZmI4Yjk5N2Y=", "type": "findings"}]}, "project": {"data": {"id": "00000000-0000-0000-0000-000000000000", "type": "projects"}}}, "type": "cases"}]} + When the request is sent + Then the response status is 404 Not Found + @team:DataDog/k9-cloud-security-platform Scenario: Delete a custom framework returns "Bad Request" response Given new "DeleteCustomFramework" request @@ -546,6 +760,27 @@ Feature: Security Monitoring When the request is sent Then the response status is 204 OK + @team:DataDog/k9-investigation + Scenario: Detach security findings from their case returns "Bad Request" response + Given new "DetachCase" request + And body with value {"data": {"relationships": {"findings": {"data": []}}, "type": "cases"}} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/k9-investigation + Scenario: Detach security findings from their case returns "No Content" response + Given new "DetachCase" request + And body with value {"data": {"relationships": {"findings": {"data": [{"id": "YzM2MTFjYzcyNmY0Zjg4MTAxZmRlNjQ1MWU1ZGQwYzR-YzI5NzE5Y2Y4MzU4ZjliNzhkNjYxNTY0ODIzZDQ2YTM=", "type": "findings"}]}}, "type": "cases"}} + When the request is sent + Then the response status is 204 No Content + + @team:DataDog/k9-investigation + Scenario: Detach security findings from their case returns "Not Found" response + Given new "DetachCase" request + And body with value {"data": {"relationships": {"findings": {"data": [{"id": "wrong-finding-id", "type": "findings"}]}}, "type": "cases"}} + When the request is sent + Then the response status is 404 Not Found + @generated @skip @team:DataDog/asm-vm Scenario: Get SBOM returns "Bad request: The server cannot process the request due to invalid syntax in the request." response Given operation "GetSBOM" enabled diff --git a/features/v2/undo.json b/features/v2/undo.json index 7c226bf60d33..2e54bbe0afb0 100644 --- a/features/v2/undo.json +++ b/features/v2/undo.json @@ -3670,6 +3670,50 @@ "type": "safe" } }, + "DetachCase": { + "tag": "Security Monitoring", + "undo": { + "type": "idempotent" + } + }, + "CreateCases": { + "tag": "Security Monitoring", + "undo": { + "operationId": "DetachCase", + "parameters": [ + { + "name": "body", + "template": "{\n \"data\": {\n \"type\": \"cases\",\n \"id\": \"{{data[0].id}}\",\n \"relationships\": {\n \"findings\": {\n \"data\": [\n {\n \"type\": \"findings\",\n \"id\": \"{{data[0].attributes.insights[0].resource_id}}\"\n }\n ]\n }\n }\n }\n}" + } + ], + "type": "unsafe" + } + }, + "AttachCase": { + "tag": "Security Monitoring", + "undo": { + "type": "idempotent" + } + }, + "AttachJiraIssue": { + "tag": "Security Monitoring", + "undo": { + "type": "idempotent" + } + }, + "CreateJiraIssues": { + "tag": "Security Monitoring", + "undo": { + "operationId": "DetachCase", + "parameters": [ + { + "name": "body", + "template": "{\n \"data\": {\n \"type\": \"cases\",\n \"id\": \"{{data[0].id}}\",\n \"relationships\": {\n \"findings\": {\n \"data\": [\n {\n \"type\": \"findings\",\n \"id\": \"{{data[0].attributes.insights[0].resource_id}}\"\n }\n ]\n }\n }\n }\n}" + } + ], + "type": "unsafe" + } + }, "ListAssetsSBOMs": { "tag": "Security Monitoring", "undo": { diff --git a/private/bdd_runner/src/support/scenarios_model_mapping.ts b/private/bdd_runner/src/support/scenarios_model_mapping.ts index 58da0cb71f68..bbcaf599cd57 100644 --- a/private/bdd_runner/src/support/scenarios_model_mapping.ts +++ b/private/bdd_runner/src/support/scenarios_model_mapping.ts @@ -3870,6 +3870,45 @@ export const ScenariosModelMappings: { [key: string]: OperationMapping } = { }, operationResponseType: "GetFindingResponse", }, + "SecurityMonitoringApi.V2.CreateCases": { + body: { + type: "CreateCaseRequestArray", + format: "", + }, + operationResponseType: "FindingCaseResponseArray", + }, + "SecurityMonitoringApi.V2.DetachCase": { + body: { + type: "DetachCaseRequest", + format: "", + }, + operationResponseType: "{}", + }, + "SecurityMonitoringApi.V2.AttachCase": { + caseId: { + type: "string", + format: "", + }, + body: { + type: "AttachCaseRequest", + format: "", + }, + operationResponseType: "FindingCaseResponse", + }, + "SecurityMonitoringApi.V2.CreateJiraIssues": { + body: { + type: "CreateJiraIssueRequestArray", + format: "", + }, + operationResponseType: "FindingCaseResponseArray", + }, + "SecurityMonitoringApi.V2.AttachJiraIssue": { + body: { + type: "AttachJiraIssueRequest", + format: "", + }, + operationResponseType: "FindingCaseResponse", + }, "SecurityMonitoringApi.V2.ListAssetsSBOMs": { pageToken: { type: "string", diff --git a/services/security_monitoring/src/v2/SecurityMonitoringApi.ts b/services/security_monitoring/src/v2/SecurityMonitoringApi.ts index 5cf737ad0065..eef1f36d1dca 100644 --- a/services/security_monitoring/src/v2/SecurityMonitoringApi.ts +++ b/services/security_monitoring/src/v2/SecurityMonitoringApi.ts @@ -24,15 +24,22 @@ import { import { TypingInfo } from "./models/TypingInfo"; import { APIErrorResponse } from "./models/APIErrorResponse"; import { AssetType } from "./models/AssetType"; +import { AttachCaseRequest } from "./models/AttachCaseRequest"; +import { AttachJiraIssueRequest } from "./models/AttachJiraIssueRequest"; import { BulkMuteFindingsRequest } from "./models/BulkMuteFindingsRequest"; import { BulkMuteFindingsResponse } from "./models/BulkMuteFindingsResponse"; import { CloudAssetType } from "./models/CloudAssetType"; import { ConvertJobResultsToSignalsRequest } from "./models/ConvertJobResultsToSignalsRequest"; +import { CreateCaseRequestArray } from "./models/CreateCaseRequestArray"; import { CreateCustomFrameworkRequest } from "./models/CreateCustomFrameworkRequest"; import { CreateCustomFrameworkResponse } from "./models/CreateCustomFrameworkResponse"; +import { CreateJiraIssueRequestArray } from "./models/CreateJiraIssueRequestArray"; import { CreateNotificationRuleParameters } from "./models/CreateNotificationRuleParameters"; import { DeleteCustomFrameworkResponse } from "./models/DeleteCustomFrameworkResponse"; +import { DetachCaseRequest } from "./models/DetachCaseRequest"; import { Finding } from "./models/Finding"; +import { FindingCaseResponse } from "./models/FindingCaseResponse"; +import { FindingCaseResponseArray } from "./models/FindingCaseResponseArray"; import { FindingEvaluation } from "./models/FindingEvaluation"; import { FindingStatus } from "./models/FindingStatus"; import { FindingVulnerabilityType } from "./models/FindingVulnerabilityType"; @@ -106,6 +113,117 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { this.userAgent = buildUserAgent("security-monitoring", version); } } + public async attachCase( + caseId: string, + body: AttachCaseRequest, + _options?: Configuration, + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'caseId' is not null or undefined + if (caseId === null || caseId === undefined) { + throw new RequiredError("caseId", "attachCase"); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError("body", "attachCase"); + } + + // Path Params + const localVarPath = "/api/v2/security/findings/cases/{case_id}".replace( + "{case_id}", + encodeURIComponent(String(caseId)), + ); + + // Make Request Context + const { server, overrides } = _config.getServerAndOverrides( + "SecurityMonitoringApi.v2.attachCase", + SecurityMonitoringApi.operationServers, + ); + const requestContext = server.makeRequestContext( + localVarPath, + HttpMethod.PATCH, + overrides, + ); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Set User-Agent + if (this.userAgent) { + requestContext.setHeaderParam("User-Agent", this.userAgent); + } + + // Body Params + const contentType = getPreferredMediaType(["application/json"]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = stringify( + serialize(body, TypingInfo, "AttachCaseRequest", ""), + contentType, + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + "AuthZ", + ]); + + return requestContext; + } + + public async attachJiraIssue( + body: AttachJiraIssueRequest, + _options?: Configuration, + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError("body", "attachJiraIssue"); + } + + // Path Params + const localVarPath = "/api/v2/security/findings/jira_issues"; + + // Make Request Context + const { server, overrides } = _config.getServerAndOverrides( + "SecurityMonitoringApi.v2.attachJiraIssue", + SecurityMonitoringApi.operationServers, + ); + const requestContext = server.makeRequestContext( + localVarPath, + HttpMethod.PATCH, + overrides, + ); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Set User-Agent + if (this.userAgent) { + requestContext.setHeaderParam("User-Agent", this.userAgent); + } + + // Body Params + const contentType = getPreferredMediaType(["application/json"]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = stringify( + serialize(body, TypingInfo, "AttachJiraIssueRequest", ""), + contentType, + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + "AuthZ", + ]); + + return requestContext; + } + public async cancelThreatHuntingJob( jobId: string, _options?: Configuration, @@ -325,6 +443,57 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { return requestContext; } + public async createCases( + body: CreateCaseRequestArray, + _options?: Configuration, + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError("body", "createCases"); + } + + // Path Params + const localVarPath = "/api/v2/security/findings/cases"; + + // Make Request Context + const { server, overrides } = _config.getServerAndOverrides( + "SecurityMonitoringApi.v2.createCases", + SecurityMonitoringApi.operationServers, + ); + const requestContext = server.makeRequestContext( + localVarPath, + HttpMethod.POST, + overrides, + ); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Set User-Agent + if (this.userAgent) { + requestContext.setHeaderParam("User-Agent", this.userAgent); + } + + // Body Params + const contentType = getPreferredMediaType(["application/json"]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = stringify( + serialize(body, TypingInfo, "CreateCaseRequestArray", ""), + contentType, + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + "AuthZ", + ]); + + return requestContext; + } + public async createCustomFramework( body: CreateCustomFrameworkRequest, _options?: Configuration, @@ -376,6 +545,57 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { return requestContext; } + public async createJiraIssues( + body: CreateJiraIssueRequestArray, + _options?: Configuration, + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError("body", "createJiraIssues"); + } + + // Path Params + const localVarPath = "/api/v2/security/findings/jira_issues"; + + // Make Request Context + const { server, overrides } = _config.getServerAndOverrides( + "SecurityMonitoringApi.v2.createJiraIssues", + SecurityMonitoringApi.operationServers, + ); + const requestContext = server.makeRequestContext( + localVarPath, + HttpMethod.POST, + overrides, + ); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Set User-Agent + if (this.userAgent) { + requestContext.setHeaderParam("User-Agent", this.userAgent); + } + + // Body Params + const contentType = getPreferredMediaType(["application/json"]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = stringify( + serialize(body, TypingInfo, "CreateJiraIssueRequestArray", ""), + contentType, + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + "AuthZ", + ]); + + return requestContext; + } + public async createSecurityFilter( body: SecurityFilterCreateRequest, _options?: Configuration, @@ -972,6 +1192,57 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { return requestContext; } + public async detachCase( + body: DetachCaseRequest, + _options?: Configuration, + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError("body", "detachCase"); + } + + // Path Params + const localVarPath = "/api/v2/security/findings/cases"; + + // Make Request Context + const { server, overrides } = _config.getServerAndOverrides( + "SecurityMonitoringApi.v2.detachCase", + SecurityMonitoringApi.operationServers, + ); + const requestContext = server.makeRequestContext( + localVarPath, + HttpMethod.DELETE, + overrides, + ); + requestContext.setHeaderParam("Accept", "*/*"); + requestContext.setHttpConfig(_config.httpConfig); + + // Set User-Agent + if (this.userAgent) { + requestContext.setHeaderParam("User-Agent", this.userAgent); + } + + // Body Params + const contentType = getPreferredMediaType(["application/json"]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = stringify( + serialize(body, TypingInfo, "DetachCaseRequest", ""), + contentType, + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + "AuthZ", + ]); + + return requestContext; + } + public async editSecurityMonitoringSignalAssignee( signalId: string, body: SecurityMonitoringSignalAssigneeUpdateRequest, @@ -3709,6 +3980,7 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { applySecurityAuthentication(_config, requestContext, [ "apiKeyAuth", "appKeyAuth", + "AuthZ", ]); return requestContext; @@ -4521,11 +4793,131 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory { "AuthZ", ]); - return requestContext; + return requestContext; + } +} + +export class SecurityMonitoringApiResponseProcessor { + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to attachCase + * @throws ApiException if the response code was not in [200, 299] + */ + public async attachCase( + response: ResponseContext, + ): Promise { + const contentType = normalizeMediaType(response.headers["content-type"]); + if (response.httpStatusCode === 200) { + const body: FindingCaseResponse = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponse", + ) as FindingCaseResponse; + return body; + } + if ( + response.httpStatusCode === 400 || + response.httpStatusCode === 404 || + response.httpStatusCode === 429 + ) { + const bodyText = parse(await response.body.text(), contentType); + let body: APIErrorResponse; + try { + body = deserialize( + bodyText, + TypingInfo, + "APIErrorResponse", + ) as APIErrorResponse; + } catch (error) { + logger.debug(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText, + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: FindingCaseResponse = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponse", + "", + ) as FindingCaseResponse; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"', + ); + } + + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to attachJiraIssue + * @throws ApiException if the response code was not in [200, 299] + */ + public async attachJiraIssue( + response: ResponseContext, + ): Promise { + const contentType = normalizeMediaType(response.headers["content-type"]); + if (response.httpStatusCode === 200) { + const body: FindingCaseResponse = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponse", + ) as FindingCaseResponse; + return body; + } + if ( + response.httpStatusCode === 400 || + response.httpStatusCode === 404 || + response.httpStatusCode === 429 + ) { + const bodyText = parse(await response.body.text(), contentType); + let body: APIErrorResponse; + try { + body = deserialize( + bodyText, + TypingInfo, + "APIErrorResponse", + ) as APIErrorResponse; + } catch (error) { + logger.debug(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText, + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: FindingCaseResponse = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponse", + "", + ) as FindingCaseResponse; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"', + ); } -} -export class SecurityMonitoringApiResponseProcessor { /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects @@ -4752,6 +5144,66 @@ export class SecurityMonitoringApiResponseProcessor { ); } + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to createCases + * @throws ApiException if the response code was not in [200, 299] + */ + public async createCases( + response: ResponseContext, + ): Promise { + const contentType = normalizeMediaType(response.headers["content-type"]); + if (response.httpStatusCode === 201) { + const body: FindingCaseResponseArray = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponseArray", + ) as FindingCaseResponseArray; + return body; + } + if ( + response.httpStatusCode === 400 || + response.httpStatusCode === 404 || + response.httpStatusCode === 429 + ) { + const bodyText = parse(await response.body.text(), contentType); + let body: APIErrorResponse; + try { + body = deserialize( + bodyText, + TypingInfo, + "APIErrorResponse", + ) as APIErrorResponse; + } catch (error) { + logger.debug(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText, + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: FindingCaseResponseArray = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponseArray", + "", + ) as FindingCaseResponseArray; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"', + ); + } + /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects @@ -4813,6 +5265,66 @@ export class SecurityMonitoringApiResponseProcessor { ); } + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to createJiraIssues + * @throws ApiException if the response code was not in [200, 299] + */ + public async createJiraIssues( + response: ResponseContext, + ): Promise { + const contentType = normalizeMediaType(response.headers["content-type"]); + if (response.httpStatusCode === 201) { + const body: FindingCaseResponseArray = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponseArray", + ) as FindingCaseResponseArray; + return body; + } + if ( + response.httpStatusCode === 400 || + response.httpStatusCode === 404 || + response.httpStatusCode === 429 + ) { + const bodyText = parse(await response.body.text(), contentType); + let body: APIErrorResponse; + try { + body = deserialize( + bodyText, + TypingInfo, + "APIErrorResponse", + ) as APIErrorResponse; + } catch (error) { + logger.debug(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText, + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: FindingCaseResponseArray = deserialize( + parse(await response.body.text(), contentType), + TypingInfo, + "FindingCaseResponseArray", + "", + ) as FindingCaseResponseArray; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"', + ); + } + /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects @@ -5470,6 +5982,53 @@ export class SecurityMonitoringApiResponseProcessor { ); } + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to detachCase + * @throws ApiException if the response code was not in [200, 299] + */ + public async detachCase(response: ResponseContext): Promise { + const contentType = normalizeMediaType(response.headers["content-type"]); + if (response.httpStatusCode === 204) { + return; + } + if ( + response.httpStatusCode === 400 || + response.httpStatusCode === 404 || + response.httpStatusCode === 429 + ) { + const bodyText = parse(await response.body.text(), contentType); + let body: APIErrorResponse; + try { + body = deserialize( + bodyText, + TypingInfo, + "APIErrorResponse", + ) as APIErrorResponse; + } catch (error) { + logger.debug(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText, + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + return; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"', + ); + } + /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects @@ -8536,6 +9095,25 @@ export class SecurityMonitoringApiResponseProcessor { } } +export interface SecurityMonitoringApiAttachCaseRequest { + /** + * The unique identifier of the case to attach security findings to + * @type string + */ + caseId: string; + /** + * @type AttachCaseRequest + */ + body: AttachCaseRequest; +} + +export interface SecurityMonitoringApiAttachJiraIssueRequest { + /** + * @type AttachJiraIssueRequest + */ + body: AttachJiraIssueRequest; +} + export interface SecurityMonitoringApiCancelThreatHuntingJobRequest { /** * The ID of the job. @@ -8566,6 +9144,13 @@ export interface SecurityMonitoringApiConvertSecurityMonitoringRuleFromJSONToTer body: SecurityMonitoringRuleConvertPayload; } +export interface SecurityMonitoringApiCreateCasesRequest { + /** + * @type CreateCaseRequestArray + */ + body: CreateCaseRequestArray; +} + export interface SecurityMonitoringApiCreateCustomFrameworkRequest { /** * @type CreateCustomFrameworkRequest @@ -8573,6 +9158,13 @@ export interface SecurityMonitoringApiCreateCustomFrameworkRequest { body: CreateCustomFrameworkRequest; } +export interface SecurityMonitoringApiCreateJiraIssuesRequest { + /** + * @type CreateJiraIssueRequestArray + */ + body: CreateJiraIssueRequestArray; +} + export interface SecurityMonitoringApiCreateSecurityFilterRequest { /** * The definition of the new security filter. @@ -8675,6 +9267,13 @@ export interface SecurityMonitoringApiDeleteVulnerabilityNotificationRuleRequest id: string; } +export interface SecurityMonitoringApiDetachCaseRequest { + /** + * @type DetachCaseRequest + */ + body: DetachCaseRequest; +} + export interface SecurityMonitoringApiEditSecurityMonitoringSignalAssigneeRequest { /** * The ID of the signal. @@ -9665,6 +10264,49 @@ export class SecurityMonitoringApi { responseProcessor || new SecurityMonitoringApiResponseProcessor(); } + /** + * Attach security findings to a case. You can attach up to 50 security findings per case. Security findings that are already attached to another case will be detached from their previous case and attached to the specified case. + * @param param The request object + */ + public attachCase( + param: SecurityMonitoringApiAttachCaseRequest, + options?: Configuration, + ): Promise { + const requestContextPromise = this.requestFactory.attachCase( + param.caseId, + param.body, + options, + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.attachCase(responseContext); + }); + }); + } + + /** + * Attach security findings to a Jira issue by providing the Jira issue URL. You can attach up to 50 security findings per Jira issue. If the Jira issue is not linked to any case, this operation will create a case for the security findings and link the Jira issue to the newly created case. Security findings that are already attached to another Jira issue will be detached from their previous Jira issue and attached to the specified Jira issue. + * @param param The request object + */ + public attachJiraIssue( + param: SecurityMonitoringApiAttachJiraIssueRequest, + options?: Configuration, + ): Promise { + const requestContextPromise = this.requestFactory.attachJiraIssue( + param.body, + options, + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.attachJiraIssue(responseContext); + }); + }); + } + /** * Cancel a threat hunting job. * @param param The request object @@ -9769,6 +10411,27 @@ export class SecurityMonitoringApi { }); } + /** + * Create cases for security findings. You can create up to 50 cases per request and associate up to 50 security findings per case. Security findings that are already attached to another case will be detached from their previous case and attached to the newly created case. + * @param param The request object + */ + public createCases( + param: SecurityMonitoringApiCreateCasesRequest, + options?: Configuration, + ): Promise { + const requestContextPromise = this.requestFactory.createCases( + param.body, + options, + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.createCases(responseContext); + }); + }); + } + /** * Create a custom framework. * @param param The request object @@ -9790,6 +10453,27 @@ export class SecurityMonitoringApi { }); } + /** + * Create Jira issues for security findings. This operation creates a case in Datadog and a Jira issue linked to that case for bidirectional sync between Datadog and Jira. You can create up to 50 Jira issues per request and associate up to 50 security findings per Jira issue. Security findings that are already attached to another Jira issue will be detached from their previous Jira issue and attached to the newly created Jira issue. + * @param param The request object + */ + public createJiraIssues( + param: SecurityMonitoringApiCreateJiraIssuesRequest, + options?: Configuration, + ): Promise { + const requestContextPromise = this.requestFactory.createJiraIssues( + param.body, + options, + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.createJiraIssues(responseContext); + }); + }); + } + /** * Create a security filter. * @@ -10058,6 +10742,27 @@ export class SecurityMonitoringApi { }); } + /** + * Detach security findings from their case. This operation dissociates security findings from their associated cases without deleting the cases themselves. You can detach security findings from multiple different cases in a single request, with a limit of 50 security findings per request. Security findings that are not currently attached to any case will be ignored. + * @param param The request object + */ + public detachCase( + param: SecurityMonitoringApiDetachCaseRequest, + options?: Configuration, + ): Promise { + const requestContextPromise = this.requestFactory.detachCase( + param.body, + options, + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.detachCase(responseContext); + }); + }); + } + /** * Modify the triage assignee of a security signal. * @param param The request object diff --git a/services/security_monitoring/src/v2/index.ts b/services/security_monitoring/src/v2/index.ts index 02b7c5eb25c3..0420ab5ea08a 100644 --- a/services/security_monitoring/src/v2/index.ts +++ b/services/security_monitoring/src/v2/index.ts @@ -1,9 +1,13 @@ export { + SecurityMonitoringApiAttachCaseRequest, + SecurityMonitoringApiAttachJiraIssueRequest, SecurityMonitoringApiCancelThreatHuntingJobRequest, SecurityMonitoringApiConvertExistingSecurityMonitoringRuleRequest, SecurityMonitoringApiConvertJobResultToSignalRequest, SecurityMonitoringApiConvertSecurityMonitoringRuleFromJSONToTerraformRequest, + SecurityMonitoringApiCreateCasesRequest, SecurityMonitoringApiCreateCustomFrameworkRequest, + SecurityMonitoringApiCreateJiraIssuesRequest, SecurityMonitoringApiCreateSecurityFilterRequest, SecurityMonitoringApiCreateSecurityMonitoringRuleRequest, SecurityMonitoringApiCreateSecurityMonitoringSuppressionRequest, @@ -16,6 +20,7 @@ export { SecurityMonitoringApiDeleteSignalNotificationRuleRequest, SecurityMonitoringApiDeleteThreatHuntingJobRequest, SecurityMonitoringApiDeleteVulnerabilityNotificationRuleRequest, + SecurityMonitoringApiDetachCaseRequest, SecurityMonitoringApiEditSecurityMonitoringSignalAssigneeRequest, SecurityMonitoringApiEditSecurityMonitoringSignalIncidentsRequest, SecurityMonitoringApiEditSecurityMonitoringSignalStateRequest, @@ -73,6 +78,13 @@ export { AssetOperatingSystem } from "./models/AssetOperatingSystem"; export { AssetRisks } from "./models/AssetRisks"; export { AssetType } from "./models/AssetType"; export { AssetVersion } from "./models/AssetVersion"; +export { AttachCaseRequest } from "./models/AttachCaseRequest"; +export { AttachCaseRequestData } from "./models/AttachCaseRequestData"; +export { AttachCaseRequestDataRelationships } from "./models/AttachCaseRequestDataRelationships"; +export { AttachJiraIssueRequest } from "./models/AttachJiraIssueRequest"; +export { AttachJiraIssueRequestData } from "./models/AttachJiraIssueRequestData"; +export { AttachJiraIssueRequestDataAttributes } from "./models/AttachJiraIssueRequestDataAttributes"; +export { AttachJiraIssueRequestDataRelationships } from "./models/AttachJiraIssueRequestDataRelationships"; export { BulkMuteFindingsRequest } from "./models/BulkMuteFindingsRequest"; export { BulkMuteFindingsRequestAttributes } from "./models/BulkMuteFindingsRequestAttributes"; export { BulkMuteFindingsRequestData } from "./models/BulkMuteFindingsRequestData"; @@ -82,6 +94,12 @@ export { BulkMuteFindingsRequestProperties } from "./models/BulkMuteFindingsRequ export { BulkMuteFindingsResponse } from "./models/BulkMuteFindingsResponse"; export { BulkMuteFindingsResponseData } from "./models/BulkMuteFindingsResponseData"; export { CalculatedField } from "./models/CalculatedField"; +export { CaseDataType } from "./models/CaseDataType"; +export { CaseInsightsItems } from "./models/CaseInsightsItems"; +export { CaseManagementProject } from "./models/CaseManagementProject"; +export { CaseManagementProjectData } from "./models/CaseManagementProjectData"; +export { CaseManagementProjectDataType } from "./models/CaseManagementProjectDataType"; +export { CasePriority } from "./models/CasePriority"; export { CloudAssetType } from "./models/CloudAssetType"; export { CloudConfigurationComplianceRuleOptions } from "./models/CloudConfigurationComplianceRuleOptions"; export { CloudConfigurationRegoRule } from "./models/CloudConfigurationRegoRule"; @@ -96,8 +114,20 @@ export { ConvertJobResultsToSignalsAttributes } from "./models/ConvertJobResults export { ConvertJobResultsToSignalsData } from "./models/ConvertJobResultsToSignalsData"; export { ConvertJobResultsToSignalsDataType } from "./models/ConvertJobResultsToSignalsDataType"; export { ConvertJobResultsToSignalsRequest } from "./models/ConvertJobResultsToSignalsRequest"; +export { CreateCaseRequestArray } from "./models/CreateCaseRequestArray"; +export { CreateCaseRequestData } from "./models/CreateCaseRequestData"; +export { CreateCaseRequestDataAttributes } from "./models/CreateCaseRequestDataAttributes"; +export { CreateCaseRequestDataRelationships } from "./models/CreateCaseRequestDataRelationships"; export { CreateCustomFrameworkRequest } from "./models/CreateCustomFrameworkRequest"; export { CreateCustomFrameworkResponse } from "./models/CreateCustomFrameworkResponse"; +export { CreateJiraIssueRequestArray } from "./models/CreateJiraIssueRequestArray"; +export { CreateJiraIssueRequestArrayIncluded } from "./models/CreateJiraIssueRequestArrayIncluded"; +export { CreateJiraIssueRequestData } from "./models/CreateJiraIssueRequestData"; +export { CreateJiraIssueRequestDataAttributes } from "./models/CreateJiraIssueRequestDataAttributes"; +export { CreateJiraIssueRequestDataAttributesFields } from "./models/CreateJiraIssueRequestDataAttributesFields"; +export { CreateJiraIssueRequestDataRelationships } from "./models/CreateJiraIssueRequestDataRelationships"; +export { CreateJiraIssueRequestDataRelationshipsCase } from "./models/CreateJiraIssueRequestDataRelationshipsCase"; +export { CreateJiraIssueRequestDataRelationshipsCaseData } from "./models/CreateJiraIssueRequestDataRelationshipsCaseData"; export { CreateNotificationRuleParameters } from "./models/CreateNotificationRuleParameters"; export { CreateNotificationRuleParametersData } from "./models/CreateNotificationRuleParametersData"; export { CreateNotificationRuleParametersDataAttributes } from "./models/CreateNotificationRuleParametersDataAttributes"; @@ -112,16 +142,29 @@ export { CustomFrameworkWithoutRequirements } from "./models/CustomFrameworkWith export { CVSS } from "./models/CVSS"; export { DeleteCustomFrameworkResponse } from "./models/DeleteCustomFrameworkResponse"; export { DependencyLocation } from "./models/DependencyLocation"; +export { DetachCaseRequest } from "./models/DetachCaseRequest"; +export { DetachCaseRequestData } from "./models/DetachCaseRequestData"; +export { DetachCaseRequestDataRelationships } from "./models/DetachCaseRequestDataRelationships"; export { DetailedFinding } from "./models/DetailedFinding"; export { DetailedFindingAttributes } from "./models/DetailedFindingAttributes"; export { DetailedFindingType } from "./models/DetailedFindingType"; export { EPSS } from "./models/EPSS"; export { Finding } from "./models/Finding"; export { FindingAttributes } from "./models/FindingAttributes"; +export { FindingCaseResponse } from "./models/FindingCaseResponse"; +export { FindingCaseResponseArray } from "./models/FindingCaseResponseArray"; +export { FindingCaseResponseData } from "./models/FindingCaseResponseData"; +export { FindingCaseResponseDataAttributes } from "./models/FindingCaseResponseDataAttributes"; +export { FindingCaseResponseDataRelationships } from "./models/FindingCaseResponseDataRelationships"; +export { FindingData } from "./models/FindingData"; +export { FindingDataType } from "./models/FindingDataType"; export { FindingEvaluation } from "./models/FindingEvaluation"; +export { FindingJiraIssue } from "./models/FindingJiraIssue"; +export { FindingJiraIssueResult } from "./models/FindingJiraIssueResult"; export { FindingMute } from "./models/FindingMute"; export { FindingMuteReason } from "./models/FindingMuteReason"; export { FindingRule } from "./models/FindingRule"; +export { Findings } from "./models/Findings"; export { FindingStatus } from "./models/FindingStatus"; export { FindingType } from "./models/FindingType"; export { FindingVulnerabilityType } from "./models/FindingVulnerabilityType"; @@ -152,6 +195,7 @@ export { GetRuleVersionHistoryData } from "./models/GetRuleVersionHistoryData"; export { GetRuleVersionHistoryDataType } from "./models/GetRuleVersionHistoryDataType"; export { GetRuleVersionHistoryResponse } from "./models/GetRuleVersionHistoryResponse"; export { GetSBOMResponse } from "./models/GetSBOMResponse"; +export { JiraIssuesDataType } from "./models/JiraIssuesDataType"; export { JobCreateResponse } from "./models/JobCreateResponse"; export { JobCreateResponseData } from "./models/JobCreateResponseData"; export { JobDefinition } from "./models/JobDefinition"; @@ -178,6 +222,8 @@ export { Pagination } from "./models/Pagination"; export { PatchNotificationRuleParameters } from "./models/PatchNotificationRuleParameters"; export { PatchNotificationRuleParametersData } from "./models/PatchNotificationRuleParametersData"; export { PatchNotificationRuleParametersDataAttributes } from "./models/PatchNotificationRuleParametersDataAttributes"; +export { RelationshipToUser } from "./models/RelationshipToUser"; +export { RelationshipToUserData } from "./models/RelationshipToUserData"; export { Remediation } from "./models/Remediation"; export { ResourceFilterAttributes } from "./models/ResourceFilterAttributes"; export { ResourceFilterRequestType } from "./models/ResourceFilterRequestType"; @@ -350,6 +396,7 @@ export { UpdateResourceEvaluationFiltersRequest } from "./models/UpdateResourceE export { UpdateResourceEvaluationFiltersRequestData } from "./models/UpdateResourceEvaluationFiltersRequestData"; export { UpdateResourceEvaluationFiltersResponse } from "./models/UpdateResourceEvaluationFiltersResponse"; export { UpdateResourceEvaluationFiltersResponseData } from "./models/UpdateResourceEvaluationFiltersResponseData"; +export { UsersType } from "./models/UsersType"; export { VulnerabilitiesType } from "./models/VulnerabilitiesType"; export { Vulnerability } from "./models/Vulnerability"; export { VulnerabilityAdvisory } from "./models/VulnerabilityAdvisory"; diff --git a/services/security_monitoring/src/v2/models/AttachCaseRequest.ts b/services/security_monitoring/src/v2/models/AttachCaseRequest.ts new file mode 100644 index 000000000000..c4406b37e10e --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachCaseRequest.ts @@ -0,0 +1,46 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { AttachCaseRequestData } from "./AttachCaseRequestData"; + +/** + * Request for attaching security findings to a case. + */ +export class AttachCaseRequest { + /** + * Data of the case to attach security findings to. + */ + "data"?: AttachCaseRequestData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "AttachCaseRequestData", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachCaseRequest.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachCaseRequestData.ts b/services/security_monitoring/src/v2/models/AttachCaseRequestData.ts new file mode 100644 index 000000000000..2a216a2b3451 --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachCaseRequestData.ts @@ -0,0 +1,65 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { AttachCaseRequestDataRelationships } from "./AttachCaseRequestDataRelationships"; +import { CaseDataType } from "./CaseDataType"; + +/** + * Data of the case to attach security findings to. + */ +export class AttachCaseRequestData { + /** + * The unique identifier of the case. + */ + "id": string; + /** + * Relationships of the case to attach security findings to. + */ + "relationships"?: AttachCaseRequestDataRelationships; + /** + * Cases resource type. + */ + "type": CaseDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + required: true, + }, + relationships: { + baseName: "relationships", + type: "AttachCaseRequestDataRelationships", + }, + type: { + baseName: "type", + type: "CaseDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachCaseRequestData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachCaseRequestDataRelationships.ts b/services/security_monitoring/src/v2/models/AttachCaseRequestDataRelationships.ts new file mode 100644 index 000000000000..d84cc364a80c --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachCaseRequestDataRelationships.ts @@ -0,0 +1,47 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { Findings } from "./Findings"; + +/** + * Relationships of the case to attach security findings to. + */ +export class AttachCaseRequestDataRelationships { + /** + * A list of security findings. + */ + "findings": Findings; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + findings: { + baseName: "findings", + type: "Findings", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachCaseRequestDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachJiraIssueRequest.ts b/services/security_monitoring/src/v2/models/AttachJiraIssueRequest.ts new file mode 100644 index 000000000000..3405af2c7543 --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachJiraIssueRequest.ts @@ -0,0 +1,46 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { AttachJiraIssueRequestData } from "./AttachJiraIssueRequestData"; + +/** + * Request for attaching security findings to a Jira issue. + */ +export class AttachJiraIssueRequest { + /** + * Data of the Jira issue to attach security findings to. + */ + "data"?: AttachJiraIssueRequestData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "AttachJiraIssueRequestData", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachJiraIssueRequest.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachJiraIssueRequestData.ts b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestData.ts new file mode 100644 index 000000000000..3d3b68c5aedb --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestData.ts @@ -0,0 +1,73 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { AttachJiraIssueRequestDataAttributes } from "./AttachJiraIssueRequestDataAttributes"; +import { AttachJiraIssueRequestDataRelationships } from "./AttachJiraIssueRequestDataRelationships"; +import { JiraIssuesDataType } from "./JiraIssuesDataType"; + +/** + * Data of the Jira issue to attach security findings to. + */ +export class AttachJiraIssueRequestData { + /** + * Attributes of the Jira issue to attach security findings to. + */ + "attributes"?: AttachJiraIssueRequestDataAttributes; + /** + * The unique identifier of the Jira issue attachment request. + */ + "id"?: string; + /** + * Relationships of the Jira issue to attach security findings to. + */ + "relationships"?: AttachJiraIssueRequestDataRelationships; + /** + * Jira issues resource type. + */ + "type": JiraIssuesDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + attributes: { + baseName: "attributes", + type: "AttachJiraIssueRequestDataAttributes", + }, + id: { + baseName: "id", + type: "string", + }, + relationships: { + baseName: "relationships", + type: "AttachJiraIssueRequestDataRelationships", + }, + type: { + baseName: "type", + type: "JiraIssuesDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachJiraIssueRequestData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataAttributes.ts b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataAttributes.ts new file mode 100644 index 000000000000..4269ef57d0aa --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataAttributes.ts @@ -0,0 +1,45 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +/** + * Attributes of the Jira issue to attach security findings to. + */ +export class AttachJiraIssueRequestDataAttributes { + /** + * The URL of the Jira issue to attach security findings to. + */ + "jiraIssueUrl": string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + jiraIssueUrl: { + baseName: "jira_issue_url", + type: "string", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachJiraIssueRequestDataAttributes.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataRelationships.ts b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataRelationships.ts new file mode 100644 index 000000000000..05069f9a330e --- /dev/null +++ b/services/security_monitoring/src/v2/models/AttachJiraIssueRequestDataRelationships.ts @@ -0,0 +1,57 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseManagementProject } from "./CaseManagementProject"; +import { Findings } from "./Findings"; + +/** + * Relationships of the Jira issue to attach security findings to. + */ +export class AttachJiraIssueRequestDataRelationships { + /** + * A list of security findings. + */ + "findings": Findings; + /** + * Case management project. + */ + "project": CaseManagementProject; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + findings: { + baseName: "findings", + type: "Findings", + required: true, + }, + project: { + baseName: "project", + type: "CaseManagementProject", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return AttachJiraIssueRequestDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CaseDataType.ts b/services/security_monitoring/src/v2/models/CaseDataType.ts new file mode 100644 index 000000000000..b281282dda4e --- /dev/null +++ b/services/security_monitoring/src/v2/models/CaseDataType.ts @@ -0,0 +1,7 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Cases resource type. + */ +export type CaseDataType = typeof CASES | UnparsedObject; +export const CASES = "cases"; diff --git a/services/security_monitoring/src/v2/models/CaseInsightsItems.ts b/services/security_monitoring/src/v2/models/CaseInsightsItems.ts new file mode 100644 index 000000000000..d4bd44a74fd8 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CaseInsightsItems.ts @@ -0,0 +1,60 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +/** + * An insight of the case. + */ +export class CaseInsightsItems { + /** + * The reference of the insight. + */ + "ref"?: string; + /** + * The unique identifier of the resource. For example, the unique identifier of a security finding. + */ + "resourceId"?: string; + /** + * The type of the resource. For example, the type of a security finding is "SECURITY_FINDING". + */ + "type"?: string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + ref: { + baseName: "ref", + type: "string", + }, + resourceId: { + baseName: "resource_id", + type: "string", + }, + type: { + baseName: "type", + type: "string", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CaseInsightsItems.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CaseManagementProject.ts b/services/security_monitoring/src/v2/models/CaseManagementProject.ts new file mode 100644 index 000000000000..40d9b6cfb735 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CaseManagementProject.ts @@ -0,0 +1,44 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseManagementProjectData } from "./CaseManagementProjectData"; + +/** + * Case management project. + */ +export class CaseManagementProject { + "data": CaseManagementProjectData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "CaseManagementProjectData", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CaseManagementProject.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CaseManagementProjectData.ts b/services/security_monitoring/src/v2/models/CaseManagementProjectData.ts new file mode 100644 index 000000000000..91cec0677844 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CaseManagementProjectData.ts @@ -0,0 +1,53 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseManagementProjectDataType } from "./CaseManagementProjectDataType"; + +export class CaseManagementProjectData { + /** + * The unique identifier of the case management project. + */ + "id": string; + /** + * Projects resource type. + */ + "type": CaseManagementProjectDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "CaseManagementProjectDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CaseManagementProjectData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CaseManagementProjectDataType.ts b/services/security_monitoring/src/v2/models/CaseManagementProjectDataType.ts new file mode 100644 index 000000000000..1c116aa2c4c9 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CaseManagementProjectDataType.ts @@ -0,0 +1,7 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Projects resource type. + */ +export type CaseManagementProjectDataType = typeof PROJECTS | UnparsedObject; +export const PROJECTS = "projects"; diff --git a/services/security_monitoring/src/v2/models/CasePriority.ts b/services/security_monitoring/src/v2/models/CasePriority.ts new file mode 100644 index 000000000000..92beb2f7f63b --- /dev/null +++ b/services/security_monitoring/src/v2/models/CasePriority.ts @@ -0,0 +1,19 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Case priority + */ +export type CasePriority = + | typeof NOT_DEFINED + | typeof P1 + | typeof P2 + | typeof P3 + | typeof P4 + | typeof P5 + | UnparsedObject; +export const NOT_DEFINED = "NOT_DEFINED"; +export const P1 = "P1"; +export const P2 = "P2"; +export const P3 = "P3"; +export const P4 = "P4"; +export const P5 = "P5"; diff --git a/services/security_monitoring/src/v2/models/CreateCaseRequestArray.ts b/services/security_monitoring/src/v2/models/CreateCaseRequestArray.ts new file mode 100644 index 000000000000..faa116057b17 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateCaseRequestArray.ts @@ -0,0 +1,44 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateCaseRequestData } from "./CreateCaseRequestData"; + +/** + * List of requests to create cases for security findings. + */ +export class CreateCaseRequestArray { + "data": Array; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateCaseRequestArray.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateCaseRequestData.ts b/services/security_monitoring/src/v2/models/CreateCaseRequestData.ts new file mode 100644 index 000000000000..b0053f6f95c2 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateCaseRequestData.ts @@ -0,0 +1,73 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseDataType } from "./CaseDataType"; +import { CreateCaseRequestDataAttributes } from "./CreateCaseRequestDataAttributes"; +import { CreateCaseRequestDataRelationships } from "./CreateCaseRequestDataRelationships"; + +/** + * Data of the case to create. + */ +export class CreateCaseRequestData { + /** + * Attributes of the case to create. + */ + "attributes"?: CreateCaseRequestDataAttributes; + /** + * The unique identifier of the case. + */ + "id"?: string; + /** + * Relationships of the case to create. + */ + "relationships"?: CreateCaseRequestDataRelationships; + /** + * Cases resource type. + */ + "type": CaseDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + attributes: { + baseName: "attributes", + type: "CreateCaseRequestDataAttributes", + }, + id: { + baseName: "id", + type: "string", + }, + relationships: { + baseName: "relationships", + type: "CreateCaseRequestDataRelationships", + }, + type: { + baseName: "type", + type: "CaseDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateCaseRequestData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateCaseRequestDataAttributes.ts b/services/security_monitoring/src/v2/models/CreateCaseRequestDataAttributes.ts new file mode 100644 index 000000000000..f5de2f0770f4 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateCaseRequestDataAttributes.ts @@ -0,0 +1,70 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CasePriority } from "./CasePriority"; + +/** + * Attributes of the case to create. + */ +export class CreateCaseRequestDataAttributes { + /** + * The unique identifier of the user assigned to the case. + */ + "assigneeId"?: string; + /** + * The description of the case. If not provided, the description will be automatically generated. + */ + "description"?: string; + /** + * Case priority + */ + "priority"?: CasePriority; + /** + * The title of the case. If not provided, the title will be automatically generated. + */ + "title"?: string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + assigneeId: { + baseName: "assignee_id", + type: "string", + }, + description: { + baseName: "description", + type: "string", + }, + priority: { + baseName: "priority", + type: "CasePriority", + }, + title: { + baseName: "title", + type: "string", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateCaseRequestDataAttributes.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateCaseRequestDataRelationships.ts b/services/security_monitoring/src/v2/models/CreateCaseRequestDataRelationships.ts new file mode 100644 index 000000000000..1c334b57dff6 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateCaseRequestDataRelationships.ts @@ -0,0 +1,57 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseManagementProject } from "./CaseManagementProject"; +import { Findings } from "./Findings"; + +/** + * Relationships of the case to create. + */ +export class CreateCaseRequestDataRelationships { + /** + * A list of security findings. + */ + "findings": Findings; + /** + * Case management project. + */ + "project": CaseManagementProject; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + findings: { + baseName: "findings", + type: "Findings", + required: true, + }, + project: { + baseName: "project", + type: "CaseManagementProject", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateCaseRequestDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArray.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArray.ts new file mode 100644 index 000000000000..0a0c584b77c0 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArray.ts @@ -0,0 +1,50 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateJiraIssueRequestArrayIncluded } from "./CreateJiraIssueRequestArrayIncluded"; +import { CreateJiraIssueRequestData } from "./CreateJiraIssueRequestData"; + +/** + * List of requests to create Jira issues for security findings. + */ +export class CreateJiraIssueRequestArray { + "data": Array; + "included"?: Array; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + required: true, + }, + included: { + baseName: "included", + type: "Array", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestArray.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArrayIncluded.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArrayIncluded.ts new file mode 100644 index 000000000000..484f8fcbd4f8 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestArrayIncluded.ts @@ -0,0 +1,14 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +import { CaseManagementProjectData } from "./CaseManagementProjectData"; +import { CreateCaseRequestData } from "./CreateCaseRequestData"; +import { FindingData } from "./FindingData"; + +/** + * Attributes and relationships of the case linked to the Jira issue. Should contain all of the following: case, project, and security findings. + */ +export type CreateJiraIssueRequestArrayIncluded = + | CreateCaseRequestData + | CaseManagementProjectData + | FindingData + | UnparsedObject; diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestData.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestData.ts new file mode 100644 index 000000000000..e709febd0405 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestData.ts @@ -0,0 +1,73 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateJiraIssueRequestDataAttributes } from "./CreateJiraIssueRequestDataAttributes"; +import { CreateJiraIssueRequestDataRelationships } from "./CreateJiraIssueRequestDataRelationships"; +import { JiraIssuesDataType } from "./JiraIssuesDataType"; + +/** + * Data of the Jira issue to create. + */ +export class CreateJiraIssueRequestData { + /** + * Attributes of the Jira issue to create. + */ + "attributes"?: CreateJiraIssueRequestDataAttributes; + /** + * The unique identifier of the Jira issue creation request. + */ + "id"?: string; + /** + * Relationships of the Jira issue to create. + */ + "relationships"?: CreateJiraIssueRequestDataRelationships; + /** + * Jira issues resource type. + */ + "type": JiraIssuesDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + attributes: { + baseName: "attributes", + type: "CreateJiraIssueRequestDataAttributes", + }, + id: { + baseName: "id", + type: "string", + }, + relationships: { + baseName: "relationships", + type: "CreateJiraIssueRequestDataRelationships", + }, + type: { + baseName: "type", + type: "JiraIssuesDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributes.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributes.ts new file mode 100644 index 000000000000..2955c87beeb0 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributes.ts @@ -0,0 +1,46 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateJiraIssueRequestDataAttributesFields } from "./CreateJiraIssueRequestDataAttributesFields"; + +/** + * Attributes of the Jira issue to create. + */ +export class CreateJiraIssueRequestDataAttributes { + /** + * Custom fields of the Jira issue to create. For the list of available fields, see [Jira documentation](https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-createmeta-projectidorkey-issuetypes-issuetypeid-get). + */ + "fields"?: CreateJiraIssueRequestDataAttributesFields; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + fields: { + baseName: "fields", + type: "CreateJiraIssueRequestDataAttributesFields", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestDataAttributes.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributesFields.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributesFields.ts new file mode 100644 index 000000000000..7c70fa8b10f8 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataAttributesFields.ts @@ -0,0 +1,41 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +/** + * Custom fields of the Jira issue to create. For the list of available fields, see [Jira documentation](https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-createmeta-projectidorkey-issuetypes-issuetypeid-get). + */ +export class CreateJiraIssueRequestDataAttributesFields { + "fields"?: any; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + fields: { + baseName: "fields", + type: "any", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestDataAttributesFields.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationships.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationships.ts new file mode 100644 index 000000000000..34aea86d5bac --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationships.ts @@ -0,0 +1,47 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateJiraIssueRequestDataRelationshipsCase } from "./CreateJiraIssueRequestDataRelationshipsCase"; + +/** + * Relationships of the Jira issue to create. + */ +export class CreateJiraIssueRequestDataRelationships { + /** + * Case linked to the Jira issue. + */ + "_case": CreateJiraIssueRequestDataRelationshipsCase; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + _case: { + baseName: "case", + type: "CreateJiraIssueRequestDataRelationshipsCase", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCase.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCase.ts new file mode 100644 index 000000000000..3af0b36d84b1 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCase.ts @@ -0,0 +1,47 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CreateJiraIssueRequestDataRelationshipsCaseData } from "./CreateJiraIssueRequestDataRelationshipsCaseData"; + +/** + * Case linked to the Jira issue. + */ +export class CreateJiraIssueRequestDataRelationshipsCase { + /** + * Case linked to the Jira issue. + */ + "data": CreateJiraIssueRequestDataRelationshipsCaseData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "CreateJiraIssueRequestDataRelationshipsCaseData", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestDataRelationshipsCase.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCaseData.ts b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCaseData.ts new file mode 100644 index 000000000000..e05ce8639bf4 --- /dev/null +++ b/services/security_monitoring/src/v2/models/CreateJiraIssueRequestDataRelationshipsCaseData.ts @@ -0,0 +1,53 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseDataType } from "./CaseDataType"; + +/** + * Case linked to the Jira issue. + */ +export class CreateJiraIssueRequestDataRelationshipsCaseData { + "id": string; + /** + * Cases resource type. + */ + "type": CaseDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "CaseDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return CreateJiraIssueRequestDataRelationshipsCaseData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/DetachCaseRequest.ts b/services/security_monitoring/src/v2/models/DetachCaseRequest.ts new file mode 100644 index 000000000000..011b5898ec36 --- /dev/null +++ b/services/security_monitoring/src/v2/models/DetachCaseRequest.ts @@ -0,0 +1,46 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { DetachCaseRequestData } from "./DetachCaseRequestData"; + +/** + * Request for detaching security findings from their case. + */ +export class DetachCaseRequest { + /** + * Data for detaching security findings from their case. + */ + "data"?: DetachCaseRequestData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "DetachCaseRequestData", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return DetachCaseRequest.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/DetachCaseRequestData.ts b/services/security_monitoring/src/v2/models/DetachCaseRequestData.ts new file mode 100644 index 000000000000..a34cbc1fed51 --- /dev/null +++ b/services/security_monitoring/src/v2/models/DetachCaseRequestData.ts @@ -0,0 +1,64 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseDataType } from "./CaseDataType"; +import { DetachCaseRequestDataRelationships } from "./DetachCaseRequestDataRelationships"; + +/** + * Data for detaching security findings from their case. + */ +export class DetachCaseRequestData { + /** + * The unique identifier of the detachment request. + */ + "id"?: string; + /** + * Relationships detaching security findings from their case. + */ + "relationships"?: DetachCaseRequestDataRelationships; + /** + * Cases resource type. + */ + "type": CaseDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + }, + relationships: { + baseName: "relationships", + type: "DetachCaseRequestDataRelationships", + }, + type: { + baseName: "type", + type: "CaseDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return DetachCaseRequestData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/DetachCaseRequestDataRelationships.ts b/services/security_monitoring/src/v2/models/DetachCaseRequestDataRelationships.ts new file mode 100644 index 000000000000..e67682554fa1 --- /dev/null +++ b/services/security_monitoring/src/v2/models/DetachCaseRequestDataRelationships.ts @@ -0,0 +1,47 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { Findings } from "./Findings"; + +/** + * Relationships detaching security findings from their case. + */ +export class DetachCaseRequestDataRelationships { + /** + * A list of security findings. + */ + "findings": Findings; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + findings: { + baseName: "findings", + type: "Findings", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return DetachCaseRequestDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingCaseResponse.ts b/services/security_monitoring/src/v2/models/FindingCaseResponse.ts new file mode 100644 index 000000000000..7dea8c45c12a --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingCaseResponse.ts @@ -0,0 +1,46 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { FindingCaseResponseData } from "./FindingCaseResponseData"; + +/** + * Case response. + */ +export class FindingCaseResponse { + /** + * Data of the case. + */ + "data"?: FindingCaseResponseData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "FindingCaseResponseData", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingCaseResponse.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingCaseResponseArray.ts b/services/security_monitoring/src/v2/models/FindingCaseResponseArray.ts new file mode 100644 index 000000000000..d14e2d660601 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingCaseResponseArray.ts @@ -0,0 +1,44 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { FindingCaseResponseData } from "./FindingCaseResponseData"; + +/** + * List of case responses. + */ +export class FindingCaseResponseArray { + "data": Array; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingCaseResponseArray.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingCaseResponseData.ts b/services/security_monitoring/src/v2/models/FindingCaseResponseData.ts new file mode 100644 index 000000000000..744843e211e4 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingCaseResponseData.ts @@ -0,0 +1,73 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseDataType } from "./CaseDataType"; +import { FindingCaseResponseDataAttributes } from "./FindingCaseResponseDataAttributes"; +import { FindingCaseResponseDataRelationships } from "./FindingCaseResponseDataRelationships"; + +/** + * Data of the case. + */ +export class FindingCaseResponseData { + /** + * Attributes of the case. + */ + "attributes"?: FindingCaseResponseDataAttributes; + /** + * The unique identifier of the case. + */ + "id"?: string; + /** + * Relationships of the case. + */ + "relationships"?: FindingCaseResponseDataRelationships; + /** + * Cases resource type. + */ + "type": CaseDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + attributes: { + baseName: "attributes", + type: "FindingCaseResponseDataAttributes", + }, + id: { + baseName: "id", + type: "string", + }, + relationships: { + baseName: "relationships", + type: "FindingCaseResponseDataRelationships", + }, + type: { + baseName: "type", + type: "CaseDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingCaseResponseData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingCaseResponseDataAttributes.ts b/services/security_monitoring/src/v2/models/FindingCaseResponseDataAttributes.ts new file mode 100644 index 000000000000..043b5df22d99 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingCaseResponseDataAttributes.ts @@ -0,0 +1,185 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseInsightsItems } from "./CaseInsightsItems"; +import { FindingJiraIssue } from "./FindingJiraIssue"; +import { RelationshipToUser } from "./RelationshipToUser"; + +/** + * Attributes of the case. + */ +export class FindingCaseResponseDataAttributes { + /** + * Timestamp of when the case was archived. + */ + "archivedAt"?: Date; + /** + * Relationship to user. + */ + "assignedTo"?: RelationshipToUser; + "attributes"?: { [key: string]: Array }; + /** + * Timestamp of when the case was closed. + */ + "closedAt"?: Date; + /** + * Timestamp of when the case was created. + */ + "createdAt"?: Date; + /** + * Source of the case creation. + */ + "creationSource"?: string; + /** + * Description of the case. + */ + "description"?: string; + /** + * Due date of the case. + */ + "dueDate"?: string; + /** + * Insights of the case. + */ + "insights"?: Array; + /** + * Jira issue associated with the case. + */ + "jiraIssue"?: FindingJiraIssue; + /** + * Key of the case. + */ + "key"?: string; + /** + * Timestamp of when the case was last modified. + */ + "modifiedAt"?: Date; + /** + * Priority of the case. + */ + "priority"?: string; + /** + * Status of the case. + */ + "status"?: string; + /** + * Status group of the case. + */ + "statusGroup"?: string; + /** + * Status name of the case. + */ + "statusName"?: string; + /** + * Title of the case. + */ + "title"?: string; + /** + * Type of the case. For security cases, this is always "SECURITY". + */ + "type"?: string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + archivedAt: { + baseName: "archived_at", + type: "Date", + format: "date-time", + }, + assignedTo: { + baseName: "assigned_to", + type: "RelationshipToUser", + }, + attributes: { + baseName: "attributes", + type: "{ [key: string]: Array; }", + }, + closedAt: { + baseName: "closed_at", + type: "Date", + format: "date-time", + }, + createdAt: { + baseName: "created_at", + type: "Date", + format: "date-time", + }, + creationSource: { + baseName: "creation_source", + type: "string", + }, + description: { + baseName: "description", + type: "string", + }, + dueDate: { + baseName: "due_date", + type: "string", + }, + insights: { + baseName: "insights", + type: "Array", + }, + jiraIssue: { + baseName: "jira_issue", + type: "FindingJiraIssue", + }, + key: { + baseName: "key", + type: "string", + }, + modifiedAt: { + baseName: "modified_at", + type: "Date", + format: "date-time", + }, + priority: { + baseName: "priority", + type: "string", + }, + status: { + baseName: "status", + type: "string", + }, + statusGroup: { + baseName: "status_group", + type: "string", + }, + statusName: { + baseName: "status_name", + type: "string", + }, + title: { + baseName: "title", + type: "string", + }, + type: { + baseName: "type", + type: "string", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingCaseResponseDataAttributes.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingCaseResponseDataRelationships.ts b/services/security_monitoring/src/v2/models/FindingCaseResponseDataRelationships.ts new file mode 100644 index 000000000000..2ed989452c9d --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingCaseResponseDataRelationships.ts @@ -0,0 +1,63 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { CaseManagementProject } from "./CaseManagementProject"; +import { RelationshipToUser } from "./RelationshipToUser"; + +/** + * Relationships of the case. + */ +export class FindingCaseResponseDataRelationships { + /** + * Relationship to user. + */ + "createdBy"?: RelationshipToUser; + /** + * Relationship to user. + */ + "modifiedBy"?: RelationshipToUser; + /** + * Case management project. + */ + "project"?: CaseManagementProject; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + createdBy: { + baseName: "created_by", + type: "RelationshipToUser", + }, + modifiedBy: { + baseName: "modified_by", + type: "RelationshipToUser", + }, + project: { + baseName: "project", + type: "CaseManagementProject", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingCaseResponseDataRelationships.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingData.ts b/services/security_monitoring/src/v2/models/FindingData.ts new file mode 100644 index 000000000000..2550e18e4148 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingData.ts @@ -0,0 +1,53 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { FindingDataType } from "./FindingDataType"; + +export class FindingData { + /** + * The unique identifier of the security finding. + */ + "id": string; + /** + * Security findings resource type. + */ + "type": FindingDataType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "FindingDataType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingDataType.ts b/services/security_monitoring/src/v2/models/FindingDataType.ts new file mode 100644 index 000000000000..a1103821d612 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingDataType.ts @@ -0,0 +1,7 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Security findings resource type. + */ +export type FindingDataType = typeof FINDINGS | UnparsedObject; +export const FINDINGS = "findings"; diff --git a/services/security_monitoring/src/v2/models/FindingJiraIssue.ts b/services/security_monitoring/src/v2/models/FindingJiraIssue.ts new file mode 100644 index 000000000000..7ec4571064ad --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingJiraIssue.ts @@ -0,0 +1,62 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { FindingJiraIssueResult } from "./FindingJiraIssueResult"; + +/** + * Jira issue associated with the case. + */ +export class FindingJiraIssue { + /** + * The error message if the Jira issue creation failed. + */ + "errorMessage"?: string; + /** + * Result of the Jira issue creation. + */ + "result"?: FindingJiraIssueResult; + /** + * The status of the Jira issue creation. Can be "COMPLETED" if the Jira issue was created successfully, or "FAILED" if the Jira issue creation failed. + */ + "status"?: string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + errorMessage: { + baseName: "error_message", + type: "string", + }, + result: { + baseName: "result", + type: "FindingJiraIssueResult", + }, + status: { + baseName: "status", + type: "string", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingJiraIssue.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/FindingJiraIssueResult.ts b/services/security_monitoring/src/v2/models/FindingJiraIssueResult.ts new file mode 100644 index 000000000000..74e7db609538 --- /dev/null +++ b/services/security_monitoring/src/v2/models/FindingJiraIssueResult.ts @@ -0,0 +1,68 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +/** + * Result of the Jira issue creation. + */ +export class FindingJiraIssueResult { + /** + * The account ID of the Jira issue. + */ + "accountId"?: string; + /** + * The unique identifier of the Jira issue. + */ + "issueId"?: string; + /** + * The key of the Jira issue. + */ + "issueKey"?: string; + /** + * The URL of the Jira issue. + */ + "issueUrl"?: string; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + accountId: { + baseName: "account_id", + type: "string", + }, + issueId: { + baseName: "issue_id", + type: "string", + }, + issueKey: { + baseName: "issue_key", + type: "string", + }, + issueUrl: { + baseName: "issue_url", + type: "string", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return FindingJiraIssueResult.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/Findings.ts b/services/security_monitoring/src/v2/models/Findings.ts new file mode 100644 index 000000000000..dd671e7d61e7 --- /dev/null +++ b/services/security_monitoring/src/v2/models/Findings.ts @@ -0,0 +1,43 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { FindingData } from "./FindingData"; + +/** + * A list of security findings. + */ +export class Findings { + "data"?: Array; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return Findings.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/JiraIssuesDataType.ts b/services/security_monitoring/src/v2/models/JiraIssuesDataType.ts new file mode 100644 index 000000000000..aa6f57168c31 --- /dev/null +++ b/services/security_monitoring/src/v2/models/JiraIssuesDataType.ts @@ -0,0 +1,7 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Jira issues resource type. + */ +export type JiraIssuesDataType = typeof JIRA_ISSUES | UnparsedObject; +export const JIRA_ISSUES = "jira_issues"; diff --git a/services/security_monitoring/src/v2/models/RelationshipToUser.ts b/services/security_monitoring/src/v2/models/RelationshipToUser.ts new file mode 100644 index 000000000000..4b6f0b80952f --- /dev/null +++ b/services/security_monitoring/src/v2/models/RelationshipToUser.ts @@ -0,0 +1,47 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { RelationshipToUserData } from "./RelationshipToUserData"; + +/** + * Relationship to user. + */ +export class RelationshipToUser { + /** + * Relationship to user object. + */ + "data": RelationshipToUserData; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "RelationshipToUserData", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return RelationshipToUser.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/RelationshipToUserData.ts b/services/security_monitoring/src/v2/models/RelationshipToUserData.ts new file mode 100644 index 000000000000..8bf7fb3eccd1 --- /dev/null +++ b/services/security_monitoring/src/v2/models/RelationshipToUserData.ts @@ -0,0 +1,56 @@ +import { AttributeTypeMap } from "@datadog/datadog-api-client"; + +import { UsersType } from "./UsersType"; + +/** + * Relationship to user object. + */ +export class RelationshipToUserData { + /** + * A unique identifier that represents the user. + */ + "id": string; + /** + * Users resource type. + */ + "type": UsersType; + /** + * A container for additional, undeclared properties. + * This is a holder for any undeclared properties as specified with + * the 'additionalProperties' keyword in the OAS document. + */ + "additionalProperties"?: { [key: string]: any }; + /** + * @ignore + */ + "_unparsed"?: boolean; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + id: { + baseName: "id", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "UsersType", + required: true, + }, + additionalProperties: { + baseName: "additionalProperties", + type: "{ [key: string]: any; }", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return RelationshipToUserData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/services/security_monitoring/src/v2/models/TypingInfo.ts b/services/security_monitoring/src/v2/models/TypingInfo.ts index 415024d2cbba..ef418580e263 100644 --- a/services/security_monitoring/src/v2/models/TypingInfo.ts +++ b/services/security_monitoring/src/v2/models/TypingInfo.ts @@ -7,6 +7,13 @@ import { AssetAttributes } from "./AssetAttributes"; import { AssetOperatingSystem } from "./AssetOperatingSystem"; import { AssetRisks } from "./AssetRisks"; import { AssetVersion } from "./AssetVersion"; +import { AttachCaseRequest } from "./AttachCaseRequest"; +import { AttachCaseRequestData } from "./AttachCaseRequestData"; +import { AttachCaseRequestDataRelationships } from "./AttachCaseRequestDataRelationships"; +import { AttachJiraIssueRequest } from "./AttachJiraIssueRequest"; +import { AttachJiraIssueRequestData } from "./AttachJiraIssueRequestData"; +import { AttachJiraIssueRequestDataAttributes } from "./AttachJiraIssueRequestDataAttributes"; +import { AttachJiraIssueRequestDataRelationships } from "./AttachJiraIssueRequestDataRelationships"; import { BulkMuteFindingsRequest } from "./BulkMuteFindingsRequest"; import { BulkMuteFindingsRequestAttributes } from "./BulkMuteFindingsRequestAttributes"; import { BulkMuteFindingsRequestData } from "./BulkMuteFindingsRequestData"; @@ -17,6 +24,9 @@ import { BulkMuteFindingsResponse } from "./BulkMuteFindingsResponse"; import { BulkMuteFindingsResponseData } from "./BulkMuteFindingsResponseData"; import { CVSS } from "./CVSS"; import { CalculatedField } from "./CalculatedField"; +import { CaseInsightsItems } from "./CaseInsightsItems"; +import { CaseManagementProject } from "./CaseManagementProject"; +import { CaseManagementProjectData } from "./CaseManagementProjectData"; import { CloudConfigurationComplianceRuleOptions } from "./CloudConfigurationComplianceRuleOptions"; import { CloudConfigurationRegoRule } from "./CloudConfigurationRegoRule"; import { CloudConfigurationRuleCaseCreate } from "./CloudConfigurationRuleCaseCreate"; @@ -28,8 +38,19 @@ import { CodeLocation } from "./CodeLocation"; import { ConvertJobResultsToSignalsAttributes } from "./ConvertJobResultsToSignalsAttributes"; import { ConvertJobResultsToSignalsData } from "./ConvertJobResultsToSignalsData"; import { ConvertJobResultsToSignalsRequest } from "./ConvertJobResultsToSignalsRequest"; +import { CreateCaseRequestArray } from "./CreateCaseRequestArray"; +import { CreateCaseRequestData } from "./CreateCaseRequestData"; +import { CreateCaseRequestDataAttributes } from "./CreateCaseRequestDataAttributes"; +import { CreateCaseRequestDataRelationships } from "./CreateCaseRequestDataRelationships"; import { CreateCustomFrameworkRequest } from "./CreateCustomFrameworkRequest"; import { CreateCustomFrameworkResponse } from "./CreateCustomFrameworkResponse"; +import { CreateJiraIssueRequestArray } from "./CreateJiraIssueRequestArray"; +import { CreateJiraIssueRequestData } from "./CreateJiraIssueRequestData"; +import { CreateJiraIssueRequestDataAttributes } from "./CreateJiraIssueRequestDataAttributes"; +import { CreateJiraIssueRequestDataAttributesFields } from "./CreateJiraIssueRequestDataAttributesFields"; +import { CreateJiraIssueRequestDataRelationships } from "./CreateJiraIssueRequestDataRelationships"; +import { CreateJiraIssueRequestDataRelationshipsCase } from "./CreateJiraIssueRequestDataRelationshipsCase"; +import { CreateJiraIssueRequestDataRelationshipsCaseData } from "./CreateJiraIssueRequestDataRelationshipsCaseData"; import { CreateNotificationRuleParameters } from "./CreateNotificationRuleParameters"; import { CreateNotificationRuleParametersData } from "./CreateNotificationRuleParametersData"; import { CreateNotificationRuleParametersDataAttributes } from "./CreateNotificationRuleParametersDataAttributes"; @@ -42,13 +63,25 @@ import { CustomFrameworkRequirement } from "./CustomFrameworkRequirement"; import { CustomFrameworkWithoutRequirements } from "./CustomFrameworkWithoutRequirements"; import { DeleteCustomFrameworkResponse } from "./DeleteCustomFrameworkResponse"; import { DependencyLocation } from "./DependencyLocation"; +import { DetachCaseRequest } from "./DetachCaseRequest"; +import { DetachCaseRequestData } from "./DetachCaseRequestData"; +import { DetachCaseRequestDataRelationships } from "./DetachCaseRequestDataRelationships"; import { DetailedFinding } from "./DetailedFinding"; import { DetailedFindingAttributes } from "./DetailedFindingAttributes"; import { EPSS } from "./EPSS"; import { Finding } from "./Finding"; import { FindingAttributes } from "./FindingAttributes"; +import { FindingCaseResponse } from "./FindingCaseResponse"; +import { FindingCaseResponseArray } from "./FindingCaseResponseArray"; +import { FindingCaseResponseData } from "./FindingCaseResponseData"; +import { FindingCaseResponseDataAttributes } from "./FindingCaseResponseDataAttributes"; +import { FindingCaseResponseDataRelationships } from "./FindingCaseResponseDataRelationships"; +import { FindingData } from "./FindingData"; +import { FindingJiraIssue } from "./FindingJiraIssue"; +import { FindingJiraIssueResult } from "./FindingJiraIssueResult"; import { FindingMute } from "./FindingMute"; import { FindingRule } from "./FindingRule"; +import { Findings } from "./Findings"; import { FrameworkHandleAndVersionResponseData } from "./FrameworkHandleAndVersionResponseData"; import { FullCustomFrameworkData } from "./FullCustomFrameworkData"; import { FullCustomFrameworkDataAttributes } from "./FullCustomFrameworkDataAttributes"; @@ -96,6 +129,8 @@ import { Pagination } from "./Pagination"; import { PatchNotificationRuleParameters } from "./PatchNotificationRuleParameters"; import { PatchNotificationRuleParametersData } from "./PatchNotificationRuleParametersData"; import { PatchNotificationRuleParametersDataAttributes } from "./PatchNotificationRuleParametersDataAttributes"; +import { RelationshipToUser } from "./RelationshipToUser"; +import { RelationshipToUserData } from "./RelationshipToUserData"; import { Remediation } from "./Remediation"; import { ResourceFilterAttributes } from "./ResourceFilterAttributes"; import { ResponseMetaAttributes } from "./ResponseMetaAttributes"; @@ -236,6 +271,9 @@ export const TypingInfo: ModelTypingInfo = { enumsMap: { AssetEntityType: ["assets"], AssetType: ["Repository", "Service", "Host", "HostImage", "Image"], + CaseDataType: ["cases"], + CaseManagementProjectDataType: ["projects"], + CasePriority: ["NOT_DEFINED", "P1", "P2", "P3", "P4", "P5"], CloudAssetType: ["Host", "HostImage", "Image"], CloudConfigurationRuleType: ["cloud_configuration"], ConvertJobResultsToSignalsDataType: [ @@ -243,6 +281,7 @@ export const TypingInfo: ModelTypingInfo = { ], CustomFrameworkType: ["custom_framework"], DetailedFindingType: ["detailed_finding"], + FindingDataType: ["findings"], FindingEvaluation: ["pass", "fail"], FindingMuteReason: [ "PENDING_FIX", @@ -270,6 +309,7 @@ export const TypingInfo: ModelTypingInfo = { ], GetMultipleRulesetsResponseDataType: ["get_multiple_rulesets_response"], GetRuleVersionHistoryDataType: ["GetRuleVersionHistoryResponse"], + JiraIssuesDataType: ["jira_issues"], NotificationRulesType: ["notification_rules"], ResourceFilterRequestType: ["csm_resource_filter"], RuleSeverity: ["critical", "high", "medium", "low", "unknown", "info"], @@ -418,6 +458,7 @@ export const TypingInfo: ModelTypingInfo = { SpecVersion: ["1.0", "1.1", "1.2", "1.3", "1.4", "1.5"], ThreatHuntingJobDataType: ["historicalDetectionsJob"], TriggerSource: ["security_findings", "security_signals"], + UsersType: ["users"], VulnerabilitiesType: ["vulnerabilities"], VulnerabilityEcosystem: [ "PyPI", @@ -494,6 +535,11 @@ export const TypingInfo: ModelTypingInfo = { ], }, oneOfMap: { + CreateJiraIssueRequestArrayIncluded: [ + "CreateCaseRequestData", + "CaseManagementProjectData", + "FindingData", + ], SecurityMonitoringRuleConvertPayload: [ "SecurityMonitoringStandardRulePayload", "SecurityMonitoringSignalRulePayload", @@ -528,6 +574,14 @@ export const TypingInfo: ModelTypingInfo = { AssetOperatingSystem: AssetOperatingSystem, AssetRisks: AssetRisks, AssetVersion: AssetVersion, + AttachCaseRequest: AttachCaseRequest, + AttachCaseRequestData: AttachCaseRequestData, + AttachCaseRequestDataRelationships: AttachCaseRequestDataRelationships, + AttachJiraIssueRequest: AttachJiraIssueRequest, + AttachJiraIssueRequestData: AttachJiraIssueRequestData, + AttachJiraIssueRequestDataAttributes: AttachJiraIssueRequestDataAttributes, + AttachJiraIssueRequestDataRelationships: + AttachJiraIssueRequestDataRelationships, BulkMuteFindingsRequest: BulkMuteFindingsRequest, BulkMuteFindingsRequestAttributes: BulkMuteFindingsRequestAttributes, BulkMuteFindingsRequestData: BulkMuteFindingsRequestData, @@ -538,6 +592,9 @@ export const TypingInfo: ModelTypingInfo = { BulkMuteFindingsResponseData: BulkMuteFindingsResponseData, CVSS: CVSS, CalculatedField: CalculatedField, + CaseInsightsItems: CaseInsightsItems, + CaseManagementProject: CaseManagementProject, + CaseManagementProjectData: CaseManagementProjectData, CloudConfigurationComplianceRuleOptions: CloudConfigurationComplianceRuleOptions, CloudConfigurationRegoRule: CloudConfigurationRegoRule, @@ -551,8 +608,23 @@ export const TypingInfo: ModelTypingInfo = { ConvertJobResultsToSignalsAttributes: ConvertJobResultsToSignalsAttributes, ConvertJobResultsToSignalsData: ConvertJobResultsToSignalsData, ConvertJobResultsToSignalsRequest: ConvertJobResultsToSignalsRequest, + CreateCaseRequestArray: CreateCaseRequestArray, + CreateCaseRequestData: CreateCaseRequestData, + CreateCaseRequestDataAttributes: CreateCaseRequestDataAttributes, + CreateCaseRequestDataRelationships: CreateCaseRequestDataRelationships, CreateCustomFrameworkRequest: CreateCustomFrameworkRequest, CreateCustomFrameworkResponse: CreateCustomFrameworkResponse, + CreateJiraIssueRequestArray: CreateJiraIssueRequestArray, + CreateJiraIssueRequestData: CreateJiraIssueRequestData, + CreateJiraIssueRequestDataAttributes: CreateJiraIssueRequestDataAttributes, + CreateJiraIssueRequestDataAttributesFields: + CreateJiraIssueRequestDataAttributesFields, + CreateJiraIssueRequestDataRelationships: + CreateJiraIssueRequestDataRelationships, + CreateJiraIssueRequestDataRelationshipsCase: + CreateJiraIssueRequestDataRelationshipsCase, + CreateJiraIssueRequestDataRelationshipsCaseData: + CreateJiraIssueRequestDataRelationshipsCaseData, CreateNotificationRuleParameters: CreateNotificationRuleParameters, CreateNotificationRuleParametersData: CreateNotificationRuleParametersData, CreateNotificationRuleParametersDataAttributes: @@ -566,13 +638,25 @@ export const TypingInfo: ModelTypingInfo = { CustomFrameworkWithoutRequirements: CustomFrameworkWithoutRequirements, DeleteCustomFrameworkResponse: DeleteCustomFrameworkResponse, DependencyLocation: DependencyLocation, + DetachCaseRequest: DetachCaseRequest, + DetachCaseRequestData: DetachCaseRequestData, + DetachCaseRequestDataRelationships: DetachCaseRequestDataRelationships, DetailedFinding: DetailedFinding, DetailedFindingAttributes: DetailedFindingAttributes, EPSS: EPSS, Finding: Finding, FindingAttributes: FindingAttributes, + FindingCaseResponse: FindingCaseResponse, + FindingCaseResponseArray: FindingCaseResponseArray, + FindingCaseResponseData: FindingCaseResponseData, + FindingCaseResponseDataAttributes: FindingCaseResponseDataAttributes, + FindingCaseResponseDataRelationships: FindingCaseResponseDataRelationships, + FindingData: FindingData, + FindingJiraIssue: FindingJiraIssue, + FindingJiraIssueResult: FindingJiraIssueResult, FindingMute: FindingMute, FindingRule: FindingRule, + Findings: Findings, FrameworkHandleAndVersionResponseData: FrameworkHandleAndVersionResponseData, FullCustomFrameworkData: FullCustomFrameworkData, @@ -631,6 +715,8 @@ export const TypingInfo: ModelTypingInfo = { PatchNotificationRuleParametersData: PatchNotificationRuleParametersData, PatchNotificationRuleParametersDataAttributes: PatchNotificationRuleParametersDataAttributes, + RelationshipToUser: RelationshipToUser, + RelationshipToUserData: RelationshipToUserData, Remediation: Remediation, ResourceFilterAttributes: ResourceFilterAttributes, ResponseMetaAttributes: ResponseMetaAttributes, diff --git a/services/security_monitoring/src/v2/models/UsersType.ts b/services/security_monitoring/src/v2/models/UsersType.ts new file mode 100644 index 000000000000..7d6f25f470df --- /dev/null +++ b/services/security_monitoring/src/v2/models/UsersType.ts @@ -0,0 +1,7 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * Users resource type. + */ +export type UsersType = typeof USERS | UnparsedObject; +export const USERS = "users";