Skip to content

Commit 4919095

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
and
ci.datadog-api-spec
authored
Delete api/v2/cost/aws_related_accounts from spec (#2078)
Co-authored-by: ci.datadog-api-spec <[email protected]>
1 parent 8e83c8f commit 4919095

14 files changed

+4
-632
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": "2024-10-31 16:03:55.097621",
8-
"spec_repo_commit": "a11da7b5"
7+
"regenerated": "2024-10-31 16:41:41.024770",
8+
"spec_repo_commit": "63c441b2"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2024-10-31 16:03:55.116103",
13-
"spec_repo_commit": "a11da7b5"
12+
"regenerated": "2024-10-31 16:41:41.042740",
13+
"spec_repo_commit": "63c441b2"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 0 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -976,49 +976,6 @@ components:
976976
type: string
977977
x-enum-varnames:
978978
- API_KEYS
979-
AWSRelatedAccount:
980-
description: AWS related account.
981-
properties:
982-
attributes:
983-
$ref: '#/components/schemas/AWSRelatedAccountAttributes'
984-
id:
985-
description: The AWS account ID.
986-
example: '123456789123'
987-
type: string
988-
type:
989-
$ref: '#/components/schemas/AWSRelatedAccountType'
990-
required:
991-
- id
992-
- type
993-
type: object
994-
AWSRelatedAccountAttributes:
995-
description: Attributes for an AWS related account.
996-
properties:
997-
has_datadog_integration:
998-
description: Whether or not the AWS account has a Datadog integration.
999-
type: boolean
1000-
name:
1001-
description: The name of the AWS account.
1002-
type: string
1003-
type: object
1004-
AWSRelatedAccountType:
1005-
default: aws_account
1006-
description: Type of AWS related account.
1007-
enum:
1008-
- aws_account
1009-
example: aws_account
1010-
type: string
1011-
x-enum-varnames:
1012-
- AWS_ACCOUNT
1013-
AWSRelatedAccountsResponse:
1014-
description: List of AWS related accounts.
1015-
properties:
1016-
data:
1017-
description: An AWS related account.
1018-
items:
1019-
$ref: '#/components/schemas/AWSRelatedAccount'
1020-
type: array
1021-
type: object
1022979
ActiveBillingDimensionsAttributes:
1023980
description: List of active billing dimensions.
1024981
properties:
@@ -28974,53 +28931,6 @@ paths:
2897428931
operator: OR
2897528932
permissions:
2897628933
- cloud_cost_management_write
28977-
/api/v2/cost/aws_related_accounts:
28978-
get:
28979-
deprecated: true
28980-
description: List the AWS accounts in an organization by calling 'organizations:ListAccounts'
28981-
from the specified management account.
28982-
operationId: ListAWSRelatedAccounts
28983-
parameters:
28984-
- description: The ID of the management account to filter by.
28985-
example: '123456789123'
28986-
in: query
28987-
name: filter[management_account_id]
28988-
required: true
28989-
schema:
28990-
type: string
28991-
responses:
28992-
'200':
28993-
content:
28994-
application/json:
28995-
schema:
28996-
$ref: '#/components/schemas/AWSRelatedAccountsResponse'
28997-
description: OK
28998-
'400':
28999-
content:
29000-
application/json:
29001-
schema:
29002-
$ref: '#/components/schemas/APIErrorResponse'
29003-
description: Bad Request
29004-
'403':
29005-
content:
29006-
application/json:
29007-
schema:
29008-
$ref: '#/components/schemas/APIErrorResponse'
29009-
description: Forbidden
29010-
'429':
29011-
$ref: '#/components/responses/TooManyRequestsResponse'
29012-
security:
29013-
- apiKeyAuth: []
29014-
appKeyAuth: []
29015-
- AuthZ:
29016-
- cloud_cost_management_read
29017-
summary: List related AWS accounts
29018-
tags:
29019-
- Cloud Cost Management
29020-
x-permission:
29021-
operator: OR
29022-
permissions:
29023-
- cloud_cost_management_read
2902428934
/api/v2/cost/azure_uc_config:
2902528935
get:
2902628936
description: List the Azure configs.

cassettes/features/v2/cloud_cost_management/List-related-AWS-accounts-returns-OK-response.frozen

Lines changed: 0 additions & 1 deletion
This file was deleted.

cassettes/features/v2/cloud_cost_management/List-related-AWS-accounts-returns-OK-response.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

examples/v2/cloud-cost-management/ListAWSRelatedAccounts.rb

Lines changed: 0 additions & 5 deletions
This file was deleted.

features/scenarios_model_mapping.rb

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1093,9 +1093,6 @@
10931093
"cloud_account_id" => "String",
10941094
"body" => "AwsCURConfigPatchRequest",
10951095
},
1096-
"v2.ListAWSRelatedAccounts" => {
1097-
"filter_management_account_id" => "String",
1098-
},
10991096
"v2.CreateCostAzureUCConfigs" => {
11001097
"body" => "AzureUCConfigPostRequest",
11011098
},

features/v2/cloud_cost_management.feature

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -148,21 +148,6 @@ Feature: Cloud Cost Management
148148
When the request is sent
149149
Then the response status is 200 OK
150150

151-
@generated @skip @team:Datadog/cloud-cost-management
152-
Scenario: List related AWS accounts returns "Bad Request" response
153-
Given new "ListAWSRelatedAccounts" request
154-
And request contains "filter[management_account_id]" parameter from "REPLACE.ME"
155-
When the request is sent
156-
Then the response status is 400 Bad Request
157-
158-
@replay-only @team:Datadog/cloud-cost-management
159-
Scenario: List related AWS accounts returns "OK" response
160-
Given new "ListAWSRelatedAccounts" request
161-
And request contains "filter[management_account_id]" parameter with value "123456789123"
162-
When the request is sent
163-
Then the response status is 200 OK
164-
And the response "data[0].attributes.name" is equal to "test_name"
165-
166151
@replay-only @team:Datadog/cloud-cost-management
167152
Scenario: Update Cloud Cost Management AWS CUR config returns "OK" response
168153
Given new "UpdateCostAWSCURConfig" request

features/v2/undo.json

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -414,12 +414,6 @@
414414
"type": "idempotent"
415415
}
416416
},
417-
"ListAWSRelatedAccounts": {
418-
"tag": "Cloud Cost Management",
419-
"undo": {
420-
"type": "safe"
421-
}
422-
},
423417
"ListCostAzureUCConfigs": {
424418
"tag": "Cloud Cost Management",
425419
"undo": {

lib/datadog_api_client/inflector.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -988,10 +988,6 @@ def overrides
988988
"v2.aws_cur_config_response" => "AwsCURConfigResponse",
989989
"v2.aws_cur_configs_response" => "AwsCURConfigsResponse",
990990
"v2.aws_cur_config_type" => "AwsCURConfigType",
991-
"v2.aws_related_account" => "AWSRelatedAccount",
992-
"v2.aws_related_account_attributes" => "AWSRelatedAccountAttributes",
993-
"v2.aws_related_accounts_response" => "AWSRelatedAccountsResponse",
994-
"v2.aws_related_account_type" => "AWSRelatedAccountType",
995991
"v2.azure_uc_config" => "AzureUCConfig",
996992
"v2.azure_uc_config_pair" => "AzureUCConfigPair",
997993
"v2.azure_uc_config_pair_attributes" => "AzureUCConfigPairAttributes",

lib/datadog_api_client/v2/api/cloud_cost_management_api.rb

Lines changed: 0 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -477,75 +477,6 @@ def get_custom_costs_file_with_http_info(file_id, opts = {})
477477
return data, status_code, headers
478478
end
479479

480-
# List related AWS accounts.
481-
#
482-
# @see #list_aws_related_accounts_with_http_info
483-
def list_aws_related_accounts(filter_management_account_id, opts = {})
484-
data, _status_code, _headers = list_aws_related_accounts_with_http_info(filter_management_account_id, opts)
485-
data
486-
end
487-
488-
# List related AWS accounts.
489-
#
490-
# List the AWS accounts in an organization by calling 'organizations:ListAccounts' from the specified management account.
491-
#
492-
# @deprecated This API is deprecated.
493-
#
494-
# @param filter_management_account_id [String] The ID of the management account to filter by.
495-
# @param opts [Hash] the optional parameters
496-
# @return [Array<(AWSRelatedAccountsResponse, Integer, Hash)>] AWSRelatedAccountsResponse data, response status code and response headers
497-
def list_aws_related_accounts_with_http_info(filter_management_account_id, opts = {})
498-
warn "[DEPRECATION] `ListAWSRelatedAccounts` is deprecated."
499-
500-
if @api_client.config.debugging
501-
@api_client.config.logger.debug 'Calling API: CloudCostManagementAPI.list_aws_related_accounts ...'
502-
end
503-
# verify the required parameter 'filter_management_account_id' is set
504-
if @api_client.config.client_side_validation && filter_management_account_id.nil?
505-
fail ArgumentError, "Missing the required parameter 'filter_management_account_id' when calling CloudCostManagementAPI.list_aws_related_accounts"
506-
end
507-
# resource path
508-
local_var_path = '/api/v2/cost/aws_related_accounts'
509-
510-
# query parameters
511-
query_params = opts[:query_params] || {}
512-
query_params[:'filter[management_account_id]'] = filter_management_account_id
513-
514-
# header parameters
515-
header_params = opts[:header_params] || {}
516-
# HTTP header 'Accept' (if needed)
517-
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
518-
519-
# form parameters
520-
form_params = opts[:form_params] || {}
521-
522-
# http body (model)
523-
post_body = opts[:debug_body]
524-
525-
# return_type
526-
return_type = opts[:debug_return_type] || 'AWSRelatedAccountsResponse'
527-
528-
# auth_names
529-
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
530-
531-
new_options = opts.merge(
532-
:operation => :list_aws_related_accounts,
533-
:header_params => header_params,
534-
:query_params => query_params,
535-
:form_params => form_params,
536-
:body => post_body,
537-
:auth_names => auth_names,
538-
:return_type => return_type,
539-
:api_version => "V2"
540-
)
541-
542-
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
543-
if @api_client.config.debugging
544-
@api_client.config.logger.debug "API called: CloudCostManagementAPI#list_aws_related_accounts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
545-
end
546-
return data, status_code, headers
547-
end
548-
549480
# List Cloud Cost Management AWS CUR configs.
550481
#
551482
# @see #list_cost_awscur_configs_with_http_info

0 commit comments

Comments
 (0)