diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index e301432aca7..fb53a3c5293 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -31072,6 +31072,84 @@ components: type: string type: array type: object + IntegrationAssignmentDataAttributesRequest: + properties: + action: + $ref: '#/components/schemas/IntegrationAssignmentDataAttributesRequestAction' + assignment: + $ref: '#/components/schemas/IntegrationAssignmentDataAttributesRequestAssignment' + type: + $ref: '#/components/schemas/IntegrationAssignmentDataAttributesRequestType' + required: + - action + - type + - assignment + type: object + IntegrationAssignmentDataAttributesRequestAction: + description: Action to perform on the assignment. Can be "assign" or "un_assign". + enum: + - assign + - un_assign + example: assign + type: string + x-enum-varnames: + - ASSIGN + - UN_ASSIGN + IntegrationAssignmentDataAttributesRequestAssignment: + properties: + jira: + additionalProperties: + items: + type: string + type: array + description: Map of Jira issue URLs to lists of finding IDs. + example: + https://jira.example.com/browse/SEC-123: + - MDBjMzdhYzgyNGZkZGJiZmY0OGNmYjNiMWQ2ODY0YmR-OTc0YjMzNjM1Y2UyODA2YTEyNWQxYmNkZjhmODllNzg= + type: object + required: + - jira + type: object + IntegrationAssignmentDataAttributesRequestType: + description: Type of the security issues. Can be "findings" or "vulnerabilities". + enum: + - findings + - vulnerabilities + example: findings + type: string + x-enum-varnames: + - FINDINGS + - VULNERABILITIES + IntegrationAssignmentDataRequest: + properties: + attributes: + $ref: '#/components/schemas/IntegrationAssignmentDataAttributesRequest' + id: + description: Unique identifier of the integration assignment. + example: some_id + type: string + type: + $ref: '#/components/schemas/IntegrationAssignmentType' + required: + - id + - type + - attributes + type: object + IntegrationAssignmentRequest: + properties: + data: + $ref: '#/components/schemas/IntegrationAssignmentDataRequest' + required: + - data + type: object + IntegrationAssignmentType: + description: Integration assignment resource type. + enum: + - issue_assignment + example: issue_assignment + type: string + x-enum-varnames: + - ISSUE_ASSIGNMENT IntegrationIncident: description: Incident integration settings properties: @@ -32389,6 +32467,158 @@ components: $ref: '#/components/schemas/Case3rdPartyTicketStatus' readOnly: true type: object + JiraIssueCustomFields: + additionalProperties: {} + description: Custom fields for the Jira issue. + example: null + nullable: true + type: object + JiraIssueDataAttributesRequest: + properties: + account_id: + description: Jira account identifier. + example: f7ccdf99-0e22-4378-bdf9-03fde5379fea + type: string + fields: + $ref: '#/components/schemas/JiraIssueCustomFields' + issue_type: + description: Jira issue type name. + example: story + type: string + issuetype_id: + description: Jira issue type identifier. + example: '1235' + type: string + mode: + $ref: '#/components/schemas/JiraIssueDataAttributesRequestMode' + project_id: + description: Jira project identifier. + example: '1234' + type: string + project_key: + description: Jira project key. + example: SEC + type: string + required: + - account_id + - project_id + - issuetype_id + - project_key + - issue_type + type: object + JiraIssueDataAttributesRequestMode: + description: Mode for creating the Jira issue. Can be "single" or "multiple". + enum: + - single + - multiple + example: single + type: string + x-enum-varnames: + - SINGLE + - MULTIPLE + JiraIssueDataMeta: + properties: + findings: + items: + $ref: '#/components/schemas/JiraIssueFinding' + type: array + vulnerabilities: + items: + $ref: '#/components/schemas/JiraIssueFinding' + type: array + type: object + JiraIssueDataRequest: + properties: + attributes: + $ref: '#/components/schemas/JiraIssueDataAttributesRequest' + id: + description: Unique identifier of the Jira issue request. + example: ID + type: string + meta: + $ref: '#/components/schemas/JiraIssueDataMeta' + type: + $ref: '#/components/schemas/JiraIssueType' + required: + - id + - type + - attributes + - meta + type: object + JiraIssueFinding: + properties: + description: + description: Description of the finding. + example: Description + type: string + ids: + items: + $ref: '#/components/schemas/JiraIssueFindingId' + type: array + impacted: + description: Number of impacted resources. + example: 1 + format: int64 + type: integer + references: + description: References for the finding. + example: '' + type: string + remediation: + description: Remediation instructions for the finding. + example: Remediation + type: string + severity: + $ref: '#/components/schemas/FindingStatus' + title: + description: Title of the finding. + example: Title + type: string + type: + description: Type of the finding. + example: ciem + type: string + required: + - title + - description + - remediation + - references + - severity + - type + - ids + type: object + JiraIssueFindingId: + properties: + discovered: + description: Timestamp when the finding was discovered. + example: 123213123 + format: int64 + type: integer + id: + description: Identifier of the finding. + example: afa-afa-hze + type: string + resource: + description: Resource associated with the finding. + example: Resource + type: string + tags: + description: Tags associated with the finding. + example: akjasd:asdsad + type: string + required: + - id + - resource + - discovered + - tags + type: object + JiraIssueRequest: + properties: + data: + $ref: '#/components/schemas/JiraIssueDataRequest' + required: + - data + type: object JiraIssueResult: description: Jira issue information properties: @@ -32580,6 +32810,14 @@ components: required: - data type: object + JiraIssueType: + description: Jira issue resource type. + enum: + - jira_issue + example: jira_issue + type: string + x-enum-varnames: + - JIRA_ISSUE JiraIssuesDataType: default: jira_issues description: Jira issues resource type. @@ -32589,6 +32827,55 @@ components: type: string x-enum-varnames: - JIRA_ISSUES + JiraIssuesMetadataDataAttributesResponse: + properties: + account_id: + description: Jira account identifier. + example: jira-account-1234 + type: string + issue_type_id: + description: Jira issue type identifier. + example: '12356' + type: string + project_id: + description: Jira project identifier. + example: jira-project-1234 + type: string + required: + - account_id + - issue_type_id + - project_id + type: object + JiraIssuesMetadataDataResponse: + properties: + attributes: + $ref: '#/components/schemas/JiraIssuesMetadataDataAttributesResponse' + id: + description: Jira issue URL. + example: https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-103394 + type: string + type: + $ref: '#/components/schemas/JiraIssuesMetadataType' + required: + - id + - type + - attributes + type: object + JiraIssuesMetadataResponse: + properties: + data: + $ref: '#/components/schemas/JiraIssuesMetadataDataResponse' + required: + - data + type: object + JiraIssuesMetadataType: + description: Jira issues metadata resource type. + enum: + - jira_issues + example: jira_issues + type: string + x-enum-varnames: + - JIRA_ISSUES JobCreateResponse: description: Run a threat hunting job response. properties: @@ -73555,6 +73842,105 @@ paths: permissions: - security_monitoring_rules_read - security_monitoring_rules_write + /api/v2/cloud_security_management/integrations/assign: + post: + description: 'Assign or un-assign Jira issues to security findings or vulnerabilities. + + This endpoint allows you to associate existing Jira issues with security findings + or vulnerabilities, or remove such associations.' + operationId: AssignIntegrationIssues + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IntegrationAssignmentRequest' + required: true + responses: + '202': + description: Accepted + '400': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Bad Request + '404': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Not Found + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + '500': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Internal Server Error + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Assign or un-assign Jira issues to security 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 preview and is subject to change. + + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).' + /api/v2/cloud_security_management/jira_issues: + post: + description: 'Create Jira issues for security findings or vulnerabilities. + + This endpoint creates new Jira issues based on the provided security findings + or vulnerability information. The operation is asynchronous and returns immediately + with a 202 Accepted status.' + operationId: CreateJiraIssue + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/JiraIssueRequest' + required: true + responses: + '202': + description: Accepted + '400': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + '500': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Internal Server Error + 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 + x-unstable: '**Note**: This endpoint is in preview and is subject to change. + + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).' /api/v2/cloud_security_management/resource_filters: get: description: List resource filters. @@ -92609,6 +92995,57 @@ paths: permissions: - security_monitoring_findings_write - appsec_vm_write + /api/v2/security/findings/jira_issues/metadata: + get: + description: 'Retrieve metadata for a Jira issue. + + This endpoint returns metadata about a Jira issue, including account ID, issue + type ID, and project ID, based on the provided Jira issue URL.' + operationId: GetJiraIssueMetadata + parameters: + - description: The Jira issue URL. + example: https://datadoghq-sandbox-538.atlassian.net/browse/CSMSEC-103394 + in: query + name: url + required: true + schema: + type: string + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/JiraIssuesMetadataResponse' + description: OK + '400': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Bad Request + '404': + content: + application/json: + schema: + $ref: '#/components/schemas/JSONAPIErrorResponse' + description: Not Found + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Get Jira issue metadata + tags: + - Security Monitoring + x-permission: + operator: OR + permissions: + - security_monitoring_findings_read + - appsec_vm_read + x-unstable: '**Note**: This endpoint is in preview and is subject to change. + + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).' /api/v2/security/findings/search: post: description: 'Get a list of security findings that match a search query. [See diff --git a/examples/v2/security-monitoring/AssignIntegrationIssues.rb b/examples/v2/security-monitoring/AssignIntegrationIssues.rb new file mode 100644 index 00000000000..2b37ee0498b --- /dev/null +++ b/examples/v2/security-monitoring/AssignIntegrationIssues.rb @@ -0,0 +1,26 @@ +# Assign or un-assign Jira issues to security findings returns "Accepted" response + +require "datadog_api_client" +DatadogAPIClient.configure do |config| + config.unstable_operations["v2.assign_integration_issues".to_sym] = true +end +api_instance = DatadogAPIClient::V2::SecurityMonitoringAPI.new + +body = DatadogAPIClient::V2::IntegrationAssignmentRequest.new({ + data: DatadogAPIClient::V2::IntegrationAssignmentDataRequest.new({ + attributes: DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequest.new({ + action: DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequestAction::ASSIGN, + assignment: DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequestAssignment.new({ + jira: { + "https://jira.example.com/browse/SEC-123" => [ + "MDBjMzdhYzgyNGZkZGJiZmY0OGNmYjNiMWQ2ODY0YmR-OTc0YjMzNjM1Y2UyODA2YTEyNWQxYmNkZjhmODllNzg=", + ], + }, + }), + type: DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequestType::FINDINGS, + }), + id: "some_id", + type: DatadogAPIClient::V2::IntegrationAssignmentType::ISSUE_ASSIGNMENT, + }), +}) +p api_instance.assign_integration_issues(body) diff --git a/examples/v2/security-monitoring/CreateJiraIssue.rb b/examples/v2/security-monitoring/CreateJiraIssue.rb new file mode 100644 index 00000000000..f30f6623cc8 --- /dev/null +++ b/examples/v2/security-monitoring/CreateJiraIssue.rb @@ -0,0 +1,64 @@ +# Create Jira issues for security findings returns "Accepted" response + +require "datadog_api_client" +DatadogAPIClient.configure do |config| + config.unstable_operations["v2.create_jira_issue".to_sym] = true +end +api_instance = DatadogAPIClient::V2::SecurityMonitoringAPI.new + +body = DatadogAPIClient::V2::JiraIssueRequest.new({ + data: DatadogAPIClient::V2::JiraIssueDataRequest.new({ + attributes: DatadogAPIClient::V2::JiraIssueDataAttributesRequest.new({ + account_id: "f7ccdf99-0e22-4378-bdf9-03fde5379fea", + fields: nil, + issue_type: "story", + issuetype_id: "1235", + mode: DatadogAPIClient::V2::JiraIssueDataAttributesRequestMode::SINGLE, + project_id: "1234", + project_key: "SEC", + }), + id: "ID", + meta: DatadogAPIClient::V2::JiraIssueDataMeta.new({ + findings: [ + DatadogAPIClient::V2::JiraIssueFinding.new({ + description: "Description", + ids: [ + DatadogAPIClient::V2::JiraIssueFindingId.new({ + discovered: 123213123, + id: "afa-afa-hze", + resource: "Resource", + tags: "akjasd:asdsad", + }), + ], + impacted: 1, + references: "", + remediation: "Remediation", + severity: DatadogAPIClient::V2::FindingStatus::CRITICAL, + title: "Title", + type: "ciem", + }), + ], + vulnerabilities: [ + DatadogAPIClient::V2::JiraIssueFinding.new({ + description: "Description", + ids: [ + DatadogAPIClient::V2::JiraIssueFindingId.new({ + discovered: 123213123, + id: "afa-afa-hze", + resource: "Resource", + tags: "akjasd:asdsad", + }), + ], + impacted: 1, + references: "", + remediation: "Remediation", + severity: DatadogAPIClient::V2::FindingStatus::CRITICAL, + title: "Title", + type: "ciem", + }), + ], + }), + type: DatadogAPIClient::V2::JiraIssueType::JIRA_ISSUE, + }), +}) +p api_instance.create_jira_issue(body) diff --git a/examples/v2/security-monitoring/GetJiraIssueMetadata.rb b/examples/v2/security-monitoring/GetJiraIssueMetadata.rb new file mode 100644 index 00000000000..8064a95259f --- /dev/null +++ b/examples/v2/security-monitoring/GetJiraIssueMetadata.rb @@ -0,0 +1,8 @@ +# Get Jira issue metadata returns "OK" response + +require "datadog_api_client" +DatadogAPIClient.configure do |config| + config.unstable_operations["v2.get_jira_issue_metadata".to_sym] = true +end +api_instance = DatadogAPIClient::V2::SecurityMonitoringAPI.new +p api_instance.get_jira_issue_metadata("url") diff --git a/features/scenarios_model_mapping.rb b/features/scenarios_model_mapping.rb index 833c5168665..e8bec70e082 100644 --- a/features/scenarios_model_mapping.rb +++ b/features/scenarios_model_mapping.rb @@ -1374,6 +1374,12 @@ "version" => "String", "body" => "UpdateCustomFrameworkRequest", }, + "v2.AssignIntegrationIssues" => { + "body" => "IntegrationAssignmentRequest", + }, + "v2.CreateJiraIssue" => { + "body" => "JiraIssueRequest", + }, "v2.GetResourceEvaluationFilters" => { "cloud_provider" => "String", "account_id" => "String", @@ -1428,6 +1434,9 @@ "v2.CreateJiraIssues" => { "body" => "CreateJiraIssueRequestArray", }, + "v2.GetJiraIssueMetadata" => { + "url" => "String", + }, "v2.SearchSecurityFindings" => { "body" => "SecurityFindingsSearchRequest", }, diff --git a/features/v2/security_monitoring.feature b/features/v2/security_monitoring.feature index df5e32bcc4d..1924cbc0241 100644 --- a/features/v2/security_monitoring.feature +++ b/features/v2/security_monitoring.feature @@ -25,6 +25,30 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found + @generated @skip @team:DataDog/k9-investigation + Scenario: Assign or un-assign Jira issues to security findings returns "Accepted" response + Given operation "AssignIntegrationIssues" enabled + And new "AssignIntegrationIssues" request + And body with value {"data": {"attributes": {"action": "assign", "assignment": {"jira": {"https://jira.example.com/browse/SEC-123": ["MDBjMzdhYzgyNGZkZGJiZmY0OGNmYjNiMWQ2ODY0YmR-OTc0YjMzNjM1Y2UyODA2YTEyNWQxYmNkZjhmODllNzg="]}}, "type": "findings"}, "id": "some_id", "type": "issue_assignment"}} + When the request is sent + Then the response status is 202 Accepted + + @generated @skip @team:DataDog/k9-investigation + Scenario: Assign or un-assign Jira issues to security findings returns "Bad Request" response + Given operation "AssignIntegrationIssues" enabled + And new "AssignIntegrationIssues" request + And body with value {"data": {"attributes": {"action": "assign", "assignment": {"jira": {"https://jira.example.com/browse/SEC-123": ["MDBjMzdhYzgyNGZkZGJiZmY0OGNmYjNiMWQ2ODY0YmR-OTc0YjMzNjM1Y2UyODA2YTEyNWQxYmNkZjhmODllNzg="]}}, "type": "findings"}, "id": "some_id", "type": "issue_assignment"}} + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/k9-investigation + Scenario: Assign or un-assign Jira issues to security findings returns "Not Found" response + Given operation "AssignIntegrationIssues" enabled + And new "AssignIntegrationIssues" request + And body with value {"data": {"attributes": {"action": "assign", "assignment": {"jira": {"https://jira.example.com/browse/SEC-123": ["MDBjMzdhYzgyNGZkZGJiZmY0OGNmYjNiMWQ2ODY0YmR-OTc0YjMzNjM1Y2UyODA2YTEyNWQxYmNkZjhmODllNzg="]}}, "type": "findings"}, "id": "some_id", "type": "issue_assignment"}} + When the request is sent + Then the response status is 404 Not Found + @team:DataDog/k9-investigation Scenario: Attach security finding to a Jira issue returns "OK" response Given new "AttachJiraIssue" request @@ -330,6 +354,14 @@ Feature: Security Monitoring 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" + @generated @skip @team:DataDog/k9-investigation + Scenario: Create Jira issues for security findings returns "Accepted" response + Given operation "CreateJiraIssue" enabled + And new "CreateJiraIssue" request + And body with value {"data": {"attributes": {"account_id": "f7ccdf99-0e22-4378-bdf9-03fde5379fea", "fields": null, "issue_type": "story", "issuetype_id": "1235", "mode": "single", "project_id": "1234", "project_key": "SEC"}, "id": "ID", "meta": {"findings": [{"description": "Description", "ids": [{"discovered": 123213123, "id": "afa-afa-hze", "resource": "Resource", "tags": "akjasd:asdsad"}], "impacted": 1, "references": "", "remediation": "Remediation", "severity": "critical", "title": "Title", "type": "ciem"}], "vulnerabilities": [{"description": "Description", "ids": [{"discovered": 123213123, "id": "afa-afa-hze", "resource": "Resource", "tags": "akjasd:asdsad"}], "impacted": 1, "references": "", "remediation": "Remediation", "severity": "critical", "title": "Title", "type": "ciem"}]}, "type": "jira_issue"}} + When the request is sent + Then the response status is 202 Accepted + @team:DataDog/k9-investigation Scenario: Create Jira issues for security findings returns "Bad Request" response Given new "CreateJiraIssues" request @@ -887,6 +919,30 @@ Feature: Security Monitoring When the request is sent Then the response status is 404 Not Found + @generated @skip @team:DataDog/k9-investigation + Scenario: Get Jira issue metadata returns "Bad Request" response + Given operation "GetJiraIssueMetadata" enabled + And new "GetJiraIssueMetadata" request + And request contains "url" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/k9-investigation + Scenario: Get Jira issue metadata returns "Not Found" response + Given operation "GetJiraIssueMetadata" enabled + And new "GetJiraIssueMetadata" request + And request contains "url" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/k9-investigation + Scenario: Get Jira issue metadata returns "OK" response + Given operation "GetJiraIssueMetadata" enabled + And new "GetJiraIssueMetadata" request + And request contains "url" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + @generated @skip @team:DataDog/k9-cloud-vm Scenario: Get SBOM returns "Bad request: The server cannot process the request due to invalid syntax in the request." response Given new "GetSBOM" request diff --git a/features/v2/undo.json b/features/v2/undo.json index c77dfee3356..b4b02ddce37 100644 --- a/features/v2/undo.json +++ b/features/v2/undo.json @@ -999,6 +999,22 @@ "type": "idempotent" } }, + "AssignIntegrationIssues": { + "tag": "Security Monitoring", + "undo": { + "operationId": "TODO", + "parameters": [], + "type": "unsafe" + } + }, + "CreateJiraIssue": { + "tag": "Security Monitoring", + "undo": { + "operationId": "TODO", + "parameters": [], + "type": "unsafe" + } + }, "GetResourceEvaluationFilters": { "tag": "Security Monitoring", "undo": { @@ -4286,6 +4302,12 @@ "type": "unsafe" } }, + "GetJiraIssueMetadata": { + "tag": "Security Monitoring", + "undo": { + "type": "safe" + } + }, "SearchSecurityFindings": { "tag": "Security Monitoring", "undo": { diff --git a/lib/datadog_api_client/configuration.rb b/lib/datadog_api_client/configuration.rb index f51747c826e..d66a4f9b33e 100644 --- a/lib/datadog_api_client/configuration.rb +++ b/lib/datadog_api_client/configuration.rb @@ -209,12 +209,15 @@ def initialize "v2.list_apis": false, "v2.update_open_api": false, "v2.activate_content_pack": false, + "v2.assign_integration_issues": false, "v2.cancel_threat_hunting_job": false, "v2.convert_job_result_to_signal": false, + "v2.create_jira_issue": false, "v2.deactivate_content_pack": false, "v2.delete_threat_hunting_job": false, "v2.get_content_packs_states": false, "v2.get_finding": false, + "v2.get_jira_issue_metadata": false, "v2.get_rule_version_history": false, "v2.get_secrets_rules": false, "v2.get_security_monitoring_histsignal": false, diff --git a/lib/datadog_api_client/inflector.rb b/lib/datadog_api_client/inflector.rb index 5e43080ff1d..55cb48084bc 100644 --- a/lib/datadog_api_client/inflector.rb +++ b/lib/datadog_api_client/inflector.rb @@ -2844,6 +2844,13 @@ def overrides "v2.input_schema_parameters" => "InputSchemaParameters", "v2.input_schema_parameters_type" => "InputSchemaParametersType", "v2.intake_payload_accepted" => "IntakePayloadAccepted", + "v2.integration_assignment_data_attributes_request" => "IntegrationAssignmentDataAttributesRequest", + "v2.integration_assignment_data_attributes_request_action" => "IntegrationAssignmentDataAttributesRequestAction", + "v2.integration_assignment_data_attributes_request_assignment" => "IntegrationAssignmentDataAttributesRequestAssignment", + "v2.integration_assignment_data_attributes_request_type" => "IntegrationAssignmentDataAttributesRequestType", + "v2.integration_assignment_data_request" => "IntegrationAssignmentDataRequest", + "v2.integration_assignment_request" => "IntegrationAssignmentRequest", + "v2.integration_assignment_type" => "IntegrationAssignmentType", "v2.integration_incident" => "IntegrationIncident", "v2.integration_incident_field_mappings_items" => "IntegrationIncidentFieldMappingsItems", "v2.integration_incident_severity_config" => "IntegrationIncidentSeverityConfig", @@ -2941,8 +2948,19 @@ def overrides "v2.jira_integration_metadata" => "JiraIntegrationMetadata", "v2.jira_integration_metadata_issues_item" => "JiraIntegrationMetadataIssuesItem", "v2.jira_issue" => "JiraIssue", + "v2.jira_issue_data_attributes_request" => "JiraIssueDataAttributesRequest", + "v2.jira_issue_data_attributes_request_mode" => "JiraIssueDataAttributesRequestMode", + "v2.jira_issue_data_meta" => "JiraIssueDataMeta", + "v2.jira_issue_data_request" => "JiraIssueDataRequest", + "v2.jira_issue_finding" => "JiraIssueFinding", + "v2.jira_issue_finding_id" => "JiraIssueFindingId", + "v2.jira_issue_request" => "JiraIssueRequest", "v2.jira_issue_result" => "JiraIssueResult", "v2.jira_issues_data_type" => "JiraIssuesDataType", + "v2.jira_issues_metadata_data_attributes_response" => "JiraIssuesMetadataDataAttributesResponse", + "v2.jira_issues_metadata_data_response" => "JiraIssuesMetadataDataResponse", + "v2.jira_issues_metadata_response" => "JiraIssuesMetadataResponse", + "v2.jira_issues_metadata_type" => "JiraIssuesMetadataType", "v2.jira_issue_template_create_request" => "JiraIssueTemplateCreateRequest", "v2.jira_issue_template_create_request_attributes" => "JiraIssueTemplateCreateRequestAttributes", "v2.jira_issue_template_create_request_attributes_jira_account" => "JiraIssueTemplateCreateRequestAttributesJiraAccount", @@ -2956,6 +2974,7 @@ def overrides "v2.jira_issue_template_update_request" => "JiraIssueTemplateUpdateRequest", "v2.jira_issue_template_update_request_attributes" => "JiraIssueTemplateUpdateRequestAttributes", "v2.jira_issue_template_update_request_data" => "JiraIssueTemplateUpdateRequestData", + "v2.jira_issue_type" => "JiraIssueType", "v2.job_create_response" => "JobCreateResponse", "v2.job_create_response_data" => "JobCreateResponseData", "v2.job_definition" => "JobDefinition", diff --git a/lib/datadog_api_client/v2/api/security_monitoring_api.rb b/lib/datadog_api_client/v2/api/security_monitoring_api.rb index 1b324c3877a..03b42e122c1 100644 --- a/lib/datadog_api_client/v2/api/security_monitoring_api.rb +++ b/lib/datadog_api_client/v2/api/security_monitoring_api.rb @@ -96,6 +96,80 @@ def activate_content_pack_with_http_info(content_pack_id, opts = {}) return data, status_code, headers end + # Assign or un-assign Jira issues to security findings. + # + # @see #assign_integration_issues_with_http_info + def assign_integration_issues(body, opts = {}) + assign_integration_issues_with_http_info(body, opts) + nil + end + + # Assign or un-assign Jira issues to security findings. + # + # Assign or un-assign Jira issues to security findings or vulnerabilities. + # This endpoint allows you to associate existing Jira issues with security findings or vulnerabilities, or remove such associations. + # + # @param body [IntegrationAssignmentRequest] + # @param opts [Hash] the optional parameters + # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers + def assign_integration_issues_with_http_info(body, opts = {}) + unstable_enabled = @api_client.config.unstable_operations["v2.assign_integration_issues".to_sym] + if unstable_enabled + @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.assign_integration_issues") + else + raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.assign_integration_issues")) + end + + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: SecurityMonitoringAPI.assign_integration_issues ...' + end + # verify the required parameter 'body' is set + if @api_client.config.client_side_validation && body.nil? + fail ArgumentError, "Missing the required parameter 'body' when calling SecurityMonitoringAPI.assign_integration_issues" + end + # resource path + local_var_path = '/api/v2/cloud_security_management/integrations/assign' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['*/*']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] || @api_client.object_to_http_body(body) + + # return_type + return_type = opts[:debug_return_type] + + # auth_names + auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] + + new_options = opts.merge( + :operation => :assign_integration_issues, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type, + :api_version => "V2" + ) + + data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options) + if @api_client.config.debugging + @api_client.config.logger.debug "API called: SecurityMonitoringAPI#assign_integration_issues\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # Attach security findings to a case. # # @see #attach_case_with_http_info @@ -729,6 +803,80 @@ def create_custom_framework_with_http_info(body, opts = {}) return data, status_code, headers end + # Create Jira issues for security findings. + # + # @see #create_jira_issue_with_http_info + def create_jira_issue(body, opts = {}) + create_jira_issue_with_http_info(body, opts) + nil + end + + # Create Jira issues for security findings. + # + # Create Jira issues for security findings or vulnerabilities. + # This endpoint creates new Jira issues based on the provided security findings or vulnerability information. The operation is asynchronous and returns immediately with a 202 Accepted status. + # + # @param body [JiraIssueRequest] + # @param opts [Hash] the optional parameters + # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers + def create_jira_issue_with_http_info(body, opts = {}) + unstable_enabled = @api_client.config.unstable_operations["v2.create_jira_issue".to_sym] + if unstable_enabled + @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_jira_issue") + else + raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_jira_issue")) + end + + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: SecurityMonitoringAPI.create_jira_issue ...' + end + # verify the required parameter 'body' is set + if @api_client.config.client_side_validation && body.nil? + fail ArgumentError, "Missing the required parameter 'body' when calling SecurityMonitoringAPI.create_jira_issue" + end + # resource path + local_var_path = '/api/v2/cloud_security_management/jira_issues' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['*/*']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] || @api_client.object_to_http_body(body) + + # return_type + return_type = opts[:debug_return_type] + + # auth_names + auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] + + new_options = opts.merge( + :operation => :create_jira_issue, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type, + :api_version => "V2" + ) + + data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options) + if @api_client.config.debugging + @api_client.config.logger.debug "API called: SecurityMonitoringAPI#create_jira_issue\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # Create Jira issues for security findings. # # @see #create_jira_issues_with_http_info @@ -2368,6 +2516,79 @@ def get_finding_with_http_info(finding_id, opts = {}) return data, status_code, headers end + # Get Jira issue metadata. + # + # @see #get_jira_issue_metadata_with_http_info + def get_jira_issue_metadata(url, opts = {}) + data, _status_code, _headers = get_jira_issue_metadata_with_http_info(url, opts) + data + end + + # Get Jira issue metadata. + # + # Retrieve metadata for a Jira issue. + # This endpoint returns metadata about a Jira issue, including account ID, issue type ID, and project ID, based on the provided Jira issue URL. + # + # @param url [String] The Jira issue URL. + # @param opts [Hash] the optional parameters + # @return [Array<(JiraIssuesMetadataResponse, Integer, Hash)>] JiraIssuesMetadataResponse data, response status code and response headers + def get_jira_issue_metadata_with_http_info(url, opts = {}) + unstable_enabled = @api_client.config.unstable_operations["v2.get_jira_issue_metadata".to_sym] + if unstable_enabled + @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_jira_issue_metadata") + else + raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_jira_issue_metadata")) + end + + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: SecurityMonitoringAPI.get_jira_issue_metadata ...' + end + # verify the required parameter 'url' is set + if @api_client.config.client_side_validation && url.nil? + fail ArgumentError, "Missing the required parameter 'url' when calling SecurityMonitoringAPI.get_jira_issue_metadata" + end + # resource path + local_var_path = '/api/v2/security/findings/jira_issues/metadata' + + # query parameters + query_params = opts[:query_params] || {} + query_params[:'url'] = url + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + + # form parameters + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] + + # return_type + return_type = opts[:debug_return_type] || 'JiraIssuesMetadataResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ] + + new_options = opts.merge( + :operation => :get_jira_issue_metadata, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type, + :api_version => "V2" + ) + + data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options) + if @api_client.config.debugging + @api_client.config.logger.debug "API called: SecurityMonitoringAPI#get_jira_issue_metadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # List resource filters. # # @see #get_resource_evaluation_filters_with_http_info diff --git a/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request.rb b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request.rb new file mode 100644 index 00000000000..0dde2c3bf38 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class IntegrationAssignmentDataAttributesRequest + include BaseGenericModel + + # Action to perform on the assignment. Can be "assign" or "un_assign". + attr_reader :action + + # + attr_reader :assignment + + # Type of the security issues. Can be "findings" or "vulnerabilities". + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'action' => :'action', + :'assignment' => :'assignment', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'action' => :'IntegrationAssignmentDataAttributesRequestAction', + :'assignment' => :'IntegrationAssignmentDataAttributesRequestAssignment', + :'type' => :'IntegrationAssignmentDataAttributesRequestType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'action') + self.action = attributes[:'action'] + end + + if attributes.key?(:'assignment') + self.assignment = attributes[:'assignment'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @action.nil? + return false if @assignment.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param action [Object] Object to be assigned + # @!visibility private + def action=(action) + if action.nil? + fail ArgumentError, 'invalid value for "action", action cannot be nil.' + end + @action = action + end + + # Custom attribute writer method with validation + # @param assignment [Object] Object to be assigned + # @!visibility private + def assignment=(assignment) + if assignment.nil? + fail ArgumentError, 'invalid value for "assignment", assignment cannot be nil.' + end + @assignment = assignment + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + action == o.action && + assignment == o.assignment && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [action, assignment, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_action.rb b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_action.rb new file mode 100644 index 00000000000..1ff8333c5ba --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_action.rb @@ -0,0 +1,27 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Action to perform on the assignment. Can be "assign" or "un_assign". + class IntegrationAssignmentDataAttributesRequestAction + include BaseEnumModel + + ASSIGN = "assign".freeze + UN_ASSIGN = "un_assign".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_assignment.rb b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_assignment.rb new file mode 100644 index 00000000000..9ca1f9b1870 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_assignment.rb @@ -0,0 +1,123 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class IntegrationAssignmentDataAttributesRequestAssignment + include BaseGenericModel + + # Map of Jira issue URLs to lists of finding IDs. + attr_reader :jira + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'jira' => :'jira' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'jira' => :'Hash>' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::IntegrationAssignmentDataAttributesRequestAssignment` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'jira') + self.jira = attributes[:'jira'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @jira.nil? + true + end + + # Custom attribute writer method with validation + # @param jira [Object] Object to be assigned + # @!visibility private + def jira=(jira) + if jira.nil? + fail ArgumentError, 'invalid value for "jira", jira cannot be nil.' + end + @jira = jira + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + jira == o.jira && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [jira, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_type.rb b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_type.rb new file mode 100644 index 00000000000..d3d13860965 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_data_attributes_request_type.rb @@ -0,0 +1,27 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Type of the security issues. Can be "findings" or "vulnerabilities". + class IntegrationAssignmentDataAttributesRequestType + include BaseEnumModel + + FINDINGS = "findings".freeze + VULNERABILITIES = "vulnerabilities".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_data_request.rb b/lib/datadog_api_client/v2/models/integration_assignment_data_request.rb new file mode 100644 index 00000000000..a88b6c0b528 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_data_request.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class IntegrationAssignmentDataRequest + include BaseGenericModel + + # + attr_reader :attributes + + # Unique identifier of the integration assignment. + attr_reader :id + + # Integration assignment resource type. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'IntegrationAssignmentDataAttributesRequest', + :'id' => :'String', + :'type' => :'IntegrationAssignmentType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::IntegrationAssignmentDataRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_request.rb b/lib/datadog_api_client/v2/models/integration_assignment_request.rb new file mode 100644 index 00000000000..d552a8f0520 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_request.rb @@ -0,0 +1,123 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class IntegrationAssignmentRequest + include BaseGenericModel + + # + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'IntegrationAssignmentDataRequest' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::IntegrationAssignmentRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + self.data = attributes[:'data'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/integration_assignment_type.rb b/lib/datadog_api_client/v2/models/integration_assignment_type.rb new file mode 100644 index 00000000000..5fc3ac5b1b1 --- /dev/null +++ b/lib/datadog_api_client/v2/models/integration_assignment_type.rb @@ -0,0 +1,26 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Integration assignment resource type. + class IntegrationAssignmentType + include BaseEnumModel + + ISSUE_ASSIGNMENT = "issue_assignment".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request.rb b/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request.rb new file mode 100644 index 00000000000..60fc51ebcf7 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request.rb @@ -0,0 +1,235 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueDataAttributesRequest + include BaseGenericModel + + # Jira account identifier. + attr_reader :account_id + + # Custom fields for the Jira issue. + attr_accessor :fields + + # Jira issue type name. + attr_reader :issue_type + + # Jira issue type identifier. + attr_reader :issuetype_id + + # Mode for creating the Jira issue. Can be "single" or "multiple". + attr_accessor :mode + + # Jira project identifier. + attr_reader :project_id + + # Jira project key. + attr_reader :project_key + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'account_id' => :'account_id', + :'fields' => :'fields', + :'issue_type' => :'issue_type', + :'issuetype_id' => :'issuetype_id', + :'mode' => :'mode', + :'project_id' => :'project_id', + :'project_key' => :'project_key' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'account_id' => :'String', + :'fields' => :'Hash', + :'issue_type' => :'String', + :'issuetype_id' => :'String', + :'mode' => :'JiraIssueDataAttributesRequestMode', + :'project_id' => :'String', + :'project_key' => :'String' + } + end + + # List of attributes with nullable: true + # @!visibility private + def self.openapi_nullable + Set.new([ + :'fields', + ]) + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueDataAttributesRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'account_id') + self.account_id = attributes[:'account_id'] + end + + if attributes.key?(:'fields') + self.fields = attributes[:'fields'] + end + + if attributes.key?(:'issue_type') + self.issue_type = attributes[:'issue_type'] + end + + if attributes.key?(:'issuetype_id') + self.issuetype_id = attributes[:'issuetype_id'] + end + + if attributes.key?(:'mode') + self.mode = attributes[:'mode'] + end + + if attributes.key?(:'project_id') + self.project_id = attributes[:'project_id'] + end + + if attributes.key?(:'project_key') + self.project_key = attributes[:'project_key'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @account_id.nil? + return false if @issue_type.nil? + return false if @issuetype_id.nil? + return false if @project_id.nil? + return false if @project_key.nil? + true + end + + # Custom attribute writer method with validation + # @param account_id [Object] Object to be assigned + # @!visibility private + def account_id=(account_id) + if account_id.nil? + fail ArgumentError, 'invalid value for "account_id", account_id cannot be nil.' + end + @account_id = account_id + end + + # Custom attribute writer method with validation + # @param issue_type [Object] Object to be assigned + # @!visibility private + def issue_type=(issue_type) + if issue_type.nil? + fail ArgumentError, 'invalid value for "issue_type", issue_type cannot be nil.' + end + @issue_type = issue_type + end + + # Custom attribute writer method with validation + # @param issuetype_id [Object] Object to be assigned + # @!visibility private + def issuetype_id=(issuetype_id) + if issuetype_id.nil? + fail ArgumentError, 'invalid value for "issuetype_id", issuetype_id cannot be nil.' + end + @issuetype_id = issuetype_id + end + + # Custom attribute writer method with validation + # @param project_id [Object] Object to be assigned + # @!visibility private + def project_id=(project_id) + if project_id.nil? + fail ArgumentError, 'invalid value for "project_id", project_id cannot be nil.' + end + @project_id = project_id + end + + # Custom attribute writer method with validation + # @param project_key [Object] Object to be assigned + # @!visibility private + def project_key=(project_key) + if project_key.nil? + fail ArgumentError, 'invalid value for "project_key", project_key cannot be nil.' + end + @project_key = project_key + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + account_id == o.account_id && + fields == o.fields && + issue_type == o.issue_type && + issuetype_id == o.issuetype_id && + mode == o.mode && + project_id == o.project_id && + project_key == o.project_key && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [account_id, fields, issue_type, issuetype_id, mode, project_id, project_key, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request_mode.rb b/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request_mode.rb new file mode 100644 index 00000000000..a5004f150cb --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_data_attributes_request_mode.rb @@ -0,0 +1,27 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Mode for creating the Jira issue. Can be "single" or "multiple". + class JiraIssueDataAttributesRequestMode + include BaseEnumModel + + SINGLE = "single".freeze + MULTIPLE = "multiple".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_data_meta.rb b/lib/datadog_api_client/v2/models/jira_issue_data_meta.rb new file mode 100644 index 00000000000..325c325df92 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_data_meta.rb @@ -0,0 +1,119 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueDataMeta + include BaseGenericModel + + # + attr_accessor :findings + + # + attr_accessor :vulnerabilities + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'findings' => :'findings', + :'vulnerabilities' => :'vulnerabilities' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'findings' => :'Array', + :'vulnerabilities' => :'Array' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueDataMeta` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'findings') + if (value = attributes[:'findings']).is_a?(Array) + self.findings = value + end + end + + if attributes.key?(:'vulnerabilities') + if (value = attributes[:'vulnerabilities']).is_a?(Array) + self.vulnerabilities = value + end + end + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + findings == o.findings && + vulnerabilities == o.vulnerabilities && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [findings, vulnerabilities, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_data_request.rb b/lib/datadog_api_client/v2/models/jira_issue_data_request.rb new file mode 100644 index 00000000000..b8f0288b3f9 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_data_request.rb @@ -0,0 +1,186 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueDataRequest + include BaseGenericModel + + # + attr_reader :attributes + + # Unique identifier of the Jira issue request. + attr_reader :id + + # + attr_reader :meta + + # Jira issue resource type. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'meta' => :'meta', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'JiraIssueDataAttributesRequest', + :'id' => :'String', + :'meta' => :'JiraIssueDataMeta', + :'type' => :'JiraIssueType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueDataRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'meta') + self.meta = attributes[:'meta'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @meta.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param meta [Object] Object to be assigned + # @!visibility private + def meta=(meta) + if meta.nil? + fail ArgumentError, 'invalid value for "meta", meta cannot be nil.' + end + @meta = meta + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + meta == o.meta && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, meta, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_finding.rb b/lib/datadog_api_client/v2/models/jira_issue_finding.rb new file mode 100644 index 00000000000..1f158f1e71b --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_finding.rb @@ -0,0 +1,261 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueFinding + include BaseGenericModel + + # Description of the finding. + attr_reader :description + + # + attr_reader :ids + + # Number of impacted resources. + attr_accessor :impacted + + # References for the finding. + attr_reader :references + + # Remediation instructions for the finding. + attr_reader :remediation + + # The status of the finding. + attr_reader :severity + + # Title of the finding. + attr_reader :title + + # Type of the finding. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'description' => :'description', + :'ids' => :'ids', + :'impacted' => :'impacted', + :'references' => :'references', + :'remediation' => :'remediation', + :'severity' => :'severity', + :'title' => :'title', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'description' => :'String', + :'ids' => :'Array', + :'impacted' => :'Integer', + :'references' => :'String', + :'remediation' => :'String', + :'severity' => :'FindingStatus', + :'title' => :'String', + :'type' => :'String' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueFinding` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'description') + self.description = attributes[:'description'] + end + + if attributes.key?(:'ids') + if (value = attributes[:'ids']).is_a?(Array) + self.ids = value + end + end + + if attributes.key?(:'impacted') + self.impacted = attributes[:'impacted'] + end + + if attributes.key?(:'references') + self.references = attributes[:'references'] + end + + if attributes.key?(:'remediation') + self.remediation = attributes[:'remediation'] + end + + if attributes.key?(:'severity') + self.severity = attributes[:'severity'] + end + + if attributes.key?(:'title') + self.title = attributes[:'title'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @description.nil? + return false if @ids.nil? + return false if @references.nil? + return false if @remediation.nil? + return false if @severity.nil? + return false if @title.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param description [Object] Object to be assigned + # @!visibility private + def description=(description) + if description.nil? + fail ArgumentError, 'invalid value for "description", description cannot be nil.' + end + @description = description + end + + # Custom attribute writer method with validation + # @param ids [Object] Object to be assigned + # @!visibility private + def ids=(ids) + if ids.nil? + fail ArgumentError, 'invalid value for "ids", ids cannot be nil.' + end + @ids = ids + end + + # Custom attribute writer method with validation + # @param references [Object] Object to be assigned + # @!visibility private + def references=(references) + if references.nil? + fail ArgumentError, 'invalid value for "references", references cannot be nil.' + end + @references = references + end + + # Custom attribute writer method with validation + # @param remediation [Object] Object to be assigned + # @!visibility private + def remediation=(remediation) + if remediation.nil? + fail ArgumentError, 'invalid value for "remediation", remediation cannot be nil.' + end + @remediation = remediation + end + + # Custom attribute writer method with validation + # @param severity [Object] Object to be assigned + # @!visibility private + def severity=(severity) + if severity.nil? + fail ArgumentError, 'invalid value for "severity", severity cannot be nil.' + end + @severity = severity + end + + # Custom attribute writer method with validation + # @param title [Object] Object to be assigned + # @!visibility private + def title=(title) + if title.nil? + fail ArgumentError, 'invalid value for "title", title cannot be nil.' + end + @title = title + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + description == o.description && + ids == o.ids && + impacted == o.impacted && + references == o.references && + remediation == o.remediation && + severity == o.severity && + title == o.title && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [description, ids, impacted, references, remediation, severity, title, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_finding_id.rb b/lib/datadog_api_client/v2/models/jira_issue_finding_id.rb new file mode 100644 index 00000000000..f35046ce8f0 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_finding_id.rb @@ -0,0 +1,186 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueFindingId + include BaseGenericModel + + # Timestamp when the finding was discovered. + attr_reader :discovered + + # Identifier of the finding. + attr_reader :id + + # Resource associated with the finding. + attr_reader :resource + + # Tags associated with the finding. + attr_reader :tags + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'discovered' => :'discovered', + :'id' => :'id', + :'resource' => :'resource', + :'tags' => :'tags' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'discovered' => :'Integer', + :'id' => :'String', + :'resource' => :'String', + :'tags' => :'String' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueFindingId` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'discovered') + self.discovered = attributes[:'discovered'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'resource') + self.resource = attributes[:'resource'] + end + + if attributes.key?(:'tags') + self.tags = attributes[:'tags'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @discovered.nil? + return false if @id.nil? + return false if @resource.nil? + return false if @tags.nil? + true + end + + # Custom attribute writer method with validation + # @param discovered [Object] Object to be assigned + # @!visibility private + def discovered=(discovered) + if discovered.nil? + fail ArgumentError, 'invalid value for "discovered", discovered cannot be nil.' + end + @discovered = discovered + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param resource [Object] Object to be assigned + # @!visibility private + def resource=(resource) + if resource.nil? + fail ArgumentError, 'invalid value for "resource", resource cannot be nil.' + end + @resource = resource + end + + # Custom attribute writer method with validation + # @param tags [Object] Object to be assigned + # @!visibility private + def tags=(tags) + if tags.nil? + fail ArgumentError, 'invalid value for "tags", tags cannot be nil.' + end + @tags = tags + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + discovered == o.discovered && + id == o.id && + resource == o.resource && + tags == o.tags && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [discovered, id, resource, tags, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_request.rb b/lib/datadog_api_client/v2/models/jira_issue_request.rb new file mode 100644 index 00000000000..4a3886afec7 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_request.rb @@ -0,0 +1,123 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssueRequest + include BaseGenericModel + + # + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'JiraIssueDataRequest' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssueRequest` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + self.data = attributes[:'data'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issue_type.rb b/lib/datadog_api_client/v2/models/jira_issue_type.rb new file mode 100644 index 00000000000..514fb7dfed6 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issue_type.rb @@ -0,0 +1,26 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Jira issue resource type. + class JiraIssueType + include BaseEnumModel + + JIRA_ISSUE = "jira_issue".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issues_metadata_data_attributes_response.rb b/lib/datadog_api_client/v2/models/jira_issues_metadata_data_attributes_response.rb new file mode 100644 index 00000000000..09b426de991 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issues_metadata_data_attributes_response.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssuesMetadataDataAttributesResponse + include BaseGenericModel + + # Jira account identifier. + attr_reader :account_id + + # Jira issue type identifier. + attr_reader :issue_type_id + + # Jira project identifier. + attr_reader :project_id + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'account_id' => :'account_id', + :'issue_type_id' => :'issue_type_id', + :'project_id' => :'project_id' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'account_id' => :'String', + :'issue_type_id' => :'String', + :'project_id' => :'String' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssuesMetadataDataAttributesResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'account_id') + self.account_id = attributes[:'account_id'] + end + + if attributes.key?(:'issue_type_id') + self.issue_type_id = attributes[:'issue_type_id'] + end + + if attributes.key?(:'project_id') + self.project_id = attributes[:'project_id'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @account_id.nil? + return false if @issue_type_id.nil? + return false if @project_id.nil? + true + end + + # Custom attribute writer method with validation + # @param account_id [Object] Object to be assigned + # @!visibility private + def account_id=(account_id) + if account_id.nil? + fail ArgumentError, 'invalid value for "account_id", account_id cannot be nil.' + end + @account_id = account_id + end + + # Custom attribute writer method with validation + # @param issue_type_id [Object] Object to be assigned + # @!visibility private + def issue_type_id=(issue_type_id) + if issue_type_id.nil? + fail ArgumentError, 'invalid value for "issue_type_id", issue_type_id cannot be nil.' + end + @issue_type_id = issue_type_id + end + + # Custom attribute writer method with validation + # @param project_id [Object] Object to be assigned + # @!visibility private + def project_id=(project_id) + if project_id.nil? + fail ArgumentError, 'invalid value for "project_id", project_id cannot be nil.' + end + @project_id = project_id + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + account_id == o.account_id && + issue_type_id == o.issue_type_id && + project_id == o.project_id && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [account_id, issue_type_id, project_id, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issues_metadata_data_response.rb b/lib/datadog_api_client/v2/models/jira_issues_metadata_data_response.rb new file mode 100644 index 00000000000..a0ece0c1306 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issues_metadata_data_response.rb @@ -0,0 +1,165 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssuesMetadataDataResponse + include BaseGenericModel + + # + attr_reader :attributes + + # Jira issue URL. + attr_reader :id + + # Jira issues metadata resource type. + attr_reader :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'attributes' => :'attributes', + :'id' => :'id', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'attributes' => :'JiraIssuesMetadataDataAttributesResponse', + :'id' => :'String', + :'type' => :'JiraIssuesMetadataType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssuesMetadataDataResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'attributes') + self.attributes = attributes[:'attributes'] + end + + if attributes.key?(:'id') + self.id = attributes[:'id'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @attributes.nil? + return false if @id.nil? + return false if @type.nil? + true + end + + # Custom attribute writer method with validation + # @param attributes [Object] Object to be assigned + # @!visibility private + def attributes=(attributes) + if attributes.nil? + fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.' + end + @attributes = attributes + end + + # Custom attribute writer method with validation + # @param id [Object] Object to be assigned + # @!visibility private + def id=(id) + if id.nil? + fail ArgumentError, 'invalid value for "id", id cannot be nil.' + end + @id = id + end + + # Custom attribute writer method with validation + # @param type [Object] Object to be assigned + # @!visibility private + def type=(type) + if type.nil? + fail ArgumentError, 'invalid value for "type", type cannot be nil.' + end + @type = type + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + attributes == o.attributes && + id == o.id && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [attributes, id, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issues_metadata_response.rb b/lib/datadog_api_client/v2/models/jira_issues_metadata_response.rb new file mode 100644 index 00000000000..3592306da81 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issues_metadata_response.rb @@ -0,0 +1,123 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # + class JiraIssuesMetadataResponse + include BaseGenericModel + + # + attr_reader :data + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'data' => :'data' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'data' => :'JiraIssuesMetadataDataResponse' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::JiraIssuesMetadataResponse` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'data') + self.data = attributes[:'data'] + end + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + # @!visibility private + def valid? + return false if @data.nil? + true + end + + # Custom attribute writer method with validation + # @param data [Object] Object to be assigned + # @!visibility private + def data=(data) + if data.nil? + fail ArgumentError, 'invalid value for "data", data cannot be nil.' + end + @data = data + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + data == o.data && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [data, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/jira_issues_metadata_type.rb b/lib/datadog_api_client/v2/models/jira_issues_metadata_type.rb new file mode 100644 index 00000000000..6ef3143be10 --- /dev/null +++ b/lib/datadog_api_client/v2/models/jira_issues_metadata_type.rb @@ -0,0 +1,26 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Jira issues metadata resource type. + class JiraIssuesMetadataType + include BaseEnumModel + + JIRA_ISSUES = "jira_issues".freeze + end +end