deleteDetector method
Deletes the detector. Before deleting a detector, you must first delete all detector versions and rule versions associated with the detector.
When you delete a detector, Amazon Fraud Detector permanently deletes the detector and the data is no longer stored in Amazon Fraud Detector.
May throw ConflictException. May throw ValidationException. May throw InternalServerException. May throw ThrottlingException. May throw AccessDeniedException.
Parameter detectorId
:
The ID of the detector to delete.
Implementation
Future<void> deleteDetector({
required String detectorId,
}) async {
ArgumentError.checkNotNull(detectorId, 'detectorId');
_s.validateStringLength(
'detectorId',
detectorId,
1,
64,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'AWSHawksNestServiceFacade.DeleteDetector'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'detectorId': detectorId,
},
);
}