module TD.Data.Update
(Update(..)) 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.AuthorizationState as AuthorizationState
import qualified TD.Data.Message as Message
import qualified TD.Data.Error as Error
import qualified TD.Data.MessageContent as MessageContent
import qualified TD.Data.ReplyMarkup as ReplyMarkup
import qualified TD.Data.MessageInteractionInfo as MessageInteractionInfo
import qualified TD.Data.UnreadReaction as UnreadReaction
import qualified TD.Data.FactCheck as FactCheck
import qualified TD.Data.Chat as Chat
import qualified Data.Text as T
import qualified TD.Data.ChatPhotoInfo as ChatPhotoInfo
import qualified TD.Data.ChatPermissions as ChatPermissions
import qualified TD.Data.ChatPosition as ChatPosition
import qualified TD.Data.ChatList as ChatList
import qualified TD.Data.ChatActionBar as ChatActionBar
import qualified TD.Data.BusinessBotManageBar as BusinessBotManageBar
import qualified TD.Data.ChatAvailableReactions as ChatAvailableReactions
import qualified TD.Data.DraftMessage as DraftMessage
import qualified TD.Data.EmojiStatus as EmojiStatus
import qualified TD.Data.MessageSender as MessageSender
import qualified TD.Data.ChatNotificationSettings as ChatNotificationSettings
import qualified TD.Data.ChatJoinRequestsInfo as ChatJoinRequestsInfo
import qualified TD.Data.ChatBackground as ChatBackground
import qualified TD.Data.VideoChat as VideoChat
import qualified TD.Data.BlockList as BlockList
import qualified TD.Data.ChatFolderInfo as ChatFolderInfo
import qualified TD.Data.SavedMessagesTopic as SavedMessagesTopic
import qualified TD.Data.QuickReplyShortcut as QuickReplyShortcut
import qualified TD.Data.QuickReplyMessage as QuickReplyMessage
import qualified TD.Data.ForumTopicInfo as ForumTopicInfo
import qualified TD.Data.NotificationSettingsScope as NotificationSettingsScope
import qualified TD.Data.ScopeNotificationSettings as ScopeNotificationSettings
import qualified TD.Data.ReactionNotificationSettings as ReactionNotificationSettings
import qualified TD.Data.Notification as Notification
import qualified TD.Data.NotificationGroupType as NotificationGroupType
import qualified TD.Data.NotificationGroup as NotificationGroup
import qualified TD.Data.ChatAction as ChatAction
import qualified TD.Data.UserStatus as UserStatus
import qualified TD.Data.User as User
import qualified TD.Data.BasicGroup as BasicGroup
import qualified TD.Data.Supergroup as Supergroup
import qualified TD.Data.SecretChat as SecretChat
import qualified TD.Data.UserFullInfo as UserFullInfo
import qualified TD.Data.BasicGroupFullInfo as BasicGroupFullInfo
import qualified TD.Data.SupergroupFullInfo as SupergroupFullInfo
import qualified TD.Data.File as File
import qualified TD.Data.FileDownload as FileDownload
import qualified TD.Data.DownloadedFileCounts as DownloadedFileCounts
import qualified TD.Data.Call as Call
import qualified TD.Data.GroupCall as GroupCall
import qualified TD.Data.GroupCallParticipant as GroupCallParticipant
import qualified Data.ByteString as BS
import qualified TD.Data.UserPrivacySetting as UserPrivacySetting
import qualified TD.Data.UserPrivacySettingRules as UserPrivacySettingRules
import qualified TD.Data.Story as Story
import qualified TD.Data.CanSendStoryResult as CanSendStoryResult
import qualified TD.Data.ChatActiveStories as ChatActiveStories
import qualified TD.Data.StoryList as StoryList
import qualified TD.Data.OptionValue as OptionValue
import qualified TD.Data.StickerSet as StickerSet
import qualified TD.Data.StickerType as StickerType
import qualified TD.Data.TrendingStickerSets as TrendingStickerSets
import qualified TD.Data.Background as Background
import qualified TD.Data.ChatTheme as ChatTheme
import qualified TD.Data.AccentColor as AccentColor
import qualified TD.Data.ProfileAccentColor as ProfileAccentColor
import qualified TD.Data.LanguagePackString as LanguagePackString
import qualified TD.Data.ConnectionState as ConnectionState
import qualified TD.Data.TermsOfService as TermsOfService
import qualified TD.Data.UnconfirmedSession as UnconfirmedSession
import qualified TD.Data.AttachmentMenuBot as AttachmentMenuBot
import qualified TD.Data.ReactionType as ReactionType
import qualified TD.Data.SavedMessagesTags as SavedMessagesTags
import qualified TD.Data.ChatRevenueAmount as ChatRevenueAmount
import qualified TD.Data.StarRevenueStatus as StarRevenueStatus
import qualified TD.Data.Sticker as Sticker
import qualified TD.Data.SuggestedAction as SuggestedAction
import qualified TD.Data.CloseBirthdayUser as CloseBirthdayUser
import qualified TD.Data.AutosaveSettingsScope as AutosaveSettingsScope
import qualified TD.Data.ScopeAutosaveSettings as ScopeAutosaveSettings
import qualified TD.Data.BusinessConnection as BusinessConnection
import qualified TD.Data.BusinessMessage as BusinessMessage
import qualified TD.Data.Location as Location
import qualified TD.Data.ChatType as ChatType
import qualified TD.Data.CallbackQueryPayload as CallbackQueryPayload
import qualified TD.Data.Address as Address
import qualified TD.Data.OrderInfo as OrderInfo
import qualified TD.Data.Poll as Poll
import qualified TD.Data.ChatInviteLink as ChatInviteLink
import qualified TD.Data.ChatMember as ChatMember
import qualified TD.Data.ChatJoinRequest as ChatJoinRequest
import qualified TD.Data.ChatBoost as ChatBoost
import qualified TD.Data.MessageReaction as MessageReaction
data Update
= UpdateAuthorizationState
{ Update -> Maybe AuthorizationState
authorization_state :: Maybe AuthorizationState.AuthorizationState
}
| UpdateNewMessage
{ Update -> Maybe Message
message :: Maybe Message.Message
}
| UpdateMessageSendAcknowledged
{ Update -> Maybe Int
chat_id :: Maybe Int
, Update -> Maybe Int
message_id :: Maybe Int
}
| UpdateMessageSendSucceeded
{ message :: Maybe Message.Message
, Update -> Maybe Int
old_message_id :: Maybe Int
}
| UpdateMessageSendFailed
{ message :: Maybe Message.Message
, old_message_id :: Maybe Int
, Update -> Maybe Error
_error :: Maybe Error.Error
}
| UpdateMessageContent
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe MessageContent
new_content :: Maybe MessageContent.MessageContent
}
| UpdateMessageEdited
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe Int
edit_date :: Maybe Int
, Update -> Maybe ReplyMarkup
reply_markup :: Maybe ReplyMarkup.ReplyMarkup
}
| UpdateMessageIsPinned
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe Bool
is_pinned :: Maybe Bool
}
| UpdateMessageInteractionInfo
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe MessageInteractionInfo
interaction_info :: Maybe MessageInteractionInfo.MessageInteractionInfo
}
| UpdateMessageContentOpened
{ chat_id :: Maybe Int
, message_id :: Maybe Int
}
| UpdateMessageMentionRead
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe Int
unread_mention_count :: Maybe Int
}
| UpdateMessageUnreadReactions
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe [UnreadReaction]
unread_reactions :: Maybe [UnreadReaction.UnreadReaction]
, Update -> Maybe Int
unread_reaction_count :: Maybe Int
}
| UpdateMessageFactCheck
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe FactCheck
fact_check :: Maybe FactCheck.FactCheck
}
| UpdateMessageLiveLocationViewed
{ chat_id :: Maybe Int
, message_id :: Maybe Int
}
| UpdateNewChat
{ Update -> Maybe Chat
chat :: Maybe Chat.Chat
}
| UpdateChatTitle
{ chat_id :: Maybe Int
, Update -> Maybe Text
title :: Maybe T.Text
}
| UpdateChatPhoto
{ chat_id :: Maybe Int
, Update -> Maybe ChatPhotoInfo
photo :: Maybe ChatPhotoInfo.ChatPhotoInfo
}
| UpdateChatAccentColors
{ chat_id :: Maybe Int
, Update -> Maybe Int
accent_color_id :: Maybe Int
, Update -> Maybe Int
background_custom_emoji_id :: Maybe Int
, Update -> Maybe Int
profile_accent_color_id :: Maybe Int
, Update -> Maybe Int
profile_background_custom_emoji_id :: Maybe Int
}
| UpdateChatPermissions
{ chat_id :: Maybe Int
, Update -> Maybe ChatPermissions
permissions :: Maybe ChatPermissions.ChatPermissions
}
| UpdateChatLastMessage
{ chat_id :: Maybe Int
, Update -> Maybe Message
last_message :: Maybe Message.Message
, Update -> Maybe [ChatPosition]
positions :: Maybe [ChatPosition.ChatPosition]
}
| UpdateChatPosition
{ chat_id :: Maybe Int
, Update -> Maybe ChatPosition
position :: Maybe ChatPosition.ChatPosition
}
| UpdateChatAddedToList
{ chat_id :: Maybe Int
, Update -> Maybe ChatList
chat_list :: Maybe ChatList.ChatList
}
| UpdateChatRemovedFromList
{ chat_id :: Maybe Int
, chat_list :: Maybe ChatList.ChatList
}
| UpdateChatReadInbox
{ chat_id :: Maybe Int
, Update -> Maybe Int
last_read_inbox_message_id :: Maybe Int
, Update -> Maybe Int
unread_count :: Maybe Int
}
| UpdateChatReadOutbox
{ chat_id :: Maybe Int
, Update -> Maybe Int
last_read_outbox_message_id :: Maybe Int
}
| UpdateChatActionBar
{ chat_id :: Maybe Int
, Update -> Maybe ChatActionBar
action_bar :: Maybe ChatActionBar.ChatActionBar
}
| UpdateChatBusinessBotManageBar
{ chat_id :: Maybe Int
, Update -> Maybe BusinessBotManageBar
business_bot_manage_bar :: Maybe BusinessBotManageBar.BusinessBotManageBar
}
| UpdateChatAvailableReactions
{ chat_id :: Maybe Int
, Update -> Maybe ChatAvailableReactions
available_reactions :: Maybe ChatAvailableReactions.ChatAvailableReactions
}
| UpdateChatDraftMessage
{ chat_id :: Maybe Int
, Update -> Maybe DraftMessage
draft_message :: Maybe DraftMessage.DraftMessage
, positions :: Maybe [ChatPosition.ChatPosition]
}
| UpdateChatEmojiStatus
{ chat_id :: Maybe Int
, Update -> Maybe EmojiStatus
emoji_status :: Maybe EmojiStatus.EmojiStatus
}
| UpdateChatMessageSender
{ chat_id :: Maybe Int
, Update -> Maybe MessageSender
message_sender_id :: Maybe MessageSender.MessageSender
}
| UpdateChatMessageAutoDeleteTime
{ chat_id :: Maybe Int
, Update -> Maybe Int
message_auto_delete_time :: Maybe Int
}
| UpdateChatNotificationSettings
{ chat_id :: Maybe Int
, Update -> Maybe ChatNotificationSettings
notification_settings :: Maybe ChatNotificationSettings.ChatNotificationSettings
}
| UpdateChatPendingJoinRequests
{ chat_id :: Maybe Int
, Update -> Maybe ChatJoinRequestsInfo
pending_join_requests :: Maybe ChatJoinRequestsInfo.ChatJoinRequestsInfo
}
| UpdateChatReplyMarkup
{ chat_id :: Maybe Int
, Update -> Maybe Int
reply_markup_message_id :: Maybe Int
}
| UpdateChatBackground
{ chat_id :: Maybe Int
, Update -> Maybe ChatBackground
background :: Maybe ChatBackground.ChatBackground
}
| UpdateChatTheme
{ chat_id :: Maybe Int
, Update -> Maybe Text
theme_name :: Maybe T.Text
}
| UpdateChatUnreadMentionCount
{ chat_id :: Maybe Int
, unread_mention_count :: Maybe Int
}
| UpdateChatUnreadReactionCount
{ chat_id :: Maybe Int
, unread_reaction_count :: Maybe Int
}
| UpdateChatVideoChat
{ chat_id :: Maybe Int
, Update -> Maybe VideoChat
video_chat :: Maybe VideoChat.VideoChat
}
| UpdateChatDefaultDisableNotification
{ chat_id :: Maybe Int
, Update -> Maybe Bool
default_disable_notification :: Maybe Bool
}
| UpdateChatHasProtectedContent
{ chat_id :: Maybe Int
, Update -> Maybe Bool
has_protected_content :: Maybe Bool
}
| UpdateChatIsTranslatable
{ chat_id :: Maybe Int
, Update -> Maybe Bool
is_translatable :: Maybe Bool
}
| UpdateChatIsMarkedAsUnread
{ chat_id :: Maybe Int
, Update -> Maybe Bool
is_marked_as_unread :: Maybe Bool
}
| UpdateChatViewAsTopics
{ chat_id :: Maybe Int
, Update -> Maybe Bool
view_as_topics :: Maybe Bool
}
| UpdateChatBlockList
{ chat_id :: Maybe Int
, Update -> Maybe BlockList
block_list :: Maybe BlockList.BlockList
}
| UpdateChatHasScheduledMessages
{ chat_id :: Maybe Int
, Update -> Maybe Bool
has_scheduled_messages :: Maybe Bool
}
| UpdateChatFolders
{ Update -> Maybe [ChatFolderInfo]
chat_folders :: Maybe [ChatFolderInfo.ChatFolderInfo]
, Update -> Maybe Int
main_chat_list_position :: Maybe Int
, Update -> Maybe Bool
are_tags_enabled :: Maybe Bool
}
| UpdateChatOnlineMemberCount
{ chat_id :: Maybe Int
, Update -> Maybe Int
online_member_count :: Maybe Int
}
| UpdateSavedMessagesTopic
{ Update -> Maybe SavedMessagesTopic
topic :: Maybe SavedMessagesTopic.SavedMessagesTopic
}
| UpdateSavedMessagesTopicCount
{ Update -> Maybe Int
topic_count :: Maybe Int
}
| UpdateQuickReplyShortcut
{ Update -> Maybe QuickReplyShortcut
shortcut :: Maybe QuickReplyShortcut.QuickReplyShortcut
}
| UpdateQuickReplyShortcutDeleted
{ Update -> Maybe Int
shortcut_id :: Maybe Int
}
| UpdateQuickReplyShortcuts
{ Update -> Maybe [Int]
shortcut_ids :: Maybe [Int]
}
| UpdateQuickReplyShortcutMessages
{ shortcut_id :: Maybe Int
, Update -> Maybe [QuickReplyMessage]
messages :: Maybe [QuickReplyMessage.QuickReplyMessage]
}
| UpdateForumTopicInfo
{ chat_id :: Maybe Int
, Update -> Maybe ForumTopicInfo
info :: Maybe ForumTopicInfo.ForumTopicInfo
}
| UpdateScopeNotificationSettings
{ Update -> Maybe NotificationSettingsScope
scope :: Maybe NotificationSettingsScope.NotificationSettingsScope
, Update -> Maybe ScopeNotificationSettings
_notification_settings :: Maybe ScopeNotificationSettings.ScopeNotificationSettings
}
| UpdateReactionNotificationSettings
{ Update -> Maybe ReactionNotificationSettings
__notification_settings :: Maybe ReactionNotificationSettings.ReactionNotificationSettings
}
| UpdateNotification
{ Update -> Maybe Int
notification_group_id :: Maybe Int
, Update -> Maybe Notification
notification :: Maybe Notification.Notification
}
| UpdateNotificationGroup
{ notification_group_id :: Maybe Int
, Update -> Maybe NotificationGroupType
_type :: Maybe NotificationGroupType.NotificationGroupType
, chat_id :: Maybe Int
, Update -> Maybe Int
notification_settings_chat_id :: Maybe Int
, Update -> Maybe Int
notification_sound_id :: Maybe Int
, Update -> Maybe Int
total_count :: Maybe Int
, Update -> Maybe [Notification]
added_notifications :: Maybe [Notification.Notification]
, Update -> Maybe [Int]
removed_notification_ids :: Maybe [Int]
}
| UpdateActiveNotifications
{ Update -> Maybe [NotificationGroup]
groups :: Maybe [NotificationGroup.NotificationGroup]
}
| UpdateHavePendingNotifications
{ Update -> Maybe Bool
have_delayed_notifications :: Maybe Bool
, Update -> Maybe Bool
have_unreceived_notifications :: Maybe Bool
}
| UpdateDeleteMessages
{ chat_id :: Maybe Int
, Update -> Maybe [Int]
message_ids :: Maybe [Int]
, Update -> Maybe Bool
is_permanent :: Maybe Bool
, Update -> Maybe Bool
from_cache :: Maybe Bool
}
| UpdateChatAction
{ chat_id :: Maybe Int
, Update -> Maybe Int
message_thread_id :: Maybe Int
, Update -> Maybe MessageSender
sender_id :: Maybe MessageSender.MessageSender
, Update -> Maybe ChatAction
action :: Maybe ChatAction.ChatAction
}
| UpdateUserStatus
{ Update -> Maybe Int
user_id :: Maybe Int
, Update -> Maybe UserStatus
status :: Maybe UserStatus.UserStatus
}
| UpdateUser
{ Update -> Maybe User
user :: Maybe User.User
}
| UpdateBasicGroup
{ Update -> Maybe BasicGroup
basic_group :: Maybe BasicGroup.BasicGroup
}
| UpdateSupergroup
{ Update -> Maybe Supergroup
supergroup :: Maybe Supergroup.Supergroup
}
| UpdateSecretChat
{ Update -> Maybe SecretChat
secret_chat :: Maybe SecretChat.SecretChat
}
| UpdateUserFullInfo
{ user_id :: Maybe Int
, Update -> Maybe UserFullInfo
user_full_info :: Maybe UserFullInfo.UserFullInfo
}
| UpdateBasicGroupFullInfo
{ Update -> Maybe Int
basic_group_id :: Maybe Int
, Update -> Maybe BasicGroupFullInfo
basic_group_full_info :: Maybe BasicGroupFullInfo.BasicGroupFullInfo
}
| UpdateSupergroupFullInfo
{ Update -> Maybe Int
supergroup_id :: Maybe Int
, Update -> Maybe SupergroupFullInfo
supergroup_full_info :: Maybe SupergroupFullInfo.SupergroupFullInfo
}
| UpdateServiceNotification
{ Update -> Maybe Text
__type :: Maybe T.Text
, Update -> Maybe MessageContent
content :: Maybe MessageContent.MessageContent
}
| UpdateFile
{ Update -> Maybe File
file :: Maybe File.File
}
| UpdateFileGenerationStart
{ Update -> Maybe Int
generation_id :: Maybe Int
, Update -> Maybe Text
original_path :: Maybe T.Text
, Update -> Maybe Text
destination_path :: Maybe T.Text
, Update -> Maybe Text
conversion :: Maybe T.Text
}
| UpdateFileGenerationStop
{ generation_id :: Maybe Int
}
| UpdateFileDownloads
{ Update -> Maybe Int
total_size :: Maybe Int
, total_count :: Maybe Int
, Update -> Maybe Int
downloaded_size :: Maybe Int
}
| UpdateFileAddedToDownloads
{ Update -> Maybe FileDownload
file_download :: Maybe FileDownload.FileDownload
, Update -> Maybe DownloadedFileCounts
counts :: Maybe DownloadedFileCounts.DownloadedFileCounts
}
| UpdateFileDownload
{ Update -> Maybe Int
file_id :: Maybe Int
, Update -> Maybe Int
complete_date :: Maybe Int
, Update -> Maybe Bool
is_paused :: Maybe Bool
, counts :: Maybe DownloadedFileCounts.DownloadedFileCounts
}
| UpdateFileRemovedFromDownloads
{ file_id :: Maybe Int
, counts :: Maybe DownloadedFileCounts.DownloadedFileCounts
}
| UpdateApplicationVerificationRequired
{ Update -> Maybe Int
verification_id :: Maybe Int
, Update -> Maybe Text
nonce :: Maybe T.Text
, Update -> Maybe Int
cloud_project_number :: Maybe Int
}
| UpdateCall
{ Update -> Maybe Call
call :: Maybe Call.Call
}
| UpdateGroupCall
{ Update -> Maybe GroupCall
group_call :: Maybe GroupCall.GroupCall
}
| UpdateGroupCallParticipant
{ Update -> Maybe Int
group_call_id :: Maybe Int
, Update -> Maybe GroupCallParticipant
participant :: Maybe GroupCallParticipant.GroupCallParticipant
}
| UpdateNewCallSignalingData
{ Update -> Maybe Int
call_id :: Maybe Int
, Update -> Maybe ByteString
_data :: Maybe BS.ByteString
}
| UpdateUserPrivacySettingRules
{ Update -> Maybe UserPrivacySetting
setting :: Maybe UserPrivacySetting.UserPrivacySetting
, Update -> Maybe UserPrivacySettingRules
rules :: Maybe UserPrivacySettingRules.UserPrivacySettingRules
}
| UpdateUnreadMessageCount
{ chat_list :: Maybe ChatList.ChatList
, unread_count :: Maybe Int
, Update -> Maybe Int
unread_unmuted_count :: Maybe Int
}
| UpdateUnreadChatCount
{ chat_list :: Maybe ChatList.ChatList
, total_count :: Maybe Int
, unread_count :: Maybe Int
, unread_unmuted_count :: Maybe Int
, Update -> Maybe Int
marked_as_unread_count :: Maybe Int
, Update -> Maybe Int
marked_as_unread_unmuted_count :: Maybe Int
}
| UpdateStory
{ Update -> Maybe Story
story :: Maybe Story.Story
}
| UpdateStoryDeleted
{ Update -> Maybe Int
story_sender_chat_id :: Maybe Int
, Update -> Maybe Int
story_id :: Maybe Int
}
| UpdateStorySendSucceeded
{ story :: Maybe Story.Story
, Update -> Maybe Int
old_story_id :: Maybe Int
}
| UpdateStorySendFailed
{ story :: Maybe Story.Story
, _error :: Maybe Error.Error
, Update -> Maybe CanSendStoryResult
error_type :: Maybe CanSendStoryResult.CanSendStoryResult
}
| UpdateChatActiveStories
{ Update -> Maybe ChatActiveStories
active_stories :: Maybe ChatActiveStories.ChatActiveStories
}
| UpdateStoryListChatCount
{ Update -> Maybe StoryList
story_list :: Maybe StoryList.StoryList
, Update -> Maybe Int
chat_count :: Maybe Int
}
| UpdateStoryStealthMode
{ Update -> Maybe Int
active_until_date :: Maybe Int
, Update -> Maybe Int
cooldown_until_date :: Maybe Int
}
| UpdateOption
{ Update -> Maybe Text
name :: Maybe T.Text
, Update -> Maybe OptionValue
value :: Maybe OptionValue.OptionValue
}
| UpdateStickerSet
{ Update -> Maybe StickerSet
sticker_set :: Maybe StickerSet.StickerSet
}
| UpdateInstalledStickerSets
{ Update -> Maybe StickerType
sticker_type :: Maybe StickerType.StickerType
, Update -> Maybe [Int]
sticker_set_ids :: Maybe [Int]
}
| UpdateTrendingStickerSets
{ sticker_type :: Maybe StickerType.StickerType
, Update -> Maybe TrendingStickerSets
sticker_sets :: Maybe TrendingStickerSets.TrendingStickerSets
}
| UpdateRecentStickers
{ Update -> Maybe Bool
is_attached :: Maybe Bool
, Update -> Maybe [Int]
sticker_ids :: Maybe [Int]
}
| UpdateFavoriteStickers
{ sticker_ids :: Maybe [Int]
}
| UpdateSavedAnimations
{ Update -> Maybe [Int]
animation_ids :: Maybe [Int]
}
| UpdateSavedNotificationSounds
{ Update -> Maybe [Int]
notification_sound_ids :: Maybe [Int]
}
| UpdateDefaultBackground
{ Update -> Maybe Bool
for_dark_theme :: Maybe Bool
, Update -> Maybe Background
_background :: Maybe Background.Background
}
| UpdateChatThemes
{ Update -> Maybe [ChatTheme]
chat_themes :: Maybe [ChatTheme.ChatTheme]
}
| UpdateAccentColors
{ Update -> Maybe [AccentColor]
colors :: Maybe [AccentColor.AccentColor]
, Update -> Maybe [Int]
available_accent_color_ids :: Maybe [Int]
}
| UpdateProfileAccentColors
{ Update -> Maybe [ProfileAccentColor]
_colors :: Maybe [ProfileAccentColor.ProfileAccentColor]
, available_accent_color_ids :: Maybe [Int]
}
| UpdateLanguagePackStrings
{ Update -> Maybe Text
localization_target :: Maybe T.Text
, Update -> Maybe Text
language_pack_id :: Maybe T.Text
, Update -> Maybe [LanguagePackString]
strings :: Maybe [LanguagePackString.LanguagePackString]
}
| UpdateConnectionState
{ Update -> Maybe ConnectionState
state :: Maybe ConnectionState.ConnectionState
}
| UpdateTermsOfService
{ Update -> Maybe Text
terms_of_service_id :: Maybe T.Text
, Update -> Maybe TermsOfService
terms_of_service :: Maybe TermsOfService.TermsOfService
}
| UpdateUnconfirmedSession
{ Update -> Maybe UnconfirmedSession
session :: Maybe UnconfirmedSession.UnconfirmedSession
}
|
{ Update -> Maybe [AttachmentMenuBot]
bots :: Maybe [AttachmentMenuBot.AttachmentMenuBot]
}
| UpdateWebAppMessageSent
{ Update -> Maybe Int
web_app_launch_id :: Maybe Int
}
| UpdateActiveEmojiReactions
{ Update -> Maybe [Text]
emojis :: Maybe [T.Text]
}
| UpdateAvailableMessageEffects
{ Update -> Maybe [Int]
reaction_effect_ids :: Maybe [Int]
, Update -> Maybe [Int]
sticker_effect_ids :: Maybe [Int]
}
| UpdateDefaultReactionType
{ Update -> Maybe ReactionType
reaction_type :: Maybe ReactionType.ReactionType
}
| UpdateSavedMessagesTags
{ Update -> Maybe Int
saved_messages_topic_id :: Maybe Int
, Update -> Maybe SavedMessagesTags
tags :: Maybe SavedMessagesTags.SavedMessagesTags
}
| UpdateActiveLiveLocationMessages
{ Update -> Maybe [Message]
_messages :: Maybe [Message.Message]
}
| UpdateOwnedStarCount
{ Update -> Maybe Int
star_count :: Maybe Int
}
| UpdateChatRevenueAmount
{ chat_id :: Maybe Int
, Update -> Maybe ChatRevenueAmount
revenue_amount :: Maybe ChatRevenueAmount.ChatRevenueAmount
}
| UpdateStarRevenueStatus
{ Update -> Maybe MessageSender
owner_id :: Maybe MessageSender.MessageSender
, Update -> Maybe StarRevenueStatus
_status :: Maybe StarRevenueStatus.StarRevenueStatus
}
| UpdateSpeechRecognitionTrial
{ Update -> Maybe Int
max_media_duration :: Maybe Int
, Update -> Maybe Int
weekly_count :: Maybe Int
, Update -> Maybe Int
left_count :: Maybe Int
, Update -> Maybe Int
next_reset_date :: Maybe Int
}
| UpdateDiceEmojis
{ emojis :: Maybe [T.Text]
}
| UpdateAnimatedEmojiMessageClicked
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe Sticker
sticker :: Maybe Sticker.Sticker
}
| UpdateAnimationSearchParameters
{ Update -> Maybe Text
provider :: Maybe T.Text
, emojis :: Maybe [T.Text]
}
| UpdateSuggestedActions
{ Update -> Maybe [SuggestedAction]
added_actions :: Maybe [SuggestedAction.SuggestedAction]
, Update -> Maybe [SuggestedAction]
removed_actions :: Maybe [SuggestedAction.SuggestedAction]
}
| UpdateSpeedLimitNotification
{ Update -> Maybe Bool
is_upload :: Maybe Bool
}
| UpdateContactCloseBirthdays
{ Update -> Maybe [CloseBirthdayUser]
close_birthday_users :: Maybe [CloseBirthdayUser.CloseBirthdayUser]
}
| UpdateAutosaveSettings
{ Update -> Maybe AutosaveSettingsScope
_scope :: Maybe AutosaveSettingsScope.AutosaveSettingsScope
, Update -> Maybe ScopeAutosaveSettings
settings :: Maybe ScopeAutosaveSettings.ScopeAutosaveSettings
}
| UpdateBusinessConnection
{ Update -> Maybe BusinessConnection
connection :: Maybe BusinessConnection.BusinessConnection
}
| UpdateNewBusinessMessage
{ Update -> Maybe Text
connection_id :: Maybe T.Text
, Update -> Maybe BusinessMessage
_message :: Maybe BusinessMessage.BusinessMessage
}
| UpdateBusinessMessageEdited
{ connection_id :: Maybe T.Text
, _message :: Maybe BusinessMessage.BusinessMessage
}
| UpdateBusinessMessagesDeleted
{ connection_id :: Maybe T.Text
, chat_id :: Maybe Int
, message_ids :: Maybe [Int]
}
| UpdateNewInlineQuery
{ Update -> Maybe Int
_id :: Maybe Int
, Update -> Maybe Int
sender_user_id :: Maybe Int
, Update -> Maybe Location
user_location :: Maybe Location.Location
, Update -> Maybe ChatType
chat_type :: Maybe ChatType.ChatType
, Update -> Maybe Text
query :: Maybe T.Text
, Update -> Maybe Text
offset :: Maybe T.Text
}
| UpdateNewChosenInlineResult
{ sender_user_id :: Maybe Int
, user_location :: Maybe Location.Location
, query :: Maybe T.Text
, Update -> Maybe Text
result_id :: Maybe T.Text
, Update -> Maybe Text
inline_message_id :: Maybe T.Text
}
| UpdateNewCallbackQuery
{ _id :: Maybe Int
, sender_user_id :: Maybe Int
, chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe Int
chat_instance :: Maybe Int
, Update -> Maybe CallbackQueryPayload
payload :: Maybe CallbackQueryPayload.CallbackQueryPayload
}
| UpdateNewInlineCallbackQuery
{ _id :: Maybe Int
, sender_user_id :: Maybe Int
, inline_message_id :: Maybe T.Text
, chat_instance :: Maybe Int
, payload :: Maybe CallbackQueryPayload.CallbackQueryPayload
}
| UpdateNewBusinessCallbackQuery
{ _id :: Maybe Int
, sender_user_id :: Maybe Int
, connection_id :: Maybe T.Text
, _message :: Maybe BusinessMessage.BusinessMessage
, chat_instance :: Maybe Int
, payload :: Maybe CallbackQueryPayload.CallbackQueryPayload
}
| UpdateNewShippingQuery
{ _id :: Maybe Int
, sender_user_id :: Maybe Int
, Update -> Maybe Text
invoice_payload :: Maybe T.Text
, Update -> Maybe Address
shipping_address :: Maybe Address.Address
}
| UpdateNewPreCheckoutQuery
{ _id :: Maybe Int
, sender_user_id :: Maybe Int
, Update -> Maybe Text
currency :: Maybe T.Text
, Update -> Maybe Int
total_amount :: Maybe Int
, Update -> Maybe ByteString
_invoice_payload :: Maybe BS.ByteString
, Update -> Maybe Text
shipping_option_id :: Maybe T.Text
, Update -> Maybe OrderInfo
order_info :: Maybe OrderInfo.OrderInfo
}
| UpdateNewCustomEvent
{ Update -> Maybe Text
event :: Maybe T.Text
}
| UpdateNewCustomQuery
{ _id :: Maybe Int
, Update -> Maybe Text
__data :: Maybe T.Text
, Update -> Maybe Int
timeout :: Maybe Int
}
| UpdatePoll
{ Update -> Maybe Poll
poll :: Maybe Poll.Poll
}
| UpdatePollAnswer
{ Update -> Maybe Int
poll_id :: Maybe Int
, Update -> Maybe MessageSender
voter_id :: Maybe MessageSender.MessageSender
, Update -> Maybe [Int]
option_ids :: Maybe [Int]
}
| UpdateChatMember
{ chat_id :: Maybe Int
, Update -> Maybe Int
actor_user_id :: Maybe Int
, Update -> Maybe Int
date :: Maybe Int
, Update -> Maybe ChatInviteLink
invite_link :: Maybe ChatInviteLink.ChatInviteLink
, Update -> Maybe Bool
via_join_request :: Maybe Bool
, Update -> Maybe Bool
via_chat_folder_invite_link :: Maybe Bool
, Update -> Maybe ChatMember
old_chat_member :: Maybe ChatMember.ChatMember
, Update -> Maybe ChatMember
new_chat_member :: Maybe ChatMember.ChatMember
}
| UpdateNewChatJoinRequest
{ chat_id :: Maybe Int
, Update -> Maybe ChatJoinRequest
request :: Maybe ChatJoinRequest.ChatJoinRequest
, Update -> Maybe Int
user_chat_id :: Maybe Int
, invite_link :: Maybe ChatInviteLink.ChatInviteLink
}
| UpdateChatBoost
{ chat_id :: Maybe Int
, Update -> Maybe ChatBoost
boost :: Maybe ChatBoost.ChatBoost
}
| UpdateMessageReaction
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, Update -> Maybe MessageSender
actor_id :: Maybe MessageSender.MessageSender
, date :: Maybe Int
, Update -> Maybe [ReactionType]
old_reaction_types :: Maybe [ReactionType.ReactionType]
, Update -> Maybe [ReactionType]
new_reaction_types :: Maybe [ReactionType.ReactionType]
}
| UpdateMessageReactions
{ chat_id :: Maybe Int
, message_id :: Maybe Int
, date :: Maybe Int
, Update -> Maybe [MessageReaction]
reactions :: Maybe [MessageReaction.MessageReaction]
}
| UpdatePaidMediaPurchased
{ user_id :: Maybe Int
, Update -> Maybe Text
_payload :: Maybe T.Text
}
deriving (Update -> Update -> Bool
(Update -> Update -> Bool)
-> (Update -> Update -> Bool) -> Eq Update
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Update -> Update -> Bool
== :: Update -> Update -> Bool
$c/= :: Update -> Update -> Bool
/= :: Update -> Update -> Bool
Eq, Int -> Update -> ShowS
[Update] -> ShowS
Update -> String
(Int -> Update -> ShowS)
-> (Update -> String) -> ([Update] -> ShowS) -> Show Update
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Update -> ShowS
showsPrec :: Int -> Update -> ShowS
$cshow :: Update -> String
show :: Update -> String
$cshowList :: [Update] -> ShowS
showList :: [Update] -> ShowS
Show)
instance I.ShortShow Update where
shortShow :: Update -> String
shortShow UpdateAuthorizationState
{ authorization_state :: Update -> Maybe AuthorizationState
authorization_state = Maybe AuthorizationState
authorization_state_
}
= String
"UpdateAuthorizationState"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"authorization_state" String -> Maybe AuthorizationState -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe AuthorizationState
authorization_state_
]
shortShow UpdateNewMessage
{ message :: Update -> Maybe Message
message = Maybe Message
message_
}
= String
"UpdateNewMessage"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"message" String -> Maybe Message -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Message
message_
]
shortShow UpdateMessageSendAcknowledged
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
}
= String
"UpdateMessageSendAcknowledged"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
]
shortShow UpdateMessageSendSucceeded
{ message :: Update -> Maybe Message
message = Maybe Message
message_
, old_message_id :: Update -> Maybe Int
old_message_id = Maybe Int
old_message_id_
}
= String
"UpdateMessageSendSucceeded"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"message" String -> Maybe Message -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Message
message_
, String
"old_message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
old_message_id_
]
shortShow UpdateMessageSendFailed
{ message :: Update -> Maybe Message
message = Maybe Message
message_
, old_message_id :: Update -> Maybe Int
old_message_id = Maybe Int
old_message_id_
, _error :: Update -> Maybe Error
_error = Maybe Error
_error_
}
= String
"UpdateMessageSendFailed"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"message" String -> Maybe Message -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Message
message_
, String
"old_message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
old_message_id_
, String
"_error" String -> Maybe Error -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Error
_error_
]
shortShow UpdateMessageContent
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, new_content :: Update -> Maybe MessageContent
new_content = Maybe MessageContent
new_content_
}
= String
"UpdateMessageContent"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"new_content" String -> Maybe MessageContent -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageContent
new_content_
]
shortShow UpdateMessageEdited
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, edit_date :: Update -> Maybe Int
edit_date = Maybe Int
edit_date_
, reply_markup :: Update -> Maybe ReplyMarkup
reply_markup = Maybe ReplyMarkup
reply_markup_
}
= String
"UpdateMessageEdited"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"edit_date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
edit_date_
, String
"reply_markup" String -> Maybe ReplyMarkup -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ReplyMarkup
reply_markup_
]
shortShow UpdateMessageIsPinned
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, is_pinned :: Update -> Maybe Bool
is_pinned = Maybe Bool
is_pinned_
}
= String
"UpdateMessageIsPinned"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"is_pinned" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_pinned_
]
shortShow UpdateMessageInteractionInfo
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, interaction_info :: Update -> Maybe MessageInteractionInfo
interaction_info = Maybe MessageInteractionInfo
interaction_info_
}
= String
"UpdateMessageInteractionInfo"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"interaction_info" String -> Maybe MessageInteractionInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageInteractionInfo
interaction_info_
]
shortShow UpdateMessageContentOpened
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
}
= String
"UpdateMessageContentOpened"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
]
shortShow UpdateMessageMentionRead
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, unread_mention_count :: Update -> Maybe Int
unread_mention_count = Maybe Int
unread_mention_count_
}
= String
"UpdateMessageMentionRead"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"unread_mention_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_mention_count_
]
shortShow UpdateMessageUnreadReactions
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, unread_reactions :: Update -> Maybe [UnreadReaction]
unread_reactions = Maybe [UnreadReaction]
unread_reactions_
, unread_reaction_count :: Update -> Maybe Int
unread_reaction_count = Maybe Int
unread_reaction_count_
}
= String
"UpdateMessageUnreadReactions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"unread_reactions" String -> Maybe [UnreadReaction] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [UnreadReaction]
unread_reactions_
, String
"unread_reaction_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_reaction_count_
]
shortShow UpdateMessageFactCheck
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, fact_check :: Update -> Maybe FactCheck
fact_check = Maybe FactCheck
fact_check_
}
= String
"UpdateMessageFactCheck"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"fact_check" String -> Maybe FactCheck -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe FactCheck
fact_check_
]
shortShow UpdateMessageLiveLocationViewed
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
}
= String
"UpdateMessageLiveLocationViewed"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
]
shortShow UpdateNewChat
{ chat :: Update -> Maybe Chat
chat = Maybe Chat
chat_
}
= String
"UpdateNewChat"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat" String -> Maybe Chat -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Chat
chat_
]
shortShow UpdateChatTitle
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, title :: Update -> Maybe Text
title = Maybe Text
title_
}
= String
"UpdateChatTitle"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"title" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
title_
]
shortShow UpdateChatPhoto
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, photo :: Update -> Maybe ChatPhotoInfo
photo = Maybe ChatPhotoInfo
photo_
}
= String
"UpdateChatPhoto"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"photo" String -> Maybe ChatPhotoInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatPhotoInfo
photo_
]
shortShow UpdateChatAccentColors
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, accent_color_id :: Update -> Maybe Int
accent_color_id = Maybe Int
accent_color_id_
, background_custom_emoji_id :: Update -> Maybe Int
background_custom_emoji_id = Maybe Int
background_custom_emoji_id_
, profile_accent_color_id :: Update -> Maybe Int
profile_accent_color_id = Maybe Int
profile_accent_color_id_
, profile_background_custom_emoji_id :: Update -> Maybe Int
profile_background_custom_emoji_id = Maybe Int
profile_background_custom_emoji_id_
}
= String
"UpdateChatAccentColors"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"accent_color_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
accent_color_id_
, String
"background_custom_emoji_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
background_custom_emoji_id_
, String
"profile_accent_color_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
profile_accent_color_id_
, String
"profile_background_custom_emoji_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
profile_background_custom_emoji_id_
]
shortShow UpdateChatPermissions
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, permissions :: Update -> Maybe ChatPermissions
permissions = Maybe ChatPermissions
permissions_
}
= String
"UpdateChatPermissions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"permissions" String -> Maybe ChatPermissions -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatPermissions
permissions_
]
shortShow UpdateChatLastMessage
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, last_message :: Update -> Maybe Message
last_message = Maybe Message
last_message_
, positions :: Update -> Maybe [ChatPosition]
positions = Maybe [ChatPosition]
positions_
}
= String
"UpdateChatLastMessage"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"last_message" String -> Maybe Message -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Message
last_message_
, String
"positions" String -> Maybe [ChatPosition] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ChatPosition]
positions_
]
shortShow UpdateChatPosition
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, position :: Update -> Maybe ChatPosition
position = Maybe ChatPosition
position_
}
= String
"UpdateChatPosition"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"position" String -> Maybe ChatPosition -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatPosition
position_
]
shortShow UpdateChatAddedToList
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, chat_list :: Update -> Maybe ChatList
chat_list = Maybe ChatList
chat_list_
}
= String
"UpdateChatAddedToList"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"chat_list" String -> Maybe ChatList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatList
chat_list_
]
shortShow UpdateChatRemovedFromList
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, chat_list :: Update -> Maybe ChatList
chat_list = Maybe ChatList
chat_list_
}
= String
"UpdateChatRemovedFromList"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"chat_list" String -> Maybe ChatList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatList
chat_list_
]
shortShow UpdateChatReadInbox
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, last_read_inbox_message_id :: Update -> Maybe Int
last_read_inbox_message_id = Maybe Int
last_read_inbox_message_id_
, unread_count :: Update -> Maybe Int
unread_count = Maybe Int
unread_count_
}
= String
"UpdateChatReadInbox"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"last_read_inbox_message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
last_read_inbox_message_id_
, String
"unread_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_count_
]
shortShow UpdateChatReadOutbox
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, last_read_outbox_message_id :: Update -> Maybe Int
last_read_outbox_message_id = Maybe Int
last_read_outbox_message_id_
}
= String
"UpdateChatReadOutbox"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"last_read_outbox_message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
last_read_outbox_message_id_
]
shortShow UpdateChatActionBar
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, action_bar :: Update -> Maybe ChatActionBar
action_bar = Maybe ChatActionBar
action_bar_
}
= String
"UpdateChatActionBar"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"action_bar" String -> Maybe ChatActionBar -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatActionBar
action_bar_
]
shortShow UpdateChatBusinessBotManageBar
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, business_bot_manage_bar :: Update -> Maybe BusinessBotManageBar
business_bot_manage_bar = Maybe BusinessBotManageBar
business_bot_manage_bar_
}
= String
"UpdateChatBusinessBotManageBar"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"business_bot_manage_bar" String -> Maybe BusinessBotManageBar -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BusinessBotManageBar
business_bot_manage_bar_
]
shortShow UpdateChatAvailableReactions
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, available_reactions :: Update -> Maybe ChatAvailableReactions
available_reactions = Maybe ChatAvailableReactions
available_reactions_
}
= String
"UpdateChatAvailableReactions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"available_reactions" String -> Maybe ChatAvailableReactions -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatAvailableReactions
available_reactions_
]
shortShow UpdateChatDraftMessage
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, draft_message :: Update -> Maybe DraftMessage
draft_message = Maybe DraftMessage
draft_message_
, positions :: Update -> Maybe [ChatPosition]
positions = Maybe [ChatPosition]
positions_
}
= String
"UpdateChatDraftMessage"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"draft_message" String -> Maybe DraftMessage -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe DraftMessage
draft_message_
, String
"positions" String -> Maybe [ChatPosition] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ChatPosition]
positions_
]
shortShow UpdateChatEmojiStatus
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, emoji_status :: Update -> Maybe EmojiStatus
emoji_status = Maybe EmojiStatus
emoji_status_
}
= String
"UpdateChatEmojiStatus"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"emoji_status" String -> Maybe EmojiStatus -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe EmojiStatus
emoji_status_
]
shortShow UpdateChatMessageSender
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_sender_id :: Update -> Maybe MessageSender
message_sender_id = Maybe MessageSender
message_sender_id_
}
= String
"UpdateChatMessageSender"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_sender_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
message_sender_id_
]
shortShow UpdateChatMessageAutoDeleteTime
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_auto_delete_time :: Update -> Maybe Int
message_auto_delete_time = Maybe Int
message_auto_delete_time_
}
= String
"UpdateChatMessageAutoDeleteTime"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_auto_delete_time" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_auto_delete_time_
]
shortShow UpdateChatNotificationSettings
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, notification_settings :: Update -> Maybe ChatNotificationSettings
notification_settings = Maybe ChatNotificationSettings
notification_settings_
}
= String
"UpdateChatNotificationSettings"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"notification_settings" String -> Maybe ChatNotificationSettings -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatNotificationSettings
notification_settings_
]
shortShow UpdateChatPendingJoinRequests
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, pending_join_requests :: Update -> Maybe ChatJoinRequestsInfo
pending_join_requests = Maybe ChatJoinRequestsInfo
pending_join_requests_
}
= String
"UpdateChatPendingJoinRequests"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"pending_join_requests" String -> Maybe ChatJoinRequestsInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatJoinRequestsInfo
pending_join_requests_
]
shortShow UpdateChatReplyMarkup
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, reply_markup_message_id :: Update -> Maybe Int
reply_markup_message_id = Maybe Int
reply_markup_message_id_
}
= String
"UpdateChatReplyMarkup"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"reply_markup_message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
reply_markup_message_id_
]
shortShow UpdateChatBackground
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, background :: Update -> Maybe ChatBackground
background = Maybe ChatBackground
background_
}
= String
"UpdateChatBackground"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"background" String -> Maybe ChatBackground -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatBackground
background_
]
shortShow UpdateChatTheme
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, theme_name :: Update -> Maybe Text
theme_name = Maybe Text
theme_name_
}
= String
"UpdateChatTheme"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"theme_name" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
theme_name_
]
shortShow UpdateChatUnreadMentionCount
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, unread_mention_count :: Update -> Maybe Int
unread_mention_count = Maybe Int
unread_mention_count_
}
= String
"UpdateChatUnreadMentionCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"unread_mention_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_mention_count_
]
shortShow UpdateChatUnreadReactionCount
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, unread_reaction_count :: Update -> Maybe Int
unread_reaction_count = Maybe Int
unread_reaction_count_
}
= String
"UpdateChatUnreadReactionCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"unread_reaction_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_reaction_count_
]
shortShow UpdateChatVideoChat
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, video_chat :: Update -> Maybe VideoChat
video_chat = Maybe VideoChat
video_chat_
}
= String
"UpdateChatVideoChat"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"video_chat" String -> Maybe VideoChat -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe VideoChat
video_chat_
]
shortShow UpdateChatDefaultDisableNotification
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, default_disable_notification :: Update -> Maybe Bool
default_disable_notification = Maybe Bool
default_disable_notification_
}
= String
"UpdateChatDefaultDisableNotification"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"default_disable_notification" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
default_disable_notification_
]
shortShow UpdateChatHasProtectedContent
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, has_protected_content :: Update -> Maybe Bool
has_protected_content = Maybe Bool
has_protected_content_
}
= String
"UpdateChatHasProtectedContent"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"has_protected_content" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
has_protected_content_
]
shortShow UpdateChatIsTranslatable
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, is_translatable :: Update -> Maybe Bool
is_translatable = Maybe Bool
is_translatable_
}
= String
"UpdateChatIsTranslatable"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"is_translatable" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_translatable_
]
shortShow UpdateChatIsMarkedAsUnread
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, is_marked_as_unread :: Update -> Maybe Bool
is_marked_as_unread = Maybe Bool
is_marked_as_unread_
}
= String
"UpdateChatIsMarkedAsUnread"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"is_marked_as_unread" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_marked_as_unread_
]
shortShow UpdateChatViewAsTopics
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, view_as_topics :: Update -> Maybe Bool
view_as_topics = Maybe Bool
view_as_topics_
}
= String
"UpdateChatViewAsTopics"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"view_as_topics" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
view_as_topics_
]
shortShow UpdateChatBlockList
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, block_list :: Update -> Maybe BlockList
block_list = Maybe BlockList
block_list_
}
= String
"UpdateChatBlockList"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"block_list" String -> Maybe BlockList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BlockList
block_list_
]
shortShow UpdateChatHasScheduledMessages
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, has_scheduled_messages :: Update -> Maybe Bool
has_scheduled_messages = Maybe Bool
has_scheduled_messages_
}
= String
"UpdateChatHasScheduledMessages"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"has_scheduled_messages" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
has_scheduled_messages_
]
shortShow UpdateChatFolders
{ chat_folders :: Update -> Maybe [ChatFolderInfo]
chat_folders = Maybe [ChatFolderInfo]
chat_folders_
, main_chat_list_position :: Update -> Maybe Int
main_chat_list_position = Maybe Int
main_chat_list_position_
, are_tags_enabled :: Update -> Maybe Bool
are_tags_enabled = Maybe Bool
are_tags_enabled_
}
= String
"UpdateChatFolders"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_folders" String -> Maybe [ChatFolderInfo] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ChatFolderInfo]
chat_folders_
, String
"main_chat_list_position" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
main_chat_list_position_
, String
"are_tags_enabled" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
are_tags_enabled_
]
shortShow UpdateChatOnlineMemberCount
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, online_member_count :: Update -> Maybe Int
online_member_count = Maybe Int
online_member_count_
}
= String
"UpdateChatOnlineMemberCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"online_member_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
online_member_count_
]
shortShow UpdateSavedMessagesTopic
{ topic :: Update -> Maybe SavedMessagesTopic
topic = Maybe SavedMessagesTopic
topic_
}
= String
"UpdateSavedMessagesTopic"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"topic" String -> Maybe SavedMessagesTopic -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe SavedMessagesTopic
topic_
]
shortShow UpdateSavedMessagesTopicCount
{ topic_count :: Update -> Maybe Int
topic_count = Maybe Int
topic_count_
}
= String
"UpdateSavedMessagesTopicCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"topic_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
topic_count_
]
shortShow UpdateQuickReplyShortcut
{ shortcut :: Update -> Maybe QuickReplyShortcut
shortcut = Maybe QuickReplyShortcut
shortcut_
}
= String
"UpdateQuickReplyShortcut"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"shortcut" String -> Maybe QuickReplyShortcut -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe QuickReplyShortcut
shortcut_
]
shortShow UpdateQuickReplyShortcutDeleted
{ shortcut_id :: Update -> Maybe Int
shortcut_id = Maybe Int
shortcut_id_
}
= String
"UpdateQuickReplyShortcutDeleted"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"shortcut_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
shortcut_id_
]
shortShow UpdateQuickReplyShortcuts
{ shortcut_ids :: Update -> Maybe [Int]
shortcut_ids = Maybe [Int]
shortcut_ids_
}
= String
"UpdateQuickReplyShortcuts"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"shortcut_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
shortcut_ids_
]
shortShow UpdateQuickReplyShortcutMessages
{ shortcut_id :: Update -> Maybe Int
shortcut_id = Maybe Int
shortcut_id_
, messages :: Update -> Maybe [QuickReplyMessage]
messages = Maybe [QuickReplyMessage]
messages_
}
= String
"UpdateQuickReplyShortcutMessages"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"shortcut_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
shortcut_id_
, String
"messages" String -> Maybe [QuickReplyMessage] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [QuickReplyMessage]
messages_
]
shortShow UpdateForumTopicInfo
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, info :: Update -> Maybe ForumTopicInfo
info = Maybe ForumTopicInfo
info_
}
= String
"UpdateForumTopicInfo"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"info" String -> Maybe ForumTopicInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ForumTopicInfo
info_
]
shortShow UpdateScopeNotificationSettings
{ scope :: Update -> Maybe NotificationSettingsScope
scope = Maybe NotificationSettingsScope
scope_
, _notification_settings :: Update -> Maybe ScopeNotificationSettings
_notification_settings = Maybe ScopeNotificationSettings
_notification_settings_
}
= String
"UpdateScopeNotificationSettings"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"scope" String -> Maybe NotificationSettingsScope -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe NotificationSettingsScope
scope_
, String
"_notification_settings" String -> Maybe ScopeNotificationSettings -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ScopeNotificationSettings
_notification_settings_
]
shortShow UpdateReactionNotificationSettings
{ __notification_settings :: Update -> Maybe ReactionNotificationSettings
__notification_settings = Maybe ReactionNotificationSettings
__notification_settings_
}
= String
"UpdateReactionNotificationSettings"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"__notification_settings" String -> Maybe ReactionNotificationSettings -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ReactionNotificationSettings
__notification_settings_
]
shortShow UpdateNotification
{ notification_group_id :: Update -> Maybe Int
notification_group_id = Maybe Int
notification_group_id_
, notification :: Update -> Maybe Notification
notification = Maybe Notification
notification_
}
= String
"UpdateNotification"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"notification_group_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
notification_group_id_
, String
"notification" String -> Maybe Notification -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Notification
notification_
]
shortShow UpdateNotificationGroup
{ notification_group_id :: Update -> Maybe Int
notification_group_id = Maybe Int
notification_group_id_
, _type :: Update -> Maybe NotificationGroupType
_type = Maybe NotificationGroupType
_type_
, chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, notification_settings_chat_id :: Update -> Maybe Int
notification_settings_chat_id = Maybe Int
notification_settings_chat_id_
, notification_sound_id :: Update -> Maybe Int
notification_sound_id = Maybe Int
notification_sound_id_
, total_count :: Update -> Maybe Int
total_count = Maybe Int
total_count_
, added_notifications :: Update -> Maybe [Notification]
added_notifications = Maybe [Notification]
added_notifications_
, removed_notification_ids :: Update -> Maybe [Int]
removed_notification_ids = Maybe [Int]
removed_notification_ids_
}
= String
"UpdateNotificationGroup"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"notification_group_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
notification_group_id_
, String
"_type" String -> Maybe NotificationGroupType -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe NotificationGroupType
_type_
, String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"notification_settings_chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
notification_settings_chat_id_
, String
"notification_sound_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
notification_sound_id_
, String
"total_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
total_count_
, String
"added_notifications" String -> Maybe [Notification] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Notification]
added_notifications_
, String
"removed_notification_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
removed_notification_ids_
]
shortShow UpdateActiveNotifications
{ groups :: Update -> Maybe [NotificationGroup]
groups = Maybe [NotificationGroup]
groups_
}
= String
"UpdateActiveNotifications"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"groups" String -> Maybe [NotificationGroup] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [NotificationGroup]
groups_
]
shortShow UpdateHavePendingNotifications
{ have_delayed_notifications :: Update -> Maybe Bool
have_delayed_notifications = Maybe Bool
have_delayed_notifications_
, have_unreceived_notifications :: Update -> Maybe Bool
have_unreceived_notifications = Maybe Bool
have_unreceived_notifications_
}
= String
"UpdateHavePendingNotifications"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"have_delayed_notifications" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
have_delayed_notifications_
, String
"have_unreceived_notifications" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
have_unreceived_notifications_
]
shortShow UpdateDeleteMessages
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_ids :: Update -> Maybe [Int]
message_ids = Maybe [Int]
message_ids_
, is_permanent :: Update -> Maybe Bool
is_permanent = Maybe Bool
is_permanent_
, from_cache :: Update -> Maybe Bool
from_cache = Maybe Bool
from_cache_
}
= String
"UpdateDeleteMessages"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
message_ids_
, String
"is_permanent" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_permanent_
, String
"from_cache" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
from_cache_
]
shortShow UpdateChatAction
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_thread_id :: Update -> Maybe Int
message_thread_id = Maybe Int
message_thread_id_
, sender_id :: Update -> Maybe MessageSender
sender_id = Maybe MessageSender
sender_id_
, action :: Update -> Maybe ChatAction
action = Maybe ChatAction
action_
}
= String
"UpdateChatAction"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_thread_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_thread_id_
, String
"sender_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
sender_id_
, String
"action" String -> Maybe ChatAction -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatAction
action_
]
shortShow UpdateUserStatus
{ user_id :: Update -> Maybe Int
user_id = Maybe Int
user_id_
, status :: Update -> Maybe UserStatus
status = Maybe UserStatus
status_
}
= String
"UpdateUserStatus"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
user_id_
, String
"status" String -> Maybe UserStatus -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe UserStatus
status_
]
shortShow UpdateUser
{ user :: Update -> Maybe User
user = Maybe User
user_
}
= String
"UpdateUser"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"user" String -> Maybe User -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe User
user_
]
shortShow UpdateBasicGroup
{ basic_group :: Update -> Maybe BasicGroup
basic_group = Maybe BasicGroup
basic_group_
}
= String
"UpdateBasicGroup"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"basic_group" String -> Maybe BasicGroup -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BasicGroup
basic_group_
]
shortShow UpdateSupergroup
{ supergroup :: Update -> Maybe Supergroup
supergroup = Maybe Supergroup
supergroup_
}
= String
"UpdateSupergroup"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"supergroup" String -> Maybe Supergroup -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Supergroup
supergroup_
]
shortShow UpdateSecretChat
{ secret_chat :: Update -> Maybe SecretChat
secret_chat = Maybe SecretChat
secret_chat_
}
= String
"UpdateSecretChat"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"secret_chat" String -> Maybe SecretChat -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe SecretChat
secret_chat_
]
shortShow UpdateUserFullInfo
{ user_id :: Update -> Maybe Int
user_id = Maybe Int
user_id_
, user_full_info :: Update -> Maybe UserFullInfo
user_full_info = Maybe UserFullInfo
user_full_info_
}
= String
"UpdateUserFullInfo"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
user_id_
, String
"user_full_info" String -> Maybe UserFullInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe UserFullInfo
user_full_info_
]
shortShow UpdateBasicGroupFullInfo
{ basic_group_id :: Update -> Maybe Int
basic_group_id = Maybe Int
basic_group_id_
, basic_group_full_info :: Update -> Maybe BasicGroupFullInfo
basic_group_full_info = Maybe BasicGroupFullInfo
basic_group_full_info_
}
= String
"UpdateBasicGroupFullInfo"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"basic_group_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
basic_group_id_
, String
"basic_group_full_info" String -> Maybe BasicGroupFullInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BasicGroupFullInfo
basic_group_full_info_
]
shortShow UpdateSupergroupFullInfo
{ supergroup_id :: Update -> Maybe Int
supergroup_id = Maybe Int
supergroup_id_
, supergroup_full_info :: Update -> Maybe SupergroupFullInfo
supergroup_full_info = Maybe SupergroupFullInfo
supergroup_full_info_
}
= String
"UpdateSupergroupFullInfo"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"supergroup_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
supergroup_id_
, String
"supergroup_full_info" String -> Maybe SupergroupFullInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe SupergroupFullInfo
supergroup_full_info_
]
shortShow UpdateServiceNotification
{ __type :: Update -> Maybe Text
__type = Maybe Text
__type_
, content :: Update -> Maybe MessageContent
content = Maybe MessageContent
content_
}
= String
"UpdateServiceNotification"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"__type" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
__type_
, String
"content" String -> Maybe MessageContent -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageContent
content_
]
shortShow UpdateFile
{ file :: Update -> Maybe File
file = Maybe File
file_
}
= String
"UpdateFile"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"file" String -> Maybe File -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe File
file_
]
shortShow UpdateFileGenerationStart
{ generation_id :: Update -> Maybe Int
generation_id = Maybe Int
generation_id_
, original_path :: Update -> Maybe Text
original_path = Maybe Text
original_path_
, destination_path :: Update -> Maybe Text
destination_path = Maybe Text
destination_path_
, conversion :: Update -> Maybe Text
conversion = Maybe Text
conversion_
}
= String
"UpdateFileGenerationStart"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"generation_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
generation_id_
, String
"original_path" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
original_path_
, String
"destination_path" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
destination_path_
, String
"conversion" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
conversion_
]
shortShow UpdateFileGenerationStop
{ generation_id :: Update -> Maybe Int
generation_id = Maybe Int
generation_id_
}
= String
"UpdateFileGenerationStop"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"generation_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
generation_id_
]
shortShow UpdateFileDownloads
{ total_size :: Update -> Maybe Int
total_size = Maybe Int
total_size_
, total_count :: Update -> Maybe Int
total_count = Maybe Int
total_count_
, downloaded_size :: Update -> Maybe Int
downloaded_size = Maybe Int
downloaded_size_
}
= String
"UpdateFileDownloads"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"total_size" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
total_size_
, String
"total_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
total_count_
, String
"downloaded_size" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
downloaded_size_
]
shortShow UpdateFileAddedToDownloads
{ file_download :: Update -> Maybe FileDownload
file_download = Maybe FileDownload
file_download_
, counts :: Update -> Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
= String
"UpdateFileAddedToDownloads"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"file_download" String -> Maybe FileDownload -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe FileDownload
file_download_
, String
"counts" String -> Maybe DownloadedFileCounts -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe DownloadedFileCounts
counts_
]
shortShow UpdateFileDownload
{ file_id :: Update -> Maybe Int
file_id = Maybe Int
file_id_
, complete_date :: Update -> Maybe Int
complete_date = Maybe Int
complete_date_
, is_paused :: Update -> Maybe Bool
is_paused = Maybe Bool
is_paused_
, counts :: Update -> Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
= String
"UpdateFileDownload"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"file_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
file_id_
, String
"complete_date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
complete_date_
, String
"is_paused" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_paused_
, String
"counts" String -> Maybe DownloadedFileCounts -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe DownloadedFileCounts
counts_
]
shortShow UpdateFileRemovedFromDownloads
{ file_id :: Update -> Maybe Int
file_id = Maybe Int
file_id_
, counts :: Update -> Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
= String
"UpdateFileRemovedFromDownloads"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"file_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
file_id_
, String
"counts" String -> Maybe DownloadedFileCounts -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe DownloadedFileCounts
counts_
]
shortShow UpdateApplicationVerificationRequired
{ verification_id :: Update -> Maybe Int
verification_id = Maybe Int
verification_id_
, nonce :: Update -> Maybe Text
nonce = Maybe Text
nonce_
, cloud_project_number :: Update -> Maybe Int
cloud_project_number = Maybe Int
cloud_project_number_
}
= String
"UpdateApplicationVerificationRequired"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"verification_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
verification_id_
, String
"nonce" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
nonce_
, String
"cloud_project_number" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
cloud_project_number_
]
shortShow UpdateCall
{ call :: Update -> Maybe Call
call = Maybe Call
call_
}
= String
"UpdateCall"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"call" String -> Maybe Call -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Call
call_
]
shortShow UpdateGroupCall
{ group_call :: Update -> Maybe GroupCall
group_call = Maybe GroupCall
group_call_
}
= String
"UpdateGroupCall"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"group_call" String -> Maybe GroupCall -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe GroupCall
group_call_
]
shortShow UpdateGroupCallParticipant
{ group_call_id :: Update -> Maybe Int
group_call_id = Maybe Int
group_call_id_
, participant :: Update -> Maybe GroupCallParticipant
participant = Maybe GroupCallParticipant
participant_
}
= String
"UpdateGroupCallParticipant"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"group_call_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
group_call_id_
, String
"participant" String -> Maybe GroupCallParticipant -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe GroupCallParticipant
participant_
]
shortShow UpdateNewCallSignalingData
{ call_id :: Update -> Maybe Int
call_id = Maybe Int
call_id_
, _data :: Update -> Maybe ByteString
_data = Maybe ByteString
_data_
}
= String
"UpdateNewCallSignalingData"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"call_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
call_id_
, String
"_data" String -> Maybe ByteString -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ByteString
_data_
]
shortShow UpdateUserPrivacySettingRules
{ setting :: Update -> Maybe UserPrivacySetting
setting = Maybe UserPrivacySetting
setting_
, rules :: Update -> Maybe UserPrivacySettingRules
rules = Maybe UserPrivacySettingRules
rules_
}
= String
"UpdateUserPrivacySettingRules"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"setting" String -> Maybe UserPrivacySetting -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe UserPrivacySetting
setting_
, String
"rules" String -> Maybe UserPrivacySettingRules -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe UserPrivacySettingRules
rules_
]
shortShow UpdateUnreadMessageCount
{ chat_list :: Update -> Maybe ChatList
chat_list = Maybe ChatList
chat_list_
, unread_count :: Update -> Maybe Int
unread_count = Maybe Int
unread_count_
, unread_unmuted_count :: Update -> Maybe Int
unread_unmuted_count = Maybe Int
unread_unmuted_count_
}
= String
"UpdateUnreadMessageCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_list" String -> Maybe ChatList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatList
chat_list_
, String
"unread_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_count_
, String
"unread_unmuted_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_unmuted_count_
]
shortShow UpdateUnreadChatCount
{ chat_list :: Update -> Maybe ChatList
chat_list = Maybe ChatList
chat_list_
, total_count :: Update -> Maybe Int
total_count = Maybe Int
total_count_
, unread_count :: Update -> Maybe Int
unread_count = Maybe Int
unread_count_
, unread_unmuted_count :: Update -> Maybe Int
unread_unmuted_count = Maybe Int
unread_unmuted_count_
, marked_as_unread_count :: Update -> Maybe Int
marked_as_unread_count = Maybe Int
marked_as_unread_count_
, marked_as_unread_unmuted_count :: Update -> Maybe Int
marked_as_unread_unmuted_count = Maybe Int
marked_as_unread_unmuted_count_
}
= String
"UpdateUnreadChatCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_list" String -> Maybe ChatList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatList
chat_list_
, String
"total_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
total_count_
, String
"unread_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_count_
, String
"unread_unmuted_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
unread_unmuted_count_
, String
"marked_as_unread_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
marked_as_unread_count_
, String
"marked_as_unread_unmuted_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
marked_as_unread_unmuted_count_
]
shortShow UpdateStory
{ story :: Update -> Maybe Story
story = Maybe Story
story_
}
= String
"UpdateStory"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"story" String -> Maybe Story -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Story
story_
]
shortShow UpdateStoryDeleted
{ story_sender_chat_id :: Update -> Maybe Int
story_sender_chat_id = Maybe Int
story_sender_chat_id_
, story_id :: Update -> Maybe Int
story_id = Maybe Int
story_id_
}
= String
"UpdateStoryDeleted"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"story_sender_chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
story_sender_chat_id_
, String
"story_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
story_id_
]
shortShow UpdateStorySendSucceeded
{ story :: Update -> Maybe Story
story = Maybe Story
story_
, old_story_id :: Update -> Maybe Int
old_story_id = Maybe Int
old_story_id_
}
= String
"UpdateStorySendSucceeded"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"story" String -> Maybe Story -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Story
story_
, String
"old_story_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
old_story_id_
]
shortShow UpdateStorySendFailed
{ story :: Update -> Maybe Story
story = Maybe Story
story_
, _error :: Update -> Maybe Error
_error = Maybe Error
_error_
, error_type :: Update -> Maybe CanSendStoryResult
error_type = Maybe CanSendStoryResult
error_type_
}
= String
"UpdateStorySendFailed"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"story" String -> Maybe Story -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Story
story_
, String
"_error" String -> Maybe Error -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Error
_error_
, String
"error_type" String -> Maybe CanSendStoryResult -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe CanSendStoryResult
error_type_
]
shortShow UpdateChatActiveStories
{ active_stories :: Update -> Maybe ChatActiveStories
active_stories = Maybe ChatActiveStories
active_stories_
}
= String
"UpdateChatActiveStories"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"active_stories" String -> Maybe ChatActiveStories -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatActiveStories
active_stories_
]
shortShow UpdateStoryListChatCount
{ story_list :: Update -> Maybe StoryList
story_list = Maybe StoryList
story_list_
, chat_count :: Update -> Maybe Int
chat_count = Maybe Int
chat_count_
}
= String
"UpdateStoryListChatCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"story_list" String -> Maybe StoryList -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe StoryList
story_list_
, String
"chat_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_count_
]
shortShow UpdateStoryStealthMode
{ active_until_date :: Update -> Maybe Int
active_until_date = Maybe Int
active_until_date_
, cooldown_until_date :: Update -> Maybe Int
cooldown_until_date = Maybe Int
cooldown_until_date_
}
= String
"UpdateStoryStealthMode"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"active_until_date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
active_until_date_
, String
"cooldown_until_date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
cooldown_until_date_
]
shortShow UpdateOption
{ name :: Update -> Maybe Text
name = Maybe Text
name_
, value :: Update -> Maybe OptionValue
value = Maybe OptionValue
value_
}
= String
"UpdateOption"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"name" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
name_
, String
"value" String -> Maybe OptionValue -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe OptionValue
value_
]
shortShow UpdateStickerSet
{ sticker_set :: Update -> Maybe StickerSet
sticker_set = Maybe StickerSet
sticker_set_
}
= String
"UpdateStickerSet"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"sticker_set" String -> Maybe StickerSet -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe StickerSet
sticker_set_
]
shortShow UpdateInstalledStickerSets
{ sticker_type :: Update -> Maybe StickerType
sticker_type = Maybe StickerType
sticker_type_
, sticker_set_ids :: Update -> Maybe [Int]
sticker_set_ids = Maybe [Int]
sticker_set_ids_
}
= String
"UpdateInstalledStickerSets"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"sticker_type" String -> Maybe StickerType -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe StickerType
sticker_type_
, String
"sticker_set_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
sticker_set_ids_
]
shortShow UpdateTrendingStickerSets
{ sticker_type :: Update -> Maybe StickerType
sticker_type = Maybe StickerType
sticker_type_
, sticker_sets :: Update -> Maybe TrendingStickerSets
sticker_sets = Maybe TrendingStickerSets
sticker_sets_
}
= String
"UpdateTrendingStickerSets"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"sticker_type" String -> Maybe StickerType -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe StickerType
sticker_type_
, String
"sticker_sets" String -> Maybe TrendingStickerSets -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe TrendingStickerSets
sticker_sets_
]
shortShow UpdateRecentStickers
{ is_attached :: Update -> Maybe Bool
is_attached = Maybe Bool
is_attached_
, sticker_ids :: Update -> Maybe [Int]
sticker_ids = Maybe [Int]
sticker_ids_
}
= String
"UpdateRecentStickers"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"is_attached" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_attached_
, String
"sticker_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
sticker_ids_
]
shortShow UpdateFavoriteStickers
{ sticker_ids :: Update -> Maybe [Int]
sticker_ids = Maybe [Int]
sticker_ids_
}
= String
"UpdateFavoriteStickers"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"sticker_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
sticker_ids_
]
shortShow UpdateSavedAnimations
{ animation_ids :: Update -> Maybe [Int]
animation_ids = Maybe [Int]
animation_ids_
}
= String
"UpdateSavedAnimations"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"animation_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
animation_ids_
]
shortShow UpdateSavedNotificationSounds
{ notification_sound_ids :: Update -> Maybe [Int]
notification_sound_ids = Maybe [Int]
notification_sound_ids_
}
= String
"UpdateSavedNotificationSounds"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"notification_sound_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
notification_sound_ids_
]
shortShow UpdateDefaultBackground
{ for_dark_theme :: Update -> Maybe Bool
for_dark_theme = Maybe Bool
for_dark_theme_
, _background :: Update -> Maybe Background
_background = Maybe Background
_background_
}
= String
"UpdateDefaultBackground"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"for_dark_theme" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
for_dark_theme_
, String
"_background" String -> Maybe Background -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Background
_background_
]
shortShow UpdateChatThemes
{ chat_themes :: Update -> Maybe [ChatTheme]
chat_themes = Maybe [ChatTheme]
chat_themes_
}
= String
"UpdateChatThemes"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_themes" String -> Maybe [ChatTheme] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ChatTheme]
chat_themes_
]
shortShow UpdateAccentColors
{ colors :: Update -> Maybe [AccentColor]
colors = Maybe [AccentColor]
colors_
, available_accent_color_ids :: Update -> Maybe [Int]
available_accent_color_ids = Maybe [Int]
available_accent_color_ids_
}
= String
"UpdateAccentColors"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"colors" String -> Maybe [AccentColor] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [AccentColor]
colors_
, String
"available_accent_color_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
available_accent_color_ids_
]
shortShow UpdateProfileAccentColors
{ _colors :: Update -> Maybe [ProfileAccentColor]
_colors = Maybe [ProfileAccentColor]
_colors_
, available_accent_color_ids :: Update -> Maybe [Int]
available_accent_color_ids = Maybe [Int]
available_accent_color_ids_
}
= String
"UpdateProfileAccentColors"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_colors" String -> Maybe [ProfileAccentColor] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ProfileAccentColor]
_colors_
, String
"available_accent_color_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
available_accent_color_ids_
]
shortShow UpdateLanguagePackStrings
{ localization_target :: Update -> Maybe Text
localization_target = Maybe Text
localization_target_
, language_pack_id :: Update -> Maybe Text
language_pack_id = Maybe Text
language_pack_id_
, strings :: Update -> Maybe [LanguagePackString]
strings = Maybe [LanguagePackString]
strings_
}
= String
"UpdateLanguagePackStrings"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"localization_target" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
localization_target_
, String
"language_pack_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
language_pack_id_
, String
"strings" String -> Maybe [LanguagePackString] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [LanguagePackString]
strings_
]
shortShow UpdateConnectionState
{ state :: Update -> Maybe ConnectionState
state = Maybe ConnectionState
state_
}
= String
"UpdateConnectionState"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"state" String -> Maybe ConnectionState -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ConnectionState
state_
]
shortShow UpdateTermsOfService
{ terms_of_service_id :: Update -> Maybe Text
terms_of_service_id = Maybe Text
terms_of_service_id_
, terms_of_service :: Update -> Maybe TermsOfService
terms_of_service = Maybe TermsOfService
terms_of_service_
}
= String
"UpdateTermsOfService"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"terms_of_service_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
terms_of_service_id_
, String
"terms_of_service" String -> Maybe TermsOfService -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe TermsOfService
terms_of_service_
]
shortShow UpdateUnconfirmedSession
{ session :: Update -> Maybe UnconfirmedSession
session = Maybe UnconfirmedSession
session_
}
= String
"UpdateUnconfirmedSession"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"session" String -> Maybe UnconfirmedSession -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe UnconfirmedSession
session_
]
shortShow UpdateAttachmentMenuBots
{ bots :: Update -> Maybe [AttachmentMenuBot]
bots = Maybe [AttachmentMenuBot]
bots_
}
= String
"UpdateAttachmentMenuBots"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"bots" String -> Maybe [AttachmentMenuBot] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [AttachmentMenuBot]
bots_
]
shortShow UpdateWebAppMessageSent
{ web_app_launch_id :: Update -> Maybe Int
web_app_launch_id = Maybe Int
web_app_launch_id_
}
= String
"UpdateWebAppMessageSent"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"web_app_launch_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
web_app_launch_id_
]
shortShow UpdateActiveEmojiReactions
{ emojis :: Update -> Maybe [Text]
emojis = Maybe [Text]
emojis_
}
= String
"UpdateActiveEmojiReactions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"emojis" String -> Maybe [Text] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Text]
emojis_
]
shortShow UpdateAvailableMessageEffects
{ reaction_effect_ids :: Update -> Maybe [Int]
reaction_effect_ids = Maybe [Int]
reaction_effect_ids_
, sticker_effect_ids :: Update -> Maybe [Int]
sticker_effect_ids = Maybe [Int]
sticker_effect_ids_
}
= String
"UpdateAvailableMessageEffects"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"reaction_effect_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
reaction_effect_ids_
, String
"sticker_effect_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
sticker_effect_ids_
]
shortShow UpdateDefaultReactionType
{ reaction_type :: Update -> Maybe ReactionType
reaction_type = Maybe ReactionType
reaction_type_
}
= String
"UpdateDefaultReactionType"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"reaction_type" String -> Maybe ReactionType -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ReactionType
reaction_type_
]
shortShow UpdateSavedMessagesTags
{ saved_messages_topic_id :: Update -> Maybe Int
saved_messages_topic_id = Maybe Int
saved_messages_topic_id_
, tags :: Update -> Maybe SavedMessagesTags
tags = Maybe SavedMessagesTags
tags_
}
= String
"UpdateSavedMessagesTags"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"saved_messages_topic_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
saved_messages_topic_id_
, String
"tags" String -> Maybe SavedMessagesTags -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe SavedMessagesTags
tags_
]
shortShow UpdateActiveLiveLocationMessages
{ _messages :: Update -> Maybe [Message]
_messages = Maybe [Message]
_messages_
}
= String
"UpdateActiveLiveLocationMessages"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_messages" String -> Maybe [Message] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Message]
_messages_
]
shortShow UpdateOwnedStarCount
{ star_count :: Update -> Maybe Int
star_count = Maybe Int
star_count_
}
= String
"UpdateOwnedStarCount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"star_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
star_count_
]
shortShow UpdateChatRevenueAmount
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, revenue_amount :: Update -> Maybe ChatRevenueAmount
revenue_amount = Maybe ChatRevenueAmount
revenue_amount_
}
= String
"UpdateChatRevenueAmount"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"revenue_amount" String -> Maybe ChatRevenueAmount -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatRevenueAmount
revenue_amount_
]
shortShow UpdateStarRevenueStatus
{ owner_id :: Update -> Maybe MessageSender
owner_id = Maybe MessageSender
owner_id_
, _status :: Update -> Maybe StarRevenueStatus
_status = Maybe StarRevenueStatus
_status_
}
= String
"UpdateStarRevenueStatus"
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_
, String
"_status" String -> Maybe StarRevenueStatus -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe StarRevenueStatus
_status_
]
shortShow UpdateSpeechRecognitionTrial
{ max_media_duration :: Update -> Maybe Int
max_media_duration = Maybe Int
max_media_duration_
, weekly_count :: Update -> Maybe Int
weekly_count = Maybe Int
weekly_count_
, left_count :: Update -> Maybe Int
left_count = Maybe Int
left_count_
, next_reset_date :: Update -> Maybe Int
next_reset_date = Maybe Int
next_reset_date_
}
= String
"UpdateSpeechRecognitionTrial"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"max_media_duration" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
max_media_duration_
, String
"weekly_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
weekly_count_
, String
"left_count" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
left_count_
, String
"next_reset_date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
next_reset_date_
]
shortShow UpdateDiceEmojis
{ emojis :: Update -> Maybe [Text]
emojis = Maybe [Text]
emojis_
}
= String
"UpdateDiceEmojis"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"emojis" String -> Maybe [Text] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Text]
emojis_
]
shortShow UpdateAnimatedEmojiMessageClicked
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, sticker :: Update -> Maybe Sticker
sticker = Maybe Sticker
sticker_
}
= String
"UpdateAnimatedEmojiMessageClicked"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"sticker" String -> Maybe Sticker -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Sticker
sticker_
]
shortShow UpdateAnimationSearchParameters
{ provider :: Update -> Maybe Text
provider = Maybe Text
provider_
, emojis :: Update -> Maybe [Text]
emojis = Maybe [Text]
emojis_
}
= String
"UpdateAnimationSearchParameters"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"provider" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
provider_
, String
"emojis" String -> Maybe [Text] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Text]
emojis_
]
shortShow UpdateSuggestedActions
{ added_actions :: Update -> Maybe [SuggestedAction]
added_actions = Maybe [SuggestedAction]
added_actions_
, removed_actions :: Update -> Maybe [SuggestedAction]
removed_actions = Maybe [SuggestedAction]
removed_actions_
}
= String
"UpdateSuggestedActions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"added_actions" String -> Maybe [SuggestedAction] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [SuggestedAction]
added_actions_
, String
"removed_actions" String -> Maybe [SuggestedAction] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [SuggestedAction]
removed_actions_
]
shortShow UpdateSpeedLimitNotification
{ is_upload :: Update -> Maybe Bool
is_upload = Maybe Bool
is_upload_
}
= String
"UpdateSpeedLimitNotification"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"is_upload" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_upload_
]
shortShow UpdateContactCloseBirthdays
{ close_birthday_users :: Update -> Maybe [CloseBirthdayUser]
close_birthday_users = Maybe [CloseBirthdayUser]
close_birthday_users_
}
= String
"UpdateContactCloseBirthdays"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"close_birthday_users" String -> Maybe [CloseBirthdayUser] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [CloseBirthdayUser]
close_birthday_users_
]
shortShow UpdateAutosaveSettings
{ _scope :: Update -> Maybe AutosaveSettingsScope
_scope = Maybe AutosaveSettingsScope
_scope_
, settings :: Update -> Maybe ScopeAutosaveSettings
settings = Maybe ScopeAutosaveSettings
settings_
}
= String
"UpdateAutosaveSettings"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_scope" String -> Maybe AutosaveSettingsScope -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe AutosaveSettingsScope
_scope_
, String
"settings" String -> Maybe ScopeAutosaveSettings -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ScopeAutosaveSettings
settings_
]
shortShow UpdateBusinessConnection
{ connection :: Update -> Maybe BusinessConnection
connection = Maybe BusinessConnection
connection_
}
= String
"UpdateBusinessConnection"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"connection" String -> Maybe BusinessConnection -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BusinessConnection
connection_
]
shortShow UpdateNewBusinessMessage
{ connection_id :: Update -> Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Update -> Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
}
= String
"UpdateNewBusinessMessage"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"connection_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
connection_id_
, String
"_message" String -> Maybe BusinessMessage -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BusinessMessage
_message_
]
shortShow UpdateBusinessMessageEdited
{ connection_id :: Update -> Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Update -> Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
}
= String
"UpdateBusinessMessageEdited"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"connection_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
connection_id_
, String
"_message" String -> Maybe BusinessMessage -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BusinessMessage
_message_
]
shortShow UpdateBusinessMessagesDeleted
{ connection_id :: Update -> Maybe Text
connection_id = Maybe Text
connection_id_
, chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_ids :: Update -> Maybe [Int]
message_ids = Maybe [Int]
message_ids_
}
= String
"UpdateBusinessMessagesDeleted"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"connection_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
connection_id_
, String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
message_ids_
]
shortShow UpdateNewInlineQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, user_location :: Update -> Maybe Location
user_location = Maybe Location
user_location_
, chat_type :: Update -> Maybe ChatType
chat_type = Maybe ChatType
chat_type_
, query :: Update -> Maybe Text
query = Maybe Text
query_
, offset :: Update -> Maybe Text
offset = Maybe Text
offset_
}
= String
"UpdateNewInlineQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"user_location" String -> Maybe Location -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Location
user_location_
, String
"chat_type" String -> Maybe ChatType -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatType
chat_type_
, String
"query" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
query_
, String
"offset" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
offset_
]
shortShow UpdateNewChosenInlineResult
{ sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, user_location :: Update -> Maybe Location
user_location = Maybe Location
user_location_
, query :: Update -> Maybe Text
query = Maybe Text
query_
, result_id :: Update -> Maybe Text
result_id = Maybe Text
result_id_
, inline_message_id :: Update -> Maybe Text
inline_message_id = Maybe Text
inline_message_id_
}
= String
"UpdateNewChosenInlineResult"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"user_location" String -> Maybe Location -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Location
user_location_
, String
"query" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
query_
, String
"result_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
result_id_
, String
"inline_message_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
inline_message_id_
]
shortShow UpdateNewCallbackQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, chat_instance :: Update -> Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Update -> Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
= String
"UpdateNewCallbackQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"chat_instance" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_instance_
, String
"payload" String -> Maybe CallbackQueryPayload -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe CallbackQueryPayload
payload_
]
shortShow UpdateNewInlineCallbackQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, inline_message_id :: Update -> Maybe Text
inline_message_id = Maybe Text
inline_message_id_
, chat_instance :: Update -> Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Update -> Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
= String
"UpdateNewInlineCallbackQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"inline_message_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
inline_message_id_
, String
"chat_instance" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_instance_
, String
"payload" String -> Maybe CallbackQueryPayload -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe CallbackQueryPayload
payload_
]
shortShow UpdateNewBusinessCallbackQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, connection_id :: Update -> Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Update -> Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
, chat_instance :: Update -> Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Update -> Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
= String
"UpdateNewBusinessCallbackQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"connection_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
connection_id_
, String
"_message" String -> Maybe BusinessMessage -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe BusinessMessage
_message_
, String
"chat_instance" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_instance_
, String
"payload" String -> Maybe CallbackQueryPayload -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe CallbackQueryPayload
payload_
]
shortShow UpdateNewShippingQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, invoice_payload :: Update -> Maybe Text
invoice_payload = Maybe Text
invoice_payload_
, shipping_address :: Update -> Maybe Address
shipping_address = Maybe Address
shipping_address_
}
= String
"UpdateNewShippingQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"invoice_payload" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
invoice_payload_
, String
"shipping_address" String -> Maybe Address -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Address
shipping_address_
]
shortShow UpdateNewPreCheckoutQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Update -> Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, currency :: Update -> Maybe Text
currency = Maybe Text
currency_
, total_amount :: Update -> Maybe Int
total_amount = Maybe Int
total_amount_
, _invoice_payload :: Update -> Maybe ByteString
_invoice_payload = Maybe ByteString
_invoice_payload_
, shipping_option_id :: Update -> Maybe Text
shipping_option_id = Maybe Text
shipping_option_id_
, order_info :: Update -> Maybe OrderInfo
order_info = Maybe OrderInfo
order_info_
}
= String
"UpdateNewPreCheckoutQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"sender_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
sender_user_id_
, String
"currency" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
currency_
, String
"total_amount" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
total_amount_
, String
"_invoice_payload" String -> Maybe ByteString -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ByteString
_invoice_payload_
, String
"shipping_option_id" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
shipping_option_id_
, String
"order_info" String -> Maybe OrderInfo -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe OrderInfo
order_info_
]
shortShow UpdateNewCustomEvent
{ event :: Update -> Maybe Text
event = Maybe Text
event_
}
= String
"UpdateNewCustomEvent"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"event" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
event_
]
shortShow UpdateNewCustomQuery
{ _id :: Update -> Maybe Int
_id = Maybe Int
_id_
, __data :: Update -> Maybe Text
__data = Maybe Text
__data_
, timeout :: Update -> Maybe Int
timeout = Maybe Int
timeout_
}
= String
"UpdateNewCustomQuery"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
_id_
, String
"__data" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
__data_
, String
"timeout" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
timeout_
]
shortShow UpdatePoll
{ poll :: Update -> Maybe Poll
poll = Maybe Poll
poll_
}
= String
"UpdatePoll"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"poll" String -> Maybe Poll -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Poll
poll_
]
shortShow UpdatePollAnswer
{ poll_id :: Update -> Maybe Int
poll_id = Maybe Int
poll_id_
, voter_id :: Update -> Maybe MessageSender
voter_id = Maybe MessageSender
voter_id_
, option_ids :: Update -> Maybe [Int]
option_ids = Maybe [Int]
option_ids_
}
= String
"UpdatePollAnswer"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"poll_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
poll_id_
, String
"voter_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
voter_id_
, String
"option_ids" String -> Maybe [Int] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [Int]
option_ids_
]
shortShow UpdateChatMember
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, actor_user_id :: Update -> Maybe Int
actor_user_id = Maybe Int
actor_user_id_
, date :: Update -> Maybe Int
date = Maybe Int
date_
, invite_link :: Update -> Maybe ChatInviteLink
invite_link = Maybe ChatInviteLink
invite_link_
, via_join_request :: Update -> Maybe Bool
via_join_request = Maybe Bool
via_join_request_
, via_chat_folder_invite_link :: Update -> Maybe Bool
via_chat_folder_invite_link = Maybe Bool
via_chat_folder_invite_link_
, old_chat_member :: Update -> Maybe ChatMember
old_chat_member = Maybe ChatMember
old_chat_member_
, new_chat_member :: Update -> Maybe ChatMember
new_chat_member = Maybe ChatMember
new_chat_member_
}
= String
"UpdateChatMember"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"actor_user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
actor_user_id_
, String
"date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
date_
, String
"invite_link" String -> Maybe ChatInviteLink -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatInviteLink
invite_link_
, String
"via_join_request" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
via_join_request_
, String
"via_chat_folder_invite_link" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
via_chat_folder_invite_link_
, String
"old_chat_member" String -> Maybe ChatMember -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatMember
old_chat_member_
, String
"new_chat_member" String -> Maybe ChatMember -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatMember
new_chat_member_
]
shortShow UpdateNewChatJoinRequest
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, request :: Update -> Maybe ChatJoinRequest
request = Maybe ChatJoinRequest
request_
, user_chat_id :: Update -> Maybe Int
user_chat_id = Maybe Int
user_chat_id_
, invite_link :: Update -> Maybe ChatInviteLink
invite_link = Maybe ChatInviteLink
invite_link_
}
= String
"UpdateNewChatJoinRequest"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"request" String -> Maybe ChatJoinRequest -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatJoinRequest
request_
, String
"user_chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
user_chat_id_
, String
"invite_link" String -> Maybe ChatInviteLink -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatInviteLink
invite_link_
]
shortShow UpdateChatBoost
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, boost :: Update -> Maybe ChatBoost
boost = Maybe ChatBoost
boost_
}
= String
"UpdateChatBoost"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"boost" String -> Maybe ChatBoost -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe ChatBoost
boost_
]
shortShow UpdateMessageReaction
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, actor_id :: Update -> Maybe MessageSender
actor_id = Maybe MessageSender
actor_id_
, date :: Update -> Maybe Int
date = Maybe Int
date_
, old_reaction_types :: Update -> Maybe [ReactionType]
old_reaction_types = Maybe [ReactionType]
old_reaction_types_
, new_reaction_types :: Update -> Maybe [ReactionType]
new_reaction_types = Maybe [ReactionType]
new_reaction_types_
}
= String
"UpdateMessageReaction"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"actor_id" String -> Maybe MessageSender -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe MessageSender
actor_id_
, String
"date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
date_
, String
"old_reaction_types" String -> Maybe [ReactionType] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ReactionType]
old_reaction_types_
, String
"new_reaction_types" String -> Maybe [ReactionType] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [ReactionType]
new_reaction_types_
]
shortShow UpdateMessageReactions
{ chat_id :: Update -> Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Update -> Maybe Int
message_id = Maybe Int
message_id_
, date :: Update -> Maybe Int
date = Maybe Int
date_
, reactions :: Update -> Maybe [MessageReaction]
reactions = Maybe [MessageReaction]
reactions_
}
= String
"UpdateMessageReactions"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"chat_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
chat_id_
, String
"message_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
message_id_
, String
"date" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
date_
, String
"reactions" String -> Maybe [MessageReaction] -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe [MessageReaction]
reactions_
]
shortShow UpdatePaidMediaPurchased
{ user_id :: Update -> Maybe Int
user_id = Maybe Int
user_id_
, _payload :: Update -> Maybe Text
_payload = Maybe Text
_payload_
}
= String
"UpdatePaidMediaPurchased"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"user_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
user_id_
, String
"_payload" String -> Maybe Text -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Text
_payload_
]
instance AT.FromJSON Update where
parseJSON :: Value -> Parser Update
parseJSON v :: Value
v@(AT.Object Object
obj) = do
String
t <- Object
obj Object -> Key -> Parser String
forall a. FromJSON a => Object -> Key -> Parser a
A..: Key
"@type" :: AT.Parser String
case String
t of
String
"updateAuthorizationState" -> Value -> Parser Update
parseUpdateAuthorizationState Value
v
String
"updateNewMessage" -> Value -> Parser Update
parseUpdateNewMessage Value
v
String
"updateMessageSendAcknowledged" -> Value -> Parser Update
parseUpdateMessageSendAcknowledged Value
v
String
"updateMessageSendSucceeded" -> Value -> Parser Update
parseUpdateMessageSendSucceeded Value
v
String
"updateMessageSendFailed" -> Value -> Parser Update
parseUpdateMessageSendFailed Value
v
String
"updateMessageContent" -> Value -> Parser Update
parseUpdateMessageContent Value
v
String
"updateMessageEdited" -> Value -> Parser Update
parseUpdateMessageEdited Value
v
String
"updateMessageIsPinned" -> Value -> Parser Update
parseUpdateMessageIsPinned Value
v
String
"updateMessageInteractionInfo" -> Value -> Parser Update
parseUpdateMessageInteractionInfo Value
v
String
"updateMessageContentOpened" -> Value -> Parser Update
parseUpdateMessageContentOpened Value
v
String
"updateMessageMentionRead" -> Value -> Parser Update
parseUpdateMessageMentionRead Value
v
String
"updateMessageUnreadReactions" -> Value -> Parser Update
parseUpdateMessageUnreadReactions Value
v
String
"updateMessageFactCheck" -> Value -> Parser Update
parseUpdateMessageFactCheck Value
v
String
"updateMessageLiveLocationViewed" -> Value -> Parser Update
parseUpdateMessageLiveLocationViewed Value
v
String
"updateNewChat" -> Value -> Parser Update
parseUpdateNewChat Value
v
String
"updateChatTitle" -> Value -> Parser Update
parseUpdateChatTitle Value
v
String
"updateChatPhoto" -> Value -> Parser Update
parseUpdateChatPhoto Value
v
String
"updateChatAccentColors" -> Value -> Parser Update
parseUpdateChatAccentColors Value
v
String
"updateChatPermissions" -> Value -> Parser Update
parseUpdateChatPermissions Value
v
String
"updateChatLastMessage" -> Value -> Parser Update
parseUpdateChatLastMessage Value
v
String
"updateChatPosition" -> Value -> Parser Update
parseUpdateChatPosition Value
v
String
"updateChatAddedToList" -> Value -> Parser Update
parseUpdateChatAddedToList Value
v
String
"updateChatRemovedFromList" -> Value -> Parser Update
parseUpdateChatRemovedFromList Value
v
String
"updateChatReadInbox" -> Value -> Parser Update
parseUpdateChatReadInbox Value
v
String
"updateChatReadOutbox" -> Value -> Parser Update
parseUpdateChatReadOutbox Value
v
String
"updateChatActionBar" -> Value -> Parser Update
parseUpdateChatActionBar Value
v
String
"updateChatBusinessBotManageBar" -> Value -> Parser Update
parseUpdateChatBusinessBotManageBar Value
v
String
"updateChatAvailableReactions" -> Value -> Parser Update
parseUpdateChatAvailableReactions Value
v
String
"updateChatDraftMessage" -> Value -> Parser Update
parseUpdateChatDraftMessage Value
v
String
"updateChatEmojiStatus" -> Value -> Parser Update
parseUpdateChatEmojiStatus Value
v
String
"updateChatMessageSender" -> Value -> Parser Update
parseUpdateChatMessageSender Value
v
String
"updateChatMessageAutoDeleteTime" -> Value -> Parser Update
parseUpdateChatMessageAutoDeleteTime Value
v
String
"updateChatNotificationSettings" -> Value -> Parser Update
parseUpdateChatNotificationSettings Value
v
String
"updateChatPendingJoinRequests" -> Value -> Parser Update
parseUpdateChatPendingJoinRequests Value
v
String
"updateChatReplyMarkup" -> Value -> Parser Update
parseUpdateChatReplyMarkup Value
v
String
"updateChatBackground" -> Value -> Parser Update
parseUpdateChatBackground Value
v
String
"updateChatTheme" -> Value -> Parser Update
parseUpdateChatTheme Value
v
String
"updateChatUnreadMentionCount" -> Value -> Parser Update
parseUpdateChatUnreadMentionCount Value
v
String
"updateChatUnreadReactionCount" -> Value -> Parser Update
parseUpdateChatUnreadReactionCount Value
v
String
"updateChatVideoChat" -> Value -> Parser Update
parseUpdateChatVideoChat Value
v
String
"updateChatDefaultDisableNotification" -> Value -> Parser Update
parseUpdateChatDefaultDisableNotification Value
v
String
"updateChatHasProtectedContent" -> Value -> Parser Update
parseUpdateChatHasProtectedContent Value
v
String
"updateChatIsTranslatable" -> Value -> Parser Update
parseUpdateChatIsTranslatable Value
v
String
"updateChatIsMarkedAsUnread" -> Value -> Parser Update
parseUpdateChatIsMarkedAsUnread Value
v
String
"updateChatViewAsTopics" -> Value -> Parser Update
parseUpdateChatViewAsTopics Value
v
String
"updateChatBlockList" -> Value -> Parser Update
parseUpdateChatBlockList Value
v
String
"updateChatHasScheduledMessages" -> Value -> Parser Update
parseUpdateChatHasScheduledMessages Value
v
String
"updateChatFolders" -> Value -> Parser Update
parseUpdateChatFolders Value
v
String
"updateChatOnlineMemberCount" -> Value -> Parser Update
parseUpdateChatOnlineMemberCount Value
v
String
"updateSavedMessagesTopic" -> Value -> Parser Update
parseUpdateSavedMessagesTopic Value
v
String
"updateSavedMessagesTopicCount" -> Value -> Parser Update
parseUpdateSavedMessagesTopicCount Value
v
String
"updateQuickReplyShortcut" -> Value -> Parser Update
parseUpdateQuickReplyShortcut Value
v
String
"updateQuickReplyShortcutDeleted" -> Value -> Parser Update
parseUpdateQuickReplyShortcutDeleted Value
v
String
"updateQuickReplyShortcuts" -> Value -> Parser Update
parseUpdateQuickReplyShortcuts Value
v
String
"updateQuickReplyShortcutMessages" -> Value -> Parser Update
parseUpdateQuickReplyShortcutMessages Value
v
String
"updateForumTopicInfo" -> Value -> Parser Update
parseUpdateForumTopicInfo Value
v
String
"updateScopeNotificationSettings" -> Value -> Parser Update
parseUpdateScopeNotificationSettings Value
v
String
"updateReactionNotificationSettings" -> Value -> Parser Update
parseUpdateReactionNotificationSettings Value
v
String
"updateNotification" -> Value -> Parser Update
parseUpdateNotification Value
v
String
"updateNotificationGroup" -> Value -> Parser Update
parseUpdateNotificationGroup Value
v
String
"updateActiveNotifications" -> Value -> Parser Update
parseUpdateActiveNotifications Value
v
String
"updateHavePendingNotifications" -> Value -> Parser Update
parseUpdateHavePendingNotifications Value
v
String
"updateDeleteMessages" -> Value -> Parser Update
parseUpdateDeleteMessages Value
v
String
"updateChatAction" -> Value -> Parser Update
parseUpdateChatAction Value
v
String
"updateUserStatus" -> Value -> Parser Update
parseUpdateUserStatus Value
v
String
"updateUser" -> Value -> Parser Update
parseUpdateUser Value
v
String
"updateBasicGroup" -> Value -> Parser Update
parseUpdateBasicGroup Value
v
String
"updateSupergroup" -> Value -> Parser Update
parseUpdateSupergroup Value
v
String
"updateSecretChat" -> Value -> Parser Update
parseUpdateSecretChat Value
v
String
"updateUserFullInfo" -> Value -> Parser Update
parseUpdateUserFullInfo Value
v
String
"updateBasicGroupFullInfo" -> Value -> Parser Update
parseUpdateBasicGroupFullInfo Value
v
String
"updateSupergroupFullInfo" -> Value -> Parser Update
parseUpdateSupergroupFullInfo Value
v
String
"updateServiceNotification" -> Value -> Parser Update
parseUpdateServiceNotification Value
v
String
"updateFile" -> Value -> Parser Update
parseUpdateFile Value
v
String
"updateFileGenerationStart" -> Value -> Parser Update
parseUpdateFileGenerationStart Value
v
String
"updateFileGenerationStop" -> Value -> Parser Update
parseUpdateFileGenerationStop Value
v
String
"updateFileDownloads" -> Value -> Parser Update
parseUpdateFileDownloads Value
v
String
"updateFileAddedToDownloads" -> Value -> Parser Update
parseUpdateFileAddedToDownloads Value
v
String
"updateFileDownload" -> Value -> Parser Update
parseUpdateFileDownload Value
v
String
"updateFileRemovedFromDownloads" -> Value -> Parser Update
parseUpdateFileRemovedFromDownloads Value
v
String
"updateApplicationVerificationRequired" -> Value -> Parser Update
parseUpdateApplicationVerificationRequired Value
v
String
"updateCall" -> Value -> Parser Update
parseUpdateCall Value
v
String
"updateGroupCall" -> Value -> Parser Update
parseUpdateGroupCall Value
v
String
"updateGroupCallParticipant" -> Value -> Parser Update
parseUpdateGroupCallParticipant Value
v
String
"updateNewCallSignalingData" -> Value -> Parser Update
parseUpdateNewCallSignalingData Value
v
String
"updateUserPrivacySettingRules" -> Value -> Parser Update
parseUpdateUserPrivacySettingRules Value
v
String
"updateUnreadMessageCount" -> Value -> Parser Update
parseUpdateUnreadMessageCount Value
v
String
"updateUnreadChatCount" -> Value -> Parser Update
parseUpdateUnreadChatCount Value
v
String
"updateStory" -> Value -> Parser Update
parseUpdateStory Value
v
String
"updateStoryDeleted" -> Value -> Parser Update
parseUpdateStoryDeleted Value
v
String
"updateStorySendSucceeded" -> Value -> Parser Update
parseUpdateStorySendSucceeded Value
v
String
"updateStorySendFailed" -> Value -> Parser Update
parseUpdateStorySendFailed Value
v
String
"updateChatActiveStories" -> Value -> Parser Update
parseUpdateChatActiveStories Value
v
String
"updateStoryListChatCount" -> Value -> Parser Update
parseUpdateStoryListChatCount Value
v
String
"updateStoryStealthMode" -> Value -> Parser Update
parseUpdateStoryStealthMode Value
v
String
"updateOption" -> Value -> Parser Update
parseUpdateOption Value
v
String
"updateStickerSet" -> Value -> Parser Update
parseUpdateStickerSet Value
v
String
"updateInstalledStickerSets" -> Value -> Parser Update
parseUpdateInstalledStickerSets Value
v
String
"updateTrendingStickerSets" -> Value -> Parser Update
parseUpdateTrendingStickerSets Value
v
String
"updateRecentStickers" -> Value -> Parser Update
parseUpdateRecentStickers Value
v
String
"updateFavoriteStickers" -> Value -> Parser Update
parseUpdateFavoriteStickers Value
v
String
"updateSavedAnimations" -> Value -> Parser Update
parseUpdateSavedAnimations Value
v
String
"updateSavedNotificationSounds" -> Value -> Parser Update
parseUpdateSavedNotificationSounds Value
v
String
"updateDefaultBackground" -> Value -> Parser Update
parseUpdateDefaultBackground Value
v
String
"updateChatThemes" -> Value -> Parser Update
parseUpdateChatThemes Value
v
String
"updateAccentColors" -> Value -> Parser Update
parseUpdateAccentColors Value
v
String
"updateProfileAccentColors" -> Value -> Parser Update
parseUpdateProfileAccentColors Value
v
String
"updateLanguagePackStrings" -> Value -> Parser Update
parseUpdateLanguagePackStrings Value
v
String
"updateConnectionState" -> Value -> Parser Update
parseUpdateConnectionState Value
v
String
"updateTermsOfService" -> Value -> Parser Update
parseUpdateTermsOfService Value
v
String
"updateUnconfirmedSession" -> Value -> Parser Update
parseUpdateUnconfirmedSession Value
v
String
"updateAttachmentMenuBots" -> Value -> Parser Update
parseUpdateAttachmentMenuBots Value
v
String
"updateWebAppMessageSent" -> Value -> Parser Update
parseUpdateWebAppMessageSent Value
v
String
"updateActiveEmojiReactions" -> Value -> Parser Update
parseUpdateActiveEmojiReactions Value
v
String
"updateAvailableMessageEffects" -> Value -> Parser Update
parseUpdateAvailableMessageEffects Value
v
String
"updateDefaultReactionType" -> Value -> Parser Update
parseUpdateDefaultReactionType Value
v
String
"updateSavedMessagesTags" -> Value -> Parser Update
parseUpdateSavedMessagesTags Value
v
String
"updateActiveLiveLocationMessages" -> Value -> Parser Update
parseUpdateActiveLiveLocationMessages Value
v
String
"updateOwnedStarCount" -> Value -> Parser Update
parseUpdateOwnedStarCount Value
v
String
"updateChatRevenueAmount" -> Value -> Parser Update
parseUpdateChatRevenueAmount Value
v
String
"updateStarRevenueStatus" -> Value -> Parser Update
parseUpdateStarRevenueStatus Value
v
String
"updateSpeechRecognitionTrial" -> Value -> Parser Update
parseUpdateSpeechRecognitionTrial Value
v
String
"updateDiceEmojis" -> Value -> Parser Update
parseUpdateDiceEmojis Value
v
String
"updateAnimatedEmojiMessageClicked" -> Value -> Parser Update
parseUpdateAnimatedEmojiMessageClicked Value
v
String
"updateAnimationSearchParameters" -> Value -> Parser Update
parseUpdateAnimationSearchParameters Value
v
String
"updateSuggestedActions" -> Value -> Parser Update
parseUpdateSuggestedActions Value
v
String
"updateSpeedLimitNotification" -> Value -> Parser Update
parseUpdateSpeedLimitNotification Value
v
String
"updateContactCloseBirthdays" -> Value -> Parser Update
parseUpdateContactCloseBirthdays Value
v
String
"updateAutosaveSettings" -> Value -> Parser Update
parseUpdateAutosaveSettings Value
v
String
"updateBusinessConnection" -> Value -> Parser Update
parseUpdateBusinessConnection Value
v
String
"updateNewBusinessMessage" -> Value -> Parser Update
parseUpdateNewBusinessMessage Value
v
String
"updateBusinessMessageEdited" -> Value -> Parser Update
parseUpdateBusinessMessageEdited Value
v
String
"updateBusinessMessagesDeleted" -> Value -> Parser Update
parseUpdateBusinessMessagesDeleted Value
v
String
"updateNewInlineQuery" -> Value -> Parser Update
parseUpdateNewInlineQuery Value
v
String
"updateNewChosenInlineResult" -> Value -> Parser Update
parseUpdateNewChosenInlineResult Value
v
String
"updateNewCallbackQuery" -> Value -> Parser Update
parseUpdateNewCallbackQuery Value
v
String
"updateNewInlineCallbackQuery" -> Value -> Parser Update
parseUpdateNewInlineCallbackQuery Value
v
String
"updateNewBusinessCallbackQuery" -> Value -> Parser Update
parseUpdateNewBusinessCallbackQuery Value
v
String
"updateNewShippingQuery" -> Value -> Parser Update
parseUpdateNewShippingQuery Value
v
String
"updateNewPreCheckoutQuery" -> Value -> Parser Update
parseUpdateNewPreCheckoutQuery Value
v
String
"updateNewCustomEvent" -> Value -> Parser Update
parseUpdateNewCustomEvent Value
v
String
"updateNewCustomQuery" -> Value -> Parser Update
parseUpdateNewCustomQuery Value
v
String
"updatePoll" -> Value -> Parser Update
parseUpdatePoll Value
v
String
"updatePollAnswer" -> Value -> Parser Update
parseUpdatePollAnswer Value
v
String
"updateChatMember" -> Value -> Parser Update
parseUpdateChatMember Value
v
String
"updateNewChatJoinRequest" -> Value -> Parser Update
parseUpdateNewChatJoinRequest Value
v
String
"updateChatBoost" -> Value -> Parser Update
parseUpdateChatBoost Value
v
String
"updateMessageReaction" -> Value -> Parser Update
parseUpdateMessageReaction Value
v
String
"updateMessageReactions" -> Value -> Parser Update
parseUpdateMessageReactions Value
v
String
"updatePaidMediaPurchased" -> Value -> Parser Update
parseUpdatePaidMediaPurchased Value
v
String
_ -> Parser Update
forall a. Monoid a => a
mempty
where
parseUpdateAuthorizationState :: A.Value -> AT.Parser Update
parseUpdateAuthorizationState :: Value -> Parser Update
parseUpdateAuthorizationState = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAuthorizationState" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe AuthorizationState
authorization_state_ <- Object
o Object -> Key -> Parser (Maybe AuthorizationState)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"authorization_state"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAuthorizationState
{ authorization_state :: Maybe AuthorizationState
authorization_state = Maybe AuthorizationState
authorization_state_
}
parseUpdateNewMessage :: A.Value -> AT.Parser Update
parseUpdateNewMessage :: Value -> Parser Update
parseUpdateNewMessage = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewMessage" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Message
message_ <- Object
o Object -> Key -> Parser (Maybe Message)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewMessage
{ message :: Maybe Message
message = Maybe Message
message_
}
parseUpdateMessageSendAcknowledged :: A.Value -> AT.Parser Update
parseUpdateMessageSendAcknowledged :: Value -> Parser Update
parseUpdateMessageSendAcknowledged = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageSendAcknowledged" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageSendAcknowledged
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
}
parseUpdateMessageSendSucceeded :: A.Value -> AT.Parser Update
parseUpdateMessageSendSucceeded :: Value -> Parser Update
parseUpdateMessageSendSucceeded = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageSendSucceeded" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Message
message_ <- Object
o Object -> Key -> Parser (Maybe Message)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Maybe Int
old_message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"old_message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageSendSucceeded
{ message :: Maybe Message
message = Maybe Message
message_
, old_message_id :: Maybe Int
old_message_id = Maybe Int
old_message_id_
}
parseUpdateMessageSendFailed :: A.Value -> AT.Parser Update
parseUpdateMessageSendFailed :: Value -> Parser Update
parseUpdateMessageSendFailed = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageSendFailed" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Message
message_ <- Object
o Object -> Key -> Parser (Maybe Message)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Maybe Int
old_message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"old_message_id"
Maybe Error
_error_ <- Object
o Object -> Key -> Parser (Maybe Error)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"error"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageSendFailed
{ message :: Maybe Message
message = Maybe Message
message_
, old_message_id :: Maybe Int
old_message_id = Maybe Int
old_message_id_
, _error :: Maybe Error
_error = Maybe Error
_error_
}
parseUpdateMessageContent :: A.Value -> AT.Parser Update
parseUpdateMessageContent :: Value -> Parser Update
parseUpdateMessageContent = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageContent" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe MessageContent
new_content_ <- Object
o Object -> Key -> Parser (Maybe MessageContent)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"new_content"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageContent
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, new_content :: Maybe MessageContent
new_content = Maybe MessageContent
new_content_
}
parseUpdateMessageEdited :: A.Value -> AT.Parser Update
parseUpdateMessageEdited :: Value -> Parser Update
parseUpdateMessageEdited = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageEdited" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Int
edit_date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"edit_date"
Maybe ReplyMarkup
reply_markup_ <- Object
o Object -> Key -> Parser (Maybe ReplyMarkup)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"reply_markup"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageEdited
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, edit_date :: Maybe Int
edit_date = Maybe Int
edit_date_
, reply_markup :: Maybe ReplyMarkup
reply_markup = Maybe ReplyMarkup
reply_markup_
}
parseUpdateMessageIsPinned :: A.Value -> AT.Parser Update
parseUpdateMessageIsPinned :: Value -> Parser Update
parseUpdateMessageIsPinned = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageIsPinned" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Bool
is_pinned_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_pinned"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageIsPinned
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, is_pinned :: Maybe Bool
is_pinned = Maybe Bool
is_pinned_
}
parseUpdateMessageInteractionInfo :: A.Value -> AT.Parser Update
parseUpdateMessageInteractionInfo :: Value -> Parser Update
parseUpdateMessageInteractionInfo = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageInteractionInfo" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe MessageInteractionInfo
interaction_info_ <- Object
o Object -> Key -> Parser (Maybe MessageInteractionInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"interaction_info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageInteractionInfo
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, interaction_info :: Maybe MessageInteractionInfo
interaction_info = Maybe MessageInteractionInfo
interaction_info_
}
parseUpdateMessageContentOpened :: A.Value -> AT.Parser Update
parseUpdateMessageContentOpened :: Value -> Parser Update
parseUpdateMessageContentOpened = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageContentOpened" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageContentOpened
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
}
parseUpdateMessageMentionRead :: A.Value -> AT.Parser Update
parseUpdateMessageMentionRead :: Value -> Parser Update
parseUpdateMessageMentionRead = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageMentionRead" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Int
unread_mention_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_mention_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageMentionRead
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, unread_mention_count :: Maybe Int
unread_mention_count = Maybe Int
unread_mention_count_
}
parseUpdateMessageUnreadReactions :: A.Value -> AT.Parser Update
parseUpdateMessageUnreadReactions :: Value -> Parser Update
parseUpdateMessageUnreadReactions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageUnreadReactions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe [UnreadReaction]
unread_reactions_ <- Object
o Object -> Key -> Parser (Maybe [UnreadReaction])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_reactions"
Maybe Int
unread_reaction_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_reaction_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageUnreadReactions
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, unread_reactions :: Maybe [UnreadReaction]
unread_reactions = Maybe [UnreadReaction]
unread_reactions_
, unread_reaction_count :: Maybe Int
unread_reaction_count = Maybe Int
unread_reaction_count_
}
parseUpdateMessageFactCheck :: A.Value -> AT.Parser Update
parseUpdateMessageFactCheck :: Value -> Parser Update
parseUpdateMessageFactCheck = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageFactCheck" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe FactCheck
fact_check_ <- Object
o Object -> Key -> Parser (Maybe FactCheck)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"fact_check"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageFactCheck
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, fact_check :: Maybe FactCheck
fact_check = Maybe FactCheck
fact_check_
}
parseUpdateMessageLiveLocationViewed :: A.Value -> AT.Parser Update
parseUpdateMessageLiveLocationViewed :: Value -> Parser Update
parseUpdateMessageLiveLocationViewed = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageLiveLocationViewed" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageLiveLocationViewed
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
}
parseUpdateNewChat :: A.Value -> AT.Parser Update
parseUpdateNewChat :: Value -> Parser Update
parseUpdateNewChat = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewChat" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Chat
chat_ <- Object
o Object -> Key -> Parser (Maybe Chat)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewChat
{ chat :: Maybe Chat
chat = Maybe Chat
chat_
}
parseUpdateChatTitle :: A.Value -> AT.Parser Update
parseUpdateChatTitle :: Value -> Parser Update
parseUpdateChatTitle = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatTitle" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Text
title_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"title"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatTitle
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, title :: Maybe Text
title = Maybe Text
title_
}
parseUpdateChatPhoto :: A.Value -> AT.Parser Update
parseUpdateChatPhoto :: Value -> Parser Update
parseUpdateChatPhoto = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatPhoto" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatPhotoInfo
photo_ <- Object
o Object -> Key -> Parser (Maybe ChatPhotoInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"photo"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatPhoto
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, photo :: Maybe ChatPhotoInfo
photo = Maybe ChatPhotoInfo
photo_
}
parseUpdateChatAccentColors :: A.Value -> AT.Parser Update
parseUpdateChatAccentColors :: Value -> Parser Update
parseUpdateChatAccentColors = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatAccentColors" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
accent_color_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"accent_color_id"
Maybe Int
background_custom_emoji_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"background_custom_emoji_id"
Maybe Int
profile_accent_color_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"profile_accent_color_id"
Maybe Int
profile_background_custom_emoji_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"profile_background_custom_emoji_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatAccentColors
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, accent_color_id :: Maybe Int
accent_color_id = Maybe Int
accent_color_id_
, background_custom_emoji_id :: Maybe Int
background_custom_emoji_id = Maybe Int
background_custom_emoji_id_
, profile_accent_color_id :: Maybe Int
profile_accent_color_id = Maybe Int
profile_accent_color_id_
, profile_background_custom_emoji_id :: Maybe Int
profile_background_custom_emoji_id = Maybe Int
profile_background_custom_emoji_id_
}
parseUpdateChatPermissions :: A.Value -> AT.Parser Update
parseUpdateChatPermissions :: Value -> Parser Update
parseUpdateChatPermissions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatPermissions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatPermissions
permissions_ <- Object
o Object -> Key -> Parser (Maybe ChatPermissions)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"permissions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatPermissions
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, permissions :: Maybe ChatPermissions
permissions = Maybe ChatPermissions
permissions_
}
parseUpdateChatLastMessage :: A.Value -> AT.Parser Update
parseUpdateChatLastMessage :: Value -> Parser Update
parseUpdateChatLastMessage = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatLastMessage" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Message
last_message_ <- Object
o Object -> Key -> Parser (Maybe Message)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"last_message"
Maybe [ChatPosition]
positions_ <- Object
o Object -> Key -> Parser (Maybe [ChatPosition])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"positions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatLastMessage
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, last_message :: Maybe Message
last_message = Maybe Message
last_message_
, positions :: Maybe [ChatPosition]
positions = Maybe [ChatPosition]
positions_
}
parseUpdateChatPosition :: A.Value -> AT.Parser Update
parseUpdateChatPosition :: Value -> Parser Update
parseUpdateChatPosition = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatPosition" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatPosition
position_ <- Object
o Object -> Key -> Parser (Maybe ChatPosition)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"position"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatPosition
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, position :: Maybe ChatPosition
position = Maybe ChatPosition
position_
}
parseUpdateChatAddedToList :: A.Value -> AT.Parser Update
parseUpdateChatAddedToList :: Value -> Parser Update
parseUpdateChatAddedToList = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatAddedToList" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatList
chat_list_ <- Object
o Object -> Key -> Parser (Maybe ChatList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_list"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatAddedToList
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, chat_list :: Maybe ChatList
chat_list = Maybe ChatList
chat_list_
}
parseUpdateChatRemovedFromList :: A.Value -> AT.Parser Update
parseUpdateChatRemovedFromList :: Value -> Parser Update
parseUpdateChatRemovedFromList = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatRemovedFromList" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatList
chat_list_ <- Object
o Object -> Key -> Parser (Maybe ChatList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_list"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatRemovedFromList
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, chat_list :: Maybe ChatList
chat_list = Maybe ChatList
chat_list_
}
parseUpdateChatReadInbox :: A.Value -> AT.Parser Update
parseUpdateChatReadInbox :: Value -> Parser Update
parseUpdateChatReadInbox = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatReadInbox" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
last_read_inbox_message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"last_read_inbox_message_id"
Maybe Int
unread_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatReadInbox
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, last_read_inbox_message_id :: Maybe Int
last_read_inbox_message_id = Maybe Int
last_read_inbox_message_id_
, unread_count :: Maybe Int
unread_count = Maybe Int
unread_count_
}
parseUpdateChatReadOutbox :: A.Value -> AT.Parser Update
parseUpdateChatReadOutbox :: Value -> Parser Update
parseUpdateChatReadOutbox = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatReadOutbox" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
last_read_outbox_message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"last_read_outbox_message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatReadOutbox
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, last_read_outbox_message_id :: Maybe Int
last_read_outbox_message_id = Maybe Int
last_read_outbox_message_id_
}
parseUpdateChatActionBar :: A.Value -> AT.Parser Update
parseUpdateChatActionBar :: Value -> Parser Update
parseUpdateChatActionBar = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatActionBar" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatActionBar
action_bar_ <- Object
o Object -> Key -> Parser (Maybe ChatActionBar)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"action_bar"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatActionBar
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, action_bar :: Maybe ChatActionBar
action_bar = Maybe ChatActionBar
action_bar_
}
parseUpdateChatBusinessBotManageBar :: A.Value -> AT.Parser Update
parseUpdateChatBusinessBotManageBar :: Value -> Parser Update
parseUpdateChatBusinessBotManageBar = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatBusinessBotManageBar" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe BusinessBotManageBar
business_bot_manage_bar_ <- Object
o Object -> Key -> Parser (Maybe BusinessBotManageBar)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"business_bot_manage_bar"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatBusinessBotManageBar
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, business_bot_manage_bar :: Maybe BusinessBotManageBar
business_bot_manage_bar = Maybe BusinessBotManageBar
business_bot_manage_bar_
}
parseUpdateChatAvailableReactions :: A.Value -> AT.Parser Update
parseUpdateChatAvailableReactions :: Value -> Parser Update
parseUpdateChatAvailableReactions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatAvailableReactions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatAvailableReactions
available_reactions_ <- Object
o Object -> Key -> Parser (Maybe ChatAvailableReactions)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"available_reactions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatAvailableReactions
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, available_reactions :: Maybe ChatAvailableReactions
available_reactions = Maybe ChatAvailableReactions
available_reactions_
}
parseUpdateChatDraftMessage :: A.Value -> AT.Parser Update
parseUpdateChatDraftMessage :: Value -> Parser Update
parseUpdateChatDraftMessage = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatDraftMessage" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe DraftMessage
draft_message_ <- Object
o Object -> Key -> Parser (Maybe DraftMessage)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"draft_message"
Maybe [ChatPosition]
positions_ <- Object
o Object -> Key -> Parser (Maybe [ChatPosition])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"positions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatDraftMessage
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, draft_message :: Maybe DraftMessage
draft_message = Maybe DraftMessage
draft_message_
, positions :: Maybe [ChatPosition]
positions = Maybe [ChatPosition]
positions_
}
parseUpdateChatEmojiStatus :: A.Value -> AT.Parser Update
parseUpdateChatEmojiStatus :: Value -> Parser Update
parseUpdateChatEmojiStatus = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatEmojiStatus" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe EmojiStatus
emoji_status_ <- Object
o Object -> Key -> Parser (Maybe EmojiStatus)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"emoji_status"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatEmojiStatus
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, emoji_status :: Maybe EmojiStatus
emoji_status = Maybe EmojiStatus
emoji_status_
}
parseUpdateChatMessageSender :: A.Value -> AT.Parser Update
parseUpdateChatMessageSender :: Value -> Parser Update
parseUpdateChatMessageSender = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatMessageSender" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe MessageSender
message_sender_id_ <- Object
o Object -> Key -> Parser (Maybe MessageSender)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_sender_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatMessageSender
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_sender_id :: Maybe MessageSender
message_sender_id = Maybe MessageSender
message_sender_id_
}
parseUpdateChatMessageAutoDeleteTime :: A.Value -> AT.Parser Update
parseUpdateChatMessageAutoDeleteTime :: Value -> Parser Update
parseUpdateChatMessageAutoDeleteTime = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatMessageAutoDeleteTime" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_auto_delete_time_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_auto_delete_time"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatMessageAutoDeleteTime
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_auto_delete_time :: Maybe Int
message_auto_delete_time = Maybe Int
message_auto_delete_time_
}
parseUpdateChatNotificationSettings :: A.Value -> AT.Parser Update
parseUpdateChatNotificationSettings :: Value -> Parser Update
parseUpdateChatNotificationSettings = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatNotificationSettings" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatNotificationSettings
notification_settings_ <- Object
o Object -> Key -> Parser (Maybe ChatNotificationSettings)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_settings"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatNotificationSettings
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, notification_settings :: Maybe ChatNotificationSettings
notification_settings = Maybe ChatNotificationSettings
notification_settings_
}
parseUpdateChatPendingJoinRequests :: A.Value -> AT.Parser Update
parseUpdateChatPendingJoinRequests :: Value -> Parser Update
parseUpdateChatPendingJoinRequests = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatPendingJoinRequests" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatJoinRequestsInfo
pending_join_requests_ <- Object
o Object -> Key -> Parser (Maybe ChatJoinRequestsInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"pending_join_requests"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatPendingJoinRequests
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, pending_join_requests :: Maybe ChatJoinRequestsInfo
pending_join_requests = Maybe ChatJoinRequestsInfo
pending_join_requests_
}
parseUpdateChatReplyMarkup :: A.Value -> AT.Parser Update
parseUpdateChatReplyMarkup :: Value -> Parser Update
parseUpdateChatReplyMarkup = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatReplyMarkup" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
reply_markup_message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"reply_markup_message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatReplyMarkup
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, reply_markup_message_id :: Maybe Int
reply_markup_message_id = Maybe Int
reply_markup_message_id_
}
parseUpdateChatBackground :: A.Value -> AT.Parser Update
parseUpdateChatBackground :: Value -> Parser Update
parseUpdateChatBackground = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatBackground" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatBackground
background_ <- Object
o Object -> Key -> Parser (Maybe ChatBackground)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"background"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatBackground
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, background :: Maybe ChatBackground
background = Maybe ChatBackground
background_
}
parseUpdateChatTheme :: A.Value -> AT.Parser Update
parseUpdateChatTheme :: Value -> Parser Update
parseUpdateChatTheme = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatTheme" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Text
theme_name_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"theme_name"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatTheme
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, theme_name :: Maybe Text
theme_name = Maybe Text
theme_name_
}
parseUpdateChatUnreadMentionCount :: A.Value -> AT.Parser Update
parseUpdateChatUnreadMentionCount :: Value -> Parser Update
parseUpdateChatUnreadMentionCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatUnreadMentionCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
unread_mention_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_mention_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatUnreadMentionCount
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, unread_mention_count :: Maybe Int
unread_mention_count = Maybe Int
unread_mention_count_
}
parseUpdateChatUnreadReactionCount :: A.Value -> AT.Parser Update
parseUpdateChatUnreadReactionCount :: Value -> Parser Update
parseUpdateChatUnreadReactionCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatUnreadReactionCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
unread_reaction_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_reaction_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatUnreadReactionCount
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, unread_reaction_count :: Maybe Int
unread_reaction_count = Maybe Int
unread_reaction_count_
}
parseUpdateChatVideoChat :: A.Value -> AT.Parser Update
parseUpdateChatVideoChat :: Value -> Parser Update
parseUpdateChatVideoChat = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatVideoChat" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe VideoChat
video_chat_ <- Object
o Object -> Key -> Parser (Maybe VideoChat)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"video_chat"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatVideoChat
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, video_chat :: Maybe VideoChat
video_chat = Maybe VideoChat
video_chat_
}
parseUpdateChatDefaultDisableNotification :: A.Value -> AT.Parser Update
parseUpdateChatDefaultDisableNotification :: Value -> Parser Update
parseUpdateChatDefaultDisableNotification = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatDefaultDisableNotification" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
default_disable_notification_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"default_disable_notification"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatDefaultDisableNotification
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, default_disable_notification :: Maybe Bool
default_disable_notification = Maybe Bool
default_disable_notification_
}
parseUpdateChatHasProtectedContent :: A.Value -> AT.Parser Update
parseUpdateChatHasProtectedContent :: Value -> Parser Update
parseUpdateChatHasProtectedContent = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatHasProtectedContent" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
has_protected_content_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"has_protected_content"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatHasProtectedContent
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, has_protected_content :: Maybe Bool
has_protected_content = Maybe Bool
has_protected_content_
}
parseUpdateChatIsTranslatable :: A.Value -> AT.Parser Update
parseUpdateChatIsTranslatable :: Value -> Parser Update
parseUpdateChatIsTranslatable = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatIsTranslatable" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
is_translatable_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_translatable"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatIsTranslatable
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, is_translatable :: Maybe Bool
is_translatable = Maybe Bool
is_translatable_
}
parseUpdateChatIsMarkedAsUnread :: A.Value -> AT.Parser Update
parseUpdateChatIsMarkedAsUnread :: Value -> Parser Update
parseUpdateChatIsMarkedAsUnread = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatIsMarkedAsUnread" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
is_marked_as_unread_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_marked_as_unread"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatIsMarkedAsUnread
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, is_marked_as_unread :: Maybe Bool
is_marked_as_unread = Maybe Bool
is_marked_as_unread_
}
parseUpdateChatViewAsTopics :: A.Value -> AT.Parser Update
parseUpdateChatViewAsTopics :: Value -> Parser Update
parseUpdateChatViewAsTopics = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatViewAsTopics" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
view_as_topics_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"view_as_topics"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatViewAsTopics
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, view_as_topics :: Maybe Bool
view_as_topics = Maybe Bool
view_as_topics_
}
parseUpdateChatBlockList :: A.Value -> AT.Parser Update
parseUpdateChatBlockList :: Value -> Parser Update
parseUpdateChatBlockList = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatBlockList" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe BlockList
block_list_ <- Object
o Object -> Key -> Parser (Maybe BlockList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"block_list"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatBlockList
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, block_list :: Maybe BlockList
block_list = Maybe BlockList
block_list_
}
parseUpdateChatHasScheduledMessages :: A.Value -> AT.Parser Update
parseUpdateChatHasScheduledMessages :: Value -> Parser Update
parseUpdateChatHasScheduledMessages = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatHasScheduledMessages" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Bool
has_scheduled_messages_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"has_scheduled_messages"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatHasScheduledMessages
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, has_scheduled_messages :: Maybe Bool
has_scheduled_messages = Maybe Bool
has_scheduled_messages_
}
parseUpdateChatFolders :: A.Value -> AT.Parser Update
parseUpdateChatFolders :: Value -> Parser Update
parseUpdateChatFolders = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatFolders" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [ChatFolderInfo]
chat_folders_ <- Object
o Object -> Key -> Parser (Maybe [ChatFolderInfo])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_folders"
Maybe Int
main_chat_list_position_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"main_chat_list_position"
Maybe Bool
are_tags_enabled_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"are_tags_enabled"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatFolders
{ chat_folders :: Maybe [ChatFolderInfo]
chat_folders = Maybe [ChatFolderInfo]
chat_folders_
, main_chat_list_position :: Maybe Int
main_chat_list_position = Maybe Int
main_chat_list_position_
, are_tags_enabled :: Maybe Bool
are_tags_enabled = Maybe Bool
are_tags_enabled_
}
parseUpdateChatOnlineMemberCount :: A.Value -> AT.Parser Update
parseUpdateChatOnlineMemberCount :: Value -> Parser Update
parseUpdateChatOnlineMemberCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatOnlineMemberCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
online_member_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"online_member_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatOnlineMemberCount
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, online_member_count :: Maybe Int
online_member_count = Maybe Int
online_member_count_
}
parseUpdateSavedMessagesTopic :: A.Value -> AT.Parser Update
parseUpdateSavedMessagesTopic :: Value -> Parser Update
parseUpdateSavedMessagesTopic = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSavedMessagesTopic" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe SavedMessagesTopic
topic_ <- Object
o Object -> Key -> Parser (Maybe SavedMessagesTopic)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"topic"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSavedMessagesTopic
{ topic :: Maybe SavedMessagesTopic
topic = Maybe SavedMessagesTopic
topic_
}
parseUpdateSavedMessagesTopicCount :: A.Value -> AT.Parser Update
parseUpdateSavedMessagesTopicCount :: Value -> Parser Update
parseUpdateSavedMessagesTopicCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSavedMessagesTopicCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
topic_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"topic_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSavedMessagesTopicCount
{ topic_count :: Maybe Int
topic_count = Maybe Int
topic_count_
}
parseUpdateQuickReplyShortcut :: A.Value -> AT.Parser Update
parseUpdateQuickReplyShortcut :: Value -> Parser Update
parseUpdateQuickReplyShortcut = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateQuickReplyShortcut" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe QuickReplyShortcut
shortcut_ <- Object
o Object -> Key -> Parser (Maybe QuickReplyShortcut)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shortcut"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateQuickReplyShortcut
{ shortcut :: Maybe QuickReplyShortcut
shortcut = Maybe QuickReplyShortcut
shortcut_
}
parseUpdateQuickReplyShortcutDeleted :: A.Value -> AT.Parser Update
parseUpdateQuickReplyShortcutDeleted :: Value -> Parser Update
parseUpdateQuickReplyShortcutDeleted = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateQuickReplyShortcutDeleted" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
shortcut_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shortcut_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateQuickReplyShortcutDeleted
{ shortcut_id :: Maybe Int
shortcut_id = Maybe Int
shortcut_id_
}
parseUpdateQuickReplyShortcuts :: A.Value -> AT.Parser Update
parseUpdateQuickReplyShortcuts :: Value -> Parser Update
parseUpdateQuickReplyShortcuts = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateQuickReplyShortcuts" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Int]
shortcut_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shortcut_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateQuickReplyShortcuts
{ shortcut_ids :: Maybe [Int]
shortcut_ids = Maybe [Int]
shortcut_ids_
}
parseUpdateQuickReplyShortcutMessages :: A.Value -> AT.Parser Update
parseUpdateQuickReplyShortcutMessages :: Value -> Parser Update
parseUpdateQuickReplyShortcutMessages = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateQuickReplyShortcutMessages" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
shortcut_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shortcut_id"
Maybe [QuickReplyMessage]
messages_ <- Object
o Object -> Key -> Parser (Maybe [QuickReplyMessage])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"messages"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateQuickReplyShortcutMessages
{ shortcut_id :: Maybe Int
shortcut_id = Maybe Int
shortcut_id_
, messages :: Maybe [QuickReplyMessage]
messages = Maybe [QuickReplyMessage]
messages_
}
parseUpdateForumTopicInfo :: A.Value -> AT.Parser Update
parseUpdateForumTopicInfo :: Value -> Parser Update
parseUpdateForumTopicInfo = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateForumTopicInfo" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ForumTopicInfo
info_ <- Object
o Object -> Key -> Parser (Maybe ForumTopicInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateForumTopicInfo
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, info :: Maybe ForumTopicInfo
info = Maybe ForumTopicInfo
info_
}
parseUpdateScopeNotificationSettings :: A.Value -> AT.Parser Update
parseUpdateScopeNotificationSettings :: Value -> Parser Update
parseUpdateScopeNotificationSettings = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateScopeNotificationSettings" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe NotificationSettingsScope
scope_ <- Object
o Object -> Key -> Parser (Maybe NotificationSettingsScope)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"scope"
Maybe ScopeNotificationSettings
_notification_settings_ <- Object
o Object -> Key -> Parser (Maybe ScopeNotificationSettings)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_settings"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateScopeNotificationSettings
{ scope :: Maybe NotificationSettingsScope
scope = Maybe NotificationSettingsScope
scope_
, _notification_settings :: Maybe ScopeNotificationSettings
_notification_settings = Maybe ScopeNotificationSettings
_notification_settings_
}
parseUpdateReactionNotificationSettings :: A.Value -> AT.Parser Update
parseUpdateReactionNotificationSettings :: Value -> Parser Update
parseUpdateReactionNotificationSettings = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateReactionNotificationSettings" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ReactionNotificationSettings
__notification_settings_ <- Object
o Object -> Key -> Parser (Maybe ReactionNotificationSettings)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_settings"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateReactionNotificationSettings
{ __notification_settings :: Maybe ReactionNotificationSettings
__notification_settings = Maybe ReactionNotificationSettings
__notification_settings_
}
parseUpdateNotification :: A.Value -> AT.Parser Update
parseUpdateNotification :: Value -> Parser Update
parseUpdateNotification = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNotification" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
notification_group_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_group_id"
Maybe Notification
notification_ <- Object
o Object -> Key -> Parser (Maybe Notification)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNotification
{ notification_group_id :: Maybe Int
notification_group_id = Maybe Int
notification_group_id_
, notification :: Maybe Notification
notification = Maybe Notification
notification_
}
parseUpdateNotificationGroup :: A.Value -> AT.Parser Update
parseUpdateNotificationGroup :: Value -> Parser Update
parseUpdateNotificationGroup = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNotificationGroup" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
notification_group_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_group_id"
Maybe NotificationGroupType
_type_ <- Object
o Object -> Key -> Parser (Maybe NotificationGroupType)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"type"
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
notification_settings_chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_settings_chat_id"
Maybe Int
notification_sound_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_sound_id"
Maybe Int
total_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"total_count"
Maybe [Notification]
added_notifications_ <- Object
o Object -> Key -> Parser (Maybe [Notification])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"added_notifications"
Maybe [Int]
removed_notification_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"removed_notification_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNotificationGroup
{ notification_group_id :: Maybe Int
notification_group_id = Maybe Int
notification_group_id_
, _type :: Maybe NotificationGroupType
_type = Maybe NotificationGroupType
_type_
, chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, notification_settings_chat_id :: Maybe Int
notification_settings_chat_id = Maybe Int
notification_settings_chat_id_
, notification_sound_id :: Maybe Int
notification_sound_id = Maybe Int
notification_sound_id_
, total_count :: Maybe Int
total_count = Maybe Int
total_count_
, added_notifications :: Maybe [Notification]
added_notifications = Maybe [Notification]
added_notifications_
, removed_notification_ids :: Maybe [Int]
removed_notification_ids = Maybe [Int]
removed_notification_ids_
}
parseUpdateActiveNotifications :: A.Value -> AT.Parser Update
parseUpdateActiveNotifications :: Value -> Parser Update
parseUpdateActiveNotifications = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateActiveNotifications" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [NotificationGroup]
groups_ <- Object
o Object -> Key -> Parser (Maybe [NotificationGroup])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"groups"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateActiveNotifications
{ groups :: Maybe [NotificationGroup]
groups = Maybe [NotificationGroup]
groups_
}
parseUpdateHavePendingNotifications :: A.Value -> AT.Parser Update
parseUpdateHavePendingNotifications :: Value -> Parser Update
parseUpdateHavePendingNotifications = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateHavePendingNotifications" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Bool
have_delayed_notifications_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"have_delayed_notifications"
Maybe Bool
have_unreceived_notifications_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"have_unreceived_notifications"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateHavePendingNotifications
{ have_delayed_notifications :: Maybe Bool
have_delayed_notifications = Maybe Bool
have_delayed_notifications_
, have_unreceived_notifications :: Maybe Bool
have_unreceived_notifications = Maybe Bool
have_unreceived_notifications_
}
parseUpdateDeleteMessages :: A.Value -> AT.Parser Update
parseUpdateDeleteMessages :: Value -> Parser Update
parseUpdateDeleteMessages = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateDeleteMessages" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe [Int]
message_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_ids"
Maybe Bool
is_permanent_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_permanent"
Maybe Bool
from_cache_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"from_cache"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateDeleteMessages
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_ids :: Maybe [Int]
message_ids = Maybe [Int]
message_ids_
, is_permanent :: Maybe Bool
is_permanent = Maybe Bool
is_permanent_
, from_cache :: Maybe Bool
from_cache = Maybe Bool
from_cache_
}
parseUpdateChatAction :: A.Value -> AT.Parser Update
parseUpdateChatAction :: Value -> Parser Update
parseUpdateChatAction = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatAction" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_thread_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_thread_id"
Maybe MessageSender
sender_id_ <- Object
o Object -> Key -> Parser (Maybe MessageSender)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_id"
Maybe ChatAction
action_ <- Object
o Object -> Key -> Parser (Maybe ChatAction)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"action"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatAction
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_thread_id :: Maybe Int
message_thread_id = Maybe Int
message_thread_id_
, sender_id :: Maybe MessageSender
sender_id = Maybe MessageSender
sender_id_
, action :: Maybe ChatAction
action = Maybe ChatAction
action_
}
parseUpdateUserStatus :: A.Value -> AT.Parser Update
parseUpdateUserStatus :: Value -> Parser Update
parseUpdateUserStatus = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUserStatus" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_id"
Maybe UserStatus
status_ <- Object
o Object -> Key -> Parser (Maybe UserStatus)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"status"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUserStatus
{ user_id :: Maybe Int
user_id = Maybe Int
user_id_
, status :: Maybe UserStatus
status = Maybe UserStatus
status_
}
parseUpdateUser :: A.Value -> AT.Parser Update
parseUpdateUser :: Value -> Parser Update
parseUpdateUser = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUser" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe User
user_ <- Object
o Object -> Key -> Parser (Maybe User)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUser
{ user :: Maybe User
user = Maybe User
user_
}
parseUpdateBasicGroup :: A.Value -> AT.Parser Update
parseUpdateBasicGroup :: Value -> Parser Update
parseUpdateBasicGroup = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateBasicGroup" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe BasicGroup
basic_group_ <- Object
o Object -> Key -> Parser (Maybe BasicGroup)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"basic_group"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateBasicGroup
{ basic_group :: Maybe BasicGroup
basic_group = Maybe BasicGroup
basic_group_
}
parseUpdateSupergroup :: A.Value -> AT.Parser Update
parseUpdateSupergroup :: Value -> Parser Update
parseUpdateSupergroup = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSupergroup" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Supergroup
supergroup_ <- Object
o Object -> Key -> Parser (Maybe Supergroup)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"supergroup"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSupergroup
{ supergroup :: Maybe Supergroup
supergroup = Maybe Supergroup
supergroup_
}
parseUpdateSecretChat :: A.Value -> AT.Parser Update
parseUpdateSecretChat :: Value -> Parser Update
parseUpdateSecretChat = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSecretChat" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe SecretChat
secret_chat_ <- Object
o Object -> Key -> Parser (Maybe SecretChat)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"secret_chat"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSecretChat
{ secret_chat :: Maybe SecretChat
secret_chat = Maybe SecretChat
secret_chat_
}
parseUpdateUserFullInfo :: A.Value -> AT.Parser Update
parseUpdateUserFullInfo :: Value -> Parser Update
parseUpdateUserFullInfo = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUserFullInfo" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_id"
Maybe UserFullInfo
user_full_info_ <- Object
o Object -> Key -> Parser (Maybe UserFullInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_full_info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUserFullInfo
{ user_id :: Maybe Int
user_id = Maybe Int
user_id_
, user_full_info :: Maybe UserFullInfo
user_full_info = Maybe UserFullInfo
user_full_info_
}
parseUpdateBasicGroupFullInfo :: A.Value -> AT.Parser Update
parseUpdateBasicGroupFullInfo :: Value -> Parser Update
parseUpdateBasicGroupFullInfo = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateBasicGroupFullInfo" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
basic_group_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"basic_group_id"
Maybe BasicGroupFullInfo
basic_group_full_info_ <- Object
o Object -> Key -> Parser (Maybe BasicGroupFullInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"basic_group_full_info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateBasicGroupFullInfo
{ basic_group_id :: Maybe Int
basic_group_id = Maybe Int
basic_group_id_
, basic_group_full_info :: Maybe BasicGroupFullInfo
basic_group_full_info = Maybe BasicGroupFullInfo
basic_group_full_info_
}
parseUpdateSupergroupFullInfo :: A.Value -> AT.Parser Update
parseUpdateSupergroupFullInfo :: Value -> Parser Update
parseUpdateSupergroupFullInfo = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSupergroupFullInfo" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
supergroup_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"supergroup_id"
Maybe SupergroupFullInfo
supergroup_full_info_ <- Object
o Object -> Key -> Parser (Maybe SupergroupFullInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"supergroup_full_info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSupergroupFullInfo
{ supergroup_id :: Maybe Int
supergroup_id = Maybe Int
supergroup_id_
, supergroup_full_info :: Maybe SupergroupFullInfo
supergroup_full_info = Maybe SupergroupFullInfo
supergroup_full_info_
}
parseUpdateServiceNotification :: A.Value -> AT.Parser Update
parseUpdateServiceNotification :: Value -> Parser Update
parseUpdateServiceNotification = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateServiceNotification" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
__type_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"type"
Maybe MessageContent
content_ <- Object
o Object -> Key -> Parser (Maybe MessageContent)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"content"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateServiceNotification
{ __type :: Maybe Text
__type = Maybe Text
__type_
, content :: Maybe MessageContent
content = Maybe MessageContent
content_
}
parseUpdateFile :: A.Value -> AT.Parser Update
parseUpdateFile :: Value -> Parser Update
parseUpdateFile = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFile" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe File
file_ <- Object
o Object -> Key -> Parser (Maybe File)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"file"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFile
{ file :: Maybe File
file = Maybe File
file_
}
parseUpdateFileGenerationStart :: A.Value -> AT.Parser Update
parseUpdateFileGenerationStart :: Value -> Parser Update
parseUpdateFileGenerationStart = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileGenerationStart" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
generation_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"generation_id"
Maybe Text
original_path_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"original_path"
Maybe Text
destination_path_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"destination_path"
Maybe Text
conversion_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"conversion"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileGenerationStart
{ generation_id :: Maybe Int
generation_id = Maybe Int
generation_id_
, original_path :: Maybe Text
original_path = Maybe Text
original_path_
, destination_path :: Maybe Text
destination_path = Maybe Text
destination_path_
, conversion :: Maybe Text
conversion = Maybe Text
conversion_
}
parseUpdateFileGenerationStop :: A.Value -> AT.Parser Update
parseUpdateFileGenerationStop :: Value -> Parser Update
parseUpdateFileGenerationStop = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileGenerationStop" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
generation_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"generation_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileGenerationStop
{ generation_id :: Maybe Int
generation_id = Maybe Int
generation_id_
}
parseUpdateFileDownloads :: A.Value -> AT.Parser Update
parseUpdateFileDownloads :: Value -> Parser Update
parseUpdateFileDownloads = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileDownloads" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
total_size_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"total_size"
Maybe Int
total_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"total_count"
Maybe Int
downloaded_size_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"downloaded_size"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileDownloads
{ total_size :: Maybe Int
total_size = Maybe Int
total_size_
, total_count :: Maybe Int
total_count = Maybe Int
total_count_
, downloaded_size :: Maybe Int
downloaded_size = Maybe Int
downloaded_size_
}
parseUpdateFileAddedToDownloads :: A.Value -> AT.Parser Update
parseUpdateFileAddedToDownloads :: Value -> Parser Update
parseUpdateFileAddedToDownloads = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileAddedToDownloads" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe FileDownload
file_download_ <- Object
o Object -> Key -> Parser (Maybe FileDownload)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"file_download"
Maybe DownloadedFileCounts
counts_ <- Object
o Object -> Key -> Parser (Maybe DownloadedFileCounts)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"counts"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileAddedToDownloads
{ file_download :: Maybe FileDownload
file_download = Maybe FileDownload
file_download_
, counts :: Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
parseUpdateFileDownload :: A.Value -> AT.Parser Update
parseUpdateFileDownload :: Value -> Parser Update
parseUpdateFileDownload = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileDownload" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
file_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"file_id"
Maybe Int
complete_date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"complete_date"
Maybe Bool
is_paused_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_paused"
Maybe DownloadedFileCounts
counts_ <- Object
o Object -> Key -> Parser (Maybe DownloadedFileCounts)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"counts"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileDownload
{ file_id :: Maybe Int
file_id = Maybe Int
file_id_
, complete_date :: Maybe Int
complete_date = Maybe Int
complete_date_
, is_paused :: Maybe Bool
is_paused = Maybe Bool
is_paused_
, counts :: Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
parseUpdateFileRemovedFromDownloads :: A.Value -> AT.Parser Update
parseUpdateFileRemovedFromDownloads :: Value -> Parser Update
parseUpdateFileRemovedFromDownloads = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFileRemovedFromDownloads" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
file_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"file_id"
Maybe DownloadedFileCounts
counts_ <- Object
o Object -> Key -> Parser (Maybe DownloadedFileCounts)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"counts"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFileRemovedFromDownloads
{ file_id :: Maybe Int
file_id = Maybe Int
file_id_
, counts :: Maybe DownloadedFileCounts
counts = Maybe DownloadedFileCounts
counts_
}
parseUpdateApplicationVerificationRequired :: A.Value -> AT.Parser Update
parseUpdateApplicationVerificationRequired :: Value -> Parser Update
parseUpdateApplicationVerificationRequired = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateApplicationVerificationRequired" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
verification_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"verification_id"
Maybe Text
nonce_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"nonce"
Maybe Int
cloud_project_number_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"cloud_project_number"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateApplicationVerificationRequired
{ verification_id :: Maybe Int
verification_id = Maybe Int
verification_id_
, nonce :: Maybe Text
nonce = Maybe Text
nonce_
, cloud_project_number :: Maybe Int
cloud_project_number = Maybe Int
cloud_project_number_
}
parseUpdateCall :: A.Value -> AT.Parser Update
parseUpdateCall :: Value -> Parser Update
parseUpdateCall = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateCall" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Call
call_ <- Object
o Object -> Key -> Parser (Maybe Call)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"call"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateCall
{ call :: Maybe Call
call = Maybe Call
call_
}
parseUpdateGroupCall :: A.Value -> AT.Parser Update
parseUpdateGroupCall :: Value -> Parser Update
parseUpdateGroupCall = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateGroupCall" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe GroupCall
group_call_ <- Object
o Object -> Key -> Parser (Maybe GroupCall)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"group_call"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateGroupCall
{ group_call :: Maybe GroupCall
group_call = Maybe GroupCall
group_call_
}
parseUpdateGroupCallParticipant :: A.Value -> AT.Parser Update
parseUpdateGroupCallParticipant :: Value -> Parser Update
parseUpdateGroupCallParticipant = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateGroupCallParticipant" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
group_call_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"group_call_id"
Maybe GroupCallParticipant
participant_ <- Object
o Object -> Key -> Parser (Maybe GroupCallParticipant)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"participant"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateGroupCallParticipant
{ group_call_id :: Maybe Int
group_call_id = Maybe Int
group_call_id_
, participant :: Maybe GroupCallParticipant
participant = Maybe GroupCallParticipant
participant_
}
parseUpdateNewCallSignalingData :: A.Value -> AT.Parser Update
parseUpdateNewCallSignalingData :: Value -> Parser Update
parseUpdateNewCallSignalingData = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewCallSignalingData" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
call_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"call_id"
Maybe ByteString
_data_ <- (String -> ByteString) -> Maybe String -> Maybe ByteString
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> ByteString
I.readBytes (Maybe String -> Maybe ByteString)
-> Parser (Maybe String) -> Parser (Maybe ByteString)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"data"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewCallSignalingData
{ call_id :: Maybe Int
call_id = Maybe Int
call_id_
, _data :: Maybe ByteString
_data = Maybe ByteString
_data_
}
parseUpdateUserPrivacySettingRules :: A.Value -> AT.Parser Update
parseUpdateUserPrivacySettingRules :: Value -> Parser Update
parseUpdateUserPrivacySettingRules = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUserPrivacySettingRules" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe UserPrivacySetting
setting_ <- Object
o Object -> Key -> Parser (Maybe UserPrivacySetting)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"setting"
Maybe UserPrivacySettingRules
rules_ <- Object
o Object -> Key -> Parser (Maybe UserPrivacySettingRules)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"rules"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUserPrivacySettingRules
{ setting :: Maybe UserPrivacySetting
setting = Maybe UserPrivacySetting
setting_
, rules :: Maybe UserPrivacySettingRules
rules = Maybe UserPrivacySettingRules
rules_
}
parseUpdateUnreadMessageCount :: A.Value -> AT.Parser Update
parseUpdateUnreadMessageCount :: Value -> Parser Update
parseUpdateUnreadMessageCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUnreadMessageCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ChatList
chat_list_ <- Object
o Object -> Key -> Parser (Maybe ChatList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_list"
Maybe Int
unread_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_count"
Maybe Int
unread_unmuted_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_unmuted_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUnreadMessageCount
{ chat_list :: Maybe ChatList
chat_list = Maybe ChatList
chat_list_
, unread_count :: Maybe Int
unread_count = Maybe Int
unread_count_
, unread_unmuted_count :: Maybe Int
unread_unmuted_count = Maybe Int
unread_unmuted_count_
}
parseUpdateUnreadChatCount :: A.Value -> AT.Parser Update
parseUpdateUnreadChatCount :: Value -> Parser Update
parseUpdateUnreadChatCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUnreadChatCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ChatList
chat_list_ <- Object
o Object -> Key -> Parser (Maybe ChatList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_list"
Maybe Int
total_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"total_count"
Maybe Int
unread_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_count"
Maybe Int
unread_unmuted_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"unread_unmuted_count"
Maybe Int
marked_as_unread_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"marked_as_unread_count"
Maybe Int
marked_as_unread_unmuted_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"marked_as_unread_unmuted_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUnreadChatCount
{ chat_list :: Maybe ChatList
chat_list = Maybe ChatList
chat_list_
, total_count :: Maybe Int
total_count = Maybe Int
total_count_
, unread_count :: Maybe Int
unread_count = Maybe Int
unread_count_
, unread_unmuted_count :: Maybe Int
unread_unmuted_count = Maybe Int
unread_unmuted_count_
, marked_as_unread_count :: Maybe Int
marked_as_unread_count = Maybe Int
marked_as_unread_count_
, marked_as_unread_unmuted_count :: Maybe Int
marked_as_unread_unmuted_count = Maybe Int
marked_as_unread_unmuted_count_
}
parseUpdateStory :: A.Value -> AT.Parser Update
parseUpdateStory :: Value -> Parser Update
parseUpdateStory = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStory" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Story
story_ <- Object
o Object -> Key -> Parser (Maybe Story)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStory
{ story :: Maybe Story
story = Maybe Story
story_
}
parseUpdateStoryDeleted :: A.Value -> AT.Parser Update
parseUpdateStoryDeleted :: Value -> Parser Update
parseUpdateStoryDeleted = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStoryDeleted" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
story_sender_chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story_sender_chat_id"
Maybe Int
story_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStoryDeleted
{ story_sender_chat_id :: Maybe Int
story_sender_chat_id = Maybe Int
story_sender_chat_id_
, story_id :: Maybe Int
story_id = Maybe Int
story_id_
}
parseUpdateStorySendSucceeded :: A.Value -> AT.Parser Update
parseUpdateStorySendSucceeded :: Value -> Parser Update
parseUpdateStorySendSucceeded = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStorySendSucceeded" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Story
story_ <- Object
o Object -> Key -> Parser (Maybe Story)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story"
Maybe Int
old_story_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"old_story_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStorySendSucceeded
{ story :: Maybe Story
story = Maybe Story
story_
, old_story_id :: Maybe Int
old_story_id = Maybe Int
old_story_id_
}
parseUpdateStorySendFailed :: A.Value -> AT.Parser Update
parseUpdateStorySendFailed :: Value -> Parser Update
parseUpdateStorySendFailed = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStorySendFailed" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Story
story_ <- Object
o Object -> Key -> Parser (Maybe Story)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story"
Maybe Error
_error_ <- Object
o Object -> Key -> Parser (Maybe Error)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"error"
Maybe CanSendStoryResult
error_type_ <- Object
o Object -> Key -> Parser (Maybe CanSendStoryResult)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"error_type"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStorySendFailed
{ story :: Maybe Story
story = Maybe Story
story_
, _error :: Maybe Error
_error = Maybe Error
_error_
, error_type :: Maybe CanSendStoryResult
error_type = Maybe CanSendStoryResult
error_type_
}
parseUpdateChatActiveStories :: A.Value -> AT.Parser Update
parseUpdateChatActiveStories :: Value -> Parser Update
parseUpdateChatActiveStories = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatActiveStories" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ChatActiveStories
active_stories_ <- Object
o Object -> Key -> Parser (Maybe ChatActiveStories)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"active_stories"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatActiveStories
{ active_stories :: Maybe ChatActiveStories
active_stories = Maybe ChatActiveStories
active_stories_
}
parseUpdateStoryListChatCount :: A.Value -> AT.Parser Update
parseUpdateStoryListChatCount :: Value -> Parser Update
parseUpdateStoryListChatCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStoryListChatCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe StoryList
story_list_ <- Object
o Object -> Key -> Parser (Maybe StoryList)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"story_list"
Maybe Int
chat_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStoryListChatCount
{ story_list :: Maybe StoryList
story_list = Maybe StoryList
story_list_
, chat_count :: Maybe Int
chat_count = Maybe Int
chat_count_
}
parseUpdateStoryStealthMode :: A.Value -> AT.Parser Update
parseUpdateStoryStealthMode :: Value -> Parser Update
parseUpdateStoryStealthMode = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStoryStealthMode" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
active_until_date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"active_until_date"
Maybe Int
cooldown_until_date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"cooldown_until_date"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStoryStealthMode
{ active_until_date :: Maybe Int
active_until_date = Maybe Int
active_until_date_
, cooldown_until_date :: Maybe Int
cooldown_until_date = Maybe Int
cooldown_until_date_
}
parseUpdateOption :: A.Value -> AT.Parser Update
parseUpdateOption :: Value -> Parser Update
parseUpdateOption = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateOption" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
name_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"name"
Maybe OptionValue
value_ <- Object
o Object -> Key -> Parser (Maybe OptionValue)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"value"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateOption
{ name :: Maybe Text
name = Maybe Text
name_
, value :: Maybe OptionValue
value = Maybe OptionValue
value_
}
parseUpdateStickerSet :: A.Value -> AT.Parser Update
parseUpdateStickerSet :: Value -> Parser Update
parseUpdateStickerSet = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStickerSet" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe StickerSet
sticker_set_ <- Object
o Object -> Key -> Parser (Maybe StickerSet)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_set"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStickerSet
{ sticker_set :: Maybe StickerSet
sticker_set = Maybe StickerSet
sticker_set_
}
parseUpdateInstalledStickerSets :: A.Value -> AT.Parser Update
parseUpdateInstalledStickerSets :: Value -> Parser Update
parseUpdateInstalledStickerSets = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateInstalledStickerSets" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe StickerType
sticker_type_ <- Object
o Object -> Key -> Parser (Maybe StickerType)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_type"
Maybe [Int]
sticker_set_ids_ <- ([String] -> [Int]) -> Maybe [String] -> Maybe [Int]
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap ((String -> Int) -> [String] -> [Int]
forall a b. (a -> b) -> [a] -> [b]
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64) (Maybe [String] -> Maybe [Int])
-> Parser (Maybe [String]) -> Parser (Maybe [Int])
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe [String])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_set_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateInstalledStickerSets
{ sticker_type :: Maybe StickerType
sticker_type = Maybe StickerType
sticker_type_
, sticker_set_ids :: Maybe [Int]
sticker_set_ids = Maybe [Int]
sticker_set_ids_
}
parseUpdateTrendingStickerSets :: A.Value -> AT.Parser Update
parseUpdateTrendingStickerSets :: Value -> Parser Update
parseUpdateTrendingStickerSets = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateTrendingStickerSets" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe StickerType
sticker_type_ <- Object
o Object -> Key -> Parser (Maybe StickerType)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_type"
Maybe TrendingStickerSets
sticker_sets_ <- Object
o Object -> Key -> Parser (Maybe TrendingStickerSets)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_sets"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateTrendingStickerSets
{ sticker_type :: Maybe StickerType
sticker_type = Maybe StickerType
sticker_type_
, sticker_sets :: Maybe TrendingStickerSets
sticker_sets = Maybe TrendingStickerSets
sticker_sets_
}
parseUpdateRecentStickers :: A.Value -> AT.Parser Update
parseUpdateRecentStickers :: Value -> Parser Update
parseUpdateRecentStickers = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateRecentStickers" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Bool
is_attached_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_attached"
Maybe [Int]
sticker_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateRecentStickers
{ is_attached :: Maybe Bool
is_attached = Maybe Bool
is_attached_
, sticker_ids :: Maybe [Int]
sticker_ids = Maybe [Int]
sticker_ids_
}
parseUpdateFavoriteStickers :: A.Value -> AT.Parser Update
parseUpdateFavoriteStickers :: Value -> Parser Update
parseUpdateFavoriteStickers = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateFavoriteStickers" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Int]
sticker_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateFavoriteStickers
{ sticker_ids :: Maybe [Int]
sticker_ids = Maybe [Int]
sticker_ids_
}
parseUpdateSavedAnimations :: A.Value -> AT.Parser Update
parseUpdateSavedAnimations :: Value -> Parser Update
parseUpdateSavedAnimations = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSavedAnimations" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Int]
animation_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"animation_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSavedAnimations
{ animation_ids :: Maybe [Int]
animation_ids = Maybe [Int]
animation_ids_
}
parseUpdateSavedNotificationSounds :: A.Value -> AT.Parser Update
parseUpdateSavedNotificationSounds :: Value -> Parser Update
parseUpdateSavedNotificationSounds = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSavedNotificationSounds" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Int]
notification_sound_ids_ <- ([String] -> [Int]) -> Maybe [String] -> Maybe [Int]
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap ((String -> Int) -> [String] -> [Int]
forall a b. (a -> b) -> [a] -> [b]
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64) (Maybe [String] -> Maybe [Int])
-> Parser (Maybe [String]) -> Parser (Maybe [Int])
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe [String])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"notification_sound_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSavedNotificationSounds
{ notification_sound_ids :: Maybe [Int]
notification_sound_ids = Maybe [Int]
notification_sound_ids_
}
parseUpdateDefaultBackground :: A.Value -> AT.Parser Update
parseUpdateDefaultBackground :: Value -> Parser Update
parseUpdateDefaultBackground = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateDefaultBackground" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Bool
for_dark_theme_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"for_dark_theme"
Maybe Background
_background_ <- Object
o Object -> Key -> Parser (Maybe Background)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"background"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateDefaultBackground
{ for_dark_theme :: Maybe Bool
for_dark_theme = Maybe Bool
for_dark_theme_
, _background :: Maybe Background
_background = Maybe Background
_background_
}
parseUpdateChatThemes :: A.Value -> AT.Parser Update
parseUpdateChatThemes :: Value -> Parser Update
parseUpdateChatThemes = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatThemes" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [ChatTheme]
chat_themes_ <- Object
o Object -> Key -> Parser (Maybe [ChatTheme])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_themes"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatThemes
{ chat_themes :: Maybe [ChatTheme]
chat_themes = Maybe [ChatTheme]
chat_themes_
}
parseUpdateAccentColors :: A.Value -> AT.Parser Update
parseUpdateAccentColors :: Value -> Parser Update
parseUpdateAccentColors = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAccentColors" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [AccentColor]
colors_ <- Object
o Object -> Key -> Parser (Maybe [AccentColor])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"colors"
Maybe [Int]
available_accent_color_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"available_accent_color_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAccentColors
{ colors :: Maybe [AccentColor]
colors = Maybe [AccentColor]
colors_
, available_accent_color_ids :: Maybe [Int]
available_accent_color_ids = Maybe [Int]
available_accent_color_ids_
}
parseUpdateProfileAccentColors :: A.Value -> AT.Parser Update
parseUpdateProfileAccentColors :: Value -> Parser Update
parseUpdateProfileAccentColors = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateProfileAccentColors" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [ProfileAccentColor]
_colors_ <- Object
o Object -> Key -> Parser (Maybe [ProfileAccentColor])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"colors"
Maybe [Int]
available_accent_color_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"available_accent_color_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateProfileAccentColors
{ _colors :: Maybe [ProfileAccentColor]
_colors = Maybe [ProfileAccentColor]
_colors_
, available_accent_color_ids :: Maybe [Int]
available_accent_color_ids = Maybe [Int]
available_accent_color_ids_
}
parseUpdateLanguagePackStrings :: A.Value -> AT.Parser Update
parseUpdateLanguagePackStrings :: Value -> Parser Update
parseUpdateLanguagePackStrings = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateLanguagePackStrings" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
localization_target_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"localization_target"
Maybe Text
language_pack_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"language_pack_id"
Maybe [LanguagePackString]
strings_ <- Object
o Object -> Key -> Parser (Maybe [LanguagePackString])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"strings"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateLanguagePackStrings
{ localization_target :: Maybe Text
localization_target = Maybe Text
localization_target_
, language_pack_id :: Maybe Text
language_pack_id = Maybe Text
language_pack_id_
, strings :: Maybe [LanguagePackString]
strings = Maybe [LanguagePackString]
strings_
}
parseUpdateConnectionState :: A.Value -> AT.Parser Update
parseUpdateConnectionState :: Value -> Parser Update
parseUpdateConnectionState = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateConnectionState" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ConnectionState
state_ <- Object
o Object -> Key -> Parser (Maybe ConnectionState)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"state"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateConnectionState
{ state :: Maybe ConnectionState
state = Maybe ConnectionState
state_
}
parseUpdateTermsOfService :: A.Value -> AT.Parser Update
parseUpdateTermsOfService :: Value -> Parser Update
parseUpdateTermsOfService = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateTermsOfService" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
terms_of_service_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"terms_of_service_id"
Maybe TermsOfService
terms_of_service_ <- Object
o Object -> Key -> Parser (Maybe TermsOfService)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"terms_of_service"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateTermsOfService
{ terms_of_service_id :: Maybe Text
terms_of_service_id = Maybe Text
terms_of_service_id_
, terms_of_service :: Maybe TermsOfService
terms_of_service = Maybe TermsOfService
terms_of_service_
}
parseUpdateUnconfirmedSession :: A.Value -> AT.Parser Update
parseUpdateUnconfirmedSession :: Value -> Parser Update
parseUpdateUnconfirmedSession = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateUnconfirmedSession" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe UnconfirmedSession
session_ <- Object
o Object -> Key -> Parser (Maybe UnconfirmedSession)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"session"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateUnconfirmedSession
{ session :: Maybe UnconfirmedSession
session = Maybe UnconfirmedSession
session_
}
parseUpdateAttachmentMenuBots :: A.Value -> AT.Parser Update
parseUpdateAttachmentMenuBots :: Value -> Parser Update
parseUpdateAttachmentMenuBots = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAttachmentMenuBots" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [AttachmentMenuBot]
bots_ <- Object
o Object -> Key -> Parser (Maybe [AttachmentMenuBot])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"bots"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAttachmentMenuBots
{ bots :: Maybe [AttachmentMenuBot]
bots = Maybe [AttachmentMenuBot]
bots_
}
parseUpdateWebAppMessageSent :: A.Value -> AT.Parser Update
parseUpdateWebAppMessageSent :: Value -> Parser Update
parseUpdateWebAppMessageSent = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateWebAppMessageSent" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
web_app_launch_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"web_app_launch_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateWebAppMessageSent
{ web_app_launch_id :: Maybe Int
web_app_launch_id = Maybe Int
web_app_launch_id_
}
parseUpdateActiveEmojiReactions :: A.Value -> AT.Parser Update
parseUpdateActiveEmojiReactions :: Value -> Parser Update
parseUpdateActiveEmojiReactions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateActiveEmojiReactions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Text]
emojis_ <- Object
o Object -> Key -> Parser (Maybe [Text])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"emojis"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateActiveEmojiReactions
{ emojis :: Maybe [Text]
emojis = Maybe [Text]
emojis_
}
parseUpdateAvailableMessageEffects :: A.Value -> AT.Parser Update
parseUpdateAvailableMessageEffects :: Value -> Parser Update
parseUpdateAvailableMessageEffects = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAvailableMessageEffects" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Int]
reaction_effect_ids_ <- ([String] -> [Int]) -> Maybe [String] -> Maybe [Int]
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap ((String -> Int) -> [String] -> [Int]
forall a b. (a -> b) -> [a] -> [b]
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64) (Maybe [String] -> Maybe [Int])
-> Parser (Maybe [String]) -> Parser (Maybe [Int])
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe [String])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"reaction_effect_ids"
Maybe [Int]
sticker_effect_ids_ <- ([String] -> [Int]) -> Maybe [String] -> Maybe [Int]
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap ((String -> Int) -> [String] -> [Int]
forall a b. (a -> b) -> [a] -> [b]
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64) (Maybe [String] -> Maybe [Int])
-> Parser (Maybe [String]) -> Parser (Maybe [Int])
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe [String])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker_effect_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAvailableMessageEffects
{ reaction_effect_ids :: Maybe [Int]
reaction_effect_ids = Maybe [Int]
reaction_effect_ids_
, sticker_effect_ids :: Maybe [Int]
sticker_effect_ids = Maybe [Int]
sticker_effect_ids_
}
parseUpdateDefaultReactionType :: A.Value -> AT.Parser Update
parseUpdateDefaultReactionType :: Value -> Parser Update
parseUpdateDefaultReactionType = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateDefaultReactionType" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe ReactionType
reaction_type_ <- Object
o Object -> Key -> Parser (Maybe ReactionType)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"reaction_type"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateDefaultReactionType
{ reaction_type :: Maybe ReactionType
reaction_type = Maybe ReactionType
reaction_type_
}
parseUpdateSavedMessagesTags :: A.Value -> AT.Parser Update
parseUpdateSavedMessagesTags :: Value -> Parser Update
parseUpdateSavedMessagesTags = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSavedMessagesTags" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
saved_messages_topic_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"saved_messages_topic_id"
Maybe SavedMessagesTags
tags_ <- Object
o Object -> Key -> Parser (Maybe SavedMessagesTags)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"tags"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSavedMessagesTags
{ saved_messages_topic_id :: Maybe Int
saved_messages_topic_id = Maybe Int
saved_messages_topic_id_
, tags :: Maybe SavedMessagesTags
tags = Maybe SavedMessagesTags
tags_
}
parseUpdateActiveLiveLocationMessages :: A.Value -> AT.Parser Update
parseUpdateActiveLiveLocationMessages :: Value -> Parser Update
parseUpdateActiveLiveLocationMessages = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateActiveLiveLocationMessages" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Message]
_messages_ <- Object
o Object -> Key -> Parser (Maybe [Message])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"messages"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateActiveLiveLocationMessages
{ _messages :: Maybe [Message]
_messages = Maybe [Message]
_messages_
}
parseUpdateOwnedStarCount :: A.Value -> AT.Parser Update
parseUpdateOwnedStarCount :: Value -> Parser Update
parseUpdateOwnedStarCount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateOwnedStarCount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
star_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"star_count"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateOwnedStarCount
{ star_count :: Maybe Int
star_count = Maybe Int
star_count_
}
parseUpdateChatRevenueAmount :: A.Value -> AT.Parser Update
parseUpdateChatRevenueAmount :: Value -> Parser Update
parseUpdateChatRevenueAmount = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatRevenueAmount" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatRevenueAmount
revenue_amount_ <- Object
o Object -> Key -> Parser (Maybe ChatRevenueAmount)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"revenue_amount"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatRevenueAmount
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, revenue_amount :: Maybe ChatRevenueAmount
revenue_amount = Maybe ChatRevenueAmount
revenue_amount_
}
parseUpdateStarRevenueStatus :: A.Value -> AT.Parser Update
parseUpdateStarRevenueStatus :: Value -> Parser Update
parseUpdateStarRevenueStatus = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateStarRevenueStatus" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe MessageSender
owner_id_ <- Object
o Object -> Key -> Parser (Maybe MessageSender)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"owner_id"
Maybe StarRevenueStatus
_status_ <- Object
o Object -> Key -> Parser (Maybe StarRevenueStatus)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"status"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateStarRevenueStatus
{ owner_id :: Maybe MessageSender
owner_id = Maybe MessageSender
owner_id_
, _status :: Maybe StarRevenueStatus
_status = Maybe StarRevenueStatus
_status_
}
parseUpdateSpeechRecognitionTrial :: A.Value -> AT.Parser Update
parseUpdateSpeechRecognitionTrial :: Value -> Parser Update
parseUpdateSpeechRecognitionTrial = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSpeechRecognitionTrial" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
max_media_duration_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"max_media_duration"
Maybe Int
weekly_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"weekly_count"
Maybe Int
left_count_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"left_count"
Maybe Int
next_reset_date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"next_reset_date"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSpeechRecognitionTrial
{ max_media_duration :: Maybe Int
max_media_duration = Maybe Int
max_media_duration_
, weekly_count :: Maybe Int
weekly_count = Maybe Int
weekly_count_
, left_count :: Maybe Int
left_count = Maybe Int
left_count_
, next_reset_date :: Maybe Int
next_reset_date = Maybe Int
next_reset_date_
}
parseUpdateDiceEmojis :: A.Value -> AT.Parser Update
parseUpdateDiceEmojis :: Value -> Parser Update
parseUpdateDiceEmojis = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateDiceEmojis" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [Text]
emojis_ <- Object
o Object -> Key -> Parser (Maybe [Text])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"emojis"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateDiceEmojis
{ emojis :: Maybe [Text]
emojis = Maybe [Text]
emojis_
}
parseUpdateAnimatedEmojiMessageClicked :: A.Value -> AT.Parser Update
parseUpdateAnimatedEmojiMessageClicked :: Value -> Parser Update
parseUpdateAnimatedEmojiMessageClicked = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAnimatedEmojiMessageClicked" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Sticker
sticker_ <- Object
o Object -> Key -> Parser (Maybe Sticker)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sticker"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAnimatedEmojiMessageClicked
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, sticker :: Maybe Sticker
sticker = Maybe Sticker
sticker_
}
parseUpdateAnimationSearchParameters :: A.Value -> AT.Parser Update
parseUpdateAnimationSearchParameters :: Value -> Parser Update
parseUpdateAnimationSearchParameters = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAnimationSearchParameters" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
provider_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"provider"
Maybe [Text]
emojis_ <- Object
o Object -> Key -> Parser (Maybe [Text])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"emojis"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAnimationSearchParameters
{ provider :: Maybe Text
provider = Maybe Text
provider_
, emojis :: Maybe [Text]
emojis = Maybe [Text]
emojis_
}
parseUpdateSuggestedActions :: A.Value -> AT.Parser Update
parseUpdateSuggestedActions :: Value -> Parser Update
parseUpdateSuggestedActions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSuggestedActions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [SuggestedAction]
added_actions_ <- Object
o Object -> Key -> Parser (Maybe [SuggestedAction])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"added_actions"
Maybe [SuggestedAction]
removed_actions_ <- Object
o Object -> Key -> Parser (Maybe [SuggestedAction])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"removed_actions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSuggestedActions
{ added_actions :: Maybe [SuggestedAction]
added_actions = Maybe [SuggestedAction]
added_actions_
, removed_actions :: Maybe [SuggestedAction]
removed_actions = Maybe [SuggestedAction]
removed_actions_
}
parseUpdateSpeedLimitNotification :: A.Value -> AT.Parser Update
parseUpdateSpeedLimitNotification :: Value -> Parser Update
parseUpdateSpeedLimitNotification = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateSpeedLimitNotification" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Bool
is_upload_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"is_upload"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateSpeedLimitNotification
{ is_upload :: Maybe Bool
is_upload = Maybe Bool
is_upload_
}
parseUpdateContactCloseBirthdays :: A.Value -> AT.Parser Update
parseUpdateContactCloseBirthdays :: Value -> Parser Update
parseUpdateContactCloseBirthdays = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateContactCloseBirthdays" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe [CloseBirthdayUser]
close_birthday_users_ <- Object
o Object -> Key -> Parser (Maybe [CloseBirthdayUser])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"close_birthday_users"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateContactCloseBirthdays
{ close_birthday_users :: Maybe [CloseBirthdayUser]
close_birthday_users = Maybe [CloseBirthdayUser]
close_birthday_users_
}
parseUpdateAutosaveSettings :: A.Value -> AT.Parser Update
parseUpdateAutosaveSettings :: Value -> Parser Update
parseUpdateAutosaveSettings = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateAutosaveSettings" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe AutosaveSettingsScope
_scope_ <- Object
o Object -> Key -> Parser (Maybe AutosaveSettingsScope)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"scope"
Maybe ScopeAutosaveSettings
settings_ <- Object
o Object -> Key -> Parser (Maybe ScopeAutosaveSettings)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"settings"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateAutosaveSettings
{ _scope :: Maybe AutosaveSettingsScope
_scope = Maybe AutosaveSettingsScope
_scope_
, settings :: Maybe ScopeAutosaveSettings
settings = Maybe ScopeAutosaveSettings
settings_
}
parseUpdateBusinessConnection :: A.Value -> AT.Parser Update
parseUpdateBusinessConnection :: Value -> Parser Update
parseUpdateBusinessConnection = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateBusinessConnection" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe BusinessConnection
connection_ <- Object
o Object -> Key -> Parser (Maybe BusinessConnection)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"connection"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateBusinessConnection
{ connection :: Maybe BusinessConnection
connection = Maybe BusinessConnection
connection_
}
parseUpdateNewBusinessMessage :: A.Value -> AT.Parser Update
parseUpdateNewBusinessMessage :: Value -> Parser Update
parseUpdateNewBusinessMessage = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewBusinessMessage" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
connection_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"connection_id"
Maybe BusinessMessage
_message_ <- Object
o Object -> Key -> Parser (Maybe BusinessMessage)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewBusinessMessage
{ connection_id :: Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
}
parseUpdateBusinessMessageEdited :: A.Value -> AT.Parser Update
parseUpdateBusinessMessageEdited :: Value -> Parser Update
parseUpdateBusinessMessageEdited = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateBusinessMessageEdited" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
connection_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"connection_id"
Maybe BusinessMessage
_message_ <- Object
o Object -> Key -> Parser (Maybe BusinessMessage)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateBusinessMessageEdited
{ connection_id :: Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
}
parseUpdateBusinessMessagesDeleted :: A.Value -> AT.Parser Update
parseUpdateBusinessMessagesDeleted :: Value -> Parser Update
parseUpdateBusinessMessagesDeleted = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateBusinessMessagesDeleted" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
connection_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"connection_id"
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe [Int]
message_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateBusinessMessagesDeleted
{ connection_id :: Maybe Text
connection_id = Maybe Text
connection_id_
, chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_ids :: Maybe [Int]
message_ids = Maybe [Int]
message_ids_
}
parseUpdateNewInlineQuery :: A.Value -> AT.Parser Update
parseUpdateNewInlineQuery :: Value -> Parser Update
parseUpdateNewInlineQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewInlineQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Location
user_location_ <- Object
o Object -> Key -> Parser (Maybe Location)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_location"
Maybe ChatType
chat_type_ <- Object
o Object -> Key -> Parser (Maybe ChatType)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_type"
Maybe Text
query_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"query"
Maybe Text
offset_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"offset"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewInlineQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, user_location :: Maybe Location
user_location = Maybe Location
user_location_
, chat_type :: Maybe ChatType
chat_type = Maybe ChatType
chat_type_
, query :: Maybe Text
query = Maybe Text
query_
, offset :: Maybe Text
offset = Maybe Text
offset_
}
parseUpdateNewChosenInlineResult :: A.Value -> AT.Parser Update
parseUpdateNewChosenInlineResult :: Value -> Parser Update
parseUpdateNewChosenInlineResult = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewChosenInlineResult" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Location
user_location_ <- Object
o Object -> Key -> Parser (Maybe Location)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_location"
Maybe Text
query_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"query"
Maybe Text
result_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"result_id"
Maybe Text
inline_message_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"inline_message_id"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewChosenInlineResult
{ sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, user_location :: Maybe Location
user_location = Maybe Location
user_location_
, query :: Maybe Text
query = Maybe Text
query_
, result_id :: Maybe Text
result_id = Maybe Text
result_id_
, inline_message_id :: Maybe Text
inline_message_id = Maybe Text
inline_message_id_
}
parseUpdateNewCallbackQuery :: A.Value -> AT.Parser Update
parseUpdateNewCallbackQuery :: Value -> Parser Update
parseUpdateNewCallbackQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewCallbackQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Int
chat_instance_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_instance"
Maybe CallbackQueryPayload
payload_ <- Object
o Object -> Key -> Parser (Maybe CallbackQueryPayload)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"payload"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewCallbackQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, chat_instance :: Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
parseUpdateNewInlineCallbackQuery :: A.Value -> AT.Parser Update
parseUpdateNewInlineCallbackQuery :: Value -> Parser Update
parseUpdateNewInlineCallbackQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewInlineCallbackQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Text
inline_message_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"inline_message_id"
Maybe Int
chat_instance_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_instance"
Maybe CallbackQueryPayload
payload_ <- Object
o Object -> Key -> Parser (Maybe CallbackQueryPayload)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"payload"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewInlineCallbackQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, inline_message_id :: Maybe Text
inline_message_id = Maybe Text
inline_message_id_
, chat_instance :: Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
parseUpdateNewBusinessCallbackQuery :: A.Value -> AT.Parser Update
parseUpdateNewBusinessCallbackQuery :: Value -> Parser Update
parseUpdateNewBusinessCallbackQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewBusinessCallbackQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Text
connection_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"connection_id"
Maybe BusinessMessage
_message_ <- Object
o Object -> Key -> Parser (Maybe BusinessMessage)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message"
Maybe Int
chat_instance_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_instance"
Maybe CallbackQueryPayload
payload_ <- Object
o Object -> Key -> Parser (Maybe CallbackQueryPayload)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"payload"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewBusinessCallbackQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, connection_id :: Maybe Text
connection_id = Maybe Text
connection_id_
, _message :: Maybe BusinessMessage
_message = Maybe BusinessMessage
_message_
, chat_instance :: Maybe Int
chat_instance = Maybe Int
chat_instance_
, payload :: Maybe CallbackQueryPayload
payload = Maybe CallbackQueryPayload
payload_
}
parseUpdateNewShippingQuery :: A.Value -> AT.Parser Update
parseUpdateNewShippingQuery :: Value -> Parser Update
parseUpdateNewShippingQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewShippingQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Text
invoice_payload_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"invoice_payload"
Maybe Address
shipping_address_ <- Object
o Object -> Key -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shipping_address"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewShippingQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, invoice_payload :: Maybe Text
invoice_payload = Maybe Text
invoice_payload_
, shipping_address :: Maybe Address
shipping_address = Maybe Address
shipping_address_
}
parseUpdateNewPreCheckoutQuery :: A.Value -> AT.Parser Update
parseUpdateNewPreCheckoutQuery :: Value -> Parser Update
parseUpdateNewPreCheckoutQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewPreCheckoutQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Int
sender_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"sender_user_id"
Maybe Text
currency_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"currency"
Maybe Int
total_amount_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"total_amount"
Maybe ByteString
_invoice_payload_ <- (String -> ByteString) -> Maybe String -> Maybe ByteString
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> ByteString
I.readBytes (Maybe String -> Maybe ByteString)
-> Parser (Maybe String) -> Parser (Maybe ByteString)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"invoice_payload"
Maybe Text
shipping_option_id_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"shipping_option_id"
Maybe OrderInfo
order_info_ <- Object
o Object -> Key -> Parser (Maybe OrderInfo)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"order_info"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewPreCheckoutQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, sender_user_id :: Maybe Int
sender_user_id = Maybe Int
sender_user_id_
, currency :: Maybe Text
currency = Maybe Text
currency_
, total_amount :: Maybe Int
total_amount = Maybe Int
total_amount_
, _invoice_payload :: Maybe ByteString
_invoice_payload = Maybe ByteString
_invoice_payload_
, shipping_option_id :: Maybe Text
shipping_option_id = Maybe Text
shipping_option_id_
, order_info :: Maybe OrderInfo
order_info = Maybe OrderInfo
order_info_
}
parseUpdateNewCustomEvent :: A.Value -> AT.Parser Update
parseUpdateNewCustomEvent :: Value -> Parser Update
parseUpdateNewCustomEvent = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewCustomEvent" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Text
event_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"event"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewCustomEvent
{ event :: Maybe Text
event = Maybe Text
event_
}
parseUpdateNewCustomQuery :: A.Value -> AT.Parser Update
parseUpdateNewCustomQuery :: Value -> Parser Update
parseUpdateNewCustomQuery = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewCustomQuery" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"id"
Maybe Text
__data_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"data"
Maybe Int
timeout_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"timeout"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewCustomQuery
{ _id :: Maybe Int
_id = Maybe Int
_id_
, __data :: Maybe Text
__data = Maybe Text
__data_
, timeout :: Maybe Int
timeout = Maybe Int
timeout_
}
parseUpdatePoll :: A.Value -> AT.Parser Update
parseUpdatePoll :: Value -> Parser Update
parseUpdatePoll = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdatePoll" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Poll
poll_ <- Object
o Object -> Key -> Parser (Maybe Poll)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"poll"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdatePoll
{ poll :: Maybe Poll
poll = Maybe Poll
poll_
}
parseUpdatePollAnswer :: A.Value -> AT.Parser Update
parseUpdatePollAnswer :: Value -> Parser Update
parseUpdatePollAnswer = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdatePollAnswer" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
poll_id_ <- (String -> Int) -> Maybe String -> Maybe Int
forall a b. (a -> b) -> Maybe a -> Maybe b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap String -> Int
I.readInt64 (Maybe String -> Maybe Int)
-> Parser (Maybe String) -> Parser (Maybe Int)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe String)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"poll_id"
Maybe MessageSender
voter_id_ <- Object
o Object -> Key -> Parser (Maybe MessageSender)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"voter_id"
Maybe [Int]
option_ids_ <- Object
o Object -> Key -> Parser (Maybe [Int])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"option_ids"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdatePollAnswer
{ poll_id :: Maybe Int
poll_id = Maybe Int
poll_id_
, voter_id :: Maybe MessageSender
voter_id = Maybe MessageSender
voter_id_
, option_ids :: Maybe [Int]
option_ids = Maybe [Int]
option_ids_
}
parseUpdateChatMember :: A.Value -> AT.Parser Update
parseUpdateChatMember :: Value -> Parser Update
parseUpdateChatMember = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatMember" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
actor_user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"actor_user_id"
Maybe Int
date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"date"
Maybe ChatInviteLink
invite_link_ <- Object
o Object -> Key -> Parser (Maybe ChatInviteLink)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"invite_link"
Maybe Bool
via_join_request_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"via_join_request"
Maybe Bool
via_chat_folder_invite_link_ <- Object
o Object -> Key -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"via_chat_folder_invite_link"
Maybe ChatMember
old_chat_member_ <- Object
o Object -> Key -> Parser (Maybe ChatMember)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"old_chat_member"
Maybe ChatMember
new_chat_member_ <- Object
o Object -> Key -> Parser (Maybe ChatMember)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"new_chat_member"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatMember
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, actor_user_id :: Maybe Int
actor_user_id = Maybe Int
actor_user_id_
, date :: Maybe Int
date = Maybe Int
date_
, invite_link :: Maybe ChatInviteLink
invite_link = Maybe ChatInviteLink
invite_link_
, via_join_request :: Maybe Bool
via_join_request = Maybe Bool
via_join_request_
, via_chat_folder_invite_link :: Maybe Bool
via_chat_folder_invite_link = Maybe Bool
via_chat_folder_invite_link_
, old_chat_member :: Maybe ChatMember
old_chat_member = Maybe ChatMember
old_chat_member_
, new_chat_member :: Maybe ChatMember
new_chat_member = Maybe ChatMember
new_chat_member_
}
parseUpdateNewChatJoinRequest :: A.Value -> AT.Parser Update
parseUpdateNewChatJoinRequest :: Value -> Parser Update
parseUpdateNewChatJoinRequest = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateNewChatJoinRequest" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatJoinRequest
request_ <- Object
o Object -> Key -> Parser (Maybe ChatJoinRequest)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"request"
Maybe Int
user_chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_chat_id"
Maybe ChatInviteLink
invite_link_ <- Object
o Object -> Key -> Parser (Maybe ChatInviteLink)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"invite_link"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateNewChatJoinRequest
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, request :: Maybe ChatJoinRequest
request = Maybe ChatJoinRequest
request_
, user_chat_id :: Maybe Int
user_chat_id = Maybe Int
user_chat_id_
, invite_link :: Maybe ChatInviteLink
invite_link = Maybe ChatInviteLink
invite_link_
}
parseUpdateChatBoost :: A.Value -> AT.Parser Update
parseUpdateChatBoost :: Value -> Parser Update
parseUpdateChatBoost = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateChatBoost" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe ChatBoost
boost_ <- Object
o Object -> Key -> Parser (Maybe ChatBoost)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"boost"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateChatBoost
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, boost :: Maybe ChatBoost
boost = Maybe ChatBoost
boost_
}
parseUpdateMessageReaction :: A.Value -> AT.Parser Update
parseUpdateMessageReaction :: Value -> Parser Update
parseUpdateMessageReaction = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageReaction" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe MessageSender
actor_id_ <- Object
o Object -> Key -> Parser (Maybe MessageSender)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"actor_id"
Maybe Int
date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"date"
Maybe [ReactionType]
old_reaction_types_ <- Object
o Object -> Key -> Parser (Maybe [ReactionType])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"old_reaction_types"
Maybe [ReactionType]
new_reaction_types_ <- Object
o Object -> Key -> Parser (Maybe [ReactionType])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"new_reaction_types"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageReaction
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, actor_id :: Maybe MessageSender
actor_id = Maybe MessageSender
actor_id_
, date :: Maybe Int
date = Maybe Int
date_
, old_reaction_types :: Maybe [ReactionType]
old_reaction_types = Maybe [ReactionType]
old_reaction_types_
, new_reaction_types :: Maybe [ReactionType]
new_reaction_types = Maybe [ReactionType]
new_reaction_types_
}
parseUpdateMessageReactions :: A.Value -> AT.Parser Update
parseUpdateMessageReactions :: Value -> Parser Update
parseUpdateMessageReactions = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdateMessageReactions" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
chat_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"chat_id"
Maybe Int
message_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"message_id"
Maybe Int
date_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"date"
Maybe [MessageReaction]
reactions_ <- Object
o Object -> Key -> Parser (Maybe [MessageReaction])
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"reactions"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdateMessageReactions
{ chat_id :: Maybe Int
chat_id = Maybe Int
chat_id_
, message_id :: Maybe Int
message_id = Maybe Int
message_id_
, date :: Maybe Int
date = Maybe Int
date_
, reactions :: Maybe [MessageReaction]
reactions = Maybe [MessageReaction]
reactions_
}
parseUpdatePaidMediaPurchased :: A.Value -> AT.Parser Update
parseUpdatePaidMediaPurchased :: Value -> Parser Update
parseUpdatePaidMediaPurchased = String -> (Object -> Parser Update) -> Value -> Parser Update
forall a. String -> (Object -> Parser a) -> Value -> Parser a
A.withObject String
"UpdatePaidMediaPurchased" ((Object -> Parser Update) -> Value -> Parser Update)
-> (Object -> Parser Update) -> Value -> Parser Update
forall a b. (a -> b) -> a -> b
$ \Object
o -> do
Maybe Int
user_id_ <- Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"user_id"
Maybe Text
_payload_ <- Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
A..:? Key
"payload"
Update -> Parser Update
forall a. a -> Parser a
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Update -> Parser Update) -> Update -> Parser Update
forall a b. (a -> b) -> a -> b
$ UpdatePaidMediaPurchased
{ user_id :: Maybe Int
user_id = Maybe Int
user_id_
, _payload :: Maybe Text
_payload = Maybe Text
_payload_
}
parseJSON Value
_ = Parser Update
forall a. Monoid a => a
mempty