Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module contains data objects which represents requests to Telegram Bot API
- data ChatId
- data SendMessageRequest = SendMessageRequest {}
- data ForwardMessageRequest = ForwardMessageRequest {}
- data FileUpload = FileUpload {}
- data FileUploadContent
- data SetWebhookRequest
- data GetUpdatesRequest = GetUpdatesRequest {}
- 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 SendVideoNoteRequest payload = SendVideoNoteRequest {}
- data SendMediaGroupRequest = SendMediaGroupRequest {}
- data SendLocationRequest = SendLocationRequest {}
- data SendVenueRequest = SendVenueRequest {}
- data SendContactRequest = SendContactRequest {}
- data SendChatActionRequest = SendChatActionRequest {}
- data SendGameRequest = SendGameRequest {}
- data ChatAction
- data AnswerInlineQueryRequest = AnswerInlineQueryRequest {}
- data AnswerCallbackQueryRequest = AnswerCallbackQueryRequest {}
- data ReplyKeyboard
- = ReplyInlineKeyboardMarkup { }
- | ReplyKeyboardMarkup { }
- | ReplyKeyboardHide { }
- | ReplyKeyboardRemove { }
- | ForceReply { }
- data EditMessageTextRequest = EditMessageTextRequest {}
- data EditMessageCaptionRequest = EditMessageCaptionRequest {}
- data EditMessageReplyMarkupRequest = EditMessageReplyMarkupRequest {}
- data SendInvoiceRequest = SendInvoiceRequest {
- snd_inv_chat_id :: Int64
- snd_inv_title :: Text
- snd_inv_description :: Text
- snd_inv_payload :: Text
- snd_inv_provider_token :: Text
- snd_inv_start_parameter :: Text
- snd_inv_currency :: CurrencyCode
- snd_inv_prices :: [LabeledPrice]
- snd_inv_provider_data :: Maybe Text
- snd_inv_photo_url :: Maybe Text
- snd_inv_photo_size :: Maybe Int
- snd_inv_photo_width :: Maybe Int
- snd_inv_photo_height :: Maybe Int
- snd_inv_need_name :: Maybe Bool
- snd_inv_need_phone_number :: Maybe Bool
- snd_inv_need_email :: Maybe Bool
- snd_inv_need_shipping_address :: Maybe Bool
- snd_inv_is_flexible :: Maybe Bool
- snd_inv_disable_notification :: Maybe Bool
- snd_inv_reply_to_message :: Maybe Int
- snd_inv_reply_markup :: Maybe InlineKeyboardMarkup
- data AnswerShippingQueryRequest = AnswerShippingQueryRequest {}
- data AnswerPreCheckoutQueryRequest = AnswerPreCheckoutQueryRequest {}
- data RestrictChatMemberRequest = RestrictChatMemberRequest {}
- data PromoteChatMemberRequest = PromoteChatMemberRequest {
- pcmr_chat_id :: ChatId
- pcmr_user_id :: Int
- pcmr_can_change_info :: Maybe Bool
- pcmr_can_post_messages :: Maybe Bool
- pcmr_can_edit_messages :: Maybe Bool
- pcmr_can_delete_messages :: Maybe Bool
- pcmr_can_invite_users :: Maybe Bool
- pcmr_can_restrict_members :: Maybe Bool
- pcmr_can_pin_messages :: Maybe Bool
- pcmr_can_promote_members :: Maybe Bool
- data SetChatPhotoRequest = SetChatPhotoRequest {}
- data UploadStickerFileRequest = UploadStickerFileRequest {}
- data CreateNewStickerSetRequest payload = CreateNewStickerSetRequest {}
- data AddStickerToSetRequest payload = AddStickerToSetRequest {}
- data EditMessageLiveLocationRequest
- data StopMessageLiveLocationRequest
- localFileUpload :: FilePath -> FileUpload
- setWebhookRequest :: Text -> FileUpload -> SetWebhookRequest
- setWebhookRequest' :: Text -> SetWebhookRequest
- getUpdatesRequest :: GetUpdatesRequest
- sendMessageRequest :: ChatId -> Text -> SendMessageRequest
- forwardMessageRequest :: ChatId -> ChatId -> Int -> ForwardMessageRequest
- sendPhotoRequest :: ChatId -> Text -> SendPhotoRequest Text
- uploadPhotoRequest :: ChatId -> FileUpload -> SendPhotoRequest FileUpload
- sendAudioRequest :: ChatId -> Text -> SendAudioRequest Text
- uploadAudioRequest :: ChatId -> FileUpload -> SendAudioRequest FileUpload
- sendDocumentRequest :: ChatId -> Text -> SendDocumentRequest Text
- uploadDocumentRequest :: ChatId -> FileUpload -> SendDocumentRequest FileUpload
- sendStickerRequest :: ChatId -> Text -> SendStickerRequest Text
- uploadStickerRequest :: ChatId -> FileUpload -> SendStickerRequest FileUpload
- sendVideoRequest :: ChatId -> Text -> SendVideoRequest Text
- uploadVideoRequest :: ChatId -> FileUpload -> SendVideoRequest FileUpload
- sendVoiceRequest :: ChatId -> Text -> SendVoiceRequest Text
- uploadVoiceRequest :: ChatId -> FileUpload -> SendVoiceRequest FileUpload
- sendVideoNoteRequest :: ChatId -> Text -> SendVideoNoteRequest Text
- uploadVideoNoteRequest :: ChatId -> FileUpload -> SendVideoNoteRequest FileUpload
- sendMediaGroupRequest :: ChatId -> [InputMedia] -> SendMediaGroupRequest
- sendLocationRequest :: ChatId -> Float -> Float -> SendLocationRequest
- sendVenueRequest :: ChatId -> Float -> Float -> Text -> Text -> SendVenueRequest
- sendContactRequest :: ChatId -> Text -> Text -> SendContactRequest
- sendChatActionRequest :: ChatId -> ChatAction -> SendChatActionRequest
- sendGameRequest :: Integer -> Text -> SendGameRequest
- answerInlineQueryRequest :: Text -> [InlineQueryResult] -> AnswerInlineQueryRequest
- answerCallbackQueryRequest :: Text -> AnswerCallbackQueryRequest
- inlineKeyboardMarkup :: [[InlineKeyboardButton]] -> ReplyKeyboard
- replyKeyboardMarkup :: [[KeyboardButton]] -> ReplyKeyboard
- replyKeyboardHide :: ReplyKeyboard
- forceReply :: ReplyKeyboard
- editMessageTextRequest :: ChatId -> Int -> Text -> EditMessageTextRequest
- editInlineMessageTextRequest :: Text -> Text -> EditMessageTextRequest
- editMessageCaptionRequest :: ChatId -> Int -> Maybe Text -> EditMessageCaptionRequest
- editInlineMessageCaptionRequest :: Text -> Maybe Text -> EditMessageCaptionRequest
- editMessageReplyMarkupRequest :: ChatId -> Int -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest
- editInlineMessageReplyMarkupRequest :: Text -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest
- sendInvoiceRequest :: Int64 -> Text -> Text -> Text -> Text -> Text -> CurrencyCode -> [LabeledPrice] -> SendInvoiceRequest
- okShippingQueryRequest :: Text -> [ShippingOption] -> AnswerShippingQueryRequest
- errorShippingQueryRequest :: Text -> Text -> AnswerShippingQueryRequest
- okAnswerPrecheckoutQueryRequest :: Text -> AnswerPreCheckoutQueryRequest
- errorAnswerPrecheckoutQueryRequest :: Text -> Text -> AnswerPreCheckoutQueryRequest
- restrictChatMemberRequest :: ChatId -> Int -> RestrictChatMemberRequest
- promoteChatMemberRequest :: ChatId -> Int -> PromoteChatMemberRequest
Types
Unique identifier for the target chat or username of the target channel (in the format @channelusername
)
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 SetWebhookRequest Source #
This object represents request for setWebhookWithCertificate
SetWebhookRequest | |
| |
SetWebhookWithoutCertRequest | |
|
data GetUpdatesRequest Source #
GetUpdatesRequest | |
|
data SendPhotoRequest payload Source #
This object represents request for sendPhoto
SendPhotoRequest | |
|
Show payload => Show (SendPhotoRequest payload) Source # | |
Generic (SendPhotoRequest payload) Source # | |
FromJSON (SendPhotoRequest Text) Source # | |
ToJSON (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 # | |
FromJSON (SendAudioRequest Text) Source # | |
ToJSON (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 # | |
FromJSON (SendDocumentRequest Text) Source # | |
ToJSON (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 # | |
FromJSON (SendStickerRequest Text) Source # | |
ToJSON (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 # | |
FromJSON (SendVideoRequest Text) Source # | |
ToJSON (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 # | |
FromJSON (SendVoiceRequest Text) Source # | |
ToJSON (SendVoiceRequest Text) Source # | |
type Rep (SendVoiceRequest payload) Source # | |
data SendVideoNoteRequest payload Source #
SendVideoNoteRequest | |
|
Show payload => Show (SendVideoNoteRequest payload) Source # | |
Generic (SendVideoNoteRequest payload) Source # | |
FromJSON (SendVideoNoteRequest Text) Source # | |
ToJSON (SendVideoNoteRequest Text) Source # | |
type Rep (SendVideoNoteRequest payload) Source # | |
data SendMediaGroupRequest Source #
This object represents request for sendMediaGroup
SendMediaGroupRequest | |
|
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 SendGameRequest Source #
This object represents request for sendGame
SendGameRequest | |
|
data ChatAction Source #
Type of action to broadcast.
data AnswerInlineQueryRequest Source #
AnswerInlineQueryRequest | |
|
data AnswerCallbackQueryRequest Source #
AnswerCallbackQueryRequest | |
|
data ReplyKeyboard Source #
ReplyInlineKeyboardMarkup | This object represents a custom keyboard with reply options |
| |
ReplyKeyboardMarkup | |
| |
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 |
| |
ReplyKeyboardRemove | |
| |
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 | |
|
data SendInvoiceRequest Source #
SendInvoiceRequest | |
|
data AnswerShippingQueryRequest Source #
AnswerShippingQueryRequest | If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the Bot API will send an Update with a shipping_query field to the bot. Use this method to reply to shipping queries. On success, True is returned. |
|
data AnswerPreCheckoutQueryRequest Source #
AnswerPreCheckoutQueryRequest | Once the user has confirmed their payment and shipping details, the Bot API sends the final confirmation in the form of an |
|
data RestrictChatMemberRequest Source #
RestrictChatMemberRequest | |
|
data PromoteChatMemberRequest Source #
PromoteChatMemberRequest | |
|
data UploadStickerFileRequest Source #
UploadStickerFileRequest | |
|
data CreateNewStickerSetRequest payload Source #
CreateNewStickerSetRequest | |
|
Show payload => Show (CreateNewStickerSetRequest payload) Source # | |
Generic (CreateNewStickerSetRequest payload) Source # | |
FromJSON (CreateNewStickerSetRequest Text) Source # | |
ToJSON (CreateNewStickerSetRequest Text) Source # | |
type Rep (CreateNewStickerSetRequest payload) Source # | |
data AddStickerToSetRequest payload Source #
AddStickerToSetRequest | |
|
Show payload => Show (AddStickerToSetRequest payload) Source # | |
Generic (AddStickerToSetRequest payload) Source # | |
FromJSON (AddStickerToSetRequest Text) Source # | |
ToJSON (AddStickerToSetRequest Text) Source # | |
type Rep (AddStickerToSetRequest payload) Source # | |
data EditMessageLiveLocationRequest Source #
EditMessageLiveLocationRequest | |
| |
EditMessageLiveLocationMessageRequest | |
| |
EditMessageLiveLocationInlineMessageRequest | |
|
data StopMessageLiveLocationRequest Source #
StopMessageLiveLocationRequest | |
| |
StopMessageLiveLocationMessageRequest | |
| |
StopMessageLiveLocationInlineMessageRequest | |
|
Functions
localFileUpload :: FilePath -> FileUpload Source #
setWebhookRequest :: Text -> FileUpload -> SetWebhookRequest Source #
sendMessageRequest :: ChatId -> Text -> SendMessageRequest Source #
forwardMessageRequest :: ChatId -> ChatId -> Int -> ForwardMessageRequest Source #
sendPhotoRequest :: ChatId -> Text -> SendPhotoRequest Text Source #
sendAudioRequest :: ChatId -> Text -> SendAudioRequest Text Source #
sendDocumentRequest :: ChatId -> Text -> SendDocumentRequest Text Source #
sendStickerRequest :: ChatId -> Text -> SendStickerRequest Text Source #
sendVideoRequest :: ChatId -> Text -> SendVideoRequest Text Source #
sendVoiceRequest :: ChatId -> Text -> SendVoiceRequest Text Source #
sendLocationRequest :: ChatId -> Float -> Float -> SendLocationRequest Source #
sendVenueRequest :: ChatId -> Float -> Float -> Text -> Text -> SendVenueRequest Source #
sendContactRequest :: ChatId -> Text -> Text -> SendContactRequest Source #
sendGameRequest :: Integer -> Text -> SendGameRequest Source #
replyKeyboardMarkup :: [[KeyboardButton]] -> ReplyKeyboard Source #
editMessageTextRequest :: ChatId -> Int -> Text -> EditMessageTextRequest Source #
editMessageCaptionRequest :: ChatId -> Int -> Maybe Text -> EditMessageCaptionRequest Source #
editMessageReplyMarkupRequest :: ChatId -> Int -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest Source #
editInlineMessageReplyMarkupRequest :: Text -> Maybe InlineKeyboardMarkup -> EditMessageReplyMarkupRequest Source #
:: Int64 | Unique identifier for the target private chat |
-> Text | Product name |
-> Text | Product description |
-> Text | Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes. |
-> Text | Payments provider token, obtained via Botfather |
-> Text | Unique deep-linking parameter that can be used to generate this invoice when used as a start parameter |
-> CurrencyCode | Three-letter ISO 4217 currency code |
-> [LabeledPrice] | Price breakdown, a list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.) |
-> SendInvoiceRequest |