From 526b5b5b24d55da35483150cd8ad24b47ee5456d Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Wed, 6 May 2026 21:02:22 +0000 Subject: [PATCH] Regenerate client from commit 54b6e9c of spec repo --- .generator/schemas/v2/openapi.yaml | 38 ++++++++--------- .../UpsertSyncConfig.java | 9 ++-- .../com/datadog/api/client/ApiClient.java | 1 - ...figsApi.java => StorageManagementApi.java} | 42 ++++++------------- ...loudInventoryCloudProviderRequestType.java | 2 +- ...ventorySyncConfigAWSRequestAttributes.java | 6 +-- .../CloudInventorySyncConfigAttributes.java | 8 ++-- .../CloudInventorySyncConfigResourceType.java | 2 +- .../CloudInventorySyncConfigResponse.java | 6 +-- .../CloudInventorySyncConfigResponseData.java | 11 ++--- ...UpsertCloudInventorySyncConfigRequest.java | 2 +- ...dInventorySyncConfigRequestAttributes.java | 6 +-- ...rtCloudInventorySyncConfigRequestData.java | 8 ++-- ...igs.feature => storage_management.feature} | 16 +++---- .../com/datadog/api/client/v2/api/undo.json | 2 +- 15 files changed, 70 insertions(+), 89 deletions(-) rename examples/v2/{cloud-inventory-sync-configs => storage-management}/UpsertSyncConfig.java (89%) rename src/main/java/com/datadog/api/client/v2/api/{CloudInventorySyncConfigsApi.java => StorageManagementApi.java} (78%) rename src/test/resources/com/datadog/api/client/v2/api/{cloud_inventory_sync_configs.feature => storage_management.feature} (70%) diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 2dc5dce2c0a..14c3f04e480 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -12687,7 +12687,7 @@ components: - GCP - AZURE CloudInventoryCloudProviderRequestType: - description: JSON:API type for upsert sync configuration requests. + description: Always `cloud_provider`. enum: - cloud_provider example: cloud_provider @@ -12695,7 +12695,7 @@ components: x-enum-varnames: - CLOUD_PROVIDER CloudInventorySyncConfigAWSRequestAttributes: - description: AWS settings for the customer bucket that stores inventory reports. + description: AWS settings for the S3 bucket Storage Management reads inventory reports from. properties: aws_account_id: description: AWS account ID that owns the inventory bucket. @@ -12710,7 +12710,7 @@ components: example: us-east-1 type: string destination_prefix: - description: Optional object key prefix for inventory files. Use `/` or omit for the entire bucket. + description: Object key prefix where inventory reports are written. Omit or set to `/` when reports are written at the bucket root. example: logs/ type: string required: @@ -12719,7 +12719,7 @@ components: - destination_bucket_region type: object CloudInventorySyncConfigAttributes: - description: Attributes for a cloud inventory sync configuration. Values beyond `id` may be omitted immediately after upsert. + description: Attributes for a Storage Management configuration. Fields other than `id` may be empty in the response immediately after a create or update; subsequent reads return the full configuration. properties: aws_account_id: description: AWS account ID for the inventory bucket. @@ -12774,7 +12774,7 @@ components: example: reader@my-gcp-project.iam.gserviceaccount.com type: string prefix: - description: Object key prefix or `/` when the entire bucket is synced. + description: Object key prefix where inventory reports are written. Returns `/` when reports are written at the bucket root. example: logs/ readOnly: true type: string @@ -12855,7 +12855,7 @@ components: - service_account_email type: object CloudInventorySyncConfigResourceType: - description: JSON:API type for sync configuration resources. + description: Always `sync_configs`. enum: - sync_configs example: sync_configs @@ -12863,7 +12863,7 @@ components: x-enum-varnames: - SYNC_CONFIGS CloudInventorySyncConfigResponse: - description: Response containing the upserted sync configuration. Additional read-only fields appear on list and get. + description: Storage Management configuration returned after a create or update. Additional read-only fields appear on list and get responses. properties: data: $ref: "#/components/schemas/CloudInventorySyncConfigResponseData" @@ -12871,12 +12871,12 @@ components: - data type: object CloudInventorySyncConfigResponseData: - description: JSON:API data object for a sync configuration. + description: Storage Management configuration data. properties: attributes: $ref: "#/components/schemas/CloudInventorySyncConfigAttributes" id: - description: Unique identifier for the recurring sync configuration. + description: Unique identifier for this Storage Management configuration. example: abc123 type: string type: @@ -81161,7 +81161,7 @@ components: type: object UpsertCloudInventorySyncConfigRequestAttributes: description: |- - Provider-specific configuration. Include the object that matches `data.id` (`aws`, `gcp`, or `azure`). + Settings for the cloud provider specified in `data.id`. Include only the matching provider object (`aws`, `gcp`, or `azure`). properties: aws: $ref: "#/components/schemas/CloudInventorySyncConfigAWSRequestAttributes" @@ -81171,7 +81171,7 @@ components: $ref: "#/components/schemas/CloudInventorySyncConfigGCPRequestAttributes" type: object UpsertCloudInventorySyncConfigRequestData: - description: JSON:API data envelope for an upsert sync configuration request. + description: Storage Management configuration data for the create or update request. properties: attributes: $ref: "#/components/schemas/UpsertCloudInventorySyncConfigRequestAttributes" @@ -93941,8 +93941,7 @@ paths: /api/v2/cloudinventoryservice/syncconfigs: put: description: |- - Create or update a cloud inventory sync configuration. Specify the cloud provider in `data.id` - and provider-specific settings under `data.attributes`. This endpoint uses an upsert model. + Enable Storage Management for an S3 bucket, GCS bucket, or Azure container by registering the destination that holds its inventory reports. Set `data.id` to the cloud provider (`aws`, `gcp`, or `azure`) and provide the matching settings under data.attributes. Calling this endpoint with the same provider replaces the existing configuration. operationId: UpsertSyncConfig requestBody: content: @@ -93990,17 +93989,14 @@ paths: $ref: "#/components/responses/ForbiddenResponse" "429": $ref: "#/components/responses/TooManyRequestsResponse" - summary: Create or update a sync configuration + summary: Enable Storage Management for a bucket tags: - - Cloud Inventory Sync Configs + - Storage Management x-codegen-request-body-name: body "x-permission": operator: OR permissions: - aws_configurations_manage - x-unstable: |- - **Note**: This endpoint is in preview and is subject to change. - If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/code-coverage/branch/summary: post: description: |- @@ -145604,9 +145600,6 @@ tags: - description: |- The Cloud Cost Management API allows you to set up, edit, and delete Cloud Cost Management accounts for AWS, Azure, and Google Cloud. You can query your cost data by using the [Metrics endpoint](https://docs.datadoghq.com/api/latest/metrics/#query-timeseries-data-across-multiple-products) and the `cloud_cost` data source. For more information, see the [Cloud Cost Management documentation](https://docs.datadoghq.com/cloud_cost_management/). name: Cloud Cost Management - - description: |- - Configure cloud inventory file synchronization from your cloud storage to Datadog. - name: Cloud Inventory Sync Configs - description: |- The Cloud Network Monitoring API allows you to fetch aggregated connections and DNS traffic with their attributes. See the [Cloud Network Monitoring page](https://docs.datadoghq.com/network_monitoring/cloud_network_monitoring/) and [DNS Monitoring page](https://docs.datadoghq.com/network_monitoring/dns/) for more information. name: Cloud Network Monitoring @@ -145988,6 +145981,9 @@ tags: name: Static Analysis - description: Manage your status pages and communicate service disruptions to stakeholders via Datadog's API. See the [Status Pages documentation](https://docs.datadoghq.com/incident_response/status_pages/) for more information. name: Status Pages + - description: |- + Enable Storage Management for S3 buckets, GCS buckets, and Azure containers. Each configuration registers the destination that holds inventory reports for the storage being monitored. + name: Storage Management - description: |- Synthetic tests use simulated requests and actions so you can monitor the availability and performance of systems and applications. Datadog supports the following types of synthetic tests: - [API tests](https://docs.datadoghq.com/synthetics/api_tests/) diff --git a/examples/v2/cloud-inventory-sync-configs/UpsertSyncConfig.java b/examples/v2/storage-management/UpsertSyncConfig.java similarity index 89% rename from examples/v2/cloud-inventory-sync-configs/UpsertSyncConfig.java rename to examples/v2/storage-management/UpsertSyncConfig.java index 03716b01aa3..73727000e3b 100644 --- a/examples/v2/cloud-inventory-sync-configs/UpsertSyncConfig.java +++ b/examples/v2/storage-management/UpsertSyncConfig.java @@ -1,8 +1,8 @@ -// Create or update a sync configuration returns "OK" response +// Enable Storage Management for a bucket returns "OK" response import com.datadog.api.client.ApiClient; import com.datadog.api.client.ApiException; -import com.datadog.api.client.v2.api.CloudInventorySyncConfigsApi; +import com.datadog.api.client.v2.api.StorageManagementApi; import com.datadog.api.client.v2.model.CloudInventoryCloudProviderId; import com.datadog.api.client.v2.model.CloudInventoryCloudProviderRequestType; import com.datadog.api.client.v2.model.CloudInventorySyncConfigAWSRequestAttributes; @@ -16,8 +16,7 @@ public class Example { public static void main(String[] args) { ApiClient defaultClient = ApiClient.getDefaultApiClient(); - defaultClient.setUnstableOperationEnabled("v2.upsertSyncConfig", true); - CloudInventorySyncConfigsApi apiInstance = new CloudInventorySyncConfigsApi(defaultClient); + StorageManagementApi apiInstance = new StorageManagementApi(defaultClient); UpsertCloudInventorySyncConfigRequest body = new UpsertCloudInventorySyncConfigRequest() @@ -53,7 +52,7 @@ public static void main(String[] args) { CloudInventorySyncConfigResponse result = apiInstance.upsertSyncConfig(body); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling CloudInventorySyncConfigsApi#upsertSyncConfig"); + System.err.println("Exception when calling StorageManagementApi#upsertSyncConfig"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); diff --git a/src/main/java/com/datadog/api/client/ApiClient.java b/src/main/java/com/datadog/api/client/ApiClient.java index e50cdd037c4..9b9c702b3cb 100644 --- a/src/main/java/com/datadog/api/client/ApiClient.java +++ b/src/main/java/com/datadog/api/client/ApiClient.java @@ -856,7 +856,6 @@ public class ApiClient { put("v2.muteSecurityFindings", false); put("v2.runHistoricalJob", false); put("v2.searchSecurityMonitoringHistsignals", false); - put("v2.upsertSyncConfig", false); put("v2.getCodeCoverageBranchSummary", false); put("v2.getCodeCoverageCommitSummary", false); put("v2.createDashboardSecureEmbed", false); diff --git a/src/main/java/com/datadog/api/client/v2/api/CloudInventorySyncConfigsApi.java b/src/main/java/com/datadog/api/client/v2/api/StorageManagementApi.java similarity index 78% rename from src/main/java/com/datadog/api/client/v2/api/CloudInventorySyncConfigsApi.java rename to src/main/java/com/datadog/api/client/v2/api/StorageManagementApi.java index b3db1b27f38..a803b78e217 100644 --- a/src/main/java/com/datadog/api/client/v2/api/CloudInventorySyncConfigsApi.java +++ b/src/main/java/com/datadog/api/client/v2/api/StorageManagementApi.java @@ -15,14 +15,14 @@ @jakarta.annotation.Generated( value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator") -public class CloudInventorySyncConfigsApi { +public class StorageManagementApi { private ApiClient apiClient; - public CloudInventorySyncConfigsApi() { + public StorageManagementApi() { this(ApiClient.getDefaultApiClient()); } - public CloudInventorySyncConfigsApi(ApiClient apiClient) { + public StorageManagementApi(ApiClient apiClient) { this.apiClient = apiClient; } @@ -45,7 +45,7 @@ public void setApiClient(ApiClient apiClient) { } /** - * Create or update a sync configuration. + * Enable Storage Management for a bucket. * *

See {@link #upsertSyncConfigWithHttpInfo}. * @@ -59,7 +59,7 @@ public CloudInventorySyncConfigResponse upsertSyncConfig( } /** - * Create or update a sync configuration. + * Enable Storage Management for a bucket. * *

See {@link #upsertSyncConfigWithHttpInfoAsync}. * @@ -76,9 +76,11 @@ public CompletableFuture upsertSyncConfigAsync } /** - * Create or update a cloud inventory sync configuration. Specify the cloud provider in - * data.id and provider-specific settings under data.attributes. This endpoint - * uses an upsert model. + * Enable Storage Management for an S3 bucket, GCS bucket, or Azure container by registering the + * destination that holds its inventory reports. Set data.id to the cloud provider ( + * aws, gcp, or azure) and provide the matching settings + * under data.attributes. Calling this endpoint with the same provider replaces the existing + * configuration. * * @param body (required) * @return ApiResponse<CloudInventorySyncConfigResponse> @@ -95,13 +97,6 @@ public CompletableFuture upsertSyncConfigAsync */ public ApiResponse upsertSyncConfigWithHttpInfo( UpsertCloudInventorySyncConfigRequest body) throws ApiException { - // Check if unstable operation is enabled - String operationId = "upsertSyncConfig"; - if (apiClient.isUnstableOperationEnabled("v2." + operationId)) { - apiClient.getLogger().warning(String.format("Using unstable operation '%s'", operationId)); - } else { - throw new ApiException(0, String.format("Unstable operation '%s' is disabled", operationId)); - } Object localVarPostBody = body; // verify the required parameter 'body' is set @@ -116,7 +111,7 @@ public ApiResponse upsertSyncConfigWithHttpInf Invocation.Builder builder = apiClient.createBuilder( - "v2.CloudInventorySyncConfigsApi.upsertSyncConfig", + "v2.StorageManagementApi.upsertSyncConfig", localVarPath, new ArrayList(), localVarHeaderParams, @@ -135,7 +130,7 @@ public ApiResponse upsertSyncConfigWithHttpInf } /** - * Create or update a sync configuration. + * Enable Storage Management for a bucket. * *

See {@link #upsertSyncConfigWithHttpInfo}. * @@ -144,17 +139,6 @@ public ApiResponse upsertSyncConfigWithHttpInf */ public CompletableFuture> upsertSyncConfigWithHttpInfoAsync(UpsertCloudInventorySyncConfigRequest body) { - // Check if unstable operation is enabled - String operationId = "upsertSyncConfig"; - if (apiClient.isUnstableOperationEnabled("v2." + operationId)) { - apiClient.getLogger().warning(String.format("Using unstable operation '%s'", operationId)); - } else { - CompletableFuture> result = - new CompletableFuture<>(); - result.completeExceptionally( - new ApiException(0, String.format("Unstable operation '%s' is disabled", operationId))); - return result; - } Object localVarPostBody = body; // verify the required parameter 'body' is set @@ -175,7 +159,7 @@ public ApiResponse upsertSyncConfigWithHttpInf try { builder = apiClient.createBuilder( - "v2.CloudInventorySyncConfigsApi.upsertSyncConfig", + "v2.StorageManagementApi.upsertSyncConfig", localVarPath, new ArrayList(), localVarHeaderParams, diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventoryCloudProviderRequestType.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventoryCloudProviderRequestType.java index 6347ade1647..a718565b5a1 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventoryCloudProviderRequestType.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventoryCloudProviderRequestType.java @@ -18,7 +18,7 @@ import java.util.HashSet; import java.util.Set; -/** JSON:API type for upsert sync configuration requests. */ +/** Always cloud_provider. */ @JsonSerialize( using = CloudInventoryCloudProviderRequestType.CloudInventoryCloudProviderRequestTypeSerializer diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAWSRequestAttributes.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAWSRequestAttributes.java index 87d7ceda797..32dfd6d6336 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAWSRequestAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAWSRequestAttributes.java @@ -17,7 +17,7 @@ import java.util.Map; import java.util.Objects; -/** AWS settings for the customer bucket that stores inventory reports. */ +/** AWS settings for the S3 bucket Storage Management reads inventory reports from. */ @JsonPropertyOrder({ CloudInventorySyncConfigAWSRequestAttributes.JSON_PROPERTY_AWS_ACCOUNT_ID, CloudInventorySyncConfigAWSRequestAttributes.JSON_PROPERTY_DESTINATION_BUCKET_NAME, @@ -122,8 +122,8 @@ public CloudInventorySyncConfigAWSRequestAttributes destinationPrefix(String des } /** - * Optional object key prefix for inventory files. Use / or omit for the entire - * bucket. + * Object key prefix where inventory reports are written. Omit or set to / when + * reports are written at the bucket root. * * @return destinationPrefix */ diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAttributes.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAttributes.java index a008f8a233d..6707778bd21 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigAttributes.java @@ -18,8 +18,9 @@ import java.util.Objects; /** - * Attributes for a cloud inventory sync configuration. Values beyond id may be omitted - * immediately after upsert. + * Attributes for a Storage Management configuration. Fields other than id may be empty + * in the response immediately after a create or update; subsequent reads return the full + * configuration. */ @JsonPropertyOrder({ CloudInventorySyncConfigAttributes.JSON_PROPERTY_AWS_ACCOUNT_ID, @@ -373,7 +374,8 @@ public void setGcpServiceAccountEmail(String gcpServiceAccountEmail) { } /** - * Object key prefix or / when the entire bucket is synced. + * Object key prefix where inventory reports are written. Returns / when reports are + * written at the bucket root. * * @return prefix */ diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResourceType.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResourceType.java index 2ee3601dce9..d837a67c5fa 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResourceType.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResourceType.java @@ -18,7 +18,7 @@ import java.util.HashSet; import java.util.Set; -/** JSON:API type for sync configuration resources. */ +/** Always sync_configs. */ @JsonSerialize( using = CloudInventorySyncConfigResourceType.CloudInventorySyncConfigResourceTypeSerializer.class) diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponse.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponse.java index f0b0984654b..19f48555fd1 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponse.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponse.java @@ -18,8 +18,8 @@ import java.util.Objects; /** - * Response containing the upserted sync configuration. Additional read-only fields appear on list - * and get. + * Storage Management configuration returned after a create or update. Additional read-only fields + * appear on list and get responses. */ @JsonPropertyOrder({CloudInventorySyncConfigResponse.JSON_PROPERTY_DATA}) @jakarta.annotation.Generated( @@ -46,7 +46,7 @@ public CloudInventorySyncConfigResponse data(CloudInventorySyncConfigResponseDat } /** - * JSON:API data object for a sync configuration. + * Storage Management configuration data. * * @return data */ diff --git a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponseData.java b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponseData.java index d614d405dac..9c5b0451675 100644 --- a/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponseData.java +++ b/src/main/java/com/datadog/api/client/v2/model/CloudInventorySyncConfigResponseData.java @@ -17,7 +17,7 @@ import java.util.Map; import java.util.Objects; -/** JSON:API data object for a sync configuration. */ +/** Storage Management configuration data. */ @JsonPropertyOrder({ CloudInventorySyncConfigResponseData.JSON_PROPERTY_ATTRIBUTES, CloudInventorySyncConfigResponseData.JSON_PROPERTY_ID, @@ -60,8 +60,9 @@ public CloudInventorySyncConfigResponseData attributes( } /** - * Attributes for a cloud inventory sync configuration. Values beyond id may be - * omitted immediately after upsert. + * Attributes for a Storage Management configuration. Fields other than id may be + * empty in the response immediately after a create or update; subsequent reads return the full + * configuration. * * @return attributes */ @@ -81,7 +82,7 @@ public CloudInventorySyncConfigResponseData id(String id) { } /** - * Unique identifier for the recurring sync configuration. + * Unique identifier for this Storage Management configuration. * * @return id */ @@ -102,7 +103,7 @@ public CloudInventorySyncConfigResponseData type(CloudInventorySyncConfigResourc } /** - * JSON:API type for sync configuration resources. + * Always sync_configs. * * @return type */ diff --git a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequest.java b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequest.java index 395a1e19467..09ee6d8b6d1 100644 --- a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequest.java +++ b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequest.java @@ -44,7 +44,7 @@ public UpsertCloudInventorySyncConfigRequest data( } /** - * JSON:API data envelope for an upsert sync configuration request. + * Storage Management configuration data for the create or update request. * * @return data */ diff --git a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestAttributes.java b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestAttributes.java index 92943bae986..8d4341e4afb 100644 --- a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestAttributes.java @@ -17,8 +17,8 @@ import java.util.Objects; /** - * Provider-specific configuration. Include the object that matches data.id (aws - * , gcp, or azure). + * Settings for the cloud provider specified in data.id. Include only the matching + * provider object (aws, gcp, or azure). */ @JsonPropertyOrder({ UpsertCloudInventorySyncConfigRequestAttributes.JSON_PROPERTY_AWS, @@ -46,7 +46,7 @@ public UpsertCloudInventorySyncConfigRequestAttributes aws( } /** - * AWS settings for the customer bucket that stores inventory reports. + * AWS settings for the S3 bucket Storage Management reads inventory reports from. * * @return aws */ diff --git a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestData.java b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestData.java index cd7f184cfa4..44bca94f64d 100644 --- a/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestData.java +++ b/src/main/java/com/datadog/api/client/v2/model/UpsertCloudInventorySyncConfigRequestData.java @@ -17,7 +17,7 @@ import java.util.Map; import java.util.Objects; -/** JSON:API data envelope for an upsert sync configuration request. */ +/** Storage Management configuration data for the create or update request. */ @JsonPropertyOrder({ UpsertCloudInventorySyncConfigRequestData.JSON_PROPERTY_ATTRIBUTES, UpsertCloudInventorySyncConfigRequestData.JSON_PROPERTY_ID, @@ -61,8 +61,8 @@ public UpsertCloudInventorySyncConfigRequestData attributes( } /** - * Provider-specific configuration. Include the object that matches data.id ( - * aws, gcp, or azure). + * Settings for the cloud provider specified in data.id. Include only the matching + * provider object (aws, gcp, or azure). * * @return attributes */ @@ -109,7 +109,7 @@ public UpsertCloudInventorySyncConfigRequestData type( } /** - * JSON:API type for upsert sync configuration requests. + * Always cloud_provider. * * @return type */ diff --git a/src/test/resources/com/datadog/api/client/v2/api/cloud_inventory_sync_configs.feature b/src/test/resources/com/datadog/api/client/v2/api/storage_management.feature similarity index 70% rename from src/test/resources/com/datadog/api/client/v2/api/cloud_inventory_sync_configs.feature rename to src/test/resources/com/datadog/api/client/v2/api/storage_management.feature index 32a7d292efb..cde4a4e9876 100644 --- a/src/test/resources/com/datadog/api/client/v2/api/cloud_inventory_sync_configs.feature +++ b/src/test/resources/com/datadog/api/client/v2/api/storage_management.feature @@ -1,22 +1,22 @@ -@endpoint(cloud-inventory-sync-configs) @endpoint(cloud-inventory-sync-configs-v2) -Feature: Cloud Inventory Sync Configs - Configure cloud inventory file synchronization from your cloud storage to - Datadog. +@endpoint(storage-management) @endpoint(storage-management-v2) +Feature: Storage Management + Enable Storage Management for S3 buckets, GCS buckets, and Azure + containers. Each configuration registers the destination that holds + inventory reports for the storage being monitored. Background: Given a valid "apiKeyAuth" key in the system And a valid "appKeyAuth" key in the system - And an instance of "CloudInventorySyncConfigs" API - And operation "UpsertSyncConfig" enabled + And an instance of "StorageManagement" API And new "UpsertSyncConfig" request And body with value {"data": {"attributes": {"aws": {"aws_account_id": "123456789012", "destination_bucket_name": "my-inventory-bucket", "destination_bucket_region": "us-east-1", "destination_prefix": "logs/"}, "azure": {"client_id": "11111111-1111-1111-1111-111111111111", "container": "inventory-container", "resource_group": "my-resource-group", "storage_account": "mystorageaccount", "subscription_id": "33333333-3333-3333-3333-333333333333", "tenant_id": "22222222-2222-2222-2222-222222222222"}, "gcp": {"destination_bucket_name": "my-inventory-reports", "project_id": "my-gcp-project", "service_account_email": "reader@my-gcp-project.iam.gserviceaccount.com", "source_bucket_name": "my-monitored-bucket"}}, "id": "aws", "type": "cloud_provider"}} @generated @skip @team:DataDog/storage-management - Scenario: Create or update a sync configuration returns "Bad Request" response + Scenario: Enable Storage Management for a bucket returns "Bad Request" response When the request is sent Then the response status is 400 Bad Request @generated @skip @team:DataDog/storage-management - Scenario: Create or update a sync configuration returns "OK" response + Scenario: Enable Storage Management for a bucket returns "OK" response When the request is sent Then the response status is 200 OK diff --git a/src/test/resources/com/datadog/api/client/v2/api/undo.json b/src/test/resources/com/datadog/api/client/v2/api/undo.json index d5a8323e270..086a6e562d7 100644 --- a/src/test/resources/com/datadog/api/client/v2/api/undo.json +++ b/src/test/resources/com/datadog/api/client/v2/api/undo.json @@ -1236,7 +1236,7 @@ } }, "UpsertSyncConfig": { - "tag": "Cloud Inventory Sync Configs", + "tag": "Storage Management", "undo": { "type": "idempotent" }