describeUser method
Returns information about a specific user.
May throw AccessDeniedException.
May throw DirectoryUnavailableException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter directoryId :
The identifier (ID) of the directory that's associated with the user.
Parameter sAMAccountName :
The name of the user.
Parameter otherAttributes :
One or more attribute names to be returned for the user. A key is an
attribute name, and the value is a list of maps. For a list of supported
attributes, see Directory
Service Data Attributes.
Parameter realm :
The domain name that's associated with the user.
This value is case insensitive.
Implementation
Future<DescribeUserResult> describeUser({
required String directoryId,
required String sAMAccountName,
List<String>? otherAttributes,
String? realm,
}) async {
final $query = <String, List<String>>{
'DirectoryId': [directoryId],
};
final $payload = <String, dynamic>{
'SAMAccountName': sAMAccountName,
if (otherAttributes != null) 'OtherAttributes': otherAttributes,
if (realm != null) 'Realm': realm,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/Users/DescribeUser',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return DescribeUserResult.fromJson(response);
}