aws_configs
Creates, updates, deletes, gets or lists an aws_configs resource.
Overview
| Name | aws_configs |
| Type | Resource |
| Id | datadog.cloud_costs.aws_configs |
Fields
The following fields are returned by SELECT queries:
- list_cost_awscurconfigs
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the AWS CUR config. |
attributes | object | Attributes for An AWS CUR config. |
type | string | Type of AWS CUR config. (aws_cur_config) (default: aws_cur_config, example: aws_cur_config) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list_cost_awscurconfigs | select | List the AWS CUR configs. | ||
create_cost_awscurconfig | insert | data | Create a Cloud Cost Management account for an AWS CUR config. | |
update_cost_awscurconfig | update | cloud_account_id, data | Update the status (active/archived) and/or account filtering configuration of an AWS CUR config. | |
delete_cost_awscurconfig | delete | cloud_account_id | Archive a Cloud Cost Management Account. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
cloud_account_id | integer (int64) | Cloud Account id. |
site | string | The Datadog site (region) for your organization, for example datadoghq.com, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, datadoghq.eu, ddog-gov.com. Resolved from the DD_SITE environment variable when set. Optional: defaults to datadoghq.com, or the value of the DD_SITE environment variable when set; a WHERE value overrides both. |
SELECT examples
- list_cost_awscurconfigs
List the AWS CUR configs.
SELECT
id,
attributes,
type
FROM datadog.cloud_costs.aws_configs
;
INSERT examples
- create_cost_awscurconfig
- Manifest
Create a Cloud Cost Management account for an AWS CUR config.
INSERT INTO datadog.cloud_costs.aws_configs (
data
)
SELECT
'{{ data }}' /* required */
RETURNING
data
;
# Description fields are for documentation purposes
- name: aws_configs
props:
- name: data
description: |
AWS CUR config Post data.
value:
attributes:
account_filters:
excluded_accounts:
- "{{ excluded_accounts }}"
include_new_accounts: {{ include_new_accounts }}
included_accounts:
- "{{ included_accounts }}"
account_id: "{{ account_id }}"
bucket_name: "{{ bucket_name }}"
bucket_region: "{{ bucket_region }}"
months: {{ months }}
report_name: "{{ report_name }}"
report_prefix: "{{ report_prefix }}"
type: "{{ type }}"
UPDATE examples
- update_cost_awscurconfig
Update the status (active/archived) and/or account filtering configuration of an AWS CUR config.
UPDATE datadog.cloud_costs.aws_configs
SET
data = '{{ data }}'
WHERE
cloud_account_id = '{{ cloud_account_id }}' --required
AND data = '{{ data }}' --required
RETURNING
data;
DELETE examples
- delete_cost_awscurconfig
Archive a Cloud Cost Management Account.
DELETE FROM datadog.cloud_costs.aws_configs
WHERE cloud_account_id = '{{ cloud_account_id }}' --required
;