module TD.Query.GetEmojiSuggestionsUrl
(GetEmojiSuggestionsUrl(..)
) where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as AT
import qualified TD.Lib.Internal as I
import qualified Data.Text as T
data GetEmojiSuggestionsUrl
= GetEmojiSuggestionsUrl
{ GetEmojiSuggestionsUrl -> Maybe Text
language_code :: Maybe T.Text
}
deriving (GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool
(GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool)
-> (GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool)
-> Eq GetEmojiSuggestionsUrl
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool
== :: GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool
$c/= :: GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool
/= :: GetEmojiSuggestionsUrl -> GetEmojiSuggestionsUrl -> Bool
Eq, Int -> GetEmojiSuggestionsUrl -> ShowS
[GetEmojiSuggestionsUrl] -> ShowS
GetEmojiSuggestionsUrl -> String
(Int -> GetEmojiSuggestionsUrl -> ShowS)
-> (GetEmojiSuggestionsUrl -> String)
-> ([GetEmojiSuggestionsUrl] -> ShowS)
-> Show GetEmojiSuggestionsUrl
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> GetEmojiSuggestionsUrl -> ShowS
showsPrec :: Int -> GetEmojiSuggestionsUrl -> ShowS
$cshow :: GetEmojiSuggestionsUrl -> String
show :: GetEmojiSuggestionsUrl -> String
$cshowList :: [GetEmojiSuggestionsUrl] -> ShowS
showList :: [GetEmojiSuggestionsUrl] -> ShowS
Show)
instance I.ShortShow GetEmojiSuggestionsUrl where
shortShow :: GetEmojiSuggestionsUrl -> String
shortShow
GetEmojiSuggestionsUrl
{ language_code :: GetEmojiSuggestionsUrl -> Maybe Text
language_code = Maybe Text
language_code_
}
= String
"GetEmojiSuggestionsUrl"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"language_code" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
language_code_
]
instance AT.ToJSON GetEmojiSuggestionsUrl where
toJSON :: GetEmojiSuggestionsUrl -> Value
toJSON
GetEmojiSuggestionsUrl
{ language_code :: GetEmojiSuggestionsUrl -> Maybe Text
language_code = Maybe Text
language_code_
}
= [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
"getEmojiSuggestionsUrl"
, Key
"language_code" Key -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Maybe Text
language_code_
]