getCompatibleElasticsearchVersions method

Future<GetCompatibleElasticsearchVersionsResponse> getCompatibleElasticsearchVersions({
  1. String? domainName,
})

Returns a list of upgrade compatible Elastisearch versions. You can optionally pass a DomainName to get all upgrade compatible Elasticsearch versions for that specific domain.

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

Implementation

Future<GetCompatibleElasticsearchVersionsResponse>
    getCompatibleElasticsearchVersions({
  String? domainName,
}) async {
  _s.validateStringLength(
    'domainName',
    domainName,
    3,
    28,
  );
  final $query = <String, List<String>>{
    if (domainName != null) 'domainName': [domainName],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/2015-01-01/es/compatibleVersions',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return GetCompatibleElasticsearchVersionsResponse.fromJson(response);
}