module TD.Query.GetStarAdAccountUrl
(GetStarAdAccountUrl(..)
) 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 GetStarAdAccountUrl
= GetStarAdAccountUrl
{ GetStarAdAccountUrl -> Maybe MessageSender
owner_id :: Maybe MessageSender.MessageSender
}
deriving (GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool
(GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool)
-> (GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool)
-> Eq GetStarAdAccountUrl
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool
== :: GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool
$c/= :: GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool
/= :: GetStarAdAccountUrl -> GetStarAdAccountUrl -> Bool
Eq, Int -> GetStarAdAccountUrl -> ShowS
[GetStarAdAccountUrl] -> ShowS
GetStarAdAccountUrl -> String
(Int -> GetStarAdAccountUrl -> ShowS)
-> (GetStarAdAccountUrl -> String)
-> ([GetStarAdAccountUrl] -> ShowS)
-> Show GetStarAdAccountUrl
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> GetStarAdAccountUrl -> ShowS
showsPrec :: Int -> GetStarAdAccountUrl -> ShowS
$cshow :: GetStarAdAccountUrl -> String
show :: GetStarAdAccountUrl -> String
$cshowList :: [GetStarAdAccountUrl] -> ShowS
showList :: [GetStarAdAccountUrl] -> ShowS
Show)
instance I.ShortShow GetStarAdAccountUrl where
shortShow :: GetStarAdAccountUrl -> String
shortShow
GetStarAdAccountUrl
{ owner_id :: GetStarAdAccountUrl -> Maybe MessageSender
owner_id = Maybe MessageSender
owner_id_
}
= String
"GetStarAdAccountUrl"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"owner_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
owner_id_
]
instance AT.ToJSON GetStarAdAccountUrl where
toJSON :: GetStarAdAccountUrl -> Value
toJSON
GetStarAdAccountUrl
{ owner_id :: GetStarAdAccountUrl -> Maybe MessageSender
owner_id = Maybe MessageSender
owner_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
"getStarAdAccountUrl"
, Key
"owner_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
owner_id_
]