amazonka-iam-1.0.1: Amazon Identity and Access Management SDK.

Copyright(c) 2013-2015 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.IAM.GetRolePolicy

Contents

Description

Retrieves the specified inline policy document that is embedded with the specified role.

A role can also have managed policies attached to it. To retrieve a managed policy document that is attached to a role, use GetPolicy to determine the policy's default version, then use GetPolicyVersion to retrieve the policy document.

For more information about policies, refer to Managed Policies and Inline Policies in the Using IAM guide.

For more information about roles, go to Using Roles to Delegate Permissions and Federate Identities.

See: AWS API Reference for GetRolePolicy.

Synopsis

Creating a Request

getRolePolicy Source

Creates a value of GetRolePolicy with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

Request Lenses

grpRoleName :: Lens' GetRolePolicy Text Source

The name of the role associated with the policy.

grpPolicyName :: Lens' GetRolePolicy Text Source

The name of the policy document to get.

Destructuring the Response

getRolePolicyResponse Source

Creates a value of GetRolePolicyResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

Response Lenses

grprsStatus :: Lens' GetRolePolicyResponse Int Source

The response status code.

grprsRoleName :: Lens' GetRolePolicyResponse Text Source

The role the policy is associated with.