amazonka-organizations-1.6.1: Amazon Organizations 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.Organizations.ListPoliciesForTarget

Contents

Description

Lists the policies that are directly attached to the specified target root, organizational unit (OU), or account. You must specify the policy type that you want included in the returned list.

This operation can be called only from the organization's master account.

This operation returns paginated results.

Synopsis

Creating a Request

listPoliciesForTarget Source #

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

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

  • lpftNextToken - Use this parameter if you receive a NextToken response in a previous request that indicates that there is more output available. Set it to the value of the previous call's NextToken response to indicate where the output should continue from.
  • lpftMaxResults - (Optional) Use this to limit the number of results you want included in the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the NextToken response element is present and has a value (is not null). Include that value as the NextToken request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check NextToken after every operation to ensure that you receive all of the results.
  • lpftTargetId - The unique identifier (ID) of the root, organizational unit, or account whose policies you want to list. The regex pattern for a target ID string requires one of the following: * Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits. * Account: a string that consists of exactly 12 digits. * Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.
  • lpftFilter - The type of policy that you want to include in the returned list.

data ListPoliciesForTarget Source #

See: listPoliciesForTarget smart constructor.

Instances
Eq ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Data ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Methods

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

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

toConstr :: ListPoliciesForTarget -> Constr #

dataTypeOf :: ListPoliciesForTarget -> DataType #

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

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

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

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

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

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

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

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

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

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

Read ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Show ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Generic ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Associated Types

type Rep ListPoliciesForTarget :: Type -> Type #

Hashable ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

ToJSON ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

AWSPager ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

AWSRequest ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Associated Types

type Rs ListPoliciesForTarget :: Type #

ToHeaders ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

ToPath ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

ToQuery ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

NFData ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Methods

rnf :: ListPoliciesForTarget -> () #

type Rep ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

type Rep ListPoliciesForTarget = D1 (MetaData "ListPoliciesForTarget" "Network.AWS.Organizations.ListPoliciesForTarget" "amazonka-organizations-1.6.1-AXMOvAV6jebLVZPNUpIjqF" False) (C1 (MetaCons "ListPoliciesForTarget'" PrefixI True) ((S1 (MetaSel (Just "_lpftNextToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)) :*: S1 (MetaSel (Just "_lpftMaxResults") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat))) :*: (S1 (MetaSel (Just "_lpftTargetId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Just "_lpftFilter") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PolicyType))))
type Rs ListPoliciesForTarget Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Request Lenses

lpftNextToken :: Lens' ListPoliciesForTarget (Maybe Text) Source #

Use this parameter if you receive a NextToken response in a previous request that indicates that there is more output available. Set it to the value of the previous call's NextToken response to indicate where the output should continue from.

lpftMaxResults :: Lens' ListPoliciesForTarget (Maybe Natural) Source #

(Optional) Use this to limit the number of results you want included in the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the NextToken response element is present and has a value (is not null). Include that value as the NextToken request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check NextToken after every operation to ensure that you receive all of the results.

lpftTargetId :: Lens' ListPoliciesForTarget Text Source #

The unique identifier (ID) of the root, organizational unit, or account whose policies you want to list. The regex pattern for a target ID string requires one of the following: * Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits. * Account: a string that consists of exactly 12 digits. * Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.

lpftFilter :: Lens' ListPoliciesForTarget PolicyType Source #

The type of policy that you want to include in the returned list.

Destructuring the Response

listPoliciesForTargetResponse Source #

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

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

  • lpftrsNextToken - If present, this value indicates that there is more output available than is included in the current response. Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the NextToken response element comes back as null .
  • lpftrsPolicies - The list of policies that match the criteria in the request.
  • lpftrsResponseStatus - -- | The response status code.

data ListPoliciesForTargetResponse Source #

See: listPoliciesForTargetResponse smart constructor.

Instances
Eq ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Data ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Methods

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

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

toConstr :: ListPoliciesForTargetResponse -> Constr #

dataTypeOf :: ListPoliciesForTargetResponse -> DataType #

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

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

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

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

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

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

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

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

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

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

Read ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Show ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Generic ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

Associated Types

type Rep ListPoliciesForTargetResponse :: Type -> Type #

NFData ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

type Rep ListPoliciesForTargetResponse Source # 
Instance details

Defined in Network.AWS.Organizations.ListPoliciesForTarget

type Rep ListPoliciesForTargetResponse = D1 (MetaData "ListPoliciesForTargetResponse" "Network.AWS.Organizations.ListPoliciesForTarget" "amazonka-organizations-1.6.1-AXMOvAV6jebLVZPNUpIjqF" False) (C1 (MetaCons "ListPoliciesForTargetResponse'" PrefixI True) (S1 (MetaSel (Just "_lpftrsNextToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 (MetaSel (Just "_lpftrsPolicies") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [PolicySummary])) :*: S1 (MetaSel (Just "_lpftrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))))

Response Lenses

lpftrsNextToken :: Lens' ListPoliciesForTargetResponse (Maybe Text) Source #

If present, this value indicates that there is more output available than is included in the current response. Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the NextToken response element comes back as null .

lpftrsPolicies :: Lens' ListPoliciesForTargetResponse [PolicySummary] Source #

The list of policies that match the criteria in the request.