{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.Pinpoint.Types.EmailChannelResponse
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Pinpoint.Types.EmailChannelResponse where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude

-- | Provides information about the status and settings of the email channel
-- for an application.
--
-- /See:/ 'newEmailChannelResponse' smart constructor.
data EmailChannelResponse = EmailChannelResponse'
  { -- | The unique identifier for the application that the email channel applies
    -- to.
    EmailChannelResponse -> Maybe Text
applicationId :: Prelude.Maybe Prelude.Text,
    -- | The
    -- <https://docs.aws.amazon.com/ses/latest/APIReference/API_ConfigurationSet.html Amazon SES configuration set>
    -- that\'s applied to messages that are sent through the channel.
    EmailChannelResponse -> Maybe Text
configurationSet :: Prelude.Maybe Prelude.Text,
    -- | The date and time, in ISO 8601 format, when the email channel was
    -- enabled.
    EmailChannelResponse -> Maybe Text
creationDate :: Prelude.Maybe Prelude.Text,
    -- | Specifies whether the email channel is enabled for the application.
    EmailChannelResponse -> Maybe Bool
enabled :: Prelude.Maybe Prelude.Bool,
    -- | The verified email address that email is sent from when you send email
    -- through the channel.
    EmailChannelResponse -> Maybe Text
fromAddress :: Prelude.Maybe Prelude.Text,
    -- | (Not used) This property is retained only for backward compatibility.
    EmailChannelResponse -> Maybe Bool
hasCredential :: Prelude.Maybe Prelude.Bool,
    -- | (Deprecated) An identifier for the email channel. This property is
    -- retained only for backward compatibility.
    EmailChannelResponse -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the identity, verified with Amazon
    -- Simple Email Service (Amazon SES), that\'s used when you send email
    -- through the channel.
    EmailChannelResponse -> Maybe Text
identity :: Prelude.Maybe Prelude.Text,
    -- | Specifies whether the email channel is archived.
    EmailChannelResponse -> Maybe Bool
isArchived :: Prelude.Maybe Prelude.Bool,
    -- | The user who last modified the email channel.
    EmailChannelResponse -> Maybe Text
lastModifiedBy :: Prelude.Maybe Prelude.Text,
    -- | The date and time, in ISO 8601 format, when the email channel was last
    -- modified.
    EmailChannelResponse -> Maybe Text
lastModifiedDate :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of emails that can be sent through the channel each
    -- second.
    EmailChannelResponse -> Maybe Int
messagesPerSecond :: Prelude.Maybe Prelude.Int,
    -- | The ARN of the AWS Identity and Access Management (IAM) role that Amazon
    -- Pinpoint uses to submit email-related event data for the channel.
    EmailChannelResponse -> Maybe Text
roleArn :: Prelude.Maybe Prelude.Text,
    -- | The current version of the email channel.
    EmailChannelResponse -> Maybe Int
version :: Prelude.Maybe Prelude.Int,
    -- | The type of messaging or notification platform for the channel. For the
    -- email channel, this value is EMAIL.
    EmailChannelResponse -> Text
platform :: Prelude.Text
  }
  deriving (EmailChannelResponse -> EmailChannelResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EmailChannelResponse -> EmailChannelResponse -> Bool
$c/= :: EmailChannelResponse -> EmailChannelResponse -> Bool
== :: EmailChannelResponse -> EmailChannelResponse -> Bool
$c== :: EmailChannelResponse -> EmailChannelResponse -> Bool
Prelude.Eq, ReadPrec [EmailChannelResponse]
ReadPrec EmailChannelResponse
Int -> ReadS EmailChannelResponse
ReadS [EmailChannelResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EmailChannelResponse]
$creadListPrec :: ReadPrec [EmailChannelResponse]
readPrec :: ReadPrec EmailChannelResponse
$creadPrec :: ReadPrec EmailChannelResponse
readList :: ReadS [EmailChannelResponse]
$creadList :: ReadS [EmailChannelResponse]
readsPrec :: Int -> ReadS EmailChannelResponse
$creadsPrec :: Int -> ReadS EmailChannelResponse
Prelude.Read, Int -> EmailChannelResponse -> ShowS
[EmailChannelResponse] -> ShowS
EmailChannelResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EmailChannelResponse] -> ShowS
$cshowList :: [EmailChannelResponse] -> ShowS
show :: EmailChannelResponse -> String
$cshow :: EmailChannelResponse -> String
showsPrec :: Int -> EmailChannelResponse -> ShowS
$cshowsPrec :: Int -> EmailChannelResponse -> ShowS
Prelude.Show, forall x. Rep EmailChannelResponse x -> EmailChannelResponse
forall x. EmailChannelResponse -> Rep EmailChannelResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep EmailChannelResponse x -> EmailChannelResponse
$cfrom :: forall x. EmailChannelResponse -> Rep EmailChannelResponse x
Prelude.Generic)

-- |
-- Create a value of 'EmailChannelResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'applicationId', 'emailChannelResponse_applicationId' - The unique identifier for the application that the email channel applies
-- to.
--
-- 'configurationSet', 'emailChannelResponse_configurationSet' - The
-- <https://docs.aws.amazon.com/ses/latest/APIReference/API_ConfigurationSet.html Amazon SES configuration set>
-- that\'s applied to messages that are sent through the channel.
--
-- 'creationDate', 'emailChannelResponse_creationDate' - The date and time, in ISO 8601 format, when the email channel was
-- enabled.
--
-- 'enabled', 'emailChannelResponse_enabled' - Specifies whether the email channel is enabled for the application.
--
-- 'fromAddress', 'emailChannelResponse_fromAddress' - The verified email address that email is sent from when you send email
-- through the channel.
--
-- 'hasCredential', 'emailChannelResponse_hasCredential' - (Not used) This property is retained only for backward compatibility.
--
-- 'id', 'emailChannelResponse_id' - (Deprecated) An identifier for the email channel. This property is
-- retained only for backward compatibility.
--
-- 'identity', 'emailChannelResponse_identity' - The Amazon Resource Name (ARN) of the identity, verified with Amazon
-- Simple Email Service (Amazon SES), that\'s used when you send email
-- through the channel.
--
-- 'isArchived', 'emailChannelResponse_isArchived' - Specifies whether the email channel is archived.
--
-- 'lastModifiedBy', 'emailChannelResponse_lastModifiedBy' - The user who last modified the email channel.
--
-- 'lastModifiedDate', 'emailChannelResponse_lastModifiedDate' - The date and time, in ISO 8601 format, when the email channel was last
-- modified.
--
-- 'messagesPerSecond', 'emailChannelResponse_messagesPerSecond' - The maximum number of emails that can be sent through the channel each
-- second.
--
-- 'roleArn', 'emailChannelResponse_roleArn' - The ARN of the AWS Identity and Access Management (IAM) role that Amazon
-- Pinpoint uses to submit email-related event data for the channel.
--
-- 'version', 'emailChannelResponse_version' - The current version of the email channel.
--
-- 'platform', 'emailChannelResponse_platform' - The type of messaging or notification platform for the channel. For the
-- email channel, this value is EMAIL.
newEmailChannelResponse ::
  -- | 'platform'
  Prelude.Text ->
  EmailChannelResponse
newEmailChannelResponse :: Text -> EmailChannelResponse
newEmailChannelResponse Text
pPlatform_ =
  EmailChannelResponse'
    { $sel:applicationId:EmailChannelResponse' :: Maybe Text
applicationId =
        forall a. Maybe a
Prelude.Nothing,
      $sel:configurationSet:EmailChannelResponse' :: Maybe Text
configurationSet = forall a. Maybe a
Prelude.Nothing,
      $sel:creationDate:EmailChannelResponse' :: Maybe Text
creationDate = forall a. Maybe a
Prelude.Nothing,
      $sel:enabled:EmailChannelResponse' :: Maybe Bool
enabled = forall a. Maybe a
Prelude.Nothing,
      $sel:fromAddress:EmailChannelResponse' :: Maybe Text
fromAddress = forall a. Maybe a
Prelude.Nothing,
      $sel:hasCredential:EmailChannelResponse' :: Maybe Bool
hasCredential = forall a. Maybe a
Prelude.Nothing,
      $sel:id:EmailChannelResponse' :: Maybe Text
id = forall a. Maybe a
Prelude.Nothing,
      $sel:identity:EmailChannelResponse' :: Maybe Text
identity = forall a. Maybe a
Prelude.Nothing,
      $sel:isArchived:EmailChannelResponse' :: Maybe Bool
isArchived = forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedBy:EmailChannelResponse' :: Maybe Text
lastModifiedBy = forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedDate:EmailChannelResponse' :: Maybe Text
lastModifiedDate = forall a. Maybe a
Prelude.Nothing,
      $sel:messagesPerSecond:EmailChannelResponse' :: Maybe Int
messagesPerSecond = forall a. Maybe a
Prelude.Nothing,
      $sel:roleArn:EmailChannelResponse' :: Maybe Text
roleArn = forall a. Maybe a
Prelude.Nothing,
      $sel:version:EmailChannelResponse' :: Maybe Int
version = forall a. Maybe a
Prelude.Nothing,
      $sel:platform:EmailChannelResponse' :: Text
platform = Text
pPlatform_
    }

-- | The unique identifier for the application that the email channel applies
-- to.
emailChannelResponse_applicationId :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_applicationId :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_applicationId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
applicationId :: Maybe Text
$sel:applicationId:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
applicationId} -> Maybe Text
applicationId) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:applicationId:EmailChannelResponse' :: Maybe Text
applicationId = Maybe Text
a} :: EmailChannelResponse)

-- | The
-- <https://docs.aws.amazon.com/ses/latest/APIReference/API_ConfigurationSet.html Amazon SES configuration set>
-- that\'s applied to messages that are sent through the channel.
emailChannelResponse_configurationSet :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_configurationSet :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_configurationSet = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
configurationSet :: Maybe Text
$sel:configurationSet:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
configurationSet} -> Maybe Text
configurationSet) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:configurationSet:EmailChannelResponse' :: Maybe Text
configurationSet = Maybe Text
a} :: EmailChannelResponse)

-- | The date and time, in ISO 8601 format, when the email channel was
-- enabled.
emailChannelResponse_creationDate :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_creationDate :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_creationDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
creationDate :: Maybe Text
$sel:creationDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
creationDate} -> Maybe Text
creationDate) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:creationDate:EmailChannelResponse' :: Maybe Text
creationDate = Maybe Text
a} :: EmailChannelResponse)

-- | Specifies whether the email channel is enabled for the application.
emailChannelResponse_enabled :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Bool)
emailChannelResponse_enabled :: Lens' EmailChannelResponse (Maybe Bool)
emailChannelResponse_enabled = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Bool
enabled :: Maybe Bool
$sel:enabled:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
enabled} -> Maybe Bool
enabled) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Bool
a -> EmailChannelResponse
s {$sel:enabled:EmailChannelResponse' :: Maybe Bool
enabled = Maybe Bool
a} :: EmailChannelResponse)

-- | The verified email address that email is sent from when you send email
-- through the channel.
emailChannelResponse_fromAddress :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_fromAddress :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_fromAddress = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
fromAddress :: Maybe Text
$sel:fromAddress:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
fromAddress} -> Maybe Text
fromAddress) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:fromAddress:EmailChannelResponse' :: Maybe Text
fromAddress = Maybe Text
a} :: EmailChannelResponse)

-- | (Not used) This property is retained only for backward compatibility.
emailChannelResponse_hasCredential :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Bool)
emailChannelResponse_hasCredential :: Lens' EmailChannelResponse (Maybe Bool)
emailChannelResponse_hasCredential = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Bool
hasCredential :: Maybe Bool
$sel:hasCredential:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
hasCredential} -> Maybe Bool
hasCredential) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Bool
a -> EmailChannelResponse
s {$sel:hasCredential:EmailChannelResponse' :: Maybe Bool
hasCredential = Maybe Bool
a} :: EmailChannelResponse)

-- | (Deprecated) An identifier for the email channel. This property is
-- retained only for backward compatibility.
emailChannelResponse_id :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_id :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_id = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
id :: Maybe Text
$sel:id:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
id} -> Maybe Text
id) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:id:EmailChannelResponse' :: Maybe Text
id = Maybe Text
a} :: EmailChannelResponse)

-- | The Amazon Resource Name (ARN) of the identity, verified with Amazon
-- Simple Email Service (Amazon SES), that\'s used when you send email
-- through the channel.
emailChannelResponse_identity :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_identity :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_identity = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
identity :: Maybe Text
$sel:identity:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
identity} -> Maybe Text
identity) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:identity:EmailChannelResponse' :: Maybe Text
identity = Maybe Text
a} :: EmailChannelResponse)

-- | Specifies whether the email channel is archived.
emailChannelResponse_isArchived :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Bool)
emailChannelResponse_isArchived :: Lens' EmailChannelResponse (Maybe Bool)
emailChannelResponse_isArchived = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Bool
isArchived :: Maybe Bool
$sel:isArchived:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
isArchived} -> Maybe Bool
isArchived) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Bool
a -> EmailChannelResponse
s {$sel:isArchived:EmailChannelResponse' :: Maybe Bool
isArchived = Maybe Bool
a} :: EmailChannelResponse)

-- | The user who last modified the email channel.
emailChannelResponse_lastModifiedBy :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_lastModifiedBy :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_lastModifiedBy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
lastModifiedBy :: Maybe Text
$sel:lastModifiedBy:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
lastModifiedBy} -> Maybe Text
lastModifiedBy) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:lastModifiedBy:EmailChannelResponse' :: Maybe Text
lastModifiedBy = Maybe Text
a} :: EmailChannelResponse)

-- | The date and time, in ISO 8601 format, when the email channel was last
-- modified.
emailChannelResponse_lastModifiedDate :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_lastModifiedDate :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_lastModifiedDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
lastModifiedDate :: Maybe Text
$sel:lastModifiedDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
lastModifiedDate} -> Maybe Text
lastModifiedDate) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:lastModifiedDate:EmailChannelResponse' :: Maybe Text
lastModifiedDate = Maybe Text
a} :: EmailChannelResponse)

-- | The maximum number of emails that can be sent through the channel each
-- second.
emailChannelResponse_messagesPerSecond :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Int)
emailChannelResponse_messagesPerSecond :: Lens' EmailChannelResponse (Maybe Int)
emailChannelResponse_messagesPerSecond = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Int
messagesPerSecond :: Maybe Int
$sel:messagesPerSecond:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
messagesPerSecond} -> Maybe Int
messagesPerSecond) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Int
a -> EmailChannelResponse
s {$sel:messagesPerSecond:EmailChannelResponse' :: Maybe Int
messagesPerSecond = Maybe Int
a} :: EmailChannelResponse)

-- | The ARN of the AWS Identity and Access Management (IAM) role that Amazon
-- Pinpoint uses to submit email-related event data for the channel.
emailChannelResponse_roleArn :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Text)
emailChannelResponse_roleArn :: Lens' EmailChannelResponse (Maybe Text)
emailChannelResponse_roleArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Text
roleArn :: Maybe Text
$sel:roleArn:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
roleArn} -> Maybe Text
roleArn) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Text
a -> EmailChannelResponse
s {$sel:roleArn:EmailChannelResponse' :: Maybe Text
roleArn = Maybe Text
a} :: EmailChannelResponse)

-- | The current version of the email channel.
emailChannelResponse_version :: Lens.Lens' EmailChannelResponse (Prelude.Maybe Prelude.Int)
emailChannelResponse_version :: Lens' EmailChannelResponse (Maybe Int)
emailChannelResponse_version = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Maybe Int
version :: Maybe Int
$sel:version:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
version} -> Maybe Int
version) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Maybe Int
a -> EmailChannelResponse
s {$sel:version:EmailChannelResponse' :: Maybe Int
version = Maybe Int
a} :: EmailChannelResponse)

-- | The type of messaging or notification platform for the channel. For the
-- email channel, this value is EMAIL.
emailChannelResponse_platform :: Lens.Lens' EmailChannelResponse Prelude.Text
emailChannelResponse_platform :: Lens' EmailChannelResponse Text
emailChannelResponse_platform = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmailChannelResponse' {Text
platform :: Text
$sel:platform:EmailChannelResponse' :: EmailChannelResponse -> Text
platform} -> Text
platform) (\s :: EmailChannelResponse
s@EmailChannelResponse' {} Text
a -> EmailChannelResponse
s {$sel:platform:EmailChannelResponse' :: Text
platform = Text
a} :: EmailChannelResponse)

instance Data.FromJSON EmailChannelResponse where
  parseJSON :: Value -> Parser EmailChannelResponse
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"EmailChannelResponse"
      ( \Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Text
-> EmailChannelResponse
EmailChannelResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ApplicationId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ConfigurationSet")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"CreationDate")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Enabled")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"FromAddress")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"HasCredential")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Id")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Identity")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"IsArchived")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"LastModifiedBy")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"LastModifiedDate")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"MessagesPerSecond")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"RoleArn")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Version")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Platform")
      )

instance Prelude.Hashable EmailChannelResponse where
  hashWithSalt :: Int -> EmailChannelResponse -> Int
hashWithSalt Int
_salt EmailChannelResponse' {Maybe Bool
Maybe Int
Maybe Text
Text
platform :: Text
version :: Maybe Int
roleArn :: Maybe Text
messagesPerSecond :: Maybe Int
lastModifiedDate :: Maybe Text
lastModifiedBy :: Maybe Text
isArchived :: Maybe Bool
identity :: Maybe Text
id :: Maybe Text
hasCredential :: Maybe Bool
fromAddress :: Maybe Text
enabled :: Maybe Bool
creationDate :: Maybe Text
configurationSet :: Maybe Text
applicationId :: Maybe Text
$sel:platform:EmailChannelResponse' :: EmailChannelResponse -> Text
$sel:version:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
$sel:roleArn:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:messagesPerSecond:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
$sel:lastModifiedDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:lastModifiedBy:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:isArchived:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:identity:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:id:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:hasCredential:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:fromAddress:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:enabled:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:creationDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:configurationSet:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:applicationId:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
applicationId
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
configurationSet
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
creationDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
enabled
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
fromAddress
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
hasCredential
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
id
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
identity
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
isArchived
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lastModifiedBy
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lastModifiedDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
messagesPerSecond
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
roleArn
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
version
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
platform

instance Prelude.NFData EmailChannelResponse where
  rnf :: EmailChannelResponse -> ()
rnf EmailChannelResponse' {Maybe Bool
Maybe Int
Maybe Text
Text
platform :: Text
version :: Maybe Int
roleArn :: Maybe Text
messagesPerSecond :: Maybe Int
lastModifiedDate :: Maybe Text
lastModifiedBy :: Maybe Text
isArchived :: Maybe Bool
identity :: Maybe Text
id :: Maybe Text
hasCredential :: Maybe Bool
fromAddress :: Maybe Text
enabled :: Maybe Bool
creationDate :: Maybe Text
configurationSet :: Maybe Text
applicationId :: Maybe Text
$sel:platform:EmailChannelResponse' :: EmailChannelResponse -> Text
$sel:version:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
$sel:roleArn:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:messagesPerSecond:EmailChannelResponse' :: EmailChannelResponse -> Maybe Int
$sel:lastModifiedDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:lastModifiedBy:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:isArchived:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:identity:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:id:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:hasCredential:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:fromAddress:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:enabled:EmailChannelResponse' :: EmailChannelResponse -> Maybe Bool
$sel:creationDate:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:configurationSet:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
$sel:applicationId:EmailChannelResponse' :: EmailChannelResponse -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
applicationId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
configurationSet
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
creationDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
enabled
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
fromAddress
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
hasCredential
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
id
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
identity
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
isArchived
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lastModifiedBy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lastModifiedDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
messagesPerSecond
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
roleArn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
version
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
platform