amazonka-iot-1.6.0: Amazon IoT SDK.

Copyright(c) 2013-2018 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.IoT.TestAuthorization

Contents

Description

Test custom authorization.

Synopsis

Creating a Request

testAuthorization Source #

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

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

  • taClientId - The MQTT client ID.
  • taPolicyNamesToAdd - When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
  • taPrincipal - The principal.
  • taCognitoIdentityPoolId - The Cognito identity pool ID.
  • taPolicyNamesToSkip - When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
  • taAuthInfos - A list of authorization info objects. Simulating authorization will create a response for each authInfo object in the list.

data TestAuthorization Source #

See: testAuthorization smart constructor.

Instances

Eq TestAuthorization Source # 
Data TestAuthorization Source # 

Methods

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

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

toConstr :: TestAuthorization -> Constr #

dataTypeOf :: TestAuthorization -> DataType #

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

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

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

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

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

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

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

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

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

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

Read TestAuthorization Source # 
Show TestAuthorization Source # 
Generic TestAuthorization Source # 
Hashable TestAuthorization Source # 
ToJSON TestAuthorization Source # 
NFData TestAuthorization Source # 

Methods

rnf :: TestAuthorization -> () #

AWSRequest TestAuthorization Source # 
ToHeaders TestAuthorization Source # 
ToPath TestAuthorization Source # 
ToQuery TestAuthorization Source # 
type Rep TestAuthorization Source # 
type Rep TestAuthorization = D1 * (MetaData "TestAuthorization" "Network.AWS.IoT.TestAuthorization" "amazonka-iot-1.6.0-GZYdsKS1TEjHFZo6BqaYJk" False) (C1 * (MetaCons "TestAuthorization'" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_taClientId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_taPolicyNamesToAdd") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe [Text]))) (S1 * (MetaSel (Just Symbol "_taPrincipal") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))))) ((:*:) * (S1 * (MetaSel (Just Symbol "_taCognitoIdentityPoolId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_taPolicyNamesToSkip") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe [Text]))) (S1 * (MetaSel (Just Symbol "_taAuthInfos") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (List1 AuthInfo)))))))
type Rs TestAuthorization Source # 

Request Lenses

taPolicyNamesToAdd :: Lens' TestAuthorization [Text] Source #

When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.

taPolicyNamesToSkip :: Lens' TestAuthorization [Text] Source #

When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.

taAuthInfos :: Lens' TestAuthorization (NonEmpty AuthInfo) Source #

A list of authorization info objects. Simulating authorization will create a response for each authInfo object in the list.

Destructuring the Response

testAuthorizationResponse Source #

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

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

data TestAuthorizationResponse Source #

See: testAuthorizationResponse smart constructor.

Instances

Eq TestAuthorizationResponse Source # 
Data TestAuthorizationResponse Source # 

Methods

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

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

toConstr :: TestAuthorizationResponse -> Constr #

dataTypeOf :: TestAuthorizationResponse -> DataType #

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

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

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

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

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

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

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

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

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

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

Read TestAuthorizationResponse Source # 
Show TestAuthorizationResponse Source # 
Generic TestAuthorizationResponse Source # 
NFData TestAuthorizationResponse Source # 
type Rep TestAuthorizationResponse Source # 
type Rep TestAuthorizationResponse = D1 * (MetaData "TestAuthorizationResponse" "Network.AWS.IoT.TestAuthorization" "amazonka-iot-1.6.0-GZYdsKS1TEjHFZo6BqaYJk" False) (C1 * (MetaCons "TestAuthorizationResponse'" PrefixI True) ((:*:) * (S1 * (MetaSel (Just Symbol "_tarsAuthResults") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe [AuthResult]))) (S1 * (MetaSel (Just Symbol "_tarsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Int))))

Response Lenses