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

Safe HaskellNone




Creates a new managed policy for your AWS account.

This operation creates a policy version with a version identifier of v1 and sets v1 as the policy's default version. For more information about policy versions, see Versioning for Managed Policies in the Using IAM guide.

For more information about managed policies in general, refer to ManagedPolicies and Inline Policies in the Using IAM guide.



Request constructor

createPolicy Source

CreatePolicy constructor.

The fields accessible through corresponding lenses are:

Request lenses

cpDescription :: Lens' CreatePolicy (Maybe Text) Source

A friendly description of the policy.

Typically used to store information about the permissions defined in the policy. For example, "Grants access to production DynamoDB tables."

The policy description is immutable. After a value is assigned, it cannot be changed.

cpPath :: Lens' CreatePolicy (Maybe Text) Source

The path for the policy.

For more information about paths, see IAM Identifiers in the Using IAM guide.

This parameter is optional. If it is not included, it defaults to a slash (/).

cpPolicyName :: Lens' CreatePolicy Text Source

The name of the policy document.


Response constructor

createPolicyResponse :: CreatePolicyResponse Source

CreatePolicyResponse constructor.

The fields accessible through corresponding lenses are:

Response lenses

cprPolicy :: Lens' CreatePolicyResponse (Maybe Policy) Source

Information about the policy.