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

Amazonka.Organizations.EnablePolicyType

Description

Enables a policy type in a root. After you enable a policy type in a root, you can attach policies of that type to the root, any organizational unit (OU), or account in that root. You can undo this by using the DisablePolicyType operation.

This is an asynchronous request that AWS performs in the background. AWS recommends that you first use ListRoots to see the status of policy types for a specified root, and then use this operation.

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

You can enable a policy type in a root only if that policy type is available in the organization. To view the status of available policy types in the organization, use DescribeOrganization.

Synopsis

Creating a Request

data EnablePolicyType Source #

See: newEnablePolicyType smart constructor.

Constructors

EnablePolicyType' 

Fields

Instances

Instances details
Eq EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Read EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Show EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Generic EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Associated Types

type Rep EnablePolicyType :: Type -> Type #

NFData EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Methods

rnf :: EnablePolicyType -> () #

Hashable EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

ToJSON EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

AWSRequest EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Associated Types

type AWSResponse EnablePolicyType #

ToHeaders EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

ToPath EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

ToQuery EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

type Rep EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

type Rep EnablePolicyType = D1 ('MetaData "EnablePolicyType" "Amazonka.Organizations.EnablePolicyType" "libZSservicesZSamazonka-organizationsZSamazonka-organizations" 'False) (C1 ('MetaCons "EnablePolicyType'" 'PrefixI 'True) (S1 ('MetaSel ('Just "rootId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "policyType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 PolicyType)))
type AWSResponse EnablePolicyType Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

newEnablePolicyType Source #

Create a value of EnablePolicyType with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:rootId:EnablePolicyType', enablePolicyType_rootId - The unique identifier (ID) of the root in which you want to enable a policy type. You can get the ID from the ListRoots operation.

The regex pattern for a root ID string requires "r-" followed by from 4 to 32 lowercase letters or digits.

$sel:policyType:EnablePolicyType', enablePolicyType_policyType - The policy type that you want to enable. You can specify one of the following values:

Request Lenses

enablePolicyType_rootId :: Lens' EnablePolicyType Text Source #

The unique identifier (ID) of the root in which you want to enable a policy type. You can get the ID from the ListRoots operation.

The regex pattern for a root ID string requires "r-" followed by from 4 to 32 lowercase letters or digits.

enablePolicyType_policyType :: Lens' EnablePolicyType PolicyType Source #

The policy type that you want to enable. You can specify one of the following values:

Destructuring the Response

data EnablePolicyTypeResponse Source #

See: newEnablePolicyTypeResponse smart constructor.

Constructors

EnablePolicyTypeResponse' 

Fields

  • root :: Maybe Root

    A structure that shows the root with the updated list of enabled policy types.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Eq EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Read EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Show EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Generic EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

Associated Types

type Rep EnablePolicyTypeResponse :: Type -> Type #

NFData EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

type Rep EnablePolicyTypeResponse Source # 
Instance details

Defined in Amazonka.Organizations.EnablePolicyType

type Rep EnablePolicyTypeResponse = D1 ('MetaData "EnablePolicyTypeResponse" "Amazonka.Organizations.EnablePolicyType" "libZSservicesZSamazonka-organizationsZSamazonka-organizations" 'False) (C1 ('MetaCons "EnablePolicyTypeResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "root") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Root)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newEnablePolicyTypeResponse Source #

Create a value of EnablePolicyTypeResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:root:EnablePolicyTypeResponse', enablePolicyTypeResponse_root - A structure that shows the root with the updated list of enabled policy types.

$sel:httpStatus:EnablePolicyTypeResponse', enablePolicyTypeResponse_httpStatus - The response's http status code.

Response Lenses

enablePolicyTypeResponse_root :: Lens' EnablePolicyTypeResponse (Maybe Root) Source #

A structure that shows the root with the updated list of enabled policy types.