searchUser method
Searches for users using user-specific queries from the Confluence Query Language (CQL).
Note that CQL input queries submitted through the
/wiki/rest/api/search/user
endpoint only support user-specific fields
like user
, user.fullname
, user.accountid
, and user.userkey
.
Note that some user fields may be set to null depending on the user's privacy settings. These are: email, profilePicture, displayName, and timeZone.
Implementation
Future<SearchPageResponseSearchResult> searchUser(
{required String cql,
int? start,
int? limit,
List<String>? expand,
String? sitePermissionTypeFilter}) async {
return SearchPageResponseSearchResult.fromJson(await _client.send(
'get',
'wiki/rest/api/search/user',
queryParameters: {
'cql': cql,
if (start != null) 'start': '$start',
if (limit != null) 'limit': '$limit',
if (expand != null) 'expand': expand.map((e) => e).join(','),
if (sitePermissionTypeFilter != null)
'sitePermissionTypeFilter': sitePermissionTypeFilter,
},
));
}