From 43b7753aa4f385f815482e0e5c6dcb620700b353 Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Thu, 29 Oct 2026 19:58:56 +0000 Subject: [PATCH] Regenerate client from commit 5524998 of spec repo --- .generator/schemas/v2/openapi.yaml | 56 +++++++- .../v2/aws-integration/UpdateAWSAccount.py | 13 +- .../v2/model/aws_metrics_config.py | 11 ++ .../v2/model/aws_resource_type_tag_filter.py | 70 ++++++++++ src/datadog_api_client/v2/models/__init__.py | 2 + ...n-returns-aws-account-object-response.json | 11 +- .../test-server-data/v2/aws-integration.json | 125 +++++++++--------- tests/v2/features/aws_integration.feature | 2 +- tests/v2/features/given.json | 2 +- 9 files changed, 215 insertions(+), 77 deletions(-) create mode 100644 src/datadog_api_client/v2/model/aws_resource_type_tag_filter.py diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index dbd876c34d..05c8e0af8a 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -4317,8 +4317,16 @@ components: type: array namespace_filters: $ref: "#/components/schemas/AWSNamespaceFilters" + resource_type_tag_filters: + description: AWS Metrics collection resource type tag filters list. Defaults to `[]`. + items: + $ref: "#/components/schemas/AWSResourceTypeTagFilter" + type: array tag_filters: - description: AWS Metrics collection tag filters list. Defaults to `[]`. + deprecated: true + description: |- + AWS Metrics collection tag filters list. Defaults to `[]`. + Deprecated in favor of `resource_type_tag_filters`. The two fields are mutually exclusive on an account. items: $ref: "#/components/schemas/AWSNamespaceTagFilter" type: array @@ -4512,6 +4520,38 @@ components: required: - include_only type: object + AWSResourceTypeTagFilter: + description: |- + AWS Metrics Collection resource type tag filter. + Each filter targets either a specific AWS service's resource types (`service` and + `resource_types`) or custom metrics (`custom`). These two modes are mutually exclusive. + The `expression` defines a tag filter that Datadog uses when collecting metrics from the + resource types of a specified service. Wildcards, such as `?` (match a single character) + and `*` (match multiple characters), and exclusion using `!` before the tag are supported. + For example, `env:production AND instance-type:c?.* AND !region:us-east-1`. + properties: + custom: + description: Whether the tag filter applies to custom metrics. When `true`, `service` and `resource_types` must be omitted. + example: false + type: boolean + expression: + description: The tag filter expression to apply when collecting metrics for the matching resource types. + example: "env:production" + type: string + resource_types: + description: The AWS resource types of the service to which the tag filter applies. Required when `service` is set. Use `*` as the only entry to match all resource types of the service; `*` cannot be combined with specific resource types. + items: + description: An AWS resource type of the service. + example: "instance" + type: string + type: array + service: + description: The AWS service for which the tag filter defined in `expression` will be applied. Required unless `custom` is `true`, and must be set together with `resource_types`. + example: "ec2" + type: string + required: + - expression + type: object AWSResourcesConfig: description: AWS Resources Collection config. properties: @@ -187941,8 +187981,11 @@ paths: - include_only: - aws.ec2.network_in namespace: AWS/EC2 - tag_filters: - - namespace: AWS/EC2 + resource_type_tag_filters: + - expression: env:production + resource_types: + - instance + service: ec2 resources_config: cloud_security_posture_management_collection: false extended_collection: true @@ -188084,8 +188127,11 @@ paths: - include_only: - aws.ec2.network_in namespace: AWS/EC2 - tag_filters: - - namespace: AWS/EC2 + resource_type_tag_filters: + - expression: env:production + resource_types: + - instance + service: ec2 resources_config: cloud_security_posture_management_collection: false extended_collection: true diff --git a/examples/v2/aws-integration/UpdateAWSAccount.py b/examples/v2/aws-integration/UpdateAWSAccount.py index 9955af00e1..7b4342831d 100644 --- a/examples/v2/aws-integration/UpdateAWSAccount.py +++ b/examples/v2/aws-integration/UpdateAWSAccount.py @@ -18,7 +18,7 @@ from datadog_api_client.v2.model.aws_log_source_tag_filter import AWSLogSourceTagFilter from datadog_api_client.v2.model.aws_logs_config import AWSLogsConfig from datadog_api_client.v2.model.aws_metrics_config import AWSMetricsConfig -from datadog_api_client.v2.model.aws_namespace_tag_filter import AWSNamespaceTagFilter +from datadog_api_client.v2.model.aws_resource_type_tag_filter import AWSResourceTypeTagFilter from datadog_api_client.v2.model.aws_resources_config import AWSResourcesConfig from datadog_api_client.v2.model.aws_traces_config import AWSTracesConfig @@ -61,12 +61,13 @@ collect_cloudwatch_alarms=True, collect_custom_metrics=True, enabled=True, - tag_filters=[ - AWSNamespaceTagFilter( - namespace="AWS/EC2", - tags=[ - "key:value", + resource_type_tag_filters=[ + AWSResourceTypeTagFilter( + service="ec2", + resource_types=[ + "instance", ], + expression="env:staging", ), ], ), diff --git a/src/datadog_api_client/v2/model/aws_metrics_config.py b/src/datadog_api_client/v2/model/aws_metrics_config.py index aa917192cf..518598f232 100644 --- a/src/datadog_api_client/v2/model/aws_metrics_config.py +++ b/src/datadog_api_client/v2/model/aws_metrics_config.py @@ -16,6 +16,7 @@ if TYPE_CHECKING: from datadog_api_client.v2.model.aws_metric_name_filters import AWSMetricNameFilters from datadog_api_client.v2.model.aws_namespace_filters import AWSNamespaceFilters + from datadog_api_client.v2.model.aws_resource_type_tag_filter import AWSResourceTypeTagFilter from datadog_api_client.v2.model.aws_namespace_tag_filter import AWSNamespaceTagFilter from datadog_api_client.v2.model.aws_metric_name_filters_include_only import AWSMetricNameFiltersIncludeOnly from datadog_api_client.v2.model.aws_metric_name_filters_exclude_only import AWSMetricNameFiltersExcludeOnly @@ -28,6 +29,7 @@ class AWSMetricsConfig(ModelNormal): def openapi_types(_): from datadog_api_client.v2.model.aws_metric_name_filters import AWSMetricNameFilters from datadog_api_client.v2.model.aws_namespace_filters import AWSNamespaceFilters + from datadog_api_client.v2.model.aws_resource_type_tag_filter import AWSResourceTypeTagFilter from datadog_api_client.v2.model.aws_namespace_tag_filter import AWSNamespaceTagFilter return { @@ -38,6 +40,7 @@ def openapi_types(_): "enabled": (bool,), "metric_name_filters": ([AWSMetricNameFilters],), "namespace_filters": (AWSNamespaceFilters,), + "resource_type_tag_filters": ([AWSResourceTypeTagFilter],), "tag_filters": ([AWSNamespaceTagFilter],), } @@ -49,6 +52,7 @@ def openapi_types(_): "enabled": "enabled", "metric_name_filters": "metric_name_filters", "namespace_filters": "namespace_filters", + "resource_type_tag_filters": "resource_type_tag_filters", "tag_filters": "tag_filters", } @@ -66,6 +70,7 @@ def __init__( namespace_filters: Union[ AWSNamespaceFilters, AWSNamespaceFiltersExcludeOnly, AWSNamespaceFiltersIncludeOnly, UnsetType ] = unset, + resource_type_tag_filters: Union[List[AWSResourceTypeTagFilter], UnsetType] = unset, tag_filters: Union[List[AWSNamespaceTagFilter], UnsetType] = unset, **kwargs, ): @@ -94,7 +99,11 @@ def __init__( :param namespace_filters: AWS Metrics namespace filters. Defaults to ``exclude_only``. :type namespace_filters: AWSNamespaceFilters, optional + :param resource_type_tag_filters: AWS Metrics collection resource type tag filters list. Defaults to ``[]``. + :type resource_type_tag_filters: [AWSResourceTypeTagFilter], optional + :param tag_filters: AWS Metrics collection tag filters list. Defaults to ``[]``. + Deprecated in favor of ``resource_type_tag_filters``. The two fields are mutually exclusive on an account. **Deprecated**. :type tag_filters: [AWSNamespaceTagFilter], optional """ if automute_enabled is not unset: @@ -111,6 +120,8 @@ def __init__( kwargs["metric_name_filters"] = metric_name_filters if namespace_filters is not unset: kwargs["namespace_filters"] = namespace_filters + if resource_type_tag_filters is not unset: + kwargs["resource_type_tag_filters"] = resource_type_tag_filters if tag_filters is not unset: kwargs["tag_filters"] = tag_filters super().__init__(kwargs) diff --git a/src/datadog_api_client/v2/model/aws_resource_type_tag_filter.py b/src/datadog_api_client/v2/model/aws_resource_type_tag_filter.py new file mode 100644 index 0000000000..4686c8be79 --- /dev/null +++ b/src/datadog_api_client/v2/model/aws_resource_type_tag_filter.py @@ -0,0 +1,70 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, Union + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + unset, + UnsetType, +) + + +class AWSResourceTypeTagFilter(ModelNormal): + @cached_property + def openapi_types(_): + return { + "custom": (bool,), + "expression": (str,), + "resource_types": ([str],), + "service": (str,), + } + + attribute_map = { + "custom": "custom", + "expression": "expression", + "resource_types": "resource_types", + "service": "service", + } + + def __init__( + self_, + expression: str, + custom: Union[bool, UnsetType] = unset, + resource_types: Union[List[str], UnsetType] = unset, + service: Union[str, UnsetType] = unset, + **kwargs, + ): + """ + AWS Metrics Collection resource type tag filter. + Each filter targets either a specific AWS service's resource types ( ``service`` and + ``resource_types`` ) or custom metrics ( ``custom`` ). These two modes are mutually exclusive. + The ``expression`` defines a tag filter that Datadog uses when collecting metrics from the + resource types of a specified service. Wildcards, such as ``?`` (match a single character) + and ``*`` (match multiple characters), and exclusion using ``!`` before the tag are supported. + For example, ``env:production AND instance-type:c?.* AND !region:us-east-1``. + + :param custom: Whether the tag filter applies to custom metrics. When ``true`` , ``service`` and ``resource_types`` must be omitted. + :type custom: bool, optional + + :param expression: The tag filter expression to apply when collecting metrics for the matching resource types. + :type expression: str + + :param resource_types: The AWS resource types of the service to which the tag filter applies. Required when ``service`` is set. Use ``*`` as the only entry to match all resource types of the service; ``*`` cannot be combined with specific resource types. + :type resource_types: [str], optional + + :param service: The AWS service for which the tag filter defined in ``expression`` will be applied. Required unless ``custom`` is ``true`` , and must be set together with ``resource_types``. + :type service: str, optional + """ + if custom is not unset: + kwargs["custom"] = custom + if resource_types is not unset: + kwargs["resource_types"] = resource_types + if service is not unset: + kwargs["service"] = service + super().__init__(kwargs) + + self_.expression = expression diff --git a/src/datadog_api_client/v2/models/__init__.py b/src/datadog_api_client/v2/models/__init__.py index e2e4ba94c3..bb42678277 100644 --- a/src/datadog_api_client/v2/models/__init__.py +++ b/src/datadog_api_client/v2/models/__init__.py @@ -165,6 +165,7 @@ from datadog_api_client.v2.model.aws_regions import AWSRegions from datadog_api_client.v2.model.aws_regions_include_all import AWSRegionsIncludeAll from datadog_api_client.v2.model.aws_regions_include_only import AWSRegionsIncludeOnly +from datadog_api_client.v2.model.aws_resource_type_tag_filter import AWSResourceTypeTagFilter from datadog_api_client.v2.model.aws_resources_config import AWSResourcesConfig from datadog_api_client.v2.model.aws_traces_config import AWSTracesConfig from datadog_api_client.v2.model.access_token_list_item import AccessTokenListItem @@ -13281,6 +13282,7 @@ "AWSRegions", "AWSRegionsIncludeAll", "AWSRegionsIncludeOnly", + "AWSResourceTypeTagFilter", "AWSResourcesConfig", "AWSTracesConfig", "AccessTokenListItem", diff --git a/tests/generated-test/test-runner-data/v2/aws-integration/update-an-aws-integration-returns-aws-account-object-response.json b/tests/generated-test/test-runner-data/v2/aws-integration/update-an-aws-integration-returns-aws-account-object-response.json index 702d8a5f9a..89f4975d66 100644 --- a/tests/generated-test/test-runner-data/v2/aws-integration/update-an-aws-integration-returns-aws-account-object-response.json +++ b/tests/generated-test/test-runner-data/v2/aws-integration/update-an-aws-integration-returns-aws-account-object-response.json @@ -48,12 +48,13 @@ "collect_cloudwatch_alarms": true, "collect_custom_metrics": true, "enabled": true, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:staging", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, diff --git a/tests/generated-test/test-server-data/v2/aws-integration.json b/tests/generated-test/test-server-data/v2/aws-integration.json index 251228d560..f3c2688fd6 100644 --- a/tests/generated-test/test-server-data/v2/aws-integration.json +++ b/tests/generated-test/test-server-data/v2/aws-integration.json @@ -2322,7 +2322,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:41.817Z", + "frozen_at": "2026-10-29T18:42:37.045Z", "interactions": [ { "request": { @@ -2374,12 +2374,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -2407,7 +2408,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"9bb08fa5-18b0-49fd-a5d7-b74f930e52b0\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"ef76163b26b04aa2a4d4d6f7be1738f3\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:42.675508202Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:42.675508202Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"b7e6adf3-50b6-40c9-8507-bef4c8b1340a\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"572f3fa14a3c4e75b207a8b3b42f52ef\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:38.167354103Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:38.167354103Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -2500,7 +2501,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/9bb08fa5-18b0-49fd-a5d7-b74f930e52b0", + "path": "/api/v2/integration/aws/accounts/b7e6adf3-50b6-40c9-8507-bef4c8b1340a", "query": [] }, "response": { @@ -2610,7 +2611,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:44.707Z", + "frozen_at": "2026-10-29T18:42:40.083Z", "interactions": [ { "request": { @@ -2662,12 +2663,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -2695,7 +2697,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"f45e01d8-2cc4-45b6-af71-6b3d3bb18dd2\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"9ae7407fac894f8fb2d25bac85a55a89\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:45.592435491Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:45.592435491Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"d8600d61-4d74-40c5-9982-d4cd9c6bbdb0\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"0efc79142195402490b08f0f0f8bad06\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:40.811596716Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:40.811596716Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -2712,7 +2714,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/f45e01d8-2cc4-45b6-af71-6b3d3bb18dd2", + "path": "/api/v2/integration/aws/accounts/d8600d61-4d74-40c5-9982-d4cd9c6bbdb0", "query": [] }, "response": { @@ -2733,7 +2735,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/f45e01d8-2cc4-45b6-af71-6b3d3bb18dd2", + "path": "/api/v2/integration/aws/accounts/d8600d61-4d74-40c5-9982-d4cd9c6bbdb0", "query": [] }, "response": { @@ -2754,7 +2756,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:46.023Z", + "frozen_at": "2026-10-29T18:42:42.739Z", "interactions": [ { "request": { @@ -2806,12 +2808,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -2839,7 +2842,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"b995026f-036d-4303-b2b1-fe6003893f2e\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"707dcccdd8424fb999d08d39a108a593\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:46.926789123Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:46.926789123Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"0f22a1d7-6e4d-4ba7-9930-25844924bea2\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"188e0cebbe854837993669bbf8730fc3\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:43.501578785Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:43.501578785Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -2879,7 +2882,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/b995026f-036d-4303-b2b1-fe6003893f2e", + "path": "/api/v2/integration/aws/accounts/0f22a1d7-6e4d-4ba7-9930-25844924bea2", "query": [] }, "response": { @@ -3022,7 +3025,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:49.517Z", + "frozen_at": "2026-10-29T18:42:45.078Z", "interactions": [ { "request": { @@ -3074,12 +3077,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -3107,7 +3111,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"957a9f7c-72ec-4946-baf4-42f00420f299\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"329146b44caa4f4fa7d0b6478f392c9e\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:50.383382183Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:50.383382183Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"ccbf1424-0fdc-43f4-9917-2b1bba5afbad\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"c1b841679391431daadd656d8212812e\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:45.773027248Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:45.773027248Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -3124,13 +3128,13 @@ }, "content_type": "", "method": "GET", - "path": "/api/v2/integration/aws/accounts/957a9f7c-72ec-4946-baf4-42f00420f299", + "path": "/api/v2/integration/aws/accounts/ccbf1424-0fdc-43f4-9917-2b1bba5afbad", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"957a9f7c-72ec-4946-baf4-42f00420f299\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"329146b44caa4f4fa7d0b6478f392c9e\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:50.383382Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:50.383382Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"ccbf1424-0fdc-43f4-9917-2b1bba5afbad\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"c1b841679391431daadd656d8212812e\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:45.773027Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:45.773027Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -3147,7 +3151,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/957a9f7c-72ec-4946-baf4-42f00420f299", + "path": "/api/v2/integration/aws/accounts/ccbf1424-0fdc-43f4-9917-2b1bba5afbad", "query": [] }, "response": { @@ -3479,7 +3483,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:51.622Z", + "frozen_at": "2026-10-29T18:42:47.661Z", "interactions": [ { "request": { @@ -3531,12 +3535,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -3564,7 +3569,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"ab6528e3-5dab-4375-ae47-4ce93d1216e2\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"36416390710445e7be511e1622ee4149\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:52.510132689Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:52.510132689Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"89f9a444-6fde-4200-bf1e-207f670656a3\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"ea006b0bcebe41b0b7b75b4ad3488012\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:48.309834895Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:48.309834895Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -3613,12 +3618,13 @@ "collect_cloudwatch_alarms": true, "collect_custom_metrics": true, "enabled": true, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:staging", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -3634,13 +3640,13 @@ }, "content_type": "application/json", "method": "PATCH", - "path": "/api/v2/integration/aws/accounts/ab6528e3-5dab-4375-ae47-4ce93d1216e2", + "path": "/api/v2/integration/aws/accounts/89f9a444-6fde-4200-bf1e-207f670656a3", "query": [] }, "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"ab6528e3-5dab-4375-ae47-4ce93d1216e2\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"36416390710445e7be511e1622ee4149\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:52.510132Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":true,\"collect_cloudwatch_alarms\":true,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:52.717094345Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"89f9a444-6fde-4200-bf1e-207f670656a3\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"ea006b0bcebe41b0b7b75b4ad3488012\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:48.309834Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":true,\"collect_cloudwatch_alarms\":true,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:staging\"}]},\"modified_at\":\"2026-10-29T18:42:48.988788064Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -3657,7 +3663,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/ab6528e3-5dab-4375-ae47-4ce93d1216e2", + "path": "/api/v2/integration/aws/accounts/89f9a444-6fde-4200-bf1e-207f670656a3", "query": [] }, "response": { @@ -3676,7 +3682,7 @@ }, { "feature": "AWS Integration", - "frozen_at": "2025-08-06T17:41:53.059Z", + "frozen_at": "2026-10-29T18:42:50.129Z", "interactions": [ { "request": { @@ -3728,12 +3734,13 @@ "AWS/EC2" ] }, - "tag_filters": [ + "resource_type_tag_filters": [ { - "namespace": "AWS/EC2", - "tags": [ - "key:value" - ] + "expression": "env:production", + "resource_types": [ + "instance" + ], + "service": "ec2" } ] }, @@ -3761,7 +3768,7 @@ "response": { "body": { "encoding": "text", - "value": "{\"data\":{\"id\":\"dff6d3ee-e90a-4df1-b0d7-6f4e1ed35acc\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"f3f5392d608c448ca4910d7adcefa849\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2025-08-06T17:41:54.148895503Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"tag_filters\":[{\"namespace\":\"AWS/EC2\",\"tags\":[\"key:value\"]}],\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]}},\"modified_at\":\"2025-08-06T17:41:54.148895503Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" + "value": "{\"data\":{\"id\":\"c318ab3d-8268-4569-a1cc-6a34377538c5\",\"type\":\"account\",\"attributes\":{\"account_tags\":[\"key:value\"],\"auth_config\":{\"role_name\":\"DatadogIntegrationRole\",\"external_id\":\"1a82f333c4244ead862c3cb871a427cf\"},\"aws_account_id\":\"123456789012\",\"aws_partition\":\"aws\",\"aws_regions\":{\"include_only\":[\"us-east-1\"]},\"created_at\":\"2026-10-29T18:42:50.811303572Z\",\"logs_config\":{\"lambda_forwarder\":{\"lambdas\":[\"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"],\"sources\":[\"s3\"],\"log_source_config\":{\"tag_filters\":[{\"source\":\"s3\",\"tags\":[\"test:test\"]}]}}},\"metrics_config\":{\"enabled\":true,\"automute_enabled\":true,\"collect_custom_metrics\":false,\"collect_cloudwatch_alarms\":false,\"namespace_filters\":{\"include_only\":[\"AWS/EC2\"]},\"resource_type_tag_filters\":[{\"service\":\"ec2\",\"resource_types\":[\"instance\"],\"expression\":\"env:production\"}]},\"modified_at\":\"2026-10-29T18:42:50.811303572Z\",\"resources_config\":{\"cloud_security_posture_management_collection\":false,\"extended_collection\":false},\"traces_config\":{\"xray_services\":{\"include_only\":[\"AWS/AppSync\"]}}}}}" }, "headers": { "content-type": "application/vnd.api+json" @@ -3832,7 +3839,7 @@ }, "content_type": "application/json", "method": "PATCH", - "path": "/api/v2/integration/aws/accounts/dff6d3ee-e90a-4df1-b0d7-6f4e1ed35acc", + "path": "/api/v2/integration/aws/accounts/c318ab3d-8268-4569-a1cc-6a34377538c5", "query": [] }, "response": { @@ -3855,7 +3862,7 @@ }, "content_type": "", "method": "DELETE", - "path": "/api/v2/integration/aws/accounts/dff6d3ee-e90a-4df1-b0d7-6f4e1ed35acc", + "path": "/api/v2/integration/aws/accounts/c318ab3d-8268-4569-a1cc-6a34377538c5", "query": [] }, "response": { diff --git a/tests/v2/features/aws_integration.feature b/tests/v2/features/aws_integration.feature index ed35928deb..d24d50e471 100644 --- a/tests/v2/features/aws_integration.feature +++ b/tests/v2/features/aws_integration.feature @@ -315,7 +315,7 @@ Feature: AWS Integration Given there is a valid "aws_account_v2" in the system And new "UpdateAWSAccount" request And request contains "aws_account_config_id" parameter from "aws_account_v2.data.id" - And body with value {"data": {"attributes": {"account_tags": ["key:value"], "auth_config": {"role_name": "DatadogIntegrationRole"}, "aws_account_id": "123456789012", "aws_partition": "aws", "logs_config": {"lambda_forwarder": {"lambdas": ["arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder"], "log_source_config": {"tag_filters": [{"source": "s3", "tags": ["test:test"]}]}, "sources": ["s3"]}}, "metrics_config": {"automute_enabled": true, "collect_cloudwatch_alarms": true, "collect_custom_metrics": true, "enabled": true, "tag_filters": [{"namespace": "AWS/EC2", "tags": ["key:value"]}]}, "resources_config": {"cloud_security_posture_management_collection": false, "extended_collection": false}, "traces_config": {}}, "type": "account"}} + And body with value {"data": {"attributes": {"account_tags": ["key:value"], "auth_config": {"role_name": "DatadogIntegrationRole"}, "aws_account_id": "123456789012", "aws_partition": "aws", "logs_config": {"lambda_forwarder": {"lambdas": ["arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder"], "log_source_config": {"tag_filters": [{"source": "s3", "tags": ["test:test"]}]}, "sources": ["s3"]}}, "metrics_config": {"automute_enabled": true, "collect_cloudwatch_alarms": true, "collect_custom_metrics": true, "enabled": true, "resource_type_tag_filters": [{"service": "ec2", "resource_types": ["instance"], "expression": "env:staging"}]}, "resources_config": {"cloud_security_posture_management_collection": false, "extended_collection": false}, "traces_config": {}}, "type": "account"}} When the request is sent Then the response status is 200 AWS Account object diff --git a/tests/v2/features/given.json b/tests/v2/features/given.json index 133777e08d..1ad94b9693 100644 --- a/tests/v2/features/given.json +++ b/tests/v2/features/given.json @@ -854,7 +854,7 @@ "parameters": [ { "name": "body", - "value": "{\n \"data\": {\n \"type\": \"account\",\n \"attributes\": {\n \"account_tags\": [\n \"key:value\"\n ],\n \"auth_config\": {\n \"role_name\": \"DatadogIntegrationRole\"\n },\n \"aws_account_id\": \"123456789012\",\n \"aws_partition\": \"aws\",\n \"aws_regions\": {\n \"include_only\": [\n \"us-east-1\"\n ]\n },\n \"logs_config\": {\n \"lambda_forwarder\": {\n \"lambdas\": [\n \"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"\n ],\n \"sources\": [\n \"s3\"\n ],\n \"log_source_config\": {\n \"tag_filters\": [\n {\n \"source\": \"s3\",\n \"tags\": [\"test:test\"]\n }\n ]\n }\n }\n },\n \"metrics_config\": {\n \"enabled\": true,\n \"automute_enabled\": true,\n \"collect_custom_metrics\": false,\n \"collect_cloudwatch_alarms\": false,\n \"tag_filters\": [\n {\n \"namespace\": \"AWS/EC2\",\n \"tags\": [\n \"key:value\"\n ]\n }\n ],\n \"namespace_filters\": {\n \"include_only\": [\n \"AWS/EC2\"\n ]\n }\n },\n \"resources_config\": {\n \"cloud_security_posture_management_collection\": false,\n \"extended_collection\": false\n },\n \"traces_config\": {\n \"xray_services\": {\n \"include_only\": [\n \"AWS/AppSync\"\n ]\n }\n }\n }\n }\n}" + "value": "{\n \"data\": {\n \"type\": \"account\",\n \"attributes\": {\n \"account_tags\": [\n \"key:value\"\n ],\n \"auth_config\": {\n \"role_name\": \"DatadogIntegrationRole\"\n },\n \"aws_account_id\": \"123456789012\",\n \"aws_partition\": \"aws\",\n \"aws_regions\": {\n \"include_only\": [\n \"us-east-1\"\n ]\n },\n \"logs_config\": {\n \"lambda_forwarder\": {\n \"lambdas\": [\n \"arn:aws:lambda:us-east-1:123456789012:function:DatadogLambdaLogForwarder\"\n ],\n \"sources\": [\n \"s3\"\n ],\n \"log_source_config\": {\n \"tag_filters\": [\n {\n \"source\": \"s3\",\n \"tags\": [\"test:test\"]\n }\n ]\n }\n }\n },\n \"metrics_config\": {\n \"enabled\": true,\n \"automute_enabled\": true,\n \"collect_custom_metrics\": false,\n \"collect_cloudwatch_alarms\": false,\n \"resource_type_tag_filters\": [\n {\n \"service\": \"ec2\",\n \"resource_types\": [\n \"instance\"\n ],\n \"expression\": \"env:production\"\n }\n ],\n \"namespace_filters\": {\n \"include_only\": [\n \"AWS/EC2\"\n ]\n }\n },\n \"resources_config\": {\n \"cloud_security_posture_management_collection\": false,\n \"extended_collection\": false\n },\n \"traces_config\": {\n \"xray_services\": {\n \"include_only\": [\n \"AWS/AppSync\"\n ]\n }\n }\n }\n }\n}" } ], "step": "there is a valid \"aws_account_v2\" in the system",