DirectoryServiceData / Client / list_groups
list_groups#
- DirectoryServiceData.Client.list_groups(**kwargs)#
Returns group information for the specified directory.
This operation supports pagination with the use of the
NextToken
request and response parameters. If more results are available, theListGroups.NextToken
member contains a token that you pass in the next call toListGroups
. This retrieves the next set of items.You can also specify a maximum number of return results with the
MaxResults
parameter.See also: AWS API Documentation
Request Syntax
response = client.list_groups( DirectoryId='string', MaxResults=123, NextToken='string', Realm='string' )
- Parameters:
DirectoryId (string) –
[REQUIRED]
The identifier (ID) of the directory that’s associated with the group.
MaxResults (integer) – The maximum number of results to be returned per request.
NextToken (string) – An encoded paging token for paginated calls that can be passed back to retrieve the next page.
Realm (string) –
The domain name associated with the directory.
Note
This parameter is optional, so you can return groups outside of your Managed Microsoft AD domain. When no value is defined, only your Managed Microsoft AD groups are returned.
This value is case insensitive.
- Return type:
dict
- Returns:
Response Syntax
{ 'DirectoryId': 'string', 'Groups': [ { 'GroupScope': 'DomainLocal'|'Global'|'Universal'|'BuiltinLocal', 'GroupType': 'Distribution'|'Security', 'SAMAccountName': 'string', 'SID': 'string' }, ], 'NextToken': 'string', 'Realm': 'string' }
Response Structure
(dict) –
DirectoryId (string) –
The identifier (ID) of the directory that’s associated with the group.
Groups (list) –
The group information that the request returns.
(dict) –
A structure containing a subset of fields of a group object from a directory.
GroupScope (string) –
The scope of the AD group. For details, see Active Directory security groups.
GroupType (string) –
The AD group type. For details, see Active Directory security group type.
SAMAccountName (string) –
The name of the group.
SID (string) –
The unique security identifier (SID) of the group.
NextToken (string) –
An encoded paging token for paginated calls that can be passed back to retrieve the next page.
Realm (string) –
The domain name associated with the group.
Exceptions
DirectoryServiceData.Client.exceptions.AccessDeniedException
DirectoryServiceData.Client.exceptions.InternalServerException
DirectoryServiceData.Client.exceptions.ValidationException
DirectoryServiceData.Client.exceptions.DirectoryUnavailableException
DirectoryServiceData.Client.exceptions.ThrottlingException