amazonka-iam-1.2.0: 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.CreatePolicyVersion

Contents

Description

Creates a new version of the specified managed policy. To update a managed policy, you create a new policy version. A managed policy can have up to five versions. If the policy has five versions, you must delete an existing version using DeletePolicyVersion before you create a new version.

Optionally, you can set the new version as the policy's default version. The default version is the operative version; that is, the version that is in effect for the IAM users, groups, and roles that the policy is attached to.

For more information about managed policy versions, see Versioning for Managed Policies in the Using IAM guide.

See: AWS API Reference for CreatePolicyVersion.

Synopsis

Creating a Request

createPolicyVersion Source

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

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

Request Lenses

cpvSetAsDefault :: Lens' CreatePolicyVersion (Maybe Bool) Source

Specifies whether to set this version as the policy's default version.

When this parameter is true, the new policy version becomes the operative version; that is, the version that is in effect for the IAM users, groups, and roles that the policy is attached to.

For more information about managed policy versions, see Versioning for Managed Policies in the Using IAM guide.

Destructuring the Response

createPolicyVersionResponse Source

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

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

Response Lenses