Skip to content

Commit a88706d

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit dfb87dda of spec repo
1 parent 695e2ac commit a88706d

25 files changed

+1225
-26
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.6.6",
7-
"regenerated": "2023-10-25 13:57:28.981603",
8-
"spec_repo_commit": "fb2f4134"
7+
"regenerated": "2023-10-25 15:28:57.018259",
8+
"spec_repo_commit": "dfb87dda"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2023-10-25 13:57:28.995815",
13-
"spec_repo_commit": "fb2f4134"
12+
"regenerated": "2023-10-25 15:28:57.031907",
13+
"spec_repo_commit": "dfb87dda"
1414
}
1515
}
1616
}

.generator/schemas/v1/openapi.yaml

Lines changed: 238 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ components:
5656
type: string
5757
account_id:
5858
description: Your AWS Account ID without dashes.
59-
example: '1234567'
59+
example: '123456789012'
6060
type: string
6161
account_specific_namespace_rules:
6262
additionalProperties:
@@ -80,7 +80,9 @@ components:
8080
example: true
8181
type: boolean
8282
excluded_regions:
83-
description: An array of AWS regions to exclude from metrics collection.
83+
description: 'An array of [AWS regions](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints)
84+
85+
to exclude from metrics collection.'
8486
example:
8587
- us-east-1
8688
- us-west-2
@@ -116,7 +118,7 @@ components:
116118
example:
117119
- $KEY:$VALUE
118120
items:
119-
description: The list of the the host_tags.
121+
description: The list of the host_tags.
120122
type: string
121123
type: array
122124
metrics_collection_enabled:
@@ -171,7 +173,7 @@ components:
171173
type: string
172174
account_id:
173175
description: Your AWS Account ID without dashes.
174-
example: '1234567'
176+
example: '123456789012'
175177
type: string
176178
role_name:
177179
description: Your Datadog role delegation name.
@@ -187,6 +189,136 @@ components:
187189
$ref: '#/components/schemas/AWSAccount'
188190
type: array
189191
type: object
192+
AWSEventBridgeAccountConfiguration:
193+
description: The EventBridge configuration for one AWS account.
194+
properties:
195+
accountId:
196+
description: Your AWS Account ID without dashes.
197+
example: '123456789012'
198+
type: string
199+
eventHubs:
200+
description: Array of AWS event sources associated with this account.
201+
items:
202+
$ref: '#/components/schemas/AWSEventBridgeSource'
203+
type: array
204+
tags:
205+
description: 'Array of tags (in the form `key:value`) which are added to
206+
all hosts
207+
208+
and metrics reporting through the main AWS integration.'
209+
example:
210+
- $KEY:$VALUE
211+
items:
212+
description: The list of the host_tags.
213+
type: string
214+
type: array
215+
type: object
216+
AWSEventBridgeCreateRequest:
217+
description: An object used to create an EventBridge source.
218+
properties:
219+
account_id:
220+
description: Your AWS Account ID without dashes.
221+
example: '123456789012'
222+
type: string
223+
create_event_bus:
224+
description: 'True if Datadog should create the event bus in addition to
225+
the event
226+
227+
source. Requires the `events:CreateEventBus` permission.'
228+
example: true
229+
type: boolean
230+
event_generator_name:
231+
description: 'The given part of the event source name, which is then combined
232+
with an
233+
234+
assigned suffix to form the full name.'
235+
example: app-alerts
236+
type: string
237+
region:
238+
description: The event source's [AWS region](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints).
239+
example: us-east-1
240+
type: string
241+
type: object
242+
AWSEventBridgeCreateResponse:
243+
description: A created EventBridge source.
244+
properties:
245+
event_source_name:
246+
description: The event source name.
247+
example: app-alerts-zyxw3210
248+
type: string
249+
has_bus:
250+
description: True if the event bus was created in addition to the source.
251+
example: true
252+
type: boolean
253+
region:
254+
description: The event source's [AWS region](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints).
255+
example: us-east-1
256+
type: string
257+
status:
258+
$ref: '#/components/schemas/AWSEventBridgeCreateStatus'
259+
type: object
260+
AWSEventBridgeCreateStatus:
261+
description: The event source status "created".
262+
enum:
263+
- created
264+
example: created
265+
type: string
266+
x-enum-varnames:
267+
- CREATED
268+
AWSEventBridgeDeleteRequest:
269+
description: An object used to delete an EventBridge source.
270+
properties:
271+
account_id:
272+
description: Your AWS Account ID without dashes.
273+
example: '123456789012'
274+
type: string
275+
event_generator_name:
276+
description: The event source name.
277+
example: app-alerts-zyxw3210
278+
type: string
279+
region:
280+
description: The event source's [AWS region](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints).
281+
example: us-east-1
282+
type: string
283+
type: object
284+
AWSEventBridgeDeleteResponse:
285+
description: An indicator of the successful deletion of an EventBridge source.
286+
properties:
287+
status:
288+
$ref: '#/components/schemas/AWSEventBridgeDeleteStatus'
289+
type: object
290+
AWSEventBridgeDeleteStatus:
291+
description: The event source status "empty".
292+
enum:
293+
- empty
294+
example: empty
295+
type: string
296+
x-enum-varnames:
297+
- EMPTY
298+
AWSEventBridgeListResponse:
299+
description: An object describing the EventBridge configuration for multiple
300+
accounts.
301+
properties:
302+
accounts:
303+
description: List of accounts with their event sources.
304+
items:
305+
$ref: '#/components/schemas/AWSEventBridgeAccountConfiguration'
306+
type: array
307+
isInstalled:
308+
description: True if the EventBridge sub-integration is enabled for your
309+
organization.
310+
type: boolean
311+
type: object
312+
AWSEventBridgeSource:
313+
description: An EventBridge source.
314+
properties:
315+
name:
316+
description: The event source name.
317+
type: string
318+
region:
319+
description: The event source's [AWS region](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints).
320+
type: string
321+
type: object
190322
AWSLogsAsyncError:
191323
description: Description of errors.
192324
properties:
@@ -323,7 +455,7 @@ components:
323455
properties:
324456
account_id:
325457
description: Your AWS Account ID without dashes.
326-
example: '1234567'
458+
example: '123456789012'
327459
type: string
328460
namespace:
329461
$ref: '#/components/schemas/AWSNamespace'
@@ -23392,6 +23524,107 @@ paths:
2339223524
summary: List namespace rules
2339323525
tags:
2339423526
- AWS Integration
23527+
/api/v1/integration/aws/event_bridge:
23528+
delete:
23529+
description: Delete an Amazon EventBridge source.
23530+
operationId: DeleteAWSEventBridgeSource
23531+
requestBody:
23532+
content:
23533+
application/json:
23534+
schema:
23535+
$ref: '#/components/schemas/AWSEventBridgeDeleteRequest'
23536+
description: Delete the Amazon EventBridge source with the given name, region,
23537+
and associated AWS account.
23538+
required: true
23539+
responses:
23540+
'200':
23541+
content:
23542+
application/json:
23543+
schema:
23544+
$ref: '#/components/schemas/AWSEventBridgeDeleteResponse'
23545+
description: OK
23546+
'400':
23547+
content:
23548+
application/json:
23549+
schema:
23550+
$ref: '#/components/schemas/APIErrorResponse'
23551+
description: Bad Request
23552+
'403':
23553+
content:
23554+
application/json:
23555+
schema:
23556+
$ref: '#/components/schemas/APIErrorResponse'
23557+
description: Authentication Error
23558+
'429':
23559+
$ref: '#/components/responses/TooManyRequestsResponse'
23560+
summary: Delete an Amazon EventBridge source
23561+
tags:
23562+
- AWS Integration
23563+
x-codegen-request-body-name: body
23564+
get:
23565+
description: Get all Amazon EventBridge sources.
23566+
operationId: ListAWSEventBridgeSources
23567+
parameters: []
23568+
responses:
23569+
'200':
23570+
content:
23571+
application/json:
23572+
schema:
23573+
$ref: '#/components/schemas/AWSEventBridgeListResponse'
23574+
description: OK
23575+
'400':
23576+
content:
23577+
application/json:
23578+
schema:
23579+
$ref: '#/components/schemas/APIErrorResponse'
23580+
description: Bad Request
23581+
'403':
23582+
content:
23583+
application/json:
23584+
schema:
23585+
$ref: '#/components/schemas/APIErrorResponse'
23586+
description: Authentication Error
23587+
'429':
23588+
$ref: '#/components/responses/TooManyRequestsResponse'
23589+
summary: Get all Amazon EventBridge sources
23590+
tags:
23591+
- AWS Integration
23592+
post:
23593+
description: Create an Amazon EventBridge source.
23594+
operationId: CreateAWSEventBridgeSource
23595+
requestBody:
23596+
content:
23597+
application/json:
23598+
schema:
23599+
$ref: '#/components/schemas/AWSEventBridgeCreateRequest'
23600+
description: Create an Amazon EventBridge source for an AWS account with a
23601+
given name and region.
23602+
required: true
23603+
responses:
23604+
'200':
23605+
content:
23606+
application/json:
23607+
schema:
23608+
$ref: '#/components/schemas/AWSEventBridgeCreateResponse'
23609+
description: OK
23610+
'400':
23611+
content:
23612+
application/json:
23613+
schema:
23614+
$ref: '#/components/schemas/APIErrorResponse'
23615+
description: Bad Request
23616+
'403':
23617+
content:
23618+
application/json:
23619+
schema:
23620+
$ref: '#/components/schemas/APIErrorResponse'
23621+
description: Authentication Error
23622+
'429':
23623+
$ref: '#/components/responses/TooManyRequestsResponse'
23624+
summary: Create an Amazon EventBridge source
23625+
tags:
23626+
- AWS Integration
23627+
x-codegen-request-body-name: body
2339523628
/api/v1/integration/aws/filtering:
2339623629
delete:
2339723630
description: Delete a tag filtering entry.

examples/v1/aws-integration/CreateAWSAccount.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const apiInstance = new v1.AWSIntegrationApi(configuration);
99

1010
const params: v1.AWSIntegrationApiCreateAWSAccountRequest = {
1111
body: {
12-
accountId: "1234567",
12+
accountId: "123456789012",
1313
accountSpecificNamespaceRules: {
1414
auto_scaling: false,
1515
opswork: false,
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/**
2+
* Create an Amazon EventBridge source returns "OK" response
3+
*/
4+
5+
import { client, v1 } from "@datadog/datadog-api-client";
6+
7+
const configuration = client.createConfiguration();
8+
const apiInstance = new v1.AWSIntegrationApi(configuration);
9+
10+
const params: v1.AWSIntegrationApiCreateAWSEventBridgeSourceRequest = {
11+
body: {
12+
accountId: "123456789012",
13+
createEventBus: true,
14+
eventGeneratorName: "app-alerts",
15+
region: "us-east-1",
16+
},
17+
};
18+
19+
apiInstance
20+
.createAWSEventBridgeSource(params)
21+
.then((data: v1.AWSEventBridgeCreateResponse) => {
22+
console.log(
23+
"API called successfully. Returned data: " + JSON.stringify(data)
24+
);
25+
})
26+
.catch((error: any) => console.error(error));

examples/v1/aws-integration/CreateAWSTagFilter.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const apiInstance = new v1.AWSIntegrationApi(configuration);
99

1010
const params: v1.AWSIntegrationApiCreateAWSTagFilterRequest = {
1111
body: {
12-
accountId: "1234567",
12+
accountId: "123456789012",
1313
namespace: "elb",
1414
tagFilterStr: "prod*",
1515
},

examples/v1/aws-integration/CreateNewAWSExternalID.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const apiInstance = new v1.AWSIntegrationApi(configuration);
99

1010
const params: v1.AWSIntegrationApiCreateNewAWSExternalIDRequest = {
1111
body: {
12-
accountId: "1234567",
12+
accountId: "123456789012",
1313
accountSpecificNamespaceRules: {
1414
auto_scaling: false,
1515
opswork: false,

examples/v1/aws-integration/DeleteAWSAccount.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const apiInstance = new v1.AWSIntegrationApi(configuration);
99

1010
const params: v1.AWSIntegrationApiDeleteAWSAccountRequest = {
1111
body: {
12-
accountId: "1234567",
12+
accountId: "123456789012",
1313
roleName: "DatadogAWSIntegrationRole",
1414
},
1515
};
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/**
2+
* Delete an Amazon EventBridge source returns "OK" response
3+
*/
4+
5+
import { client, v1 } from "@datadog/datadog-api-client";
6+
7+
const configuration = client.createConfiguration();
8+
const apiInstance = new v1.AWSIntegrationApi(configuration);
9+
10+
const params: v1.AWSIntegrationApiDeleteAWSEventBridgeSourceRequest = {
11+
body: {
12+
accountId: "123456789012",
13+
eventGeneratorName: "app-alerts-zyxw3210",
14+
region: "us-east-1",
15+
},
16+
};
17+
18+
apiInstance
19+
.deleteAWSEventBridgeSource(params)
20+
.then((data: v1.AWSEventBridgeDeleteResponse) => {
21+
console.log(
22+
"API called successfully. Returned data: " + JSON.stringify(data)
23+
);
24+
})
25+
.catch((error: any) => console.error(error));

0 commit comments

Comments
 (0)