getCustomerRequests method
This method returns all customer requests for the user executing the query.
The returned customer requests are ordered chronologically by the latest activity on each request. For example, the latest status transition or comment.
Permissions required: Permission to access the specified service desk.
Response limitations: For customers, the list returned will include request they created (or were created on their behalf) or are participating in only.
Implementation
Future<PagedDTOCustomerRequestDTO> getCustomerRequests(
{String? searchTerm,
List<String>? requestOwnership,
String? requestStatus,
String? approvalStatus,
int? organizationId,
int? serviceDeskId,
int? requestTypeId,
List<String>? expand,
int? start,
int? limit}) async {
return PagedDTOCustomerRequestDTO.fromJson(await _client.send(
'get',
'rest/servicedeskapi/request',
queryParameters: {
if (searchTerm != null) 'searchTerm': searchTerm,
if (requestOwnership != null)
'requestOwnership': requestOwnership.map((e) => e).join(','),
if (requestStatus != null) 'requestStatus': requestStatus,
if (approvalStatus != null) 'approvalStatus': approvalStatus,
if (organizationId != null) 'organizationId': '$organizationId',
if (serviceDeskId != null) 'serviceDeskId': '$serviceDeskId',
if (requestTypeId != null) 'requestTypeId': '$requestTypeId',
if (expand != null) 'expand': expand.map((e) => e).join(','),
if (start != null) 'start': '$start',
if (limit != null) 'limit': '$limit',
},
));
}