createJob method
This operation creates a job.
May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException. May throw InternalServerException. May throw AccessDeniedException.
Parameter details
:
The details for the CreateJob request.
Parameter type
:
The type of job to be created.
Implementation
Future<CreateJobResponse> createJob({
required RequestDetails details,
required Type type,
}) async {
ArgumentError.checkNotNull(details, 'details');
ArgumentError.checkNotNull(type, 'type');
final $payload = <String, dynamic>{
'Details': details,
'Type': type.toValue(),
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/v1/jobs',
exceptionFnMap: _exceptionFns,
);
return CreateJobResponse.fromJson(response);
}