Skip to content

Commit 79cd063

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit e913a88 of spec repo (#4471)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent ff2e6f5 commit 79cd063

6 files changed

Lines changed: 6 additions & 36 deletions

File tree

.generator/schemas/v2/openapi.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -166470,9 +166470,6 @@ paths:
166470166470
permissions:
166471166471
- security_monitoring_findings_write
166472166472
- appsec_vm_write
166473-
x-unstable: |-
166474-
**Note**: This endpoint is in preview and is subject to change.
166475-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
166476166473
post:
166477166474
description: >-
166478166475
Create ServiceNow tickets for security findings.
@@ -166543,9 +166540,6 @@ paths:
166543166540
permissions:
166544166541
- security_monitoring_findings_write
166545166542
- appsec_vm_write
166546-
x-unstable: |-
166547-
**Note**: This endpoint is in preview and is subject to change.
166548-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
166549166543
/api/v2/security/sboms:
166550166544
get:
166551166545
description: |-

examples/v2/security-monitoring/AttachServiceNowTicket.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import { client, v2 } from "@datadog/datadog-api-client";
66

77
const configuration = client.createConfiguration();
8-
configuration.unstableOperations["v2.attachServiceNowTicket"] = true;
98
const apiInstance = new v2.SecurityMonitoringApi(configuration);
109

1110
const params: v2.SecurityMonitoringApiAttachServiceNowTicketRequest = {

examples/v2/security-monitoring/CreateServiceNowTickets.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import { client, v2 } from "@datadog/datadog-api-client";
66

77
const configuration = client.createConfiguration();
8-
configuration.unstableOperations["v2.createServiceNowTickets"] = true;
98
const apiInstance = new v2.SecurityMonitoringApi(configuration);
109

1110
const params: v2.SecurityMonitoringApiCreateServiceNowTicketsRequest = {

features/v2/security_monitoring.feature

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -113,24 +113,21 @@ Feature: Security Monitoring
113113

114114
@generated @skip @team:DataDog/k9-investigation
115115
Scenario: Attach security findings to a ServiceNow ticket returns "Bad Request" response
116-
Given operation "AttachServiceNowTicket" enabled
117-
And new "AttachServiceNowTicket" request
116+
Given new "AttachServiceNowTicket" request
118117
And body with value {"data": {"attributes": {"servicenow_ticket_url": "https://example.service-now.com/now/nav/ui/classic/params/target/incident.do?sys_id=abcdef0123456789abcdef0123456789"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}}
119118
When the request is sent
120119
Then the response status is 400 Bad Request
121120

122121
@generated @skip @team:DataDog/k9-investigation
123122
Scenario: Attach security findings to a ServiceNow ticket returns "Not Found" response
124-
Given operation "AttachServiceNowTicket" enabled
125-
And new "AttachServiceNowTicket" request
123+
Given new "AttachServiceNowTicket" request
126124
And body with value {"data": {"attributes": {"servicenow_ticket_url": "https://example.service-now.com/now/nav/ui/classic/params/target/incident.do?sys_id=abcdef0123456789abcdef0123456789"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}}
127125
When the request is sent
128126
Then the response status is 404 Not Found
129127

130128
@generated @skip @team:DataDog/k9-investigation
131129
Scenario: Attach security findings to a ServiceNow ticket returns "OK" response
132-
Given operation "AttachServiceNowTicket" enabled
133-
And new "AttachServiceNowTicket" request
130+
Given new "AttachServiceNowTicket" request
134131
And body with value {"data": {"attributes": {"servicenow_ticket_url": "https://example.service-now.com/now/nav/ui/classic/params/target/incident.do?sys_id=abcdef0123456789abcdef0123456789"}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}}
135132
When the request is sent
136133
Then the response status is 200 OK
@@ -532,24 +529,21 @@ Feature: Security Monitoring
532529

533530
@generated @skip @team:DataDog/k9-investigation
534531
Scenario: Create ServiceNow tickets for security findings returns "Bad Request" response
535-
Given operation "CreateServiceNowTickets" enabled
536-
And new "CreateServiceNowTickets" request
532+
Given new "CreateServiceNowTickets" request
537533
And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the ServiceNow ticket.", "priority": "NOT_DEFINED", "title": "A title for the ServiceNow ticket."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}]}
538534
When the request is sent
539535
Then the response status is 400 Bad Request
540536

541537
@generated @skip @team:DataDog/k9-investigation
542538
Scenario: Create ServiceNow tickets for security findings returns "Created" response
543-
Given operation "CreateServiceNowTickets" enabled
544-
And new "CreateServiceNowTickets" request
539+
Given new "CreateServiceNowTickets" request
545540
And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the ServiceNow ticket.", "priority": "NOT_DEFINED", "title": "A title for the ServiceNow ticket."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}]}
546541
When the request is sent
547542
Then the response status is 201 Created
548543

549544
@generated @skip @team:DataDog/k9-investigation
550545
Scenario: Create ServiceNow tickets for security findings returns "Not Found" response
551-
Given operation "CreateServiceNowTickets" enabled
552-
And new "CreateServiceNowTickets" request
546+
Given new "CreateServiceNowTickets" request
553547
And body with value {"data": [{"attributes": {"assignee_id": "f315bdaf-9ee7-4808-a9c1-99c15bf0f4d0", "description": "A description of the ServiceNow ticket.", "priority": "NOT_DEFINED", "title": "A title for the ServiceNow ticket."}, "relationships": {"findings": {"data": [{"id": "ZGVmLTAwcC1pZXJ-aS0wZjhjNjMyZDNmMzRlZTgzNw==", "type": "findings"}]}, "project": {"data": {"id": "aeadc05e-98a8-11ec-ac2c-da7ad0900001", "type": "projects"}}}, "type": "servicenow_tickets"}]}
554548
When the request is sent
555549
Then the response status is 404 Not Found

packages/datadog-api-client-common/configuration.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,6 @@ export function createConfiguration(
370370
"v2.getAWSCloudAuthPersonaMapping": false,
371371
"v2.listAWSCloudAuthPersonaMappings": false,
372372
"v2.activateContentPack": false,
373-
"v2.attachServiceNowTicket": false,
374373
"v2.batchGetSecurityMonitoringDatasetDependencies": false,
375374
"v2.bulkCreateSampleLogGenerationSubscriptions": false,
376375
"v2.bulkExportSecurityMonitoringTerraformResources": false,
@@ -380,7 +379,6 @@ export function createConfiguration(
380379
"v2.createSampleLogGenerationSubscription": false,
381380
"v2.createSecurityMonitoringDataset": false,
382381
"v2.createSecurityMonitoringIntegrationConfig": false,
383-
"v2.createServiceNowTickets": false,
384382
"v2.createStaticAnalysisAst": false,
385383
"v2.createStaticAnalysisServerAnalysis": false,
386384
"v2.deactivateContentPack": false,

packages/datadog-api-client-v2/apis/SecurityMonitoringApi.ts

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -307,13 +307,6 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory {
307307
): Promise<RequestContext> {
308308
const _config = _options || this.configuration;
309309

310-
logger.warn("Using unstable operation 'attachServiceNowTicket'");
311-
if (!_config.unstableOperations["v2.attachServiceNowTicket"]) {
312-
throw new Error(
313-
"Unstable operation 'attachServiceNowTicket' is disabled"
314-
);
315-
}
316-
317310
// verify required parameter 'body' is not null or undefined
318311
if (body === null || body === undefined) {
319312
throw new RequiredError("body", "attachServiceNowTicket");
@@ -1603,13 +1596,6 @@ export class SecurityMonitoringApiRequestFactory extends BaseAPIRequestFactory {
16031596
): Promise<RequestContext> {
16041597
const _config = _options || this.configuration;
16051598

1606-
logger.warn("Using unstable operation 'createServiceNowTickets'");
1607-
if (!_config.unstableOperations["v2.createServiceNowTickets"]) {
1608-
throw new Error(
1609-
"Unstable operation 'createServiceNowTickets' is disabled"
1610-
);
1611-
}
1612-
16131599
// verify required parameter 'body' is not null or undefined
16141600
if (body === null || body === undefined) {
16151601
throw new RequiredError("body", "createServiceNowTickets");

0 commit comments

Comments
 (0)