Skip to content

Commit 1d45c39

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 3d40628 of spec repo
1 parent 6a05bef commit 1d45c39

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
@@ -2437,6 +2437,158 @@ components:
24372437
type: string
24382438
x-enum-varnames:
24392439
- CCM_CONFIG
2440+
AWSCcmConfigValidationIssue:
2441+
description: A single validation issue found while validating an AWS Cost and Usage Report (CUR) 2.0 configuration.
2442+
properties:
2443+
code:
2444+
$ref: "#/components/schemas/AWSCcmConfigValidationIssueCode"
2445+
description:
2446+
description: Human-readable description of the validation issue.
2447+
example: 'no CUR 2.0 export named "cost-and-usage-report" found'
2448+
type: string
2449+
required:
2450+
- code
2451+
- description
2452+
type: object
2453+
AWSCcmConfigValidationIssueCode:
2454+
description: Identifies the specific reason a Cost and Usage Report (CUR) 2.0 configuration failed validation.
2455+
enum:
2456+
- ISSUE_CODE_UNSPECIFIED
2457+
- CREDENTIAL_ERROR
2458+
- BUCKET_NAME_INVALID_GOVCLOUD
2459+
- S3_LIST_PERMISSION_MISSING
2460+
- S3_GET_PERMISSION_MISSING
2461+
- S3_BUCKET_REGION_MISMATCH
2462+
- S3_BUCKET_NOT_ACCESSIBLE
2463+
- EXPORT_LIST_PERMISSION_MISSING
2464+
- EXPORT_GET_PERMISSION_MISSING
2465+
- EXPORT_NOT_FOUND
2466+
- EXPORT_STATUS_UNHEALTHY
2467+
- TIME_GRANULARITY_INVALID
2468+
- FILE_FORMAT_INVALID
2469+
- INCLUDE_RESOURCES_DISABLED
2470+
- REFRESH_CADENCE_INVALID
2471+
- OVERWRITE_MODE_INVALID
2472+
- QUERY_STATEMENT_INVALID
2473+
example: "EXPORT_NOT_FOUND"
2474+
type: string
2475+
x-enum-varnames:
2476+
- ISSUE_CODE_UNSPECIFIED
2477+
- CREDENTIAL_ERROR
2478+
- BUCKET_NAME_INVALID_GOVCLOUD
2479+
- S3_LIST_PERMISSION_MISSING
2480+
- S3_GET_PERMISSION_MISSING
2481+
- S3_BUCKET_REGION_MISMATCH
2482+
- S3_BUCKET_NOT_ACCESSIBLE
2483+
- EXPORT_LIST_PERMISSION_MISSING
2484+
- EXPORT_GET_PERMISSION_MISSING
2485+
- EXPORT_NOT_FOUND
2486+
- EXPORT_STATUS_UNHEALTHY
2487+
- TIME_GRANULARITY_INVALID
2488+
- FILE_FORMAT_INVALID
2489+
- INCLUDE_RESOURCES_DISABLED
2490+
- REFRESH_CADENCE_INVALID
2491+
- OVERWRITE_MODE_INVALID
2492+
- QUERY_STATEMENT_INVALID
2493+
AWSCcmConfigValidationIssues:
2494+
description: List of validation issues found for the Cost and Usage Report (CUR) 2.0 configuration. Empty when the configuration is valid.
2495+
items:
2496+
$ref: "#/components/schemas/AWSCcmConfigValidationIssue"
2497+
type: array
2498+
AWSCcmConfigValidationRequest:
2499+
description: AWS CCM config validation request body.
2500+
properties:
2501+
data:
2502+
$ref: "#/components/schemas/AWSCcmConfigValidationRequestData"
2503+
required:
2504+
- data
2505+
type: object
2506+
AWSCcmConfigValidationRequestAttributes:
2507+
description: Attributes for an AWS CCM config validation request.
2508+
properties:
2509+
account_id:
2510+
description: Your AWS Account ID without dashes.
2511+
example: "123456789012"
2512+
type: string
2513+
bucket_name:
2514+
description: Name of the S3 bucket where the Cost and Usage Report is stored.
2515+
example: "billing"
2516+
type: string
2517+
bucket_region:
2518+
description: AWS region of the S3 bucket.
2519+
example: "us-east-1"
2520+
type: string
2521+
report_name:
2522+
description: Name of the Cost and Usage Report.
2523+
example: "cost-and-usage-report"
2524+
type: string
2525+
report_prefix:
2526+
description: S3 prefix where the Cost and Usage Report is stored.
2527+
example: "reports"
2528+
type: string
2529+
required:
2530+
- account_id
2531+
- bucket_name
2532+
- bucket_region
2533+
- report_name
2534+
type: object
2535+
AWSCcmConfigValidationRequestData:
2536+
description: AWS CCM config validation request data.
2537+
properties:
2538+
attributes:
2539+
$ref: "#/components/schemas/AWSCcmConfigValidationRequestAttributes"
2540+
type:
2541+
$ref: "#/components/schemas/AWSCcmConfigValidationType"
2542+
required:
2543+
- attributes
2544+
- type
2545+
type: object
2546+
AWSCcmConfigValidationResponse:
2547+
description: AWS CCM config validation response body.
2548+
properties:
2549+
data:
2550+
$ref: "#/components/schemas/AWSCcmConfigValidationResponseData"
2551+
required:
2552+
- data
2553+
type: object
2554+
AWSCcmConfigValidationResponseAttributes:
2555+
description: Attributes for an AWS CCM config validation response.
2556+
properties:
2557+
account_id:
2558+
description: Your AWS Account ID without dashes.
2559+
example: "123456789012"
2560+
type: string
2561+
issues:
2562+
$ref: "#/components/schemas/AWSCcmConfigValidationIssues"
2563+
required:
2564+
- account_id
2565+
- issues
2566+
type: object
2567+
AWSCcmConfigValidationResponseData:
2568+
description: AWS CCM config validation response data.
2569+
properties:
2570+
attributes:
2571+
$ref: "#/components/schemas/AWSCcmConfigValidationResponseAttributes"
2572+
id:
2573+
description: AWS CCM config validation resource identifier.
2574+
example: "ccm_config_validation"
2575+
type: string
2576+
type:
2577+
$ref: "#/components/schemas/AWSCcmConfigValidationType"
2578+
required:
2579+
- attributes
2580+
- id
2581+
- type
2582+
type: object
2583+
AWSCcmConfigValidationType:
2584+
default: "ccm_config_validation"
2585+
description: AWS CCM config validation resource type.
2586+
enum:
2587+
- ccm_config_validation
2588+
example: "ccm_config_validation"
2589+
type: string
2590+
x-enum-varnames:
2591+
- CCM_CONFIG_VALIDATION
24402592
AWSCloudAuthPersonaMappingAttributesResponse:
24412593
description: Attributes for AWS cloud authentication persona mapping response
24422594
properties:
@@ -121468,6 +121620,76 @@ paths:
121468121620
operator: OR
121469121621
permissions:
121470121622
- aws_configuration_read
121623+
/api/v2/integration/aws/validate_ccm_config:
121624+
post:
121625+
description: |-
121626+
Validate a Cloud Cost Management config for an AWS account using Cost and Usage Report
121627+
(CUR) 2.0 against Datadog's ingest requirements without persisting it.
121628+
operationId: ValidateAWSCCMConfig
121629+
requestBody:
121630+
content:
121631+
application/json:
121632+
examples:
121633+
default:
121634+
value:
121635+
data:
121636+
attributes:
121637+
account_id: "123456789012"
121638+
bucket_name: billing
121639+
bucket_region: us-east-1
121640+
report_name: cost-and-usage-report
121641+
report_prefix: reports
121642+
type: ccm_config_validation
121643+
schema:
121644+
$ref: "#/components/schemas/AWSCcmConfigValidationRequest"
121645+
description: Validate a Cloud Cost Management config for an AWS account integration config.
121646+
required: true
121647+
responses:
121648+
"200":
121649+
content:
121650+
application/json:
121651+
examples:
121652+
default:
121653+
value:
121654+
data:
121655+
attributes:
121656+
account_id: "123456789012"
121657+
issues:
121658+
- code: EXPORT_NOT_FOUND
121659+
description: 'no CUR 2.0 export named "cost-and-usage-report" found'
121660+
id: ccm_config_validation
121661+
type: ccm_config_validation
121662+
schema:
121663+
$ref: "#/components/schemas/AWSCcmConfigValidationResponse"
121664+
description: AWS CCM Config validation result
121665+
"400":
121666+
content:
121667+
application/json:
121668+
schema:
121669+
$ref: "#/components/schemas/JSONAPIErrorResponse"
121670+
description: Bad Request
121671+
"403":
121672+
$ref: "#/components/responses/ForbiddenResponse"
121673+
"429":
121674+
$ref: "#/components/responses/TooManyRequestsResponse"
121675+
"503":
121676+
content:
121677+
application/json:
121678+
schema:
121679+
$ref: "#/components/schemas/JSONAPIErrorResponse"
121680+
description: Service Unavailable
121681+
summary: Validate AWS CCM config
121682+
tags:
121683+
- AWS Integration
121684+
x-codegen-request-body-name: body
121685+
"x-permission":
121686+
operator: OR
121687+
permissions:
121688+
- cloud_cost_management_read
121689+
- cloud_cost_management_write
121690+
x-unstable: |-
121691+
**Note**: This endpoint is in Preview and may be subject to change.
121692+
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
121471121693
/api/v2/integration/gcp/accounts:
121472121694
get:
121473121695
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
@@ -1043,6 +1043,7 @@ public class ApiClient {
10431043
put("v2.deleteAWSAccountCCMConfig", false);
10441044
put("v2.getAWSAccountCCMConfig", false);
10451045
put("v2.updateAWSAccountCCMConfig", false);
1046+
put("v2.validateAWSCCMConfig", false);
10461047
put("v2.createJiraIssueTemplate", false);
10471048
put("v2.deleteJiraAccount", false);
10481049
put("v2.deleteJiraIssueTemplate", false);

0 commit comments

Comments
 (0)