returnSavingsPlan method

Future<ReturnSavingsPlanResponse> returnSavingsPlan({
  1. required String savingsPlanId,
  2. String? clientToken,
})

Returns the specified Savings Plan.

May throw InternalServerException. May throw ResourceNotFoundException. May throw ServiceQuotaExceededException. May throw ValidationException.

Parameter savingsPlanId : The ID of the Savings Plan.

Parameter clientToken : A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Implementation

Future<ReturnSavingsPlanResponse> returnSavingsPlan({
  required String savingsPlanId,
  String? clientToken,
}) async {
  final $payload = <String, dynamic>{
    'savingsPlanId': savingsPlanId,
    'clientToken': clientToken ?? _s.generateIdempotencyToken(),
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/ReturnSavingsPlan',
    exceptionFnMap: _exceptionFns,
  );
  return ReturnSavingsPlanResponse.fromJson(response);
}