updateFindingsFeedback method
Marks the specified GuardDuty findings as useful or not useful.
May throw BadRequestException.
May throw InternalServerErrorException.
Parameter detectorId :
The ID of the detector that is associated with the findings for which you
want to update the feedback.
To find the detectorId in the current Region, see the
Settings page in the GuardDuty console, or run the ListDetectors
API.
Parameter feedback :
The feedback for the finding.
Parameter findingIds :
The IDs of the findings that you want to mark as useful or not useful.
Parameter comments :
Additional feedback about the GuardDuty findings.
Implementation
Future<void> updateFindingsFeedback({
required String detectorId,
required Feedback feedback,
required List<String> findingIds,
String? comments,
}) async {
final $payload = <String, dynamic>{
'feedback': feedback.value,
'findingIds': findingIds,
if (comments != null) 'comments': comments,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/detector/${Uri.encodeComponent(detectorId)}/findings/feedback',
exceptionFnMap: _exceptionFns,
);
}