resource_scan_related_resources
Creates, updates, deletes, gets or lists a resource_scan_related_resources resource.
Overview
| Name | resource_scan_related_resources |
| Type | Resource |
| Id | aws.cloudformation.resource_scan_related_resources |
Fields
The following fields are returned by SELECT queries:
- list_resource_scan_related_resources
| Name | Datatype | Description |
|---|---|---|
managed_by_stack | boolean | If true, the resource is managed by a CloudFormation stack. |
resource_identifier | string | A 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_type | string | The 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:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list_resource_scan_related_resources | select | ResourceScanId, Resources, region | NextToken, MaxResults | Lists the related resources for a list of resources from a resource scan. 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.
| Name | Datatype | Description |
|---|---|---|
ResourceScanId | string | The Amazon Resource Name (ARN) of the resource scan. |
Resources | array | The list of resources for which you want to get the related resources. Up to 100 resources can be provided. |
region | string | AWS region (default: us-east-1) |
MaxResults | integer | If 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 ListResourceScanRelatedResources API action will return up to 100 results in each response. The maximum value is 100. |
NextToken | string | The token for the next set of items to return. (You received this token from a previous call.) |
SELECT examples
- list_resource_scan_related_resources
Lists the related resources for a list of resources from a resource scan. 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_related_resources
WHERE ResourceScanId = '{{ ResourceScanId }}' -- required
AND Resources = '{{ Resources }}' -- required
AND region = '{{ region }}' -- required
AND NextToken = '{{ NextToken }}'
AND MaxResults = '{{ MaxResults }}'
;