setDefaultRoles method

Future<Group> setDefaultRoles(
  1. String sdkId,
  2. String groupId,
  3. String userType,
  4. List<String> roleIds,
)

Implementation

Future<Group> setDefaultRoles(String sdkId, String groupId, String userType, List<String> roleIds) async {
	final res = await _methodChannel.invokeMethod<String>(
		'GroupApi.setDefaultRoles',
		{
			"sdkId": sdkId,
			"groupId": jsonEncode(groupId),
			"userType": jsonEncode(userType),
			"roleIds": jsonEncode(roleIds.map((x0) => x0).toList()),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method setDefaultRoles");
	final parsedResJson = jsonDecode(res);
	return Group.fromJSON(parsedResJson);
}