RAM.Paginator.ListPrincipals¶paginator = client.get_paginator('list_principals')
paginate(**kwargs)¶Creates an iterator that will paginate through responses from RAM.Client.list_principals().
See also: AWS API Documentation
Request Syntax
response_iterator = paginator.paginate(
resourceOwner='SELF'|'OTHER-ACCOUNTS',
resourceArn='string',
principals=[
'string',
],
resourceType='string',
resourceShareArns=[
'string',
],
PaginationConfig={
'MaxItems': 123,
'PageSize': 123,
'StartingToken': 'string'
}
)
[REQUIRED]
Specifies that you want to list information for only resource shares that match the following:
SELF – principals that your account is sharing resources withOTHER-ACCOUNTS – principals that are sharing resources with your accountSpecifies that you want to list information for only the listed principals.
You can include the following values:
123456789012organizations::123456789012:organization/o-exampleorgidorganizations::123456789012:ou/o-exampleorgid/ou-examplerootid-exampleouid123iam::123456789012:role/rolenameiam::123456789012user/usernameNote
Not all resource types can be shared with IAM roles and users. For more information, see Sharing with IAM roles and users in the Resource Access Manager User Guide .
Specifies that you want to list information for only principals associated with resource shares that include the specified resource type.
For a list of valid values, query the ListResourceTypes operation.
Specifies that you want to list information for only principals associated with the resource shares specified by a list the Amazon Resource Names (ARNs).
A dictionary that provides parameters to control pagination.
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.
The size of each page.
A token to specify where to start paginating. This is the NextToken from a previous response.
dict
Response Syntax
{
'principals': [
{
'id': 'string',
'resourceShareArn': 'string',
'creationTime': datetime(2015, 1, 1),
'lastUpdatedTime': datetime(2015, 1, 1),
'external': True|False
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
principals (list) --
An array of objects that contain the details about the principals.
(dict) --
Describes a principal for use with Resource Access Manager.
id (string) --
The ID of the principal.
resourceShareArn (string) --
The Amazon Resoure Name (ARN) of a resource share the principal is associated with.
creationTime (datetime) --
The date and time when the principal was associated with the resource share.
lastUpdatedTime (datetime) --
The date and time when the association was last updated.
external (boolean) --
Indicates whether the principal belongs to the same organization in Organizations as the Amazon Web Services account that owns the resource share.
NextToken (string) --
A token to resume pagination.