cancelImportTask method
Cancels an active import task and stops importing data from the CloudTrail Lake Event Data Store.
May throw AccessDeniedException.
May throw InvalidOperationException.
May throw InvalidParameterException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
Parameter importId :
The ID of the import task to cancel.
Implementation
Future<CancelImportTaskResponse> cancelImportTask({
required String importId,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'Logs_20140328.CancelImportTask'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'importId': importId,
},
);
return CancelImportTaskResponse.fromJson(jsonResponse.body);
}