Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module contains data objects which represents requests to Telegram Bot API
- data SendMessageRequest = SendMessageRequest {}
- data ForwardMessageRequest = ForwardMessageRequest {}
- data FileUpload = FileUpload {}
- data FileUploadContent
- data SendPhotoRequest payload = SendPhotoRequest {}
- data SendAudioRequest payload = SendAudioRequest {}
- data SendDocumentRequest payload = SendDocumentRequest {}
- data SendStickerRequest payload = SendStickerRequest {}
- data SendVideoRequest payload = SendVideoRequest {}
- data SendVoiceRequest payload = SendVoiceRequest {}
- data SendLocationRequest = SendLocationRequest {}
- data SendVenueRequest = SendVenueRequest {}
- data SendContactRequest = SendContactRequest {}
- data SendChatActionRequest = SendChatActionRequest {}
- data ChatAction
- data AnswerInlineQueryRequest = AnswerInlineQueryRequest {}
- data AnswerCallbackQueryRequest = AnswerCallbackQueryRequest {}
- data ReplyKeyboard
- = ReplyKeyboardMarkup { }
- | ReplyKeyboardHide { }
- | ForceReply { }
- data EditMessageTextRequest = EditMessageTextRequest {}
- data EditMessageCaptionRequest = EditMessageCaptionRequest {}
- data EditMessageReplyMarkupRequest = EditMessageReplyMarkupRequest {}
- localFileUpload :: FilePath -> FileUpload
- sendMessageRequest :: Text -> Text -> SendMessageRequest
- forwardMessageRequest :: Text -> Text -> Int -> ForwardMessageRequest
- sendPhotoRequest :: Text -> Text -> SendPhotoRequest Text
- uploadPhotoRequest :: Text -> FileUpload -> SendPhotoRequest FileUpload
- sendAudioRequest :: Text -> Text -> SendAudioRequest Text
- uploadAudioRequest :: Text -> FileUpload -> SendAudioRequest FileUpload
- sendDocumentRequest :: Text -> Text -> SendDocumentRequest Text
- uploadDocumentRequest :: Text -> FileUpload -> SendDocumentRequest FileUpload
- sendStickerRequest :: Text -> Text -> SendStickerRequest Text
- uploadStickerRequest :: Text -> FileUpload -> SendStickerRequest FileUpload
- sendVideoRequest :: Text -> Text -> SendVideoRequest Text
- uploadVideoRequest :: Text -> FileUpload -> SendVideoRequest FileUpload
- sendVoiceRequest :: Text -> Text -> SendVoiceRequest Text
- uploadVoiceRequest :: Text -> FileUpload -> SendVoiceRequest FileUpload
- sendLocationRequest :: Text -> Float -> Float -> SendLocationRequest
- sendVenueRequest :: Text -> Float -> Float -> Text -> Text -> SendVenueRequest
- sendContactRequest :: Text -> Text -> Text -> SendContactRequest
- sendChatActionRequest :: Text -> ChatAction -> SendChatActionRequest
- answerInlineQueryRequest :: Text -> [InlineQueryResult] -> AnswerInlineQueryRequest
- answerCallbackQueryRequest :: Text -> AnswerCallbackQueryRequest
- replyKeyboardMarkup :: [[KeyboardButton]] -> ReplyKeyboard
- replyKeyboardHide :: ReplyKeyboard
- forceReply :: ReplyKeyboard
- editMessageTextRequest :: Text -> Int -> Text -> EditMessageTextRequest
- editInlineMessageTextRequest :: Text -> Text -> EditMessageTextRequest
- editMessageCaptionRequest :: Text -> Int -> Maybe Text -> EditMessageCaptionRequest
- editInlineMessageCaptionRequest :: Text -> Maybe Text -> EditMessageCaptionRequest
- editMessageReplyMarkupRequest :: Text -> Int -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest
- editInlineMessageReplyMarkupRequest :: Text -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest
Types
data SendMessageRequest Source
This object represents request for sendMessage
SendMessageRequest | |
|
data ForwardMessageRequest Source
This object represents request for forwardMessage
ForwardMessageRequest | |
|
data FileUpload Source
This object represents data (image, video, ...) with mime type to upload.
FileUpload | |
|
data FileUploadContent Source
This object represents data (image, video, ...) to upload.
data SendPhotoRequest payload Source
This object represents request for sendPhoto
SendPhotoRequest | |
|
Show payload => Show (SendPhotoRequest payload) Source | |
Generic (SendPhotoRequest payload) Source | |
ToJSON (SendPhotoRequest Text) Source | |
FromJSON (SendPhotoRequest Text) Source | |
type Rep (SendPhotoRequest payload) Source |
data SendAudioRequest payload Source
This object represents request for sendAudio
SendAudioRequest | |
|
Show payload => Show (SendAudioRequest payload) Source | |
Generic (SendAudioRequest payload) Source | |
ToJSON (SendAudioRequest Text) Source | |
FromJSON (SendAudioRequest Text) Source | |
type Rep (SendAudioRequest payload) Source |
data SendDocumentRequest payload Source
This object represents request for sendDocument
SendDocumentRequest | |
|
Show payload => Show (SendDocumentRequest payload) Source | |
Generic (SendDocumentRequest payload) Source | |
ToJSON (SendDocumentRequest Text) Source | |
FromJSON (SendDocumentRequest Text) Source | |
type Rep (SendDocumentRequest payload) Source |
data SendStickerRequest payload Source
This object represents request for sendSticker
SendStickerRequest | |
|
Show payload => Show (SendStickerRequest payload) Source | |
Generic (SendStickerRequest payload) Source | |
ToJSON (SendStickerRequest Text) Source | |
FromJSON (SendStickerRequest Text) Source | |
type Rep (SendStickerRequest payload) Source |
data SendVideoRequest payload Source
This object represents request for sendVideo
SendVideoRequest | |
|
Show payload => Show (SendVideoRequest payload) Source | |
Generic (SendVideoRequest payload) Source | |
ToJSON (SendVideoRequest Text) Source | |
FromJSON (SendVideoRequest Text) Source | |
type Rep (SendVideoRequest payload) Source |
data SendVoiceRequest payload Source
This object represents request for sendVoice
SendVoiceRequest | |
|
Show payload => Show (SendVoiceRequest payload) Source | |
Generic (SendVoiceRequest payload) Source | |
ToJSON (SendVoiceRequest Text) Source | |
FromJSON (SendVoiceRequest Text) Source | |
type Rep (SendVoiceRequest payload) Source |
data SendLocationRequest Source
This object represents request for sendLocation
SendLocationRequest | |
|
data SendVenueRequest Source
This object represents request for sendVenue
SendVenueRequest | |
|
data SendContactRequest Source
This object represents request for sendContact
SendContactRequest | |
|
data SendChatActionRequest Source
This object represents request for sendChatAction
SendChatActionRequest | |
|
data ChatAction Source
Type of action to broadcast.
data AnswerInlineQueryRequest Source
AnswerInlineQueryRequest | |
|
data AnswerCallbackQueryRequest Source
AnswerCallbackQueryRequest | |
|
data ReplyKeyboard Source
ReplyKeyboardMarkup | This object represents a custom keyboard with reply options |
| |
ReplyKeyboardHide | Upon receiving a message with this object, Telegram clients will hide the current custom keyboard and display the default letter-keyboard. By default, custom keyboards are displayed until a new keyboard is sent by a bot. An exception is made for one-time keyboards that are hidden immediately after the user presses a button |
| |
ForceReply | Upon receiving a message with this object, Telegram clients will display a reply interface to the user (act as if the user has selected the bot‘s message and tapped ’Reply'). This can be extremely useful if you want to create user-friendly step-by-step interfaces without having to sacrifice privacy mode. |
|
data EditMessageTextRequest Source
EditMessageTextRequest | |
|
data EditMessageCaptionRequest Source
EditMessageCaptionRequest | |
|
data EditMessageReplyMarkupRequest Source
EditMessageReplyMarkupRequest | |
|
Functions
sendMessageRequest :: Text -> Text -> SendMessageRequest Source
forwardMessageRequest :: Text -> Text -> Int -> ForwardMessageRequest Source
sendPhotoRequest :: Text -> Text -> SendPhotoRequest Text Source
sendAudioRequest :: Text -> Text -> SendAudioRequest Text Source
sendDocumentRequest :: Text -> Text -> SendDocumentRequest Text Source
sendStickerRequest :: Text -> Text -> SendStickerRequest Text Source
sendVideoRequest :: Text -> Text -> SendVideoRequest Text Source
sendVoiceRequest :: Text -> Text -> SendVoiceRequest Text Source
sendLocationRequest :: Text -> Float -> Float -> SendLocationRequest Source
sendVenueRequest :: Text -> Float -> Float -> Text -> Text -> SendVenueRequest Source
sendContactRequest :: Text -> Text -> Text -> SendContactRequest Source
replyKeyboardMarkup :: [[KeyboardButton]] -> ReplyKeyboard Source
editMessageTextRequest :: Text -> Int -> Text -> EditMessageTextRequest Source
editMessageCaptionRequest :: Text -> Int -> Maybe Text -> EditMessageCaptionRequest Source