Skip to main content

resource_scan_resources

Creates, updates, deletes, gets or lists a resource_scan_resources resource.

Overview

Nameresource_scan_resources
TypeResource
Idaws.cloudformation.resource_scan_resources

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
managed_by_stackbooleanIf true, the resource is managed by a CloudFormation stack.
resource_identifierstringA list of up to 256 key-value pairs that identifies for the scanned resource. The key is the name of one of the primary identifiers for the resource. (Primary identifiers are specified in the primaryIdentifier list in the resource schema.) The value is the value of that primary identifier. For example, for a AWS::DynamoDB::Table resource, the primary identifiers is TableName so the key-value pair could be "TableName": "MyDDBTable". For more information, see primaryIdentifier in the CloudFormation Command Line Interface (CLI) User Guide.
resource_typestringThe type of the resource, such as AWS::DynamoDB::Table. For the list of supported resources, see Resource type support for imports and drift detection In the CloudFormation User Guide

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_resource_scan_resourcesselectResourceScanId, regionResourceIdentifier, ResourceTypePrefix, TagKey, TagValue, NextToken, MaxResultsLists the resources from a resource scan. The results can be filtered by resource identifier, resource type prefix, tag key, and tag value. Only resources that match all specified filters are returned. The response indicates whether each returned resource is already managed by CloudFormation.

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.

NameDatatypeDescription
ResourceScanIdstringThe Amazon Resource Name (ARN) of the resource scan.
regionstringAWS region (default: us-east-1)
MaxResultsintegerIf the number of available results exceeds this maximum, the response includes a NextToken value that you can use for the NextToken parameter to get the next set of results. By default the ListResourceScanResources API action will return at most 100 results in each response. The maximum value is 100.
NextTokenstringThe token for the next set of items to return. (You received this token from a previous call.)
ResourceIdentifierstringIf specified, the returned resources will have the specified resource identifier (or one of them in the case where the resource has multiple identifiers).
ResourceTypePrefixstringIf specified, the returned resources will be of any of the resource types with the specified prefix.
TagKeystringIf specified, the returned resources will have a matching tag key.
TagValuestringIf specified, the returned resources will have a matching tag value.

SELECT examples

Lists the resources from a resource scan. The results can be filtered by resource identifier, resource type prefix, tag key, and tag value. Only resources that match all specified filters are returned. The response indicates whether each returned resource is already managed by CloudFormation.

SELECT
managed_by_stack,
resource_identifier,
resource_type
FROM aws.cloudformation.resource_scan_resources
WHERE ResourceScanId = '{{ ResourceScanId }}' -- required
AND region = '{{ region }}' -- required
AND ResourceIdentifier = '{{ ResourceIdentifier }}'
AND ResourceTypePrefix = '{{ ResourceTypePrefix }}'
AND TagKey = '{{ TagKey }}'
AND TagValue = '{{ TagValue }}'
AND NextToken = '{{ NextToken }}'
AND MaxResults = '{{ MaxResults }}'
;