This endpoint is deprecated - use the V2 endpoints instead. List all Datadog-AWS integrations available in your Datadog organization.
This endpoint requires the aws_configuration_read permission.
Arguments
Query Strings
Name
Type
Description
account_id
string
Only return AWS accounts that matches this account_id.
role_name
string
Only return AWS accounts that matches this role_name.
access_key_id
string
Only return AWS accounts that matches this access_key_id.
Your AWS access key ID. Only required if your AWS account is a GovCloud or China account.
account_id
string
Your AWS Account ID without dashes.
account_specific_namespace_rules
object
An object (in the form {"namespace1":true/false, "namespace2":true/false}) containing user-supplied overrides
for AWS namespace metric collection. Important: This field only contains namespaces explicitly configured through API calls,
not the comprehensive enabled or disabled status of all namespaces. If a namespace is absent from this field, it uses Datadog's
internal defaults (all namespaces enabled by default, except AWS/SQS, AWS/ElasticMapReduce, and AWS/Usage).
For a complete view of all namespace statuses, use the V2 AWS Integration API instead.
<any-key>
boolean
A list of additional properties.
cspm_resource_collection_enabled
boolean
Whether Datadog collects cloud security posture management resources from your AWS account. This includes additional resources not covered under the general resource_collection.
excluded_regions
[string]
An array of AWS regions
to exclude from metrics collection.
extended_resource_collection_enabled
boolean
Whether Datadog collects additional attributes and configuration information about the resources in your AWS account. Required for cspm_resource_collection.
filter_tags
[string]
The array of EC2 tags (in the form key:value) defines a filter that Datadog uses when collecting metrics from EC2.
Wildcards, such as ? (for single characters) and * (for multiple characters) can also be used.
Only hosts that match one of the defined tags
will be imported into Datadog. The rest will be ignored.
Host matching a given tag can also be excluded by adding ! before the tag.
For example, env:production,instance-type:c1.*,!region:us-east-1
host_tags
[string]
Array of tags (in the form key:value) to add to all hosts
and metrics reporting through this integration.
metrics_collection_enabled
boolean
Whether Datadog collects metrics for this AWS account.
default: true
resource_collection_enabled
boolean
DEPRECATED: Deprecated in favor of 'extended_resource_collection_enabled'. Whether Datadog collects a standard set of resources from your AWS account.
role_name
string
Your Datadog role delegation name.
secret_access_key
string
Your AWS secret access key. Only required if your AWS account is a GovCloud or China account.
"""
List all AWS integrations returns "OK" response
"""fromdatadog_api_clientimportApiClient,Configurationfromdatadog_api_client.v1.api.aws_integration_apiimportAWSIntegrationApiconfiguration=Configuration()withApiClient(configuration)asapi_client:api_instance=AWSIntegrationApi(api_client)response=api_instance.list_aws_accounts()print(response)
# List all AWS integrations returns "OK" responserequire"datadog_api_client"api_instance=DatadogAPIClient::V1::AWSIntegrationAPI.newpapi_instance.list_aws_accounts()
// List all AWS integrations returns "OK" responsepackagemainimport("context""encoding/json""fmt""os""github.com/DataDog/datadog-api-client-go/v2/api/datadog""github.com/DataDog/datadog-api-client-go/v2/api/datadogV1")funcmain(){ctx:=datadog.NewDefaultContext(context.Background())configuration:=datadog.NewConfiguration()apiClient:=datadog.NewAPIClient(configuration)api:=datadogV1.NewAWSIntegrationApi(apiClient)resp,r,err:=api.ListAWSAccounts(ctx,*datadogV1.NewListAWSAccountsOptionalParameters())iferr!=nil{fmt.Fprintf(os.Stderr,"Error when calling `AWSIntegrationApi.ListAWSAccounts`: %v\n",err)fmt.Fprintf(os.Stderr,"Full HTTP response: %v\n",r)}responseContent,_:=json.MarshalIndent(resp,""," ")fmt.Fprintf(os.Stdout,"Response from `AWSIntegrationApi.ListAWSAccounts`:\n%s\n",responseContent)}
// List all AWS integrations returns "OK" response
usedatadog_api_client::datadog;usedatadog_api_client::datadogV1::api_aws_integration::AWSIntegrationAPI;usedatadog_api_client::datadogV1::api_aws_integration::ListAWSAccountsOptionalParams;#[tokio::main]asyncfnmain(){letconfiguration=datadog::Configuration::new();letapi=AWSIntegrationAPI::with_config(configuration);letresp=api.list_aws_accounts(ListAWSAccountsOptionalParams::default()).await;ifletOk(value)=resp{println!("{:#?}",value);}else{println!("{:#?}",resp.unwrap_err());}}
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comap2.datadoghq.comddog-gov.comus2.ddog-gov.com"DD_API_KEY="<API-KEY>"DD_APP_KEY="<APP-KEY>"cargo run
/**
* List all AWS integrations returns "OK" response
*/import{client,v1}from"@datadog/datadog-api-client";constconfiguration=client.createConfiguration();constapiInstance=newv1.AWSIntegrationApi(configuration);apiInstance.listAWSAccounts().then((data: v1.AWSAccountListResponse)=>{console.log("API called successfully. Returned data: "+JSON.stringify(data));}).catch((error: any)=>console.error(error));
Tags to apply to all hosts and metrics reporting for this account. Defaults to [].
auth_config
<oneOf>
AWS Authentication config.
Option 1
object
AWS Authentication config to integrate your account using an access key pair.
access_key_id [required]
string
AWS Access Key ID.
secret_access_key
string
AWS Secret Access Key.
Option 2
object
AWS Authentication config to integrate your account using an IAM role.
external_id
string
AWS IAM External ID for associated role.
role_name [required]
string
AWS IAM Role name.
aws_account_id [required]
string
AWS Account ID.
aws_partition
enum
AWS partition your AWS account is scoped to. Defaults to aws.
See Partitions
in the AWS documentation for more information.
Allowed enum values: aws,aws-cn,aws-us-gov
aws_regions
<oneOf>
AWS Regions to collect data from. Defaults to include_all.
Option 1
object
Include all regions. Defaults to true.
include_all [required]
boolean
Include all regions.
Option 2
object
Include only these regions.
include_only [required]
[string]
Include only these regions.
created_at
date-time
Timestamp of when the account integration was created.
logs_config
object
AWS Logs Collection config.
lambda_forwarder
object
Log Autosubscription configuration for Datadog Forwarder Lambda functions.
Automatically set up triggers for existing and new logs for some services,
ensuring no logs from new resources are missed and saving time spent on manual configuration.
lambdas
[string]
List of Datadog Lambda Log Forwarder ARNs in your AWS account. Defaults to [].
log_source_config
object
Log source configuration.
tag_filters
[object]
List of AWS log source tag filters. Defaults to [].
source
string
The AWS log source to which the tag filters defined in tags are applied.
tags
[string]
The AWS resource tags to filter on for the log source specified by source.
sources
[string]
List of service IDs set to enable automatic log collection.
Discover the list of available services with the
Get list of AWS log ready
services
endpoint.
metrics_config
object
AWS Metrics Collection config.
automute_enabled
boolean
Enable EC2 automute for AWS metrics. Defaults to true.
collect_cloudwatch_alarms
boolean
Enable CloudWatch alarms collection. Defaults to false.
collect_custom_metrics
boolean
Enable custom metrics collection. Defaults to false.
enabled
boolean
Enable AWS metrics collection. Defaults to true.
namespace_filters
<oneOf>
AWS Metrics namespace filters. Defaults to exclude_only.
Option 1
object
Exclude only these namespaces from metrics collection.
Defaults to ["AWS/SQS", "AWS/ElasticMapReduce", "AWS/Usage"].
AWS/SQS, AWS/ElasticMapReduce, and AWS/Usage are excluded by default
to reduce your AWS CloudWatch costs from GetMetricData API calls.
exclude_only [required]
[string]
Exclude only these namespaces from metrics collection.
Defaults to ["AWS/SQS", "AWS/ElasticMapReduce", "AWS/Usage"].
AWS/SQS, AWS/ElasticMapReduce, and AWS/Usage are excluded by default
to reduce your AWS CloudWatch costs from GetMetricData API calls.
Option 2
object
Include only these namespaces.
include_only [required]
[string]
Include only these namespaces.
tag_filters
[object]
AWS Metrics collection tag filters list. Defaults to [].
namespace
string
The AWS service for which the tag filters defined in tags will be applied.
tags
[string]
The AWS resource tags to filter on for the service specified by namespace.
modified_at
date-time
Timestamp of when the account integration was updated.
resources_config
object
AWS Resources Collection config.
cloud_security_posture_management_collection
boolean
Enable Cloud Security Management to scan AWS resources for vulnerabilities, misconfigurations,
identity risks, and compliance violations. Defaults to false.
Requires extended_collection to be set to true.
extended_collection
boolean
Whether Datadog collects additional attributes and configuration information about the resources
in your AWS account. Defaults to true. Required for cloud_security_posture_management_collection.
traces_config
object
AWS Traces Collection config.
xray_services
<oneOf>
AWS X-Ray services to collect traces from. Defaults to include_only.
Option 1
object
Include all services.
include_all [required]
boolean
Include all services.
Option 2
object
Include only these services. Defaults to [].
include_only [required]
[string]
Include only these services.
id [required]
string
Unique Datadog ID of the AWS Account Integration Config.
To get the config ID for an account, use the
List all AWS integrations
endpoint and query by AWS Account ID.
"""
List all AWS integrations returns "AWS Accounts List object" response
"""fromdatadog_api_clientimportApiClient,Configurationfromdatadog_api_client.v2.api.aws_integration_apiimportAWSIntegrationApiconfiguration=Configuration()withApiClient(configuration)asapi_client:api_instance=AWSIntegrationApi(api_client)response=api_instance.list_aws_accounts()print(response)
# List all AWS integrations returns "AWS Accounts List object" responserequire"datadog_api_client"api_instance=DatadogAPIClient::V2::AWSIntegrationAPI.newpapi_instance.list_aws_accounts()
// List all AWS integrations returns "AWS Accounts List object" responsepackagemainimport("context""encoding/json""fmt""os""github.com/DataDog/datadog-api-client-go/v2/api/datadog""github.com/DataDog/datadog-api-client-go/v2/api/datadogV2")funcmain(){ctx:=datadog.NewDefaultContext(context.Background())configuration:=datadog.NewConfiguration()apiClient:=datadog.NewAPIClient(configuration)api:=datadogV2.NewAWSIntegrationApi(apiClient)resp,r,err:=api.ListAWSAccounts(ctx,*datadogV2.NewListAWSAccountsOptionalParameters())iferr!=nil{fmt.Fprintf(os.Stderr,"Error when calling `AWSIntegrationApi.ListAWSAccounts`: %v\n",err)fmt.Fprintf(os.Stderr,"Full HTTP response: %v\n",r)}responseContent,_:=json.MarshalIndent(resp,""," ")fmt.Fprintf(os.Stdout,"Response from `AWSIntegrationApi.ListAWSAccounts`:\n%s\n",responseContent)}
// List all AWS integrations returns "AWS Accounts List object" responseimportcom.datadog.api.client.ApiClient;importcom.datadog.api.client.ApiException;importcom.datadog.api.client.v2.api.AwsIntegrationApi;importcom.datadog.api.client.v2.model.AWSAccountsResponse;publicclassExample{publicstaticvoidmain(String[]args){ApiClientdefaultClient=ApiClient.getDefaultApiClient();AwsIntegrationApiapiInstance=newAwsIntegrationApi(defaultClient);try{AWSAccountsResponseresult=apiInstance.listAWSAccounts();System.out.println(result);}catch(ApiExceptione){System.err.println("Exception when calling AwsIntegrationApi#listAWSAccounts");System.err.println("Status code: "+e.getCode());System.err.println("Reason: "+e.getResponseBody());System.err.println("Response headers: "+e.getResponseHeaders());e.printStackTrace();}}}
// List all AWS integrations returns "AWS Accounts List object" response
usedatadog_api_client::datadog;usedatadog_api_client::datadogV2::api_aws_integration::AWSIntegrationAPI;usedatadog_api_client::datadogV2::api_aws_integration::ListAWSAccountsOptionalParams;#[tokio::main]asyncfnmain(){letconfiguration=datadog::Configuration::new();letapi=AWSIntegrationAPI::with_config(configuration);letresp=api.list_aws_accounts(ListAWSAccountsOptionalParams::default()).await;ifletOk(value)=resp{println!("{:#?}",value);}else{println!("{:#?}",resp.unwrap_err());}}
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comap2.datadoghq.comddog-gov.comus2.ddog-gov.com"DD_API_KEY="<API-KEY>"DD_APP_KEY="<APP-KEY>"cargo run
/**
* List all AWS integrations returns "AWS Accounts List object" response
*/import{client,v2}from"@datadog/datadog-api-client";constconfiguration=client.createConfiguration();constapiInstance=newv2.AWSIntegrationApi(configuration);apiInstance.listAWSAccounts().then((data: v2.AWSAccountsResponse)=>{console.log("API called successfully. Returned data: "+JSON.stringify(data));}).catch((error: any)=>console.error(error));