stopImport method

Future<StopImportResponse> stopImport({
  1. required String importId,
})

Stops a specified import.

May throw ImportNotFoundException. May throw InvalidParameterException. May throw OperationNotPermittedException. May throw UnsupportedOperationException.

Parameter importId : The ID of the import.

Implementation

Future<StopImportResponse> stopImport({
  required String importId,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'CloudTrail_20131101.StopImport'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ImportId': importId,
    },
  );

  return StopImportResponse.fromJson(jsonResponse.body);
}