CmdID / aws / aws configservice
aws configservice list-discovered-resources
Returns a list of resource resource identifiers for the specified resource types for the resources of that type. AWS CLI reference
1 example 6 options Its page in the AWS CLI reference
Examples
To list resources that AWS Config has discovered
The following list-discovered-resources example lists the EC2 instances that AWS Config has discovered.
aws configservice list-discovered-resources --resource-type AWS::EC2::InstanceIdentify--resource-typeThe type of resources that you want Config to list in the response.Its output
{
"resourceIdentifiers": [
{
"resourceType": "AWS::EC2::Instance",
"resourceId": "i-1a2b3c4d"
},
{
"resourceType": "AWS::EC2::Instance",
"resourceId": "i-2a2b3c4d"
},
{
"resourceType": "AWS::EC2::Instance",
"resourceId": "i-3a2b3c4d"
}
]
}For more information, see Looking Up Resources That Are Discovered by AWS Config in the AWS Config Developer Guide.
Options
--include-deleted-resourcesSpecifies whether Config includes deleted resources in the results.--limitThe maximum number of resource identifiers returned on each page.--next-tokenThe nextToken string returned on a previous page that you use to get the next page of results in a paginated response.--resource-idsThe IDs of only those resources that you want Config to list in the response.--resource-nameThe custom name of only those resources that you want Config to list in the response.--resource-typeThe type of resources that you want Config to list in the response.