diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index ed984a56d..5f22ac50f 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -177876,9 +177876,6 @@ paths: 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/). post: description: >- Create Linear issues for security findings. @@ -177952,9 +177949,6 @@ paths: 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/security/findings/mute: patch: description: >- diff --git a/examples/v2_security-monitoring_AttachLinearIssue.rs b/examples/v2_security-monitoring_AttachLinearIssue.rs index 8082b1ea9..272a07f0c 100644 --- a/examples/v2_security-monitoring_AttachLinearIssue.rs +++ b/examples/v2_security-monitoring_AttachLinearIssue.rs @@ -31,8 +31,7 @@ async fn main() { ), LinearIssuesDataType::LINEAR_ISSUES, )); - let mut configuration = datadog::Configuration::new(); - configuration.set_unstable_operation_enabled("v2.AttachLinearIssue", true); + let configuration = datadog::Configuration::new(); let api = SecurityMonitoringAPI::with_config(configuration); let resp = api.attach_linear_issue(body).await; if let Ok(value) = resp { diff --git a/examples/v2_security-monitoring_CreateLinearIssues.rs b/examples/v2_security-monitoring_CreateLinearIssues.rs index 3b1e4bfe8..5e4295b5b 100644 --- a/examples/v2_security-monitoring_CreateLinearIssues.rs +++ b/examples/v2_security-monitoring_CreateLinearIssues.rs @@ -38,8 +38,7 @@ async fn main() { CaseManagementProjectDataType::PROJECTS, )), ))]); - let mut configuration = datadog::Configuration::new(); - configuration.set_unstable_operation_enabled("v2.CreateLinearIssues", true); + let configuration = datadog::Configuration::new(); let api = SecurityMonitoringAPI::with_config(configuration); let resp = api.create_linear_issues(body).await; if let Ok(value) = resp { diff --git a/src/datadog/configuration.rs b/src/datadog/configuration.rs index 0f430b0dd..62185c568 100644 --- a/src/datadog/configuration.rs +++ b/src/datadog/configuration.rs @@ -292,7 +292,6 @@ impl Default for Configuration { ("v2.list_aws_cloud_auth_persona_mappings".to_owned(), false), ("v2.activate_content_pack".to_owned(), false), ("v2.activate_integration".to_owned(), false), - ("v2.attach_linear_issue".to_owned(), false), ( "v2.batch_get_security_monitoring_dataset_dependencies".to_owned(), false, @@ -312,7 +311,6 @@ impl Default for Configuration { false, ), ("v2.create_io_c_triage_state".to_owned(), false), - ("v2.create_linear_issues".to_owned(), false), ( "v2.create_sample_log_generation_subscription".to_owned(), false, diff --git a/src/datadogV2/api/api_security_monitoring.rs b/src/datadogV2/api/api_security_monitoring.rs index 0a89955c7..4570f0855 100644 --- a/src/datadogV2/api/api_security_monitoring.rs +++ b/src/datadogV2/api/api_security_monitoring.rs @@ -3595,14 +3595,6 @@ impl SecurityMonitoringAPI { > { let local_configuration = &self.config; let operation_id = "v2.attach_linear_issue"; - if local_configuration.is_unstable_operation_enabled(operation_id) { - warn!("Using unstable operation {operation_id}"); - } else { - let local_error = datadog::UnstableOperationDisabledError { - msg: "Operation 'v2.attach_linear_issue' is not enabled".to_string(), - }; - return Err(datadog::Error::UnstableOperationDisabledError(local_error)); - } let local_client = &self.client; @@ -6738,14 +6730,6 @@ impl SecurityMonitoringAPI { > { let local_configuration = &self.config; let operation_id = "v2.create_linear_issues"; - if local_configuration.is_unstable_operation_enabled(operation_id) { - warn!("Using unstable operation {operation_id}"); - } else { - let local_error = datadog::UnstableOperationDisabledError { - msg: "Operation 'v2.create_linear_issues' is not enabled".to_string(), - }; - return Err(datadog::Error::UnstableOperationDisabledError(local_error)); - } let local_client = &self.client; diff --git a/tests/scenarios/features/v2/security_monitoring.feature b/tests/scenarios/features/v2/security_monitoring.feature index c713293f4..10c4c66af 100644 --- a/tests/scenarios/features/v2/security_monitoring.feature +++ b/tests/scenarios/features/v2/security_monitoring.feature @@ -140,24 +140,21 @@ Feature: Security Monitoring @generated @skip @team:DataDog/k9-investigation Scenario: Attach security findings to a Linear issue returns "Bad Request" response - Given operation "AttachLinearIssue" enabled - And new "AttachLinearIssue" request + Given new "AttachLinearIssue" request And body with value {"data": {"attributes": {"linear_issue_url": "https://linear.app/your-workspace/issue/ENG-123"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}} When the request is sent Then the response status is 400 Bad Request @generated @skip @team:DataDog/k9-investigation Scenario: Attach security findings to a Linear issue returns "Not Found" response - Given operation "AttachLinearIssue" enabled - And new "AttachLinearIssue" request + Given new "AttachLinearIssue" request And body with value {"data": {"attributes": {"linear_issue_url": "https://linear.app/your-workspace/issue/ENG-123"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}} When the request is sent Then the response status is 404 Not Found @generated @skip @team:DataDog/k9-investigation Scenario: Attach security findings to a Linear issue returns "OK" response - Given operation "AttachLinearIssue" enabled - And new "AttachLinearIssue" request + Given new "AttachLinearIssue" request And body with value {"data": {"attributes": {"linear_issue_url": "https://linear.app/your-workspace/issue/ENG-123"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}} When the request is sent Then the response status is 200 OK @@ -580,24 +577,21 @@ Feature: Security Monitoring @generated @skip @team:DataDog/k9-investigation Scenario: Create Linear issues for security findings returns "Bad Request" response - Given operation "CreateLinearIssues" enabled - And new "CreateLinearIssues" request + Given new "CreateLinearIssues" request And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the Linear issue.", "label_ids": ["a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"], "linear_project_id": "d4c3b2a1-6f5e-8b7a-0d9c-2f1e4a3b6c5d", "priority": "NOT_DEFINED", "title": "A title for the Linear issue."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}]} When the request is sent Then the response status is 400 Bad Request @generated @skip @team:DataDog/k9-investigation Scenario: Create Linear issues for security findings returns "Created" response - Given operation "CreateLinearIssues" enabled - And new "CreateLinearIssues" request + Given new "CreateLinearIssues" request And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the Linear issue.", "label_ids": ["a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"], "linear_project_id": "d4c3b2a1-6f5e-8b7a-0d9c-2f1e4a3b6c5d", "priority": "NOT_DEFINED", "title": "A title for the Linear issue."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}]} When the request is sent Then the response status is 201 Created @generated @skip @team:DataDog/k9-investigation Scenario: Create Linear issues for security findings returns "Not Found" response - Given operation "CreateLinearIssues" enabled - And new "CreateLinearIssues" request + Given new "CreateLinearIssues" request And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the Linear issue.", "label_ids": ["a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"], "linear_project_id": "d4c3b2a1-6f5e-8b7a-0d9c-2f1e4a3b6c5d", "priority": "NOT_DEFINED", "title": "A title for the Linear issue."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "linear_issues"}]} When the request is sent Then the response status is 404 Not Found