{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.FraudDetector.CreateRule
(
CreateRule (..),
newCreateRule,
createRule_description,
createRule_tags,
createRule_ruleId,
createRule_detectorId,
createRule_expression,
createRule_language,
createRule_outcomes,
CreateRuleResponse (..),
newCreateRuleResponse,
createRuleResponse_rule,
createRuleResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.FraudDetector.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateRule = CreateRule'
{
CreateRule -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
CreateRule -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
CreateRule -> Text
ruleId :: Prelude.Text,
CreateRule -> Text
detectorId :: Prelude.Text,
CreateRule -> Sensitive Text
expression :: Core.Sensitive Prelude.Text,
CreateRule -> Language
language :: Language,
CreateRule -> NonEmpty Text
outcomes :: Prelude.NonEmpty Prelude.Text
}
deriving (CreateRule -> CreateRule -> Bool
(CreateRule -> CreateRule -> Bool)
-> (CreateRule -> CreateRule -> Bool) -> Eq CreateRule
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateRule -> CreateRule -> Bool
$c/= :: CreateRule -> CreateRule -> Bool
== :: CreateRule -> CreateRule -> Bool
$c== :: CreateRule -> CreateRule -> Bool
Prelude.Eq, Int -> CreateRule -> ShowS
[CreateRule] -> ShowS
CreateRule -> String
(Int -> CreateRule -> ShowS)
-> (CreateRule -> String)
-> ([CreateRule] -> ShowS)
-> Show CreateRule
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateRule] -> ShowS
$cshowList :: [CreateRule] -> ShowS
show :: CreateRule -> String
$cshow :: CreateRule -> String
showsPrec :: Int -> CreateRule -> ShowS
$cshowsPrec :: Int -> CreateRule -> ShowS
Prelude.Show, (forall x. CreateRule -> Rep CreateRule x)
-> (forall x. Rep CreateRule x -> CreateRule) -> Generic CreateRule
forall x. Rep CreateRule x -> CreateRule
forall x. CreateRule -> Rep CreateRule x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateRule x -> CreateRule
$cfrom :: forall x. CreateRule -> Rep CreateRule x
Prelude.Generic)
newCreateRule ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Language ->
Prelude.NonEmpty Prelude.Text ->
CreateRule
newCreateRule :: Text -> Text -> Text -> Language -> NonEmpty Text -> CreateRule
newCreateRule
Text
pRuleId_
Text
pDetectorId_
Text
pExpression_
Language
pLanguage_
NonEmpty Text
pOutcomes_ =
CreateRule' :: Maybe Text
-> Maybe [Tag]
-> Text
-> Text
-> Sensitive Text
-> Language
-> NonEmpty Text
-> CreateRule
CreateRule'
{ $sel:description:CreateRule' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateRule' :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing,
$sel:ruleId:CreateRule' :: Text
ruleId = Text
pRuleId_,
$sel:detectorId:CreateRule' :: Text
detectorId = Text
pDetectorId_,
$sel:expression:CreateRule' :: Sensitive Text
expression = Tagged Text (Identity Text)
-> Tagged (Sensitive Text) (Identity (Sensitive Text))
forall a. Iso' (Sensitive a) a
Core._Sensitive (Tagged Text (Identity Text)
-> Tagged (Sensitive Text) (Identity (Sensitive Text)))
-> Text -> Sensitive Text
forall t b. AReview t b -> b -> t
Lens.# Text
pExpression_,
$sel:language:CreateRule' :: Language
language = Language
pLanguage_,
$sel:outcomes:CreateRule' :: NonEmpty Text
outcomes = Tagged (NonEmpty Text) (Identity (NonEmpty Text))
-> Tagged (NonEmpty Text) (Identity (NonEmpty Text))
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced (Tagged (NonEmpty Text) (Identity (NonEmpty Text))
-> Tagged (NonEmpty Text) (Identity (NonEmpty Text)))
-> NonEmpty Text -> NonEmpty Text
forall t b. AReview t b -> b -> t
Lens.# NonEmpty Text
pOutcomes_
}
createRule_description :: Lens.Lens' CreateRule (Prelude.Maybe Prelude.Text)
createRule_description :: (Maybe Text -> f (Maybe Text)) -> CreateRule -> f CreateRule
createRule_description = (CreateRule -> Maybe Text)
-> (CreateRule -> Maybe Text -> CreateRule)
-> Lens CreateRule CreateRule (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Maybe Text
description :: Maybe Text
$sel:description:CreateRule' :: CreateRule -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateRule
s@CreateRule' {} Maybe Text
a -> CreateRule
s {$sel:description:CreateRule' :: Maybe Text
description = Maybe Text
a} :: CreateRule)
createRule_tags :: Lens.Lens' CreateRule (Prelude.Maybe [Tag])
createRule_tags :: (Maybe [Tag] -> f (Maybe [Tag])) -> CreateRule -> f CreateRule
createRule_tags = (CreateRule -> Maybe [Tag])
-> (CreateRule -> Maybe [Tag] -> CreateRule)
-> Lens CreateRule CreateRule (Maybe [Tag]) (Maybe [Tag])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:CreateRule' :: CreateRule -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: CreateRule
s@CreateRule' {} Maybe [Tag]
a -> CreateRule
s {$sel:tags:CreateRule' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: CreateRule) ((Maybe [Tag] -> f (Maybe [Tag])) -> CreateRule -> f CreateRule)
-> ((Maybe [Tag] -> f (Maybe [Tag]))
-> Maybe [Tag] -> f (Maybe [Tag]))
-> (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateRule
-> f CreateRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Tag] [Tag] [Tag] [Tag]
-> Iso (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Tag] [Tag] [Tag] [Tag]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createRule_ruleId :: Lens.Lens' CreateRule Prelude.Text
createRule_ruleId :: (Text -> f Text) -> CreateRule -> f CreateRule
createRule_ruleId = (CreateRule -> Text)
-> (CreateRule -> Text -> CreateRule)
-> Lens CreateRule CreateRule Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Text
ruleId :: Text
$sel:ruleId:CreateRule' :: CreateRule -> Text
ruleId} -> Text
ruleId) (\s :: CreateRule
s@CreateRule' {} Text
a -> CreateRule
s {$sel:ruleId:CreateRule' :: Text
ruleId = Text
a} :: CreateRule)
createRule_detectorId :: Lens.Lens' CreateRule Prelude.Text
createRule_detectorId :: (Text -> f Text) -> CreateRule -> f CreateRule
createRule_detectorId = (CreateRule -> Text)
-> (CreateRule -> Text -> CreateRule)
-> Lens CreateRule CreateRule Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Text
detectorId :: Text
$sel:detectorId:CreateRule' :: CreateRule -> Text
detectorId} -> Text
detectorId) (\s :: CreateRule
s@CreateRule' {} Text
a -> CreateRule
s {$sel:detectorId:CreateRule' :: Text
detectorId = Text
a} :: CreateRule)
createRule_expression :: Lens.Lens' CreateRule Prelude.Text
createRule_expression :: (Text -> f Text) -> CreateRule -> f CreateRule
createRule_expression = (CreateRule -> Sensitive Text)
-> (CreateRule -> Sensitive Text -> CreateRule)
-> Lens CreateRule CreateRule (Sensitive Text) (Sensitive Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Sensitive Text
expression :: Sensitive Text
$sel:expression:CreateRule' :: CreateRule -> Sensitive Text
expression} -> Sensitive Text
expression) (\s :: CreateRule
s@CreateRule' {} Sensitive Text
a -> CreateRule
s {$sel:expression:CreateRule' :: Sensitive Text
expression = Sensitive Text
a} :: CreateRule) ((Sensitive Text -> f (Sensitive Text))
-> CreateRule -> f CreateRule)
-> ((Text -> f Text) -> Sensitive Text -> f (Sensitive Text))
-> (Text -> f Text)
-> CreateRule
-> f CreateRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> f Text) -> Sensitive Text -> f (Sensitive Text)
forall a. Iso' (Sensitive a) a
Core._Sensitive
createRule_language :: Lens.Lens' CreateRule Language
createRule_language :: (Language -> f Language) -> CreateRule -> f CreateRule
createRule_language = (CreateRule -> Language)
-> (CreateRule -> Language -> CreateRule)
-> Lens CreateRule CreateRule Language Language
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {Language
language :: Language
$sel:language:CreateRule' :: CreateRule -> Language
language} -> Language
language) (\s :: CreateRule
s@CreateRule' {} Language
a -> CreateRule
s {$sel:language:CreateRule' :: Language
language = Language
a} :: CreateRule)
createRule_outcomes :: Lens.Lens' CreateRule (Prelude.NonEmpty Prelude.Text)
createRule_outcomes :: (NonEmpty Text -> f (NonEmpty Text)) -> CreateRule -> f CreateRule
createRule_outcomes = (CreateRule -> NonEmpty Text)
-> (CreateRule -> NonEmpty Text -> CreateRule)
-> Lens CreateRule CreateRule (NonEmpty Text) (NonEmpty Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRule' {NonEmpty Text
outcomes :: NonEmpty Text
$sel:outcomes:CreateRule' :: CreateRule -> NonEmpty Text
outcomes} -> NonEmpty Text
outcomes) (\s :: CreateRule
s@CreateRule' {} NonEmpty Text
a -> CreateRule
s {$sel:outcomes:CreateRule' :: NonEmpty Text
outcomes = NonEmpty Text
a} :: CreateRule) ((NonEmpty Text -> f (NonEmpty Text))
-> CreateRule -> f CreateRule)
-> ((NonEmpty Text -> f (NonEmpty Text))
-> NonEmpty Text -> f (NonEmpty Text))
-> (NonEmpty Text -> f (NonEmpty Text))
-> CreateRule
-> f CreateRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (NonEmpty Text -> f (NonEmpty Text))
-> NonEmpty Text -> f (NonEmpty Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Core.AWSRequest CreateRule where
type AWSResponse CreateRule = CreateRuleResponse
request :: CreateRule -> Request CreateRule
request = Service -> CreateRule -> Request CreateRule
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CreateRule
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateRule)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CreateRule))
-> Logger
-> Service
-> Proxy CreateRule
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateRule)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Rule -> Int -> CreateRuleResponse
CreateRuleResponse'
(Maybe Rule -> Int -> CreateRuleResponse)
-> Either String (Maybe Rule)
-> Either String (Int -> CreateRuleResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Rule)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"rule")
Either String (Int -> CreateRuleResponse)
-> Either String Int -> Either String CreateRuleResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable CreateRule
instance Prelude.NFData CreateRule
instance Core.ToHeaders CreateRule where
toHeaders :: CreateRule -> ResponseHeaders
toHeaders =
ResponseHeaders -> CreateRule -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWSHawksNestServiceFacade.CreateRule" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON CreateRule where
toJSON :: CreateRule -> Value
toJSON CreateRule' {Maybe [Tag]
Maybe Text
NonEmpty Text
Text
Sensitive Text
Language
outcomes :: NonEmpty Text
language :: Language
expression :: Sensitive Text
detectorId :: Text
ruleId :: Text
tags :: Maybe [Tag]
description :: Maybe Text
$sel:outcomes:CreateRule' :: CreateRule -> NonEmpty Text
$sel:language:CreateRule' :: CreateRule -> Language
$sel:expression:CreateRule' :: CreateRule -> Sensitive Text
$sel:detectorId:CreateRule' :: CreateRule -> Text
$sel:ruleId:CreateRule' :: CreateRule -> Text
$sel:tags:CreateRule' :: CreateRule -> Maybe [Tag]
$sel:description:CreateRule' :: CreateRule -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"description" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
description,
(Text
"tags" Text -> [Tag] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Tag] -> Pair) -> Maybe [Tag] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"ruleId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
ruleId),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"detectorId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
detectorId),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"expression" Text -> Sensitive Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Sensitive Text
expression),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"language" Text -> Language -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Language
language),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"outcomes" Text -> NonEmpty Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= NonEmpty Text
outcomes)
]
)
instance Core.ToPath CreateRule where
toPath :: CreateRule -> ByteString
toPath = ByteString -> CreateRule -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery CreateRule where
toQuery :: CreateRule -> QueryString
toQuery = QueryString -> CreateRule -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CreateRuleResponse = CreateRuleResponse'
{
CreateRuleResponse -> Maybe Rule
rule :: Prelude.Maybe Rule,
CreateRuleResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateRuleResponse -> CreateRuleResponse -> Bool
(CreateRuleResponse -> CreateRuleResponse -> Bool)
-> (CreateRuleResponse -> CreateRuleResponse -> Bool)
-> Eq CreateRuleResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateRuleResponse -> CreateRuleResponse -> Bool
$c/= :: CreateRuleResponse -> CreateRuleResponse -> Bool
== :: CreateRuleResponse -> CreateRuleResponse -> Bool
$c== :: CreateRuleResponse -> CreateRuleResponse -> Bool
Prelude.Eq, ReadPrec [CreateRuleResponse]
ReadPrec CreateRuleResponse
Int -> ReadS CreateRuleResponse
ReadS [CreateRuleResponse]
(Int -> ReadS CreateRuleResponse)
-> ReadS [CreateRuleResponse]
-> ReadPrec CreateRuleResponse
-> ReadPrec [CreateRuleResponse]
-> Read CreateRuleResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateRuleResponse]
$creadListPrec :: ReadPrec [CreateRuleResponse]
readPrec :: ReadPrec CreateRuleResponse
$creadPrec :: ReadPrec CreateRuleResponse
readList :: ReadS [CreateRuleResponse]
$creadList :: ReadS [CreateRuleResponse]
readsPrec :: Int -> ReadS CreateRuleResponse
$creadsPrec :: Int -> ReadS CreateRuleResponse
Prelude.Read, Int -> CreateRuleResponse -> ShowS
[CreateRuleResponse] -> ShowS
CreateRuleResponse -> String
(Int -> CreateRuleResponse -> ShowS)
-> (CreateRuleResponse -> String)
-> ([CreateRuleResponse] -> ShowS)
-> Show CreateRuleResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateRuleResponse] -> ShowS
$cshowList :: [CreateRuleResponse] -> ShowS
show :: CreateRuleResponse -> String
$cshow :: CreateRuleResponse -> String
showsPrec :: Int -> CreateRuleResponse -> ShowS
$cshowsPrec :: Int -> CreateRuleResponse -> ShowS
Prelude.Show, (forall x. CreateRuleResponse -> Rep CreateRuleResponse x)
-> (forall x. Rep CreateRuleResponse x -> CreateRuleResponse)
-> Generic CreateRuleResponse
forall x. Rep CreateRuleResponse x -> CreateRuleResponse
forall x. CreateRuleResponse -> Rep CreateRuleResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateRuleResponse x -> CreateRuleResponse
$cfrom :: forall x. CreateRuleResponse -> Rep CreateRuleResponse x
Prelude.Generic)
newCreateRuleResponse ::
Prelude.Int ->
CreateRuleResponse
newCreateRuleResponse :: Int -> CreateRuleResponse
newCreateRuleResponse Int
pHttpStatus_ =
CreateRuleResponse' :: Maybe Rule -> Int -> CreateRuleResponse
CreateRuleResponse'
{ $sel:rule:CreateRuleResponse' :: Maybe Rule
rule = Maybe Rule
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateRuleResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createRuleResponse_rule :: Lens.Lens' CreateRuleResponse (Prelude.Maybe Rule)
createRuleResponse_rule :: (Maybe Rule -> f (Maybe Rule))
-> CreateRuleResponse -> f CreateRuleResponse
createRuleResponse_rule = (CreateRuleResponse -> Maybe Rule)
-> (CreateRuleResponse -> Maybe Rule -> CreateRuleResponse)
-> Lens
CreateRuleResponse CreateRuleResponse (Maybe Rule) (Maybe Rule)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRuleResponse' {Maybe Rule
rule :: Maybe Rule
$sel:rule:CreateRuleResponse' :: CreateRuleResponse -> Maybe Rule
rule} -> Maybe Rule
rule) (\s :: CreateRuleResponse
s@CreateRuleResponse' {} Maybe Rule
a -> CreateRuleResponse
s {$sel:rule:CreateRuleResponse' :: Maybe Rule
rule = Maybe Rule
a} :: CreateRuleResponse)
createRuleResponse_httpStatus :: Lens.Lens' CreateRuleResponse Prelude.Int
createRuleResponse_httpStatus :: (Int -> f Int) -> CreateRuleResponse -> f CreateRuleResponse
createRuleResponse_httpStatus = (CreateRuleResponse -> Int)
-> (CreateRuleResponse -> Int -> CreateRuleResponse)
-> Lens CreateRuleResponse CreateRuleResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateRuleResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateRuleResponse' :: CreateRuleResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateRuleResponse
s@CreateRuleResponse' {} Int
a -> CreateRuleResponse
s {$sel:httpStatus:CreateRuleResponse' :: Int
httpStatus = Int
a} :: CreateRuleResponse)
instance Prelude.NFData CreateRuleResponse