Copyright | (c) 2013-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
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 IAM User Guide.
- createPolicyVersion :: Text -> Text -> CreatePolicyVersion
- data CreatePolicyVersion
- cpvSetAsDefault :: Lens' CreatePolicyVersion (Maybe Bool)
- cpvPolicyARN :: Lens' CreatePolicyVersion Text
- cpvPolicyDocument :: Lens' CreatePolicyVersion Text
- createPolicyVersionResponse :: Int -> CreatePolicyVersionResponse
- data CreatePolicyVersionResponse
- cpvrsPolicyVersion :: Lens' CreatePolicyVersionResponse (Maybe PolicyVersion)
- cpvrsResponseStatus :: Lens' CreatePolicyVersionResponse Int
Creating a Request
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:
data CreatePolicyVersion Source #
See: createPolicyVersion
smart constructor.
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 IAM User Guide.
cpvPolicyARN :: Lens' CreatePolicyVersion Text Source #
Undocumented member.
cpvPolicyDocument :: Lens' CreatePolicyVersion Text Source #
The policy document.
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:
data CreatePolicyVersionResponse Source #
Contains the response to a successful CreatePolicyVersion request.
See: createPolicyVersionResponse
smart constructor.
Response Lenses
cpvrsPolicyVersion :: Lens' CreatePolicyVersionResponse (Maybe PolicyVersion) Source #
Information about the policy version.
cpvrsResponseStatus :: Lens' CreatePolicyVersionResponse Int Source #
The response status code.