Skip to content

Commit d1f4ffe

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Add a new includeDiscovered query parameter to Software Catalog APIs (#3143)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 674f96f commit d1f4ffe

File tree

3 files changed

+53
-0
lines changed

3 files changed

+53
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63547,6 +63547,14 @@ paths:
6354763547
- $ref: '#/components/parameters/FilterByRelationType'
6354863548
- $ref: '#/components/parameters/FilterByExcludeSnapshot'
6354963549
- $ref: '#/components/parameters/Include'
63550+
- description: If true, includes discovered services from APM and USM that do
63551+
not have entity definitions.
63552+
in: query
63553+
name: includeDiscovered
63554+
required: false
63555+
schema:
63556+
default: false
63557+
type: boolean
6355063558
responses:
6355163559
'200':
6355263560
content:
@@ -63765,6 +63773,13 @@ paths:
6376563773
- $ref: '#/components/parameters/FilterRelationByFromRef'
6376663774
- $ref: '#/components/parameters/FilterRelationByToRef'
6376763775
- $ref: '#/components/parameters/RelationInclude'
63776+
- description: If true, includes relationships discovered by APM and USM.
63777+
in: query
63778+
name: includeDiscovered
63779+
required: false
63780+
schema:
63781+
default: false
63782+
type: boolean
6376863783
responses:
6376963784
'200':
6377063785
content:

private/bdd_runner/src/support/scenarios_model_mapping.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3596,6 +3596,10 @@ export const ScenariosModelMappings: { [key: string]: OperationMapping } = {
35963596
type: "IncludeType",
35973597
format: "",
35983598
},
3599+
includeDiscovered: {
3600+
type: "boolean",
3601+
format: "",
3602+
},
35993603
operationResponseType: "ListEntityCatalogResponse",
36003604
},
36013605
"SoftwareCatalogApi.V2.UpsertCatalogEntity": {
@@ -3673,6 +3677,10 @@ export const ScenariosModelMappings: { [key: string]: OperationMapping } = {
36733677
type: "RelationIncludeType",
36743678
format: "",
36753679
},
3680+
includeDiscovered: {
3681+
type: "boolean",
3682+
format: "",
3683+
},
36763684
operationResponseType: "ListRelationCatalogResponse",
36773685
},
36783686
"CIVisibilityPipelinesApi.V2.CreateCIAppPipelineEvent": {

services/software_catalog/src/v2/SoftwareCatalogApi.ts

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ export class SoftwareCatalogApiRequestFactory extends BaseAPIRequestFactory {
149149
filterRelationType?: RelationType,
150150
filterExcludeSnapshot?: string,
151151
include?: IncludeType,
152+
includeDiscovered?: boolean,
152153
_options?: Configuration,
153154
): Promise<RequestContext> {
154155
const _config = _options || this.configuration;
@@ -245,6 +246,13 @@ export class SoftwareCatalogApiRequestFactory extends BaseAPIRequestFactory {
245246
"",
246247
);
247248
}
249+
if (includeDiscovered !== undefined) {
250+
requestContext.setQueryParam(
251+
"includeDiscovered",
252+
serialize(includeDiscovered, TypingInfo, "boolean", ""),
253+
"",
254+
);
255+
}
248256

249257
// Apply auth methods
250258
applySecurityAuthentication(_config, requestContext, [
@@ -333,6 +341,7 @@ export class SoftwareCatalogApiRequestFactory extends BaseAPIRequestFactory {
333341
filterFromRef?: string,
334342
filterToRef?: string,
335343
include?: RelationIncludeType,
344+
includeDiscovered?: boolean,
336345
_options?: Configuration,
337346
): Promise<RequestContext> {
338347
const _config = _options || this.configuration;
@@ -401,6 +410,13 @@ export class SoftwareCatalogApiRequestFactory extends BaseAPIRequestFactory {
401410
"",
402411
);
403412
}
413+
if (includeDiscovered !== undefined) {
414+
requestContext.setQueryParam(
415+
"includeDiscovered",
416+
serialize(includeDiscovered, TypingInfo, "boolean", ""),
417+
"",
418+
);
419+
}
404420

405421
// Apply auth methods
406422
applySecurityAuthentication(_config, requestContext, [
@@ -1064,6 +1080,11 @@ export interface SoftwareCatalogApiListCatalogEntityRequest {
10641080
* @type IncludeType
10651081
*/
10661082
include?: IncludeType;
1083+
/**
1084+
* If true, includes discovered services from APM and USM that do not have entity definitions.
1085+
* @type boolean
1086+
*/
1087+
includeDiscovered?: boolean;
10671088
}
10681089

10691090
export interface SoftwareCatalogApiListCatalogKindRequest {
@@ -1120,6 +1141,11 @@ export interface SoftwareCatalogApiListCatalogRelationRequest {
11201141
* @type RelationIncludeType
11211142
*/
11221143
include?: RelationIncludeType;
1144+
/**
1145+
* If true, includes relationships discovered by APM and USM.
1146+
* @type boolean
1147+
*/
1148+
includeDiscovered?: boolean;
11231149
}
11241150

11251151
export interface SoftwareCatalogApiUpsertCatalogEntityRequest {
@@ -1219,6 +1245,7 @@ export class SoftwareCatalogApi {
12191245
param.filterRelationType,
12201246
param.filterExcludeSnapshot,
12211247
param.include,
1248+
param.includeDiscovered,
12221249
options,
12231250
);
12241251
return requestContextPromise.then((requestContext) => {
@@ -1254,6 +1281,7 @@ export class SoftwareCatalogApi {
12541281
param.filterRelationType,
12551282
param.filterExcludeSnapshot,
12561283
param.include,
1284+
param.includeDiscovered,
12571285
options,
12581286
);
12591287
const responseContext =
@@ -1363,6 +1391,7 @@ export class SoftwareCatalogApi {
13631391
param.filterFromRef,
13641392
param.filterToRef,
13651393
param.include,
1394+
param.includeDiscovered,
13661395
options,
13671396
);
13681397
return requestContextPromise.then((requestContext) => {
@@ -1394,6 +1423,7 @@ export class SoftwareCatalogApi {
13941423
param.filterFromRef,
13951424
param.filterToRef,
13961425
param.include,
1426+
param.includeDiscovered,
13971427
options,
13981428
);
13991429
const responseContext =

0 commit comments

Comments
 (0)