amazonka-cloudwatch-events-1.5.0: Amazon CloudWatch Events SDK.

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

Network.AWS.CloudWatchEvents.PutPermission

Contents

Description

Running PutPermission permits the specified AWS account to put events to your account's default event bus . CloudWatch Events rules in your account are triggered by these events arriving to your default event bus.

For another account to send events to your account, that external account must have a CloudWatch Events rule with your account's default event bus as a target.

To enable multiple AWS accounts to put events to your default event bus, run PutPermission once for each of these accounts.

The permission policy on the default event bus cannot exceed 10KB in size.

Synopsis

Creating a Request

putPermission Source #

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

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

  • ppAction - The action that you are enabling the other account to perform. Currently, this must be events:PutEvents .
  • ppPrincipal - The 12-digit AWS account ID that you are permitting to put events to your default event bus. Specify "*" to permit any account to put events to your default event bus. If you specify "*", avoid creating rules that may match undesirable events. To create more secure rules, make sure that the event pattern for each rule contains an account field with a specific account ID from which to receive events. Rules with an account field do not match any events sent from other accounts.
  • ppStatementId - An identifier string for the external account that you are granting permissions to. If you later want to revoke the permission for this external account, specify this StatementId when you run RemovePermission .

data PutPermission Source #

See: putPermission smart constructor.

Instances

Eq PutPermission Source # 
Data PutPermission Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutPermission -> c PutPermission #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutPermission #

toConstr :: PutPermission -> Constr #

dataTypeOf :: PutPermission -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutPermission) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutPermission) #

gmapT :: (forall b. Data b => b -> b) -> PutPermission -> PutPermission #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutPermission -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutPermission -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutPermission -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutPermission -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutPermission -> m PutPermission #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermission -> m PutPermission #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermission -> m PutPermission #

Read PutPermission Source # 
Show PutPermission Source # 
Generic PutPermission Source # 

Associated Types

type Rep PutPermission :: * -> * #

Hashable PutPermission Source # 
ToJSON PutPermission Source # 
NFData PutPermission Source # 

Methods

rnf :: PutPermission -> () #

AWSRequest PutPermission Source # 
ToQuery PutPermission Source # 
ToPath PutPermission Source # 
ToHeaders PutPermission Source # 
type Rep PutPermission Source # 
type Rep PutPermission = D1 (MetaData "PutPermission" "Network.AWS.CloudWatchEvents.PutPermission" "amazonka-cloudwatch-events-1.5.0-45UlPAa7R14ChwLoYVg3Ab" False) (C1 (MetaCons "PutPermission'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_ppAction") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) ((:*:) (S1 (MetaSel (Just Symbol "_ppPrincipal") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_ppStatementId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)))))
type Rs PutPermission Source # 

Request Lenses

ppAction :: Lens' PutPermission Text Source #

The action that you are enabling the other account to perform. Currently, this must be events:PutEvents .

ppPrincipal :: Lens' PutPermission Text Source #

The 12-digit AWS account ID that you are permitting to put events to your default event bus. Specify "*" to permit any account to put events to your default event bus. If you specify "*", avoid creating rules that may match undesirable events. To create more secure rules, make sure that the event pattern for each rule contains an account field with a specific account ID from which to receive events. Rules with an account field do not match any events sent from other accounts.

ppStatementId :: Lens' PutPermission Text Source #

An identifier string for the external account that you are granting permissions to. If you later want to revoke the permission for this external account, specify this StatementId when you run RemovePermission .

Destructuring the Response

putPermissionResponse :: PutPermissionResponse Source #

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

data PutPermissionResponse Source #

See: putPermissionResponse smart constructor.

Instances

Eq PutPermissionResponse Source # 
Data PutPermissionResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutPermissionResponse -> c PutPermissionResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutPermissionResponse #

toConstr :: PutPermissionResponse -> Constr #

dataTypeOf :: PutPermissionResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutPermissionResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutPermissionResponse) #

gmapT :: (forall b. Data b => b -> b) -> PutPermissionResponse -> PutPermissionResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutPermissionResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutPermissionResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutPermissionResponse -> m PutPermissionResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionResponse -> m PutPermissionResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionResponse -> m PutPermissionResponse #

Read PutPermissionResponse Source # 
Show PutPermissionResponse Source # 
Generic PutPermissionResponse Source # 
NFData PutPermissionResponse Source # 

Methods

rnf :: PutPermissionResponse -> () #

type Rep PutPermissionResponse Source # 
type Rep PutPermissionResponse = D1 (MetaData "PutPermissionResponse" "Network.AWS.CloudWatchEvents.PutPermission" "amazonka-cloudwatch-events-1.5.0-45UlPAa7R14ChwLoYVg3Ab" False) (C1 (MetaCons "PutPermissionResponse'" PrefixI False) U1)