listDevicesJobs method
Returns a list of jobs.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ValidationException.
Parameter deviceId :
Filter results by the job's target device ID.
Parameter maxResults :
The maximum number of device jobs to return in one page of results.
Parameter nextToken :
Specify the pagination token from a previous request to retrieve the next
page of results.
Implementation
Future<ListDevicesJobsResponse> listDevicesJobs({
String? deviceId,
int? maxResults,
String? nextToken,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
0,
25,
);
final $query = <String, List<String>>{
if (deviceId != null) 'DeviceId': [deviceId],
if (maxResults != null) 'MaxResults': [maxResults.toString()],
if (nextToken != null) 'NextToken': [nextToken],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri: '/jobs',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return ListDevicesJobsResponse.fromJson(response);
}