searchProjects method
Returns a paginated list of projects visible to the user.
This operation can be accessed anonymously.
Permissions required: Projects are returned only where the user has one of:
- Browse Projects project permission for the project.
- Administer Projects project permission for the project.
- Administer Jira global permission.
Implementation
Future<PageBeanProject> searchProjects(
{int? startAt,
int? maxResults,
String? orderBy,
List<int>? id,
List<String>? keys,
String? query,
String? typeKey,
int? categoryId,
String? action,
String? expand,
List<String>? status,
List<StringList>? properties,
String? propertyQuery}) async {
return PageBeanProject.fromJson(await _client.send(
'get',
'rest/api/3/project/search',
queryParameters: {
if (startAt != null) 'startAt': '$startAt',
if (maxResults != null) 'maxResults': '$maxResults',
if (orderBy != null) 'orderBy': orderBy,
if (id != null) 'id': id.map((e) => '$e').join(','),
if (keys != null) 'keys': keys.map((e) => e).join(','),
if (query != null) 'query': query,
if (typeKey != null) 'typeKey': typeKey,
if (categoryId != null) 'categoryId': '$categoryId',
if (action != null) 'action': action,
if (expand != null) 'expand': expand,
if (status != null) 'status': status.map((e) => e).join(','),
if (properties != null)
'properties': properties.map((e) => '$e').join(','),
if (propertyQuery != null) 'propertyQuery': propertyQuery,
},
));
}