updateUser method
Updates a information associated with a user id.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter applicationId :
The identifier of the application the user is attached to.
Parameter userId :
The email id attached to the user.
Parameter userAliasesToDelete :
The user aliases attached to the user id that are to be deleted.
Parameter userAliasesToUpdate :
The user aliases attached to the user id that are to be updated.
Implementation
Future<UpdateUserResponse> updateUser({
required String applicationId,
required String userId,
List<UserAlias>? userAliasesToDelete,
List<UserAlias>? userAliasesToUpdate,
}) async {
final $payload = <String, dynamic>{
if (userAliasesToDelete != null)
'userAliasesToDelete': userAliasesToDelete,
if (userAliasesToUpdate != null)
'userAliasesToUpdate': userAliasesToUpdate,
};
final response = await _protocol.send(
payload: $payload,
method: 'PUT',
requestUri:
'/applications/${Uri.encodeComponent(applicationId)}/users/${Uri.encodeComponent(userId)}',
exceptionFnMap: _exceptionFns,
);
return UpdateUserResponse.fromJson(response);
}