disableUser method
Future<void>
disableUser({
- required AuthenticationType authenticationType,
- required String userName,
Disables the specified user in the user pool. Users can't sign in to WorkSpaces Applications until they are re-enabled. This action does not delete the user.
May throw ResourceNotFoundException.
Parameter authenticationType :
The authentication type for the user. You must specify USERPOOL.
Parameter userName :
The email address of the user.
Implementation
Future<void> disableUser({
required AuthenticationType authenticationType,
required String userName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'PhotonAdminProxyService.DisableUser'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'AuthenticationType': authenticationType.value,
'UserName': userName,
},
);
}