setUserRoles method
Implementation
Future<User> setUserRoles(String sdkId, String userId, ListOfIds rolesId) async {
final res = await _methodChannel.invokeMethod<String>(
'UserApi.setUserRoles',
{
"sdkId": sdkId,
"userId": jsonEncode(userId),
"rolesId": jsonEncode(ListOfIds.encode(rolesId)),
}
);
if (res == null) throw AssertionError("received null result from platform method setUserRoles");
final parsedResJson = jsonDecode(res);
return User.fromJSON(parsedResJson);
}