getMilestone method

Future<GetMilestoneOutput> getMilestone({
  1. required int milestoneNumber,
  2. required String workloadId,
})

Get a milestone for an existing workload.

May throw AccessDeniedException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Implementation

Future<GetMilestoneOutput> getMilestone({
  required int milestoneNumber,
  required String workloadId,
}) async {
  _s.validateNumRange(
    'milestoneNumber',
    milestoneNumber,
    1,
    100,
    isRequired: true,
  );
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/workloads/${Uri.encodeComponent(workloadId)}/milestones/${Uri.encodeComponent(milestoneNumber.toString())}',
    exceptionFnMap: _exceptionFns,
  );
  return GetMilestoneOutput.fromJson(response);
}