{-# LANGUAGE DeriveGeneric #-}
module Telegram.Bot.API.Types.CallbackGame where

import Data.Aeson (FromJSON (..), ToJSON (..), Object)
import GHC.Generics (Generic)

import Telegram.Bot.API.Internal.Utils

-- ** 'CallbackGame'

-- | A placeholder, currently holds no information. Use BotFather to set up your game.
newtype CallbackGame = CallbackGame Object
  deriving (forall x. Rep CallbackGame x -> CallbackGame
forall x. CallbackGame -> Rep CallbackGame x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CallbackGame x -> CallbackGame
$cfrom :: forall x. CallbackGame -> Rep CallbackGame x
Generic, Int -> CallbackGame -> ShowS
[CallbackGame] -> ShowS
CallbackGame -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CallbackGame] -> ShowS
$cshowList :: [CallbackGame] -> ShowS
show :: CallbackGame -> String
$cshow :: CallbackGame -> String
showsPrec :: Int -> CallbackGame -> ShowS
$cshowsPrec :: Int -> CallbackGame -> ShowS
Show)

instance ToJSON   CallbackGame where toJSON :: CallbackGame -> Value
toJSON = forall a (d :: Meta) (f :: * -> *).
(Generic a, GToJSON Zero (Rep a), Rep a ~ D1 d f, Datatype d) =>
a -> Value
gtoJSON
instance FromJSON CallbackGame where parseJSON :: Value -> Parser CallbackGame
parseJSON = forall a (d :: Meta) (f :: * -> *).
(Generic a, GFromJSON Zero (Rep a), Rep a ~ D1 d f, Datatype d) =>
Value -> Parser a
gparseJSON