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

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

Network.AWS.IAM.GetUserPolicy

Contents

Description

Retrieves the specified inline policy document that is embedded in the specified IAM user.

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

For more information about policies, see Managed Policies and Inline Policies in the IAM User Guide .

Synopsis

Creating a Request

getUserPolicy #

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

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

  • gupUserName - The name of the user who the policy is associated with. This parameter allows (per its regex pattern ) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-
  • gupPolicyName - The name of the policy document to get. This parameter allows (per its regex pattern ) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-

data GetUserPolicy #

See: getUserPolicy smart constructor.

Instances
Eq GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Data GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GetUserPolicy -> c GetUserPolicy #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GetUserPolicy #

toConstr :: GetUserPolicy -> Constr #

dataTypeOf :: GetUserPolicy -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c GetUserPolicy) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GetUserPolicy) #

gmapT :: (forall b. Data b => b -> b) -> GetUserPolicy -> GetUserPolicy #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GetUserPolicy -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GetUserPolicy -> r #

gmapQ :: (forall d. Data d => d -> u) -> GetUserPolicy -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GetUserPolicy -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GetUserPolicy -> m GetUserPolicy #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GetUserPolicy -> m GetUserPolicy #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GetUserPolicy -> m GetUserPolicy #

Read GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Show GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Generic GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Associated Types

type Rep GetUserPolicy :: * -> * #

Hashable GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

AWSRequest GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Associated Types

type Rs GetUserPolicy :: * #

ToHeaders GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

ToPath GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

ToQuery GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

NFData GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Methods

rnf :: GetUserPolicy -> () #

type Rep GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

type Rep GetUserPolicy = D1 (MetaData "GetUserPolicy" "Network.AWS.IAM.GetUserPolicy" "amazonka-iam-1.6.0-KLHg33OPBsA2oss7MTCyZq" False) (C1 (MetaCons "GetUserPolicy'" PrefixI True) (S1 (MetaSel (Just "_gupUserName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Just "_gupPolicyName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)))
type Rs GetUserPolicy # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Request Lenses

gupUserName :: Lens' GetUserPolicy Text #

The name of the user who the policy is associated with. This parameter allows (per its regex pattern ) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-

gupPolicyName :: Lens' GetUserPolicy Text #

The name of the policy document to get. This parameter allows (per its regex pattern ) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-

Destructuring the Response

getUserPolicyResponse #

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

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

data GetUserPolicyResponse #

Contains the response to a successful GetUserPolicy request.

See: getUserPolicyResponse smart constructor.

Instances
Eq GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Data GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GetUserPolicyResponse -> c GetUserPolicyResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GetUserPolicyResponse #

toConstr :: GetUserPolicyResponse -> Constr #

dataTypeOf :: GetUserPolicyResponse -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c GetUserPolicyResponse) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GetUserPolicyResponse) #

gmapT :: (forall b. Data b => b -> b) -> GetUserPolicyResponse -> GetUserPolicyResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GetUserPolicyResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GetUserPolicyResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> GetUserPolicyResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GetUserPolicyResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GetUserPolicyResponse -> m GetUserPolicyResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GetUserPolicyResponse -> m GetUserPolicyResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GetUserPolicyResponse -> m GetUserPolicyResponse #

Read GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Show GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Generic GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Associated Types

type Rep GetUserPolicyResponse :: * -> * #

NFData GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

Methods

rnf :: GetUserPolicyResponse -> () #

type Rep GetUserPolicyResponse # 
Instance details

Defined in Network.AWS.IAM.GetUserPolicy

type Rep GetUserPolicyResponse = D1 (MetaData "GetUserPolicyResponse" "Network.AWS.IAM.GetUserPolicy" "amazonka-iam-1.6.0-KLHg33OPBsA2oss7MTCyZq" False) (C1 (MetaCons "GetUserPolicyResponse'" PrefixI True) ((S1 (MetaSel (Just "_guprsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int) :*: S1 (MetaSel (Just "_guprsUserName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) :*: (S1 (MetaSel (Just "_guprsPolicyName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Just "_guprsPolicyDocument") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text))))

Response Lenses

guprsResponseStatus :: Lens' GetUserPolicyResponse Int #

  • - | The response status code.

guprsUserName :: Lens' GetUserPolicyResponse Text #

The user the policy is associated with.