UserListRequest constructor

UserListRequest({
  1. String? token,
  2. int limit = 30,
  3. String? metaDataKey,
  4. List<String>? metaDataValues,
  5. String? nicknameStartsWith,
  6. List<String>? userIds,
})

Implementation

UserListRequest({
  String? token,
  int limit = 30,
  String? metaDataKey,
  List<String>? metaDataValues,
  String? nicknameStartsWith,
  List<String>? userIds,
}) : super() {
  url = 'users';
  queryParams = {
    'limit': limit,
    if (token != null) 'token': token,
    if (userIds != null && userIds.isNotEmpty) 'user_ids': userIds,
    if (metaDataKey != null) 'metadatakey': metaDataKey,
    if (metaDataValues != null && metaDataValues.isNotEmpty)
      'metadatavalues_in': metaDataValues,
    if (nicknameStartsWith != null) 'nickname_startswith': nicknameStartsWith,
  };
}