Skip to content

Commit 75e9311

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit f0a4221 of spec repo (#211)
Co-authored-by: ci.datadog-api-spec <[email protected]>
1 parent effe5b8 commit 75e9311

File tree

10 files changed

+117
-22
lines changed

10 files changed

+117
-22
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.4.1.dev11",
7-
"regenerated": "2021-07-13 15:56:55.034199",
8-
"spec_repo_commit": "c2e2dda"
7+
"regenerated": "2021-07-14 09:09:02.529056",
8+
"spec_repo_commit": "f0a4221"
99
},
1010
"v2": {
1111
"apigentools_version": "1.4.1.dev11",
12-
"regenerated": "2021-07-13 15:58:05.751675",
13-
"spec_repo_commit": "c2e2dda"
12+
"regenerated": "2021-07-14 09:10:15.078678",
13+
"spec_repo_commit": "f0a4221"
1414
}
1515
}
1616
}

docs/v1/AWSIntegrationApi.md

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -229,18 +229,11 @@ const configuration = v1.createConfiguration();
229229
const apiInstance = new v1.AWSIntegrationApi(configuration);
230230

231231
let params:v1.AWSIntegrationApiDeleteAWSAccountRequest = {
232-
// AWSAccount | AWS request object
232+
// AWSAccountDeleteRequest | AWS request object
233233
body: {
234234
accessKeyId: "accessKeyId_example",
235235
accountId: "1234567",
236-
accountSpecificNamespaceRules: {
237-
"key": true,
238-
},
239-
excludedRegions: ["us-east-1","us-west-2"],
240-
filterTags: ["<KEY>:<VALUE>"],
241-
hostTags: ["<KEY>:<VALUE>"],
242236
roleName: "DatadogAWSIntegrationRole",
243-
secretAccessKey: "secretAccessKey_example",
244237
},
245238
};
246239

@@ -254,7 +247,7 @@ apiInstance.deleteAWSAccount(params).then((data:any) => {
254247

255248
Name | Type | Description | Notes
256249
------------- | ------------- | ------------- | -------------
257-
**body** | **AWSAccount**| AWS request object |
250+
**body** | **AWSAccountDeleteRequest**| AWS request object |
258251

259252

260253
### Return type

features/v1/aws_integration.feature

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,21 +47,21 @@ Feature: AWS Integration
4747
@generated @skip
4848
Scenario: Delete an AWS integration returns "Bad Request" response
4949
Given new "DeleteAWSAccount" request
50-
And body with value {"access_key_id": null, "account_id": "1234567", "account_specific_namespace_rules": {"auto_scaling": false, "opswork": false}, "excluded_regions": ["us-east-1", "us-west-2"], "filter_tags": ["<KEY>:<VALUE>"], "host_tags": ["<KEY>:<VALUE>"], "role_name": "DatadogAWSIntegrationRole", "secret_access_key": null}
50+
And body with value {"access_key_id": null, "account_id": "1234567", "role_name": "DatadogAWSIntegrationRole"}
5151
When the request is sent
5252
Then the response status is 400 Bad Request
5353

5454
@generated @skip
5555
Scenario: Delete an AWS integration returns "Conflict Error" response
5656
Given new "DeleteAWSAccount" request
57-
And body with value {"access_key_id": null, "account_id": "1234567", "account_specific_namespace_rules": {"auto_scaling": false, "opswork": false}, "excluded_regions": ["us-east-1", "us-west-2"], "filter_tags": ["<KEY>:<VALUE>"], "host_tags": ["<KEY>:<VALUE>"], "role_name": "DatadogAWSIntegrationRole", "secret_access_key": null}
57+
And body with value {"access_key_id": null, "account_id": "1234567", "role_name": "DatadogAWSIntegrationRole"}
5858
When the request is sent
5959
Then the response status is 409 Conflict Error
6060

6161
@generated @skip
6262
Scenario: Delete an AWS integration returns "OK" response
6363
Given new "DeleteAWSAccount" request
64-
And body with value {"access_key_id": null, "account_id": "1234567", "account_specific_namespace_rules": {"auto_scaling": false, "opswork": false}, "excluded_regions": ["us-east-1", "us-west-2"], "filter_tags": ["<KEY>:<VALUE>"], "host_tags": ["<KEY>:<VALUE>"], "role_name": "DatadogAWSIntegrationRole", "secret_access_key": null}
64+
And body with value {"access_key_id": null, "account_id": "1234567", "role_name": "DatadogAWSIntegrationRole"}
6565
When the request is sent
6666
Then the response status is 200 OK
6767

packages/datadog-api-client-v1/.openapi-generator/FILES

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ models/APIErrorResponse.ts
6969
models/AWSAccount.ts
7070
models/AWSAccountAndLambdaRequest.ts
7171
models/AWSAccountCreateResponse.ts
72+
models/AWSAccountDeleteRequest.ts
7273
models/AWSAccountListResponse.ts
7374
models/AWSLogsAsyncError.ts
7475
models/AWSLogsAsyncResponse.ts

packages/datadog-api-client-v1/apis/AWSIntegrationApi.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import { isCodeInRange } from "../util";
99
import { APIErrorResponse } from "../models/APIErrorResponse";
1010
import { AWSAccount } from "../models/AWSAccount";
1111
import { AWSAccountCreateResponse } from "../models/AWSAccountCreateResponse";
12+
import { AWSAccountDeleteRequest } from "../models/AWSAccountDeleteRequest";
1213
import { AWSAccountListResponse } from "../models/AWSAccountListResponse";
1314
import { AWSTagFilterCreateRequest } from "../models/AWSTagFilterCreateRequest";
1415
import { AWSTagFilterDeleteRequest } from "../models/AWSTagFilterDeleteRequest";
@@ -204,7 +205,7 @@ export class AWSIntegrationApiRequestFactory extends BaseAPIRequestFactory {
204205
* @param body AWS request object
205206
*/
206207
public async deleteAWSAccount(
207-
body: AWSAccount,
208+
body: AWSAccountDeleteRequest,
208209
options?: Configuration
209210
): Promise<RequestContext> {
210211
const config = options || this.configuration;
@@ -239,7 +240,7 @@ export class AWSIntegrationApiRequestFactory extends BaseAPIRequestFactory {
239240
]);
240241
requestContext.setHeaderParam("Content-Type", contentType);
241242
const serializedBody = ObjectSerializer.stringify(
242-
ObjectSerializer.serialize(body, "AWSAccount", ""),
243+
ObjectSerializer.serialize(body, "AWSAccountDeleteRequest", ""),
243244
contentType
244245
);
245246
requestContext.setBody(serializedBody);
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
/**
2+
* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
3+
* This product includes software developed at Datadog (https://www.datadoghq.com/).
4+
* Copyright 2020-Present Datadog, Inc.
5+
*
6+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
7+
* https://openapi-generator.tech
8+
* Do not edit the class manually.
9+
*/
10+
11+
import { ObjectSerializer } from "./ObjectSerializer";
12+
13+
/**
14+
* List of AWS accounts to delete.
15+
*/
16+
17+
export class AWSAccountDeleteRequest {
18+
/**
19+
* Your AWS access key ID. Only required if your AWS account is a GovCloud or China account.
20+
*/
21+
"accessKeyId"?: string;
22+
/**
23+
* Your AWS Account ID without dashes.
24+
*/
25+
"accountId"?: string;
26+
/**
27+
* Your Datadog role delegation name.
28+
*/
29+
"roleName"?: string;
30+
31+
static readonly discriminator: string | undefined = undefined;
32+
33+
static readonly attributeTypeMap: {
34+
[key: string]: { baseName: string; type: string; format: string };
35+
} = {
36+
accessKeyId: {
37+
baseName: "access_key_id",
38+
type: "string",
39+
format: "",
40+
},
41+
accountId: {
42+
baseName: "account_id",
43+
type: "string",
44+
format: "",
45+
},
46+
roleName: {
47+
baseName: "role_name",
48+
type: "string",
49+
format: "",
50+
},
51+
};
52+
53+
static getAttributeTypeMap() {
54+
return AWSAccountDeleteRequest.attributeTypeMap;
55+
}
56+
57+
static deserialize(data: { [key: string]: any }): AWSAccountDeleteRequest {
58+
const res = new AWSAccountDeleteRequest();
59+
60+
res.accessKeyId = ObjectSerializer.deserialize(
61+
data.access_key_id,
62+
"string",
63+
""
64+
);
65+
66+
res.accountId = ObjectSerializer.deserialize(data.account_id, "string", "");
67+
68+
res.roleName = ObjectSerializer.deserialize(data.role_name, "string", "");
69+
70+
return res;
71+
}
72+
73+
static serialize(data: AWSAccountDeleteRequest): { [key: string]: any } {
74+
const attributeTypes = AWSAccountDeleteRequest.getAttributeTypeMap();
75+
const res: { [index: string]: any } = {};
76+
for (const [key, value] of Object.entries(data)) {
77+
if (!(key in attributeTypes)) {
78+
throw new TypeError(`${key} attribute not in schema`);
79+
}
80+
}
81+
res.access_key_id = ObjectSerializer.serialize(
82+
data.accessKeyId,
83+
"string",
84+
""
85+
);
86+
87+
res.account_id = ObjectSerializer.serialize(data.accountId, "string", "");
88+
89+
res.role_name = ObjectSerializer.serialize(data.roleName, "string", "");
90+
91+
return res;
92+
}
93+
94+
public constructor() {}
95+
}

packages/datadog-api-client-v1/models/ObjectSerializer.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import { APIErrorResponse } from "./APIErrorResponse";
22
import { AWSAccount } from "./AWSAccount";
33
import { AWSAccountAndLambdaRequest } from "./AWSAccountAndLambdaRequest";
44
import { AWSAccountCreateResponse } from "./AWSAccountCreateResponse";
5+
import { AWSAccountDeleteRequest } from "./AWSAccountDeleteRequest";
56
import { AWSAccountListResponse } from "./AWSAccountListResponse";
67
import { AWSLogsAsyncError } from "./AWSLogsAsyncError";
78
import { AWSLogsAsyncResponse } from "./AWSLogsAsyncResponse";
@@ -597,6 +598,7 @@ const typeMap: { [index: string]: any } = {
597598
AWSAccount: AWSAccount,
598599
AWSAccountAndLambdaRequest: AWSAccountAndLambdaRequest,
599600
AWSAccountCreateResponse: AWSAccountCreateResponse,
601+
AWSAccountDeleteRequest: AWSAccountDeleteRequest,
600602
AWSAccountListResponse: AWSAccountListResponse,
601603
AWSLogsAsyncError: AWSLogsAsyncError,
602604
AWSLogsAsyncResponse: AWSLogsAsyncResponse,

packages/datadog-api-client-v1/types/ObjectParamAPI.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { Configuration } from "../configuration";
44
import { AWSAccount } from "../models/AWSAccount";
55
import { AWSAccountAndLambdaRequest } from "../models/AWSAccountAndLambdaRequest";
66
import { AWSAccountCreateResponse } from "../models/AWSAccountCreateResponse";
7+
import { AWSAccountDeleteRequest } from "../models/AWSAccountDeleteRequest";
78
import { AWSAccountListResponse } from "../models/AWSAccountListResponse";
89
import { AWSLogsAsyncResponse } from "../models/AWSLogsAsyncResponse";
910
import { AWSLogsListResponse } from "../models/AWSLogsListResponse";
@@ -185,10 +186,10 @@ export interface AWSIntegrationApiCreateNewAWSExternalIDRequest {
185186
export interface AWSIntegrationApiDeleteAWSAccountRequest {
186187
/**
187188
* AWS request object
188-
* @type AWSAccount
189+
* @type AWSAccountDeleteRequest
189190
* @memberof AWSIntegrationApideleteAWSAccount
190191
*/
191-
body: AWSAccount;
192+
body: AWSAccountDeleteRequest;
192193
}
193194

194195
export interface AWSIntegrationApiDeleteAWSTagFilterRequest {

packages/datadog-api-client-v1/types/ObservableAPI.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { mergeMap, map } from "../rxjsStub";
55
import { AWSAccount } from "../models/AWSAccount";
66
import { AWSAccountAndLambdaRequest } from "../models/AWSAccountAndLambdaRequest";
77
import { AWSAccountCreateResponse } from "../models/AWSAccountCreateResponse";
8+
import { AWSAccountDeleteRequest } from "../models/AWSAccountDeleteRequest";
89
import { AWSAccountListResponse } from "../models/AWSAccountListResponse";
910
import { AWSLogsAsyncResponse } from "../models/AWSLogsAsyncResponse";
1011
import { AWSLogsListResponse } from "../models/AWSLogsListResponse";
@@ -306,7 +307,7 @@ export class ObservableAWSIntegrationApi {
306307
* @param body AWS request object
307308
*/
308309
public deleteAWSAccount(
309-
body: AWSAccount,
310+
body: AWSAccountDeleteRequest,
310311
options?: Configuration
311312
): Observable<any> {
312313
const requestContextPromise = this.requestFactory.deleteAWSAccount(

packages/datadog-api-client-v1/types/PromiseAPI.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { Configuration } from "../configuration";
44
import { AWSAccount } from "../models/AWSAccount";
55
import { AWSAccountAndLambdaRequest } from "../models/AWSAccountAndLambdaRequest";
66
import { AWSAccountCreateResponse } from "../models/AWSAccountCreateResponse";
7+
import { AWSAccountDeleteRequest } from "../models/AWSAccountDeleteRequest";
78
import { AWSAccountListResponse } from "../models/AWSAccountListResponse";
89
import { AWSLogsAsyncResponse } from "../models/AWSLogsAsyncResponse";
910
import { AWSLogsListResponse } from "../models/AWSLogsListResponse";
@@ -214,7 +215,7 @@ export class PromiseAWSIntegrationApi {
214215
* @param body AWS request object
215216
*/
216217
public deleteAWSAccount(
217-
body: AWSAccount,
218+
body: AWSAccountDeleteRequest,
218219
options?: Configuration
219220
): Promise<any> {
220221
const result = this.api.deleteAWSAccount(body, options);

0 commit comments

Comments
 (0)