{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Pinpoint.Types.InAppTemplateResponse where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Pinpoint.Types.InAppMessageContent
import Amazonka.Pinpoint.Types.Layout
import Amazonka.Pinpoint.Types.TemplateType
import qualified Amazonka.Prelude as Prelude
data InAppTemplateResponse = InAppTemplateResponse'
{
InAppTemplateResponse -> Maybe Layout
layout :: Prelude.Maybe Layout,
InAppTemplateResponse -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
InAppTemplateResponse -> Maybe Text
templateDescription :: Prelude.Maybe Prelude.Text,
InAppTemplateResponse -> Maybe [InAppMessageContent]
content :: Prelude.Maybe [InAppMessageContent],
InAppTemplateResponse -> Maybe (HashMap Text Text)
customConfig :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
InAppTemplateResponse -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
InAppTemplateResponse -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
InAppTemplateResponse -> Text
lastModifiedDate :: Prelude.Text,
InAppTemplateResponse -> Text
creationDate :: Prelude.Text,
InAppTemplateResponse -> Text
templateName :: Prelude.Text,
InAppTemplateResponse -> TemplateType
templateType :: TemplateType
}
deriving (InAppTemplateResponse -> InAppTemplateResponse -> Bool
(InAppTemplateResponse -> InAppTemplateResponse -> Bool)
-> (InAppTemplateResponse -> InAppTemplateResponse -> Bool)
-> Eq InAppTemplateResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InAppTemplateResponse -> InAppTemplateResponse -> Bool
$c/= :: InAppTemplateResponse -> InAppTemplateResponse -> Bool
== :: InAppTemplateResponse -> InAppTemplateResponse -> Bool
$c== :: InAppTemplateResponse -> InAppTemplateResponse -> Bool
Prelude.Eq, ReadPrec [InAppTemplateResponse]
ReadPrec InAppTemplateResponse
Int -> ReadS InAppTemplateResponse
ReadS [InAppTemplateResponse]
(Int -> ReadS InAppTemplateResponse)
-> ReadS [InAppTemplateResponse]
-> ReadPrec InAppTemplateResponse
-> ReadPrec [InAppTemplateResponse]
-> Read InAppTemplateResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [InAppTemplateResponse]
$creadListPrec :: ReadPrec [InAppTemplateResponse]
readPrec :: ReadPrec InAppTemplateResponse
$creadPrec :: ReadPrec InAppTemplateResponse
readList :: ReadS [InAppTemplateResponse]
$creadList :: ReadS [InAppTemplateResponse]
readsPrec :: Int -> ReadS InAppTemplateResponse
$creadsPrec :: Int -> ReadS InAppTemplateResponse
Prelude.Read, Int -> InAppTemplateResponse -> ShowS
[InAppTemplateResponse] -> ShowS
InAppTemplateResponse -> String
(Int -> InAppTemplateResponse -> ShowS)
-> (InAppTemplateResponse -> String)
-> ([InAppTemplateResponse] -> ShowS)
-> Show InAppTemplateResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InAppTemplateResponse] -> ShowS
$cshowList :: [InAppTemplateResponse] -> ShowS
show :: InAppTemplateResponse -> String
$cshow :: InAppTemplateResponse -> String
showsPrec :: Int -> InAppTemplateResponse -> ShowS
$cshowsPrec :: Int -> InAppTemplateResponse -> ShowS
Prelude.Show, (forall x. InAppTemplateResponse -> Rep InAppTemplateResponse x)
-> (forall x. Rep InAppTemplateResponse x -> InAppTemplateResponse)
-> Generic InAppTemplateResponse
forall x. Rep InAppTemplateResponse x -> InAppTemplateResponse
forall x. InAppTemplateResponse -> Rep InAppTemplateResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep InAppTemplateResponse x -> InAppTemplateResponse
$cfrom :: forall x. InAppTemplateResponse -> Rep InAppTemplateResponse x
Prelude.Generic)
newInAppTemplateResponse ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
TemplateType ->
InAppTemplateResponse
newInAppTemplateResponse :: Text -> Text -> Text -> TemplateType -> InAppTemplateResponse
newInAppTemplateResponse
Text
pLastModifiedDate_
Text
pCreationDate_
Text
pTemplateName_
TemplateType
pTemplateType_ =
InAppTemplateResponse' :: Maybe Layout
-> Maybe Text
-> Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse
InAppTemplateResponse'
{ $sel:layout:InAppTemplateResponse' :: Maybe Layout
layout = Maybe Layout
forall a. Maybe a
Prelude.Nothing,
$sel:arn:InAppTemplateResponse' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:templateDescription:InAppTemplateResponse' :: Maybe Text
templateDescription = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:content:InAppTemplateResponse' :: Maybe [InAppMessageContent]
content = Maybe [InAppMessageContent]
forall a. Maybe a
Prelude.Nothing,
$sel:customConfig:InAppTemplateResponse' :: Maybe (HashMap Text Text)
customConfig = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:version:InAppTemplateResponse' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:InAppTemplateResponse' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedDate:InAppTemplateResponse' :: Text
lastModifiedDate = Text
pLastModifiedDate_,
$sel:creationDate:InAppTemplateResponse' :: Text
creationDate = Text
pCreationDate_,
$sel:templateName:InAppTemplateResponse' :: Text
templateName = Text
pTemplateName_,
$sel:templateType:InAppTemplateResponse' :: TemplateType
templateType = TemplateType
pTemplateType_
}
inAppTemplateResponse_layout :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe Layout)
inAppTemplateResponse_layout :: (Maybe Layout -> f (Maybe Layout))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_layout = (InAppTemplateResponse -> Maybe Layout)
-> (InAppTemplateResponse -> Maybe Layout -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe Layout)
(Maybe Layout)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe Layout
layout :: Maybe Layout
$sel:layout:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe Layout
layout} -> Maybe Layout
layout) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe Layout
a -> InAppTemplateResponse
s {$sel:layout:InAppTemplateResponse' :: Maybe Layout
layout = Maybe Layout
a} :: InAppTemplateResponse)
inAppTemplateResponse_arn :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe Prelude.Text)
inAppTemplateResponse_arn :: (Maybe Text -> f (Maybe Text))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_arn = (InAppTemplateResponse -> Maybe Text)
-> (InAppTemplateResponse -> Maybe Text -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe Text
arn :: Maybe Text
$sel:arn:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe Text
arn} -> Maybe Text
arn) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe Text
a -> InAppTemplateResponse
s {$sel:arn:InAppTemplateResponse' :: Maybe Text
arn = Maybe Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_templateDescription :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe Prelude.Text)
inAppTemplateResponse_templateDescription :: (Maybe Text -> f (Maybe Text))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_templateDescription = (InAppTemplateResponse -> Maybe Text)
-> (InAppTemplateResponse -> Maybe Text -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe Text
templateDescription :: Maybe Text
$sel:templateDescription:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe Text
templateDescription} -> Maybe Text
templateDescription) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe Text
a -> InAppTemplateResponse
s {$sel:templateDescription:InAppTemplateResponse' :: Maybe Text
templateDescription = Maybe Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_content :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe [InAppMessageContent])
inAppTemplateResponse_content :: (Maybe [InAppMessageContent] -> f (Maybe [InAppMessageContent]))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_content = (InAppTemplateResponse -> Maybe [InAppMessageContent])
-> (InAppTemplateResponse
-> Maybe [InAppMessageContent] -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe [InAppMessageContent])
(Maybe [InAppMessageContent])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe [InAppMessageContent]
content :: Maybe [InAppMessageContent]
$sel:content:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe [InAppMessageContent]
content} -> Maybe [InAppMessageContent]
content) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe [InAppMessageContent]
a -> InAppTemplateResponse
s {$sel:content:InAppTemplateResponse' :: Maybe [InAppMessageContent]
content = Maybe [InAppMessageContent]
a} :: InAppTemplateResponse) ((Maybe [InAppMessageContent] -> f (Maybe [InAppMessageContent]))
-> InAppTemplateResponse -> f InAppTemplateResponse)
-> ((Maybe [InAppMessageContent]
-> f (Maybe [InAppMessageContent]))
-> Maybe [InAppMessageContent] -> f (Maybe [InAppMessageContent]))
-> (Maybe [InAppMessageContent] -> f (Maybe [InAppMessageContent]))
-> InAppTemplateResponse
-> f InAppTemplateResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[InAppMessageContent]
[InAppMessageContent]
[InAppMessageContent]
[InAppMessageContent]
-> Iso
(Maybe [InAppMessageContent])
(Maybe [InAppMessageContent])
(Maybe [InAppMessageContent])
(Maybe [InAppMessageContent])
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
[InAppMessageContent]
[InAppMessageContent]
[InAppMessageContent]
[InAppMessageContent]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
inAppTemplateResponse_customConfig :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
inAppTemplateResponse_customConfig :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_customConfig = (InAppTemplateResponse -> Maybe (HashMap Text Text))
-> (InAppTemplateResponse
-> Maybe (HashMap Text Text) -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe (HashMap Text Text)
customConfig :: Maybe (HashMap Text Text)
$sel:customConfig:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe (HashMap Text Text)
customConfig} -> Maybe (HashMap Text Text)
customConfig) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe (HashMap Text Text)
a -> InAppTemplateResponse
s {$sel:customConfig:InAppTemplateResponse' :: Maybe (HashMap Text Text)
customConfig = Maybe (HashMap Text Text)
a} :: InAppTemplateResponse) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse -> f InAppTemplateResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse
-> f InAppTemplateResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
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
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
inAppTemplateResponse_version :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe Prelude.Text)
inAppTemplateResponse_version :: (Maybe Text -> f (Maybe Text))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_version = (InAppTemplateResponse -> Maybe Text)
-> (InAppTemplateResponse -> Maybe Text -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe Text
version :: Maybe Text
$sel:version:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe Text
version} -> Maybe Text
version) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe Text
a -> InAppTemplateResponse
s {$sel:version:InAppTemplateResponse' :: Maybe Text
version = Maybe Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_tags :: Lens.Lens' InAppTemplateResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
inAppTemplateResponse_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_tags = (InAppTemplateResponse -> Maybe (HashMap Text Text))
-> (InAppTemplateResponse
-> Maybe (HashMap Text Text) -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:InAppTemplateResponse' :: InAppTemplateResponse -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Maybe (HashMap Text Text)
a -> InAppTemplateResponse
s {$sel:tags:InAppTemplateResponse' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: InAppTemplateResponse) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse -> f InAppTemplateResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> InAppTemplateResponse
-> f InAppTemplateResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
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
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
inAppTemplateResponse_lastModifiedDate :: Lens.Lens' InAppTemplateResponse Prelude.Text
inAppTemplateResponse_lastModifiedDate :: (Text -> f Text)
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_lastModifiedDate = (InAppTemplateResponse -> Text)
-> (InAppTemplateResponse -> Text -> InAppTemplateResponse)
-> Lens InAppTemplateResponse InAppTemplateResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Text
lastModifiedDate :: Text
$sel:lastModifiedDate:InAppTemplateResponse' :: InAppTemplateResponse -> Text
lastModifiedDate} -> Text
lastModifiedDate) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Text
a -> InAppTemplateResponse
s {$sel:lastModifiedDate:InAppTemplateResponse' :: Text
lastModifiedDate = Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_creationDate :: Lens.Lens' InAppTemplateResponse Prelude.Text
inAppTemplateResponse_creationDate :: (Text -> f Text)
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_creationDate = (InAppTemplateResponse -> Text)
-> (InAppTemplateResponse -> Text -> InAppTemplateResponse)
-> Lens InAppTemplateResponse InAppTemplateResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Text
creationDate :: Text
$sel:creationDate:InAppTemplateResponse' :: InAppTemplateResponse -> Text
creationDate} -> Text
creationDate) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Text
a -> InAppTemplateResponse
s {$sel:creationDate:InAppTemplateResponse' :: Text
creationDate = Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_templateName :: Lens.Lens' InAppTemplateResponse Prelude.Text
inAppTemplateResponse_templateName :: (Text -> f Text)
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_templateName = (InAppTemplateResponse -> Text)
-> (InAppTemplateResponse -> Text -> InAppTemplateResponse)
-> Lens InAppTemplateResponse InAppTemplateResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {Text
templateName :: Text
$sel:templateName:InAppTemplateResponse' :: InAppTemplateResponse -> Text
templateName} -> Text
templateName) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} Text
a -> InAppTemplateResponse
s {$sel:templateName:InAppTemplateResponse' :: Text
templateName = Text
a} :: InAppTemplateResponse)
inAppTemplateResponse_templateType :: Lens.Lens' InAppTemplateResponse TemplateType
inAppTemplateResponse_templateType :: (TemplateType -> f TemplateType)
-> InAppTemplateResponse -> f InAppTemplateResponse
inAppTemplateResponse_templateType = (InAppTemplateResponse -> TemplateType)
-> (InAppTemplateResponse -> TemplateType -> InAppTemplateResponse)
-> Lens
InAppTemplateResponse
InAppTemplateResponse
TemplateType
TemplateType
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InAppTemplateResponse' {TemplateType
templateType :: TemplateType
$sel:templateType:InAppTemplateResponse' :: InAppTemplateResponse -> TemplateType
templateType} -> TemplateType
templateType) (\s :: InAppTemplateResponse
s@InAppTemplateResponse' {} TemplateType
a -> InAppTemplateResponse
s {$sel:templateType:InAppTemplateResponse' :: TemplateType
templateType = TemplateType
a} :: InAppTemplateResponse)
instance Core.FromJSON InAppTemplateResponse where
parseJSON :: Value -> Parser InAppTemplateResponse
parseJSON =
String
-> (Object -> Parser InAppTemplateResponse)
-> Value
-> Parser InAppTemplateResponse
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"InAppTemplateResponse"
( \Object
x ->
Maybe Layout
-> Maybe Text
-> Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse
InAppTemplateResponse'
(Maybe Layout
-> Maybe Text
-> Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe Layout)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Layout)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Layout")
Parser
(Maybe Text
-> Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Arn")
Parser
(Maybe Text
-> Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TemplateDescription")
Parser
(Maybe [InAppMessageContent]
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe [InAppMessageContent])
-> Parser
(Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [InAppMessageContent]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Content" Parser (Maybe (Maybe [InAppMessageContent]))
-> Maybe [InAppMessageContent]
-> Parser (Maybe [InAppMessageContent])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [InAppMessageContent]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe (HashMap Text Text))
-> Parser
(Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CustomConfig" Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> TemplateType
-> InAppTemplateResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe (HashMap Text Text)
-> Text -> Text -> Text -> TemplateType -> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Version")
Parser
(Maybe (HashMap Text Text)
-> Text -> Text -> Text -> TemplateType -> InAppTemplateResponse)
-> Parser (Maybe (HashMap Text Text))
-> Parser
(Text -> Text -> Text -> TemplateType -> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"tags" Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
Parser
(Text -> Text -> Text -> TemplateType -> InAppTemplateResponse)
-> Parser Text
-> Parser (Text -> Text -> TemplateType -> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"LastModifiedDate")
Parser (Text -> Text -> TemplateType -> InAppTemplateResponse)
-> Parser Text
-> Parser (Text -> TemplateType -> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CreationDate")
Parser (Text -> TemplateType -> InAppTemplateResponse)
-> Parser Text -> Parser (TemplateType -> InAppTemplateResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"TemplateName")
Parser (TemplateType -> InAppTemplateResponse)
-> Parser TemplateType -> Parser InAppTemplateResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser TemplateType
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"TemplateType")
)
instance Prelude.Hashable InAppTemplateResponse
instance Prelude.NFData InAppTemplateResponse