packages feed

telegram-bot-api-6.7.1 / src / Telegram / Bot / API / Methods / GetMyShortDescription.hs

{-# LANGUAGE DataKinds #-}{-# LANGUAGE DeriveGeneric #-}{-# LANGUAGE TypeApplications #-}{-# LANGUAGE TypeOperators #-}module Telegram.Bot.API.Methods.GetMyShortDescription whereimport Data.Aeson (FromJSON (..), ToJSON (..))import Data.Proxyimport GHC.Generics (Generic)import Data.Text (Text)import Servant.APIimport Servant.Client hiding (Response)import Telegram.Bot.API.Internal.Utilsimport Telegram.Bot.API.MakingRequestsimport Telegram.Bot.API.Typesimport Telegram.Bot.API.Internal.TH-- ** 'GetMyShortDescription'newtype GetMyShortDescriptionRequest = GetMyShortDescriptionRequest  { getMyShortDescriptionLanguageCode :: Maybe Text -- ^ A two-letter ISO 639-1 language code or an empty string.  }  deriving Genericinstance ToJSON   GetMyShortDescriptionRequest where toJSON = gtoJSONinstance FromJSON GetMyShortDescriptionRequest where parseJSON = gparseJSONtype GetMyShortDescription = "getMyShortDescription"  :> ReqBody '[JSON] GetMyShortDescriptionRequest  :> Post '[JSON] (Response BotShortDescription)-- | Use this method to get the current bot short description for the given user language.--   Returns 'BotShortDescription' on success.getMyShortDescription :: GetMyShortDescriptionRequest -> ClientM (Response BotShortDescription)getMyShortDescription = client (Proxy @GetMyShortDescription)makeDefault ''GetMyShortDescriptionRequest