getCompatibleVersions method

Future<GetCompatibleVersionsResponse> getCompatibleVersions({
  1. String? domainName,
})

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

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

Implementation

Future<GetCompatibleVersionsResponse> getCompatibleVersions({
  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: '/2021-01-01/opensearch/compatibleVersions',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return GetCompatibleVersionsResponse.fromJson(response);
}