getUsagePlan method

Future<UsagePlan> getUsagePlan({
  1. required String usagePlanId,
})

Gets a usage plan of a given plan identifier.

May throw BadRequestException. May throw UnauthorizedException. May throw NotFoundException. May throw TooManyRequestsException.

Parameter usagePlanId : Required The identifier of the UsagePlan resource to be retrieved.

Implementation

Future<UsagePlan> getUsagePlan({
  required String usagePlanId,
}) async {
  ArgumentError.checkNotNull(usagePlanId, 'usagePlanId');
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/usageplans/${Uri.encodeComponent(usagePlanId)}',
    exceptionFnMap: _exceptionFns,
  );
  return UsagePlan.fromJson(response);
}