Skip to content

Commit 26eb797

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 041b29a of spec repo
1 parent 2c7b1a0 commit 26eb797

15 files changed

Lines changed: 1940 additions & 0 deletions

.generator/schemas/v2/openapi.yaml

Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2397,6 +2397,158 @@ components:
23972397
type: string
23982398
x-enum-varnames:
23992399
- CCM_CONFIG
2400+
AWSCcmConfigValidationIssue:
2401+
description: A single validation issue found while validating an AWS Cost and Usage Report (CUR) 2.0 configuration.
2402+
properties:
2403+
code:
2404+
$ref: "#/components/schemas/AWSCcmConfigValidationIssueCode"
2405+
description:
2406+
description: Human-readable description of the validation issue.
2407+
example: 'no CUR 2.0 export named "cost-and-usage-report" found'
2408+
type: string
2409+
required:
2410+
- code
2411+
- description
2412+
type: object
2413+
AWSCcmConfigValidationIssueCode:
2414+
description: Identifies the specific reason a Cost and Usage Report (CUR) 2.0 configuration failed validation.
2415+
enum:
2416+
- ISSUE_CODE_UNSPECIFIED
2417+
- CREDENTIAL_ERROR
2418+
- BUCKET_NAME_INVALID_GOVCLOUD
2419+
- S3_LIST_PERMISSION_MISSING
2420+
- S3_GET_PERMISSION_MISSING
2421+
- S3_BUCKET_REGION_MISMATCH
2422+
- S3_BUCKET_NOT_ACCESSIBLE
2423+
- EXPORT_LIST_PERMISSION_MISSING
2424+
- EXPORT_GET_PERMISSION_MISSING
2425+
- EXPORT_NOT_FOUND
2426+
- EXPORT_STATUS_UNHEALTHY
2427+
- TIME_GRANULARITY_INVALID
2428+
- FILE_FORMAT_INVALID
2429+
- INCLUDE_RESOURCES_DISABLED
2430+
- REFRESH_CADENCE_INVALID
2431+
- OVERWRITE_MODE_INVALID
2432+
- QUERY_STATEMENT_INVALID
2433+
example: "EXPORT_NOT_FOUND"
2434+
type: string
2435+
x-enum-varnames:
2436+
- ISSUE_CODE_UNSPECIFIED
2437+
- CREDENTIAL_ERROR
2438+
- BUCKET_NAME_INVALID_GOVCLOUD
2439+
- S3_LIST_PERMISSION_MISSING
2440+
- S3_GET_PERMISSION_MISSING
2441+
- S3_BUCKET_REGION_MISMATCH
2442+
- S3_BUCKET_NOT_ACCESSIBLE
2443+
- EXPORT_LIST_PERMISSION_MISSING
2444+
- EXPORT_GET_PERMISSION_MISSING
2445+
- EXPORT_NOT_FOUND
2446+
- EXPORT_STATUS_UNHEALTHY
2447+
- TIME_GRANULARITY_INVALID
2448+
- FILE_FORMAT_INVALID
2449+
- INCLUDE_RESOURCES_DISABLED
2450+
- REFRESH_CADENCE_INVALID
2451+
- OVERWRITE_MODE_INVALID
2452+
- QUERY_STATEMENT_INVALID
2453+
AWSCcmConfigValidationIssues:
2454+
description: List of validation issues found for the Cost and Usage Report (CUR) 2.0 configuration. Empty when the configuration is valid.
2455+
items:
2456+
$ref: "#/components/schemas/AWSCcmConfigValidationIssue"
2457+
type: array
2458+
AWSCcmConfigValidationRequest:
2459+
description: AWS CCM config validation request body.
2460+
properties:
2461+
data:
2462+
$ref: "#/components/schemas/AWSCcmConfigValidationRequestData"
2463+
required:
2464+
- data
2465+
type: object
2466+
AWSCcmConfigValidationRequestAttributes:
2467+
description: Attributes for an AWS CCM config validation request.
2468+
properties:
2469+
account_id:
2470+
description: Your AWS Account ID without dashes.
2471+
example: "123456789012"
2472+
type: string
2473+
bucket_name:
2474+
description: Name of the S3 bucket where the Cost and Usage Report is stored.
2475+
example: "billing"
2476+
type: string
2477+
bucket_region:
2478+
description: AWS region of the S3 bucket.
2479+
example: "us-east-1"
2480+
type: string
2481+
report_name:
2482+
description: Name of the Cost and Usage Report.
2483+
example: "cost-and-usage-report"
2484+
type: string
2485+
report_prefix:
2486+
description: S3 prefix where the Cost and Usage Report is stored.
2487+
example: "reports"
2488+
type: string
2489+
required:
2490+
- account_id
2491+
- bucket_name
2492+
- bucket_region
2493+
- report_name
2494+
type: object
2495+
AWSCcmConfigValidationRequestData:
2496+
description: AWS CCM config validation request data.
2497+
properties:
2498+
attributes:
2499+
$ref: "#/components/schemas/AWSCcmConfigValidationRequestAttributes"
2500+
type:
2501+
$ref: "#/components/schemas/AWSCcmConfigValidationType"
2502+
required:
2503+
- attributes
2504+
- type
2505+
type: object
2506+
AWSCcmConfigValidationResponse:
2507+
description: AWS CCM config validation response body.
2508+
properties:
2509+
data:
2510+
$ref: "#/components/schemas/AWSCcmConfigValidationResponseData"
2511+
required:
2512+
- data
2513+
type: object
2514+
AWSCcmConfigValidationResponseAttributes:
2515+
description: Attributes for an AWS CCM config validation response.
2516+
properties:
2517+
account_id:
2518+
description: Your AWS Account ID without dashes.
2519+
example: "123456789012"
2520+
type: string
2521+
issues:
2522+
$ref: "#/components/schemas/AWSCcmConfigValidationIssues"
2523+
required:
2524+
- account_id
2525+
- issues
2526+
type: object
2527+
AWSCcmConfigValidationResponseData:
2528+
description: AWS CCM config validation response data.
2529+
properties:
2530+
attributes:
2531+
$ref: "#/components/schemas/AWSCcmConfigValidationResponseAttributes"
2532+
id:
2533+
description: AWS CCM config validation resource identifier.
2534+
example: "ccm_config_validation"
2535+
type: string
2536+
type:
2537+
$ref: "#/components/schemas/AWSCcmConfigValidationType"
2538+
required:
2539+
- attributes
2540+
- id
2541+
- type
2542+
type: object
2543+
AWSCcmConfigValidationType:
2544+
default: "ccm_config_validation"
2545+
description: AWS CCM config validation resource type.
2546+
enum:
2547+
- ccm_config_validation
2548+
example: "ccm_config_validation"
2549+
type: string
2550+
x-enum-varnames:
2551+
- CCM_CONFIG_VALIDATION
24002552
AWSCloudAuthPersonaMappingAttributesResponse:
24012553
description: Attributes for AWS cloud authentication persona mapping response
24022554
properties:
@@ -116331,6 +116483,76 @@ paths:
116331116483
operator: OR
116332116484
permissions:
116333116485
- aws_configuration_read
116486+
/api/v2/integration/aws/validate_ccm_config:
116487+
post:
116488+
description: |-
116489+
Validate a Cloud Cost Management config for an AWS account using Cost and Usage Report
116490+
(CUR) 2.0 against Datadog's ingest requirements without persisting it.
116491+
operationId: ValidateAWSCCMConfig
116492+
requestBody:
116493+
content:
116494+
application/json:
116495+
examples:
116496+
default:
116497+
value:
116498+
data:
116499+
attributes:
116500+
account_id: "123456789012"
116501+
bucket_name: billing
116502+
bucket_region: us-east-1
116503+
report_name: cost-and-usage-report
116504+
report_prefix: reports
116505+
type: ccm_config_validation
116506+
schema:
116507+
$ref: "#/components/schemas/AWSCcmConfigValidationRequest"
116508+
description: Validate a Cloud Cost Management config for an AWS account integration config.
116509+
required: true
116510+
responses:
116511+
"200":
116512+
content:
116513+
application/json:
116514+
examples:
116515+
default:
116516+
value:
116517+
data:
116518+
attributes:
116519+
account_id: "123456789012"
116520+
issues:
116521+
- code: EXPORT_NOT_FOUND
116522+
description: 'no CUR 2.0 export named "cost-and-usage-report" found'
116523+
id: ccm_config_validation
116524+
type: ccm_config_validation
116525+
schema:
116526+
$ref: "#/components/schemas/AWSCcmConfigValidationResponse"
116527+
description: AWS CCM Config validation result
116528+
"400":
116529+
content:
116530+
application/json:
116531+
schema:
116532+
$ref: "#/components/schemas/JSONAPIErrorResponse"
116533+
description: Bad Request
116534+
"403":
116535+
$ref: "#/components/responses/ForbiddenResponse"
116536+
"429":
116537+
$ref: "#/components/responses/TooManyRequestsResponse"
116538+
"503":
116539+
content:
116540+
application/json:
116541+
schema:
116542+
$ref: "#/components/schemas/JSONAPIErrorResponse"
116543+
description: Service Unavailable
116544+
summary: Validate AWS CCM config
116545+
tags:
116546+
- AWS Integration
116547+
x-codegen-request-body-name: body
116548+
"x-permission":
116549+
operator: OR
116550+
permissions:
116551+
- cloud_cost_management_read
116552+
- cloud_cost_management_write
116553+
x-unstable: |-
116554+
**Note**: This endpoint is in Preview and may be subject to change.
116555+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
116334116556
/api/v2/integration/gcp/accounts:
116335116557
get:
116336116558
description: List all GCP STS-enabled service accounts configured in your Datadog account.
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
// Validate AWS CCM config returns "AWS CCM Config validation result" response
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.ApiException;
5+
import com.datadog.api.client.v2.api.AwsIntegrationApi;
6+
import com.datadog.api.client.v2.model.AWSCcmConfigValidationRequest;
7+
import com.datadog.api.client.v2.model.AWSCcmConfigValidationRequestAttributes;
8+
import com.datadog.api.client.v2.model.AWSCcmConfigValidationRequestData;
9+
import com.datadog.api.client.v2.model.AWSCcmConfigValidationResponse;
10+
import com.datadog.api.client.v2.model.AWSCcmConfigValidationType;
11+
12+
public class Example {
13+
public static void main(String[] args) {
14+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
15+
defaultClient.setUnstableOperationEnabled("v2.validateAWSCCMConfig", true);
16+
AwsIntegrationApi apiInstance = new AwsIntegrationApi(defaultClient);
17+
18+
AWSCcmConfigValidationRequest body =
19+
new AWSCcmConfigValidationRequest()
20+
.data(
21+
new AWSCcmConfigValidationRequestData()
22+
.attributes(
23+
new AWSCcmConfigValidationRequestAttributes()
24+
.accountId("123456789012")
25+
.bucketName("billing")
26+
.bucketRegion("us-east-1")
27+
.reportName("cost-and-usage-report")
28+
.reportPrefix("reports"))
29+
.type(AWSCcmConfigValidationType.CCM_CONFIG_VALIDATION));
30+
31+
try {
32+
AWSCcmConfigValidationResponse result = apiInstance.validateAWSCCMConfig(body);
33+
System.out.println(result);
34+
} catch (ApiException e) {
35+
System.err.println("Exception when calling AwsIntegrationApi#validateAWSCCMConfig");
36+
System.err.println("Status code: " + e.getCode());
37+
System.err.println("Reason: " + e.getResponseBody());
38+
System.err.println("Response headers: " + e.getResponseHeaders());
39+
e.printStackTrace();
40+
}
41+
}
42+
}

src/main/java/com/datadog/api/client/ApiClient.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1003,6 +1003,7 @@ public class ApiClient {
10031003
put("v2.deleteAWSAccountCCMConfig", false);
10041004
put("v2.getAWSAccountCCMConfig", false);
10051005
put("v2.updateAWSAccountCCMConfig", false);
1006+
put("v2.validateAWSCCMConfig", false);
10061007
put("v2.createJiraIssueTemplate", false);
10071008
put("v2.deleteJiraAccount", false);
10081009
put("v2.deleteJiraIssueTemplate", false);

0 commit comments

Comments
 (0)