listElasticsearchVersions method

Future<ListElasticsearchVersionsResponse> listElasticsearchVersions({
  1. int? maxResults,
  2. String? nextToken,
})

List all supported Elasticsearch versions

May throw BaseException. May throw InternalException. May throw ResourceNotFoundException. May throw ValidationException.

Parameter maxResults : Set this value to limit the number of results returned. Value provided must be greater than 10 else it wont be honored.

Implementation

Future<ListElasticsearchVersionsResponse> listElasticsearchVersions({
  int? maxResults,
  String? nextToken,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    0,
    100,
  );
  final $query = <String, List<String>>{
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/2015-01-01/es/versions',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListElasticsearchVersionsResponse.fromJson(response);
}