amazonka-apigateway-1.4.3: Amazon API Gateway SDK.

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

Network.AWS.APIGateway.TestInvokeAuthorizer

Contents

Description

Simulate the execution of an Authorizer in your RestApi with headers, parameters, and an incoming request body.

Synopsis

Creating a Request

testInvokeAuthorizer Source #

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

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

data TestInvokeAuthorizer Source #

Make a request to simulate the execution of an Authorizer.

See: testInvokeAuthorizer smart constructor.

Instances

Eq TestInvokeAuthorizer Source # 
Data TestInvokeAuthorizer Source # 

Methods

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

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

toConstr :: TestInvokeAuthorizer -> Constr #

dataTypeOf :: TestInvokeAuthorizer -> DataType #

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

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

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

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

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

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

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

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

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

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

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

Methods

rnf :: TestInvokeAuthorizer -> () #

AWSRequest TestInvokeAuthorizer Source # 
ToQuery TestInvokeAuthorizer Source # 
ToPath TestInvokeAuthorizer Source # 
ToHeaders TestInvokeAuthorizer Source # 
type Rep TestInvokeAuthorizer Source # 
type Rep TestInvokeAuthorizer = D1 (MetaData "TestInvokeAuthorizer" "Network.AWS.APIGateway.TestInvokeAuthorizer" "amazonka-apigateway-1.4.3-GVOaWI3QK1e6b27bXNOifn" False) (C1 (MetaCons "TestInvokeAuthorizer'" PrefixI True) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_tiaPathWithQueryString") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) ((:*:) (S1 (MetaSel (Just Symbol "_tiaBody") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_tiaAdditionalContext") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text Text)))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_tiaStageVariables") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text Text)))) (S1 (MetaSel (Just Symbol "_tiaHeaders") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text Text))))) ((:*:) (S1 (MetaSel (Just Symbol "_tiaRestAPIId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_tiaAuthorizerId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text))))))
type Rs TestInvokeAuthorizer Source # 

Request Lenses

tiaPathWithQueryString :: Lens' TestInvokeAuthorizer (Maybe Text) Source #

Optional
The URI path, including query string, of the simulated invocation request. Use this to specify path parameters and query string parameters.

tiaBody :: Lens' TestInvokeAuthorizer (Maybe Text) Source #

Optional
The simulated request body of an incoming invocation request.

tiaAdditionalContext :: Lens' TestInvokeAuthorizer (HashMap Text Text) Source #

Optional
A key-value map of additional context variables.

tiaStageVariables :: Lens' TestInvokeAuthorizer (HashMap Text Text) Source #

A key-value map of stage variables to simulate an invocation on a deployed Stage.

tiaHeaders :: Lens' TestInvokeAuthorizer (HashMap Text Text) Source #

Required
A key-value map of headers to simulate an incoming invocation request. This is where the incoming authorization token, or identity source, should be specified.

tiaRestAPIId :: Lens' TestInvokeAuthorizer Text Source #

Specifies a test invoke authorizer request's RestApi identifier.

tiaAuthorizerId :: Lens' TestInvokeAuthorizer Text Source #

Specifies a test invoke authorizer request's Authorizer ID.

Destructuring the Response

testInvokeAuthorizerResponse Source #

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

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

data TestInvokeAuthorizerResponse Source #

Represents the response of the test invoke request in for a custom Authorizer

See: testInvokeAuthorizerResponse smart constructor.

Instances

Eq TestInvokeAuthorizerResponse Source # 
Data TestInvokeAuthorizerResponse Source # 

Methods

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

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

toConstr :: TestInvokeAuthorizerResponse -> Constr #

dataTypeOf :: TestInvokeAuthorizerResponse -> DataType #

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

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

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

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

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

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

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

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

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

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

Read TestInvokeAuthorizerResponse Source # 
Show TestInvokeAuthorizerResponse Source # 
Generic TestInvokeAuthorizerResponse Source # 
NFData TestInvokeAuthorizerResponse Source # 
type Rep TestInvokeAuthorizerResponse Source # 
type Rep TestInvokeAuthorizerResponse = D1 (MetaData "TestInvokeAuthorizerResponse" "Network.AWS.APIGateway.TestInvokeAuthorizer" "amazonka-apigateway-1.4.3-GVOaWI3QK1e6b27bXNOifn" False) (C1 (MetaCons "TestInvokeAuthorizerResponse'" PrefixI True) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_tiarsLog") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) ((:*:) (S1 (MetaSel (Just Symbol "_tiarsPrincipalId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_tiarsLatency") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Integer))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_tiarsAuthorization") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text [Text])))) (S1 (MetaSel (Just Symbol "_tiarsClientStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Int)))) ((:*:) (S1 (MetaSel (Just Symbol "_tiarsPolicy") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_tiarsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))))))

Response Lenses

tiarsLog :: Lens' TestInvokeAuthorizerResponse (Maybe Text) Source #

The Amazon API Gateway execution log for the test authorizer request.

tiarsPrincipalId :: Lens' TestInvokeAuthorizerResponse (Maybe Text) Source #

The principal identity returned by the Authorizer

tiarsLatency :: Lens' TestInvokeAuthorizerResponse (Maybe Integer) Source #

The execution latency of the test authorizer request

tiarsClientStatus :: Lens' TestInvokeAuthorizerResponse (Maybe Int) Source #

The HTTP status code that the client would have received. Value is 0 if the authorizer succeeded.

tiarsPolicy :: Lens' TestInvokeAuthorizerResponse (Maybe Text) Source #

The policy JSON document returned by the Authorizer