listPolicyVersions method
Lists the versions of the specified policy and identifies the default version.
Requires permission to access the ListPolicyVersions action.
May throw InternalFailureException.
May throw InvalidRequestException.
May throw ResourceNotFoundException.
May throw ServiceUnavailableException.
May throw ThrottlingException.
May throw UnauthorizedException.
Parameter policyName :
The policy name.
Implementation
Future<ListPolicyVersionsResponse> listPolicyVersions({
required String policyName,
}) async {
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri: '/policies/${Uri.encodeComponent(policyName)}/version',
exceptionFnMap: _exceptionFns,
);
return ListPolicyVersionsResponse.fromJson(response);
}