IoT / Client / list_targets_for_policy

list_targets_for_policy#

IoT.Client.list_targets_for_policy(**kwargs)#

List targets for the specified policy.

Requires permission to access the ListTargetsForPolicy action.

See also: AWS API Documentation

Request Syntax

response = client.list_targets_for_policy(
    policyName='string',
    marker='string',
    pageSize=123
)
Parameters:
  • policyName (string) –

    [REQUIRED]

    The policy name.

  • marker (string) – A marker used to get the next set of results.

  • pageSize (integer) – The maximum number of results to return at one time.

Return type:

dict

Returns:

Response Syntax

{
    'targets': [
        'string',
    ],
    'nextMarker': 'string'
}

Response Structure

  • (dict) –

    • targets (list) –

      The policy targets.

      • (string) –

    • nextMarker (string) –

      A marker used to get the next set of results.

Exceptions

  • IoT.Client.exceptions.ResourceNotFoundException

  • IoT.Client.exceptions.InvalidRequestException

  • IoT.Client.exceptions.ThrottlingException

  • IoT.Client.exceptions.UnauthorizedException

  • IoT.Client.exceptions.ServiceUnavailableException

  • IoT.Client.exceptions.InternalFailureException

  • IoT.Client.exceptions.LimitExceededException