getUsers method
Getting users
In addition to getting the current authenticated player’s user account, Nakama has a convenient way to get a list of other players’ public profiles from their ids or usernames.
Implementation
@override
Future<List<model.User>> getUsers({
required model.Session session,
List<String>? facebookIds,
List<String>? ids,
List<String>? usernames,
}) async {
_session = session;
final res = await _api.v2UserGet(
facebookIds: facebookIds,
ids: ids,
usernames: usernames,
);
return res.body!.users!.map((e) => model.User.fromJson(e.toJson())).toList(growable: false);
}