module TD.Query.RemoveMessageSenderBotVerification
(RemoveMessageSenderBotVerification(..)
, defaultRemoveMessageSenderBotVerification
) where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as AT
import qualified TD.Lib.Internal as I
import qualified TD.Data.MessageSender as MessageSender
data RemoveMessageSenderBotVerification
= RemoveMessageSenderBotVerification
{ RemoveMessageSenderBotVerification -> Maybe Int
bot_user_id :: Maybe Int
, RemoveMessageSenderBotVerification -> Maybe MessageSender
verified_id :: Maybe MessageSender.MessageSender
}
deriving (RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool
(RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool)
-> (RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool)
-> Eq RemoveMessageSenderBotVerification
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool
== :: RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool
$c/= :: RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool
/= :: RemoveMessageSenderBotVerification
-> RemoveMessageSenderBotVerification -> Bool
Eq, Int -> RemoveMessageSenderBotVerification -> ShowS
[RemoveMessageSenderBotVerification] -> ShowS
RemoveMessageSenderBotVerification -> String
(Int -> RemoveMessageSenderBotVerification -> ShowS)
-> (RemoveMessageSenderBotVerification -> String)
-> ([RemoveMessageSenderBotVerification] -> ShowS)
-> Show RemoveMessageSenderBotVerification
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> RemoveMessageSenderBotVerification -> ShowS
showsPrec :: Int -> RemoveMessageSenderBotVerification -> ShowS
$cshow :: RemoveMessageSenderBotVerification -> String
show :: RemoveMessageSenderBotVerification -> String
$cshowList :: [RemoveMessageSenderBotVerification] -> ShowS
showList :: [RemoveMessageSenderBotVerification] -> ShowS
Show)
instance I.ShortShow RemoveMessageSenderBotVerification where
shortShow :: RemoveMessageSenderBotVerification -> String
shortShow
RemoveMessageSenderBotVerification
{ bot_user_id :: RemoveMessageSenderBotVerification -> Maybe Int
bot_user_id = Maybe Int
bot_user_id_
, verified_id :: RemoveMessageSenderBotVerification -> Maybe MessageSender
verified_id = Maybe MessageSender
verified_id_
}
= String
"RemoveMessageSenderBotVerification"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"bot_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
bot_user_id_
, String
"verified_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
verified_id_
]
instance AT.ToJSON RemoveMessageSenderBotVerification where
toJSON :: RemoveMessageSenderBotVerification -> Value
toJSON
RemoveMessageSenderBotVerification
{ bot_user_id :: RemoveMessageSenderBotVerification -> Maybe Int
bot_user_id = Maybe Int
bot_user_id_
, verified_id :: RemoveMessageSenderBotVerification -> Maybe MessageSender
verified_id = Maybe MessageSender
verified_id_
}
= [Pair] -> Value
A.object
[ Key
"@type" Key -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Text -> Value
AT.String Text
"removeMessageSenderBotVerification"
, Key
"bot_user_id" Key -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Maybe Int
bot_user_id_
, Key
"verified_id" Key -> Maybe MessageSender -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Maybe MessageSender
verified_id_
]
defaultRemoveMessageSenderBotVerification :: RemoveMessageSenderBotVerification
defaultRemoveMessageSenderBotVerification :: RemoveMessageSenderBotVerification
defaultRemoveMessageSenderBotVerification =
RemoveMessageSenderBotVerification
{ bot_user_id :: Maybe Int
bot_user_id = Maybe Int
forall a. Maybe a
Nothing
, verified_id :: Maybe MessageSender
verified_id = Maybe MessageSender
forall a. Maybe a
Nothing
}