Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Amazonka.IoT.AttachPolicy
Description
Attaches the specified policy to the specified principal (certificate or other credential).
Requires permission to access the AttachPolicy action.
Synopsis
- data AttachPolicy = AttachPolicy' {
- policyName :: Text
- target :: Text
- newAttachPolicy :: Text -> Text -> AttachPolicy
- attachPolicy_policyName :: Lens' AttachPolicy Text
- attachPolicy_target :: Lens' AttachPolicy Text
- data AttachPolicyResponse = AttachPolicyResponse' {
- newAttachPolicyResponse :: AttachPolicyResponse
Creating a Request
data AttachPolicy Source #
See: newAttachPolicy
smart constructor.
Constructors
AttachPolicy' | |
Fields
|
Instances
Create a value of AttachPolicy
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:policyName:AttachPolicy'
, attachPolicy_policyName
- The name of the policy to attach.
$sel:target:AttachPolicy'
, attachPolicy_target
- The
identity
to which the policy is attached. For example, a thing group or a
certificate.
Request Lenses
attachPolicy_policyName :: Lens' AttachPolicy Text Source #
The name of the policy to attach.
attachPolicy_target :: Lens' AttachPolicy Text Source #
The identity to which the policy is attached. For example, a thing group or a certificate.
Destructuring the Response
data AttachPolicyResponse Source #
See: newAttachPolicyResponse
smart constructor.
Constructors
AttachPolicyResponse' | |
Instances
newAttachPolicyResponse :: AttachPolicyResponse Source #
Create a value of AttachPolicyResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.