getCapacityProvider method

Future<GetCapacityProviderResponse> getCapacityProvider({
  1. required String capacityProviderName,
})

Retrieves information about a specific capacity provider, including its configuration, state, and associated resources.

May throw InvalidParameterValueException. May throw ResourceNotFoundException. May throw ServiceException. May throw TooManyRequestsException.

Parameter capacityProviderName : The name of the capacity provider to retrieve.

Implementation

Future<GetCapacityProviderResponse> getCapacityProvider({
  required String capacityProviderName,
}) async {
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/2025-11-30/capacity-providers/${Uri.encodeComponent(capacityProviderName)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetCapacityProviderResponse.fromJson(response);
}