listInferenceExecutions method

Future<ListInferenceExecutionsResponse> listInferenceExecutions({
  1. required String inferenceSchedulerName,
  2. DateTime? dataEndTimeBefore,
  3. DateTime? dataStartTimeAfter,
  4. int? maxResults,
  5. String? nextToken,
  6. InferenceExecutionStatus? status,
})

Lists all inference executions that have been performed by the specified inference scheduler.

May throw AccessDeniedException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter inferenceSchedulerName : The name of the inference scheduler for the inference execution listed.

Parameter dataEndTimeBefore : The time reference in the inferenced dataset before which Amazon Lookout for Equipment stopped the inference execution.

Parameter dataStartTimeAfter : The time reference in the inferenced dataset after which Amazon Lookout for Equipment started the inference execution.

Parameter maxResults : Specifies the maximum number of inference executions to list.

Parameter nextToken : An opaque pagination token indicating where to continue the listing of inference executions.

Parameter status : The status of the inference execution.

Implementation

Future<ListInferenceExecutionsResponse> listInferenceExecutions({
  required String inferenceSchedulerName,
  DateTime? dataEndTimeBefore,
  DateTime? dataStartTimeAfter,
  int? maxResults,
  String? nextToken,
  InferenceExecutionStatus? status,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    500,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target':
        'AWSLookoutEquipmentFrontendService.ListInferenceExecutions'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'InferenceSchedulerName': inferenceSchedulerName,
      if (dataEndTimeBefore != null)
        'DataEndTimeBefore': unixTimestampToJson(dataEndTimeBefore),
      if (dataStartTimeAfter != null)
        'DataStartTimeAfter': unixTimestampToJson(dataStartTimeAfter),
      if (maxResults != null) 'MaxResults': maxResults,
      if (nextToken != null) 'NextToken': nextToken,
      if (status != null) 'Status': status.value,
    },
  );

  return ListInferenceExecutionsResponse.fromJson(jsonResponse.body);
}