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 #

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 #

See: testAuthorization smart constructor.

Instances
Eq TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Data TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

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 # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Show TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Generic TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Associated Types

type Rep TestAuthorization :: * -> * #

Hashable TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

ToJSON TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

AWSRequest TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Associated Types

type Rs TestAuthorization :: * #

ToHeaders TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

ToPath TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

ToQuery TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

NFData TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Methods

rnf :: TestAuthorization -> () #

type Rep TestAuthorization # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

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

Defined in Network.AWS.IoT.TestAuthorization

Request Lenses

taClientId :: Lens' TestAuthorization (Maybe Text) #

The MQTT client ID.

taPolicyNamesToAdd :: Lens' TestAuthorization [Text] #

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

taCognitoIdentityPoolId :: Lens' TestAuthorization (Maybe Text) #

The Cognito identity pool ID.

taPolicyNamesToSkip :: Lens' TestAuthorization [Text] #

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) #

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

Destructuring the Response

testAuthorizationResponse #

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 #

See: testAuthorizationResponse smart constructor.

Instances
Eq TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Data TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

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 # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Show TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Generic TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

Associated Types

type Rep TestAuthorizationResponse :: * -> * #

NFData TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

type Rep TestAuthorizationResponse # 
Instance details

Defined in Network.AWS.IoT.TestAuthorization

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

Response Lenses

tarsResponseStatus :: Lens' TestAuthorizationResponse Int #

  • - | The response status code.