describeFieldIndexes method

Future<DescribeFieldIndexesResponse> describeFieldIndexes({
  1. required List<String> logGroupIdentifiers,
  2. String? nextToken,
})

Returns a list of custom and default field indexes which are discovered in log data. For more information about field index policies, see PutIndexPolicy.

May throw InvalidParameterException. May throw LimitExceededException. May throw OperationAbortedException. May throw ResourceNotFoundException. May throw ServiceUnavailableException.

Parameter logGroupIdentifiers : An array containing the names or ARNs of the log groups that you want to retrieve field indexes for.

Implementation

Future<DescribeFieldIndexesResponse> describeFieldIndexes({
  required List<String> logGroupIdentifiers,
  String? nextToken,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'Logs_20140328.DescribeFieldIndexes'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'logGroupIdentifiers': logGroupIdentifiers,
      if (nextToken != null) 'nextToken': nextToken,
    },
  );

  return DescribeFieldIndexesResponse.fromJson(jsonResponse.body);
}