{-# 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.CustomerProfiles.Types.Profile where
import qualified Amazonka.Core as Core
import Amazonka.CustomerProfiles.Types.Address
import Amazonka.CustomerProfiles.Types.Gender
import Amazonka.CustomerProfiles.Types.PartyType
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data Profile = Profile'
{
Profile -> Maybe Address
shippingAddress :: Prelude.Maybe Address,
Profile -> Maybe Text
mobilePhoneNumber :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Address
mailingAddress :: Prelude.Maybe Address,
Profile -> Maybe Text
middleName :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
personalEmailAddress :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
lastName :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
additionalInformation :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
homePhoneNumber :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Address
address :: Prelude.Maybe Address,
Profile -> Maybe PartyType
partyType :: Prelude.Maybe PartyType,
Profile -> Maybe Text
profileId :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
businessEmailAddress :: Prelude.Maybe Prelude.Text,
Profile -> Maybe (HashMap Text Text)
attributes :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
Profile -> Maybe Gender
gender :: Prelude.Maybe Gender,
Profile -> Maybe Text
phoneNumber :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
accountNumber :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
emailAddress :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
firstName :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Address
billingAddress :: Prelude.Maybe Address,
Profile -> Maybe Text
businessPhoneNumber :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
birthDate :: Prelude.Maybe Prelude.Text,
Profile -> Maybe Text
businessName :: Prelude.Maybe Prelude.Text
}
deriving (Profile -> Profile -> Bool
(Profile -> Profile -> Bool)
-> (Profile -> Profile -> Bool) -> Eq Profile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Profile -> Profile -> Bool
$c/= :: Profile -> Profile -> Bool
== :: Profile -> Profile -> Bool
$c== :: Profile -> Profile -> Bool
Prelude.Eq, ReadPrec [Profile]
ReadPrec Profile
Int -> ReadS Profile
ReadS [Profile]
(Int -> ReadS Profile)
-> ReadS [Profile]
-> ReadPrec Profile
-> ReadPrec [Profile]
-> Read Profile
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Profile]
$creadListPrec :: ReadPrec [Profile]
readPrec :: ReadPrec Profile
$creadPrec :: ReadPrec Profile
readList :: ReadS [Profile]
$creadList :: ReadS [Profile]
readsPrec :: Int -> ReadS Profile
$creadsPrec :: Int -> ReadS Profile
Prelude.Read, Int -> Profile -> ShowS
[Profile] -> ShowS
Profile -> String
(Int -> Profile -> ShowS)
-> (Profile -> String) -> ([Profile] -> ShowS) -> Show Profile
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Profile] -> ShowS
$cshowList :: [Profile] -> ShowS
show :: Profile -> String
$cshow :: Profile -> String
showsPrec :: Int -> Profile -> ShowS
$cshowsPrec :: Int -> Profile -> ShowS
Prelude.Show, (forall x. Profile -> Rep Profile x)
-> (forall x. Rep Profile x -> Profile) -> Generic Profile
forall x. Rep Profile x -> Profile
forall x. Profile -> Rep Profile x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Profile x -> Profile
$cfrom :: forall x. Profile -> Rep Profile x
Prelude.Generic)
newProfile ::
Profile
newProfile :: Profile
newProfile =
Profile' :: Maybe Address
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile
Profile'
{ $sel:shippingAddress:Profile' :: Maybe Address
shippingAddress = Maybe Address
forall a. Maybe a
Prelude.Nothing,
$sel:mobilePhoneNumber:Profile' :: Maybe Text
mobilePhoneNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:mailingAddress:Profile' :: Maybe Address
mailingAddress = Maybe Address
forall a. Maybe a
Prelude.Nothing,
$sel:middleName:Profile' :: Maybe Text
middleName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:personalEmailAddress:Profile' :: Maybe Text
personalEmailAddress = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lastName:Profile' :: Maybe Text
lastName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:additionalInformation:Profile' :: Maybe Text
additionalInformation = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:homePhoneNumber:Profile' :: Maybe Text
homePhoneNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:address:Profile' :: Maybe Address
address = Maybe Address
forall a. Maybe a
Prelude.Nothing,
$sel:partyType:Profile' :: Maybe PartyType
partyType = Maybe PartyType
forall a. Maybe a
Prelude.Nothing,
$sel:profileId:Profile' :: Maybe Text
profileId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:businessEmailAddress:Profile' :: Maybe Text
businessEmailAddress = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:attributes:Profile' :: Maybe (HashMap Text Text)
attributes = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:gender:Profile' :: Maybe Gender
gender = Maybe Gender
forall a. Maybe a
Prelude.Nothing,
$sel:phoneNumber:Profile' :: Maybe Text
phoneNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:accountNumber:Profile' :: Maybe Text
accountNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:emailAddress:Profile' :: Maybe Text
emailAddress = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:firstName:Profile' :: Maybe Text
firstName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:billingAddress:Profile' :: Maybe Address
billingAddress = Maybe Address
forall a. Maybe a
Prelude.Nothing,
$sel:businessPhoneNumber:Profile' :: Maybe Text
businessPhoneNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:birthDate:Profile' :: Maybe Text
birthDate = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:businessName:Profile' :: Maybe Text
businessName = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
profile_shippingAddress :: Lens.Lens' Profile (Prelude.Maybe Address)
profile_shippingAddress :: (Maybe Address -> f (Maybe Address)) -> Profile -> f Profile
profile_shippingAddress = (Profile -> Maybe Address)
-> (Profile -> Maybe Address -> Profile)
-> Lens Profile Profile (Maybe Address) (Maybe Address)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Address
shippingAddress :: Maybe Address
$sel:shippingAddress:Profile' :: Profile -> Maybe Address
shippingAddress} -> Maybe Address
shippingAddress) (\s :: Profile
s@Profile' {} Maybe Address
a -> Profile
s {$sel:shippingAddress:Profile' :: Maybe Address
shippingAddress = Maybe Address
a} :: Profile)
profile_mobilePhoneNumber :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_mobilePhoneNumber :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_mobilePhoneNumber = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
mobilePhoneNumber :: Maybe Text
$sel:mobilePhoneNumber:Profile' :: Profile -> Maybe Text
mobilePhoneNumber} -> Maybe Text
mobilePhoneNumber) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:mobilePhoneNumber:Profile' :: Maybe Text
mobilePhoneNumber = Maybe Text
a} :: Profile)
profile_mailingAddress :: Lens.Lens' Profile (Prelude.Maybe Address)
profile_mailingAddress :: (Maybe Address -> f (Maybe Address)) -> Profile -> f Profile
profile_mailingAddress = (Profile -> Maybe Address)
-> (Profile -> Maybe Address -> Profile)
-> Lens Profile Profile (Maybe Address) (Maybe Address)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Address
mailingAddress :: Maybe Address
$sel:mailingAddress:Profile' :: Profile -> Maybe Address
mailingAddress} -> Maybe Address
mailingAddress) (\s :: Profile
s@Profile' {} Maybe Address
a -> Profile
s {$sel:mailingAddress:Profile' :: Maybe Address
mailingAddress = Maybe Address
a} :: Profile)
profile_middleName :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_middleName :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_middleName = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
middleName :: Maybe Text
$sel:middleName:Profile' :: Profile -> Maybe Text
middleName} -> Maybe Text
middleName) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:middleName:Profile' :: Maybe Text
middleName = Maybe Text
a} :: Profile)
profile_personalEmailAddress :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_personalEmailAddress :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_personalEmailAddress = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
personalEmailAddress :: Maybe Text
$sel:personalEmailAddress:Profile' :: Profile -> Maybe Text
personalEmailAddress} -> Maybe Text
personalEmailAddress) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:personalEmailAddress:Profile' :: Maybe Text
personalEmailAddress = Maybe Text
a} :: Profile)
profile_lastName :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_lastName :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_lastName = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
lastName :: Maybe Text
$sel:lastName:Profile' :: Profile -> Maybe Text
lastName} -> Maybe Text
lastName) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:lastName:Profile' :: Maybe Text
lastName = Maybe Text
a} :: Profile)
profile_additionalInformation :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_additionalInformation :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_additionalInformation = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
additionalInformation :: Maybe Text
$sel:additionalInformation:Profile' :: Profile -> Maybe Text
additionalInformation} -> Maybe Text
additionalInformation) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:additionalInformation:Profile' :: Maybe Text
additionalInformation = Maybe Text
a} :: Profile)
profile_homePhoneNumber :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_homePhoneNumber :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_homePhoneNumber = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
homePhoneNumber :: Maybe Text
$sel:homePhoneNumber:Profile' :: Profile -> Maybe Text
homePhoneNumber} -> Maybe Text
homePhoneNumber) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:homePhoneNumber:Profile' :: Maybe Text
homePhoneNumber = Maybe Text
a} :: Profile)
profile_address :: Lens.Lens' Profile (Prelude.Maybe Address)
profile_address :: (Maybe Address -> f (Maybe Address)) -> Profile -> f Profile
profile_address = (Profile -> Maybe Address)
-> (Profile -> Maybe Address -> Profile)
-> Lens Profile Profile (Maybe Address) (Maybe Address)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Address
address :: Maybe Address
$sel:address:Profile' :: Profile -> Maybe Address
address} -> Maybe Address
address) (\s :: Profile
s@Profile' {} Maybe Address
a -> Profile
s {$sel:address:Profile' :: Maybe Address
address = Maybe Address
a} :: Profile)
profile_partyType :: Lens.Lens' Profile (Prelude.Maybe PartyType)
profile_partyType :: (Maybe PartyType -> f (Maybe PartyType)) -> Profile -> f Profile
profile_partyType = (Profile -> Maybe PartyType)
-> (Profile -> Maybe PartyType -> Profile)
-> Lens Profile Profile (Maybe PartyType) (Maybe PartyType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe PartyType
partyType :: Maybe PartyType
$sel:partyType:Profile' :: Profile -> Maybe PartyType
partyType} -> Maybe PartyType
partyType) (\s :: Profile
s@Profile' {} Maybe PartyType
a -> Profile
s {$sel:partyType:Profile' :: Maybe PartyType
partyType = Maybe PartyType
a} :: Profile)
profile_profileId :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_profileId :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_profileId = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
profileId :: Maybe Text
$sel:profileId:Profile' :: Profile -> Maybe Text
profileId} -> Maybe Text
profileId) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:profileId:Profile' :: Maybe Text
profileId = Maybe Text
a} :: Profile)
profile_businessEmailAddress :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_businessEmailAddress :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_businessEmailAddress = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
businessEmailAddress :: Maybe Text
$sel:businessEmailAddress:Profile' :: Profile -> Maybe Text
businessEmailAddress} -> Maybe Text
businessEmailAddress) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:businessEmailAddress:Profile' :: Maybe Text
businessEmailAddress = Maybe Text
a} :: Profile)
profile_attributes :: Lens.Lens' Profile (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
profile_attributes :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Profile -> f Profile
profile_attributes = (Profile -> Maybe (HashMap Text Text))
-> (Profile -> Maybe (HashMap Text Text) -> Profile)
-> Lens
Profile
Profile
(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 (\Profile' {Maybe (HashMap Text Text)
attributes :: Maybe (HashMap Text Text)
$sel:attributes:Profile' :: Profile -> Maybe (HashMap Text Text)
attributes} -> Maybe (HashMap Text Text)
attributes) (\s :: Profile
s@Profile' {} Maybe (HashMap Text Text)
a -> Profile
s {$sel:attributes:Profile' :: Maybe (HashMap Text Text)
attributes = Maybe (HashMap Text Text)
a} :: Profile) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Profile -> f Profile)
-> ((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)))
-> Profile
-> f Profile
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
profile_gender :: Lens.Lens' Profile (Prelude.Maybe Gender)
profile_gender :: (Maybe Gender -> f (Maybe Gender)) -> Profile -> f Profile
profile_gender = (Profile -> Maybe Gender)
-> (Profile -> Maybe Gender -> Profile)
-> Lens Profile Profile (Maybe Gender) (Maybe Gender)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Gender
gender :: Maybe Gender
$sel:gender:Profile' :: Profile -> Maybe Gender
gender} -> Maybe Gender
gender) (\s :: Profile
s@Profile' {} Maybe Gender
a -> Profile
s {$sel:gender:Profile' :: Maybe Gender
gender = Maybe Gender
a} :: Profile)
profile_phoneNumber :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_phoneNumber :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_phoneNumber = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
phoneNumber :: Maybe Text
$sel:phoneNumber:Profile' :: Profile -> Maybe Text
phoneNumber} -> Maybe Text
phoneNumber) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:phoneNumber:Profile' :: Maybe Text
phoneNumber = Maybe Text
a} :: Profile)
profile_accountNumber :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_accountNumber :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_accountNumber = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
accountNumber :: Maybe Text
$sel:accountNumber:Profile' :: Profile -> Maybe Text
accountNumber} -> Maybe Text
accountNumber) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:accountNumber:Profile' :: Maybe Text
accountNumber = Maybe Text
a} :: Profile)
profile_emailAddress :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_emailAddress :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_emailAddress = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
emailAddress :: Maybe Text
$sel:emailAddress:Profile' :: Profile -> Maybe Text
emailAddress} -> Maybe Text
emailAddress) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:emailAddress:Profile' :: Maybe Text
emailAddress = Maybe Text
a} :: Profile)
profile_firstName :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_firstName :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_firstName = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
firstName :: Maybe Text
$sel:firstName:Profile' :: Profile -> Maybe Text
firstName} -> Maybe Text
firstName) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:firstName:Profile' :: Maybe Text
firstName = Maybe Text
a} :: Profile)
profile_billingAddress :: Lens.Lens' Profile (Prelude.Maybe Address)
profile_billingAddress :: (Maybe Address -> f (Maybe Address)) -> Profile -> f Profile
profile_billingAddress = (Profile -> Maybe Address)
-> (Profile -> Maybe Address -> Profile)
-> Lens Profile Profile (Maybe Address) (Maybe Address)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Address
billingAddress :: Maybe Address
$sel:billingAddress:Profile' :: Profile -> Maybe Address
billingAddress} -> Maybe Address
billingAddress) (\s :: Profile
s@Profile' {} Maybe Address
a -> Profile
s {$sel:billingAddress:Profile' :: Maybe Address
billingAddress = Maybe Address
a} :: Profile)
profile_businessPhoneNumber :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_businessPhoneNumber :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_businessPhoneNumber = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
businessPhoneNumber :: Maybe Text
$sel:businessPhoneNumber:Profile' :: Profile -> Maybe Text
businessPhoneNumber} -> Maybe Text
businessPhoneNumber) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:businessPhoneNumber:Profile' :: Maybe Text
businessPhoneNumber = Maybe Text
a} :: Profile)
profile_birthDate :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_birthDate :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_birthDate = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
birthDate :: Maybe Text
$sel:birthDate:Profile' :: Profile -> Maybe Text
birthDate} -> Maybe Text
birthDate) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:birthDate:Profile' :: Maybe Text
birthDate = Maybe Text
a} :: Profile)
profile_businessName :: Lens.Lens' Profile (Prelude.Maybe Prelude.Text)
profile_businessName :: (Maybe Text -> f (Maybe Text)) -> Profile -> f Profile
profile_businessName = (Profile -> Maybe Text)
-> (Profile -> Maybe Text -> Profile)
-> Lens Profile Profile (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Profile' {Maybe Text
businessName :: Maybe Text
$sel:businessName:Profile' :: Profile -> Maybe Text
businessName} -> Maybe Text
businessName) (\s :: Profile
s@Profile' {} Maybe Text
a -> Profile
s {$sel:businessName:Profile' :: Maybe Text
businessName = Maybe Text
a} :: Profile)
instance Core.FromJSON Profile where
parseJSON :: Value -> Parser Profile
parseJSON =
String -> (Object -> Parser Profile) -> Value -> Parser Profile
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"Profile"
( \Object
x ->
Maybe Address
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile
Profile'
(Maybe Address
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Address)
-> Parser
(Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ShippingAddress")
Parser
(Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"MobilePhoneNumber")
Parser
(Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Address)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MailingAddress")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"MiddleName")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"PersonalEmailAddress")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"LastName")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"AdditionalInformation")
Parser
(Maybe Text
-> Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"HomePhoneNumber")
Parser
(Maybe Address
-> Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Address)
-> Parser
(Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Address")
Parser
(Maybe PartyType
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe PartyType)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe PartyType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"PartyType")
Parser
(Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"ProfileId")
Parser
(Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"BusinessEmailAddress")
Parser
(Maybe (HashMap Text Text)
-> Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe (HashMap Text Text))
-> Parser
(Maybe Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"Attributes" 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 Gender
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Gender)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Gender)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Gender")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"PhoneNumber")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"AccountNumber")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
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
"EmailAddress")
Parser
(Maybe Text
-> Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Profile)
-> Parser (Maybe Text)
-> Parser
(Maybe Address
-> Maybe Text -> Maybe Text -> Maybe Text -> Profile)
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
"FirstName")
Parser
(Maybe Address
-> Maybe Text -> Maybe Text -> Maybe Text -> Profile)
-> Parser (Maybe Address)
-> Parser (Maybe Text -> Maybe Text -> Maybe Text -> Profile)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"BillingAddress")
Parser (Maybe Text -> Maybe Text -> Maybe Text -> Profile)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> Profile)
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
"BusinessPhoneNumber")
Parser (Maybe Text -> Maybe Text -> Profile)
-> Parser (Maybe Text) -> Parser (Maybe Text -> Profile)
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
"BirthDate")
Parser (Maybe Text -> Profile)
-> Parser (Maybe Text) -> Parser Profile
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
"BusinessName")
)
instance Prelude.Hashable Profile
instance Prelude.NFData Profile