Skip to content

Commit b1ee419

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit cc70a77 of spec repo
1 parent 94e5072 commit b1ee419

File tree

38 files changed

+1408
-0
lines changed

38 files changed

+1408
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 248 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1761,6 +1761,82 @@ components:
17611761
required:
17621762
- role_name
17631763
type: object
1764+
AWSCcmConfig:
1765+
description: AWS Cloud Cost Management config.
1766+
properties:
1767+
data_export_configs:
1768+
description: List of data export configurations for Cost and Usage Reports.
1769+
items:
1770+
$ref: '#/components/schemas/DataExportConfig'
1771+
type: array
1772+
required:
1773+
- data_export_configs
1774+
type: object
1775+
AWSCcmConfigRequest:
1776+
description: AWS CCM Config Create/Update Request body.
1777+
properties:
1778+
data:
1779+
$ref: '#/components/schemas/AWSCcmConfigRequestData'
1780+
required:
1781+
- data
1782+
type: object
1783+
AWSCcmConfigRequestAttributes:
1784+
description: AWS CCM Config attributes for Create/Update requests.
1785+
properties:
1786+
ccm_config:
1787+
$ref: '#/components/schemas/AWSCcmConfig'
1788+
required:
1789+
- ccm_config
1790+
type: object
1791+
AWSCcmConfigRequestData:
1792+
description: AWS CCM Config Create/Update Request data.
1793+
properties:
1794+
attributes:
1795+
$ref: '#/components/schemas/AWSCcmConfigRequestAttributes'
1796+
type:
1797+
$ref: '#/components/schemas/AWSCcmConfigType'
1798+
required:
1799+
- attributes
1800+
- type
1801+
type: object
1802+
AWSCcmConfigResponse:
1803+
description: AWS CCM Config response body.
1804+
properties:
1805+
data:
1806+
$ref: '#/components/schemas/AWSCcmConfigResponseData'
1807+
required:
1808+
- data
1809+
type: object
1810+
AWSCcmConfigResponseAttributes:
1811+
description: AWS CCM Config response attributes.
1812+
properties:
1813+
data_export_configs:
1814+
description: List of data export configurations for Cost and Usage Reports.
1815+
items:
1816+
$ref: '#/components/schemas/DataExportConfig'
1817+
type: array
1818+
type: object
1819+
AWSCcmConfigResponseData:
1820+
description: AWS CCM Config response data.
1821+
properties:
1822+
attributes:
1823+
$ref: '#/components/schemas/AWSCcmConfigResponseAttributes'
1824+
id:
1825+
$ref: '#/components/schemas/AWSAccountConfigID'
1826+
type:
1827+
$ref: '#/components/schemas/AWSCcmConfigType'
1828+
required:
1829+
- type
1830+
type: object
1831+
AWSCcmConfigType:
1832+
default: ccm_config
1833+
description: AWS CCM Config resource type.
1834+
enum:
1835+
- ccm_config
1836+
example: ccm_config
1837+
type: string
1838+
x-enum-varnames:
1839+
- CCM_CONFIG
17641840
AWSCredentials:
17651841
description: The definition of `AWSCredentials` object.
17661842
oneOf:
@@ -16811,6 +16887,37 @@ components:
1681116887
example: canceled
1681216888
type: string
1681316889
type: object
16890+
DataExportConfig:
16891+
description: AWS Cost and Usage Report data export configuration.
16892+
properties:
16893+
bucket_name:
16894+
description: Name of the S3 bucket where the Cost and Usage Report is stored.
16895+
example: billing
16896+
type: string
16897+
bucket_region:
16898+
description: AWS region of the S3 bucket.
16899+
example: us-east-1
16900+
type: string
16901+
report_name:
16902+
description: Name of the Cost and Usage Report.
16903+
example: cost-and-usage-report
16904+
type: string
16905+
report_prefix:
16906+
description: S3 prefix where the Cost and Usage Report is stored.
16907+
example: reports
16908+
type: string
16909+
report_type:
16910+
description: Type of the Cost and Usage Report. Currently only `CUR2.0`
16911+
is supported.
16912+
example: CUR2.0
16913+
type: string
16914+
required:
16915+
- report_name
16916+
- report_prefix
16917+
- report_type
16918+
- bucket_name
16919+
- bucket_region
16920+
type: object
1681416921
DataRelationshipsTeams:
1681516922
description: Associates teams with this schedule in a data structure.
1681616923
properties:
@@ -72421,6 +72528,147 @@ paths:
7242172528
operator: OR
7242272529
permissions:
7242372530
- aws_configuration_edit
72531+
/api/v2/integration/aws/accounts/{aws_account_config_id}/ccm_config:
72532+
delete:
72533+
description: 'Delete the Cloud Cost Management config for an AWS Account Integration
72534+
Config using Cost and Usage Report
72535+
72536+
(CUR) 2.0 by config ID.'
72537+
operationId: DeleteAWSAccountCCMConfig
72538+
parameters:
72539+
- $ref: '#/components/parameters/AWSAccountConfigIDPathParameter'
72540+
responses:
72541+
'204':
72542+
description: No Content.
72543+
'403':
72544+
$ref: '#/components/responses/ForbiddenResponse'
72545+
'404':
72546+
$ref: '#/components/responses/NotFoundResponse'
72547+
'429':
72548+
$ref: '#/components/responses/TooManyRequestsResponse'
72549+
summary: Delete AWS CCM config
72550+
tags:
72551+
- AWS Integration
72552+
x-permission:
72553+
operator: OR
72554+
permissions:
72555+
- aws_configuration_edit
72556+
x-unstable: '**Note**: This endpoint is in preview and may be subject to change.
72557+
72558+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
72559+
get:
72560+
description: 'Get the Cloud Cost Management config for an AWS Account Integration
72561+
Config using Cost and Usage Report
72562+
72563+
(CUR) 2.0 by config ID.'
72564+
operationId: GetAWSAccountCCMConfig
72565+
parameters:
72566+
- $ref: '#/components/parameters/AWSAccountConfigIDPathParameter'
72567+
responses:
72568+
'200':
72569+
content:
72570+
application/json:
72571+
schema:
72572+
$ref: '#/components/schemas/AWSCcmConfigResponse'
72573+
description: AWS CCM Config object.
72574+
'403':
72575+
$ref: '#/components/responses/ForbiddenResponse'
72576+
'404':
72577+
$ref: '#/components/responses/NotFoundResponse'
72578+
'429':
72579+
$ref: '#/components/responses/TooManyRequestsResponse'
72580+
summary: Get AWS CCM config
72581+
tags:
72582+
- AWS Integration
72583+
x-permission:
72584+
operator: OR
72585+
permissions:
72586+
- aws_configuration_read
72587+
x-unstable: '**Note**: This endpoint is in preview and may be subject to change.
72588+
72589+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
72590+
patch:
72591+
description: 'Update the Cloud Cost Management config for an AWS Account Integration
72592+
Config using Cost and Usage Report
72593+
72594+
(CUR) 2.0 by config ID.'
72595+
operationId: UpdateAWSAccountCCMConfig
72596+
parameters:
72597+
- $ref: '#/components/parameters/AWSAccountConfigIDPathParameter'
72598+
requestBody:
72599+
content:
72600+
application/json:
72601+
schema:
72602+
$ref: '#/components/schemas/AWSCcmConfigRequest'
72603+
description: Update a Cloud Cost Management config for an AWS Account Integration
72604+
Config.
72605+
required: true
72606+
responses:
72607+
'200':
72608+
content:
72609+
application/json:
72610+
schema:
72611+
$ref: '#/components/schemas/AWSCcmConfigResponse'
72612+
description: AWS CCM Config object.
72613+
'403':
72614+
$ref: '#/components/responses/ForbiddenResponse'
72615+
'404':
72616+
$ref: '#/components/responses/NotFoundResponse'
72617+
'429':
72618+
$ref: '#/components/responses/TooManyRequestsResponse'
72619+
summary: Update AWS CCM config
72620+
tags:
72621+
- AWS Integration
72622+
x-codegen-request-body-name: body
72623+
x-permission:
72624+
operator: OR
72625+
permissions:
72626+
- aws_configuration_edit
72627+
x-unstable: '**Note**: This endpoint is in preview and may be subject to change.
72628+
72629+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
72630+
post:
72631+
description: 'Create the Cloud Cost Management config for an AWS Account Integration
72632+
Config using Cost and Usage Report
72633+
72634+
(CUR) 2.0 by config ID.'
72635+
operationId: CreateAWSAccountCCMConfig
72636+
parameters:
72637+
- $ref: '#/components/parameters/AWSAccountConfigIDPathParameter'
72638+
requestBody:
72639+
content:
72640+
application/json:
72641+
schema:
72642+
$ref: '#/components/schemas/AWSCcmConfigRequest'
72643+
description: Create a Cloud Cost Management config for an AWS Account Integration
72644+
Config.
72645+
required: true
72646+
responses:
72647+
'200':
72648+
content:
72649+
application/json:
72650+
schema:
72651+
$ref: '#/components/schemas/AWSCcmConfigResponse'
72652+
description: AWS CCM Config object.
72653+
'403':
72654+
$ref: '#/components/responses/ForbiddenResponse'
72655+
'404':
72656+
$ref: '#/components/responses/NotFoundResponse'
72657+
'409':
72658+
$ref: '#/components/responses/ConflictResponse'
72659+
'429':
72660+
$ref: '#/components/responses/TooManyRequestsResponse'
72661+
summary: Create AWS CCM config
72662+
tags:
72663+
- AWS Integration
72664+
x-codegen-request-body-name: body
72665+
x-permission:
72666+
operator: OR
72667+
permissions:
72668+
- aws_configuration_edit
72669+
x-unstable: '**Note**: This endpoint is in preview and may be subject to change.
72670+
72671+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
7242472672
/api/v2/integration/aws/available_namespaces:
7242572673
get:
7242672674
description: Get a list of available AWS CloudWatch namespaces that can send

docs/datadog_api_client.v2.model.rst

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1712,6 +1712,62 @@ datadog\_api\_client.v2.model.aws\_auth\_config\_role module
17121712
:members:
17131713
:show-inheritance:
17141714

1715+
datadog\_api\_client.v2.model.aws\_ccm\_config module
1716+
-----------------------------------------------------
1717+
1718+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config
1719+
:members:
1720+
:show-inheritance:
1721+
1722+
datadog\_api\_client.v2.model.aws\_ccm\_config\_request module
1723+
--------------------------------------------------------------
1724+
1725+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_request
1726+
:members:
1727+
:show-inheritance:
1728+
1729+
datadog\_api\_client.v2.model.aws\_ccm\_config\_request\_attributes module
1730+
--------------------------------------------------------------------------
1731+
1732+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_request_attributes
1733+
:members:
1734+
:show-inheritance:
1735+
1736+
datadog\_api\_client.v2.model.aws\_ccm\_config\_request\_data module
1737+
--------------------------------------------------------------------
1738+
1739+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_request_data
1740+
:members:
1741+
:show-inheritance:
1742+
1743+
datadog\_api\_client.v2.model.aws\_ccm\_config\_response module
1744+
---------------------------------------------------------------
1745+
1746+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_response
1747+
:members:
1748+
:show-inheritance:
1749+
1750+
datadog\_api\_client.v2.model.aws\_ccm\_config\_response\_attributes module
1751+
---------------------------------------------------------------------------
1752+
1753+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_response_attributes
1754+
:members:
1755+
:show-inheritance:
1756+
1757+
datadog\_api\_client.v2.model.aws\_ccm\_config\_response\_data module
1758+
---------------------------------------------------------------------
1759+
1760+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_response_data
1761+
:members:
1762+
:show-inheritance:
1763+
1764+
datadog\_api\_client.v2.model.aws\_ccm\_config\_type module
1765+
-----------------------------------------------------------
1766+
1767+
.. automodule:: datadog_api_client.v2.model.aws_ccm_config_type
1768+
:members:
1769+
:show-inheritance:
1770+
17151771
datadog\_api\_client.v2.model.aws\_credentials module
17161772
-----------------------------------------------------
17171773

@@ -6591,6 +6647,13 @@ datadog\_api\_client.v2.model.data\_deletion\_response\_meta module
65916647
:members:
65926648
:show-inheritance:
65936649

6650+
datadog\_api\_client.v2.model.data\_export\_config module
6651+
---------------------------------------------------------
6652+
6653+
.. automodule:: datadog_api_client.v2.model.data_export_config
6654+
:members:
6655+
:show-inheritance:
6656+
65946657
datadog\_api\_client.v2.model.data\_relationships\_teams module
65956658
---------------------------------------------------------------
65966659

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
"""
2+
Create AWS CCM config returns "AWS CCM Config object." response
3+
"""
4+
5+
from datadog_api_client import ApiClient, Configuration
6+
from datadog_api_client.v2.api.aws_integration_api import AWSIntegrationApi
7+
from datadog_api_client.v2.model.aws_ccm_config import AWSCcmConfig
8+
from datadog_api_client.v2.model.aws_ccm_config_request import AWSCcmConfigRequest
9+
from datadog_api_client.v2.model.aws_ccm_config_request_attributes import AWSCcmConfigRequestAttributes
10+
from datadog_api_client.v2.model.aws_ccm_config_request_data import AWSCcmConfigRequestData
11+
from datadog_api_client.v2.model.aws_ccm_config_type import AWSCcmConfigType
12+
from datadog_api_client.v2.model.data_export_config import DataExportConfig
13+
14+
body = AWSCcmConfigRequest(
15+
data=AWSCcmConfigRequestData(
16+
attributes=AWSCcmConfigRequestAttributes(
17+
ccm_config=AWSCcmConfig(
18+
data_export_configs=[
19+
DataExportConfig(
20+
bucket_name="billing",
21+
bucket_region="us-east-1",
22+
report_name="cost-and-usage-report",
23+
report_prefix="reports",
24+
report_type="CUR2.0",
25+
),
26+
],
27+
),
28+
),
29+
type=AWSCcmConfigType.CCM_CONFIG,
30+
),
31+
)
32+
33+
configuration = Configuration()
34+
configuration.unstable_operations["create_aws_account_ccm_config"] = True
35+
with ApiClient(configuration) as api_client:
36+
api_instance = AWSIntegrationApi(api_client)
37+
response = api_instance.create_aws_account_ccm_config(aws_account_config_id="aws_account_config_id", body=body)
38+
39+
print(response)

0 commit comments

Comments
 (0)