getFilter method

Future<GetFilterResponse> getFilter({
  1. required String detectorId,
  2. required String filterName,
})

Returns the details of the filter specified by the filter name.

May throw BadRequestException. May throw InternalServerErrorException.

Parameter detectorId : The unique ID of the detector that is associated with this filter.

To find the detectorId in the current Region, see the Settings page in the GuardDuty console, or run the ListDetectors API.

Parameter filterName : The name of the filter you want to get.

Implementation

Future<GetFilterResponse> getFilter({
  required String detectorId,
  required String filterName,
}) async {
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/detector/${Uri.encodeComponent(detectorId)}/filter/${Uri.encodeComponent(filterName)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetFilterResponse.fromJson(response);
}