list_resource_scan_related_resources
async
¶
list_resource_scan_related_resources(
*,
config_overrides: Optional[AsyncCloudFormationClientConfig] = None,
resource_scan_id: Optional[ResourceScanId] = None,
resources: Optional[ScannedResourceIdentifiers] = None,
next_token: Optional[NextToken] = None,
max_results: Optional[BoxedMaxResults] = None,
) -> ListResourceScanRelatedResourcesOutput
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:
-
resource_scan_id(Optional[ResourceScanId], default:None) –The Amazon Resource Name (ARN) of the resource scan.
-
resources(Optional[ScannedResourceIdentifiers], default:None) –The list of resources for which you want to get the related resources. Up to 100 resources can be provided.
-
next_token(Optional[NextToken], default:None) –The token for the next set of items to return. (You received this token from a previous call.)
-
max_results(Optional[BoxedMaxResults], default:None) –If the number of available results exceeds this maximum, the response includes a
NextTokenvalue that you can use for theNextTokenparameter to get the next set of results. By default theListResourceScanRelatedResourcesAPI action will return up to 100 results in each response. The maximum value is 100.
Raises:
-
ResourceScanInProgressException–A resource scan is currently in progress. Only one can be run at a time for an account in a Region.
-
ResourceScanNotFoundException–The resource scan was not found.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To list resource scan related resources This example lists the resources related to the passed in resources
>>> await client.list_resource_scan_related_resources(resource_scan_id='arn:aws:cloudformation:us-east-1:123456789012:resourceScan/c19304f6-c4f1-4ff8-8e1f-35162e41d7e1', resources=[{'ResourceType': 'AWS::S3::Bucket', 'ResourceIdentifier': {'BucketName': 'jazz-bucket'}}, {'ResourceType': 'AWS::EC2::DHCPOptions', 'ResourceIdentifier': {'DhcpOptionsId': 'random-id123'}}])
Source code in docs_src/capo_cloudformation/_services/async_cloud_formation.py
4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 | |