{-# 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.EndpointBatchItem where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Pinpoint.Types.ChannelType
import Amazonka.Pinpoint.Types.EndpointDemographic
import Amazonka.Pinpoint.Types.EndpointLocation
import Amazonka.Pinpoint.Types.EndpointUser
import qualified Amazonka.Prelude as Prelude
data EndpointBatchItem = EndpointBatchItem'
{
EndpointBatchItem -> Maybe Text
requestId :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe (HashMap Text Double)
metrics :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Double),
EndpointBatchItem -> Maybe EndpointLocation
location :: Prelude.Maybe EndpointLocation,
EndpointBatchItem -> Maybe EndpointDemographic
demographic :: Prelude.Maybe EndpointDemographic,
EndpointBatchItem -> Maybe Text
address :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe Text
effectiveDate :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe EndpointUser
user :: Prelude.Maybe EndpointUser,
EndpointBatchItem -> Maybe (HashMap Text [Text])
attributes :: Prelude.Maybe (Prelude.HashMap Prelude.Text [Prelude.Text]),
EndpointBatchItem -> Maybe Text
endpointStatus :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe Text
optOut :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
EndpointBatchItem -> Maybe ChannelType
channelType :: Prelude.Maybe ChannelType
}
deriving (EndpointBatchItem -> EndpointBatchItem -> Bool
(EndpointBatchItem -> EndpointBatchItem -> Bool)
-> (EndpointBatchItem -> EndpointBatchItem -> Bool)
-> Eq EndpointBatchItem
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EndpointBatchItem -> EndpointBatchItem -> Bool
$c/= :: EndpointBatchItem -> EndpointBatchItem -> Bool
== :: EndpointBatchItem -> EndpointBatchItem -> Bool
$c== :: EndpointBatchItem -> EndpointBatchItem -> Bool
Prelude.Eq, ReadPrec [EndpointBatchItem]
ReadPrec EndpointBatchItem
Int -> ReadS EndpointBatchItem
ReadS [EndpointBatchItem]
(Int -> ReadS EndpointBatchItem)
-> ReadS [EndpointBatchItem]
-> ReadPrec EndpointBatchItem
-> ReadPrec [EndpointBatchItem]
-> Read EndpointBatchItem
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EndpointBatchItem]
$creadListPrec :: ReadPrec [EndpointBatchItem]
readPrec :: ReadPrec EndpointBatchItem
$creadPrec :: ReadPrec EndpointBatchItem
readList :: ReadS [EndpointBatchItem]
$creadList :: ReadS [EndpointBatchItem]
readsPrec :: Int -> ReadS EndpointBatchItem
$creadsPrec :: Int -> ReadS EndpointBatchItem
Prelude.Read, Int -> EndpointBatchItem -> ShowS
[EndpointBatchItem] -> ShowS
EndpointBatchItem -> String
(Int -> EndpointBatchItem -> ShowS)
-> (EndpointBatchItem -> String)
-> ([EndpointBatchItem] -> ShowS)
-> Show EndpointBatchItem
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EndpointBatchItem] -> ShowS
$cshowList :: [EndpointBatchItem] -> ShowS
show :: EndpointBatchItem -> String
$cshow :: EndpointBatchItem -> String
showsPrec :: Int -> EndpointBatchItem -> ShowS
$cshowsPrec :: Int -> EndpointBatchItem -> ShowS
Prelude.Show, (forall x. EndpointBatchItem -> Rep EndpointBatchItem x)
-> (forall x. Rep EndpointBatchItem x -> EndpointBatchItem)
-> Generic EndpointBatchItem
forall x. Rep EndpointBatchItem x -> EndpointBatchItem
forall x. EndpointBatchItem -> Rep EndpointBatchItem x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep EndpointBatchItem x -> EndpointBatchItem
$cfrom :: forall x. EndpointBatchItem -> Rep EndpointBatchItem x
Prelude.Generic)
newEndpointBatchItem ::
EndpointBatchItem
newEndpointBatchItem :: EndpointBatchItem
newEndpointBatchItem =
EndpointBatchItem' :: Maybe Text
-> Maybe (HashMap Text Double)
-> Maybe EndpointLocation
-> Maybe EndpointDemographic
-> Maybe Text
-> Maybe Text
-> Maybe EndpointUser
-> Maybe (HashMap Text [Text])
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ChannelType
-> EndpointBatchItem
EndpointBatchItem'
{ $sel:requestId:EndpointBatchItem' :: Maybe Text
requestId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:metrics:EndpointBatchItem' :: Maybe (HashMap Text Double)
metrics = Maybe (HashMap Text Double)
forall a. Maybe a
Prelude.Nothing,
$sel:location:EndpointBatchItem' :: Maybe EndpointLocation
location = Maybe EndpointLocation
forall a. Maybe a
Prelude.Nothing,
$sel:demographic:EndpointBatchItem' :: Maybe EndpointDemographic
demographic = Maybe EndpointDemographic
forall a. Maybe a
Prelude.Nothing,
$sel:address:EndpointBatchItem' :: Maybe Text
address = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:effectiveDate:EndpointBatchItem' :: Maybe Text
effectiveDate = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:user:EndpointBatchItem' :: Maybe EndpointUser
user = Maybe EndpointUser
forall a. Maybe a
Prelude.Nothing,
$sel:attributes:EndpointBatchItem' :: Maybe (HashMap Text [Text])
attributes = Maybe (HashMap Text [Text])
forall a. Maybe a
Prelude.Nothing,
$sel:endpointStatus:EndpointBatchItem' :: Maybe Text
endpointStatus = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:optOut:EndpointBatchItem' :: Maybe Text
optOut = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:id:EndpointBatchItem' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:channelType:EndpointBatchItem' :: Maybe ChannelType
channelType = Maybe ChannelType
forall a. Maybe a
Prelude.Nothing
}
endpointBatchItem_requestId :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_requestId :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_requestId = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
requestId :: Maybe Text
$sel:requestId:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
requestId} -> Maybe Text
requestId) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:requestId:EndpointBatchItem' :: Maybe Text
requestId = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_metrics :: Lens.Lens' EndpointBatchItem (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Double))
endpointBatchItem_metrics :: (Maybe (HashMap Text Double) -> f (Maybe (HashMap Text Double)))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_metrics = (EndpointBatchItem -> Maybe (HashMap Text Double))
-> (EndpointBatchItem
-> Maybe (HashMap Text Double) -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(Maybe (HashMap Text Double))
(Maybe (HashMap Text Double))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe (HashMap Text Double)
metrics :: Maybe (HashMap Text Double)
$sel:metrics:EndpointBatchItem' :: EndpointBatchItem -> Maybe (HashMap Text Double)
metrics} -> Maybe (HashMap Text Double)
metrics) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe (HashMap Text Double)
a -> EndpointBatchItem
s {$sel:metrics:EndpointBatchItem' :: Maybe (HashMap Text Double)
metrics = Maybe (HashMap Text Double)
a} :: EndpointBatchItem) ((Maybe (HashMap Text Double) -> f (Maybe (HashMap Text Double)))
-> EndpointBatchItem -> f EndpointBatchItem)
-> ((Maybe (HashMap Text Double)
-> f (Maybe (HashMap Text Double)))
-> Maybe (HashMap Text Double) -> f (Maybe (HashMap Text Double)))
-> (Maybe (HashMap Text Double) -> f (Maybe (HashMap Text Double)))
-> EndpointBatchItem
-> f EndpointBatchItem
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Double)
(HashMap Text Double)
(HashMap Text Double)
(HashMap Text Double)
-> Iso
(Maybe (HashMap Text Double))
(Maybe (HashMap Text Double))
(Maybe (HashMap Text Double))
(Maybe (HashMap Text Double))
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 Double)
(HashMap Text Double)
(HashMap Text Double)
(HashMap Text Double)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
endpointBatchItem_location :: Lens.Lens' EndpointBatchItem (Prelude.Maybe EndpointLocation)
endpointBatchItem_location :: (Maybe EndpointLocation -> f (Maybe EndpointLocation))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_location = (EndpointBatchItem -> Maybe EndpointLocation)
-> (EndpointBatchItem
-> Maybe EndpointLocation -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(Maybe EndpointLocation)
(Maybe EndpointLocation)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe EndpointLocation
location :: Maybe EndpointLocation
$sel:location:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointLocation
location} -> Maybe EndpointLocation
location) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe EndpointLocation
a -> EndpointBatchItem
s {$sel:location:EndpointBatchItem' :: Maybe EndpointLocation
location = Maybe EndpointLocation
a} :: EndpointBatchItem)
endpointBatchItem_demographic :: Lens.Lens' EndpointBatchItem (Prelude.Maybe EndpointDemographic)
endpointBatchItem_demographic :: (Maybe EndpointDemographic -> f (Maybe EndpointDemographic))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_demographic = (EndpointBatchItem -> Maybe EndpointDemographic)
-> (EndpointBatchItem
-> Maybe EndpointDemographic -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(Maybe EndpointDemographic)
(Maybe EndpointDemographic)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe EndpointDemographic
demographic :: Maybe EndpointDemographic
$sel:demographic:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointDemographic
demographic} -> Maybe EndpointDemographic
demographic) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe EndpointDemographic
a -> EndpointBatchItem
s {$sel:demographic:EndpointBatchItem' :: Maybe EndpointDemographic
demographic = Maybe EndpointDemographic
a} :: EndpointBatchItem)
endpointBatchItem_address :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_address :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_address = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
address :: Maybe Text
$sel:address:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
address} -> Maybe Text
address) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:address:EndpointBatchItem' :: Maybe Text
address = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_effectiveDate :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_effectiveDate :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_effectiveDate = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
effectiveDate :: Maybe Text
$sel:effectiveDate:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
effectiveDate} -> Maybe Text
effectiveDate) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:effectiveDate:EndpointBatchItem' :: Maybe Text
effectiveDate = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_user :: Lens.Lens' EndpointBatchItem (Prelude.Maybe EndpointUser)
endpointBatchItem_user :: (Maybe EndpointUser -> f (Maybe EndpointUser))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_user = (EndpointBatchItem -> Maybe EndpointUser)
-> (EndpointBatchItem -> Maybe EndpointUser -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(Maybe EndpointUser)
(Maybe EndpointUser)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe EndpointUser
user :: Maybe EndpointUser
$sel:user:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointUser
user} -> Maybe EndpointUser
user) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe EndpointUser
a -> EndpointBatchItem
s {$sel:user:EndpointBatchItem' :: Maybe EndpointUser
user = Maybe EndpointUser
a} :: EndpointBatchItem)
endpointBatchItem_attributes :: Lens.Lens' EndpointBatchItem (Prelude.Maybe (Prelude.HashMap Prelude.Text [Prelude.Text]))
endpointBatchItem_attributes :: (Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_attributes = (EndpointBatchItem -> Maybe (HashMap Text [Text]))
-> (EndpointBatchItem
-> Maybe (HashMap Text [Text]) -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(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 (\EndpointBatchItem' {Maybe (HashMap Text [Text])
attributes :: Maybe (HashMap Text [Text])
$sel:attributes:EndpointBatchItem' :: EndpointBatchItem -> Maybe (HashMap Text [Text])
attributes} -> Maybe (HashMap Text [Text])
attributes) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe (HashMap Text [Text])
a -> EndpointBatchItem
s {$sel:attributes:EndpointBatchItem' :: Maybe (HashMap Text [Text])
attributes = Maybe (HashMap Text [Text])
a} :: EndpointBatchItem) ((Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
-> EndpointBatchItem -> f EndpointBatchItem)
-> ((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])))
-> EndpointBatchItem
-> f EndpointBatchItem
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
endpointBatchItem_endpointStatus :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_endpointStatus :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_endpointStatus = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
endpointStatus :: Maybe Text
$sel:endpointStatus:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
endpointStatus} -> Maybe Text
endpointStatus) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:endpointStatus:EndpointBatchItem' :: Maybe Text
endpointStatus = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_optOut :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_optOut :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_optOut = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
optOut :: Maybe Text
$sel:optOut:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
optOut} -> Maybe Text
optOut) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:optOut:EndpointBatchItem' :: Maybe Text
optOut = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_id :: Lens.Lens' EndpointBatchItem (Prelude.Maybe Prelude.Text)
endpointBatchItem_id :: (Maybe Text -> f (Maybe Text))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_id = (EndpointBatchItem -> Maybe Text)
-> (EndpointBatchItem -> Maybe Text -> EndpointBatchItem)
-> Lens
EndpointBatchItem EndpointBatchItem (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe Text
id :: Maybe Text
$sel:id:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
id} -> Maybe Text
id) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe Text
a -> EndpointBatchItem
s {$sel:id:EndpointBatchItem' :: Maybe Text
id = Maybe Text
a} :: EndpointBatchItem)
endpointBatchItem_channelType :: Lens.Lens' EndpointBatchItem (Prelude.Maybe ChannelType)
endpointBatchItem_channelType :: (Maybe ChannelType -> f (Maybe ChannelType))
-> EndpointBatchItem -> f EndpointBatchItem
endpointBatchItem_channelType = (EndpointBatchItem -> Maybe ChannelType)
-> (EndpointBatchItem -> Maybe ChannelType -> EndpointBatchItem)
-> Lens
EndpointBatchItem
EndpointBatchItem
(Maybe ChannelType)
(Maybe ChannelType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EndpointBatchItem' {Maybe ChannelType
channelType :: Maybe ChannelType
$sel:channelType:EndpointBatchItem' :: EndpointBatchItem -> Maybe ChannelType
channelType} -> Maybe ChannelType
channelType) (\s :: EndpointBatchItem
s@EndpointBatchItem' {} Maybe ChannelType
a -> EndpointBatchItem
s {$sel:channelType:EndpointBatchItem' :: Maybe ChannelType
channelType = Maybe ChannelType
a} :: EndpointBatchItem)
instance Prelude.Hashable EndpointBatchItem
instance Prelude.NFData EndpointBatchItem
instance Core.ToJSON EndpointBatchItem where
toJSON :: EndpointBatchItem -> Value
toJSON EndpointBatchItem' {Maybe Text
Maybe (HashMap Text Double)
Maybe (HashMap Text [Text])
Maybe ChannelType
Maybe EndpointDemographic
Maybe EndpointLocation
Maybe EndpointUser
channelType :: Maybe ChannelType
id :: Maybe Text
optOut :: Maybe Text
endpointStatus :: Maybe Text
attributes :: Maybe (HashMap Text [Text])
user :: Maybe EndpointUser
effectiveDate :: Maybe Text
address :: Maybe Text
demographic :: Maybe EndpointDemographic
location :: Maybe EndpointLocation
metrics :: Maybe (HashMap Text Double)
requestId :: Maybe Text
$sel:channelType:EndpointBatchItem' :: EndpointBatchItem -> Maybe ChannelType
$sel:id:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
$sel:optOut:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
$sel:endpointStatus:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
$sel:attributes:EndpointBatchItem' :: EndpointBatchItem -> Maybe (HashMap Text [Text])
$sel:user:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointUser
$sel:effectiveDate:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
$sel:address:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
$sel:demographic:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointDemographic
$sel:location:EndpointBatchItem' :: EndpointBatchItem -> Maybe EndpointLocation
$sel:metrics:EndpointBatchItem' :: EndpointBatchItem -> Maybe (HashMap Text Double)
$sel:requestId:EndpointBatchItem' :: EndpointBatchItem -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"RequestId" 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
requestId,
(Text
"Metrics" Text -> HashMap Text Double -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Double -> Pair)
-> Maybe (HashMap Text Double) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Double)
metrics,
(Text
"Location" Text -> EndpointLocation -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EndpointLocation -> Pair) -> Maybe EndpointLocation -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EndpointLocation
location,
(Text
"Demographic" Text -> EndpointDemographic -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EndpointDemographic -> Pair)
-> Maybe EndpointDemographic -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EndpointDemographic
demographic,
(Text
"Address" 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
address,
(Text
"EffectiveDate" 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
effectiveDate,
(Text
"User" Text -> EndpointUser -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EndpointUser -> Pair) -> Maybe EndpointUser -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EndpointUser
user,
(Text
"Attributes" Text -> HashMap Text [Text] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text [Text] -> Pair)
-> Maybe (HashMap Text [Text]) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text [Text])
attributes,
(Text
"EndpointStatus" 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
endpointStatus,
(Text
"OptOut" 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
optOut,
(Text
"Id" 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
id,
(Text
"ChannelType" Text -> ChannelType -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (ChannelType -> Pair) -> Maybe ChannelType -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ChannelType
channelType
]
)