{-# 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.ActivityResponse where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ActivityResponse = ActivityResponse'
{
ActivityResponse -> Maybe Text
state :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Maybe Text
start :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Maybe Int
timezonesCompletedCount :: Prelude.Maybe Prelude.Int,
ActivityResponse -> Maybe Int
timezonesTotalCount :: Prelude.Maybe Prelude.Int,
ActivityResponse -> Maybe Text
result :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Maybe Text
treatmentId :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Maybe Int
successfulEndpointCount :: Prelude.Maybe Prelude.Int,
ActivityResponse -> Maybe Text
end :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Maybe Int
totalEndpointCount :: Prelude.Maybe Prelude.Int,
ActivityResponse -> Maybe Text
scheduledStart :: Prelude.Maybe Prelude.Text,
ActivityResponse -> Text
campaignId :: Prelude.Text,
ActivityResponse -> Text
id :: Prelude.Text,
ActivityResponse -> Text
applicationId :: Prelude.Text
}
deriving (ActivityResponse -> ActivityResponse -> Bool
(ActivityResponse -> ActivityResponse -> Bool)
-> (ActivityResponse -> ActivityResponse -> Bool)
-> Eq ActivityResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ActivityResponse -> ActivityResponse -> Bool
$c/= :: ActivityResponse -> ActivityResponse -> Bool
== :: ActivityResponse -> ActivityResponse -> Bool
$c== :: ActivityResponse -> ActivityResponse -> Bool
Prelude.Eq, ReadPrec [ActivityResponse]
ReadPrec ActivityResponse
Int -> ReadS ActivityResponse
ReadS [ActivityResponse]
(Int -> ReadS ActivityResponse)
-> ReadS [ActivityResponse]
-> ReadPrec ActivityResponse
-> ReadPrec [ActivityResponse]
-> Read ActivityResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ActivityResponse]
$creadListPrec :: ReadPrec [ActivityResponse]
readPrec :: ReadPrec ActivityResponse
$creadPrec :: ReadPrec ActivityResponse
readList :: ReadS [ActivityResponse]
$creadList :: ReadS [ActivityResponse]
readsPrec :: Int -> ReadS ActivityResponse
$creadsPrec :: Int -> ReadS ActivityResponse
Prelude.Read, Int -> ActivityResponse -> ShowS
[ActivityResponse] -> ShowS
ActivityResponse -> String
(Int -> ActivityResponse -> ShowS)
-> (ActivityResponse -> String)
-> ([ActivityResponse] -> ShowS)
-> Show ActivityResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ActivityResponse] -> ShowS
$cshowList :: [ActivityResponse] -> ShowS
show :: ActivityResponse -> String
$cshow :: ActivityResponse -> String
showsPrec :: Int -> ActivityResponse -> ShowS
$cshowsPrec :: Int -> ActivityResponse -> ShowS
Prelude.Show, (forall x. ActivityResponse -> Rep ActivityResponse x)
-> (forall x. Rep ActivityResponse x -> ActivityResponse)
-> Generic ActivityResponse
forall x. Rep ActivityResponse x -> ActivityResponse
forall x. ActivityResponse -> Rep ActivityResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ActivityResponse x -> ActivityResponse
$cfrom :: forall x. ActivityResponse -> Rep ActivityResponse x
Prelude.Generic)
newActivityResponse ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
ActivityResponse
newActivityResponse :: Text -> Text -> Text -> ActivityResponse
newActivityResponse Text
pCampaignId_ Text
pId_ Text
pApplicationId_ =
ActivityResponse' :: Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse
ActivityResponse'
{ $sel:state:ActivityResponse' :: Maybe Text
state = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:start:ActivityResponse' :: Maybe Text
start = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:timezonesCompletedCount:ActivityResponse' :: Maybe Int
timezonesCompletedCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:timezonesTotalCount:ActivityResponse' :: Maybe Int
timezonesTotalCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:result:ActivityResponse' :: Maybe Text
result = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:treatmentId:ActivityResponse' :: Maybe Text
treatmentId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:successfulEndpointCount:ActivityResponse' :: Maybe Int
successfulEndpointCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:end:ActivityResponse' :: Maybe Text
end = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:totalEndpointCount:ActivityResponse' :: Maybe Int
totalEndpointCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:scheduledStart:ActivityResponse' :: Maybe Text
scheduledStart = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:campaignId:ActivityResponse' :: Text
campaignId = Text
pCampaignId_,
$sel:id:ActivityResponse' :: Text
id = Text
pId_,
$sel:applicationId:ActivityResponse' :: Text
applicationId = Text
pApplicationId_
}
activityResponse_state :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_state :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_state = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
state :: Maybe Text
$sel:state:ActivityResponse' :: ActivityResponse -> Maybe Text
state} -> Maybe Text
state) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:state:ActivityResponse' :: Maybe Text
state = Maybe Text
a} :: ActivityResponse)
activityResponse_start :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_start :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_start = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
start :: Maybe Text
$sel:start:ActivityResponse' :: ActivityResponse -> Maybe Text
start} -> Maybe Text
start) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:start:ActivityResponse' :: Maybe Text
start = Maybe Text
a} :: ActivityResponse)
activityResponse_timezonesCompletedCount :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Int)
activityResponse_timezonesCompletedCount :: (Maybe Int -> f (Maybe Int))
-> ActivityResponse -> f ActivityResponse
activityResponse_timezonesCompletedCount = (ActivityResponse -> Maybe Int)
-> (ActivityResponse -> Maybe Int -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Int
timezonesCompletedCount :: Maybe Int
$sel:timezonesCompletedCount:ActivityResponse' :: ActivityResponse -> Maybe Int
timezonesCompletedCount} -> Maybe Int
timezonesCompletedCount) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Int
a -> ActivityResponse
s {$sel:timezonesCompletedCount:ActivityResponse' :: Maybe Int
timezonesCompletedCount = Maybe Int
a} :: ActivityResponse)
activityResponse_timezonesTotalCount :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Int)
activityResponse_timezonesTotalCount :: (Maybe Int -> f (Maybe Int))
-> ActivityResponse -> f ActivityResponse
activityResponse_timezonesTotalCount = (ActivityResponse -> Maybe Int)
-> (ActivityResponse -> Maybe Int -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Int
timezonesTotalCount :: Maybe Int
$sel:timezonesTotalCount:ActivityResponse' :: ActivityResponse -> Maybe Int
timezonesTotalCount} -> Maybe Int
timezonesTotalCount) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Int
a -> ActivityResponse
s {$sel:timezonesTotalCount:ActivityResponse' :: Maybe Int
timezonesTotalCount = Maybe Int
a} :: ActivityResponse)
activityResponse_result :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_result :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_result = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
result :: Maybe Text
$sel:result:ActivityResponse' :: ActivityResponse -> Maybe Text
result} -> Maybe Text
result) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:result:ActivityResponse' :: Maybe Text
result = Maybe Text
a} :: ActivityResponse)
activityResponse_treatmentId :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_treatmentId :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_treatmentId = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
treatmentId :: Maybe Text
$sel:treatmentId:ActivityResponse' :: ActivityResponse -> Maybe Text
treatmentId} -> Maybe Text
treatmentId) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:treatmentId:ActivityResponse' :: Maybe Text
treatmentId = Maybe Text
a} :: ActivityResponse)
activityResponse_successfulEndpointCount :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Int)
activityResponse_successfulEndpointCount :: (Maybe Int -> f (Maybe Int))
-> ActivityResponse -> f ActivityResponse
activityResponse_successfulEndpointCount = (ActivityResponse -> Maybe Int)
-> (ActivityResponse -> Maybe Int -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Int
successfulEndpointCount :: Maybe Int
$sel:successfulEndpointCount:ActivityResponse' :: ActivityResponse -> Maybe Int
successfulEndpointCount} -> Maybe Int
successfulEndpointCount) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Int
a -> ActivityResponse
s {$sel:successfulEndpointCount:ActivityResponse' :: Maybe Int
successfulEndpointCount = Maybe Int
a} :: ActivityResponse)
activityResponse_end :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_end :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_end = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
end :: Maybe Text
$sel:end:ActivityResponse' :: ActivityResponse -> Maybe Text
end} -> Maybe Text
end) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:end:ActivityResponse' :: Maybe Text
end = Maybe Text
a} :: ActivityResponse)
activityResponse_totalEndpointCount :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Int)
activityResponse_totalEndpointCount :: (Maybe Int -> f (Maybe Int))
-> ActivityResponse -> f ActivityResponse
activityResponse_totalEndpointCount = (ActivityResponse -> Maybe Int)
-> (ActivityResponse -> Maybe Int -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Int
totalEndpointCount :: Maybe Int
$sel:totalEndpointCount:ActivityResponse' :: ActivityResponse -> Maybe Int
totalEndpointCount} -> Maybe Int
totalEndpointCount) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Int
a -> ActivityResponse
s {$sel:totalEndpointCount:ActivityResponse' :: Maybe Int
totalEndpointCount = Maybe Int
a} :: ActivityResponse)
activityResponse_scheduledStart :: Lens.Lens' ActivityResponse (Prelude.Maybe Prelude.Text)
activityResponse_scheduledStart :: (Maybe Text -> f (Maybe Text))
-> ActivityResponse -> f ActivityResponse
activityResponse_scheduledStart = (ActivityResponse -> Maybe Text)
-> (ActivityResponse -> Maybe Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Maybe Text
scheduledStart :: Maybe Text
$sel:scheduledStart:ActivityResponse' :: ActivityResponse -> Maybe Text
scheduledStart} -> Maybe Text
scheduledStart) (\s :: ActivityResponse
s@ActivityResponse' {} Maybe Text
a -> ActivityResponse
s {$sel:scheduledStart:ActivityResponse' :: Maybe Text
scheduledStart = Maybe Text
a} :: ActivityResponse)
activityResponse_campaignId :: Lens.Lens' ActivityResponse Prelude.Text
activityResponse_campaignId :: (Text -> f Text) -> ActivityResponse -> f ActivityResponse
activityResponse_campaignId = (ActivityResponse -> Text)
-> (ActivityResponse -> Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Text
campaignId :: Text
$sel:campaignId:ActivityResponse' :: ActivityResponse -> Text
campaignId} -> Text
campaignId) (\s :: ActivityResponse
s@ActivityResponse' {} Text
a -> ActivityResponse
s {$sel:campaignId:ActivityResponse' :: Text
campaignId = Text
a} :: ActivityResponse)
activityResponse_id :: Lens.Lens' ActivityResponse Prelude.Text
activityResponse_id :: (Text -> f Text) -> ActivityResponse -> f ActivityResponse
activityResponse_id = (ActivityResponse -> Text)
-> (ActivityResponse -> Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Text
id :: Text
$sel:id:ActivityResponse' :: ActivityResponse -> Text
id} -> Text
id) (\s :: ActivityResponse
s@ActivityResponse' {} Text
a -> ActivityResponse
s {$sel:id:ActivityResponse' :: Text
id = Text
a} :: ActivityResponse)
activityResponse_applicationId :: Lens.Lens' ActivityResponse Prelude.Text
activityResponse_applicationId :: (Text -> f Text) -> ActivityResponse -> f ActivityResponse
activityResponse_applicationId = (ActivityResponse -> Text)
-> (ActivityResponse -> Text -> ActivityResponse)
-> Lens ActivityResponse ActivityResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActivityResponse' {Text
applicationId :: Text
$sel:applicationId:ActivityResponse' :: ActivityResponse -> Text
applicationId} -> Text
applicationId) (\s :: ActivityResponse
s@ActivityResponse' {} Text
a -> ActivityResponse
s {$sel:applicationId:ActivityResponse' :: Text
applicationId = Text
a} :: ActivityResponse)
instance Core.FromJSON ActivityResponse where
parseJSON :: Value -> Parser ActivityResponse
parseJSON =
String
-> (Object -> Parser ActivityResponse)
-> Value
-> Parser ActivityResponse
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ActivityResponse"
( \Object
x ->
Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse
ActivityResponse'
(Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
forall (f :: * -> *) a b. Functor 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
"State")
Parser
(Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
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
"Start")
Parser
(Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Int)
-> Parser
(Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TimezonesCompletedCount")
Parser
(Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Int)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TimezonesTotalCount")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
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
"Result")
Parser
(Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
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
"TreatmentId")
Parser
(Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Int)
-> Parser
(Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"SuccessfulEndpointCount")
Parser
(Maybe Text
-> Maybe Int
-> Maybe Text
-> Text
-> Text
-> Text
-> ActivityResponse)
-> Parser (Maybe Text)
-> Parser
(Maybe Int
-> Maybe Text -> Text -> Text -> Text -> ActivityResponse)
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
"End")
Parser
(Maybe Int
-> Maybe Text -> Text -> Text -> Text -> ActivityResponse)
-> Parser (Maybe Int)
-> Parser (Maybe Text -> Text -> Text -> Text -> ActivityResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TotalEndpointCount")
Parser (Maybe Text -> Text -> Text -> Text -> ActivityResponse)
-> Parser (Maybe Text)
-> Parser (Text -> Text -> Text -> ActivityResponse)
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
"ScheduledStart")
Parser (Text -> Text -> Text -> ActivityResponse)
-> Parser Text -> Parser (Text -> Text -> ActivityResponse)
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
"CampaignId")
Parser (Text -> Text -> ActivityResponse)
-> Parser Text -> Parser (Text -> ActivityResponse)
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
"Id")
Parser (Text -> ActivityResponse)
-> Parser Text -> Parser ActivityResponse
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
"ApplicationId")
)
instance Prelude.Hashable ActivityResponse
instance Prelude.NFData ActivityResponse