Organizations / Paginator / ListPoliciesForTarget
ListPoliciesForTarget#
- class Organizations.Paginator.ListPoliciesForTarget#
paginator = client.get_paginator('list_policies_for_target')
- paginate(**kwargs)#
Creates an iterator that will paginate through responses from
Organizations.Client.list_policies_for_target()
.See also: AWS API Documentation
Request Syntax
response_iterator = paginator.paginate( TargetId='string', Filter='SERVICE_CONTROL_POLICY'|'RESOURCE_CONTROL_POLICY'|'TAG_POLICY'|'BACKUP_POLICY'|'AISERVICES_OPT_OUT_POLICY'|'CHATBOT_POLICY', PaginationConfig={ 'MaxItems': 123, 'PageSize': 123, 'StartingToken': 'string' } )
- Parameters:
TargetId (string) –
[REQUIRED]
The unique identifier (ID) of the root, organizational unit, or account whose policies you want to list.
The regex pattern for a target ID string requires one of the following:
Root - A string that begins with “r-” followed by from 4 to 32 lowercase letters or digits.
Account - A string that consists of exactly 12 digits.
Organizational unit (OU) - A string that begins with “ou-” followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second “-” dash and from 8 to 32 additional lowercase letters or digits.
Filter (string) –
[REQUIRED]
The type of policy that you want to include in the returned list. You must specify one of the following values:
PaginationConfig (dict) –
A dictionary that provides parameters to control pagination.
MaxItems (integer) –
The total number of items to return. If the total number of items available is more than the value specified in max-items then a
NextToken
will be provided in the output that you can use to resume pagination.PageSize (integer) –
The size of each page.
StartingToken (string) –
A token to specify where to start paginating. This is the
NextToken
from a previous response.
- Return type:
dict
- Returns:
Response Syntax
{ 'Policies': [ { 'Id': 'string', 'Arn': 'string', 'Name': 'string', 'Description': 'string', 'Type': 'SERVICE_CONTROL_POLICY'|'RESOURCE_CONTROL_POLICY'|'TAG_POLICY'|'BACKUP_POLICY'|'AISERVICES_OPT_OUT_POLICY'|'CHATBOT_POLICY', 'AwsManaged': True|False }, ], }
Response Structure
(dict) –
Policies (list) –
The list of policies that match the criteria in the request.
(dict) –
Contains information about a policy, but does not include the content. To see the content of a policy, see DescribePolicy.
Id (string) –
The unique identifier (ID) of the policy.
The regex pattern for a policy ID string requires “p-” followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).
Arn (string) –
The Amazon Resource Name (ARN) of the policy.
For more information about ARNs in Organizations, see ARN Formats Supported by Organizations in the Amazon Web Services Service Authorization Reference.
Name (string) –
The friendly name of the policy.
The regex pattern that is used to validate this parameter is a string of any of the characters in the ASCII character range.
Description (string) –
The description of the policy.
Type (string) –
The type of policy.
AwsManaged (boolean) –
A boolean value that indicates whether the specified policy is an Amazon Web Services managed policy. If true, then you can attach the policy to roots, OUs, or accounts, but you cannot edit it.