getResourcePolicy method

Future<GetResourcePolicyResponse> getResourcePolicy({
  1. required String resourceArn,
})

Retrieves the resource-based policy for a specified resource.

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

Parameter resourceArn : The Amazon Resource Name (ARN) of the resource for which to retrieve the resource policy.

Implementation

Future<GetResourcePolicyResponse> getResourcePolicy({
  required String resourceArn,
}) async {
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/resourcepolicy/${Uri.encodeComponent(resourceArn)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetResourcePolicyResponse.fromJson(response);
}