client

package
v0.0.0-...-9597215 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 26, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClassAuthenticationCodeType                 = "AuthenticationCodeType"
	ClassAuthorizationState                     = "AuthorizationState"
	ClassInputFile                              = "InputFile"
	ClassThumbnailFormat                        = "ThumbnailFormat"
	ClassMaskPoint                              = "MaskPoint"
	ClassPollType                               = "PollType"
	ClassUserType                               = "UserType"
	ClassInputChatPhoto                         = "InputChatPhoto"
	ClassChatMemberStatus                       = "ChatMemberStatus"
	ClassChatMembersFilter                      = "ChatMembersFilter"
	ClassSupergroupMembersFilter                = "SupergroupMembersFilter"
	ClassSecretChatState                        = "SecretChatState"
	ClassMessageSender                          = "MessageSender"
	ClassMessageForwardOrigin                   = "MessageForwardOrigin"
	ClassMessageSendingState                    = "MessageSendingState"
	ClassNotificationSettingsScope              = "NotificationSettingsScope"
	ClassChatType                               = "ChatType"
	ClassChatList                               = "ChatList"
	ClassChatSource                             = "ChatSource"
	ClassPublicChatType                         = "PublicChatType"
	ClassChatActionBar                          = "ChatActionBar"
	ClassKeyboardButtonType                     = "KeyboardButtonType"
	ClassInlineKeyboardButtonType               = "InlineKeyboardButtonType"
	ClassReplyMarkup                            = "ReplyMarkup"
	ClassLoginUrlInfo                           = "LoginUrlInfo"
	ClassRichText                               = "RichText"
	ClassPageBlockHorizontalAlignment           = "PageBlockHorizontalAlignment"
	ClassPageBlockVerticalAlignment             = "PageBlockVerticalAlignment"
	ClassPageBlock                              = "PageBlock"
	ClassInputCredentials                       = "InputCredentials"
	ClassPassportElementType                    = "PassportElementType"
	ClassPassportElement                        = "PassportElement"
	ClassInputPassportElement                   = "InputPassportElement"
	ClassPassportElementErrorSource             = "PassportElementErrorSource"
	ClassInputPassportElementErrorSource        = "InputPassportElementErrorSource"
	ClassMessageContent                         = "MessageContent"
	ClassTextEntityType                         = "TextEntityType"
	ClassMessageSchedulingState                 = "MessageSchedulingState"
	ClassInputMessageContent                    = "InputMessageContent"
	ClassSearchMessagesFilter                   = "SearchMessagesFilter"
	ClassChatAction                             = "ChatAction"
	ClassUserStatus                             = "UserStatus"
	ClassCallDiscardReason                      = "CallDiscardReason"
	ClassCallServerType                         = "CallServerType"
	ClassCallState                              = "CallState"
	ClassCallProblem                            = "CallProblem"
	ClassDiceStickers                           = "DiceStickers"
	ClassInputInlineQueryResult                 = "InputInlineQueryResult"
	ClassInlineQueryResult                      = "InlineQueryResult"
	ClassCallbackQueryPayload                   = "CallbackQueryPayload"
	ClassChatEventAction                        = "ChatEventAction"
	ClassLanguagePackStringValue                = "LanguagePackStringValue"
	ClassDeviceToken                            = "DeviceToken"
	ClassBackgroundFill                         = "BackgroundFill"
	ClassBackgroundType                         = "BackgroundType"
	ClassInputBackground                        = "InputBackground"
	ClassCanTransferOwnershipResult             = "CanTransferOwnershipResult"
	ClassCheckChatUsernameResult                = "CheckChatUsernameResult"
	ClassPushMessageContent                     = "PushMessageContent"
	ClassNotificationType                       = "NotificationType"
	ClassNotificationGroupType                  = "NotificationGroupType"
	ClassOptionValue                            = "OptionValue"
	ClassJsonValue                              = "JsonValue"
	ClassUserPrivacySettingRule                 = "UserPrivacySettingRule"
	ClassUserPrivacySetting                     = "UserPrivacySetting"
	ClassChatReportReason                       = "ChatReportReason"
	ClassFileType                               = "FileType"
	ClassNetworkType                            = "NetworkType"
	ClassNetworkStatisticsEntry                 = "NetworkStatisticsEntry"
	ClassConnectionState                        = "ConnectionState"
	ClassTopChatCategory                        = "TopChatCategory"
	ClassTMeUrlType                             = "TMeUrlType"
	ClassSuggestedAction                        = "SuggestedAction"
	ClassTextParseMode                          = "TextParseMode"
	ClassProxyType                              = "ProxyType"
	ClassInputSticker                           = "InputSticker"
	ClassStatisticalGraph                       = "StatisticalGraph"
	ClassChatStatistics                         = "ChatStatistics"
	ClassUpdate                                 = "Update"
	ClassLogStream                              = "LogStream"
	ClassError                                  = "Error"
	ClassOk                                     = "Ok"
	ClassTdlibParameters                        = "TdlibParameters"
	ClassAuthenticationCodeInfo                 = "AuthenticationCodeInfo"
	ClassEmailAddressAuthenticationCodeInfo     = "EmailAddressAuthenticationCodeInfo"
	ClassTextEntity                             = "TextEntity"
	ClassTextEntities                           = "TextEntities"
	ClassFormattedText                          = "FormattedText"
	ClassTermsOfService                         = "TermsOfService"
	ClassPasswordState                          = "PasswordState"
	ClassRecoveryEmailAddress                   = "RecoveryEmailAddress"
	ClassTemporaryPasswordState                 = "TemporaryPasswordState"
	ClassLocalFile                              = "LocalFile"
	ClassRemoteFile                             = "RemoteFile"
	ClassFile                                   = "File"
	ClassPhotoSize                              = "PhotoSize"
	ClassMinithumbnail                          = "Minithumbnail"
	ClassThumbnail                              = "Thumbnail"
	ClassMaskPosition                           = "MaskPosition"
	ClassPollOption                             = "PollOption"
	ClassAnimation                              = "Animation"
	ClassAudio                                  = "Audio"
	ClassDocument                               = "Document"
	ClassPhoto                                  = "Photo"
	ClassSticker                                = "Sticker"
	ClassVideo                                  = "Video"
	ClassVideoNote                              = "VideoNote"
	ClassVoiceNote                              = "VoiceNote"
	ClassContact                                = "Contact"
	ClassLocation                               = "Location"
	ClassVenue                                  = "Venue"
	ClassGame                                   = "Game"
	ClassPoll                                   = "Poll"
	ClassProfilePhoto                           = "ProfilePhoto"
	ClassChatPhotoInfo                          = "ChatPhotoInfo"
	ClassBotCommand                             = "BotCommand"
	ClassBotInfo                                = "BotInfo"
	ClassChatLocation                           = "ChatLocation"
	ClassAnimatedChatPhoto                      = "AnimatedChatPhoto"
	ClassChatPhoto                              = "ChatPhoto"
	ClassChatPhotos                             = "ChatPhotos"
	ClassUser                                   = "User"
	ClassUserFullInfo                           = "UserFullInfo"
	ClassUsers                                  = "Users"
	ClassChatAdministrator                      = "ChatAdministrator"
	ClassChatAdministrators                     = "ChatAdministrators"
	ClassChatPermissions                        = "ChatPermissions"
	ClassChatMember                             = "ChatMember"
	ClassChatMembers                            = "ChatMembers"
	ClassBasicGroup                             = "BasicGroup"
	ClassBasicGroupFullInfo                     = "BasicGroupFullInfo"
	ClassSupergroup                             = "Supergroup"
	ClassSupergroupFullInfo                     = "SupergroupFullInfo"
	ClassSecretChat                             = "SecretChat"
	ClassMessageSenders                         = "MessageSenders"
	ClassMessageForwardInfo                     = "MessageForwardInfo"
	ClassMessageReplyInfo                       = "MessageReplyInfo"
	ClassMessageInteractionInfo                 = "MessageInteractionInfo"
	ClassMessage                                = "Message"
	ClassMessages                               = "Messages"
	ClassFoundMessages                          = "FoundMessages"
	ClassChatNotificationSettings               = "ChatNotificationSettings"
	ClassScopeNotificationSettings              = "ScopeNotificationSettings"
	ClassDraftMessage                           = "DraftMessage"
	ClassChatFilter                             = "ChatFilter"
	ClassChatFilterInfo                         = "ChatFilterInfo"
	ClassRecommendedChatFilter                  = "RecommendedChatFilter"
	ClassRecommendedChatFilters                 = "RecommendedChatFilters"
	ClassChatLists                              = "ChatLists"
	ClassChatPosition                           = "ChatPosition"
	ClassChat                                   = "Chat"
	ClassChats                                  = "Chats"
	ClassChatNearby                             = "ChatNearby"
	ClassChatsNearby                            = "ChatsNearby"
	ClassChatInviteLink                         = "ChatInviteLink"
	ClassChatInviteLinkInfo                     = "ChatInviteLinkInfo"
	ClassKeyboardButton                         = "KeyboardButton"
	ClassInlineKeyboardButton                   = "InlineKeyboardButton"
	ClassMessageThreadInfo                      = "MessageThreadInfo"
	ClassPageBlockCaption                       = "PageBlockCaption"
	ClassPageBlockListItem                      = "PageBlockListItem"
	ClassPageBlockTableCell                     = "PageBlockTableCell"
	ClassPageBlockRelatedArticle                = "PageBlockRelatedArticle"
	ClassWebPageInstantView                     = "WebPageInstantView"
	ClassWebPage                                = "WebPage"
	ClassCountryInfo                            = "CountryInfo"
	ClassCountries                              = "Countries"
	ClassPhoneNumberInfo                        = "PhoneNumberInfo"
	ClassBankCardActionOpenUrl                  = "BankCardActionOpenUrl"
	ClassBankCardInfo                           = "BankCardInfo"
	ClassAddress                                = "Address"
	ClassLabeledPricePart                       = "LabeledPricePart"
	ClassInvoice                                = "Invoice"
	ClassOrderInfo                              = "OrderInfo"
	ClassShippingOption                         = "ShippingOption"
	ClassSavedCredentials                       = "SavedCredentials"
	ClassPaymentsProviderStripe                 = "PaymentsProviderStripe"
	ClassPaymentForm                            = "PaymentForm"
	ClassValidatedOrderInfo                     = "ValidatedOrderInfo"
	ClassPaymentResult                          = "PaymentResult"
	ClassPaymentReceipt                         = "PaymentReceipt"
	ClassDatedFile                              = "DatedFile"
	ClassDate                                   = "Date"
	ClassPersonalDetails                        = "PersonalDetails"
	ClassIdentityDocument                       = "IdentityDocument"
	ClassInputIdentityDocument                  = "InputIdentityDocument"
	ClassPersonalDocument                       = "PersonalDocument"
	ClassInputPersonalDocument                  = "InputPersonalDocument"
	ClassPassportElements                       = "PassportElements"
	ClassPassportElementError                   = "PassportElementError"
	ClassPassportSuitableElement                = "PassportSuitableElement"
	ClassPassportRequiredElement                = "PassportRequiredElement"
	ClassPassportAuthorizationForm              = "PassportAuthorizationForm"
	ClassPassportElementsWithErrors             = "PassportElementsWithErrors"
	ClassEncryptedCredentials                   = "EncryptedCredentials"
	ClassEncryptedPassportElement               = "EncryptedPassportElement"
	ClassInputPassportElementError              = "InputPassportElementError"
	ClassInputThumbnail                         = "InputThumbnail"
	ClassMessageSendOptions                     = "MessageSendOptions"
	ClassMessageCopyOptions                     = "MessageCopyOptions"
	ClassStickers                               = "Stickers"
	ClassEmojis                                 = "Emojis"
	ClassStickerSet                             = "StickerSet"
	ClassStickerSetInfo                         = "StickerSetInfo"
	ClassStickerSets                            = "StickerSets"
	ClassCallProtocol                           = "CallProtocol"
	ClassCallServer                             = "CallServer"
	ClassCallId                                 = "CallId"
	ClassCall                                   = "Call"
	ClassPhoneNumberAuthenticationSettings      = "PhoneNumberAuthenticationSettings"
	ClassAnimations                             = "Animations"
	ClassImportedContacts                       = "ImportedContacts"
	ClassHttpUrl                                = "HttpUrl"
	ClassInlineQueryResults                     = "InlineQueryResults"
	ClassCallbackQueryAnswer                    = "CallbackQueryAnswer"
	ClassCustomRequestResult                    = "CustomRequestResult"
	ClassGameHighScore                          = "GameHighScore"
	ClassGameHighScores                         = "GameHighScores"
	ClassChatEvent                              = "ChatEvent"
	ClassChatEvents                             = "ChatEvents"
	ClassChatEventLogFilters                    = "ChatEventLogFilters"
	ClassLanguagePackString                     = "LanguagePackString"
	ClassLanguagePackStrings                    = "LanguagePackStrings"
	ClassLanguagePackInfo                       = "LanguagePackInfo"
	ClassLocalizationTargetInfo                 = "LocalizationTargetInfo"
	ClassPushReceiverId                         = "PushReceiverId"
	ClassBackground                             = "Background"
	ClassBackgrounds                            = "Backgrounds"
	ClassHashtags                               = "Hashtags"
	ClassNotification                           = "Notification"
	ClassNotificationGroup                      = "NotificationGroup"
	ClassJsonObjectMember                       = "JsonObjectMember"
	ClassUserPrivacySettingRules                = "UserPrivacySettingRules"
	ClassAccountTtl                             = "AccountTtl"
	ClassSession                                = "Session"
	ClassSessions                               = "Sessions"
	ClassConnectedWebsite                       = "ConnectedWebsite"
	ClassConnectedWebsites                      = "ConnectedWebsites"
	ClassMessageLink                            = "MessageLink"
	ClassMessageLinkInfo                        = "MessageLinkInfo"
	ClassFilePart                               = "FilePart"
	ClassStorageStatisticsByFileType            = "StorageStatisticsByFileType"
	ClassStorageStatisticsByChat                = "StorageStatisticsByChat"
	ClassStorageStatistics                      = "StorageStatistics"
	ClassStorageStatisticsFast                  = "StorageStatisticsFast"
	ClassDatabaseStatistics                     = "DatabaseStatistics"
	ClassNetworkStatistics                      = "NetworkStatistics"
	ClassAutoDownloadSettings                   = "AutoDownloadSettings"
	ClassAutoDownloadSettingsPresets            = "AutoDownloadSettingsPresets"
	ClassTMeUrl                                 = "TMeUrl"
	ClassTMeUrls                                = "TMeUrls"
	ClassCount                                  = "Count"
	ClassText                                   = "Text"
	ClassSeconds                                = "Seconds"
	ClassDeepLinkInfo                           = "DeepLinkInfo"
	ClassProxy                                  = "Proxy"
	ClassProxies                                = "Proxies"
	ClassDateRange                              = "DateRange"
	ClassStatisticalValue                       = "StatisticalValue"
	ClassChatStatisticsMessageInteractionInfo   = "ChatStatisticsMessageInteractionInfo"
	ClassChatStatisticsMessageSenderInfo        = "ChatStatisticsMessageSenderInfo"
	ClassChatStatisticsAdministratorActionsInfo = "ChatStatisticsAdministratorActionsInfo"
	ClassChatStatisticsInviterInfo              = "ChatStatisticsInviterInfo"
	ClassMessageStatistics                      = "MessageStatistics"
	ClassUpdates                                = "Updates"
	ClassLogVerbosityLevel                      = "LogVerbosityLevel"
	ClassLogTags                                = "LogTags"
	ClassTestInt                                = "TestInt"
	ClassTestString                             = "TestString"
	ClassTestBytes                              = "TestBytes"
	ClassTestVectorInt                          = "TestVectorInt"
	ClassTestVectorIntObject                    = "TestVectorIntObject"
	ClassTestVectorString                       = "TestVectorString"
	ClassTestVectorStringObject                 = "TestVectorStringObject"
)
View Source
const (
	TypeError                                           = "error"
	TypeOk                                              = "ok"
	TypeTdlibParameters                                 = "tdlibParameters"
	TypeAuthenticationCodeTypeTelegramMessage           = "authenticationCodeTypeTelegramMessage"
	TypeAuthenticationCodeTypeSms                       = "authenticationCodeTypeSms"
	TypeAuthenticationCodeTypeCall                      = "authenticationCodeTypeCall"
	TypeAuthenticationCodeTypeFlashCall                 = "authenticationCodeTypeFlashCall"
	TypeAuthenticationCodeInfo                          = "authenticationCodeInfo"
	TypeEmailAddressAuthenticationCodeInfo              = "emailAddressAuthenticationCodeInfo"
	TypeTextEntity                                      = "textEntity"
	TypeTextEntities                                    = "textEntities"
	TypeFormattedText                                   = "formattedText"
	TypeTermsOfService                                  = "termsOfService"
	TypeAuthorizationStateWaitTdlibParameters           = "authorizationStateWaitTdlibParameters"
	TypeAuthorizationStateWaitEncryptionKey             = "authorizationStateWaitEncryptionKey"
	TypeAuthorizationStateWaitPhoneNumber               = "authorizationStateWaitPhoneNumber"
	TypeAuthorizationStateWaitCode                      = "authorizationStateWaitCode"
	TypeAuthorizationStateWaitOtherDeviceConfirmation   = "authorizationStateWaitOtherDeviceConfirmation"
	TypeAuthorizationStateWaitRegistration              = "authorizationStateWaitRegistration"
	TypeAuthorizationStateWaitPassword                  = "authorizationStateWaitPassword"
	TypeAuthorizationStateReady                         = "authorizationStateReady"
	TypeAuthorizationStateLoggingOut                    = "authorizationStateLoggingOut"
	TypeAuthorizationStateClosing                       = "authorizationStateClosing"
	TypeAuthorizationStateClosed                        = "authorizationStateClosed"
	TypePasswordState                                   = "passwordState"
	TypeRecoveryEmailAddress                            = "recoveryEmailAddress"
	TypeTemporaryPasswordState                          = "temporaryPasswordState"
	TypeLocalFile                                       = "localFile"
	TypeRemoteFile                                      = "remoteFile"
	TypeFile                                            = "file"
	TypeInputFileId                                     = "inputFileId"
	TypeInputFileRemote                                 = "inputFileRemote"
	TypeInputFileLocal                                  = "inputFileLocal"
	TypeInputFileGenerated                              = "inputFileGenerated"
	TypePhotoSize                                       = "photoSize"
	TypeMinithumbnail                                   = "minithumbnail"
	TypeThumbnailFormatJpeg                             = "thumbnailFormatJpeg"
	TypeThumbnailFormatPng                              = "thumbnailFormatPng"
	TypeThumbnailFormatWebp                             = "thumbnailFormatWebp"
	TypeThumbnailFormatGif                              = "thumbnailFormatGif"
	TypeThumbnailFormatTgs                              = "thumbnailFormatTgs"
	TypeThumbnailFormatMpeg4                            = "thumbnailFormatMpeg4"
	TypeThumbnail                                       = "thumbnail"
	TypeMaskPointForehead                               = "maskPointForehead"
	TypeMaskPointEyes                                   = "maskPointEyes"
	TypeMaskPointMouth                                  = "maskPointMouth"
	TypeMaskPointChin                                   = "maskPointChin"
	TypeMaskPosition                                    = "maskPosition"
	TypePollOption                                      = "pollOption"
	TypePollTypeRegular                                 = "pollTypeRegular"
	TypePollTypeQuiz                                    = "pollTypeQuiz"
	TypeAnimation                                       = "animation"
	TypeAudio                                           = "audio"
	TypeDocument                                        = "document"
	TypePhoto                                           = "photo"
	TypeSticker                                         = "sticker"
	TypeVideo                                           = "video"
	TypeVideoNote                                       = "videoNote"
	TypeVoiceNote                                       = "voiceNote"
	TypeContact                                         = "contact"
	TypeLocation                                        = "location"
	TypeVenue                                           = "venue"
	TypeGame                                            = "game"
	TypePoll                                            = "poll"
	TypeProfilePhoto                                    = "profilePhoto"
	TypeChatPhotoInfo                                   = "chatPhotoInfo"
	TypeUserTypeRegular                                 = "userTypeRegular"
	TypeUserTypeDeleted                                 = "userTypeDeleted"
	TypeUserTypeBot                                     = "userTypeBot"
	TypeUserTypeUnknown                                 = "userTypeUnknown"
	TypeBotCommand                                      = "botCommand"
	TypeBotInfo                                         = "botInfo"
	TypeChatLocation                                    = "chatLocation"
	TypeAnimatedChatPhoto                               = "animatedChatPhoto"
	TypeChatPhoto                                       = "chatPhoto"
	TypeChatPhotos                                      = "chatPhotos"
	TypeInputChatPhotoPrevious                          = "inputChatPhotoPrevious"
	TypeInputChatPhotoStatic                            = "inputChatPhotoStatic"
	TypeInputChatPhotoAnimation                         = "inputChatPhotoAnimation"
	TypeUser                                            = "user"
	TypeUserFullInfo                                    = "userFullInfo"
	TypeUsers                                           = "users"
	TypeChatAdministrator                               = "chatAdministrator"
	TypeChatAdministrators                              = "chatAdministrators"
	TypeChatPermissions                                 = "chatPermissions"
	TypeChatMemberStatusCreator                         = "chatMemberStatusCreator"
	TypeChatMemberStatusAdministrator                   = "chatMemberStatusAdministrator"
	TypeChatMemberStatusMember                          = "chatMemberStatusMember"
	TypeChatMemberStatusRestricted                      = "chatMemberStatusRestricted"
	TypeChatMemberStatusLeft                            = "chatMemberStatusLeft"
	TypeChatMemberStatusBanned                          = "chatMemberStatusBanned"
	TypeChatMember                                      = "chatMember"
	TypeChatMembers                                     = "chatMembers"
	TypeChatMembersFilterContacts                       = "chatMembersFilterContacts"
	TypeChatMembersFilterAdministrators                 = "chatMembersFilterAdministrators"
	TypeChatMembersFilterMembers                        = "chatMembersFilterMembers"
	TypeChatMembersFilterMention                        = "chatMembersFilterMention"
	TypeChatMembersFilterRestricted                     = "chatMembersFilterRestricted"
	TypeChatMembersFilterBanned                         = "chatMembersFilterBanned"
	TypeChatMembersFilterBots                           = "chatMembersFilterBots"
	TypeSupergroupMembersFilterRecent                   = "supergroupMembersFilterRecent"
	TypeSupergroupMembersFilterContacts                 = "supergroupMembersFilterContacts"
	TypeSupergroupMembersFilterAdministrators           = "supergroupMembersFilterAdministrators"
	TypeSupergroupMembersFilterSearch                   = "supergroupMembersFilterSearch"
	TypeSupergroupMembersFilterRestricted               = "supergroupMembersFilterRestricted"
	TypeSupergroupMembersFilterBanned                   = "supergroupMembersFilterBanned"
	TypeSupergroupMembersFilterMention                  = "supergroupMembersFilterMention"
	TypeSupergroupMembersFilterBots                     = "supergroupMembersFilterBots"
	TypeBasicGroup                                      = "basicGroup"
	TypeBasicGroupFullInfo                              = "basicGroupFullInfo"
	TypeSupergroup                                      = "supergroup"
	TypeSupergroupFullInfo                              = "supergroupFullInfo"
	TypeSecretChatStatePending                          = "secretChatStatePending"
	TypeSecretChatStateReady                            = "secretChatStateReady"
	TypeSecretChatStateClosed                           = "secretChatStateClosed"
	TypeSecretChat                                      = "secretChat"
	TypeMessageSenderUser                               = "messageSenderUser"
	TypeMessageSenderChat                               = "messageSenderChat"
	TypeMessageSenders                                  = "messageSenders"
	TypeMessageForwardOriginUser                        = "messageForwardOriginUser"
	TypeMessageForwardOriginChat                        = "messageForwardOriginChat"
	TypeMessageForwardOriginHiddenUser                  = "messageForwardOriginHiddenUser"
	TypeMessageForwardOriginChannel                     = "messageForwardOriginChannel"
	TypeMessageForwardInfo                              = "messageForwardInfo"
	TypeMessageReplyInfo                                = "messageReplyInfo"
	TypeMessageInteractionInfo                          = "messageInteractionInfo"
	TypeMessageSendingStatePending                      = "messageSendingStatePending"
	TypeMessageSendingStateFailed                       = "messageSendingStateFailed"
	TypeMessage                                         = "message"
	TypeMessages                                        = "messages"
	TypeFoundMessages                                   = "foundMessages"
	TypeNotificationSettingsScopePrivateChats           = "notificationSettingsScopePrivateChats"
	TypeNotificationSettingsScopeGroupChats             = "notificationSettingsScopeGroupChats"
	TypeNotificationSettingsScopeChannelChats           = "notificationSettingsScopeChannelChats"
	TypeChatNotificationSettings                        = "chatNotificationSettings"
	TypeScopeNotificationSettings                       = "scopeNotificationSettings"
	TypeDraftMessage                                    = "draftMessage"
	TypeChatTypePrivate                                 = "chatTypePrivate"
	TypeChatTypeBasicGroup                              = "chatTypeBasicGroup"
	TypeChatTypeSupergroup                              = "chatTypeSupergroup"
	TypeChatTypeSecret                                  = "chatTypeSecret"
	TypeChatFilter                                      = "chatFilter"
	TypeChatFilterInfo                                  = "chatFilterInfo"
	TypeRecommendedChatFilter                           = "recommendedChatFilter"
	TypeRecommendedChatFilters                          = "recommendedChatFilters"
	TypeChatListMain                                    = "chatListMain"
	TypeChatListArchive                                 = "chatListArchive"
	TypeChatListFilter                                  = "chatListFilter"
	TypeChatLists                                       = "chatLists"
	TypeChatSourceMtprotoProxy                          = "chatSourceMtprotoProxy"
	TypeChatSourcePublicServiceAnnouncement             = "chatSourcePublicServiceAnnouncement"
	TypeChatPosition                                    = "chatPosition"
	TypeChat                                            = "chat"
	TypeChats                                           = "chats"
	TypeChatNearby                                      = "chatNearby"
	TypeChatsNearby                                     = "chatsNearby"
	TypeChatInviteLink                                  = "chatInviteLink"
	TypeChatInviteLinkInfo                              = "chatInviteLinkInfo"
	TypePublicChatTypeHasUsername                       = "publicChatTypeHasUsername"
	TypePublicChatTypeIsLocationBased                   = "publicChatTypeIsLocationBased"
	TypeChatActionBarReportSpam                         = "chatActionBarReportSpam"
	TypeChatActionBarReportUnrelatedLocation            = "chatActionBarReportUnrelatedLocation"
	TypeChatActionBarReportAddBlock                     = "chatActionBarReportAddBlock"
	TypeChatActionBarAddContact                         = "chatActionBarAddContact"
	TypeChatActionBarSharePhoneNumber                   = "chatActionBarSharePhoneNumber"
	TypeKeyboardButtonTypeText                          = "keyboardButtonTypeText"
	TypeKeyboardButtonTypeRequestPhoneNumber            = "keyboardButtonTypeRequestPhoneNumber"
	TypeKeyboardButtonTypeRequestLocation               = "keyboardButtonTypeRequestLocation"
	TypeKeyboardButtonTypeRequestPoll                   = "keyboardButtonTypeRequestPoll"
	TypeKeyboardButton                                  = "keyboardButton"
	TypeInlineKeyboardButtonTypeUrl                     = "inlineKeyboardButtonTypeUrl"
	TypeInlineKeyboardButtonTypeLoginUrl                = "inlineKeyboardButtonTypeLoginUrl"
	TypeInlineKeyboardButtonTypeCallback                = "inlineKeyboardButtonTypeCallback"
	TypeInlineKeyboardButtonTypeCallbackWithPassword    = "inlineKeyboardButtonTypeCallbackWithPassword"
	TypeInlineKeyboardButtonTypeCallbackGame            = "inlineKeyboardButtonTypeCallbackGame"
	TypeInlineKeyboardButtonTypeSwitchInline            = "inlineKeyboardButtonTypeSwitchInline"
	TypeInlineKeyboardButtonTypeBuy                     = "inlineKeyboardButtonTypeBuy"
	TypeInlineKeyboardButton                            = "inlineKeyboardButton"
	TypeReplyMarkupRemoveKeyboard                       = "replyMarkupRemoveKeyboard"
	TypeReplyMarkupForceReply                           = "replyMarkupForceReply"
	TypeReplyMarkupShowKeyboard                         = "replyMarkupShowKeyboard"
	TypeReplyMarkupInlineKeyboard                       = "replyMarkupInlineKeyboard"
	TypeLoginUrlInfoOpen                                = "loginUrlInfoOpen"
	TypeLoginUrlInfoRequestConfirmation                 = "loginUrlInfoRequestConfirmation"
	TypeMessageThreadInfo                               = "messageThreadInfo"
	TypeRichTextPlain                                   = "richTextPlain"
	TypeRichTextBold                                    = "richTextBold"
	TypeRichTextItalic                                  = "richTextItalic"
	TypeRichTextUnderline                               = "richTextUnderline"
	TypeRichTextStrikethrough                           = "richTextStrikethrough"
	TypeRichTextFixed                                   = "richTextFixed"
	TypeRichTextUrl                                     = "richTextUrl"
	TypeRichTextEmailAddress                            = "richTextEmailAddress"
	TypeRichTextSubscript                               = "richTextSubscript"
	TypeRichTextSuperscript                             = "richTextSuperscript"
	TypeRichTextMarked                                  = "richTextMarked"
	TypeRichTextPhoneNumber                             = "richTextPhoneNumber"
	TypeRichTextIcon                                    = "richTextIcon"
	TypeRichTextReference                               = "richTextReference"
	TypeRichTextAnchor                                  = "richTextAnchor"
	TypeRichTextAnchorLink                              = "richTextAnchorLink"
	TypeRichTexts                                       = "richTexts"
	TypePageBlockCaption                                = "pageBlockCaption"
	TypePageBlockListItem                               = "pageBlockListItem"
	TypePageBlockHorizontalAlignmentLeft                = "pageBlockHorizontalAlignmentLeft"
	TypePageBlockHorizontalAlignmentCenter              = "pageBlockHorizontalAlignmentCenter"
	TypePageBlockHorizontalAlignmentRight               = "pageBlockHorizontalAlignmentRight"
	TypePageBlockVerticalAlignmentTop                   = "pageBlockVerticalAlignmentTop"
	TypePageBlockVerticalAlignmentMiddle                = "pageBlockVerticalAlignmentMiddle"
	TypePageBlockVerticalAlignmentBottom                = "pageBlockVerticalAlignmentBottom"
	TypePageBlockTableCell                              = "pageBlockTableCell"
	TypePageBlockRelatedArticle                         = "pageBlockRelatedArticle"
	TypePageBlockTitle                                  = "pageBlockTitle"
	TypePageBlockSubtitle                               = "pageBlockSubtitle"
	TypePageBlockAuthorDate                             = "pageBlockAuthorDate"
	TypePageBlockHeader                                 = "pageBlockHeader"
	TypePageBlockSubheader                              = "pageBlockSubheader"
	TypePageBlockKicker                                 = "pageBlockKicker"
	TypePageBlockParagraph                              = "pageBlockParagraph"
	TypePageBlockPreformatted                           = "pageBlockPreformatted"
	TypePageBlockFooter                                 = "pageBlockFooter"
	TypePageBlockDivider                                = "pageBlockDivider"
	TypePageBlockAnchor                                 = "pageBlockAnchor"
	TypePageBlockList                                   = "pageBlockList"
	TypePageBlockBlockQuote                             = "pageBlockBlockQuote"
	TypePageBlockPullQuote                              = "pageBlockPullQuote"
	TypePageBlockAnimation                              = "pageBlockAnimation"
	TypePageBlockAudio                                  = "pageBlockAudio"
	TypePageBlockPhoto                                  = "pageBlockPhoto"
	TypePageBlockVideo                                  = "pageBlockVideo"
	TypePageBlockVoiceNote                              = "pageBlockVoiceNote"
	TypePageBlockCover                                  = "pageBlockCover"
	TypePageBlockEmbedded                               = "pageBlockEmbedded"
	TypePageBlockEmbeddedPost                           = "pageBlockEmbeddedPost"
	TypePageBlockCollage                                = "pageBlockCollage"
	TypePageBlockSlideshow                              = "pageBlockSlideshow"
	TypePageBlockChatLink                               = "pageBlockChatLink"
	TypePageBlockTable                                  = "pageBlockTable"
	TypePageBlockDetails                                = "pageBlockDetails"
	TypePageBlockRelatedArticles                        = "pageBlockRelatedArticles"
	TypePageBlockMap                                    = "pageBlockMap"
	TypeWebPageInstantView                              = "webPageInstantView"
	TypeWebPage                                         = "webPage"
	TypeCountryInfo                                     = "countryInfo"
	TypeCountries                                       = "countries"
	TypePhoneNumberInfo                                 = "phoneNumberInfo"
	TypeBankCardActionOpenUrl                           = "bankCardActionOpenUrl"
	TypeBankCardInfo                                    = "bankCardInfo"
	TypeAddress                                         = "address"
	TypeLabeledPricePart                                = "labeledPricePart"
	TypeInvoice                                         = "invoice"
	TypeOrderInfo                                       = "orderInfo"
	TypeShippingOption                                  = "shippingOption"
	TypeSavedCredentials                                = "savedCredentials"
	TypeInputCredentialsSaved                           = "inputCredentialsSaved"
	TypeInputCredentialsNew                             = "inputCredentialsNew"
	TypeInputCredentialsAndroidPay                      = "inputCredentialsAndroidPay"
	TypeInputCredentialsApplePay                        = "inputCredentialsApplePay"
	TypePaymentsProviderStripe                          = "paymentsProviderStripe"
	TypePaymentForm                                     = "paymentForm"
	TypeValidatedOrderInfo                              = "validatedOrderInfo"
	TypePaymentResult                                   = "paymentResult"
	TypePaymentReceipt                                  = "paymentReceipt"
	TypeDatedFile                                       = "datedFile"
	TypePassportElementTypePersonalDetails              = "passportElementTypePersonalDetails"
	TypePassportElementTypePassport                     = "passportElementTypePassport"
	TypePassportElementTypeDriverLicense                = "passportElementTypeDriverLicense"
	TypePassportElementTypeIdentityCard                 = "passportElementTypeIdentityCard"
	TypePassportElementTypeInternalPassport             = "passportElementTypeInternalPassport"
	TypePassportElementTypeAddress                      = "passportElementTypeAddress"
	TypePassportElementTypeUtilityBill                  = "passportElementTypeUtilityBill"
	TypePassportElementTypeBankStatement                = "passportElementTypeBankStatement"
	TypePassportElementTypeRentalAgreement              = "passportElementTypeRentalAgreement"
	TypePassportElementTypePassportRegistration         = "passportElementTypePassportRegistration"
	TypePassportElementTypeTemporaryRegistration        = "passportElementTypeTemporaryRegistration"
	TypePassportElementTypePhoneNumber                  = "passportElementTypePhoneNumber"
	TypePassportElementTypeEmailAddress                 = "passportElementTypeEmailAddress"
	TypeDate                                            = "date"
	TypePersonalDetails                                 = "personalDetails"
	TypeIdentityDocument                                = "identityDocument"
	TypeInputIdentityDocument                           = "inputIdentityDocument"
	TypePersonalDocument                                = "personalDocument"
	TypeInputPersonalDocument                           = "inputPersonalDocument"
	TypePassportElementPersonalDetails                  = "passportElementPersonalDetails"
	TypePassportElementPassport                         = "passportElementPassport"
	TypePassportElementDriverLicense                    = "passportElementDriverLicense"
	TypePassportElementIdentityCard                     = "passportElementIdentityCard"
	TypePassportElementInternalPassport                 = "passportElementInternalPassport"
	TypePassportElementAddress                          = "passportElementAddress"
	TypePassportElementUtilityBill                      = "passportElementUtilityBill"
	TypePassportElementBankStatement                    = "passportElementBankStatement"
	TypePassportElementRentalAgreement                  = "passportElementRentalAgreement"
	TypePassportElementPassportRegistration             = "passportElementPassportRegistration"
	TypePassportElementTemporaryRegistration            = "passportElementTemporaryRegistration"
	TypePassportElementPhoneNumber                      = "passportElementPhoneNumber"
	TypePassportElementEmailAddress                     = "passportElementEmailAddress"
	TypeInputPassportElementPersonalDetails             = "inputPassportElementPersonalDetails"
	TypeInputPassportElementPassport                    = "inputPassportElementPassport"
	TypeInputPassportElementDriverLicense               = "inputPassportElementDriverLicense"
	TypeInputPassportElementIdentityCard                = "inputPassportElementIdentityCard"
	TypeInputPassportElementInternalPassport            = "inputPassportElementInternalPassport"
	TypeInputPassportElementAddress                     = "inputPassportElementAddress"
	TypeInputPassportElementUtilityBill                 = "inputPassportElementUtilityBill"
	TypeInputPassportElementBankStatement               = "inputPassportElementBankStatement"
	TypeInputPassportElementRentalAgreement             = "inputPassportElementRentalAgreement"
	TypeInputPassportElementPassportRegistration        = "inputPassportElementPassportRegistration"
	TypeInputPassportElementTemporaryRegistration       = "inputPassportElementTemporaryRegistration"
	TypeInputPassportElementPhoneNumber                 = "inputPassportElementPhoneNumber"
	TypeInputPassportElementEmailAddress                = "inputPassportElementEmailAddress"
	TypePassportElements                                = "passportElements"
	TypePassportElementErrorSourceUnspecified           = "passportElementErrorSourceUnspecified"
	TypePassportElementErrorSourceDataField             = "passportElementErrorSourceDataField"
	TypePassportElementErrorSourceFrontSide             = "passportElementErrorSourceFrontSide"
	TypePassportElementErrorSourceReverseSide           = "passportElementErrorSourceReverseSide"
	TypePassportElementErrorSourceSelfie                = "passportElementErrorSourceSelfie"
	TypePassportElementErrorSourceTranslationFile       = "passportElementErrorSourceTranslationFile"
	TypePassportElementErrorSourceTranslationFiles      = "passportElementErrorSourceTranslationFiles"
	TypePassportElementErrorSourceFile                  = "passportElementErrorSourceFile"
	TypePassportElementErrorSourceFiles                 = "passportElementErrorSourceFiles"
	TypePassportElementError                            = "passportElementError"
	TypePassportSuitableElement                         = "passportSuitableElement"
	TypePassportRequiredElement                         = "passportRequiredElement"
	TypePassportAuthorizationForm                       = "passportAuthorizationForm"
	TypePassportElementsWithErrors                      = "passportElementsWithErrors"
	TypeEncryptedCredentials                            = "encryptedCredentials"
	TypeEncryptedPassportElement                        = "encryptedPassportElement"
	TypeInputPassportElementErrorSourceUnspecified      = "inputPassportElementErrorSourceUnspecified"
	TypeInputPassportElementErrorSourceDataField        = "inputPassportElementErrorSourceDataField"
	TypeInputPassportElementErrorSourceFrontSide        = "inputPassportElementErrorSourceFrontSide"
	TypeInputPassportElementErrorSourceReverseSide      = "inputPassportElementErrorSourceReverseSide"
	TypeInputPassportElementErrorSourceSelfie           = "inputPassportElementErrorSourceSelfie"
	TypeInputPassportElementErrorSourceTranslationFile  = "inputPassportElementErrorSourceTranslationFile"
	TypeInputPassportElementErrorSourceTranslationFiles = "inputPassportElementErrorSourceTranslationFiles"
	TypeInputPassportElementErrorSourceFile             = "inputPassportElementErrorSourceFile"
	TypeInputPassportElementErrorSourceFiles            = "inputPassportElementErrorSourceFiles"
	TypeInputPassportElementError                       = "inputPassportElementError"
	TypeMessageText                                     = "messageText"
	TypeMessageAnimation                                = "messageAnimation"
	TypeMessageAudio                                    = "messageAudio"
	TypeMessageDocument                                 = "messageDocument"
	TypeMessagePhoto                                    = "messagePhoto"
	TypeMessageExpiredPhoto                             = "messageExpiredPhoto"
	TypeMessageSticker                                  = "messageSticker"
	TypeMessageVideo                                    = "messageVideo"
	TypeMessageExpiredVideo                             = "messageExpiredVideo"
	TypeMessageVideoNote                                = "messageVideoNote"
	TypeMessageVoiceNote                                = "messageVoiceNote"
	TypeMessageLocation                                 = "messageLocation"
	TypeMessageVenue                                    = "messageVenue"
	TypeMessageContact                                  = "messageContact"
	TypeMessageDice                                     = "messageDice"
	TypeMessageGame                                     = "messageGame"
	TypeMessagePoll                                     = "messagePoll"
	TypeMessageInvoice                                  = "messageInvoice"
	TypeMessageCall                                     = "messageCall"
	TypeMessageBasicGroupChatCreate                     = "messageBasicGroupChatCreate"
	TypeMessageSupergroupChatCreate                     = "messageSupergroupChatCreate"
	TypeMessageChatChangeTitle                          = "messageChatChangeTitle"
	TypeMessageChatChangePhoto                          = "messageChatChangePhoto"
	TypeMessageChatDeletePhoto                          = "messageChatDeletePhoto"
	TypeMessageChatAddMembers                           = "messageChatAddMembers"
	TypeMessageChatJoinByLink                           = "messageChatJoinByLink"
	TypeMessageChatDeleteMember                         = "messageChatDeleteMember"
	TypeMessageChatUpgradeTo                            = "messageChatUpgradeTo"
	TypeMessageChatUpgradeFrom                          = "messageChatUpgradeFrom"
	TypeMessagePinMessage                               = "messagePinMessage"
	TypeMessageScreenshotTaken                          = "messageScreenshotTaken"
	TypeMessageChatSetTtl                               = "messageChatSetTtl"
	TypeMessageCustomServiceAction                      = "messageCustomServiceAction"
	TypeMessageGameScore                                = "messageGameScore"
	TypeMessagePaymentSuccessful                        = "messagePaymentSuccessful"
	TypeMessagePaymentSuccessfulBot                     = "messagePaymentSuccessfulBot"
	TypeMessageContactRegistered                        = "messageContactRegistered"
	TypeMessageWebsiteConnected                         = "messageWebsiteConnected"
	TypeMessagePassportDataSent                         = "messagePassportDataSent"
	TypeMessagePassportDataReceived                     = "messagePassportDataReceived"
	TypeMessageProximityAlertTriggered                  = "messageProximityAlertTriggered"
	TypeMessageUnsupported                              = "messageUnsupported"
	TypeTextEntityTypeMention                           = "textEntityTypeMention"
	TypeTextEntityTypeHashtag                           = "textEntityTypeHashtag"
	TypeTextEntityTypeCashtag                           = "textEntityTypeCashtag"
	TypeTextEntityTypeBotCommand                        = "textEntityTypeBotCommand"
	TypeTextEntityTypeUrl                               = "textEntityTypeUrl"
	TypeTextEntityTypeEmailAddress                      = "textEntityTypeEmailAddress"
	TypeTextEntityTypePhoneNumber                       = "textEntityTypePhoneNumber"
	TypeTextEntityTypeBankCardNumber                    = "textEntityTypeBankCardNumber"
	TypeTextEntityTypeBold                              = "textEntityTypeBold"
	TypeTextEntityTypeItalic                            = "textEntityTypeItalic"
	TypeTextEntityTypeUnderline                         = "textEntityTypeUnderline"
	TypeTextEntityTypeStrikethrough                     = "textEntityTypeStrikethrough"
	TypeTextEntityTypeCode                              = "textEntityTypeCode"
	TypeTextEntityTypePre                               = "textEntityTypePre"
	TypeTextEntityTypePreCode                           = "textEntityTypePreCode"
	TypeTextEntityTypeTextUrl                           = "textEntityTypeTextUrl"
	TypeTextEntityTypeMentionName                       = "textEntityTypeMentionName"
	TypeInputThumbnail                                  = "inputThumbnail"
	TypeMessageSchedulingStateSendAtDate                = "messageSchedulingStateSendAtDate"
	TypeMessageSchedulingStateSendWhenOnline            = "messageSchedulingStateSendWhenOnline"
	TypeMessageSendOptions                              = "messageSendOptions"
	TypeMessageCopyOptions                              = "messageCopyOptions"
	TypeInputMessageText                                = "inputMessageText"
	TypeInputMessageAnimation                           = "inputMessageAnimation"
	TypeInputMessageAudio                               = "inputMessageAudio"
	TypeInputMessageDocument                            = "inputMessageDocument"
	TypeInputMessagePhoto                               = "inputMessagePhoto"
	TypeInputMessageSticker                             = "inputMessageSticker"
	TypeInputMessageVideo                               = "inputMessageVideo"
	TypeInputMessageVideoNote                           = "inputMessageVideoNote"
	TypeInputMessageVoiceNote                           = "inputMessageVoiceNote"
	TypeInputMessageLocation                            = "inputMessageLocation"
	TypeInputMessageVenue                               = "inputMessageVenue"
	TypeInputMessageContact                             = "inputMessageContact"
	TypeInputMessageDice                                = "inputMessageDice"
	TypeInputMessageGame                                = "inputMessageGame"
	TypeInputMessageInvoice                             = "inputMessageInvoice"
	TypeInputMessagePoll                                = "inputMessagePoll"
	TypeInputMessageForwarded                           = "inputMessageForwarded"
	TypeSearchMessagesFilterEmpty                       = "searchMessagesFilterEmpty"
	TypeSearchMessagesFilterAnimation                   = "searchMessagesFilterAnimation"
	TypeSearchMessagesFilterAudio                       = "searchMessagesFilterAudio"
	TypeSearchMessagesFilterDocument                    = "searchMessagesFilterDocument"
	TypeSearchMessagesFilterPhoto                       = "searchMessagesFilterPhoto"
	TypeSearchMessagesFilterVideo                       = "searchMessagesFilterVideo"
	TypeSearchMessagesFilterVoiceNote                   = "searchMessagesFilterVoiceNote"
	TypeSearchMessagesFilterPhotoAndVideo               = "searchMessagesFilterPhotoAndVideo"
	TypeSearchMessagesFilterUrl                         = "searchMessagesFilterUrl"
	TypeSearchMessagesFilterChatPhoto                   = "searchMessagesFilterChatPhoto"
	TypeSearchMessagesFilterCall                        = "searchMessagesFilterCall"
	TypeSearchMessagesFilterMissedCall                  = "searchMessagesFilterMissedCall"
	TypeSearchMessagesFilterVideoNote                   = "searchMessagesFilterVideoNote"
	TypeSearchMessagesFilterVoiceAndVideoNote           = "searchMessagesFilterVoiceAndVideoNote"
	TypeSearchMessagesFilterMention                     = "searchMessagesFilterMention"
	TypeSearchMessagesFilterUnreadMention               = "searchMessagesFilterUnreadMention"
	TypeSearchMessagesFilterFailedToSend                = "searchMessagesFilterFailedToSend"
	TypeSearchMessagesFilterPinned                      = "searchMessagesFilterPinned"
	TypeChatActionTyping                                = "chatActionTyping"
	TypeChatActionRecordingVideo                        = "chatActionRecordingVideo"
	TypeChatActionUploadingVideo                        = "chatActionUploadingVideo"
	TypeChatActionRecordingVoiceNote                    = "chatActionRecordingVoiceNote"
	TypeChatActionUploadingVoiceNote                    = "chatActionUploadingVoiceNote"
	TypeChatActionUploadingPhoto                        = "chatActionUploadingPhoto"
	TypeChatActionUploadingDocument                     = "chatActionUploadingDocument"
	TypeChatActionChoosingLocation                      = "chatActionChoosingLocation"
	TypeChatActionChoosingContact                       = "chatActionChoosingContact"
	TypeChatActionStartPlayingGame                      = "chatActionStartPlayingGame"
	TypeChatActionRecordingVideoNote                    = "chatActionRecordingVideoNote"
	TypeChatActionUploadingVideoNote                    = "chatActionUploadingVideoNote"
	TypeChatActionCancel                                = "chatActionCancel"
	TypeUserStatusEmpty                                 = "userStatusEmpty"
	TypeUserStatusOnline                                = "userStatusOnline"
	TypeUserStatusOffline                               = "userStatusOffline"
	TypeUserStatusRecently                              = "userStatusRecently"
	TypeUserStatusLastWeek                              = "userStatusLastWeek"
	TypeUserStatusLastMonth                             = "userStatusLastMonth"
	TypeStickers                                        = "stickers"
	TypeEmojis                                          = "emojis"
	TypeStickerSet                                      = "stickerSet"
	TypeStickerSetInfo                                  = "stickerSetInfo"
	TypeStickerSets                                     = "stickerSets"
	TypeCallDiscardReasonEmpty                          = "callDiscardReasonEmpty"
	TypeCallDiscardReasonMissed                         = "callDiscardReasonMissed"
	TypeCallDiscardReasonDeclined                       = "callDiscardReasonDeclined"
	TypeCallDiscardReasonDisconnected                   = "callDiscardReasonDisconnected"
	TypeCallDiscardReasonHungUp                         = "callDiscardReasonHungUp"
	TypeCallProtocol                                    = "callProtocol"
	TypeCallServerTypeTelegramReflector                 = "callServerTypeTelegramReflector"
	TypeCallServerTypeWebrtc                            = "callServerTypeWebrtc"
	TypeCallServer                                      = "callServer"
	TypeCallId                                          = "callId"
	TypeCallStatePending                                = "callStatePending"
	TypeCallStateExchangingKeys                         = "callStateExchangingKeys"
	TypeCallStateReady                                  = "callStateReady"
	TypeCallStateHangingUp                              = "callStateHangingUp"
	TypeCallStateDiscarded                              = "callStateDiscarded"
	TypeCallStateError                                  = "callStateError"
	TypeCallProblemEcho                                 = "callProblemEcho"
	TypeCallProblemNoise                                = "callProblemNoise"
	TypeCallProblemInterruptions                        = "callProblemInterruptions"
	TypeCallProblemDistortedSpeech                      = "callProblemDistortedSpeech"
	TypeCallProblemSilentLocal                          = "callProblemSilentLocal"
	TypeCallProblemSilentRemote                         = "callProblemSilentRemote"
	TypeCallProblemDropped                              = "callProblemDropped"
	TypeCallProblemDistortedVideo                       = "callProblemDistortedVideo"
	TypeCallProblemPixelatedVideo                       = "callProblemPixelatedVideo"
	TypeCall                                            = "call"
	TypePhoneNumberAuthenticationSettings               = "phoneNumberAuthenticationSettings"
	TypeAnimations                                      = "animations"
	TypeDiceStickersRegular                             = "diceStickersRegular"
	TypeDiceStickersSlotMachine                         = "diceStickersSlotMachine"
	TypeImportedContacts                                = "importedContacts"
	TypeHttpUrl                                         = "httpUrl"
	TypeInputInlineQueryResultAnimation                 = "inputInlineQueryResultAnimation"
	TypeInputInlineQueryResultArticle                   = "inputInlineQueryResultArticle"
	TypeInputInlineQueryResultAudio                     = "inputInlineQueryResultAudio"
	TypeInputInlineQueryResultContact                   = "inputInlineQueryResultContact"
	TypeInputInlineQueryResultDocument                  = "inputInlineQueryResultDocument"
	TypeInputInlineQueryResultGame                      = "inputInlineQueryResultGame"
	TypeInputInlineQueryResultLocation                  = "inputInlineQueryResultLocation"
	TypeInputInlineQueryResultPhoto                     = "inputInlineQueryResultPhoto"
	TypeInputInlineQueryResultSticker                   = "inputInlineQueryResultSticker"
	TypeInputInlineQueryResultVenue                     = "inputInlineQueryResultVenue"
	TypeInputInlineQueryResultVideo                     = "inputInlineQueryResultVideo"
	TypeInputInlineQueryResultVoiceNote                 = "inputInlineQueryResultVoiceNote"
	TypeInlineQueryResultArticle                        = "inlineQueryResultArticle"
	TypeInlineQueryResultContact                        = "inlineQueryResultContact"
	TypeInlineQueryResultLocation                       = "inlineQueryResultLocation"
	TypeInlineQueryResultVenue                          = "inlineQueryResultVenue"
	TypeInlineQueryResultGame                           = "inlineQueryResultGame"
	TypeInlineQueryResultAnimation                      = "inlineQueryResultAnimation"
	TypeInlineQueryResultAudio                          = "inlineQueryResultAudio"
	TypeInlineQueryResultDocument                       = "inlineQueryResultDocument"
	TypeInlineQueryResultPhoto                          = "inlineQueryResultPhoto"
	TypeInlineQueryResultSticker                        = "inlineQueryResultSticker"
	TypeInlineQueryResultVideo                          = "inlineQueryResultVideo"
	TypeInlineQueryResultVoiceNote                      = "inlineQueryResultVoiceNote"
	TypeInlineQueryResults                              = "inlineQueryResults"
	TypeCallbackQueryPayloadData                        = "callbackQueryPayloadData"
	TypeCallbackQueryPayloadDataWithPassword            = "callbackQueryPayloadDataWithPassword"
	TypeCallbackQueryPayloadGame                        = "callbackQueryPayloadGame"
	TypeCallbackQueryAnswer                             = "callbackQueryAnswer"
	TypeCustomRequestResult                             = "customRequestResult"
	TypeGameHighScore                                   = "gameHighScore"
	TypeGameHighScores                                  = "gameHighScores"
	TypeChatEventMessageEdited                          = "chatEventMessageEdited"
	TypeChatEventMessageDeleted                         = "chatEventMessageDeleted"
	TypeChatEventPollStopped                            = "chatEventPollStopped"
	TypeChatEventMessagePinned                          = "chatEventMessagePinned"
	TypeChatEventMessageUnpinned                        = "chatEventMessageUnpinned"
	TypeChatEventMemberJoined                           = "chatEventMemberJoined"
	TypeChatEventMemberLeft                             = "chatEventMemberLeft"
	TypeChatEventMemberInvited                          = "chatEventMemberInvited"
	TypeChatEventMemberPromoted                         = "chatEventMemberPromoted"
	TypeChatEventMemberRestricted                       = "chatEventMemberRestricted"
	TypeChatEventTitleChanged                           = "chatEventTitleChanged"
	TypeChatEventPermissionsChanged                     = "chatEventPermissionsChanged"
	TypeChatEventDescriptionChanged                     = "chatEventDescriptionChanged"
	TypeChatEventUsernameChanged                        = "chatEventUsernameChanged"
	TypeChatEventPhotoChanged                           = "chatEventPhotoChanged"
	TypeChatEventInvitesToggled                         = "chatEventInvitesToggled"
	TypeChatEventLinkedChatChanged                      = "chatEventLinkedChatChanged"
	TypeChatEventSlowModeDelayChanged                   = "chatEventSlowModeDelayChanged"
	TypeChatEventSignMessagesToggled                    = "chatEventSignMessagesToggled"
	TypeChatEventStickerSetChanged                      = "chatEventStickerSetChanged"
	TypeChatEventLocationChanged                        = "chatEventLocationChanged"
	TypeChatEventIsAllHistoryAvailableToggled           = "chatEventIsAllHistoryAvailableToggled"
	TypeChatEvent                                       = "chatEvent"
	TypeChatEvents                                      = "chatEvents"
	TypeChatEventLogFilters                             = "chatEventLogFilters"
	TypeLanguagePackStringValueOrdinary                 = "languagePackStringValueOrdinary"
	TypeLanguagePackStringValuePluralized               = "languagePackStringValuePluralized"
	TypeLanguagePackStringValueDeleted                  = "languagePackStringValueDeleted"
	TypeLanguagePackString                              = "languagePackString"
	TypeLanguagePackStrings                             = "languagePackStrings"
	TypeLanguagePackInfo                                = "languagePackInfo"
	TypeLocalizationTargetInfo                          = "localizationTargetInfo"
	TypeDeviceTokenFirebaseCloudMessaging               = "deviceTokenFirebaseCloudMessaging"
	TypeDeviceTokenApplePush                            = "deviceTokenApplePush"
	TypeDeviceTokenApplePushVoIP                        = "deviceTokenApplePushVoIP"
	TypeDeviceTokenWindowsPush                          = "deviceTokenWindowsPush"
	TypeDeviceTokenMicrosoftPush                        = "deviceTokenMicrosoftPush"
	TypeDeviceTokenMicrosoftPushVoIP                    = "deviceTokenMicrosoftPushVoIP"
	TypeDeviceTokenWebPush                              = "deviceTokenWebPush"
	TypeDeviceTokenSimplePush                           = "deviceTokenSimplePush"
	TypeDeviceTokenUbuntuPush                           = "deviceTokenUbuntuPush"
	TypeDeviceTokenBlackBerryPush                       = "deviceTokenBlackBerryPush"
	TypeDeviceTokenTizenPush                            = "deviceTokenTizenPush"
	TypePushReceiverId                                  = "pushReceiverId"
	TypeBackgroundFillSolid                             = "backgroundFillSolid"
	TypeBackgroundFillGradient                          = "backgroundFillGradient"
	TypeBackgroundTypeWallpaper                         = "backgroundTypeWallpaper"
	TypeBackgroundTypePattern                           = "backgroundTypePattern"
	TypeBackgroundTypeFill                              = "backgroundTypeFill"
	TypeBackground                                      = "background"
	TypeBackgrounds                                     = "backgrounds"
	TypeInputBackgroundLocal                            = "inputBackgroundLocal"
	TypeInputBackgroundRemote                           = "inputBackgroundRemote"
	TypeHashtags                                        = "hashtags"
	TypeCanTransferOwnershipResultOk                    = "canTransferOwnershipResultOk"
	TypeCanTransferOwnershipResultPasswordNeeded        = "canTransferOwnershipResultPasswordNeeded"
	TypeCanTransferOwnershipResultPasswordTooFresh      = "canTransferOwnershipResultPasswordTooFresh"
	TypeCanTransferOwnershipResultSessionTooFresh       = "canTransferOwnershipResultSessionTooFresh"
	TypeCheckChatUsernameResultOk                       = "checkChatUsernameResultOk"
	TypeCheckChatUsernameResultUsernameInvalid          = "checkChatUsernameResultUsernameInvalid"
	TypeCheckChatUsernameResultUsernameOccupied         = "checkChatUsernameResultUsernameOccupied"
	TypeCheckChatUsernameResultPublicChatsTooMuch       = "checkChatUsernameResultPublicChatsTooMuch"
	TypeCheckChatUsernameResultPublicGroupsUnavailable  = "checkChatUsernameResultPublicGroupsUnavailable"
	TypePushMessageContentHidden                        = "pushMessageContentHidden"
	TypePushMessageContentAnimation                     = "pushMessageContentAnimation"
	TypePushMessageContentAudio                         = "pushMessageContentAudio"
	TypePushMessageContentContact                       = "pushMessageContentContact"
	TypePushMessageContentContactRegistered             = "pushMessageContentContactRegistered"
	TypePushMessageContentDocument                      = "pushMessageContentDocument"
	TypePushMessageContentGame                          = "pushMessageContentGame"
	TypePushMessageContentGameScore                     = "pushMessageContentGameScore"
	TypePushMessageContentInvoice                       = "pushMessageContentInvoice"
	TypePushMessageContentLocation                      = "pushMessageContentLocation"
	TypePushMessageContentPhoto                         = "pushMessageContentPhoto"
	TypePushMessageContentPoll                          = "pushMessageContentPoll"
	TypePushMessageContentScreenshotTaken               = "pushMessageContentScreenshotTaken"
	TypePushMessageContentSticker                       = "pushMessageContentSticker"
	TypePushMessageContentText                          = "pushMessageContentText"
	TypePushMessageContentVideo                         = "pushMessageContentVideo"
	TypePushMessageContentVideoNote                     = "pushMessageContentVideoNote"
	TypePushMessageContentVoiceNote                     = "pushMessageContentVoiceNote"
	TypePushMessageContentBasicGroupChatCreate          = "pushMessageContentBasicGroupChatCreate"
	TypePushMessageContentChatAddMembers                = "pushMessageContentChatAddMembers"
	TypePushMessageContentChatChangePhoto               = "pushMessageContentChatChangePhoto"
	TypePushMessageContentChatChangeTitle               = "pushMessageContentChatChangeTitle"
	TypePushMessageContentChatDeleteMember              = "pushMessageContentChatDeleteMember"
	TypePushMessageContentChatJoinByLink                = "pushMessageContentChatJoinByLink"
	TypePushMessageContentMessageForwards               = "pushMessageContentMessageForwards"
	TypePushMessageContentMediaAlbum                    = "pushMessageContentMediaAlbum"
	TypeNotificationTypeNewMessage                      = "notificationTypeNewMessage"
	TypeNotificationTypeNewSecretChat                   = "notificationTypeNewSecretChat"
	TypeNotificationTypeNewCall                         = "notificationTypeNewCall"
	TypeNotificationTypeNewPushMessage                  = "notificationTypeNewPushMessage"
	TypeNotificationGroupTypeMessages                   = "notificationGroupTypeMessages"
	TypeNotificationGroupTypeMentions                   = "notificationGroupTypeMentions"
	TypeNotificationGroupTypeSecretChat                 = "notificationGroupTypeSecretChat"
	TypeNotificationGroupTypeCalls                      = "notificationGroupTypeCalls"
	TypeNotification                                    = "notification"
	TypeNotificationGroup                               = "notificationGroup"
	TypeOptionValueBoolean                              = "optionValueBoolean"
	TypeOptionValueEmpty                                = "optionValueEmpty"
	TypeOptionValueInteger                              = "optionValueInteger"
	TypeOptionValueString                               = "optionValueString"
	TypeJsonObjectMember                                = "jsonObjectMember"
	TypeJsonValueNull                                   = "jsonValueNull"
	TypeJsonValueBoolean                                = "jsonValueBoolean"
	TypeJsonValueNumber                                 = "jsonValueNumber"
	TypeJsonValueString                                 = "jsonValueString"
	TypeJsonValueArray                                  = "jsonValueArray"
	TypeJsonValueObject                                 = "jsonValueObject"
	TypeUserPrivacySettingRuleAllowAll                  = "userPrivacySettingRuleAllowAll"
	TypeUserPrivacySettingRuleAllowContacts             = "userPrivacySettingRuleAllowContacts"
	TypeUserPrivacySettingRuleAllowUsers                = "userPrivacySettingRuleAllowUsers"
	TypeUserPrivacySettingRuleAllowChatMembers          = "userPrivacySettingRuleAllowChatMembers"
	TypeUserPrivacySettingRuleRestrictAll               = "userPrivacySettingRuleRestrictAll"
	TypeUserPrivacySettingRuleRestrictContacts          = "userPrivacySettingRuleRestrictContacts"
	TypeUserPrivacySettingRuleRestrictUsers             = "userPrivacySettingRuleRestrictUsers"
	TypeUserPrivacySettingRuleRestrictChatMembers       = "userPrivacySettingRuleRestrictChatMembers"
	TypeUserPrivacySettingRules                         = "userPrivacySettingRules"
	TypeUserPrivacySettingShowStatus                    = "userPrivacySettingShowStatus"
	TypeUserPrivacySettingShowProfilePhoto              = "userPrivacySettingShowProfilePhoto"
	TypeUserPrivacySettingShowLinkInForwardedMessages   = "userPrivacySettingShowLinkInForwardedMessages"
	TypeUserPrivacySettingShowPhoneNumber               = "userPrivacySettingShowPhoneNumber"
	TypeUserPrivacySettingAllowChatInvites              = "userPrivacySettingAllowChatInvites"
	TypeUserPrivacySettingAllowCalls                    = "userPrivacySettingAllowCalls"
	TypeUserPrivacySettingAllowPeerToPeerCalls          = "userPrivacySettingAllowPeerToPeerCalls"
	TypeUserPrivacySettingAllowFindingByPhoneNumber     = "userPrivacySettingAllowFindingByPhoneNumber"
	TypeAccountTtl                                      = "accountTtl"
	TypeSession                                         = "session"
	TypeSessions                                        = "sessions"
	TypeConnectedWebsite                                = "connectedWebsite"
	TypeConnectedWebsites                               = "connectedWebsites"
	TypeChatReportReasonSpam                            = "chatReportReasonSpam"
	TypeChatReportReasonViolence                        = "chatReportReasonViolence"
	TypeChatReportReasonPornography                     = "chatReportReasonPornography"
	TypeChatReportReasonChildAbuse                      = "chatReportReasonChildAbuse"
	TypeChatReportReasonCopyright                       = "chatReportReasonCopyright"
	TypeChatReportReasonUnrelatedLocation               = "chatReportReasonUnrelatedLocation"
	TypeChatReportReasonCustom                          = "chatReportReasonCustom"
	TypeMessageLink                                     = "messageLink"
	TypeMessageLinkInfo                                 = "messageLinkInfo"
	TypeFilePart                                        = "filePart"
	TypeFileTypeNone                                    = "fileTypeNone"
	TypeFileTypeAnimation                               = "fileTypeAnimation"
	TypeFileTypeAudio                                   = "fileTypeAudio"
	TypeFileTypeDocument                                = "fileTypeDocument"
	TypeFileTypePhoto                                   = "fileTypePhoto"
	TypeFileTypeProfilePhoto                            = "fileTypeProfilePhoto"
	TypeFileTypeSecret                                  = "fileTypeSecret"
	TypeFileTypeSecretThumbnail                         = "fileTypeSecretThumbnail"
	TypeFileTypeSecure                                  = "fileTypeSecure"
	TypeFileTypeSticker                                 = "fileTypeSticker"
	TypeFileTypeThumbnail                               = "fileTypeThumbnail"
	TypeFileTypeUnknown                                 = "fileTypeUnknown"
	TypeFileTypeVideo                                   = "fileTypeVideo"
	TypeFileTypeVideoNote                               = "fileTypeVideoNote"
	TypeFileTypeVoiceNote                               = "fileTypeVoiceNote"
	TypeFileTypeWallpaper                               = "fileTypeWallpaper"
	TypeStorageStatisticsByFileType                     = "storageStatisticsByFileType"
	TypeStorageStatisticsByChat                         = "storageStatisticsByChat"
	TypeStorageStatistics                               = "storageStatistics"
	TypeStorageStatisticsFast                           = "storageStatisticsFast"
	TypeDatabaseStatistics                              = "databaseStatistics"
	TypeNetworkTypeNone                                 = "networkTypeNone"
	TypeNetworkTypeMobile                               = "networkTypeMobile"
	TypeNetworkTypeMobileRoaming                        = "networkTypeMobileRoaming"
	TypeNetworkTypeWiFi                                 = "networkTypeWiFi"
	TypeNetworkTypeOther                                = "networkTypeOther"
	TypeNetworkStatisticsEntryFile                      = "networkStatisticsEntryFile"
	TypeNetworkStatisticsEntryCall                      = "networkStatisticsEntryCall"
	TypeNetworkStatistics                               = "networkStatistics"
	TypeAutoDownloadSettings                            = "autoDownloadSettings"
	TypeAutoDownloadSettingsPresets                     = "autoDownloadSettingsPresets"
	TypeConnectionStateWaitingForNetwork                = "connectionStateWaitingForNetwork"
	TypeConnectionStateConnectingToProxy                = "connectionStateConnectingToProxy"
	TypeConnectionStateConnecting                       = "connectionStateConnecting"
	TypeConnectionStateUpdating                         = "connectionStateUpdating"
	TypeConnectionStateReady                            = "connectionStateReady"
	TypeTopChatCategoryUsers                            = "topChatCategoryUsers"
	TypeTopChatCategoryBots                             = "topChatCategoryBots"
	TypeTopChatCategoryGroups                           = "topChatCategoryGroups"
	TypeTopChatCategoryChannels                         = "topChatCategoryChannels"
	TypeTopChatCategoryInlineBots                       = "topChatCategoryInlineBots"
	TypeTopChatCategoryCalls                            = "topChatCategoryCalls"
	TypeTopChatCategoryForwardChats                     = "topChatCategoryForwardChats"
	TypeTMeUrlTypeUser                                  = "tMeUrlTypeUser"
	TypeTMeUrlTypeSupergroup                            = "tMeUrlTypeSupergroup"
	TypeTMeUrlTypeChatInvite                            = "tMeUrlTypeChatInvite"
	TypeTMeUrlTypeStickerSet                            = "tMeUrlTypeStickerSet"
	TypeTMeUrl                                          = "tMeUrl"
	TypeTMeUrls                                         = "tMeUrls"
	TypeSuggestedActionEnableArchiveAndMuteNewChats     = "suggestedActionEnableArchiveAndMuteNewChats"
	TypeSuggestedActionCheckPhoneNumber                 = "suggestedActionCheckPhoneNumber"
	TypeCount                                           = "count"
	TypeText                                            = "text"
	TypeSeconds                                         = "seconds"
	TypeDeepLinkInfo                                    = "deepLinkInfo"
	TypeTextParseModeMarkdown                           = "textParseModeMarkdown"
	TypeTextParseModeHTML                               = "textParseModeHTML"
	TypeProxyTypeSocks5                                 = "proxyTypeSocks5"
	TypeProxyTypeHttp                                   = "proxyTypeHttp"
	TypeProxyTypeMtproto                                = "proxyTypeMtproto"
	TypeProxy                                           = "proxy"
	TypeProxies                                         = "proxies"
	TypeInputStickerStatic                              = "inputStickerStatic"
	TypeInputStickerAnimated                            = "inputStickerAnimated"
	TypeDateRange                                       = "dateRange"
	TypeStatisticalValue                                = "statisticalValue"
	TypeStatisticalGraphData                            = "statisticalGraphData"
	TypeStatisticalGraphAsync                           = "statisticalGraphAsync"
	TypeStatisticalGraphError                           = "statisticalGraphError"
	TypeChatStatisticsMessageInteractionInfo            = "chatStatisticsMessageInteractionInfo"
	TypeChatStatisticsMessageSenderInfo                 = "chatStatisticsMessageSenderInfo"
	TypeChatStatisticsAdministratorActionsInfo          = "chatStatisticsAdministratorActionsInfo"
	TypeChatStatisticsInviterInfo                       = "chatStatisticsInviterInfo"
	TypeChatStatisticsSupergroup                        = "chatStatisticsSupergroup"
	TypeChatStatisticsChannel                           = "chatStatisticsChannel"
	TypeMessageStatistics                               = "messageStatistics"
	TypeUpdateAuthorizationState                        = "updateAuthorizationState"
	TypeUpdateNewMessage                                = "updateNewMessage"
	TypeUpdateMessageSendAcknowledged                   = "updateMessageSendAcknowledged"
	TypeUpdateMessageSendSucceeded                      = "updateMessageSendSucceeded"
	TypeUpdateMessageSendFailed                         = "updateMessageSendFailed"
	TypeUpdateMessageContent                            = "updateMessageContent"
	TypeUpdateMessageEdited                             = "updateMessageEdited"
	TypeUpdateMessageIsPinned                           = "updateMessageIsPinned"
	TypeUpdateMessageInteractionInfo                    = "updateMessageInteractionInfo"
	TypeUpdateMessageContentOpened                      = "updateMessageContentOpened"
	TypeUpdateMessageMentionRead                        = "updateMessageMentionRead"
	TypeUpdateMessageLiveLocationViewed                 = "updateMessageLiveLocationViewed"
	TypeUpdateNewChat                                   = "updateNewChat"
	TypeUpdateChatTitle                                 = "updateChatTitle"
	TypeUpdateChatPhoto                                 = "updateChatPhoto"
	TypeUpdateChatPermissions                           = "updateChatPermissions"
	TypeUpdateChatLastMessage                           = "updateChatLastMessage"
	TypeUpdateChatPosition                              = "updateChatPosition"
	TypeUpdateChatIsMarkedAsUnread                      = "updateChatIsMarkedAsUnread"
	TypeUpdateChatIsBlocked                             = "updateChatIsBlocked"
	TypeUpdateChatHasScheduledMessages                  = "updateChatHasScheduledMessages"
	TypeUpdateChatDefaultDisableNotification            = "updateChatDefaultDisableNotification"
	TypeUpdateChatReadInbox                             = "updateChatReadInbox"
	TypeUpdateChatReadOutbox                            = "updateChatReadOutbox"
	TypeUpdateChatUnreadMentionCount                    = "updateChatUnreadMentionCount"
	TypeUpdateChatNotificationSettings                  = "updateChatNotificationSettings"
	TypeUpdateScopeNotificationSettings                 = "updateScopeNotificationSettings"
	TypeUpdateChatActionBar                             = "updateChatActionBar"
	TypeUpdateChatReplyMarkup                           = "updateChatReplyMarkup"
	TypeUpdateChatDraftMessage                          = "updateChatDraftMessage"
	TypeUpdateChatFilters                               = "updateChatFilters"
	TypeUpdateChatOnlineMemberCount                     = "updateChatOnlineMemberCount"
	TypeUpdateNotification                              = "updateNotification"
	TypeUpdateNotificationGroup                         = "updateNotificationGroup"
	TypeUpdateActiveNotifications                       = "updateActiveNotifications"
	TypeUpdateHavePendingNotifications                  = "updateHavePendingNotifications"
	TypeUpdateDeleteMessages                            = "updateDeleteMessages"
	TypeUpdateUserChatAction                            = "updateUserChatAction"
	TypeUpdateUserStatus                                = "updateUserStatus"
	TypeUpdateUser                                      = "updateUser"
	TypeUpdateBasicGroup                                = "updateBasicGroup"
	TypeUpdateSupergroup                                = "updateSupergroup"
	TypeUpdateSecretChat                                = "updateSecretChat"
	TypeUpdateUserFullInfo                              = "updateUserFullInfo"
	TypeUpdateBasicGroupFullInfo                        = "updateBasicGroupFullInfo"
	TypeUpdateSupergroupFullInfo                        = "updateSupergroupFullInfo"
	TypeUpdateServiceNotification                       = "updateServiceNotification"
	TypeUpdateFile                                      = "updateFile"
	TypeUpdateFileGenerationStart                       = "updateFileGenerationStart"
	TypeUpdateFileGenerationStop                        = "updateFileGenerationStop"
	TypeUpdateCall                                      = "updateCall"
	TypeUpdateNewCallSignalingData                      = "updateNewCallSignalingData"
	TypeUpdateUserPrivacySettingRules                   = "updateUserPrivacySettingRules"
	TypeUpdateUnreadMessageCount                        = "updateUnreadMessageCount"
	TypeUpdateUnreadChatCount                           = "updateUnreadChatCount"
	TypeUpdateOption                                    = "updateOption"
	TypeUpdateStickerSet                                = "updateStickerSet"
	TypeUpdateInstalledStickerSets                      = "updateInstalledStickerSets"
	TypeUpdateTrendingStickerSets                       = "updateTrendingStickerSets"
	TypeUpdateRecentStickers                            = "updateRecentStickers"
	TypeUpdateFavoriteStickers                          = "updateFavoriteStickers"
	TypeUpdateSavedAnimations                           = "updateSavedAnimations"
	TypeUpdateSelectedBackground                        = "updateSelectedBackground"
	TypeUpdateLanguagePackStrings                       = "updateLanguagePackStrings"
	TypeUpdateConnectionState                           = "updateConnectionState"
	TypeUpdateTermsOfService                            = "updateTermsOfService"
	TypeUpdateUsersNearby                               = "updateUsersNearby"
	TypeUpdateDiceEmojis                                = "updateDiceEmojis"
	TypeUpdateAnimationSearchParameters                 = "updateAnimationSearchParameters"
	TypeUpdateSuggestedActions                          = "updateSuggestedActions"
	TypeUpdateNewInlineQuery                            = "updateNewInlineQuery"
	TypeUpdateNewChosenInlineResult                     = "updateNewChosenInlineResult"
	TypeUpdateNewCallbackQuery                          = "updateNewCallbackQuery"
	TypeUpdateNewInlineCallbackQuery                    = "updateNewInlineCallbackQuery"
	TypeUpdateNewShippingQuery                          = "updateNewShippingQuery"
	TypeUpdateNewPreCheckoutQuery                       = "updateNewPreCheckoutQuery"
	TypeUpdateNewCustomEvent                            = "updateNewCustomEvent"
	TypeUpdateNewCustomQuery                            = "updateNewCustomQuery"
	TypeUpdatePoll                                      = "updatePoll"
	TypeUpdatePollAnswer                                = "updatePollAnswer"
	TypeUpdates                                         = "updates"
	TypeLogStreamDefault                                = "logStreamDefault"
	TypeLogStreamFile                                   = "logStreamFile"
	TypeLogStreamEmpty                                  = "logStreamEmpty"
	TypeLogVerbosityLevel                               = "logVerbosityLevel"
	TypeLogTags                                         = "logTags"
	TypeTestInt                                         = "testInt"
	TypeTestString                                      = "testString"
	TypeTestBytes                                       = "testBytes"
	TypeTestVectorInt                                   = "testVectorInt"
	TypeTestVectorIntObject                             = "testVectorIntObject"
	TypeTestVectorString                                = "testVectorString"
	TypeTestVectorStringObject                          = "testVectorStringObject"
)

Variables

View Source
var ErrNotSupportedAuthorizationState = errors.New("not supported state")

Functions

func Authorize

func Authorize(client *Client, authorizationStateHandler AuthorizationStateHandler) error

func BotAuthorizer

func BotAuthorizer(token string) *botAuthorizer

func CliInteractor

func CliInteractor(clientAuthorizer *clientAuthorizer)

func ClientAuthorizer

func ClientAuthorizer() *clientAuthorizer

Types

type AcceptCallRequest

type AcceptCallRequest struct {
	// Call identifier
	CallId int32 `json:"call_id"`
	// Description of the call protocols supported by the application
	Protocol *CallProtocol `json:"protocol"`
}

type AcceptTermsOfServiceRequest

type AcceptTermsOfServiceRequest struct {
	// Terms of service identifier
	TermsOfServiceId string `json:"terms_of_service_id"`
}

type AccountTtl

type AccountTtl struct {

	// Number of days of inactivity before the account will be flagged for deletion; should range from 30-366 days
	Days int32 `json:"days"`
	// contains filtered or unexported fields
}

Contains information about the period of inactivity after which the current user's account will automatically be deleted

func UnmarshalAccountTtl

func UnmarshalAccountTtl(data json.RawMessage) (*AccountTtl, error)

func (*AccountTtl) GetClass

func (*AccountTtl) GetClass() string

func (*AccountTtl) GetType

func (*AccountTtl) GetType() string

func (*AccountTtl) MarshalJSON

func (entity *AccountTtl) MarshalJSON() ([]byte, error)

type AddChatMemberRequest

type AddChatMemberRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Identifier of the user
	UserId int32 `json:"user_id"`
	// The number of earlier messages from the chat to be forwarded to the new member; up to 100. Ignored for supergroups and channels
	ForwardLimit int32 `json:"forward_limit"`
}

type AddChatMembersRequest

type AddChatMembersRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Identifiers of the users to be added to the chat
	UserIds []int32 `json:"user_ids"`
}

type AddChatToListRequest

type AddChatToListRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// The chat list. Use getChatListsToAddChat to get suitable chat lists
	ChatList ChatList `json:"chat_list"`
}

type AddContactRequest

type AddContactRequest struct {
	// The contact to add or edit; phone number can be empty and needs to be specified only if known, vCard is ignored
	Contact *Contact `json:"contact"`
	// True, if the new contact needs to be allowed to see current user's phone number. A corresponding rule to userPrivacySettingShowPhoneNumber will be added if needed. Use the field UserFullInfo.need_phone_number_privacy_exception to check whether the current user needs to be asked to share their phone number
	SharePhoneNumber bool `json:"share_phone_number"`
}

type AddCustomServerLanguagePackRequest

type AddCustomServerLanguagePackRequest struct {
	// Identifier of a language pack to be added; may be different from a name that is used in an "https://t.me/setlanguage/" link
	LanguagePackId string `json:"language_pack_id"`
}

type AddFavoriteStickerRequest

type AddFavoriteStickerRequest struct {
	// Sticker file to add
	Sticker InputFile `json:"sticker"`
}

type AddLocalMessageRequest

type AddLocalMessageRequest struct {
	// Target chat
	ChatId int64 `json:"chat_id"`
	// The sender sender of the message
	Sender MessageSender `json:"sender"`
	// Identifier of the message to reply to or 0
	ReplyToMessageId int64 `json:"reply_to_message_id"`
	// Pass true to disable notification for the message
	DisableNotification bool `json:"disable_notification"`
	// The content of the message to be added
	InputMessageContent InputMessageContent `json:"input_message_content"`
}

type AddLogMessageRequest

type AddLogMessageRequest struct {
	// The minimum verbosity level needed for the message to be logged, 0-1023
	VerbosityLevel int32 `json:"verbosity_level"`
	// Text of a message to log
	Text string `json:"text"`
}

type AddNetworkStatisticsRequest

type AddNetworkStatisticsRequest struct {
	// The network statistics entry with the data to be added to statistics
	Entry NetworkStatisticsEntry `json:"entry"`
}

type AddProxyRequest

type AddProxyRequest struct {
	// Proxy server IP address
	Server string `json:"server"`
	// Proxy server port
	Port int32 `json:"port"`
	// True, if the proxy should be enabled
	Enable bool `json:"enable"`
	// Proxy type
	Type ProxyType `json:"type"`
}

type AddRecentStickerRequest

type AddRecentStickerRequest struct {
	// Pass true to add the sticker to the list of stickers recently attached to photo or video files; pass false to add the sticker to the list of recently sent stickers
	IsAttached bool `json:"is_attached"`
	// Sticker file to add
	Sticker InputFile `json:"sticker"`
}

type AddRecentlyFoundChatRequest

type AddRecentlyFoundChatRequest struct {
	// Identifier of the chat to add
	ChatId int64 `json:"chat_id"`
}

type AddSavedAnimationRequest

type AddSavedAnimationRequest struct {
	// The animation file to be added. Only animations known to the server (i.e. successfully sent via a message) can be added to the list
	Animation InputFile `json:"animation"`
}

type AddStickerToSetRequest

type AddStickerToSetRequest struct {
	// Sticker set owner
	UserId int32 `json:"user_id"`
	// Sticker set name
	Name string `json:"name"`
	// Sticker to add to the set
	Sticker InputSticker `json:"sticker"`
}

type Address

type Address struct {

	// A two-letter ISO 3166-1 alpha-2 country code
	CountryCode string `json:"country_code"`
	// State, if applicable
	State string `json:"state"`
	// City
	City string `json:"city"`
	// First line of the address
	StreetLine1 string `json:"street_line1"`
	// Second line of the address
	StreetLine2 string `json:"street_line2"`
	// Address postal code
	PostalCode string `json:"postal_code"`
	// contains filtered or unexported fields
}

Describes an address

func UnmarshalAddress

func UnmarshalAddress(data json.RawMessage) (*Address, error)

func (*Address) GetClass

func (*Address) GetClass() string

func (*Address) GetType

func (*Address) GetType() string

func (*Address) MarshalJSON

func (entity *Address) MarshalJSON() ([]byte, error)

type AnimatedChatPhoto

type AnimatedChatPhoto struct {

	// Animation width and height
	Length int32 `json:"length"`
	// Information about the animation file
	File *File `json:"file"`
	// Timestamp of the frame, used as a static chat photo
	MainFrameTimestamp float64 `json:"main_frame_timestamp"`
	// contains filtered or unexported fields
}

Animated variant of a chat photo in MPEG4 format

func UnmarshalAnimatedChatPhoto

func UnmarshalAnimatedChatPhoto(data json.RawMessage) (*AnimatedChatPhoto, error)

func (*AnimatedChatPhoto) GetClass

func (*AnimatedChatPhoto) GetClass() string

func (*AnimatedChatPhoto) GetType

func (*AnimatedChatPhoto) GetType() string

func (*AnimatedChatPhoto) MarshalJSON

func (entity *AnimatedChatPhoto) MarshalJSON() ([]byte, error)

type Animation

type Animation struct {

	// Duration of the animation, in seconds; as defined by the sender
	Duration int32 `json:"duration"`
	// Width of the animation
	Width int32 `json:"width"`
	// Height of the animation
	Height int32 `json:"height"`
	// Original name of the file; as defined by the sender
	FileName string `json:"file_name"`
	// MIME type of the file, usually "image/gif" or "video/mp4"
	MimeType string `json:"mime_type"`
	// True, if stickers were added to the animation. The list of corresponding sticker set can be received using getAttachedStickerSets
	HasStickers bool `json:"has_stickers"`
	// Animation minithumbnail; may be null
	Minithumbnail *Minithumbnail `json:"minithumbnail"`
	// Animation thumbnail in JPEG or MPEG4 format; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// File containing the animation
	Animation *File `json:"animation"`
	// contains filtered or unexported fields
}

Describes an animation file. The animation must be encoded in GIF or MPEG4 format

func UnmarshalAnimation

func UnmarshalAnimation(data json.RawMessage) (*Animation, error)

func (*Animation) GetClass

func (*Animation) GetClass() string

func (*Animation) GetType

func (*Animation) GetType() string

func (*Animation) MarshalJSON

func (entity *Animation) MarshalJSON() ([]byte, error)

type Animations

type Animations struct {

	// List of animations
	Animations []*Animation `json:"animations"`
	// contains filtered or unexported fields
}

Represents a list of animations

func UnmarshalAnimations

func UnmarshalAnimations(data json.RawMessage) (*Animations, error)

func (*Animations) GetClass

func (*Animations) GetClass() string

func (*Animations) GetType

func (*Animations) GetType() string

func (*Animations) MarshalJSON

func (entity *Animations) MarshalJSON() ([]byte, error)

type AnswerCallbackQueryRequest

type AnswerCallbackQueryRequest struct {
	// Identifier of the callback query
	CallbackQueryId JsonInt64 `json:"callback_query_id"`
	// Text of the answer
	Text string `json:"text"`
	// If true, an alert should be shown to the user instead of a toast notification
	ShowAlert bool `json:"show_alert"`
	// URL to be opened
	Url string `json:"url"`
	// Time during which the result of the query can be cached, in seconds
	CacheTime int32 `json:"cache_time"`
}

type AnswerCustomQueryRequest

type AnswerCustomQueryRequest struct {
	// Identifier of a custom query
	CustomQueryId JsonInt64 `json:"custom_query_id"`
	// JSON-serialized answer to the query
	Data string `json:"data"`
}

type AnswerInlineQueryRequest

type AnswerInlineQueryRequest struct {
	// Identifier of the inline query
	InlineQueryId JsonInt64 `json:"inline_query_id"`
	// True, if the result of the query can be cached for the specified user
	IsPersonal bool `json:"is_personal"`
	// The results of the query
	Results []InputInlineQueryResult `json:"results"`
	// Allowed time to cache the results of the query, in seconds
	CacheTime int32 `json:"cache_time"`
	// Offset for the next inline query; pass an empty string if there are no more results
	NextOffset string `json:"next_offset"`
	// If non-empty, this text should be shown on the button that opens a private chat with the bot and sends a start message to the bot with the parameter switch_pm_parameter
	SwitchPmText string `json:"switch_pm_text"`
	// The parameter for the bot start message
	SwitchPmParameter string `json:"switch_pm_parameter"`
}

type AnswerPreCheckoutQueryRequest

type AnswerPreCheckoutQueryRequest struct {
	// Identifier of the pre-checkout query
	PreCheckoutQueryId JsonInt64 `json:"pre_checkout_query_id"`
	// An error message, empty on success
	ErrorMessage string `json:"error_message"`
}

type AnswerShippingQueryRequest

type AnswerShippingQueryRequest struct {
	// Identifier of the shipping query
	ShippingQueryId JsonInt64 `json:"shipping_query_id"`
	// Available shipping options
	ShippingOptions []*ShippingOption `json:"shipping_options"`
	// An error message, empty on success
	ErrorMessage string `json:"error_message"`
}

type Audio

type Audio struct {

	// Duration of the audio, in seconds; as defined by the sender
	Duration int32 `json:"duration"`
	// Title of the audio; as defined by the sender
	Title string `json:"title"`
	// Performer of the audio; as defined by the sender
	Performer string `json:"performer"`
	// Original name of the file; as defined by the sender
	FileName string `json:"file_name"`
	// The MIME type of the file; as defined by the sender
	MimeType string `json:"mime_type"`
	// The minithumbnail of the album cover; may be null
	AlbumCoverMinithumbnail *Minithumbnail `json:"album_cover_minithumbnail"`
	// The thumbnail of the album cover in JPEG format; as defined by the sender. The full size thumbnail should be extracted from the downloaded file; may be null
	AlbumCoverThumbnail *Thumbnail `json:"album_cover_thumbnail"`
	// File containing the audio
	Audio *File `json:"audio"`
	// contains filtered or unexported fields
}

Describes an audio file. Audio is usually in MP3 or M4A format

func UnmarshalAudio

func UnmarshalAudio(data json.RawMessage) (*Audio, error)

func (*Audio) GetClass

func (*Audio) GetClass() string

func (*Audio) GetType

func (*Audio) GetType() string

func (*Audio) MarshalJSON

func (entity *Audio) MarshalJSON() ([]byte, error)

type AuthenticationCodeInfo

type AuthenticationCodeInfo struct {

	// A phone number that is being authenticated
	PhoneNumber string `json:"phone_number"`
	// Describes the way the code was sent to the user
	Type AuthenticationCodeType `json:"type"`
	// Describes the way the next code will be sent to the user; may be null
	NextType AuthenticationCodeType `json:"next_type"`
	// Timeout before the code should be re-sent, in seconds
	Timeout int32 `json:"timeout"`
	// contains filtered or unexported fields
}

Information about the authentication code that was sent

func UnmarshalAuthenticationCodeInfo

func UnmarshalAuthenticationCodeInfo(data json.RawMessage) (*AuthenticationCodeInfo, error)

func (*AuthenticationCodeInfo) GetClass

func (*AuthenticationCodeInfo) GetClass() string

func (*AuthenticationCodeInfo) GetType

func (*AuthenticationCodeInfo) GetType() string

func (*AuthenticationCodeInfo) MarshalJSON

func (entity *AuthenticationCodeInfo) MarshalJSON() ([]byte, error)

func (*AuthenticationCodeInfo) UnmarshalJSON

func (authenticationCodeInfo *AuthenticationCodeInfo) UnmarshalJSON(data []byte) error

type AuthenticationCodeType

type AuthenticationCodeType interface {
	AuthenticationCodeTypeType() string
}

Provides information about the method by which an authentication code is delivered to the user

func UnmarshalAuthenticationCodeType

func UnmarshalAuthenticationCodeType(data json.RawMessage) (AuthenticationCodeType, error)

func UnmarshalListOfAuthenticationCodeType

func UnmarshalListOfAuthenticationCodeType(dataList []json.RawMessage) ([]AuthenticationCodeType, error)

type AuthenticationCodeTypeCall

type AuthenticationCodeTypeCall struct {

	// Length of the code
	Length int32 `json:"length"`
	// contains filtered or unexported fields
}

An authentication code is delivered via a phone call to the specified phone number

func UnmarshalAuthenticationCodeTypeCall

func UnmarshalAuthenticationCodeTypeCall(data json.RawMessage) (*AuthenticationCodeTypeCall, error)

func (*AuthenticationCodeTypeCall) AuthenticationCodeTypeType

func (*AuthenticationCodeTypeCall) AuthenticationCodeTypeType() string

func (*AuthenticationCodeTypeCall) GetClass

func (*AuthenticationCodeTypeCall) GetClass() string

func (*AuthenticationCodeTypeCall) GetType

func (*AuthenticationCodeTypeCall) MarshalJSON

func (entity *AuthenticationCodeTypeCall) MarshalJSON() ([]byte, error)

type AuthenticationCodeTypeFlashCall

type AuthenticationCodeTypeFlashCall struct {

	// Pattern of the phone number from which the call will be made
	Pattern string `json:"pattern"`
	// contains filtered or unexported fields
}

An authentication code is delivered by an immediately cancelled call to the specified phone number. The number from which the call was made is the code

func UnmarshalAuthenticationCodeTypeFlashCall

func UnmarshalAuthenticationCodeTypeFlashCall(data json.RawMessage) (*AuthenticationCodeTypeFlashCall, error)

func (*AuthenticationCodeTypeFlashCall) AuthenticationCodeTypeType

func (*AuthenticationCodeTypeFlashCall) AuthenticationCodeTypeType() string

func (*AuthenticationCodeTypeFlashCall) GetClass

func (*AuthenticationCodeTypeFlashCall) GetType

func (*AuthenticationCodeTypeFlashCall) MarshalJSON

func (entity *AuthenticationCodeTypeFlashCall) MarshalJSON() ([]byte, error)

type AuthenticationCodeTypeSms

type AuthenticationCodeTypeSms struct {

	// Length of the code
	Length int32 `json:"length"`
	// contains filtered or unexported fields
}

An authentication code is delivered via an SMS message to the specified phone number

func UnmarshalAuthenticationCodeTypeSms

func UnmarshalAuthenticationCodeTypeSms(data json.RawMessage) (*AuthenticationCodeTypeSms, error)

func (*AuthenticationCodeTypeSms) AuthenticationCodeTypeType

func (*AuthenticationCodeTypeSms) AuthenticationCodeTypeType() string

func (*AuthenticationCodeTypeSms) GetClass

func (*AuthenticationCodeTypeSms) GetClass() string

func (*AuthenticationCodeTypeSms) GetType

func (*AuthenticationCodeTypeSms) GetType() string

func (*AuthenticationCodeTypeSms) MarshalJSON

func (entity *AuthenticationCodeTypeSms) MarshalJSON() ([]byte, error)

type AuthenticationCodeTypeTelegramMessage

type AuthenticationCodeTypeTelegramMessage struct {

	// Length of the code
	Length int32 `json:"length"`
	// contains filtered or unexported fields
}

An authentication code is delivered via a private Telegram message, which can be viewed from another active session

func UnmarshalAuthenticationCodeTypeTelegramMessage

func UnmarshalAuthenticationCodeTypeTelegramMessage(data json.RawMessage) (*AuthenticationCodeTypeTelegramMessage, error)

func (*AuthenticationCodeTypeTelegramMessage) AuthenticationCodeTypeType

func (*AuthenticationCodeTypeTelegramMessage) AuthenticationCodeTypeType() string

func (*AuthenticationCodeTypeTelegramMessage) GetClass

func (*AuthenticationCodeTypeTelegramMessage) GetType

func (*AuthenticationCodeTypeTelegramMessage) MarshalJSON

func (entity *AuthenticationCodeTypeTelegramMessage) MarshalJSON() ([]byte, error)

type AuthorizationState

type AuthorizationState interface {
	AuthorizationStateType() string
}

Represents the current authorization state of the TDLib client

func UnmarshalAuthorizationState

func UnmarshalAuthorizationState(data json.RawMessage) (AuthorizationState, error)

func UnmarshalListOfAuthorizationState

func UnmarshalListOfAuthorizationState(dataList []json.RawMessage) ([]AuthorizationState, error)

type AuthorizationStateClosed

type AuthorizationStateClosed struct {
	// contains filtered or unexported fields
}

TDLib client is in its final state. All databases are closed and all resources are released. No other updates will be received after this. All queries will be responded to with error code 500. To continue working, one should create a new instance of the TDLib client

func UnmarshalAuthorizationStateClosed

func UnmarshalAuthorizationStateClosed(data json.RawMessage) (*AuthorizationStateClosed, error)

func (*AuthorizationStateClosed) AuthorizationStateType

func (*AuthorizationStateClosed) AuthorizationStateType() string

func (*AuthorizationStateClosed) GetClass

func (*AuthorizationStateClosed) GetClass() string

func (*AuthorizationStateClosed) GetType

func (*AuthorizationStateClosed) GetType() string

func (*AuthorizationStateClosed) MarshalJSON

func (entity *AuthorizationStateClosed) MarshalJSON() ([]byte, error)

type AuthorizationStateClosing

type AuthorizationStateClosing struct {
	// contains filtered or unexported fields
}

TDLib is closing, all subsequent queries will be answered with the error 500. Note that closing TDLib can take a while. All resources will be freed only after authorizationStateClosed has been received

func UnmarshalAuthorizationStateClosing

func UnmarshalAuthorizationStateClosing(data json.RawMessage) (*AuthorizationStateClosing, error)

func (*AuthorizationStateClosing) AuthorizationStateType

func (*AuthorizationStateClosing) AuthorizationStateType() string

func (*AuthorizationStateClosing) GetClass

func (*AuthorizationStateClosing) GetClass() string

func (*AuthorizationStateClosing) GetType

func (*AuthorizationStateClosing) GetType() string

func (*AuthorizationStateClosing) MarshalJSON

func (entity *AuthorizationStateClosing) MarshalJSON() ([]byte, error)

type AuthorizationStateHandler

type AuthorizationStateHandler interface {
	Handle(client *Client, state AuthorizationState) error
	Close()
}

type AuthorizationStateLoggingOut

type AuthorizationStateLoggingOut struct {
	// contains filtered or unexported fields
}

The user is currently logging out

func UnmarshalAuthorizationStateLoggingOut

func UnmarshalAuthorizationStateLoggingOut(data json.RawMessage) (*AuthorizationStateLoggingOut, error)

func (*AuthorizationStateLoggingOut) AuthorizationStateType

func (*AuthorizationStateLoggingOut) AuthorizationStateType() string

func (*AuthorizationStateLoggingOut) GetClass

func (*AuthorizationStateLoggingOut) GetType

func (*AuthorizationStateLoggingOut) MarshalJSON

func (entity *AuthorizationStateLoggingOut) MarshalJSON() ([]byte, error)

type AuthorizationStateReady

type AuthorizationStateReady struct {
	// contains filtered or unexported fields
}

The user has been successfully authorized. TDLib is now ready to answer queries

func UnmarshalAuthorizationStateReady

func UnmarshalAuthorizationStateReady(data json.RawMessage) (*AuthorizationStateReady, error)

func (*AuthorizationStateReady) AuthorizationStateType

func (*AuthorizationStateReady) AuthorizationStateType() string

func (*AuthorizationStateReady) GetClass

func (*AuthorizationStateReady) GetClass() string

func (*AuthorizationStateReady) GetType

func (*AuthorizationStateReady) GetType() string

func (*AuthorizationStateReady) MarshalJSON

func (entity *AuthorizationStateReady) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitCode

type AuthorizationStateWaitCode struct {

	// Information about the authorization code that was sent
	CodeInfo *AuthenticationCodeInfo `json:"code_info"`
	// contains filtered or unexported fields
}

TDLib needs the user's authentication code to authorize

func UnmarshalAuthorizationStateWaitCode

func UnmarshalAuthorizationStateWaitCode(data json.RawMessage) (*AuthorizationStateWaitCode, error)

func (*AuthorizationStateWaitCode) AuthorizationStateType

func (*AuthorizationStateWaitCode) AuthorizationStateType() string

func (*AuthorizationStateWaitCode) GetClass

func (*AuthorizationStateWaitCode) GetClass() string

func (*AuthorizationStateWaitCode) GetType

func (*AuthorizationStateWaitCode) MarshalJSON

func (entity *AuthorizationStateWaitCode) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitEncryptionKey

type AuthorizationStateWaitEncryptionKey struct {

	// True, if the database is currently encrypted
	IsEncrypted bool `json:"is_encrypted"`
	// contains filtered or unexported fields
}

TDLib needs an encryption key to decrypt the local database

func UnmarshalAuthorizationStateWaitEncryptionKey

func UnmarshalAuthorizationStateWaitEncryptionKey(data json.RawMessage) (*AuthorizationStateWaitEncryptionKey, error)

func (*AuthorizationStateWaitEncryptionKey) AuthorizationStateType

func (*AuthorizationStateWaitEncryptionKey) AuthorizationStateType() string

func (*AuthorizationStateWaitEncryptionKey) GetClass

func (*AuthorizationStateWaitEncryptionKey) GetType

func (*AuthorizationStateWaitEncryptionKey) MarshalJSON

func (entity *AuthorizationStateWaitEncryptionKey) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitOtherDeviceConfirmation

type AuthorizationStateWaitOtherDeviceConfirmation struct {

	// A tg:// URL for the QR code. The link will be updated frequently
	Link string `json:"link"`
	// contains filtered or unexported fields
}

The user needs to confirm authorization on another logged in device by scanning a QR code with the provided link

func UnmarshalAuthorizationStateWaitOtherDeviceConfirmation

func UnmarshalAuthorizationStateWaitOtherDeviceConfirmation(data json.RawMessage) (*AuthorizationStateWaitOtherDeviceConfirmation, error)

func (*AuthorizationStateWaitOtherDeviceConfirmation) AuthorizationStateType

func (*AuthorizationStateWaitOtherDeviceConfirmation) AuthorizationStateType() string

func (*AuthorizationStateWaitOtherDeviceConfirmation) GetClass

func (*AuthorizationStateWaitOtherDeviceConfirmation) GetType

func (*AuthorizationStateWaitOtherDeviceConfirmation) MarshalJSON

func (entity *AuthorizationStateWaitOtherDeviceConfirmation) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitPassword

type AuthorizationStateWaitPassword struct {

	// Hint for the password; may be empty
	PasswordHint string `json:"password_hint"`
	// True, if a recovery email address has been set up
	HasRecoveryEmailAddress bool `json:"has_recovery_email_address"`
	// Pattern of the email address to which the recovery email was sent; empty until a recovery email has been sent
	RecoveryEmailAddressPattern string `json:"recovery_email_address_pattern"`
	// contains filtered or unexported fields
}

The user has been authorized, but needs to enter a password to start using the application

func UnmarshalAuthorizationStateWaitPassword

func UnmarshalAuthorizationStateWaitPassword(data json.RawMessage) (*AuthorizationStateWaitPassword, error)

func (*AuthorizationStateWaitPassword) AuthorizationStateType

func (*AuthorizationStateWaitPassword) AuthorizationStateType() string

func (*AuthorizationStateWaitPassword) GetClass

func (*AuthorizationStateWaitPassword) GetType

func (*AuthorizationStateWaitPassword) MarshalJSON

func (entity *AuthorizationStateWaitPassword) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitPhoneNumber

type AuthorizationStateWaitPhoneNumber struct {
	// contains filtered or unexported fields
}

TDLib needs the user's phone number to authorize. Call `setAuthenticationPhoneNumber` to provide the phone number, or use `requestQrCodeAuthentication`, or `checkAuthenticationBotToken` for other authentication options

func UnmarshalAuthorizationStateWaitPhoneNumber

func UnmarshalAuthorizationStateWaitPhoneNumber(data json.RawMessage) (*AuthorizationStateWaitPhoneNumber, error)

func (*AuthorizationStateWaitPhoneNumber) AuthorizationStateType

func (*AuthorizationStateWaitPhoneNumber) AuthorizationStateType() string

func (*AuthorizationStateWaitPhoneNumber) GetClass

func (*AuthorizationStateWaitPhoneNumber) GetType

func (*AuthorizationStateWaitPhoneNumber) MarshalJSON

func (entity *AuthorizationStateWaitPhoneNumber) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitRegistration

type AuthorizationStateWaitRegistration struct {

	// Telegram terms of service
	TermsOfService *TermsOfService `json:"terms_of_service"`
	// contains filtered or unexported fields
}

The user is unregistered and need to accept terms of service and enter their first name and last name to finish registration

func UnmarshalAuthorizationStateWaitRegistration

func UnmarshalAuthorizationStateWaitRegistration(data json.RawMessage) (*AuthorizationStateWaitRegistration, error)

func (*AuthorizationStateWaitRegistration) AuthorizationStateType

func (*AuthorizationStateWaitRegistration) AuthorizationStateType() string

func (*AuthorizationStateWaitRegistration) GetClass

func (*AuthorizationStateWaitRegistration) GetType

func (*AuthorizationStateWaitRegistration) MarshalJSON

func (entity *AuthorizationStateWaitRegistration) MarshalJSON() ([]byte, error)

type AuthorizationStateWaitTdlibParameters

type AuthorizationStateWaitTdlibParameters struct {
	// contains filtered or unexported fields
}

TDLib needs TdlibParameters for initialization

func UnmarshalAuthorizationStateWaitTdlibParameters

func UnmarshalAuthorizationStateWaitTdlibParameters(data json.RawMessage) (*AuthorizationStateWaitTdlibParameters, error)

func (*AuthorizationStateWaitTdlibParameters) AuthorizationStateType

func (*AuthorizationStateWaitTdlibParameters) AuthorizationStateType() string

func (*AuthorizationStateWaitTdlibParameters) GetClass

func (*AuthorizationStateWaitTdlibParameters) GetType

func (*AuthorizationStateWaitTdlibParameters) MarshalJSON

func (entity *AuthorizationStateWaitTdlibParameters) MarshalJSON() ([]byte, error)

type AutoDownloadSettings

type AutoDownloadSettings struct {

	// True, if the auto-download is enabled
	IsAutoDownloadEnabled bool `json:"is_auto_download_enabled"`
	// The maximum size of a photo file to be auto-downloaded
	MaxPhotoFileSize int32 `json:"max_photo_file_size"`
	// The maximum size of a video file to be auto-downloaded
	MaxVideoFileSize int32 `json:"max_video_file_size"`
	// The maximum size of other file types to be auto-downloaded
	MaxOtherFileSize int32 `json:"max_other_file_size"`
	// The maximum suggested bitrate for uploaded videos
	VideoUploadBitrate int32 `json:"video_upload_bitrate"`
	// True, if the beginning of video files needs to be preloaded for instant playback
	PreloadLargeVideos bool `json:"preload_large_videos"`
	// True, if the next audio track needs to be preloaded while the user is listening to an audio file
	PreloadNextAudio bool `json:"preload_next_audio"`
	// True, if "use less data for calls" option needs to be enabled
	UseLessDataForCalls bool `json:"use_less_data_for_calls"`
	// contains filtered or unexported fields
}

Contains auto-download settings

func UnmarshalAutoDownloadSettings

func UnmarshalAutoDownloadSettings(data json.RawMessage) (*AutoDownloadSettings, error)

func (*AutoDownloadSettings) GetClass

func (*AutoDownloadSettings) GetClass() string

func (*AutoDownloadSettings) GetType

func (*AutoDownloadSettings) GetType() string

func (*AutoDownloadSettings) MarshalJSON

func (entity *AutoDownloadSettings) MarshalJSON() ([]byte, error)

type AutoDownloadSettingsPresets

type AutoDownloadSettingsPresets struct {

	// Preset with lowest settings; supposed to be used by default when roaming
	Low *AutoDownloadSettings `json:"low"`
	// Preset with medium settings; supposed to be used by default when using mobile data
	Medium *AutoDownloadSettings `json:"medium"`
	// Preset with highest settings; supposed to be used by default when connected on Wi-Fi
	High *AutoDownloadSettings `json:"high"`
	// contains filtered or unexported fields
}

Contains auto-download settings presets for the user

func UnmarshalAutoDownloadSettingsPresets

func UnmarshalAutoDownloadSettingsPresets(data json.RawMessage) (*AutoDownloadSettingsPresets, error)

func (*AutoDownloadSettingsPresets) GetClass

func (*AutoDownloadSettingsPresets) GetClass() string

func (*AutoDownloadSettingsPresets) GetType

func (*AutoDownloadSettingsPresets) MarshalJSON

func (entity *AutoDownloadSettingsPresets) MarshalJSON() ([]byte, error)

type Background

type Background struct {

	// Unique background identifier
	Id JsonInt64 `json:"id"`
	// True, if this is one of default backgrounds
	IsDefault bool `json:"is_default"`
	// True, if the background is dark and is recommended to be used with dark theme
	IsDark bool `json:"is_dark"`
	// Unique background name
	Name string `json:"name"`
	// Document with the background; may be null. Null only for filled backgrounds
	Document *Document `json:"document"`
	// Type of the background
	Type BackgroundType `json:"type"`
	// contains filtered or unexported fields
}

Describes a chat background

func UnmarshalBackground

func UnmarshalBackground(data json.RawMessage) (*Background, error)

func (*Background) GetClass

func (*Background) GetClass() string

func (*Background) GetType

func (*Background) GetType() string

func (*Background) MarshalJSON

func (entity *Background) MarshalJSON() ([]byte, error)

func (*Background) UnmarshalJSON

func (background *Background) UnmarshalJSON(data []byte) error

type BackgroundFill

type BackgroundFill interface {
	BackgroundFillType() string
}

Describes a fill of a background

func UnmarshalBackgroundFill

func UnmarshalBackgroundFill(data json.RawMessage) (BackgroundFill, error)

func UnmarshalListOfBackgroundFill

func UnmarshalListOfBackgroundFill(dataList []json.RawMessage) ([]BackgroundFill, error)

type BackgroundFillGradient

type BackgroundFillGradient struct {

	// A top color of the background in the RGB24 format
	TopColor int32 `json:"top_color"`
	// A bottom color of the background in the RGB24 format
	BottomColor int32 `json:"bottom_color"`
	// Clockwise rotation angle of the gradient, in degrees; 0-359. Should be always divisible by 45
	RotationAngle int32 `json:"rotation_angle"`
	// contains filtered or unexported fields
}

Describes a gradient fill of a background

func UnmarshalBackgroundFillGradient

func UnmarshalBackgroundFillGradient(data json.RawMessage) (*BackgroundFillGradient, error)

func (*BackgroundFillGradient) BackgroundFillType

func (*BackgroundFillGradient) BackgroundFillType() string

func (*BackgroundFillGradient) GetClass

func (*BackgroundFillGradient) GetClass() string

func (*BackgroundFillGradient) GetType

func (*BackgroundFillGradient) GetType() string

func (*BackgroundFillGradient) MarshalJSON

func (entity *BackgroundFillGradient) MarshalJSON() ([]byte, error)

type BackgroundFillSolid

type BackgroundFillSolid struct {

	// A color of the background in the RGB24 format
	Color int32 `json:"color"`
	// contains filtered or unexported fields
}

Describes a solid fill of a background

func UnmarshalBackgroundFillSolid

func UnmarshalBackgroundFillSolid(data json.RawMessage) (*BackgroundFillSolid, error)

func (*BackgroundFillSolid) BackgroundFillType

func (*BackgroundFillSolid) BackgroundFillType() string

func (*BackgroundFillSolid) GetClass

func (*BackgroundFillSolid) GetClass() string

func (*BackgroundFillSolid) GetType

func (*BackgroundFillSolid) GetType() string

func (*BackgroundFillSolid) MarshalJSON

func (entity *BackgroundFillSolid) MarshalJSON() ([]byte, error)

type BackgroundType

type BackgroundType interface {
	BackgroundTypeType() string
}

Describes the type of a background

func UnmarshalBackgroundType

func UnmarshalBackgroundType(data json.RawMessage) (BackgroundType, error)

func UnmarshalListOfBackgroundType

func UnmarshalListOfBackgroundType(dataList []json.RawMessage) ([]BackgroundType, error)

type BackgroundTypeFill

type BackgroundTypeFill struct {

	// Description of the background fill
	Fill BackgroundFill `json:"fill"`
	// contains filtered or unexported fields
}

A filled background

func UnmarshalBackgroundTypeFill

func UnmarshalBackgroundTypeFill(data json.RawMessage) (*BackgroundTypeFill, error)

func (*BackgroundTypeFill) BackgroundTypeType

func (*BackgroundTypeFill) BackgroundTypeType() string

func (*BackgroundTypeFill) GetClass

func (*BackgroundTypeFill) GetClass() string

func (*BackgroundTypeFill) GetType

func (*BackgroundTypeFill) GetType() string

func (*BackgroundTypeFill) MarshalJSON

func (entity *BackgroundTypeFill) MarshalJSON() ([]byte, error)

func (*BackgroundTypeFill) UnmarshalJSON

func (backgroundTypeFill *BackgroundTypeFill) UnmarshalJSON(data []byte) error

type BackgroundTypePattern

type BackgroundTypePattern struct {

	// Description of the background fill
	Fill BackgroundFill `json:"fill"`
	// Intensity of the pattern when it is shown above the filled background, 0-100
	Intensity int32 `json:"intensity"`
	// True, if the background needs to be slightly moved when device is tilted
	IsMoving bool `json:"is_moving"`
	// contains filtered or unexported fields
}

A PNG or TGV (gzipped subset of SVG with MIME type "application/x-tgwallpattern") pattern to be combined with the background fill chosen by the user

func UnmarshalBackgroundTypePattern

func UnmarshalBackgroundTypePattern(data json.RawMessage) (*BackgroundTypePattern, error)

func (*BackgroundTypePattern) BackgroundTypeType

func (*BackgroundTypePattern) BackgroundTypeType() string

func (*BackgroundTypePattern) GetClass

func (*BackgroundTypePattern) GetClass() string

func (*BackgroundTypePattern) GetType

func (*BackgroundTypePattern) GetType() string

func (*BackgroundTypePattern) MarshalJSON

func (entity *BackgroundTypePattern) MarshalJSON() ([]byte, error)

func (*BackgroundTypePattern) UnmarshalJSON

func (backgroundTypePattern *BackgroundTypePattern) UnmarshalJSON(data []byte) error

type BackgroundTypeWallpaper

type BackgroundTypeWallpaper struct {

	// True, if the wallpaper must be downscaled to fit in 450x450 square and then box-blurred with radius 12
	IsBlurred bool `json:"is_blurred"`
	// True, if the background needs to be slightly moved when device is tilted
	IsMoving bool `json:"is_moving"`
	// contains filtered or unexported fields
}

A wallpaper in JPEG format

func UnmarshalBackgroundTypeWallpaper

func UnmarshalBackgroundTypeWallpaper(data json.RawMessage) (*BackgroundTypeWallpaper, error)

func (*BackgroundTypeWallpaper) BackgroundTypeType

func (*BackgroundTypeWallpaper) BackgroundTypeType() string

func (*BackgroundTypeWallpaper) GetClass

func (*BackgroundTypeWallpaper) GetClass() string

func (*BackgroundTypeWallpaper) GetType

func (*BackgroundTypeWallpaper) GetType() string

func (*BackgroundTypeWallpaper) MarshalJSON

func (entity *BackgroundTypeWallpaper) MarshalJSON() ([]byte, error)

type Backgrounds

type Backgrounds struct {

	// A list of backgrounds
	Backgrounds []*Background `json:"backgrounds"`
	// contains filtered or unexported fields
}

Contains a list of backgrounds

func UnmarshalBackgrounds

func UnmarshalBackgrounds(data json.RawMessage) (*Backgrounds, error)

func (*Backgrounds) GetClass

func (*Backgrounds) GetClass() string

func (*Backgrounds) GetType

func (*Backgrounds) GetType() string

func (*Backgrounds) MarshalJSON

func (entity *Backgrounds) MarshalJSON() ([]byte, error)

type BankCardActionOpenUrl

type BankCardActionOpenUrl struct {

	// Action text
	Text string `json:"text"`
	// The URL to be opened
	Url string `json:"url"`
	// contains filtered or unexported fields
}

Describes an action associated with a bank card number

func UnmarshalBankCardActionOpenUrl

func UnmarshalBankCardActionOpenUrl(data json.RawMessage) (*BankCardActionOpenUrl, error)

func (*BankCardActionOpenUrl) GetClass

func (*BankCardActionOpenUrl) GetClass() string

func (*BankCardActionOpenUrl) GetType

func (*BankCardActionOpenUrl) GetType() string

func (*BankCardActionOpenUrl) MarshalJSON

func (entity *BankCardActionOpenUrl) MarshalJSON() ([]byte, error)

type BankCardInfo

type BankCardInfo struct {

	// Title of the bank card description
	Title string `json:"title"`
	// Actions that can be done with the bank card number
	Actions []*BankCardActionOpenUrl `json:"actions"`
	// contains filtered or unexported fields
}

Information about a bank card

func UnmarshalBankCardInfo

func UnmarshalBankCardInfo(data json.RawMessage) (*BankCardInfo, error)

func (*BankCardInfo) GetClass

func (*BankCardInfo) GetClass() string

func (*BankCardInfo) GetType

func (*BankCardInfo) GetType() string

func (*BankCardInfo) MarshalJSON

func (entity *BankCardInfo) MarshalJSON() ([]byte, error)

type BasicGroup

type BasicGroup struct {

	// Group identifier
	Id int32 `json:"id"`
	// Number of members in the group
	MemberCount int32 `json:"member_count"`
	// Status of the current user in the group
	Status ChatMemberStatus `json:"status"`
	// True, if the group is active
	IsActive bool `json:"is_active"`
	// Identifier of the supergroup to which this group was upgraded; 0 if none
	UpgradedToSupergroupId int32 `json:"upgraded_to_supergroup_id"`
	// contains filtered or unexported fields
}

Represents a basic group of 0-200 users (must be upgraded to a supergroup to accommodate more than 200 users)

func UnmarshalBasicGroup

func UnmarshalBasicGroup(data json.RawMessage) (*BasicGroup, error)

func (*BasicGroup) GetClass

func (*BasicGroup) GetClass() string

func (*BasicGroup) GetType

func (*BasicGroup) GetType() string

func (*BasicGroup) MarshalJSON

func (entity *BasicGroup) MarshalJSON() ([]byte, error)

func (*BasicGroup) UnmarshalJSON

func (basicGroup *BasicGroup) UnmarshalJSON(data []byte) error

type BasicGroupFullInfo

type BasicGroupFullInfo struct {

	// Chat photo; may be null
	Photo *ChatPhoto `json:"photo"`
	// Group description
	Description string `json:"description"`
	// User identifier of the creator of the group; 0 if unknown
	CreatorUserId int32 `json:"creator_user_id"`
	// Group members
	Members []*ChatMember `json:"members"`
	// Invite link for this group; available only after it has been generated at least once and only for the group creator
	InviteLink string `json:"invite_link"`
	// contains filtered or unexported fields
}

Contains full information about a basic group

func UnmarshalBasicGroupFullInfo

func UnmarshalBasicGroupFullInfo(data json.RawMessage) (*BasicGroupFullInfo, error)

func (*BasicGroupFullInfo) GetClass

func (*BasicGroupFullInfo) GetClass() string

func (*BasicGroupFullInfo) GetType

func (*BasicGroupFullInfo) GetType() string

func (*BasicGroupFullInfo) MarshalJSON

func (entity *BasicGroupFullInfo) MarshalJSON() ([]byte, error)

type BlockMessageSenderFromRepliesRequest

type BlockMessageSenderFromRepliesRequest struct {
	// The identifier of an incoming message in the Replies chat
	MessageId int64 `json:"message_id"`
	// Pass true if the message must be deleted
	DeleteMessage bool `json:"delete_message"`
	// Pass true if all messages from the same sender must be deleted
	DeleteAllMessages bool `json:"delete_all_messages"`
	// Pass true if the sender must be reported to the Telegram moderators
	ReportSpam bool `json:"report_spam"`
}

type BotCommand

type BotCommand struct {

	// Text of the bot command
	Command string `json:"command"`
	// Description of the bot command
	Description string `json:"description"`
	// contains filtered or unexported fields
}

Represents a command supported by a bot

func UnmarshalBotCommand

func UnmarshalBotCommand(data json.RawMessage) (*BotCommand, error)

func (*BotCommand) GetClass

func (*BotCommand) GetClass() string

func (*BotCommand) GetType

func (*BotCommand) GetType() string

func (*BotCommand) MarshalJSON

func (entity *BotCommand) MarshalJSON() ([]byte, error)

type BotInfo

type BotInfo struct {

	// Long description shown on the user info page
	Description string `json:"description"`
	// A list of commands supported by the bot
	Commands []*BotCommand `json:"commands"`
	// contains filtered or unexported fields
}

Provides information about a bot and its supported commands

func UnmarshalBotInfo

func UnmarshalBotInfo(data json.RawMessage) (*BotInfo, error)

func (*BotInfo) GetClass

func (*BotInfo) GetClass() string

func (*BotInfo) GetType

func (*BotInfo) GetType() string

func (*BotInfo) MarshalJSON

func (entity *BotInfo) MarshalJSON() ([]byte, error)

type Call

type Call struct {

	// Call identifier, not persistent
	Id int32 `json:"id"`
	// Peer user identifier
	UserId int32 `json:"user_id"`
	// True, if the call is outgoing
	IsOutgoing bool `json:"is_outgoing"`
	// True, if the call is a video call
	IsVideo bool `json:"is_video"`
	// Call state
	State CallState `json:"state"`
	// contains filtered or unexported fields
}

Describes a call

func UnmarshalCall

func UnmarshalCall(data json.RawMessage) (*Call, error)

func (*Call) GetClass

func (*Call) GetClass() string

func (*Call) GetType

func (*Call) GetType() string

func (*Call) MarshalJSON

func (entity *Call) MarshalJSON() ([]byte, error)

func (*Call) UnmarshalJSON

func (call *Call) UnmarshalJSON(data []byte) error

type CallDiscardReason

type CallDiscardReason interface {
	CallDiscardReasonType() string
}

Describes the reason why a call was discarded

func UnmarshalCallDiscardReason

func UnmarshalCallDiscardReason(data json.RawMessage) (CallDiscardReason, error)

func UnmarshalListOfCallDiscardReason

func UnmarshalListOfCallDiscardReason(dataList []json.RawMessage) ([]CallDiscardReason, error)

type CallDiscardReasonDeclined

type CallDiscardReasonDeclined struct {
	// contains filtered or unexported fields
}

The call was ended before the conversation started. It was declined by the other party

func UnmarshalCallDiscardReasonDeclined

func UnmarshalCallDiscardReasonDeclined(data json.RawMessage) (*CallDiscardReasonDeclined, error)

func (*CallDiscardReasonDeclined) CallDiscardReasonType

func (*CallDiscardReasonDeclined) CallDiscardReasonType() string

func (*CallDiscardReasonDeclined) GetClass

func (*CallDiscardReasonDeclined) GetClass() string

func (*CallDiscardReasonDeclined) GetType

func (*CallDiscardReasonDeclined) GetType() string

func (*CallDiscardReasonDeclined) MarshalJSON

func (entity *CallDiscardReasonDeclined) MarshalJSON() ([]byte, error)

type CallDiscardReasonDisconnected

type CallDiscardReasonDisconnected struct {
	// contains filtered or unexported fields
}

The call was ended during the conversation because the users were disconnected

func UnmarshalCallDiscardReasonDisconnected

func UnmarshalCallDiscardReasonDisconnected(data json.RawMessage) (*CallDiscardReasonDisconnected, error)

func (*CallDiscardReasonDisconnected) CallDiscardReasonType

func (*CallDiscardReasonDisconnected) CallDiscardReasonType() string

func (*CallDiscardReasonDisconnected) GetClass

func (*CallDiscardReasonDisconnected) GetType

func (*CallDiscardReasonDisconnected) MarshalJSON

func (entity *CallDiscardReasonDisconnected) MarshalJSON() ([]byte, error)

type CallDiscardReasonEmpty

type CallDiscardReasonEmpty struct {
	// contains filtered or unexported fields
}

The call wasn't discarded, or the reason is unknown

func UnmarshalCallDiscardReasonEmpty

func UnmarshalCallDiscardReasonEmpty(data json.RawMessage) (*CallDiscardReasonEmpty, error)

func (*CallDiscardReasonEmpty) CallDiscardReasonType

func (*CallDiscardReasonEmpty) CallDiscardReasonType() string

func (*CallDiscardReasonEmpty) GetClass

func (*CallDiscardReasonEmpty) GetClass() string

func (*CallDiscardReasonEmpty) GetType

func (*CallDiscardReasonEmpty) GetType() string

func (*CallDiscardReasonEmpty) MarshalJSON

func (entity *CallDiscardReasonEmpty) MarshalJSON() ([]byte, error)

type CallDiscardReasonHungUp

type CallDiscardReasonHungUp struct {
	// contains filtered or unexported fields
}

The call was ended because one of the parties hung up

func UnmarshalCallDiscardReasonHungUp

func UnmarshalCallDiscardReasonHungUp(data json.RawMessage) (*CallDiscardReasonHungUp, error)

func (*CallDiscardReasonHungUp) CallDiscardReasonType

func (*CallDiscardReasonHungUp) CallDiscardReasonType() string

func (*CallDiscardReasonHungUp) GetClass

func (*CallDiscardReasonHungUp) GetClass() string

func (*CallDiscardReasonHungUp) GetType

func (*CallDiscardReasonHungUp) GetType() string

func (*CallDiscardReasonHungUp) MarshalJSON

func (entity *CallDiscardReasonHungUp) MarshalJSON() ([]byte, error)

type CallDiscardReasonMissed

type CallDiscardReasonMissed struct {
	// contains filtered or unexported fields
}

The call was ended before the conversation started. It was cancelled by the caller or missed by the other party

func UnmarshalCallDiscardReasonMissed

func UnmarshalCallDiscardReasonMissed(data json.RawMessage) (*CallDiscardReasonMissed, error)

func (*CallDiscardReasonMissed) CallDiscardReasonType

func (*CallDiscardReasonMissed) CallDiscardReasonType() string

func (*CallDiscardReasonMissed) GetClass

func (*CallDiscardReasonMissed) GetClass() string

func (*CallDiscardReasonMissed) GetType

func (*CallDiscardReasonMissed) GetType() string

func (*CallDiscardReasonMissed) MarshalJSON

func (entity *CallDiscardReasonMissed) MarshalJSON() ([]byte, error)

type CallId

type CallId struct {

	// Call identifier
	Id int32 `json:"id"`
	// contains filtered or unexported fields
}

Contains the call identifier

func UnmarshalCallId

func UnmarshalCallId(data json.RawMessage) (*CallId, error)

func (*CallId) GetClass

func (*CallId) GetClass() string

func (*CallId) GetType

func (*CallId) GetType() string

func (*CallId) MarshalJSON

func (entity *CallId) MarshalJSON() ([]byte, error)

type CallProblem

type CallProblem interface {
	CallProblemType() string
}

Describes the exact type of a problem with a call

func UnmarshalCallProblem

func UnmarshalCallProblem(data json.RawMessage) (CallProblem, error)

func UnmarshalListOfCallProblem

func UnmarshalListOfCallProblem(dataList []json.RawMessage) ([]CallProblem, error)

type CallProblemDistortedSpeech

type CallProblemDistortedSpeech struct {
	// contains filtered or unexported fields
}

The speech was distorted

func UnmarshalCallProblemDistortedSpeech

func UnmarshalCallProblemDistortedSpeech(data json.RawMessage) (*CallProblemDistortedSpeech, error)

func (*CallProblemDistortedSpeech) CallProblemType

func (*CallProblemDistortedSpeech) CallProblemType() string

func (*CallProblemDistortedSpeech) GetClass

func (*CallProblemDistortedSpeech) GetClass() string

func (*CallProblemDistortedSpeech) GetType

func (*CallProblemDistortedSpeech) MarshalJSON

func (entity *CallProblemDistortedSpeech) MarshalJSON() ([]byte, error)

type CallProblemDistortedVideo

type CallProblemDistortedVideo struct {
	// contains filtered or unexported fields
}

The video was distorted

func UnmarshalCallProblemDistortedVideo

func UnmarshalCallProblemDistortedVideo(data json.RawMessage) (*CallProblemDistortedVideo, error)

func (*CallProblemDistortedVideo) CallProblemType

func (*CallProblemDistortedVideo) CallProblemType() string

func (*CallProblemDistortedVideo) GetClass

func (*CallProblemDistortedVideo) GetClass() string

func (*CallProblemDistortedVideo) GetType

func (*CallProblemDistortedVideo) GetType() string

func (*CallProblemDistortedVideo) MarshalJSON

func (entity *CallProblemDistortedVideo) MarshalJSON() ([]byte, error)

type CallProblemDropped

type CallProblemDropped struct {
	// contains filtered or unexported fields
}

The call ended unexpectedly

func UnmarshalCallProblemDropped

func UnmarshalCallProblemDropped(data json.RawMessage) (*CallProblemDropped, error)

func (*CallProblemDropped) CallProblemType

func (*CallProblemDropped) CallProblemType() string

func (*CallProblemDropped) GetClass

func (*CallProblemDropped) GetClass() string

func (*CallProblemDropped) GetType

func (*CallProblemDropped) GetType() string

func (*CallProblemDropped) MarshalJSON

func (entity *CallProblemDropped) MarshalJSON() ([]byte, error)

type CallProblemEcho

type CallProblemEcho struct {
	// contains filtered or unexported fields
}

The user heard their own voice

func UnmarshalCallProblemEcho

func UnmarshalCallProblemEcho(data json.RawMessage) (*CallProblemEcho, error)

func (*CallProblemEcho) CallProblemType

func (*CallProblemEcho) CallProblemType() string

func (*CallProblemEcho) GetClass

func (*CallProblemEcho) GetClass() string

func (*CallProblemEcho) GetType

func (*CallProblemEcho) GetType() string

func (*CallProblemEcho) MarshalJSON

func (entity *CallProblemEcho) MarshalJSON() ([]byte, error)

type CallProblemInterruptions

type CallProblemInterruptions struct {
	// contains filtered or unexported fields
}

The other side kept disappearing

func UnmarshalCallProblemInterruptions

func UnmarshalCallProblemInterruptions(data json.RawMessage) (*CallProblemInterruptions, error)

func (*CallProblemInterruptions) CallProblemType

func (*CallProblemInterruptions) CallProblemType() string

func (*CallProblemInterruptions) GetClass

func (*CallProblemInterruptions) GetClass() string

func (*CallProblemInterruptions) GetType

func (*CallProblemInterruptions) GetType() string

func (*CallProblemInterruptions) MarshalJSON

func (entity *CallProblemInterruptions) MarshalJSON() ([]byte, error)

type CallProblemNoise

type CallProblemNoise struct {
	// contains filtered or unexported fields
}

The user heard background noise

func UnmarshalCallProblemNoise

func UnmarshalCallProblemNoise(data json.RawMessage) (*CallProblemNoise, error)

func (*CallProblemNoise) CallProblemType

func (*CallProblemNoise) CallProblemType() string

func (*CallProblemNoise) GetClass

func (*CallProblemNoise) GetClass() string

func (*CallProblemNoise) GetType

func (*CallProblemNoise) GetType() string

func (*CallProblemNoise) MarshalJSON

func (entity *CallProblemNoise) MarshalJSON() ([]byte, error)

type CallProblemPixelatedVideo

type CallProblemPixelatedVideo struct {
	// contains filtered or unexported fields
}

The video was pixelated

func UnmarshalCallProblemPixelatedVideo

func UnmarshalCallProblemPixelatedVideo(data json.RawMessage) (*CallProblemPixelatedVideo, error)

func (*CallProblemPixelatedVideo) CallProblemType

func (*CallProblemPixelatedVideo) CallProblemType() string

func (*CallProblemPixelatedVideo) GetClass

func (*CallProblemPixelatedVideo) GetClass() string

func (*CallProblemPixelatedVideo) GetType

func (*CallProblemPixelatedVideo) GetType() string

func (*CallProblemPixelatedVideo) MarshalJSON

func (entity *CallProblemPixelatedVideo) MarshalJSON() ([]byte, error)

type CallProblemSilentLocal

type CallProblemSilentLocal struct {
	// contains filtered or unexported fields
}

The user couldn't hear the other side

func UnmarshalCallProblemSilentLocal

func UnmarshalCallProblemSilentLocal(data json.RawMessage) (*CallProblemSilentLocal, error)

func (*CallProblemSilentLocal) CallProblemType

func (*CallProblemSilentLocal) CallProblemType() string

func (*CallProblemSilentLocal) GetClass

func (*CallProblemSilentLocal) GetClass() string

func (*CallProblemSilentLocal) GetType

func (*CallProblemSilentLocal) GetType() string

func (*CallProblemSilentLocal) MarshalJSON

func (entity *CallProblemSilentLocal) MarshalJSON() ([]byte, error)

type CallProblemSilentRemote

type CallProblemSilentRemote struct {
	// contains filtered or unexported fields
}

The other side couldn't hear the user

func UnmarshalCallProblemSilentRemote

func UnmarshalCallProblemSilentRemote(data json.RawMessage) (*CallProblemSilentRemote, error)

func (*CallProblemSilentRemote) CallProblemType

func (*CallProblemSilentRemote) CallProblemType() string

func (*CallProblemSilentRemote) GetClass

func (*CallProblemSilentRemote) GetClass() string

func (*CallProblemSilentRemote) GetType

func (*CallProblemSilentRemote) GetType() string

func (*CallProblemSilentRemote) MarshalJSON

func (entity *CallProblemSilentRemote) MarshalJSON() ([]byte, error)

type CallProtocol

type CallProtocol struct {

	// True, if UDP peer-to-peer connections are supported
	UdpP2p bool `json:"udp_p2p"`
	// True, if connection through UDP reflectors is supported
	UdpReflector bool `json:"udp_reflector"`
	// The minimum supported API layer; use 65
	MinLayer int32 `json:"min_layer"`
	// The maximum supported API layer; use 65
	MaxLayer int32 `json:"max_layer"`
	// List of supported libtgvoip versions
	LibraryVersions []string `json:"library_versions"`
	// contains filtered or unexported fields
}

Specifies the supported call protocols

func UnmarshalCallProtocol

func UnmarshalCallProtocol(data json.RawMessage) (*CallProtocol, error)

func (*CallProtocol) GetClass

func (*CallProtocol) GetClass() string

func (*CallProtocol) GetType

func (*CallProtocol) GetType() string

func (*CallProtocol) MarshalJSON

func (entity *CallProtocol) MarshalJSON() ([]byte, error)

type CallServer

type CallServer struct {

	// Server identifier
	Id JsonInt64 `json:"id"`
	// Server IPv4 address
	IpAddress string `json:"ip_address"`
	// Server IPv6 address
	Ipv6Address string `json:"ipv6_address"`
	// Server port number
	Port int32 `json:"port"`
	// Server type
	Type CallServerType `json:"type"`
	// contains filtered or unexported fields
}

Describes a server for relaying call data

func UnmarshalCallServer

func UnmarshalCallServer(data json.RawMessage) (*CallServer, error)

func (*CallServer) GetClass

func (*CallServer) GetClass() string

func (*CallServer) GetType

func (*CallServer) GetType() string

func (*CallServer) MarshalJSON

func (entity *CallServer) MarshalJSON() ([]byte, error)

func (*CallServer) UnmarshalJSON

func (callServer *CallServer) UnmarshalJSON(data []byte) error

type CallServerType

type CallServerType interface {
	CallServerTypeType() string
}

Describes the type of a call server

func UnmarshalCallServerType

func UnmarshalCallServerType(data json.RawMessage) (CallServerType, error)

func UnmarshalListOfCallServerType

func UnmarshalListOfCallServerType(dataList []json.RawMessage) ([]CallServerType, error)

type CallServerTypeTelegramReflector

type CallServerTypeTelegramReflector struct {

	// A peer tag to be used with the reflector
	PeerTag []byte `json:"peer_tag"`
	// contains filtered or unexported fields
}

A Telegram call reflector

func UnmarshalCallServerTypeTelegramReflector

func UnmarshalCallServerTypeTelegramReflector(data json.RawMessage) (*CallServerTypeTelegramReflector, error)

func (*CallServerTypeTelegramReflector) CallServerTypeType

func (*CallServerTypeTelegramReflector) CallServerTypeType() string

func (*CallServerTypeTelegramReflector) GetClass

func (*CallServerTypeTelegramReflector) GetType

func (*CallServerTypeTelegramReflector) MarshalJSON

func (entity *CallServerTypeTelegramReflector) MarshalJSON() ([]byte, error)

type CallServerTypeWebrtc

type CallServerTypeWebrtc struct {

	// Username to be used for authentication
	Username string `json:"username"`
	// Authentication password
	Password string `json:"password"`
	// True, if the server supports TURN
	SupportsTurn bool `json:"supports_turn"`
	// True, if the server supports STUN
	SupportsStun bool `json:"supports_stun"`
	// contains filtered or unexported fields
}

A WebRTC server

func UnmarshalCallServerTypeWebrtc

func UnmarshalCallServerTypeWebrtc(data json.RawMessage) (*CallServerTypeWebrtc, error)

func (*CallServerTypeWebrtc) CallServerTypeType

func (*CallServerTypeWebrtc) CallServerTypeType() string

func (*CallServerTypeWebrtc) GetClass

func (*CallServerTypeWebrtc) GetClass() string

func (*CallServerTypeWebrtc) GetType

func (*CallServerTypeWebrtc) GetType() string

func (*CallServerTypeWebrtc) MarshalJSON

func (entity *CallServerTypeWebrtc) MarshalJSON() ([]byte, error)

type CallState

type CallState interface {
	CallStateType() string
}

Describes the current call state

func UnmarshalCallState

func UnmarshalCallState(data json.RawMessage) (CallState, error)

func UnmarshalListOfCallState

func UnmarshalListOfCallState(dataList []json.RawMessage) ([]CallState, error)

type CallStateDiscarded

type CallStateDiscarded struct {

	// The reason, why the call has ended
	Reason CallDiscardReason `json:"reason"`
	// True, if the call rating should be sent to the server
	NeedRating bool `json:"need_rating"`
	// True, if the call debug information should be sent to the server
	NeedDebugInformation bool `json:"need_debug_information"`
	// contains filtered or unexported fields
}

The call has ended successfully

func UnmarshalCallStateDiscarded

func UnmarshalCallStateDiscarded(data json.RawMessage) (*CallStateDiscarded, error)

func (*CallStateDiscarded) CallStateType

func (*CallStateDiscarded) CallStateType() string

func (*CallStateDiscarded) GetClass

func (*CallStateDiscarded) GetClass() string

func (*CallStateDiscarded) GetType

func (*CallStateDiscarded) GetType() string

func (*CallStateDiscarded) MarshalJSON

func (entity *CallStateDiscarded) MarshalJSON() ([]byte, error)

func (*CallStateDiscarded) UnmarshalJSON

func (callStateDiscarded *CallStateDiscarded) UnmarshalJSON(data []byte) error

type CallStateError

type CallStateError struct {

	// Error. An error with the code 4005000 will be returned if an outgoing call is missed because of an expired timeout
	Error *Error `json:"error"`
	// contains filtered or unexported fields
}

The call has ended with an error

func UnmarshalCallStateError

func UnmarshalCallStateError(data json.RawMessage) (*CallStateError, error)

func (*CallStateError) CallStateType

func (*CallStateError) CallStateType() string

func (*CallStateError) GetClass

func (*CallStateError) GetClass() string

func (*CallStateError) GetType

func (*CallStateError) GetType() string

func (*CallStateError) MarshalJSON

func (entity *CallStateError) MarshalJSON() ([]byte, error)

type CallStateExchangingKeys

type CallStateExchangingKeys struct {
	// contains filtered or unexported fields
}

The call has been answered and encryption keys are being exchanged

func UnmarshalCallStateExchangingKeys

func UnmarshalCallStateExchangingKeys(data json.RawMessage) (*CallStateExchangingKeys, error)

func (*CallStateExchangingKeys) CallStateType

func (*CallStateExchangingKeys) CallStateType() string

func (*CallStateExchangingKeys) GetClass

func (*CallStateExchangingKeys) GetClass() string

func (*CallStateExchangingKeys) GetType

func (*CallStateExchangingKeys) GetType() string

func (*CallStateExchangingKeys) MarshalJSON

func (entity *CallStateExchangingKeys) MarshalJSON() ([]byte, error)

type CallStateHangingUp

type CallStateHangingUp struct {
	// contains filtered or unexported fields
}

The call is hanging up after discardCall has been called

func UnmarshalCallStateHangingUp

func UnmarshalCallStateHangingUp(data json.RawMessage) (*CallStateHangingUp, error)

func (*CallStateHangingUp) CallStateType

func (*CallStateHangingUp) CallStateType() string

func (*CallStateHangingUp) GetClass

func (*CallStateHangingUp) GetClass() string

func (*CallStateHangingUp) GetType

func (*CallStateHangingUp) GetType() string

func (*CallStateHangingUp) MarshalJSON

func (entity *CallStateHangingUp) MarshalJSON() ([]byte, error)

type CallStatePending

type CallStatePending struct {

	// True, if the call has already been created by the server
	IsCreated bool `json:"is_created"`
	// True, if the call has already been received by the other party
	IsReceived bool `json:"is_received"`
	// contains filtered or unexported fields
}

The call is pending, waiting to be accepted by a user

func UnmarshalCallStatePending

func UnmarshalCallStatePending(data json.RawMessage) (*CallStatePending, error)

func (*CallStatePending) CallStateType

func (*CallStatePending) CallStateType() string

func (*CallStatePending) GetClass

func (*CallStatePending) GetClass() string

func (*CallStatePending) GetType

func (*CallStatePending) GetType() string

func (*CallStatePending) MarshalJSON

func (entity *CallStatePending) MarshalJSON() ([]byte, error)

type CallStateReady

type CallStateReady struct {

	// Call protocols supported by the peer
	Protocol *CallProtocol `json:"protocol"`
	// List of available call servers
	Servers []*CallServer `json:"servers"`
	// A JSON-encoded call config
	Config string `json:"config"`
	// Call encryption key
	EncryptionKey []byte `json:"encryption_key"`
	// Encryption key emojis fingerprint
	Emojis []string `json:"emojis"`
	// True, if peer-to-peer connection is allowed by users privacy settings
	AllowP2p bool `json:"allow_p2p"`
	// contains filtered or unexported fields
}

The call is ready to use

func UnmarshalCallStateReady

func UnmarshalCallStateReady(data json.RawMessage) (*CallStateReady, error)

func (*CallStateReady) CallStateType

func (*CallStateReady) CallStateType() string

func (*CallStateReady) GetClass

func (*CallStateReady) GetClass() string

func (*CallStateReady) GetType

func (*CallStateReady) GetType() string

func (*CallStateReady) MarshalJSON

func (entity *CallStateReady) MarshalJSON() ([]byte, error)

type CallbackQueryAnswer

type CallbackQueryAnswer struct {

	// Text of the answer
	Text string `json:"text"`
	// True, if an alert should be shown to the user instead of a toast notification
	ShowAlert bool `json:"show_alert"`
	// URL to be opened
	Url string `json:"url"`
	// contains filtered or unexported fields
}

Contains a bot's answer to a callback query

func UnmarshalCallbackQueryAnswer

func UnmarshalCallbackQueryAnswer(data json.RawMessage) (*CallbackQueryAnswer, error)

func (*CallbackQueryAnswer) GetClass

func (*CallbackQueryAnswer) GetClass() string

func (*CallbackQueryAnswer) GetType

func (*CallbackQueryAnswer) GetType() string

func (*CallbackQueryAnswer) MarshalJSON

func (entity *CallbackQueryAnswer) MarshalJSON() ([]byte, error)

type CallbackQueryPayload

type CallbackQueryPayload interface {
	CallbackQueryPayloadType() string
}

Represents a payload of a callback query

func UnmarshalCallbackQueryPayload

func UnmarshalCallbackQueryPayload(data json.RawMessage) (CallbackQueryPayload, error)

func UnmarshalListOfCallbackQueryPayload

func UnmarshalListOfCallbackQueryPayload(dataList []json.RawMessage) ([]CallbackQueryPayload, error)

type CallbackQueryPayloadData

type CallbackQueryPayloadData struct {

	// Data that was attached to the callback button
	Data []byte `json:"data"`
	// contains filtered or unexported fields
}

The payload for a general callback button

func UnmarshalCallbackQueryPayloadData

func UnmarshalCallbackQueryPayloadData(data json.RawMessage) (*CallbackQueryPayloadData, error)

func (*CallbackQueryPayloadData) CallbackQueryPayloadType

func (*CallbackQueryPayloadData) CallbackQueryPayloadType() string

func (*CallbackQueryPayloadData) GetClass

func (*CallbackQueryPayloadData) GetClass() string

func (*CallbackQueryPayloadData) GetType

func (*CallbackQueryPayloadData) GetType() string

func (*CallbackQueryPayloadData) MarshalJSON

func (entity *CallbackQueryPayloadData) MarshalJSON() ([]byte, error)

type CallbackQueryPayloadDataWithPassword

type CallbackQueryPayloadDataWithPassword struct {

	// The password for the current user
	Password string `json:"password"`
	// Data that was attached to the callback button
	Data []byte `json:"data"`
	// contains filtered or unexported fields
}

The payload for a callback button requiring password

func UnmarshalCallbackQueryPayloadDataWithPassword

func UnmarshalCallbackQueryPayloadDataWithPassword(data json.RawMessage) (*CallbackQueryPayloadDataWithPassword, error)

func (*CallbackQueryPayloadDataWithPassword) CallbackQueryPayloadType

func (*CallbackQueryPayloadDataWithPassword) CallbackQueryPayloadType() string

func (*CallbackQueryPayloadDataWithPassword) GetClass

func (*CallbackQueryPayloadDataWithPassword) GetType

func (*CallbackQueryPayloadDataWithPassword) MarshalJSON

func (entity *CallbackQueryPayloadDataWithPassword) MarshalJSON() ([]byte, error)

type CallbackQueryPayloadGame

type CallbackQueryPayloadGame struct {

	// A short name of the game that was attached to the callback button
	GameShortName string `json:"game_short_name"`
	// contains filtered or unexported fields
}

The payload for a game callback button

func UnmarshalCallbackQueryPayloadGame

func UnmarshalCallbackQueryPayloadGame(data json.RawMessage) (*CallbackQueryPayloadGame, error)

func (*CallbackQueryPayloadGame) CallbackQueryPayloadType

func (*CallbackQueryPayloadGame) CallbackQueryPayloadType() string

func (*CallbackQueryPayloadGame) GetClass

func (*CallbackQueryPayloadGame) GetClass() string

func (*CallbackQueryPayloadGame) GetType

func (*CallbackQueryPayloadGame) GetType() string

func (*CallbackQueryPayloadGame) MarshalJSON

func (entity *CallbackQueryPayloadGame) MarshalJSON() ([]byte, error)

type CanTransferOwnershipResult

type CanTransferOwnershipResult interface {
	CanTransferOwnershipResultType() string
}

Represents result of checking whether the current session can be used to transfer a chat ownership to another user

func UnmarshalCanTransferOwnershipResult

func UnmarshalCanTransferOwnershipResult(data json.RawMessage) (CanTransferOwnershipResult, error)

func UnmarshalListOfCanTransferOwnershipResult

func UnmarshalListOfCanTransferOwnershipResult(dataList []json.RawMessage) ([]CanTransferOwnershipResult, error)

type CanTransferOwnershipResultOk

type CanTransferOwnershipResultOk struct {
	// contains filtered or unexported fields
}

The session can be used

func UnmarshalCanTransferOwnershipResultOk

func UnmarshalCanTransferOwnershipResultOk(data json.RawMessage) (*CanTransferOwnershipResultOk, error)

func (*CanTransferOwnershipResultOk) CanTransferOwnershipResultType

func (*CanTransferOwnershipResultOk) CanTransferOwnershipResultType() string

func (*CanTransferOwnershipResultOk) GetClass

func (*CanTransferOwnershipResultOk) GetType

func (*CanTransferOwnershipResultOk) MarshalJSON

func (entity *CanTransferOwnershipResultOk) MarshalJSON() ([]byte, error)

type CanTransferOwnershipResultPasswordNeeded

type CanTransferOwnershipResultPasswordNeeded struct {
	// contains filtered or unexported fields
}

The 2-step verification needs to be enabled first

func UnmarshalCanTransferOwnershipResultPasswordNeeded

func UnmarshalCanTransferOwnershipResultPasswordNeeded(data json.RawMessage) (*CanTransferOwnershipResultPasswordNeeded, error)

func (*CanTransferOwnershipResultPasswordNeeded) CanTransferOwnershipResultType

func (*CanTransferOwnershipResultPasswordNeeded) CanTransferOwnershipResultType() string

func (*CanTransferOwnershipResultPasswordNeeded) GetClass

func (*CanTransferOwnershipResultPasswordNeeded) GetType

func (*CanTransferOwnershipResultPasswordNeeded) MarshalJSON

func (entity *CanTransferOwnershipResultPasswordNeeded) MarshalJSON() ([]byte, error)

type CanTransferOwnershipResultPasswordTooFresh

type CanTransferOwnershipResultPasswordTooFresh struct {

	// Time left before the session can be used to transfer ownership of a chat, in seconds
	RetryAfter int32 `json:"retry_after"`
	// contains filtered or unexported fields
}

The 2-step verification was enabled recently, user needs to wait

func UnmarshalCanTransferOwnershipResultPasswordTooFresh

func UnmarshalCanTransferOwnershipResultPasswordTooFresh(data json.RawMessage) (*CanTransferOwnershipResultPasswordTooFresh, error)

func (*CanTransferOwnershipResultPasswordTooFresh) CanTransferOwnershipResultType

func (*CanTransferOwnershipResultPasswordTooFresh) CanTransferOwnershipResultType() string

func (*CanTransferOwnershipResultPasswordTooFresh) GetClass

func (*CanTransferOwnershipResultPasswordTooFresh) GetType

func (*CanTransferOwnershipResultPasswordTooFresh) MarshalJSON

func (entity *CanTransferOwnershipResultPasswordTooFresh) MarshalJSON() ([]byte, error)

type CanTransferOwnershipResultSessionTooFresh

type CanTransferOwnershipResultSessionTooFresh struct {

	// Time left before the session can be used to transfer ownership of a chat, in seconds
	RetryAfter int32 `json:"retry_after"`
	// contains filtered or unexported fields
}

The session was created recently, user needs to wait

func UnmarshalCanTransferOwnershipResultSessionTooFresh

func UnmarshalCanTransferOwnershipResultSessionTooFresh(data json.RawMessage) (*CanTransferOwnershipResultSessionTooFresh, error)

func (*CanTransferOwnershipResultSessionTooFresh) CanTransferOwnershipResultType

func (*CanTransferOwnershipResultSessionTooFresh) CanTransferOwnershipResultType() string

func (*CanTransferOwnershipResultSessionTooFresh) GetClass

func (*CanTransferOwnershipResultSessionTooFresh) GetType

func (*CanTransferOwnershipResultSessionTooFresh) MarshalJSON

func (entity *CanTransferOwnershipResultSessionTooFresh) MarshalJSON() ([]byte, error)

type CancelDownloadFileRequest

type CancelDownloadFileRequest struct {
	// Identifier of a file to stop downloading
	FileId int32 `json:"file_id"`
	// Pass true to stop downloading only if it hasn't been started, i.e. request hasn't been sent to server
	OnlyIfPending bool `json:"only_if_pending"`
}

type CancelUploadFileRequest

type CancelUploadFileRequest struct {
	// Identifier of the file to stop uploading
	FileId int32 `json:"file_id"`
}

type ChangeImportedContactsRequest

type ChangeImportedContactsRequest struct {
	// The new list of contacts, contact's vCard are ignored and are not imported
	Contacts []*Contact `json:"contacts"`
}

type ChangePhoneNumberRequest

type ChangePhoneNumberRequest struct {
	// The new phone number of the user in international format
	PhoneNumber string `json:"phone_number"`
	// Settings for the authentication of the user's phone number
	Settings *PhoneNumberAuthenticationSettings `json:"settings"`
}

type ChangeStickerSetRequest

type ChangeStickerSetRequest struct {
	// Identifier of the sticker set
	SetId JsonInt64 `json:"set_id"`
	// The new value of is_installed
	IsInstalled bool `json:"is_installed"`
	// The new value of is_archived. A sticker set can't be installed and archived simultaneously
	IsArchived bool `json:"is_archived"`
}

type Chat

type Chat struct {

	// Chat unique identifier
	Id int64 `json:"id"`
	// Type of the chat
	Type ChatType `json:"type"`
	// Chat title
	Title string `json:"title"`
	// Chat photo; may be null
	Photo *ChatPhotoInfo `json:"photo"`
	// Actions that non-administrator chat members are allowed to take in the chat
	Permissions *ChatPermissions `json:"permissions"`
	// Last message in the chat; may be null
	LastMessage *Message `json:"last_message"`
	// Positions of the chat in chat lists
	Positions []*ChatPosition `json:"positions"`
	// True, if the chat is marked as unread
	IsMarkedAsUnread bool `json:"is_marked_as_unread"`
	// True, if the chat is blocked by the current user and private messages from the chat can't be received
	IsBlocked bool `json:"is_blocked"`
	// True, if the chat has scheduled messages
	HasScheduledMessages bool `json:"has_scheduled_messages"`
	// True, if the chat messages can be deleted only for the current user while other users will continue to see the messages
	CanBeDeletedOnlyForSelf bool `json:"can_be_deleted_only_for_self"`
	// True, if the chat messages can be deleted for all users
	CanBeDeletedForAllUsers bool `json:"can_be_deleted_for_all_users"`
	// True, if the chat can be reported to Telegram moderators through reportChat
	CanBeReported bool `json:"can_be_reported"`
	// Default value of the disable_notification parameter, used when a message is sent to the chat
	DefaultDisableNotification bool `json:"default_disable_notification"`
	// Number of unread messages in the chat
	UnreadCount int32 `json:"unread_count"`
	// Identifier of the last read incoming message
	LastReadInboxMessageId int64 `json:"last_read_inbox_message_id"`
	// Identifier of the last read outgoing message
	LastReadOutboxMessageId int64 `json:"last_read_outbox_message_id"`
	// Number of unread messages with a mention/reply in the chat
	UnreadMentionCount int32 `json:"unread_mention_count"`
	// Notification settings for this chat
	NotificationSettings *ChatNotificationSettings `json:"notification_settings"`
	// Describes actions which should be possible to do through a chat action bar; may be null
	ActionBar ChatActionBar `json:"action_bar"`
	// Identifier of the message from which reply markup needs to be used; 0 if there is no default custom reply markup in the chat
	ReplyMarkupMessageId int64 `json:"reply_markup_message_id"`
	// A draft of a message in the chat; may be null
	DraftMessage *DraftMessage `json:"draft_message"`
	// Contains application-specific data associated with the chat. (For example, the chat scroll position or local chat notification settings can be stored here.) Persistent if the message database is used
	ClientData string `json:"client_data"`
	// contains filtered or unexported fields
}

A chat. (Can be a private chat, basic group, supergroup, or secret chat)

func UnmarshalChat

func UnmarshalChat(data json.RawMessage) (*Chat, error)

func (*Chat) GetClass

func (*Chat) GetClass() string

func (*Chat) GetType

func (*Chat) GetType() string

func (*Chat) MarshalJSON

func (entity *Chat) MarshalJSON() ([]byte, error)

func (*Chat) UnmarshalJSON

func (chat *Chat) UnmarshalJSON(data []byte) error

type ChatAction

type ChatAction interface {
	ChatActionType() string
}

Describes the different types of activity in a chat

func UnmarshalChatAction

func UnmarshalChatAction(data json.RawMessage) (ChatAction, error)

func UnmarshalListOfChatAction

func UnmarshalListOfChatAction(dataList []json.RawMessage) ([]ChatAction, error)

type ChatActionBar

type ChatActionBar interface {
	ChatActionBarType() string
}

Describes actions which should be possible to do through a chat action bar

func UnmarshalChatActionBar

func UnmarshalChatActionBar(data json.RawMessage) (ChatActionBar, error)

func UnmarshalListOfChatActionBar

func UnmarshalListOfChatActionBar(dataList []json.RawMessage) ([]ChatActionBar, error)

type ChatActionBarAddContact

type ChatActionBarAddContact struct {
	// contains filtered or unexported fields
}

The chat is a private or secret chat and the other user can be added to the contact list using the method addContact

func UnmarshalChatActionBarAddContact

func UnmarshalChatActionBarAddContact(data json.RawMessage) (*ChatActionBarAddContact, error)

func (*ChatActionBarAddContact) ChatActionBarType

func (*ChatActionBarAddContact) ChatActionBarType() string

func (*ChatActionBarAddContact) GetClass

func (*ChatActionBarAddContact) GetClass() string

func (*ChatActionBarAddContact) GetType

func (*ChatActionBarAddContact) GetType() string

func (*ChatActionBarAddContact) MarshalJSON

func (entity *ChatActionBarAddContact) MarshalJSON() ([]byte, error)

type ChatActionBarReportAddBlock

type ChatActionBarReportAddBlock struct {

	// If true, the chat was automatically archived and can be moved back to the main chat list using addChatToList simultaneously with setting chat notification settings to default using setChatNotificationSettings
	CanUnarchive bool `json:"can_unarchive"`
	// If non-negative, the current user was found by the peer through searchChatsNearby and this is the distance between the users
	Distance int32 `json:"distance"`
	// contains filtered or unexported fields
}

The chat is a private or secret chat, which can be reported using the method reportChat, or the other user can be blocked using the method blockUser, or the other user can be added to the contact list using the method addContact

func UnmarshalChatActionBarReportAddBlock

func UnmarshalChatActionBarReportAddBlock(data json.RawMessage) (*ChatActionBarReportAddBlock, error)

func (*ChatActionBarReportAddBlock) ChatActionBarType

func (*ChatActionBarReportAddBlock) ChatActionBarType() string

func (*ChatActionBarReportAddBlock) GetClass

func (*ChatActionBarReportAddBlock) GetClass() string

func (*ChatActionBarReportAddBlock) GetType

func (*ChatActionBarReportAddBlock) MarshalJSON

func (entity *ChatActionBarReportAddBlock) MarshalJSON() ([]byte, error)

type ChatActionBarReportSpam

type ChatActionBarReportSpam struct {

	// If true, the chat was automatically archived and can be moved back to the main chat list using addChatToList simultaneously with setting chat notification settings to default using setChatNotificationSettings
	CanUnarchive bool `json:"can_unarchive"`
	// contains filtered or unexported fields
}

The chat can be reported as spam using the method reportChat with the reason chatReportReasonSpam

func UnmarshalChatActionBarReportSpam

func UnmarshalChatActionBarReportSpam(data json.RawMessage) (*ChatActionBarReportSpam, error)

func (*ChatActionBarReportSpam) ChatActionBarType

func (*ChatActionBarReportSpam) ChatActionBarType() string

func (*ChatActionBarReportSpam) GetClass

func (*ChatActionBarReportSpam) GetClass() string

func (*ChatActionBarReportSpam) GetType

func (*ChatActionBarReportSpam) GetType() string

func (*ChatActionBarReportSpam) MarshalJSON

func (entity *ChatActionBarReportSpam) MarshalJSON() ([]byte, error)

type ChatActionBarReportUnrelatedLocation

type ChatActionBarReportUnrelatedLocation struct {
	// contains filtered or unexported fields
}

The chat is a location-based supergroup, which can be reported as having unrelated location using the method reportChat with the reason chatReportReasonUnrelatedLocation

func UnmarshalChatActionBarReportUnrelatedLocation

func UnmarshalChatActionBarReportUnrelatedLocation(data json.RawMessage) (*ChatActionBarReportUnrelatedLocation, error)

func (*ChatActionBarReportUnrelatedLocation) ChatActionBarType

func (*ChatActionBarReportUnrelatedLocation) ChatActionBarType() string

func (*ChatActionBarReportUnrelatedLocation) GetClass

func (*ChatActionBarReportUnrelatedLocation) GetType

func (*ChatActionBarReportUnrelatedLocation) MarshalJSON

func (entity *ChatActionBarReportUnrelatedLocation) MarshalJSON() ([]byte, error)

type ChatActionBarSharePhoneNumber

type ChatActionBarSharePhoneNumber struct {
	// contains filtered or unexported fields
}

The chat is a private or secret chat with a mutual contact and the user's phone number can be shared with the other user using the method sharePhoneNumber

func UnmarshalChatActionBarSharePhoneNumber

func UnmarshalChatActionBarSharePhoneNumber(data json.RawMessage) (*ChatActionBarSharePhoneNumber, error)

func (*ChatActionBarSharePhoneNumber) ChatActionBarType

func (*ChatActionBarSharePhoneNumber) ChatActionBarType() string

func (*ChatActionBarSharePhoneNumber) GetClass

func (*ChatActionBarSharePhoneNumber) GetType

func (*ChatActionBarSharePhoneNumber) MarshalJSON

func (entity *ChatActionBarSharePhoneNumber) MarshalJSON() ([]byte, error)

type ChatActionCancel

type ChatActionCancel struct {
	// contains filtered or unexported fields
}

The user has cancelled the previous action

func UnmarshalChatActionCancel

func UnmarshalChatActionCancel(data json.RawMessage) (*ChatActionCancel, error)

func (*ChatActionCancel) ChatActionType

func (*ChatActionCancel) ChatActionType() string

func (*ChatActionCancel) GetClass

func (*ChatActionCancel) GetClass() string

func (*ChatActionCancel) GetType

func (*ChatActionCancel) GetType() string

func (*ChatActionCancel) MarshalJSON

func (entity *ChatActionCancel) MarshalJSON() ([]byte, error)

type ChatActionChoosingContact

type ChatActionChoosingContact struct {
	// contains filtered or unexported fields
}

The user is picking a contact to send

func UnmarshalChatActionChoosingContact

func UnmarshalChatActionChoosingContact(data json.RawMessage) (*ChatActionChoosingContact, error)

func (*ChatActionChoosingContact) ChatActionType

func (*ChatActionChoosingContact) ChatActionType() string

func (*ChatActionChoosingContact) GetClass

func (*ChatActionChoosingContact) GetClass() string

func (*ChatActionChoosingContact) GetType

func (*ChatActionChoosingContact) GetType() string

func (*ChatActionChoosingContact) MarshalJSON

func (entity *ChatActionChoosingContact) MarshalJSON() ([]byte, error)

type ChatActionChoosingLocation

type ChatActionChoosingLocation struct {
	// contains filtered or unexported fields
}

The user is picking a location or venue to send

func UnmarshalChatActionChoosingLocation

func UnmarshalChatActionChoosingLocation(data json.RawMessage) (*ChatActionChoosingLocation, error)

func (*ChatActionChoosingLocation) ChatActionType

func (*ChatActionChoosingLocation) ChatActionType() string

func (*ChatActionChoosingLocation) GetClass

func (*ChatActionChoosingLocation) GetClass() string

func (*ChatActionChoosingLocation) GetType

func (*ChatActionChoosingLocation) MarshalJSON

func (entity *ChatActionChoosingLocation) MarshalJSON() ([]byte, error)

type ChatActionRecordingVideo

type ChatActionRecordingVideo struct {
	// contains filtered or unexported fields
}

The user is recording a video

func UnmarshalChatActionRecordingVideo

func UnmarshalChatActionRecordingVideo(data json.RawMessage) (*ChatActionRecordingVideo, error)

func (*ChatActionRecordingVideo) ChatActionType

func (*ChatActionRecordingVideo) ChatActionType() string

func (*ChatActionRecordingVideo) GetClass

func (*ChatActionRecordingVideo) GetClass() string

func (*ChatActionRecordingVideo) GetType

func (*ChatActionRecordingVideo) GetType() string

func (*ChatActionRecordingVideo) MarshalJSON

func (entity *ChatActionRecordingVideo) MarshalJSON() ([]byte, error)

type ChatActionRecordingVideoNote

type ChatActionRecordingVideoNote struct {
	// contains filtered or unexported fields
}

The user is recording a video note

func UnmarshalChatActionRecordingVideoNote

func UnmarshalChatActionRecordingVideoNote(data json.RawMessage) (*ChatActionRecordingVideoNote, error)

func (*ChatActionRecordingVideoNote) ChatActionType

func (*ChatActionRecordingVideoNote) ChatActionType() string

func (*ChatActionRecordingVideoNote) GetClass

func (*ChatActionRecordingVideoNote) GetType

func (*ChatActionRecordingVideoNote) MarshalJSON

func (entity *ChatActionRecordingVideoNote) MarshalJSON() ([]byte, error)

type ChatActionRecordingVoiceNote

type ChatActionRecordingVoiceNote struct {
	// contains filtered or unexported fields
}

The user is recording a voice note

func UnmarshalChatActionRecordingVoiceNote

func UnmarshalChatActionRecordingVoiceNote(data json.RawMessage) (*ChatActionRecordingVoiceNote, error)

func (*ChatActionRecordingVoiceNote) ChatActionType

func (*ChatActionRecordingVoiceNote) ChatActionType() string

func (*ChatActionRecordingVoiceNote) GetClass

func (*ChatActionRecordingVoiceNote) GetType

func (*ChatActionRecordingVoiceNote) MarshalJSON

func (entity *ChatActionRecordingVoiceNote) MarshalJSON() ([]byte, error)

type ChatActionStartPlayingGame

type ChatActionStartPlayingGame struct {
	// contains filtered or unexported fields
}

The user has started to play a game

func UnmarshalChatActionStartPlayingGame

func UnmarshalChatActionStartPlayingGame(data json.RawMessage) (*ChatActionStartPlayingGame, error)

func (*ChatActionStartPlayingGame) ChatActionType

func (*ChatActionStartPlayingGame) ChatActionType() string

func (*ChatActionStartPlayingGame) GetClass

func (*ChatActionStartPlayingGame) GetClass() string

func (*ChatActionStartPlayingGame) GetType

func (*ChatActionStartPlayingGame) MarshalJSON

func (entity *ChatActionStartPlayingGame) MarshalJSON() ([]byte, error)

type ChatActionTyping

type ChatActionTyping struct {
	// contains filtered or unexported fields
}

The user is typing a message

func UnmarshalChatActionTyping

func UnmarshalChatActionTyping(data json.RawMessage) (*ChatActionTyping, error)

func (*ChatActionTyping) ChatActionType

func (*ChatActionTyping) ChatActionType() string

func (*ChatActionTyping) GetClass

func (*ChatActionTyping) GetClass() string

func (*ChatActionTyping) GetType

func (*ChatActionTyping) GetType() string

func (*ChatActionTyping) MarshalJSON

func (entity *ChatActionTyping) MarshalJSON() ([]byte, error)

type ChatActionUploadingDocument

type ChatActionUploadingDocument struct {

	// Upload progress, as a percentage
	Progress int32 `json:"progress"`
	// contains filtered or unexported fields
}

The user is uploading a document

func UnmarshalChatActionUploadingDocument

func UnmarshalChatActionUploadingDocument(data json.RawMessage) (*ChatActionUploadingDocument, error)

func (*ChatActionUploadingDocument) ChatActionType

func (*ChatActionUploadingDocument) ChatActionType() string

func (*ChatActionUploadingDocument) GetClass

func (*ChatActionUploadingDocument) GetClass() string

func (*ChatActionUploadingDocument) GetType

func (*ChatActionUploadingDocument) MarshalJSON

func (entity *ChatActionUploadingDocument) MarshalJSON() ([]byte, error)

type ChatActionUploadingPhoto

type ChatActionUploadingPhoto struct {

	// Upload progress, as a percentage
	Progress int32 `json:"progress"`
	// contains filtered or unexported fields
}

The user is uploading a photo

func UnmarshalChatActionUploadingPhoto

func UnmarshalChatActionUploadingPhoto(data json.RawMessage) (*ChatActionUploadingPhoto, error)

func (*ChatActionUploadingPhoto) ChatActionType

func (*ChatActionUploadingPhoto) ChatActionType() string

func (*ChatActionUploadingPhoto) GetClass

func (*ChatActionUploadingPhoto) GetClass() string

func (*ChatActionUploadingPhoto) GetType

func (*ChatActionUploadingPhoto) GetType() string

func (*ChatActionUploadingPhoto) MarshalJSON

func (entity *ChatActionUploadingPhoto) MarshalJSON() ([]byte, error)

type ChatActionUploadingVideo

type ChatActionUploadingVideo struct {

	// Upload progress, as a percentage
	Progress int32 `json:"progress"`
	// contains filtered or unexported fields
}

The user is uploading a video

func UnmarshalChatActionUploadingVideo

func UnmarshalChatActionUploadingVideo(data json.RawMessage) (*ChatActionUploadingVideo, error)

func (*ChatActionUploadingVideo) ChatActionType

func (*ChatActionUploadingVideo) ChatActionType() string

func (*ChatActionUploadingVideo) GetClass

func (*ChatActionUploadingVideo) GetClass() string

func (*ChatActionUploadingVideo) GetType

func (*ChatActionUploadingVideo) GetType() string

func (*ChatActionUploadingVideo) MarshalJSON

func (entity *ChatActionUploadingVideo) MarshalJSON() ([]byte, error)

type ChatActionUploadingVideoNote

type ChatActionUploadingVideoNote struct {

	// Upload progress, as a percentage
	Progress int32 `json:"progress"`
	// contains filtered or unexported fields
}

The user is uploading a video note

func UnmarshalChatActionUploadingVideoNote

func UnmarshalChatActionUploadingVideoNote(data json.RawMessage) (*ChatActionUploadingVideoNote, error)

func (*ChatActionUploadingVideoNote) ChatActionType

func (*ChatActionUploadingVideoNote) ChatActionType() string

func (*ChatActionUploadingVideoNote) GetClass

func (*ChatActionUploadingVideoNote) GetType

func (*ChatActionUploadingVideoNote) MarshalJSON

func (entity *ChatActionUploadingVideoNote) MarshalJSON() ([]byte, error)

type ChatActionUploadingVoiceNote

type ChatActionUploadingVoiceNote struct {

	// Upload progress, as a percentage
	Progress int32 `json:"progress"`
	// contains filtered or unexported fields
}

The user is uploading a voice note

func UnmarshalChatActionUploadingVoiceNote

func UnmarshalChatActionUploadingVoiceNote(data json.RawMessage) (*ChatActionUploadingVoiceNote, error)

func (*ChatActionUploadingVoiceNote) ChatActionType

func (*ChatActionUploadingVoiceNote) ChatActionType() string

func (*ChatActionUploadingVoiceNote) GetClass

func (*ChatActionUploadingVoiceNote) GetType

func (*ChatActionUploadingVoiceNote) MarshalJSON

func (entity *ChatActionUploadingVoiceNote) MarshalJSON() ([]byte, error)

type ChatAdministrator

type ChatAdministrator struct {

	// User identifier of the administrator
	UserId int32 `json:"user_id"`
	// Custom title of the administrator
	CustomTitle string `json:"custom_title"`
	// True, if the user is the owner of the chat
	IsOwner bool `json:"is_owner"`
	// contains filtered or unexported fields
}

Contains information about a chat administrator

func UnmarshalChatAdministrator

func UnmarshalChatAdministrator(data json.RawMessage) (*ChatAdministrator, error)

func (*ChatAdministrator) GetClass

func (*ChatAdministrator) GetClass() string

func (*ChatAdministrator) GetType

func (*ChatAdministrator) GetType() string

func (*ChatAdministrator) MarshalJSON

func (entity *ChatAdministrator) MarshalJSON() ([]byte, error)

type ChatAdministrators

type ChatAdministrators struct {

	// A list of chat administrators
	Administrators []*ChatAdministrator `json:"administrators"`
	// contains filtered or unexported fields
}

Represents a list of chat administrators

func UnmarshalChatAdministrators

func UnmarshalChatAdministrators(data json.RawMessage) (*ChatAdministrators, error)

func (*ChatAdministrators) GetClass

func (*ChatAdministrators) GetClass() string

func (*ChatAdministrators) GetType

func (*ChatAdministrators) GetType() string

func (*ChatAdministrators) MarshalJSON

func (entity *ChatAdministrators) MarshalJSON() ([]byte, error)

type ChatEvent

type ChatEvent struct {

	// Chat event identifier
	Id JsonInt64 `json:"id"`
	// Point in time (Unix timestamp) when the event happened
	Date int32 `json:"date"`
	// Identifier of the user who performed the action that triggered the event
	UserId int32 `json:"user_id"`
	// Action performed by the user
	Action ChatEventAction `json:"action"`
	// contains filtered or unexported fields
}

Represents a chat event

func UnmarshalChatEvent

func UnmarshalChatEvent(data json.RawMessage) (*ChatEvent, error)

func (*ChatEvent) GetClass

func (*ChatEvent) GetClass() string

func (*ChatEvent) GetType

func (*ChatEvent) GetType() string

func (*ChatEvent) MarshalJSON

func (entity *ChatEvent) MarshalJSON() ([]byte, error)

func (*ChatEvent) UnmarshalJSON

func (chatEvent *ChatEvent) UnmarshalJSON(data []byte) error

type ChatEventAction

type ChatEventAction interface {
	ChatEventActionType() string
}

Represents a chat event

func UnmarshalChatEventAction

func UnmarshalChatEventAction(data json.RawMessage) (ChatEventAction, error)

func UnmarshalListOfChatEventAction

func UnmarshalListOfChatEventAction(dataList []json.RawMessage) ([]ChatEventAction, error)

type ChatEventDescriptionChanged

type ChatEventDescriptionChanged struct {

	// Previous chat description
	OldDescription string `json:"old_description"`
	// New chat description
	NewDescription string `json:"new_description"`
	// contains filtered or unexported fields
}

The chat description was changed

func UnmarshalChatEventDescriptionChanged

func UnmarshalChatEventDescriptionChanged(data json.RawMessage) (*ChatEventDescriptionChanged, error)

func (*ChatEventDescriptionChanged) ChatEventActionType

func (*ChatEventDescriptionChanged) ChatEventActionType() string

func (*ChatEventDescriptionChanged) GetClass

func (*ChatEventDescriptionChanged) GetClass() string

func (*ChatEventDescriptionChanged) GetType

func (*ChatEventDescriptionChanged) MarshalJSON

func (entity *ChatEventDescriptionChanged) MarshalJSON() ([]byte, error)

type ChatEventInvitesToggled

type ChatEventInvitesToggled struct {

	// New value of can_invite_users permission
	CanInviteUsers bool `json:"can_invite_users"`
	// contains filtered or unexported fields
}

The can_invite_users permission of a supergroup chat was toggled

func UnmarshalChatEventInvitesToggled

func UnmarshalChatEventInvitesToggled(data json.RawMessage) (*ChatEventInvitesToggled, error)

func (*ChatEventInvitesToggled) ChatEventActionType

func (*ChatEventInvitesToggled) ChatEventActionType() string

func (*ChatEventInvitesToggled) GetClass

func (*ChatEventInvitesToggled) GetClass() string

func (*ChatEventInvitesToggled) GetType

func (*ChatEventInvitesToggled) GetType() string

func (*ChatEventInvitesToggled) MarshalJSON

func (entity *ChatEventInvitesToggled) MarshalJSON() ([]byte, error)

type ChatEventIsAllHistoryAvailableToggled

type ChatEventIsAllHistoryAvailableToggled struct {

	// New value of is_all_history_available
	IsAllHistoryAvailable bool `json:"is_all_history_available"`
	// contains filtered or unexported fields
}

The is_all_history_available setting of a supergroup was toggled

func UnmarshalChatEventIsAllHistoryAvailableToggled

func UnmarshalChatEventIsAllHistoryAvailableToggled(data json.RawMessage) (*ChatEventIsAllHistoryAvailableToggled, error)

func (*ChatEventIsAllHistoryAvailableToggled) ChatEventActionType

func (*ChatEventIsAllHistoryAvailableToggled) ChatEventActionType() string

func (*ChatEventIsAllHistoryAvailableToggled) GetClass

func (*ChatEventIsAllHistoryAvailableToggled) GetType

func (*ChatEventIsAllHistoryAvailableToggled) MarshalJSON

func (entity *ChatEventIsAllHistoryAvailableToggled) MarshalJSON() ([]byte, error)

type ChatEventLinkedChatChanged

type ChatEventLinkedChatChanged struct {

	// Previous supergroup linked chat identifier
	OldLinkedChatId int64 `json:"old_linked_chat_id"`
	// New supergroup linked chat identifier
	NewLinkedChatId int64 `json:"new_linked_chat_id"`
	// contains filtered or unexported fields
}

The linked chat of a supergroup was changed

func UnmarshalChatEventLinkedChatChanged

func UnmarshalChatEventLinkedChatChanged(data json.RawMessage) (*ChatEventLinkedChatChanged, error)

func (*ChatEventLinkedChatChanged) ChatEventActionType

func (*ChatEventLinkedChatChanged) ChatEventActionType() string

func (*ChatEventLinkedChatChanged) GetClass

func (*ChatEventLinkedChatChanged) GetClass() string

func (*ChatEventLinkedChatChanged) GetType

func (*ChatEventLinkedChatChanged) MarshalJSON

func (entity *ChatEventLinkedChatChanged) MarshalJSON() ([]byte, error)

type ChatEventLocationChanged

type ChatEventLocationChanged struct {

	// Previous location; may be null
	OldLocation *ChatLocation `json:"old_location"`
	// New location; may be null
	NewLocation *ChatLocation `json:"new_location"`
	// contains filtered or unexported fields
}

The supergroup location was changed

func UnmarshalChatEventLocationChanged

func UnmarshalChatEventLocationChanged(data json.RawMessage) (*ChatEventLocationChanged, error)

func (*ChatEventLocationChanged) ChatEventActionType

func (*ChatEventLocationChanged) ChatEventActionType() string

func (*ChatEventLocationChanged) GetClass

func (*ChatEventLocationChanged) GetClass() string

func (*ChatEventLocationChanged) GetType

func (*ChatEventLocationChanged) GetType() string

func (*ChatEventLocationChanged) MarshalJSON

func (entity *ChatEventLocationChanged) MarshalJSON() ([]byte, error)

type ChatEventLogFilters

type ChatEventLogFilters struct {

	// True, if message edits should be returned
	MessageEdits bool `json:"message_edits"`
	// True, if message deletions should be returned
	MessageDeletions bool `json:"message_deletions"`
	// True, if pin/unpin events should be returned
	MessagePins bool `json:"message_pins"`
	// True, if members joining events should be returned
	MemberJoins bool `json:"member_joins"`
	// True, if members leaving events should be returned
	MemberLeaves bool `json:"member_leaves"`
	// True, if invited member events should be returned
	MemberInvites bool `json:"member_invites"`
	// True, if member promotion/demotion events should be returned
	MemberPromotions bool `json:"member_promotions"`
	// True, if member restricted/unrestricted/banned/unbanned events should be returned
	MemberRestrictions bool `json:"member_restrictions"`
	// True, if changes in chat information should be returned
	InfoChanges bool `json:"info_changes"`
	// True, if changes in chat settings should be returned
	SettingChanges bool `json:"setting_changes"`
	// contains filtered or unexported fields
}

Represents a set of filters used to obtain a chat event log

func UnmarshalChatEventLogFilters

func UnmarshalChatEventLogFilters(data json.RawMessage) (*ChatEventLogFilters, error)

func (*ChatEventLogFilters) GetClass

func (*ChatEventLogFilters) GetClass() string

func (*ChatEventLogFilters) GetType

func (*ChatEventLogFilters) GetType() string

func (*ChatEventLogFilters) MarshalJSON

func (entity *ChatEventLogFilters) MarshalJSON() ([]byte, error)

type ChatEventMemberInvited

type ChatEventMemberInvited struct {

	// New member user identifier
	UserId int32 `json:"user_id"`
	// New member status
	Status ChatMemberStatus `json:"status"`
	// contains filtered or unexported fields
}

A new chat member was invited

func UnmarshalChatEventMemberInvited

func UnmarshalChatEventMemberInvited(data json.RawMessage) (*ChatEventMemberInvited, error)

func (*ChatEventMemberInvited) ChatEventActionType

func (*ChatEventMemberInvited) ChatEventActionType() string

func (*ChatEventMemberInvited) GetClass

func (*ChatEventMemberInvited) GetClass() string

func (*ChatEventMemberInvited) GetType

func (*ChatEventMemberInvited) GetType() string

func (*ChatEventMemberInvited) MarshalJSON

func (entity *ChatEventMemberInvited) MarshalJSON() ([]byte, error)

func (*ChatEventMemberInvited) UnmarshalJSON

func (chatEventMemberInvited *ChatEventMemberInvited) UnmarshalJSON(data []byte) error

type ChatEventMemberJoined

type ChatEventMemberJoined struct {
	// contains filtered or unexported fields
}

A new member joined the chat

func UnmarshalChatEventMemberJoined

func UnmarshalChatEventMemberJoined(data json.RawMessage) (*ChatEventMemberJoined, error)

func (*ChatEventMemberJoined) ChatEventActionType

func (*ChatEventMemberJoined) ChatEventActionType() string

func (*ChatEventMemberJoined) GetClass

func (*ChatEventMemberJoined) GetClass() string

func (*ChatEventMemberJoined) GetType

func (*ChatEventMemberJoined) GetType() string

func (*ChatEventMemberJoined) MarshalJSON

func (entity *ChatEventMemberJoined) MarshalJSON() ([]byte, error)

type ChatEventMemberLeft

type ChatEventMemberLeft struct {
	// contains filtered or unexported fields
}

A member left the chat

func UnmarshalChatEventMemberLeft

func UnmarshalChatEventMemberLeft(data json.RawMessage) (*ChatEventMemberLeft, error)

func (*ChatEventMemberLeft) ChatEventActionType

func (*ChatEventMemberLeft) ChatEventActionType() string

func (*ChatEventMemberLeft) GetClass

func (*ChatEventMemberLeft) GetClass() string

func (*ChatEventMemberLeft) GetType

func (*ChatEventMemberLeft) GetType() string

func (*ChatEventMemberLeft) MarshalJSON

func (entity *ChatEventMemberLeft) MarshalJSON() ([]byte, error)

type ChatEventMemberPromoted

type ChatEventMemberPromoted struct {

	// Chat member user identifier
	UserId int32 `json:"user_id"`
	// Previous status of the chat member
	OldStatus ChatMemberStatus `json:"old_status"`
	// New status of the chat member
	NewStatus ChatMemberStatus `json:"new_status"`
	// contains filtered or unexported fields
}

A chat member has gained/lost administrator status, or the list of their administrator privileges has changed

func UnmarshalChatEventMemberPromoted

func UnmarshalChatEventMemberPromoted(data json.RawMessage) (*ChatEventMemberPromoted, error)

func (*ChatEventMemberPromoted) ChatEventActionType

func (*ChatEventMemberPromoted) ChatEventActionType() string

func (*ChatEventMemberPromoted) GetClass

func (*ChatEventMemberPromoted) GetClass() string

func (*ChatEventMemberPromoted) GetType

func (*ChatEventMemberPromoted) GetType() string

func (*ChatEventMemberPromoted) MarshalJSON

func (entity *ChatEventMemberPromoted) MarshalJSON() ([]byte, error)

func (*ChatEventMemberPromoted) UnmarshalJSON

func (chatEventMemberPromoted *ChatEventMemberPromoted) UnmarshalJSON(data []byte) error

type ChatEventMemberRestricted

type ChatEventMemberRestricted struct {

	// Chat member user identifier
	UserId int32 `json:"user_id"`
	// Previous status of the chat member
	OldStatus ChatMemberStatus `json:"old_status"`
	// New status of the chat member
	NewStatus ChatMemberStatus `json:"new_status"`
	// contains filtered or unexported fields
}

A chat member was restricted/unrestricted or banned/unbanned, or the list of their restrictions has changed

func UnmarshalChatEventMemberRestricted

func UnmarshalChatEventMemberRestricted(data json.RawMessage) (*ChatEventMemberRestricted, error)

func (*ChatEventMemberRestricted) ChatEventActionType

func (*ChatEventMemberRestricted) ChatEventActionType() string

func (*ChatEventMemberRestricted) GetClass

func (*ChatEventMemberRestricted) GetClass() string

func (*ChatEventMemberRestricted) GetType

func (*ChatEventMemberRestricted) GetType() string

func (*ChatEventMemberRestricted) MarshalJSON

func (entity *ChatEventMemberRestricted) MarshalJSON() ([]byte, error)

func (*ChatEventMemberRestricted) UnmarshalJSON

func (chatEventMemberRestricted *ChatEventMemberRestricted) UnmarshalJSON(data []byte) error

type ChatEventMessageDeleted

type ChatEventMessageDeleted struct {

	// Deleted message
	Message *Message `json:"message"`
	// contains filtered or unexported fields
}

A message was deleted

func UnmarshalChatEventMessageDeleted

func UnmarshalChatEventMessageDeleted(data json.RawMessage) (*ChatEventMessageDeleted, error)

func (*ChatEventMessageDeleted) ChatEventActionType

func (*ChatEventMessageDeleted) ChatEventActionType() string

func (*ChatEventMessageDeleted) GetClass

func (*ChatEventMessageDeleted) GetClass() string

func (*ChatEventMessageDeleted) GetType

func (*ChatEventMessageDeleted) GetType() string

func (*ChatEventMessageDeleted) MarshalJSON

func (entity *ChatEventMessageDeleted) MarshalJSON() ([]byte, error)

type ChatEventMessageEdited

type ChatEventMessageEdited struct {

	// The original message before the edit
	OldMessage *Message `json:"old_message"`
	// The message after it was edited
	NewMessage *Message `json:"new_message"`
	// contains filtered or unexported fields
}

A message was edited

func UnmarshalChatEventMessageEdited

func UnmarshalChatEventMessageEdited(data json.RawMessage) (*ChatEventMessageEdited, error)

func (*ChatEventMessageEdited) ChatEventActionType

func (*ChatEventMessageEdited) ChatEventActionType() string

func (*ChatEventMessageEdited) GetClass

func (*ChatEventMessageEdited) GetClass() string

func (*ChatEventMessageEdited) GetType

func (*ChatEventMessageEdited) GetType() string

func (*ChatEventMessageEdited) MarshalJSON

func (entity *ChatEventMessageEdited) MarshalJSON() ([]byte, error)

type ChatEventMessagePinned

type ChatEventMessagePinned struct {

	// Pinned message
	Message *Message `json:"message"`
	// contains filtered or unexported fields
}

A message was pinned

func UnmarshalChatEventMessagePinned

func UnmarshalChatEventMessagePinned(data json.RawMessage) (*ChatEventMessagePinned, error)

func (*ChatEventMessagePinned) ChatEventActionType

func (*ChatEventMessagePinned) ChatEventActionType() string

func (*ChatEventMessagePinned) GetClass

func (*ChatEventMessagePinned) GetClass() string

func (*ChatEventMessagePinned) GetType

func (*ChatEventMessagePinned) GetType() string

func (*ChatEventMessagePinned) MarshalJSON

func (entity *ChatEventMessagePinned) MarshalJSON() ([]byte, error)

type ChatEventMessageUnpinned

type ChatEventMessageUnpinned struct {

	// Unpinned message
	Message *Message `json:"message"`
	// contains filtered or unexported fields
}

A message was unpinned

func UnmarshalChatEventMessageUnpinned

func UnmarshalChatEventMessageUnpinned(data json.RawMessage) (*ChatEventMessageUnpinned, error)

func (*ChatEventMessageUnpinned) ChatEventActionType

func (*ChatEventMessageUnpinned) ChatEventActionType() string

func (*ChatEventMessageUnpinned) GetClass

func (*ChatEventMessageUnpinned) GetClass() string

func (*ChatEventMessageUnpinned) GetType

func (*ChatEventMessageUnpinned) GetType() string

func (*ChatEventMessageUnpinned) MarshalJSON

func (entity *ChatEventMessageUnpinned) MarshalJSON() ([]byte, error)

type ChatEventPermissionsChanged

type ChatEventPermissionsChanged struct {

	// Previous chat permissions
	OldPermissions *ChatPermissions `json:"old_permissions"`
	// New chat permissions
	NewPermissions *ChatPermissions `json:"new_permissions"`
	// contains filtered or unexported fields
}

The chat permissions was changed

func UnmarshalChatEventPermissionsChanged

func UnmarshalChatEventPermissionsChanged(data json.RawMessage) (*ChatEventPermissionsChanged, error)

func (*ChatEventPermissionsChanged) ChatEventActionType

func (*ChatEventPermissionsChanged) ChatEventActionType() string

func (*ChatEventPermissionsChanged) GetClass

func (*ChatEventPermissionsChanged) GetClass() string

func (*ChatEventPermissionsChanged) GetType

func (*ChatEventPermissionsChanged) MarshalJSON

func (entity *ChatEventPermissionsChanged) MarshalJSON() ([]byte, error)

type ChatEventPhotoChanged

type ChatEventPhotoChanged struct {

	// Previous chat photo value; may be null
	OldPhoto *ChatPhoto `json:"old_photo"`
	// New chat photo value; may be null
	NewPhoto *ChatPhoto `json:"new_photo"`
	// contains filtered or unexported fields
}

The chat photo was changed

func UnmarshalChatEventPhotoChanged

func UnmarshalChatEventPhotoChanged(data json.RawMessage) (*ChatEventPhotoChanged, error)

func (*ChatEventPhotoChanged) ChatEventActionType

func (*ChatEventPhotoChanged) ChatEventActionType() string

func (*ChatEventPhotoChanged) GetClass

func (*ChatEventPhotoChanged) GetClass() string

func (*ChatEventPhotoChanged) GetType

func (*ChatEventPhotoChanged) GetType() string

func (*ChatEventPhotoChanged) MarshalJSON

func (entity *ChatEventPhotoChanged) MarshalJSON() ([]byte, error)

type ChatEventPollStopped

type ChatEventPollStopped struct {

	// The message with the poll
	Message *Message `json:"message"`
	// contains filtered or unexported fields
}

A poll in a message was stopped

func UnmarshalChatEventPollStopped

func UnmarshalChatEventPollStopped(data json.RawMessage) (*ChatEventPollStopped, error)

func (*ChatEventPollStopped) ChatEventActionType

func (*ChatEventPollStopped) ChatEventActionType() string

func (*ChatEventPollStopped) GetClass

func (*ChatEventPollStopped) GetClass() string

func (*ChatEventPollStopped) GetType

func (*ChatEventPollStopped) GetType() string

func (*ChatEventPollStopped) MarshalJSON

func (entity *ChatEventPollStopped) MarshalJSON() ([]byte, error)

type ChatEventSignMessagesToggled

type ChatEventSignMessagesToggled struct {

	// New value of sign_messages
	SignMessages bool `json:"sign_messages"`
	// contains filtered or unexported fields
}

The sign_messages setting of a channel was toggled

func UnmarshalChatEventSignMessagesToggled

func UnmarshalChatEventSignMessagesToggled(data json.RawMessage) (*ChatEventSignMessagesToggled, error)

func (*ChatEventSignMessagesToggled) ChatEventActionType

func (*ChatEventSignMessagesToggled) ChatEventActionType() string

func (*ChatEventSignMessagesToggled) GetClass

func (*ChatEventSignMessagesToggled) GetType

func (*ChatEventSignMessagesToggled) MarshalJSON

func (entity *ChatEventSignMessagesToggled) MarshalJSON() ([]byte, error)

type ChatEventSlowModeDelayChanged

type ChatEventSlowModeDelayChanged struct {

	// Previous value of slow_mode_delay
	OldSlowModeDelay int32 `json:"old_slow_mode_delay"`
	// New value of slow_mode_delay
	NewSlowModeDelay int32 `json:"new_slow_mode_delay"`
	// contains filtered or unexported fields
}

The slow_mode_delay setting of a supergroup was changed

func UnmarshalChatEventSlowModeDelayChanged

func UnmarshalChatEventSlowModeDelayChanged(data json.RawMessage) (*ChatEventSlowModeDelayChanged, error)

func (*ChatEventSlowModeDelayChanged) ChatEventActionType

func (*ChatEventSlowModeDelayChanged) ChatEventActionType() string

func (*ChatEventSlowModeDelayChanged) GetClass

func (*ChatEventSlowModeDelayChanged) GetType

func (*ChatEventSlowModeDelayChanged) MarshalJSON

func (entity *ChatEventSlowModeDelayChanged) MarshalJSON() ([]byte, error)

type ChatEventStickerSetChanged

type ChatEventStickerSetChanged struct {

	// Previous identifier of the chat sticker set; 0 if none
	OldStickerSetId JsonInt64 `json:"old_sticker_set_id"`
	// New identifier of the chat sticker set; 0 if none
	NewStickerSetId JsonInt64 `json:"new_sticker_set_id"`
	// contains filtered or unexported fields
}

The supergroup sticker set was changed

func UnmarshalChatEventStickerSetChanged

func UnmarshalChatEventStickerSetChanged(data json.RawMessage) (*ChatEventStickerSetChanged, error)

func (*ChatEventStickerSetChanged) ChatEventActionType

func (*ChatEventStickerSetChanged) ChatEventActionType() string

func (*ChatEventStickerSetChanged) GetClass

func (*ChatEventStickerSetChanged) GetClass() string

func (*ChatEventStickerSetChanged) GetType

func (*ChatEventStickerSetChanged) MarshalJSON

func (entity *ChatEventStickerSetChanged) MarshalJSON() ([]byte, error)

type ChatEventTitleChanged

type ChatEventTitleChanged struct {

	// Previous chat title
	OldTitle string `json:"old_title"`
	// New chat title
	NewTitle string `json:"new_title"`
	// contains filtered or unexported fields
}

The chat title was changed

func UnmarshalChatEventTitleChanged

func UnmarshalChatEventTitleChanged(data json.RawMessage) (*ChatEventTitleChanged, error)

func (*ChatEventTitleChanged) ChatEventActionType

func (*ChatEventTitleChanged) ChatEventActionType() string

func (*ChatEventTitleChanged) GetClass

func (*ChatEventTitleChanged) GetClass() string

func (*ChatEventTitleChanged) GetType

func (*ChatEventTitleChanged) GetType() string

func (*ChatEventTitleChanged) MarshalJSON

func (entity *ChatEventTitleChanged) MarshalJSON() ([]byte, error)

type ChatEventUsernameChanged

type ChatEventUsernameChanged struct {

	// Previous chat username
	OldUsername string `json:"old_username"`
	// New chat username
	NewUsername string `json:"new_username"`
	// contains filtered or unexported fields
}

The chat username was changed

func UnmarshalChatEventUsernameChanged

func UnmarshalChatEventUsernameChanged(data json.RawMessage) (*ChatEventUsernameChanged, error)

func (*ChatEventUsernameChanged) ChatEventActionType

func (*ChatEventUsernameChanged) ChatEventActionType() string

func (*ChatEventUsernameChanged) GetClass

func (*ChatEventUsernameChanged) GetClass() string

func (*ChatEventUsernameChanged) GetType

func (*ChatEventUsernameChanged) GetType() string

func (*ChatEventUsernameChanged) MarshalJSON

func (entity *ChatEventUsernameChanged) MarshalJSON() ([]byte, error)

type ChatEvents

type ChatEvents struct {

	// List of events
	Events []*ChatEvent `json:"events"`
	// contains filtered or unexported fields
}

Contains a list of chat events

func UnmarshalChatEvents

func UnmarshalChatEvents(data json.RawMessage) (*ChatEvents, error)

func (*ChatEvents) GetClass

func (*ChatEvents) GetClass() string

func (*ChatEvents) GetType

func (*ChatEvents) GetType() string

func (*ChatEvents) MarshalJSON

func (entity *ChatEvents) MarshalJSON() ([]byte, error)

type ChatFilter

type ChatFilter struct {

	// The title of the filter; 1-12 characters without line feeds
	Title string `json:"title"`
	// The icon name for short filter representation. If non-empty, must be one of "All", "Unread", "Unmuted", "Bots", "Channels", "Groups", "Private", "Custom", "Setup", "Cat", "Crown", "Favorite", "Flower", "Game", "Home", "Love", "Mask", "Party", "Sport", "Study", "Trade", "Travel", "Work". If empty, use getChatFilterDefaultIconName to get default icon name for the filter
	IconName string `json:"icon_name"`
	// The chat identifiers of pinned chats in the filtered chat list
	PinnedChatIds []int64 `json:"pinned_chat_ids"`
	// The chat identifiers of always included chats in the filtered chat list
	IncludedChatIds []int64 `json:"included_chat_ids"`
	// The chat identifiers of always excluded chats in the filtered chat list
	ExcludedChatIds []int64 `json:"excluded_chat_ids"`
	// True, if muted chats need to be excluded
	ExcludeMuted bool `json:"exclude_muted"`
	// True, if read chats need to be excluded
	ExcludeRead bool `json:"exclude_read"`
	// True, if archived chats need to be excluded
	ExcludeArchived bool `json:"exclude_archived"`
	// True, if contacts need to be included
	IncludeContacts bool `json:"include_contacts"`
	// True, if non-contact users need to be included
	IncludeNonContacts bool `json:"include_non_contacts"`
	// True, if bots need to be included
	IncludeBots bool `json:"include_bots"`
	// True, if basic groups and supergroups need to be included
	IncludeGroups bool `json:"include_groups"`
	// True, if channels need to be included
	IncludeChannels bool `json:"include_channels"`
	// contains filtered or unexported fields
}

Represents a filter of user chats

func UnmarshalChatFilter

func UnmarshalChatFilter(data json.RawMessage) (*ChatFilter, error)

func (*ChatFilter) GetClass

func (*ChatFilter) GetClass() string

func (*ChatFilter) GetType

func (*ChatFilter) GetType() string

func (*ChatFilter) MarshalJSON

func (entity *ChatFilter) MarshalJSON() ([]byte, error)

type ChatFilterInfo

type ChatFilterInfo struct {

	// Unique chat filter identifier
	Id int32 `json:"id"`
	// The title of the filter; 1-12 characters without line feeds
	Title string `json:"title"`
	// The icon name for short filter representation. One of "All", "Unread", "Unmuted", "Bots", "Channels", "Groups", "Private", "Custom", "Setup", "Cat", "Crown", "Favorite", "Flower", "Game", "Home", "Love", "Mask", "Party", "Sport", "Study", "Trade", "Travel", "Work"
	IconName string `json:"icon_name"`
	// contains filtered or unexported fields
}

Contains basic information about a chat filter

func UnmarshalChatFilterInfo

func UnmarshalChatFilterInfo(data json.RawMessage) (*ChatFilterInfo, error)

func (*ChatFilterInfo) GetClass

func (*ChatFilterInfo) GetClass() string

func (*ChatFilterInfo) GetType

func (*ChatFilterInfo) GetType() string

func (*ChatFilterInfo) MarshalJSON

func (entity *ChatFilterInfo) MarshalJSON() ([]byte, error)
type ChatInviteLink struct {

	// Chat invite link
	InviteLink string `json:"invite_link"`
	// contains filtered or unexported fields
}

Contains a chat invite link

func UnmarshalChatInviteLink(data json.RawMessage) (*ChatInviteLink, error)

func (*ChatInviteLink) GetClass

func (*ChatInviteLink) GetClass() string

func (*ChatInviteLink) GetType

func (*ChatInviteLink) GetType() string

func (*ChatInviteLink) MarshalJSON

func (entity *ChatInviteLink) MarshalJSON() ([]byte, error)

type ChatInviteLinkInfo

type ChatInviteLinkInfo struct {

	// Chat identifier of the invite link; 0 if the user has no access to the chat before joining
	ChatId int64 `json:"chat_id"`
	// If non-zero, the amount of time for which read access to the chat will remain available, in seconds
	AccessibleFor int32 `json:"accessible_for"`
	// Contains information about the type of the chat
	Type ChatType `json:"type"`
	// Title of the chat
	Title string `json:"title"`
	// Chat photo; may be null
	Photo *ChatPhotoInfo `json:"photo"`
	// Number of members in the chat
	MemberCount int32 `json:"member_count"`
	// User identifiers of some chat members that may be known to the current user
	MemberUserIds []int32 `json:"member_user_ids"`
	// True, if the chat is a public supergroup or channel, i.e. it has a username or it is a location-based supergroup
	IsPublic bool `json:"is_public"`
	// contains filtered or unexported fields
}

Contains information about a chat invite link

func UnmarshalChatInviteLinkInfo

func UnmarshalChatInviteLinkInfo(data json.RawMessage) (*ChatInviteLinkInfo, error)

func (*ChatInviteLinkInfo) GetClass

func (*ChatInviteLinkInfo) GetClass() string

func (*ChatInviteLinkInfo) GetType

func (*ChatInviteLinkInfo) GetType() string

func (*ChatInviteLinkInfo) MarshalJSON

func (entity *ChatInviteLinkInfo) MarshalJSON() ([]byte, error)

func (*ChatInviteLinkInfo) UnmarshalJSON

func (chatInviteLinkInfo *ChatInviteLinkInfo) UnmarshalJSON(data []byte) error

type ChatList

type ChatList interface {
	ChatListType() string
}

Describes a list of chats

func UnmarshalChatList

func UnmarshalChatList(data json.RawMessage) (ChatList, error)

func UnmarshalListOfChatList

func UnmarshalListOfChatList(dataList []json.RawMessage) ([]ChatList, error)

type ChatListArchive

type ChatListArchive struct {
	// contains filtered or unexported fields
}

A list of chats usually located at the top of the main chat list. Unmuted chats are automatically moved from the Archive to the Main chat list when a new message arrives

func UnmarshalChatListArchive

func UnmarshalChatListArchive(data json.RawMessage) (*ChatListArchive, error)

func (*ChatListArchive) ChatListType

func (*ChatListArchive) ChatListType() string

func (*ChatListArchive) GetClass

func (*ChatListArchive) GetClass() string

func (*ChatListArchive) GetType

func (*ChatListArchive) GetType() string

func (*ChatListArchive) MarshalJSON

func (entity *ChatListArchive) MarshalJSON() ([]byte, error)

type ChatListFilter

type ChatListFilter struct {

	// Chat filter identifier
	ChatFilterId int32 `json:"chat_filter_id"`
	// contains filtered or unexported fields
}

A list of chats belonging to a chat filter

func UnmarshalChatListFilter

func UnmarshalChatListFilter(data json.RawMessage) (*ChatListFilter, error)

func (*ChatListFilter) ChatListType

func (*ChatListFilter) ChatListType() string

func (*ChatListFilter) GetClass

func (*ChatListFilter) GetClass() string

func (*ChatListFilter) GetType

func (*ChatListFilter) GetType() string

func (*ChatListFilter) MarshalJSON

func (entity *ChatListFilter) MarshalJSON() ([]byte, error)

type ChatListMain

type ChatListMain struct {
	// contains filtered or unexported fields
}

A main list of chats

func UnmarshalChatListMain

func UnmarshalChatListMain(data json.RawMessage) (*ChatListMain, error)

func (*ChatListMain) ChatListType

func (*ChatListMain) ChatListType() string

func (*ChatListMain) GetClass

func (*ChatListMain) GetClass() string

func (*ChatListMain) GetType

func (*ChatListMain) GetType() string

func (*ChatListMain) MarshalJSON

func (entity *ChatListMain) MarshalJSON() ([]byte, error)

type ChatLists

type ChatLists struct {

	// List of chat lists
	ChatLists []ChatList `json:"chat_lists"`
	// contains filtered or unexported fields
}

Contains a list of chat lists

func UnmarshalChatLists

func UnmarshalChatLists(data json.RawMessage) (*ChatLists, error)

func (*ChatLists) GetClass

func (*ChatLists) GetClass() string

func (*ChatLists) GetType

func (*ChatLists) GetType() string

func (*ChatLists) MarshalJSON

func (entity *ChatLists) MarshalJSON() ([]byte, error)

func (*ChatLists) UnmarshalJSON

func (chatLists *ChatLists) UnmarshalJSON(data []byte) error

type ChatLocation

type ChatLocation struct {

	// The location
	Location *Location `json:"location"`
	// Location address; 1-64 characters, as defined by the chat owner
	Address string `json:"address"`
	// contains filtered or unexported fields
}

Represents a location to which a chat is connected

func UnmarshalChatLocation

func UnmarshalChatLocation(data json.RawMessage) (*ChatLocation, error)

func (*ChatLocation) GetClass

func (*ChatLocation) GetClass() string

func (*ChatLocation) GetType

func (*ChatLocation) GetType() string

func (*ChatLocation) MarshalJSON

func (entity *ChatLocation) MarshalJSON() ([]byte, error)

type ChatMember

type ChatMember struct {

	// User identifier of the chat member
	UserId int32 `json:"user_id"`
	// Identifier of a user that invited/promoted/banned this member in the chat; 0 if unknown
	InviterUserId int32 `json:"inviter_user_id"`
	// Point in time (Unix timestamp) when the user joined the chat
	JoinedChatDate int32 `json:"joined_chat_date"`
	// Status of the member in the chat
	Status ChatMemberStatus `json:"status"`
	// If the user is a bot, information about the bot; may be null. Can be null even for a bot if the bot is not the chat member
	BotInfo *BotInfo `json:"bot_info"`
	// contains filtered or unexported fields
}

A user with information about joining/leaving a chat

func UnmarshalChatMember

func UnmarshalChatMember(data json.RawMessage) (*ChatMember, error)

func (*ChatMember) GetClass

func (*ChatMember) GetClass() string

func (*ChatMember) GetType

func (*ChatMember) GetType() string

func (*ChatMember) MarshalJSON

func (entity *ChatMember) MarshalJSON() ([]byte, error)

func (*ChatMember) UnmarshalJSON

func (chatMember *ChatMember) UnmarshalJSON(data []byte) error

type ChatMemberStatus

type ChatMemberStatus interface {
	ChatMemberStatusType() string
}

Provides information about the status of a member in a chat

func UnmarshalChatMemberStatus

func UnmarshalChatMemberStatus(data json.RawMessage) (ChatMemberStatus, error)

func UnmarshalListOfChatMemberStatus

func UnmarshalListOfChatMemberStatus(dataList []json.RawMessage) ([]ChatMemberStatus, error)

type ChatMemberStatusAdministrator

type ChatMemberStatusAdministrator struct {

	// A custom title of the administrator; 0-16 characters without emojis; applicable to supergroups only
	CustomTitle string `json:"custom_title"`
	// True, if the current user can edit the administrator privileges for the called user
	CanBeEdited bool `json:"can_be_edited"`
	// True, if the administrator can change the chat title, photo, and other settings
	CanChangeInfo bool `json:"can_change_info"`
	// True, if the administrator can create channel posts; applicable to channels only
	CanPostMessages bool `json:"can_post_messages"`
	// True, if the administrator can edit messages of other users and pin messages; applicable to channels only
	CanEditMessages bool `json:"can_edit_messages"`
	// True, if the administrator can delete messages of other users
	CanDeleteMessages bool `json:"can_delete_messages"`
	// True, if the administrator can invite new users to the chat
	CanInviteUsers bool `json:"can_invite_users"`
	// True, if the administrator can restrict, ban, or unban chat members
	CanRestrictMembers bool `json:"can_restrict_members"`
	// True, if the administrator can pin messages; applicable to groups only
	CanPinMessages bool `json:"can_pin_messages"`
	// True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that were directly or indirectly promoted by them
	CanPromoteMembers bool `json:"can_promote_members"`
	// True, if the administrator isn't shown in the chat member list and sends messages anonymously; applicable to supergroups only
	IsAnonymous bool `json:"is_anonymous"`
	// contains filtered or unexported fields
}

The user is a member of a chat and has some additional privileges. In basic groups, administrators can edit and delete messages sent by others, add new members, and ban unprivileged members. In supergroups and channels, there are more detailed options for administrator privileges

func UnmarshalChatMemberStatusAdministrator

func UnmarshalChatMemberStatusAdministrator(data json.RawMessage) (*ChatMemberStatusAdministrator, error)

func (*ChatMemberStatusAdministrator) ChatMemberStatusType

func (*ChatMemberStatusAdministrator) ChatMemberStatusType() string

func (*ChatMemberStatusAdministrator) GetClass

func (*ChatMemberStatusAdministrator) GetType

func (*ChatMemberStatusAdministrator) MarshalJSON

func (entity *ChatMemberStatusAdministrator) MarshalJSON() ([]byte, error)

type ChatMemberStatusBanned

type ChatMemberStatusBanned struct {

	// Point in time (Unix timestamp) when the user will be unbanned; 0 if never. If the user is banned for more than 366 days or for less than 30 seconds from the current time, the user is considered to be banned forever
	BannedUntilDate int32 `json:"banned_until_date"`
	// contains filtered or unexported fields
}

The user was banned (and hence is not a member of the chat). Implies the user can't return to the chat or view messages

func UnmarshalChatMemberStatusBanned

func UnmarshalChatMemberStatusBanned(data json.RawMessage) (*ChatMemberStatusBanned, error)

func (*ChatMemberStatusBanned) ChatMemberStatusType

func (*ChatMemberStatusBanned) ChatMemberStatusType() string

func (*ChatMemberStatusBanned) GetClass

func (*ChatMemberStatusBanned) GetClass() string

func (*ChatMemberStatusBanned) GetType

func (*ChatMemberStatusBanned) GetType() string

func (*ChatMemberStatusBanned) MarshalJSON

func (entity *ChatMemberStatusBanned) MarshalJSON() ([]byte, error)

type ChatMemberStatusCreator

type ChatMemberStatusCreator struct {

	// A custom title of the owner; 0-16 characters without emojis; applicable to supergroups only
	CustomTitle string `json:"custom_title"`
	// True, if the creator isn't shown in the chat member list and sends messages anonymously; applicable to supergroups only
	IsAnonymous bool `json:"is_anonymous"`
	// True, if the user is a member of the chat
	IsMember bool `json:"is_member"`
	// contains filtered or unexported fields
}

The user is the owner of a chat and has all the administrator privileges

func UnmarshalChatMemberStatusCreator

func UnmarshalChatMemberStatusCreator(data json.RawMessage) (*ChatMemberStatusCreator, error)

func (*ChatMemberStatusCreator) ChatMemberStatusType

func (*ChatMemberStatusCreator) ChatMemberStatusType() string

func (*ChatMemberStatusCreator) GetClass

func (*ChatMemberStatusCreator) GetClass() string

func (*ChatMemberStatusCreator) GetType

func (*ChatMemberStatusCreator) GetType() string

func (*ChatMemberStatusCreator) MarshalJSON

func (entity *ChatMemberStatusCreator) MarshalJSON() ([]byte, error)

type ChatMemberStatusLeft

type ChatMemberStatusLeft struct {
	// contains filtered or unexported fields
}

The user is not a chat member

func UnmarshalChatMemberStatusLeft

func UnmarshalChatMemberStatusLeft(data json.RawMessage) (*ChatMemberStatusLeft, error)

func (*ChatMemberStatusLeft) ChatMemberStatusType

func (*ChatMemberStatusLeft) ChatMemberStatusType() string

func (*ChatMemberStatusLeft) GetClass

func (*ChatMemberStatusLeft) GetClass() string

func (*ChatMemberStatusLeft) GetType

func (*ChatMemberStatusLeft) GetType() string

func (*ChatMemberStatusLeft) MarshalJSON

func (entity *ChatMemberStatusLeft) MarshalJSON() ([]byte, error)

type ChatMemberStatusMember

type ChatMemberStatusMember struct {
	// contains filtered or unexported fields
}

The user is a member of a chat, without any additional privileges or restrictions

func UnmarshalChatMemberStatusMember

func UnmarshalChatMemberStatusMember(data json.RawMessage) (*ChatMemberStatusMember, error)

func (*ChatMemberStatusMember) ChatMemberStatusType

func (*ChatMemberStatusMember) ChatMemberStatusType() string

func (*ChatMemberStatusMember) GetClass

func (*ChatMemberStatusMember) GetClass() string

func (*ChatMemberStatusMember) GetType

func (*ChatMemberStatusMember) GetType() string

func (*ChatMemberStatusMember) MarshalJSON

func (entity *ChatMemberStatusMember) MarshalJSON() ([]byte, error)

type ChatMemberStatusRestricted

type ChatMemberStatusRestricted struct {

	// True, if the user is a member of the chat
	IsMember bool `json:"is_member"`
	// Point in time (Unix timestamp) when restrictions will be lifted from the user; 0 if never. If the user is restricted for more than 366 days or for less than 30 seconds from the current time, the user is considered to be restricted forever
	RestrictedUntilDate int32 `json:"restricted_until_date"`
	// User permissions in the chat
	Permissions *ChatPermissions `json:"permissions"`
	// contains filtered or unexported fields
}

The user is under certain restrictions in the chat. Not supported in basic groups and channels

func UnmarshalChatMemberStatusRestricted

func UnmarshalChatMemberStatusRestricted(data json.RawMessage) (*ChatMemberStatusRestricted, error)

func (*ChatMemberStatusRestricted) ChatMemberStatusType

func (*ChatMemberStatusRestricted) ChatMemberStatusType() string

func (*ChatMemberStatusRestricted) GetClass

func (*ChatMemberStatusRestricted) GetClass() string

func (*ChatMemberStatusRestricted) GetType

func (*ChatMemberStatusRestricted) MarshalJSON

func (entity *ChatMemberStatusRestricted) MarshalJSON() ([]byte, error)

type ChatMembers

type ChatMembers struct {

	// Approximate total count of chat members found
	TotalCount int32 `json:"total_count"`
	// A list of chat members
	Members []*ChatMember `json:"members"`
	// contains filtered or unexported fields
}

Contains a list of chat members

func UnmarshalChatMembers

func UnmarshalChatMembers(data json.RawMessage) (*ChatMembers, error)

func (*ChatMembers) GetClass

func (*ChatMembers) GetClass() string

func (*ChatMembers) GetType

func (*ChatMembers) GetType() string

func (*ChatMembers) MarshalJSON

func (entity *ChatMembers) MarshalJSON() ([]byte, error)

type ChatMembersFilter

type ChatMembersFilter interface {
	ChatMembersFilterType() string
}

Specifies the kind of chat members to return in searchChatMembers

func UnmarshalChatMembersFilter

func UnmarshalChatMembersFilter(data json.RawMessage) (ChatMembersFilter, error)

func UnmarshalListOfChatMembersFilter

func UnmarshalListOfChatMembersFilter(dataList []json.RawMessage) ([]ChatMembersFilter, error)

type ChatMembersFilterAdministrators

type ChatMembersFilterAdministrators struct {
	// contains filtered or unexported fields
}

Returns the owner and administrators

func UnmarshalChatMembersFilterAdministrators

func UnmarshalChatMembersFilterAdministrators(data json.RawMessage) (*ChatMembersFilterAdministrators, error)

func (*ChatMembersFilterAdministrators) ChatMembersFilterType

func (*ChatMembersFilterAdministrators) ChatMembersFilterType() string

func (*ChatMembersFilterAdministrators) GetClass

func (*ChatMembersFilterAdministrators) GetType

func (*ChatMembersFilterAdministrators) MarshalJSON

func (entity *ChatMembersFilterAdministrators) MarshalJSON() ([]byte, error)

type ChatMembersFilterBanned

type ChatMembersFilterBanned struct {
	// contains filtered or unexported fields
}

Returns users banned from the chat; can be used only by administrators in a supergroup or in a channel

func UnmarshalChatMembersFilterBanned

func UnmarshalChatMembersFilterBanned(data json.RawMessage) (*ChatMembersFilterBanned, error)

func (*ChatMembersFilterBanned) ChatMembersFilterType

func (*ChatMembersFilterBanned) ChatMembersFilterType() string

func (*ChatMembersFilterBanned) GetClass

func (*ChatMembersFilterBanned) GetClass() string

func (*ChatMembersFilterBanned) GetType

func (*ChatMembersFilterBanned) GetType() string

func (*ChatMembersFilterBanned) MarshalJSON

func (entity *ChatMembersFilterBanned) MarshalJSON() ([]byte, error)

type ChatMembersFilterBots

type ChatMembersFilterBots struct {
	// contains filtered or unexported fields
}

Returns bot members of the chat

func UnmarshalChatMembersFilterBots

func UnmarshalChatMembersFilterBots(data json.RawMessage) (*ChatMembersFilterBots, error)

func (*ChatMembersFilterBots) ChatMembersFilterType

func (*ChatMembersFilterBots) ChatMembersFilterType() string

func (*ChatMembersFilterBots) GetClass

func (*ChatMembersFilterBots) GetClass() string

func (*ChatMembersFilterBots) GetType

func (*ChatMembersFilterBots) GetType() string

func (*ChatMembersFilterBots) MarshalJSON

func (entity *ChatMembersFilterBots) MarshalJSON() ([]byte, error)

type ChatMembersFilterContacts

type ChatMembersFilterContacts struct {
	// contains filtered or unexported fields
}

Returns contacts of the user

func UnmarshalChatMembersFilterContacts

func UnmarshalChatMembersFilterContacts(data json.RawMessage) (*ChatMembersFilterContacts, error)

func (*ChatMembersFilterContacts) ChatMembersFilterType

func (*ChatMembersFilterContacts) ChatMembersFilterType() string

func (*ChatMembersFilterContacts) GetClass

func (*ChatMembersFilterContacts) GetClass() string

func (*ChatMembersFilterContacts) GetType

func (*ChatMembersFilterContacts) GetType() string

func (*ChatMembersFilterContacts) MarshalJSON

func (entity *ChatMembersFilterContacts) MarshalJSON() ([]byte, error)

type ChatMembersFilterMembers

type ChatMembersFilterMembers struct {
	// contains filtered or unexported fields
}

Returns all chat members, including restricted chat members

func UnmarshalChatMembersFilterMembers

func UnmarshalChatMembersFilterMembers(data json.RawMessage) (*ChatMembersFilterMembers, error)

func (*ChatMembersFilterMembers) ChatMembersFilterType

func (*ChatMembersFilterMembers) ChatMembersFilterType() string

func (*ChatMembersFilterMembers) GetClass

func (*ChatMembersFilterMembers) GetClass() string

func (*ChatMembersFilterMembers) GetType

func (*ChatMembersFilterMembers) GetType() string

func (*ChatMembersFilterMembers) MarshalJSON

func (entity *ChatMembersFilterMembers) MarshalJSON() ([]byte, error)

type ChatMembersFilterMention

type ChatMembersFilterMention struct {

	// If non-zero, the identifier of the current message thread
	MessageThreadId int64 `json:"message_thread_id"`
	// contains filtered or unexported fields
}

Returns users which can be mentioned in the chat

func UnmarshalChatMembersFilterMention

func UnmarshalChatMembersFilterMention(data json.RawMessage) (*ChatMembersFilterMention, error)

func (*ChatMembersFilterMention) ChatMembersFilterType

func (*ChatMembersFilterMention) ChatMembersFilterType() string

func (*ChatMembersFilterMention) GetClass

func (*ChatMembersFilterMention) GetClass() string

func (*ChatMembersFilterMention) GetType

func (*ChatMembersFilterMention) GetType() string

func (*ChatMembersFilterMention) MarshalJSON

func (entity *ChatMembersFilterMention) MarshalJSON() ([]byte, error)

type ChatMembersFilterRestricted

type ChatMembersFilterRestricted struct {
	// contains filtered or unexported fields
}

Returns users under certain restrictions in the chat; can be used only by administrators in a supergroup

func UnmarshalChatMembersFilterRestricted

func UnmarshalChatMembersFilterRestricted(data json.RawMessage) (*ChatMembersFilterRestricted, error)

func (*ChatMembersFilterRestricted) ChatMembersFilterType

func (*ChatMembersFilterRestricted) ChatMembersFilterType() string

func (*ChatMembersFilterRestricted) GetClass

func (*ChatMembersFilterRestricted) GetClass() string

func (*ChatMembersFilterRestricted) GetType

func (*ChatMembersFilterRestricted) MarshalJSON

func (entity *ChatMembersFilterRestricted) MarshalJSON() ([]byte, error)

type ChatNearby

type ChatNearby struct {

	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Distance to the chat location, in meters
	Distance int32 `json:"distance"`
	// contains filtered or unexported fields
}

Describes a chat located nearby

func UnmarshalChatNearby

func UnmarshalChatNearby(data json.RawMessage) (*ChatNearby, error)

func (*ChatNearby) GetClass

func (*ChatNearby) GetClass() string

func (*ChatNearby) GetType

func (*ChatNearby) GetType() string

func (*ChatNearby) MarshalJSON

func (entity *ChatNearby) MarshalJSON() ([]byte, error)

type ChatNotificationSettings

type ChatNotificationSettings struct {

	// If true, mute_for is ignored and the value for the relevant type of chat is used instead
	UseDefaultMuteFor bool `json:"use_default_mute_for"`
	// Time left before notifications will be unmuted, in seconds
	MuteFor int32 `json:"mute_for"`
	// If true, sound is ignored and the value for the relevant type of chat is used instead
	UseDefaultSound bool `json:"use_default_sound"`
	// The name of an audio file to be used for notification sounds; only applies to iOS applications
	Sound string `json:"sound"`
	// If true, show_preview is ignored and the value for the relevant type of chat is used instead
	UseDefaultShowPreview bool `json:"use_default_show_preview"`
	// True, if message content should be displayed in notifications
	ShowPreview bool `json:"show_preview"`
	// If true, disable_pinned_message_notifications is ignored and the value for the relevant type of chat is used instead
	UseDefaultDisablePinnedMessageNotifications bool `json:"use_default_disable_pinned_message_notifications"`
	// If true, notifications for incoming pinned messages will be created as for an ordinary unread message
	DisablePinnedMessageNotifications bool `json:"disable_pinned_message_notifications"`
	// If true, disable_mention_notifications is ignored and the value for the relevant type of chat is used instead
	UseDefaultDisableMentionNotifications bool `json:"use_default_disable_mention_notifications"`
	// If true, notifications for messages with mentions will be created as for an ordinary unread message
	DisableMentionNotifications bool `json:"disable_mention_notifications"`
	// contains filtered or unexported fields
}

Contains information about notification settings for a chat

func UnmarshalChatNotificationSettings

func UnmarshalChatNotificationSettings(data json.RawMessage) (*ChatNotificationSettings, error)

func (*ChatNotificationSettings) GetClass

func (*ChatNotificationSettings) GetClass() string

func (*ChatNotificationSettings) GetType

func (*ChatNotificationSettings) GetType() string

func (*ChatNotificationSettings) MarshalJSON

func (entity *ChatNotificationSettings) MarshalJSON() ([]byte, error)

type ChatPermissions

type ChatPermissions struct {

	// True, if the user can send text messages, contacts, locations, and venues
	CanSendMessages bool `json:"can_send_messages"`
	// True, if the user can send audio files, documents, photos, videos, video notes, and voice notes. Implies can_send_messages permissions
	CanSendMediaMessages bool `json:"can_send_media_messages"`
	// True, if the user can send polls. Implies can_send_messages permissions
	CanSendPolls bool `json:"can_send_polls"`
	// True, if the user can send animations, games, stickers, and dice and use inline bots. Implies can_send_messages permissions
	CanSendOtherMessages bool `json:"can_send_other_messages"`
	// True, if the user may add a web page preview to their messages. Implies can_send_messages permissions
	CanAddWebPagePreviews bool `json:"can_add_web_page_previews"`
	// True, if the user can change the chat title, photo, and other settings
	CanChangeInfo bool `json:"can_change_info"`
	// True, if the user can invite new users to the chat
	CanInviteUsers bool `json:"can_invite_users"`
	// True, if the user can pin messages
	CanPinMessages bool `json:"can_pin_messages"`
	// contains filtered or unexported fields
}

Describes actions that a user is allowed to take in a chat

func UnmarshalChatPermissions

func UnmarshalChatPermissions(data json.RawMessage) (*ChatPermissions, error)

func (*ChatPermissions) GetClass

func (*ChatPermissions) GetClass() string

func (*ChatPermissions) GetType

func (*ChatPermissions) GetType() string

func (*ChatPermissions) MarshalJSON

func (entity *ChatPermissions) MarshalJSON() ([]byte, error)

type ChatPhoto

type ChatPhoto struct {

	// Unique photo identifier
	Id JsonInt64 `json:"id"`
	// Point in time (Unix timestamp) when the photo has been added
	AddedDate int32 `json:"added_date"`
	// Photo minithumbnail; may be null
	Minithumbnail *Minithumbnail `json:"minithumbnail"`
	// Available variants of the photo in JPEG format, in different size
	Sizes []*PhotoSize `json:"sizes"`
	// Animated variant of the photo in MPEG4 format; may be null
	Animation *AnimatedChatPhoto `json:"animation"`
	// contains filtered or unexported fields
}

Describes a chat or user profile photo

func UnmarshalChatPhoto

func UnmarshalChatPhoto(data json.RawMessage) (*ChatPhoto, error)

func (*ChatPhoto) GetClass

func (*ChatPhoto) GetClass() string

func (*ChatPhoto) GetType

func (*ChatPhoto) GetType() string

func (*ChatPhoto) MarshalJSON

func (entity *ChatPhoto) MarshalJSON() ([]byte, error)

type ChatPhotoInfo

type ChatPhotoInfo struct {

	// A small (160x160) chat photo variant in JPEG format. The file can be downloaded only before the photo is changed
	Small *File `json:"small"`
	// A big (640x640) chat photo variant in JPEG format. The file can be downloaded only before the photo is changed
	Big *File `json:"big"`
	// True, if the photo has animated variant
	HasAnimation bool `json:"has_animation"`
	// contains filtered or unexported fields
}

Contains basic information about the photo of a chat

func UnmarshalChatPhotoInfo

func UnmarshalChatPhotoInfo(data json.RawMessage) (*ChatPhotoInfo, error)

func (*ChatPhotoInfo) GetClass

func (*ChatPhotoInfo) GetClass() string

func (*ChatPhotoInfo) GetType

func (*ChatPhotoInfo) GetType() string

func (*ChatPhotoInfo) MarshalJSON

func (entity *ChatPhotoInfo) MarshalJSON() ([]byte, error)

type ChatPhotos

type ChatPhotos struct {

	// Total number of photos
	TotalCount int32 `json:"total_count"`
	// List of photos
	Photos []*ChatPhoto `json:"photos"`
	// contains filtered or unexported fields
}

Contains a list of chat or user profile photos

func UnmarshalChatPhotos

func UnmarshalChatPhotos(data json.RawMessage) (*ChatPhotos, error)

func (*ChatPhotos) GetClass

func (*ChatPhotos) GetClass() string

func (*ChatPhotos) GetType

func (*ChatPhotos) GetType() string

func (*ChatPhotos) MarshalJSON

func (entity *ChatPhotos) MarshalJSON() ([]byte, error)

type ChatPosition

type ChatPosition struct {

	// The chat list
	List ChatList `json:"list"`
	// A parameter used to determine order of the chat in the chat list. Chats must be sorted by the pair (order, chat.id) in descending order
	Order JsonInt64 `json:"order"`
	// True, if the chat is pinned in the chat list
	IsPinned bool `json:"is_pinned"`
	// Source of the chat in the chat list; may be null
	Source ChatSource `json:"source"`
	// contains filtered or unexported fields
}

Describes a position of a chat in a chat list

func UnmarshalChatPosition

func UnmarshalChatPosition(data json.RawMessage) (*ChatPosition, error)

func (*ChatPosition) GetClass

func (*ChatPosition) GetClass() string

func (*ChatPosition) GetType

func (*ChatPosition) GetType() string

func (*ChatPosition) MarshalJSON

func (entity *ChatPosition) MarshalJSON() ([]byte, error)

func (*ChatPosition) UnmarshalJSON

func (chatPosition *ChatPosition) UnmarshalJSON(data []byte) error

type ChatReportReason

type ChatReportReason interface {
	ChatReportReasonType() string
}

Describes the reason why a chat is reported

func UnmarshalChatReportReason

func UnmarshalChatReportReason(data json.RawMessage) (ChatReportReason, error)

func UnmarshalListOfChatReportReason

func UnmarshalListOfChatReportReason(dataList []json.RawMessage) ([]ChatReportReason, error)

type ChatReportReasonChildAbuse

type ChatReportReasonChildAbuse struct {
	// contains filtered or unexported fields
}

The chat has child abuse related content

func UnmarshalChatReportReasonChildAbuse

func UnmarshalChatReportReasonChildAbuse(data json.RawMessage) (*ChatReportReasonChildAbuse, error)

func (*ChatReportReasonChildAbuse) ChatReportReasonType

func (*ChatReportReasonChildAbuse) ChatReportReasonType() string

func (*ChatReportReasonChildAbuse) GetClass

func (*ChatReportReasonChildAbuse) GetClass() string

func (*ChatReportReasonChildAbuse) GetType

func (*ChatReportReasonChildAbuse) MarshalJSON

func (entity *ChatReportReasonChildAbuse) MarshalJSON() ([]byte, error)

type ChatReportReasonCopyright

type ChatReportReasonCopyright struct {
	// contains filtered or unexported fields
}

The chat contains copyrighted content

func UnmarshalChatReportReasonCopyright

func UnmarshalChatReportReasonCopyright(data json.RawMessage) (*ChatReportReasonCopyright, error)

func (*ChatReportReasonCopyright) ChatReportReasonType

func (*ChatReportReasonCopyright) ChatReportReasonType() string

func (*ChatReportReasonCopyright) GetClass

func (*ChatReportReasonCopyright) GetClass() string

func (*ChatReportReasonCopyright) GetType

func (*ChatReportReasonCopyright) GetType() string

func (*ChatReportReasonCopyright) MarshalJSON

func (entity *ChatReportReasonCopyright) MarshalJSON() ([]byte, error)

type ChatReportReasonCustom

type ChatReportReasonCustom struct {

	// Report text
	Text string `json:"text"`
	// contains filtered or unexported fields
}

A custom reason provided by the user

func UnmarshalChatReportReasonCustom

func UnmarshalChatReportReasonCustom(data json.RawMessage) (*ChatReportReasonCustom, error)

func (*ChatReportReasonCustom) ChatReportReasonType

func (*ChatReportReasonCustom) ChatReportReasonType() string

func (*ChatReportReasonCustom) GetClass

func (*ChatReportReasonCustom) GetClass() string

func (*ChatReportReasonCustom) GetType

func (*ChatReportReasonCustom) GetType() string

func (*ChatReportReasonCustom) MarshalJSON

func (entity *ChatReportReasonCustom) MarshalJSON() ([]byte, error)

type ChatReportReasonPornography

type ChatReportReasonPornography struct {
	// contains filtered or unexported fields
}

The chat contains pornographic messages

func UnmarshalChatReportReasonPornography

func UnmarshalChatReportReasonPornography(data json.RawMessage) (*ChatReportReasonPornography, error)

func (*ChatReportReasonPornography) ChatReportReasonType

func (*ChatReportReasonPornography) ChatReportReasonType() string

func (*ChatReportReasonPornography) GetClass

func (*ChatReportReasonPornography) GetClass() string

func (*ChatReportReasonPornography) GetType

func (*ChatReportReasonPornography) MarshalJSON

func (entity *ChatReportReasonPornography) MarshalJSON() ([]byte, error)

type ChatReportReasonSpam

type ChatReportReasonSpam struct {
	// contains filtered or unexported fields
}

The chat contains spam messages

func UnmarshalChatReportReasonSpam

func UnmarshalChatReportReasonSpam(data json.RawMessage) (*ChatReportReasonSpam, error)

func (*ChatReportReasonSpam) ChatReportReasonType

func (*ChatReportReasonSpam) ChatReportReasonType() string

func (*ChatReportReasonSpam) GetClass

func (*ChatReportReasonSpam) GetClass() string

func (*ChatReportReasonSpam) GetType

func (*ChatReportReasonSpam) GetType() string

func (*ChatReportReasonSpam) MarshalJSON

func (entity *ChatReportReasonSpam) MarshalJSON() ([]byte, error)

type ChatReportReasonUnrelatedLocation

type ChatReportReasonUnrelatedLocation struct {
	// contains filtered or unexported fields
}

The location-based chat is unrelated to its stated location

func UnmarshalChatReportReasonUnrelatedLocation

func UnmarshalChatReportReasonUnrelatedLocation(data json.RawMessage) (*ChatReportReasonUnrelatedLocation, error)

func (*ChatReportReasonUnrelatedLocation) ChatReportReasonType

func (*ChatReportReasonUnrelatedLocation) ChatReportReasonType() string

func (*ChatReportReasonUnrelatedLocation) GetClass

func (*ChatReportReasonUnrelatedLocation) GetType

func (*ChatReportReasonUnrelatedLocation) MarshalJSON

func (entity *ChatReportReasonUnrelatedLocation) MarshalJSON() ([]byte, error)

type ChatReportReasonViolence

type ChatReportReasonViolence struct {
	// contains filtered or unexported fields
}

The chat promotes violence

func UnmarshalChatReportReasonViolence

func UnmarshalChatReportReasonViolence(data json.RawMessage) (*ChatReportReasonViolence, error)

func (*ChatReportReasonViolence) ChatReportReasonType

func (*ChatReportReasonViolence) ChatReportReasonType() string

func (*ChatReportReasonViolence) GetClass

func (*ChatReportReasonViolence) GetClass() string

func (*ChatReportReasonViolence) GetType

func (*ChatReportReasonViolence) GetType() string

func (*ChatReportReasonViolence) MarshalJSON

func (entity *ChatReportReasonViolence) MarshalJSON() ([]byte, error)

type ChatSource

type ChatSource interface {
	ChatSourceType() string
}

Describes a reason why an external chat is shown in a chat list

func UnmarshalChatSource

func UnmarshalChatSource(data json.RawMessage) (ChatSource, error)

func UnmarshalListOfChatSource

func UnmarshalListOfChatSource(dataList []json.RawMessage) ([]ChatSource, error)

type ChatSourceMtprotoProxy

type ChatSourceMtprotoProxy struct {
	// contains filtered or unexported fields
}

The chat is sponsored by the user's MTProxy server

func UnmarshalChatSourceMtprotoProxy

func UnmarshalChatSourceMtprotoProxy(data json.RawMessage) (*ChatSourceMtprotoProxy, error)

func (*ChatSourceMtprotoProxy) ChatSourceType

func (*ChatSourceMtprotoProxy) ChatSourceType() string

func (*ChatSourceMtprotoProxy) GetClass

func (*ChatSourceMtprotoProxy) GetClass() string

func (*ChatSourceMtprotoProxy) GetType

func (*ChatSourceMtprotoProxy) GetType() string

func (*ChatSourceMtprotoProxy) MarshalJSON

func (entity *ChatSourceMtprotoProxy) MarshalJSON() ([]byte, error)

type ChatSourcePublicServiceAnnouncement

type ChatSourcePublicServiceAnnouncement struct {

	// The type of the announcement
	Type string `json:"type"`
	// The text of the announcement
	Text string `json:"text"`
	// contains filtered or unexported fields
}

The chat contains a public service announcement

func UnmarshalChatSourcePublicServiceAnnouncement

func UnmarshalChatSourcePublicServiceAnnouncement(data json.RawMessage) (*ChatSourcePublicServiceAnnouncement, error)

func (*ChatSourcePublicServiceAnnouncement) ChatSourceType

func (*ChatSourcePublicServiceAnnouncement) ChatSourceType() string

func (*ChatSourcePublicServiceAnnouncement) GetClass

func (*ChatSourcePublicServiceAnnouncement) GetType

func (*ChatSourcePublicServiceAnnouncement) MarshalJSON

func (entity *ChatSourcePublicServiceAnnouncement) MarshalJSON() ([]byte, error)

type ChatStatistics

type ChatStatistics interface {
	ChatStatisticsType() string
}

Contains a detailed statistics about a chat

func UnmarshalChatStatistics

func UnmarshalChatStatistics(data json.RawMessage) (ChatStatistics, error)

func UnmarshalListOfChatStatistics

func UnmarshalListOfChatStatistics(dataList []json.RawMessage) ([]ChatStatistics, error)

type ChatStatisticsAdministratorActionsInfo

type ChatStatisticsAdministratorActionsInfo struct {

	// Administrator user identifier
	UserId int32 `json:"user_id"`
	// Number of messages deleted by the administrator
	DeletedMessageCount int32 `json:"deleted_message_count"`
	// Number of users banned by the administrator
	BannedUserCount int32 `json:"banned_user_count"`
	// Number of users restricted by the administrator
	RestrictedUserCount int32 `json:"restricted_user_count"`
	// contains filtered or unexported fields
}

Contains statistics about administrator actions done by a user

func UnmarshalChatStatisticsAdministratorActionsInfo

func UnmarshalChatStatisticsAdministratorActionsInfo(data json.RawMessage) (*ChatStatisticsAdministratorActionsInfo, error)

func (*ChatStatisticsAdministratorActionsInfo) GetClass

func (*ChatStatisticsAdministratorActionsInfo) GetType

func (*ChatStatisticsAdministratorActionsInfo) MarshalJSON

func (entity *ChatStatisticsAdministratorActionsInfo) MarshalJSON() ([]byte, error)

type ChatStatisticsChannel

type ChatStatisticsChannel struct {

	// A period to which the statistics applies
	Period *DateRange `json:"period"`
	// Number of members in the chat
	MemberCount *StatisticalValue `json:"member_count"`
	// Mean number of times the recently sent messages was viewed
	MeanViewCount *StatisticalValue `json:"mean_view_count"`
	// Mean number of times the recently sent messages was shared
	MeanShareCount *StatisticalValue `json:"mean_share_count"`
	// A percentage of users with enabled notifications for the chat
	EnabledNotificationsPercentage float64 `json:"enabled_notifications_percentage"`
	// A graph containing number of members in the chat
	MemberCountGraph StatisticalGraph `json:"member_count_graph"`
	// A graph containing number of members joined and left the chat
	JoinGraph StatisticalGraph `json:"join_graph"`
	// A graph containing number of members muted and unmuted the chat
	MuteGraph StatisticalGraph `json:"mute_graph"`
	// A graph containing number of message views in a given hour in the last two weeks
	ViewCountByHourGraph StatisticalGraph `json:"view_count_by_hour_graph"`
	// A graph containing number of message views per source
	ViewCountBySourceGraph StatisticalGraph `json:"view_count_by_source_graph"`
	// A graph containing number of new member joins per source
	JoinBySourceGraph StatisticalGraph `json:"join_by_source_graph"`
	// A graph containing number of users viewed chat messages per language
	LanguageGraph StatisticalGraph `json:"language_graph"`
	// A graph containing number of chat message views and shares
	MessageInteractionGraph StatisticalGraph `json:"message_interaction_graph"`
	// A graph containing number of views of associated with the chat instant views
	InstantViewInteractionGraph StatisticalGraph `json:"instant_view_interaction_graph"`
	// Detailed statistics about number of views and shares of recently sent messages
	RecentMessageInteractions []*ChatStatisticsMessageInteractionInfo `json:"recent_message_interactions"`
	// contains filtered or unexported fields
}

A detailed statistics about a channel chat

func UnmarshalChatStatisticsChannel

func UnmarshalChatStatisticsChannel(data json.RawMessage) (*ChatStatisticsChannel, error)

func (*ChatStatisticsChannel) ChatStatisticsType

func (*ChatStatisticsChannel) ChatStatisticsType() string

func (*ChatStatisticsChannel) GetClass

func (*ChatStatisticsChannel) GetClass() string

func (*ChatStatisticsChannel) GetType

func (*ChatStatisticsChannel) GetType() string

func (*ChatStatisticsChannel) MarshalJSON

func (entity *ChatStatisticsChannel) MarshalJSON() ([]byte, error)

func (*ChatStatisticsChannel) UnmarshalJSON

func (chatStatisticsChannel *ChatStatisticsChannel) UnmarshalJSON(data []byte) error

type ChatStatisticsInviterInfo

type ChatStatisticsInviterInfo struct {

	// User identifier
	UserId int32 `json:"user_id"`
	// Number of new members invited by the user
	AddedMemberCount int32 `json:"added_member_count"`
	// contains filtered or unexported fields
}

Contains statistics about number of new members invited by a user

func UnmarshalChatStatisticsInviterInfo

func UnmarshalChatStatisticsInviterInfo(data json.RawMessage) (*ChatStatisticsInviterInfo, error)

func (*ChatStatisticsInviterInfo) GetClass

func (*ChatStatisticsInviterInfo) GetClass() string

func (*ChatStatisticsInviterInfo) GetType

func (*ChatStatisticsInviterInfo) GetType() string

func (*ChatStatisticsInviterInfo) MarshalJSON

func (entity *ChatStatisticsInviterInfo) MarshalJSON() ([]byte, error)

type ChatStatisticsMessageInteractionInfo

type ChatStatisticsMessageInteractionInfo struct {

	// Message identifier
	MessageId int64 `json:"message_id"`
	// Number of times the message was viewed
	ViewCount int32 `json:"view_count"`
	// Number of times the message was forwarded
	ForwardCount int32 `json:"forward_count"`
	// contains filtered or unexported fields
}

Contains statistics about interactions with a message

func UnmarshalChatStatisticsMessageInteractionInfo

func UnmarshalChatStatisticsMessageInteractionInfo(data json.RawMessage) (*ChatStatisticsMessageInteractionInfo, error)

func (*ChatStatisticsMessageInteractionInfo) GetClass

func (*ChatStatisticsMessageInteractionInfo) GetType

func (*ChatStatisticsMessageInteractionInfo) MarshalJSON

func (entity *ChatStatisticsMessageInteractionInfo) MarshalJSON() ([]byte, error)

type ChatStatisticsMessageSenderInfo

type ChatStatisticsMessageSenderInfo struct {

	// User identifier
	UserId int32 `json:"user_id"`
	// Number of sent messages
	SentMessageCount int32 `json:"sent_message_count"`
	// Average number of characters in sent messages
	AverageCharacterCount int32 `json:"average_character_count"`
	// contains filtered or unexported fields
}

Contains statistics about messages sent by a user

func UnmarshalChatStatisticsMessageSenderInfo

func UnmarshalChatStatisticsMessageSenderInfo(data json.RawMessage) (*ChatStatisticsMessageSenderInfo, error)

func (*ChatStatisticsMessageSenderInfo) GetClass

func (*ChatStatisticsMessageSenderInfo) GetType

func (*ChatStatisticsMessageSenderInfo) MarshalJSON

func (entity *ChatStatisticsMessageSenderInfo) MarshalJSON() ([]byte, error)

type ChatStatisticsSupergroup

type ChatStatisticsSupergroup struct {

	// A period to which the statistics applies
	Period *DateRange `json:"period"`
	// Number of members in the chat
	MemberCount *StatisticalValue `json:"member_count"`
	// Number of messages sent to the chat
	MessageCount *StatisticalValue `json:"message_count"`
	// Number of users who viewed messages in the chat
	ViewerCount *StatisticalValue `json:"viewer_count"`
	// Number of users who sent messages to the chat
	SenderCount *StatisticalValue `json:"sender_count"`
	// A graph containing number of members in the chat
	MemberCountGraph StatisticalGraph `json:"member_count_graph"`
	// A graph containing number of members joined and left the chat
	JoinGraph StatisticalGraph `json:"join_graph"`
	// A graph containing number of new member joins per source
	JoinBySourceGraph StatisticalGraph `json:"join_by_source_graph"`
	// A graph containing distribution of active users per language
	LanguageGraph StatisticalGraph `json:"language_graph"`
	// A graph containing distribution of sent messages by content type
	MessageContentGraph StatisticalGraph `json:"message_content_graph"`
	// A graph containing number of different actions in the chat
	ActionGraph StatisticalGraph `json:"action_graph"`
	// A graph containing distribution of message views per hour
	DayGraph StatisticalGraph `json:"day_graph"`
	// A graph containing distribution of message views per day of week
	WeekGraph StatisticalGraph `json:"week_graph"`
	// List of users sent most messages in the last week
	TopSenders []*ChatStatisticsMessageSenderInfo `json:"top_senders"`
	// List of most active administrators in the last week
	TopAdministrators []*ChatStatisticsAdministratorActionsInfo `json:"top_administrators"`
	// List of most active inviters of new members in the last week
	TopInviters []*ChatStatisticsInviterInfo `json:"top_inviters"`
	// contains filtered or unexported fields
}

A detailed statistics about a supergroup chat

func UnmarshalChatStatisticsSupergroup

func UnmarshalChatStatisticsSupergroup(data json.RawMessage) (*ChatStatisticsSupergroup, error)

func (*ChatStatisticsSupergroup) ChatStatisticsType

func (*ChatStatisticsSupergroup) ChatStatisticsType() string

func (*ChatStatisticsSupergroup) GetClass

func (*ChatStatisticsSupergroup) GetClass() string

func (*ChatStatisticsSupergroup) GetType

func (*ChatStatisticsSupergroup) GetType() string

func (*ChatStatisticsSupergroup) MarshalJSON

func (entity *ChatStatisticsSupergroup) MarshalJSON() ([]byte, error)

func (*ChatStatisticsSupergroup) UnmarshalJSON

func (chatStatisticsSupergroup *ChatStatisticsSupergroup) UnmarshalJSON(data []byte) error

type ChatType

type ChatType interface {
	ChatTypeType() string
}

Describes the type of a chat

func UnmarshalChatType

func UnmarshalChatType(data json.RawMessage) (ChatType, error)

func UnmarshalListOfChatType

func UnmarshalListOfChatType(dataList []json.RawMessage) ([]ChatType, error)

type ChatTypeBasicGroup

type ChatTypeBasicGroup struct {

	// Basic group identifier
	BasicGroupId int32 `json:"basic_group_id"`
	// contains filtered or unexported fields
}

A basic group (i.e., a chat with 0-200 other users)

func UnmarshalChatTypeBasicGroup

func UnmarshalChatTypeBasicGroup(data json.RawMessage) (*ChatTypeBasicGroup, error)

func (*ChatTypeBasicGroup) ChatTypeType

func (*ChatTypeBasicGroup) ChatTypeType() string

func (*ChatTypeBasicGroup) GetClass

func (*ChatTypeBasicGroup) GetClass() string

func (*ChatTypeBasicGroup) GetType

func (*ChatTypeBasicGroup) GetType() string

func (*ChatTypeBasicGroup) MarshalJSON

func (entity *ChatTypeBasicGroup) MarshalJSON() ([]byte, error)

type ChatTypePrivate

type ChatTypePrivate struct {

	// User identifier
	UserId int32 `json:"user_id"`
	// contains filtered or unexported fields
}

An ordinary chat with a user

func UnmarshalChatTypePrivate

func UnmarshalChatTypePrivate(data json.RawMessage) (*ChatTypePrivate, error)

func (*ChatTypePrivate) ChatTypeType

func (*ChatTypePrivate) ChatTypeType() string

func (*ChatTypePrivate) GetClass

func (*ChatTypePrivate) GetClass() string

func (*ChatTypePrivate) GetType

func (*ChatTypePrivate) GetType() string

func (*ChatTypePrivate) MarshalJSON

func (entity *ChatTypePrivate) MarshalJSON() ([]byte, error)

type ChatTypeSecret

type ChatTypeSecret struct {

	// Secret chat identifier
	SecretChatId int32 `json:"secret_chat_id"`
	// User identifier of the secret chat peer
	UserId int32 `json:"user_id"`
	// contains filtered or unexported fields
}

A secret chat with a user

func UnmarshalChatTypeSecret

func UnmarshalChatTypeSecret(data json.RawMessage) (*ChatTypeSecret, error)

func (*ChatTypeSecret) ChatTypeType

func (*ChatTypeSecret) ChatTypeType() string

func (*ChatTypeSecret) GetClass

func (*ChatTypeSecret) GetClass() string

func (*ChatTypeSecret) GetType

func (*ChatTypeSecret) GetType() string

func (*ChatTypeSecret) MarshalJSON

func (entity *ChatTypeSecret) MarshalJSON() ([]byte, error)

type ChatTypeSupergroup

type ChatTypeSupergroup struct {

	// Supergroup or channel identifier
	SupergroupId int32 `json:"supergroup_id"`
	// True, if the supergroup is a channel
	IsChannel bool `json:"is_channel"`
	// contains filtered or unexported fields
}

A supergroup (i.e. a chat with up to GetOption("supergroup_max_size") other users), or channel (with unlimited members)

func UnmarshalChatTypeSupergroup

func UnmarshalChatTypeSupergroup(data json.RawMessage) (*ChatTypeSupergroup, error)

func (*ChatTypeSupergroup) ChatTypeType

func (*ChatTypeSupergroup) ChatTypeType() string

func (*ChatTypeSupergroup) GetClass

func (*ChatTypeSupergroup) GetClass() string

func (*ChatTypeSupergroup) GetType

func (*ChatTypeSupergroup) GetType() string

func (*ChatTypeSupergroup) MarshalJSON

func (entity *ChatTypeSupergroup) MarshalJSON() ([]byte, error)

type Chats

type Chats struct {

	// Approximate total count of chats found
	TotalCount int32 `json:"total_count"`
	// List of chat identifiers
	ChatIds []int64 `json:"chat_ids"`
	// contains filtered or unexported fields
}

Represents a list of chats

func UnmarshalChats

func UnmarshalChats(data json.RawMessage) (*Chats, error)

func (*Chats) GetClass

func (*Chats) GetClass() string

func (*Chats) GetType

func (*Chats) GetType() string

func (*Chats) MarshalJSON

func (entity *Chats) MarshalJSON() ([]byte, error)

type ChatsNearby

type ChatsNearby struct {

	// List of users nearby
	UsersNearby []*ChatNearby `json:"users_nearby"`
	// List of location-based supergroups nearby
	SupergroupsNearby []*ChatNearby `json:"supergroups_nearby"`
	// contains filtered or unexported fields
}

Represents a list of chats located nearby

func UnmarshalChatsNearby

func UnmarshalChatsNearby(data json.RawMessage) (*ChatsNearby, error)

func (*ChatsNearby) GetClass

func (*ChatsNearby) GetClass() string

func (*ChatsNearby) GetType

func (*ChatsNearby) GetType() string

func (*ChatsNearby) MarshalJSON

func (entity *ChatsNearby) MarshalJSON() ([]byte, error)

type CheckAuthenticationBotTokenRequest

type CheckAuthenticationBotTokenRequest struct {
	// The bot token
	Token string `json:"token"`
}

type CheckAuthenticationCodeRequest

type CheckAuthenticationCodeRequest struct {
	// The verification code received via SMS, Telegram message, phone call, or flash call
	Code string `json:"code"`
}

type CheckAuthenticationPasswordRequest

type CheckAuthenticationPasswordRequest struct {
	// The password to check
	Password string `json:"password"`
}

type CheckChangePhoneNumberCodeRequest

type CheckChangePhoneNumberCodeRequest struct {
	// Verification code received by SMS, phone call or flash call
	Code string `json:"code"`
}

type CheckChatInviteLinkRequest

type CheckChatInviteLinkRequest struct {
	// Invite link to be checked; should begin with "https://t.me/joinchat/", "https://telegram.me/joinchat/", or "https://telegram.dog/joinchat/"
	InviteLink string `json:"invite_link"`
}

type CheckChatUsernameRequest

type CheckChatUsernameRequest struct {
	// Chat identifier; should be identifier of a supergroup chat, or a channel chat, or a private chat with self, or zero if chat is being created
	ChatId int64 `json:"chat_id"`
	// Username to be checked
	Username string `json:"username"`
}

type CheckChatUsernameResult

type CheckChatUsernameResult interface {
	CheckChatUsernameResultType() string
}

Represents result of checking whether a username can be set for a chat

func UnmarshalCheckChatUsernameResult

func UnmarshalCheckChatUsernameResult(data json.RawMessage) (CheckChatUsernameResult, error)

func UnmarshalListOfCheckChatUsernameResult

func UnmarshalListOfCheckChatUsernameResult(dataList []json.RawMessage) ([]CheckChatUsernameResult, error)

type CheckChatUsernameResultOk

type CheckChatUsernameResultOk struct {
	// contains filtered or unexported fields
}

The username can be set

func UnmarshalCheckChatUsernameResultOk

func UnmarshalCheckChatUsernameResultOk(data json.RawMessage) (*CheckChatUsernameResultOk, error)

func (*CheckChatUsernameResultOk) CheckChatUsernameResultType

func (*CheckChatUsernameResultOk) CheckChatUsernameResultType() string

func (*CheckChatUsernameResultOk) GetClass

func (*CheckChatUsernameResultOk) GetClass() string

func (*CheckChatUsernameResultOk) GetType

func (*CheckChatUsernameResultOk) GetType() string

func (*CheckChatUsernameResultOk) MarshalJSON

func (entity *CheckChatUsernameResultOk) MarshalJSON() ([]byte, error)

type CheckChatUsernameResultPublicChatsTooMuch

type CheckChatUsernameResultPublicChatsTooMuch struct {
	// contains filtered or unexported fields
}

The user has too much chats with username, one of them should be made private first

func UnmarshalCheckChatUsernameResultPublicChatsTooMuch

func UnmarshalCheckChatUsernameResultPublicChatsTooMuch(data json.RawMessage) (*CheckChatUsernameResultPublicChatsTooMuch, error)

func (*CheckChatUsernameResultPublicChatsTooMuch) CheckChatUsernameResultType

func (*CheckChatUsernameResultPublicChatsTooMuch) CheckChatUsernameResultType() string

func (*CheckChatUsernameResultPublicChatsTooMuch) GetClass

func (*CheckChatUsernameResultPublicChatsTooMuch) GetType

func (*CheckChatUsernameResultPublicChatsTooMuch) MarshalJSON

func (entity *CheckChatUsernameResultPublicChatsTooMuch) MarshalJSON() ([]byte, error)

type CheckChatUsernameResultPublicGroupsUnavailable

type CheckChatUsernameResultPublicGroupsUnavailable struct {
	// contains filtered or unexported fields
}

The user can't be a member of a public supergroup

func UnmarshalCheckChatUsernameResultPublicGroupsUnavailable

func UnmarshalCheckChatUsernameResultPublicGroupsUnavailable(data json.RawMessage) (*CheckChatUsernameResultPublicGroupsUnavailable, error)

func (*CheckChatUsernameResultPublicGroupsUnavailable) CheckChatUsernameResultType

func (*CheckChatUsernameResultPublicGroupsUnavailable) CheckChatUsernameResultType() string

func (*CheckChatUsernameResultPublicGroupsUnavailable) GetClass

func (*CheckChatUsernameResultPublicGroupsUnavailable) GetType

func (*CheckChatUsernameResultPublicGroupsUnavailable) MarshalJSON

func (entity *CheckChatUsernameResultPublicGroupsUnavailable) MarshalJSON() ([]byte, error)

type CheckChatUsernameResultUsernameInvalid

type CheckChatUsernameResultUsernameInvalid struct {
	// contains filtered or unexported fields
}

The username is invalid

func UnmarshalCheckChatUsernameResultUsernameInvalid

func UnmarshalCheckChatUsernameResultUsernameInvalid(data json.RawMessage) (*CheckChatUsernameResultUsernameInvalid, error)

func (*CheckChatUsernameResultUsernameInvalid) CheckChatUsernameResultType

func (*CheckChatUsernameResultUsernameInvalid) CheckChatUsernameResultType() string

func (*CheckChatUsernameResultUsernameInvalid) GetClass

func (*CheckChatUsernameResultUsernameInvalid) GetType

func (*CheckChatUsernameResultUsernameInvalid) MarshalJSON

func (entity *CheckChatUsernameResultUsernameInvalid) MarshalJSON() ([]byte, error)

type CheckChatUsernameResultUsernameOccupied

type CheckChatUsernameResultUsernameOccupied struct {
	// contains filtered or unexported fields
}

The username is occupied

func UnmarshalCheckChatUsernameResultUsernameOccupied

func UnmarshalCheckChatUsernameResultUsernameOccupied(data json.RawMessage) (*CheckChatUsernameResultUsernameOccupied, error)

func (*CheckChatUsernameResultUsernameOccupied) CheckChatUsernameResultType

func (*CheckChatUsernameResultUsernameOccupied) CheckChatUsernameResultType() string

func (*CheckChatUsernameResultUsernameOccupied) GetClass

func (*CheckChatUsernameResultUsernameOccupied) GetType

func (*CheckChatUsernameResultUsernameOccupied) MarshalJSON

func (entity *CheckChatUsernameResultUsernameOccupied) MarshalJSON() ([]byte, error)

type CheckCreatedPublicChatsLimitRequest

type CheckCreatedPublicChatsLimitRequest struct {
	// Type of the public chats, for which to check the limit
	Type PublicChatType `json:"type"`
}

type CheckDatabaseEncryptionKeyRequest

type CheckDatabaseEncryptionKeyRequest struct {
	// Encryption key to check or set up
	EncryptionKey []byte `json:"encryption_key"`
}

type CheckEmailAddressVerificationCodeRequest

type CheckEmailAddressVerificationCodeRequest struct {
	// Verification code
	Code string `json:"code"`
}

type CheckPhoneNumberConfirmationCodeRequest

type CheckPhoneNumberConfirmationCodeRequest struct {
	// The phone number confirmation code
	Code string `json:"code"`
}

type CheckPhoneNumberVerificationCodeRequest

type CheckPhoneNumberVerificationCodeRequest struct {
	// Verification code
	Code string `json:"code"`
}

type CheckRecoveryEmailAddressCodeRequest

type CheckRecoveryEmailAddressCodeRequest struct {
	// Verification code
	Code string `json:"code"`
}

type CleanFileNameRequest

type CleanFileNameRequest struct {
	// File name or path to the file
	FileName string `json:"file_name"`
}

type ClearAllDraftMessagesRequest

type ClearAllDraftMessagesRequest struct {
	// If true, local draft messages in secret chats will not be cleared
	ExcludeSecretChats bool `json:"exclude_secret_chats"`
}

type ClearRecentStickersRequest

type ClearRecentStickersRequest struct {
	// Pass true to clear the list of stickers recently attached to photo or video files; pass false to clear the list of recently sent stickers
	IsAttached bool `json:"is_attached"`
}

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(authorizationStateHandler AuthorizationStateHandler, options ...Option) (*Client, error)

func (*Client) AcceptCall

func (client *Client) AcceptCall(req *AcceptCallRequest) (*Ok, error)

Accepts an incoming call

func (*Client) AcceptTermsOfService

func (client *Client) AcceptTermsOfService(req *AcceptTermsOfServiceRequest) (*Ok, error)

Accepts Telegram terms of services

func (*Client) AddChatMember

func (client *Client) AddChatMember(req *AddChatMemberRequest) (*Ok, error)

Adds a new member to a chat. Members can't be added to private or secret chats. Members will not be added until the chat state has been synchronized with the server

func (*Client) AddChatMembers

func (client *Client) AddChatMembers(req *AddChatMembersRequest) (*Ok, error)

Adds multiple new members to a chat. Currently this option is only available for supergroups and channels. This option can't be used to join a chat. Members can't be added to a channel if it has more than 200 members. Members will not be added until the chat state has been synchronized with the server

func (*Client) AddChatToList

func (client *Client) AddChatToList(req *AddChatToListRequest) (*Ok, error)

Adds a chat to a chat list. A chat can't be simultaneously in Main and Archive chat lists, so it is automatically removed from another one if needed

func (*Client) AddContact

func (client *Client) AddContact(req *AddContactRequest) (*Ok, error)

Adds a user to the contact list or edits an existing contact by their user identifier

func (*Client) AddCustomServerLanguagePack

func (client *Client) AddCustomServerLanguagePack(req *AddCustomServerLanguagePackRequest) (*Ok, error)

Adds a custom server language pack to the list of installed language packs in current localization target. Can be called before authorization

func (*Client) AddFavoriteSticker

func (client *Client) AddFavoriteSticker(req *AddFavoriteStickerRequest) (*Ok, error)

Adds a new sticker to the list of favorite stickers. The new sticker is added to the top of the list. If the sticker was already in the list, it is removed from the list first. Only stickers belonging to a sticker set can be added to this list

func (*Client) AddLocalMessage

func (client *Client) AddLocalMessage(req *AddLocalMessageRequest) (*Message, error)

Adds a local message to a chat. The message is persistent across application restarts only if the message database is used. Returns the added message

func (*Client) AddLogMessage

func (client *Client) AddLogMessage(req *AddLogMessageRequest) (*Ok, error)

Adds a message to TDLib internal log. Can be called synchronously

func (*Client) AddNetworkStatistics

func (client *Client) AddNetworkStatistics(req *AddNetworkStatisticsRequest) (*Ok, error)

Adds the specified data to data usage statistics. Can be called before authorization

func (*Client) AddProxy

func (client *Client) AddProxy(req *AddProxyRequest) (*Proxy, error)

Adds a proxy server for network requests. Can be called before authorization

func (*Client) AddRecentSticker

func (client *Client) AddRecentSticker(req *AddRecentStickerRequest) (*Stickers, error)

Manually adds a new sticker to the list of recently used stickers. The new sticker is added to the top of the list. If the sticker was already in the list, it is removed from the list first. Only stickers belonging to a sticker set can be added to this list

func (*Client) AddRecentlyFoundChat

func (client *Client) AddRecentlyFoundChat(req *AddRecentlyFoundChatRequest) (*Ok, error)

Adds a chat to the list of recently found chats. The chat is added to the beginning of the list. If the chat is already in the list, it will be removed from the list first

func (*Client) AddSavedAnimation

func (client *Client) AddSavedAnimation(req *AddSavedAnimationRequest) (*Ok, error)

Manually adds a new animation to the list of saved animations. The new animation is added to the beginning of the list. If the animation was already in the list, it is removed first. Only non-secret video animations with MIME type "video/mp4" can be added to the list

func (*Client) AddStickerToSet

func (client *Client) AddStickerToSet(req *AddStickerToSetRequest) (*StickerSet, error)

Adds a new sticker to a set; for bots only. Returns the sticker set

func (*Client) AnswerCallbackQuery

func (client *Client) AnswerCallbackQuery(req *AnswerCallbackQueryRequest) (*Ok, error)

Sets the result of a callback query; for bots only

func (*Client) AnswerCustomQuery

func (client *Client) AnswerCustomQuery(req *AnswerCustomQueryRequest) (*Ok, error)

Answers a custom query; for bots only

func (*Client) AnswerInlineQuery

func (client *Client) AnswerInlineQuery(req *AnswerInlineQueryRequest) (*Ok, error)

Sets the result of an inline query; for bots only

func (*Client) AnswerPreCheckoutQuery

func (client *Client) AnswerPreCheckoutQuery(req *AnswerPreCheckoutQueryRequest) (*Ok, error)

Sets the result of a pre-checkout query; for bots only

func (*Client) AnswerShippingQuery

func (client *Client) AnswerShippingQuery(req *AnswerShippingQueryRequest) (*Ok, error)

Sets the result of a shipping query; for bots only

func (*Client) BlockMessageSenderFromReplies

func (client *Client) BlockMessageSenderFromReplies(req *BlockMessageSenderFromRepliesRequest) (*Ok, error)

Blocks an original sender of a message in the Replies chat

func (*Client) CanTransferOwnership

func (client *Client) CanTransferOwnership() (CanTransferOwnershipResult, error)

Checks whether the current session can be used to transfer a chat ownership to another user

func (*Client) CancelDownloadFile

func (client *Client) CancelDownloadFile(req *CancelDownloadFileRequest) (*Ok, error)

Stops the downloading of a file. If a file has already been downloaded, does nothing

func (*Client) CancelUploadFile

func (client *Client) CancelUploadFile(req *CancelUploadFileRequest) (*Ok, error)

Stops the uploading of a file. Supported only for files uploaded by using uploadFile. For other files the behavior is undefined

func (*Client) ChangeImportedContacts

func (client *Client) ChangeImportedContacts(req *ChangeImportedContactsRequest) (*ImportedContacts, error)

Changes imported contacts using the list of current user contacts saved on the device. Imports newly added contacts and, if at least the file database is enabled, deletes recently deleted contacts. Query result depends on the result of the previous query, so only one query is possible at the same time

func (*Client) ChangePhoneNumber

func (client *Client) ChangePhoneNumber(req *ChangePhoneNumberRequest) (*AuthenticationCodeInfo, error)

Changes the phone number of the user and sends an authentication code to the user's new phone number. On success, returns information about the sent code

func (*Client) ChangeStickerSet

func (client *Client) ChangeStickerSet(req *ChangeStickerSetRequest) (*Ok, error)

Installs/uninstalls or activates/archives a sticker set

func (*Client) CheckAuthenticationBotToken

func (client *Client) CheckAuthenticationBotToken(req *CheckAuthenticationBotTokenRequest) (*Ok, error)

Checks the authentication token of a bot; to log in as a bot. Works only when the current authorization state is authorizationStateWaitPhoneNumber. Can be used instead of setAuthenticationPhoneNumber and checkAuthenticationCode to log in

func (*Client) CheckAuthenticationCode

func (client *Client) CheckAuthenticationCode(req *CheckAuthenticationCodeRequest) (*Ok, error)

Checks the authentication code. Works only when the current authorization state is authorizationStateWaitCode

func (*Client) CheckAuthenticationPassword

func (client *Client) CheckAuthenticationPassword(req *CheckAuthenticationPasswordRequest) (*Ok, error)

Checks the authentication password for correctness. Works only when the current authorization state is authorizationStateWaitPassword

func (*Client) CheckChangePhoneNumberCode

func (client *Client) CheckChangePhoneNumberCode(req *CheckChangePhoneNumberCodeRequest) (*Ok, error)

Checks the authentication code sent to confirm a new phone number of the user

func (client *Client) CheckChatInviteLink(req *CheckChatInviteLinkRequest) (*ChatInviteLinkInfo, error)

Checks the validity of an invite link for a chat and returns information about the corresponding chat

func (*Client) CheckChatUsername

func (client *Client) CheckChatUsername(req *CheckChatUsernameRequest) (CheckChatUsernameResult, error)

Checks whether a username can be set for a chat

func (*Client) CheckCreatedPublicChatsLimit

func (client *Client) CheckCreatedPublicChatsLimit(req *CheckCreatedPublicChatsLimitRequest) (*Ok, error)

Checks whether the maximum number of owned public chats has been reached. Returns corresponding error if the limit was reached

func (*Client) CheckDatabaseEncryptionKey

func (client *Client) CheckDatabaseEncryptionKey(req *CheckDatabaseEncryptionKeyRequest) (*Ok, error)

Checks the database encryption key for correctness. Works only when the current authorization state is authorizationStateWaitEncryptionKey

func (*Client) CheckEmailAddressVerificationCode

func (client *Client) CheckEmailAddressVerificationCode(req *CheckEmailAddressVerificationCodeRequest) (*Ok, error)

Checks the email address verification code for Telegram Passport

func (*Client) CheckPhoneNumberConfirmationCode

func (client *Client) CheckPhoneNumberConfirmationCode(req *CheckPhoneNumberConfirmationCodeRequest) (*Ok, error)

Checks phone number confirmation code

func (*Client) CheckPhoneNumberVerificationCode

func (client *Client) CheckPhoneNumberVerificationCode(req *CheckPhoneNumberVerificationCodeRequest) (*Ok, error)

Checks the phone number verification code for Telegram Passport

func (*Client) CheckRecoveryEmailAddressCode

func (client *Client) CheckRecoveryEmailAddressCode(req *CheckRecoveryEmailAddressCodeRequest) (*PasswordState, error)

Checks the 2-step verification recovery email address verification code

func (*Client) CleanFileName

func (client *Client) CleanFileName(req *CleanFileNameRequest) (*Text, error)

Removes potentially dangerous characters from the name of a file. The encoding of the file name is supposed to be UTF-8. Returns an empty string on failure. Can be called synchronously

func (*Client) ClearAllDraftMessages

func (client *Client) ClearAllDraftMessages(req *ClearAllDraftMessagesRequest) (*Ok, error)

Clears draft messages in all chats

func (*Client) ClearImportedContacts

func (client *Client) ClearImportedContacts() (*Ok, error)

Clears all imported contacts, contact list remains unchanged

func (*Client) ClearRecentStickers

func (client *Client) ClearRecentStickers(req *ClearRecentStickersRequest) (*Ok, error)

Clears the list of recently used stickers

func (*Client) ClearRecentlyFoundChats

func (client *Client) ClearRecentlyFoundChats() (*Ok, error)

Clears the list of recently found chats

func (*Client) Close

func (client *Client) Close() (*Ok, error)

Closes the TDLib instance. All databases will be flushed to disk and properly closed. After the close completes, updateAuthorizationState with authorizationStateClosed will be sent. Can be called before initialization

func (*Client) CloseChat

func (client *Client) CloseChat(req *CloseChatRequest) (*Ok, error)

Informs TDLib that the chat is closed by the user. Many useful activities depend on the chat being opened or closed

func (*Client) CloseSecretChat

func (client *Client) CloseSecretChat(req *CloseSecretChatRequest) (*Ok, error)

Closes a secret chat, effectively transferring its state to secretChatStateClosed

func (*Client) ConfirmQrCodeAuthentication

func (client *Client) ConfirmQrCodeAuthentication(req *ConfirmQrCodeAuthenticationRequest) (*Session, error)

Confirms QR code authentication on another device. Returns created session on success

func (*Client) CreateBasicGroupChat

func (client *Client) CreateBasicGroupChat(req *CreateBasicGroupChatRequest) (*Chat, error)

Returns an existing chat corresponding to a known basic group

func (*Client) CreateCall

func (client *Client) CreateCall(req *CreateCallRequest) (*CallId, error)

Creates a new call

func (*Client) CreateChatFilter

func (client *Client) CreateChatFilter(req *CreateChatFilterRequest) (*ChatFilterInfo, error)

Creates new chat filter. Returns information about the created chat filter

func (*Client) CreateNewBasicGroupChat

func (client *Client) CreateNewBasicGroupChat(req *CreateNewBasicGroupChatRequest) (*Chat, error)

Creates a new basic group and sends a corresponding messageBasicGroupChatCreate. Returns the newly created chat

func (*Client) CreateNewSecretChat

func (client *Client) CreateNewSecretChat(req *CreateNewSecretChatRequest) (*Chat, error)

Creates a new secret chat. Returns the newly created chat

func (*Client) CreateNewStickerSet

func (client *Client) CreateNewStickerSet(req *CreateNewStickerSetRequest) (*StickerSet, error)

Creates a new sticker set; for bots only. Returns the newly created sticker set

func (*Client) CreateNewSupergroupChat

func (client *Client) CreateNewSupergroupChat(req *CreateNewSupergroupChatRequest) (*Chat, error)

Creates a new supergroup or channel and sends a corresponding messageSupergroupChatCreate. Returns the newly created chat

func (*Client) CreatePrivateChat

func (client *Client) CreatePrivateChat(req *CreatePrivateChatRequest) (*Chat, error)

Returns an existing chat corresponding to a given user

func (*Client) CreateSecretChat

func (client *Client) CreateSecretChat(req *CreateSecretChatRequest) (*Chat, error)

Returns an existing chat corresponding to a known secret chat

func (*Client) CreateSupergroupChat

func (client *Client) CreateSupergroupChat(req *CreateSupergroupChatRequest) (*Chat, error)

Returns an existing chat corresponding to a known supergroup or channel

func (*Client) CreateTemporaryPassword

func (client *Client) CreateTemporaryPassword(req *CreateTemporaryPasswordRequest) (*TemporaryPasswordState, error)

Creates a new temporary password for processing payments

func (*Client) DeleteAccount

func (client *Client) DeleteAccount(req *DeleteAccountRequest) (*Ok, error)

Deletes the account of the current user, deleting all information associated with the user from the server. The phone number of the account can be used to create a new account. Can be called before authorization when the current authorization state is authorizationStateWaitPassword

func (*Client) DeleteChatFilter

func (client *Client) DeleteChatFilter(req *DeleteChatFilterRequest) (*Ok, error)

Deletes existing chat filter

func (*Client) DeleteChatHistory

func (client *Client) DeleteChatHistory(req *DeleteChatHistoryRequest) (*Ok, error)

Deletes all messages in the chat. Use Chat.can_be_deleted_only_for_self and Chat.can_be_deleted_for_all_users fields to find whether and how the method can be applied to the chat

func (*Client) DeleteChatMessagesFromUser

func (client *Client) DeleteChatMessagesFromUser(req *DeleteChatMessagesFromUserRequest) (*Ok, error)

Deletes all messages sent by the specified user to a chat. Supported only for supergroups; requires can_delete_messages administrator privileges

func (*Client) DeleteChatReplyMarkup

func (client *Client) DeleteChatReplyMarkup(req *DeleteChatReplyMarkupRequest) (*Ok, error)

Deletes the default reply markup from a chat. Must be called after a one-time keyboard or a ForceReply reply markup has been used. UpdateChatReplyMarkup will be sent if the reply markup will be changed

func (*Client) DeleteFile

func (client *Client) DeleteFile(req *DeleteFileRequest) (*Ok, error)

Deletes a file from the TDLib file cache

func (*Client) DeleteLanguagePack

func (client *Client) DeleteLanguagePack(req *DeleteLanguagePackRequest) (*Ok, error)

Deletes all information about a language pack in the current localization target. The language pack which is currently in use (including base language pack) or is being synchronized can't be deleted. Can be called before authorization

func (*Client) DeleteMessages

func (client *Client) DeleteMessages(req *DeleteMessagesRequest) (*Ok, error)

Deletes messages

func (*Client) DeletePassportElement

func (client *Client) DeletePassportElement(req *DeletePassportElementRequest) (*Ok, error)

Deletes a Telegram Passport element

func (*Client) DeleteProfilePhoto

func (client *Client) DeleteProfilePhoto(req *DeleteProfilePhotoRequest) (*Ok, error)

Deletes a profile photo

func (*Client) DeleteSavedCredentials

func (client *Client) DeleteSavedCredentials() (*Ok, error)

Deletes saved credentials for all payment provider bots

func (*Client) DeleteSavedOrderInfo

func (client *Client) DeleteSavedOrderInfo() (*Ok, error)

Deletes saved order info

func (*Client) DeleteSupergroup

func (client *Client) DeleteSupergroup(req *DeleteSupergroupRequest) (*Ok, error)

Deletes a supergroup or channel along with all messages in the corresponding chat. This will release the supergroup or channel username and remove all members; requires owner privileges in the supergroup or channel. Chats with more than 1000 members can't be deleted using this method

func (*Client) Destroy

func (client *Client) Destroy() (*Ok, error)

Closes the TDLib instance, destroying all local data without a proper logout. The current user session will remain in the list of all active sessions. All local data will be destroyed. After the destruction completes updateAuthorizationState with authorizationStateClosed will be sent. Can be called before authorization

func (*Client) DisableProxy

func (client *Client) DisableProxy() (*Ok, error)

Disables the currently enabled proxy. Can be called before authorization

func (*Client) DiscardCall

func (client *Client) DiscardCall(req *DiscardCallRequest) (*Ok, error)

Discards a call

func (*Client) DisconnectAllWebsites

func (client *Client) DisconnectAllWebsites() (*Ok, error)

Disconnects all websites from the current user's Telegram account

func (*Client) DisconnectWebsite

func (client *Client) DisconnectWebsite(req *DisconnectWebsiteRequest) (*Ok, error)

Disconnects website from the current user's Telegram account

func (*Client) DownloadFile

func (client *Client) DownloadFile(req *DownloadFileRequest) (*File, error)

Downloads a file from the cloud. Download progress and completion of the download will be notified through updateFile updates

func (*Client) EditChatFilter

func (client *Client) EditChatFilter(req *EditChatFilterRequest) (*ChatFilterInfo, error)

Edits existing chat filter. Returns information about the edited chat filter

func (*Client) EditCustomLanguagePackInfo

func (client *Client) EditCustomLanguagePackInfo(req *EditCustomLanguagePackInfoRequest) (*Ok, error)

Edits information about a custom local language pack in the current localization target. Can be called before authorization

func (*Client) EditInlineMessageCaption

func (client *Client) EditInlineMessageCaption(req *EditInlineMessageCaptionRequest) (*Ok, error)

Edits the caption of an inline message sent via a bot; for bots only

func (*Client) EditInlineMessageLiveLocation

func (client *Client) EditInlineMessageLiveLocation(req *EditInlineMessageLiveLocationRequest) (*Ok, error)

Edits the content of a live location in an inline message sent via a bot; for bots only

func (*Client) EditInlineMessageMedia

func (client *Client) EditInlineMessageMedia(req *EditInlineMessageMediaRequest) (*Ok, error)

Edits the content of a message with an animation, an audio, a document, a photo or a video in an inline message sent via a bot; for bots only

func (*Client) EditInlineMessageReplyMarkup

func (client *Client) EditInlineMessageReplyMarkup(req *EditInlineMessageReplyMarkupRequest) (*Ok, error)

Edits the reply markup of an inline message sent via a bot; for bots only

func (*Client) EditInlineMessageText

func (client *Client) EditInlineMessageText(req *EditInlineMessageTextRequest) (*Ok, error)

Edits the text of an inline text or game message sent via a bot; for bots only

func (*Client) EditMessageCaption

func (client *Client) EditMessageCaption(req *EditMessageCaptionRequest) (*Message, error)

Edits the message content caption. Returns the edited message after the edit is completed on the server side

func (*Client) EditMessageLiveLocation

func (client *Client) EditMessageLiveLocation(req *EditMessageLiveLocationRequest) (*Message, error)

Edits the message content of a live location. Messages can be edited for a limited period of time specified in the live location. Returns the edited message after the edit is completed on the server side

func (*Client) EditMessageMedia

func (client *Client) EditMessageMedia(req *EditMessageMediaRequest) (*Message, error)

Edits the content of a message with an animation, an audio, a document, a photo or a video. The media in the message can't be replaced if the message was set to self-destruct. Media can't be replaced by self-destructing media. Media in an album can be edited only to contain a photo or a video. Returns the edited message after the edit is completed on the server side

func (*Client) EditMessageReplyMarkup

func (client *Client) EditMessageReplyMarkup(req *EditMessageReplyMarkupRequest) (*Message, error)

Edits the message reply markup; for bots only. Returns the edited message after the edit is completed on the server side

func (*Client) EditMessageSchedulingState

func (client *Client) EditMessageSchedulingState(req *EditMessageSchedulingStateRequest) (*Ok, error)

Edits the time when a scheduled message will be sent. Scheduling state of all messages in the same album or forwarded together with the message will be also changed

func (*Client) EditMessageText

func (client *Client) EditMessageText(req *EditMessageTextRequest) (*Message, error)

Edits the text of a message (or a text of a game message). Returns the edited message after the edit is completed on the server side

func (*Client) EditProxy

func (client *Client) EditProxy(req *EditProxyRequest) (*Proxy, error)

Edits an existing proxy server for network requests. Can be called before authorization

func (*Client) EnableProxy

func (client *Client) EnableProxy(req *EnableProxyRequest) (*Ok, error)

Enables a proxy. Only one proxy can be enabled at a time. Can be called before authorization

func (*Client) FinishFileGeneration

func (client *Client) FinishFileGeneration(req *FinishFileGenerationRequest) (*Ok, error)

Finishes the file generation

func (*Client) ForwardMessages

func (client *Client) ForwardMessages(req *ForwardMessagesRequest) (*Messages, error)

Forwards previously sent messages. Returns the forwarded messages in the same order as the message identifiers passed in message_ids. If a message can't be forwarded, null will be returned instead of the message

func (client *Client) GenerateChatInviteLink(req *GenerateChatInviteLinkRequest) (*ChatInviteLink, error)

Generates a new invite link for a chat; the previously generated link is revoked. Available for basic groups, supergroups, and channels. Requires administrator privileges and can_invite_users right

func (*Client) GetAccountTtl

func (client *Client) GetAccountTtl() (*AccountTtl, error)

Returns the period of inactivity after which the account of the current user will automatically be deleted

func (*Client) GetActiveLiveLocationMessages

func (client *Client) GetActiveLiveLocationMessages() (*Messages, error)

Returns all active live locations that should be updated by the application. The list is persistent across application restarts only if the message database is used

func (*Client) GetActiveSessions

func (client *Client) GetActiveSessions() (*Sessions, error)

Returns all active sessions of the current user

func (*Client) GetAllPassportElements

func (client *Client) GetAllPassportElements(req *GetAllPassportElementsRequest) (*PassportElements, error)

Returns all available Telegram Passport elements

func (*Client) GetApplicationConfig

func (client *Client) GetApplicationConfig() (JsonValue, error)

Returns application config, provided by the server. Can be called before authorization

func (*Client) GetArchivedStickerSets

func (client *Client) GetArchivedStickerSets(req *GetArchivedStickerSetsRequest) (*StickerSets, error)

Returns a list of archived sticker sets

func (*Client) GetAttachedStickerSets

func (client *Client) GetAttachedStickerSets(req *GetAttachedStickerSetsRequest) (*StickerSets, error)

Returns a list of sticker sets attached to a file. Currently only photos and videos can have attached sticker sets

func (*Client) GetAuthorizationState

func (client *Client) GetAuthorizationState() (AuthorizationState, error)

Returns the current authorization state; this is an offline request. For informational purposes only. Use updateAuthorizationState instead to maintain the current authorization state. Can be called before initialization

func (*Client) GetAutoDownloadSettingsPresets

func (client *Client) GetAutoDownloadSettingsPresets() (*AutoDownloadSettingsPresets, error)

Returns auto-download settings presets for the current user

func (*Client) GetBackgroundUrl

func (client *Client) GetBackgroundUrl(req *GetBackgroundUrlRequest) (*HttpUrl, error)

Constructs a persistent HTTP URL for a background

func (*Client) GetBackgrounds

func (client *Client) GetBackgrounds(req *GetBackgroundsRequest) (*Backgrounds, error)

Returns backgrounds installed by the user

func (*Client) GetBankCardInfo

func (client *Client) GetBankCardInfo(req *GetBankCardInfoRequest) (*BankCardInfo, error)

Returns information about a bank card

func (*Client) GetBasicGroup

func (client *Client) GetBasicGroup(req *GetBasicGroupRequest) (*BasicGroup, error)

Returns information about a basic group by its identifier. This is an offline request if the current user is not a bot

func (*Client) GetBasicGroupFullInfo

func (client *Client) GetBasicGroupFullInfo(req *GetBasicGroupFullInfoRequest) (*BasicGroupFullInfo, error)

Returns full information about a basic group by its identifier

func (*Client) GetBlockedMessageSenders

func (client *Client) GetBlockedMessageSenders(req *GetBlockedMessageSendersRequest) (*MessageSenders, error)

Returns users and chats that were blocked by the current user

func (*Client) GetCallbackQueryAnswer

func (client *Client) GetCallbackQueryAnswer(req *GetCallbackQueryAnswerRequest) (*CallbackQueryAnswer, error)

Sends a callback query to a bot and returns an answer. Returns an error with code 502 if the bot fails to answer the query before the query timeout expires

func (*Client) GetCallbackQueryMessage

func (client *Client) GetCallbackQueryMessage(req *GetCallbackQueryMessageRequest) (*Message, error)

Returns information about a message with the callback button that originated a callback query; for bots only

func (*Client) GetChat

func (client *Client) GetChat(req *GetChatRequest) (*Chat, error)

Returns information about a chat by its identifier, this is an offline request if the current user is not a bot

func (*Client) GetChatAdministrators

func (client *Client) GetChatAdministrators(req *GetChatAdministratorsRequest) (*ChatAdministrators, error)

Returns a list of administrators of the chat with their custom titles

func (*Client) GetChatEventLog

func (client *Client) GetChatEventLog(req *GetChatEventLogRequest) (*ChatEvents, error)

Returns a list of service actions taken by chat members and administrators in the last 48 hours. Available only for supergroups and channels. Requires administrator rights. Returns results in reverse chronological order (i. e., in order of decreasing event_id)

func (*Client) GetChatFilter

func (client *Client) GetChatFilter(req *GetChatFilterRequest) (*ChatFilter, error)

Returns information about a chat filter by its identifier

func (*Client) GetChatFilterDefaultIconName

func (client *Client) GetChatFilterDefaultIconName(req *GetChatFilterDefaultIconNameRequest) (*Text, error)

Returns default icon name for a filter. Can be called synchronously

func (*Client) GetChatHistory

func (client *Client) GetChatHistory(req *GetChatHistoryRequest) (*Messages, error)

Returns messages in a chat. The messages are returned in a reverse chronological order (i.e., in order of decreasing message_id). For optimal performance the number of returned messages is chosen by the library. This is an offline request if only_local is true

func (*Client) GetChatListsToAddChat

func (client *Client) GetChatListsToAddChat(req *GetChatListsToAddChatRequest) (*ChatLists, error)

Returns chat lists to which the chat can be added. This is an offline request

func (*Client) GetChatMember

func (client *Client) GetChatMember(req *GetChatMemberRequest) (*ChatMember, error)

Returns information about a single member of a chat

func (*Client) GetChatMessageByDate

func (client *Client) GetChatMessageByDate(req *GetChatMessageByDateRequest) (*Message, error)

Returns the last message sent in a chat no later than the specified date

func (*Client) GetChatMessageCount

func (client *Client) GetChatMessageCount(req *GetChatMessageCountRequest) (*Count, error)

Returns approximate number of messages of the specified type in the chat

func (*Client) GetChatNotificationSettingsExceptions

func (client *Client) GetChatNotificationSettingsExceptions(req *GetChatNotificationSettingsExceptionsRequest) (*Chats, error)

Returns list of chats with non-default notification settings

func (*Client) GetChatPinnedMessage

func (client *Client) GetChatPinnedMessage(req *GetChatPinnedMessageRequest) (*Message, error)

Returns information about a newest pinned message in the chat

func (*Client) GetChatScheduledMessages

func (client *Client) GetChatScheduledMessages(req *GetChatScheduledMessagesRequest) (*Messages, error)

Returns all scheduled messages in a chat. The messages are returned in a reverse chronological order (i.e., in order of decreasing message_id)

func (*Client) GetChatStatistics

func (client *Client) GetChatStatistics(req *GetChatStatisticsRequest) (ChatStatistics, error)

Returns detailed statistics about a chat. Currently this method can be used only for supergroups and channels. Can be used only if SupergroupFullInfo.can_get_statistics == true

func (*Client) GetChatStatisticsUrl

func (client *Client) GetChatStatisticsUrl(req *GetChatStatisticsUrlRequest) (*HttpUrl, error)

Returns an HTTP URL with the chat statistics. Currently this method of getting the statistics are disabled and can be deleted in the future

func (*Client) GetChats

func (client *Client) GetChats(req *GetChatsRequest) (*Chats, error)

Returns an ordered list of chats in a chat list. Chats are sorted by the pair (chat.position.order, chat.id) in descending order. (For example, to get a list of chats from the beginning, the offset_order should be equal to a biggest signed 64-bit number 9223372036854775807 == 2^63 - 1). For optimal performance the number of returned chats is chosen by the library

func (*Client) GetConnectedWebsites

func (client *Client) GetConnectedWebsites() (*ConnectedWebsites, error)

Returns all website where the current user used Telegram to log in

func (*Client) GetContacts

func (client *Client) GetContacts() (*Users, error)

Returns all user contacts

func (*Client) GetCountries

func (client *Client) GetCountries() (*Countries, error)

Returns information about existing countries. Can be called before authorization

func (*Client) GetCountryCode

func (client *Client) GetCountryCode() (*Text, error)

Uses current user IP address to find their country. Returns two-letter ISO 3166-1 alpha-2 country code. Can be called before authorization

func (*Client) GetCreatedPublicChats

func (client *Client) GetCreatedPublicChats(req *GetCreatedPublicChatsRequest) (*Chats, error)

Returns a list of public chats of the specified type, owned by the user

func (*Client) GetCurrentState

func (client *Client) GetCurrentState() (*Updates, error)

Returns all updates needed to restore current TDLib state, i.e. all actual UpdateAuthorizationState/UpdateUser/UpdateNewChat and others. This is especially useful if TDLib is run in a separate process. Can be called before initialization

func (*Client) GetDatabaseStatistics

func (client *Client) GetDatabaseStatistics() (*DatabaseStatistics, error)

Returns database statistics

func (*Client) GetDeepLinkInfo

func (client *Client) GetDeepLinkInfo(req *GetDeepLinkInfoRequest) (*DeepLinkInfo, error)

Returns information about a tg:// deep link. Use "tg://need_update_for_some_feature" or "tg:some_unsupported_feature" for testing. Returns a 404 error for unknown links. Can be called before authorization

func (*Client) GetEmojiSuggestionsUrl

func (client *Client) GetEmojiSuggestionsUrl(req *GetEmojiSuggestionsUrlRequest) (*HttpUrl, error)

Returns an HTTP URL which can be used to automatically log in to the translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation

func (*Client) GetFavoriteStickers

func (client *Client) GetFavoriteStickers() (*Stickers, error)

Returns favorite stickers

func (*Client) GetFile

func (client *Client) GetFile(req *GetFileRequest) (*File, error)

Returns information about a file; this is an offline request

func (*Client) GetFileDownloadedPrefixSize

func (client *Client) GetFileDownloadedPrefixSize(req *GetFileDownloadedPrefixSizeRequest) (*Count, error)

Returns file downloaded prefix size from a given offset

func (*Client) GetFileExtension

func (client *Client) GetFileExtension(req *GetFileExtensionRequest) (*Text, error)

Returns the extension of a file, guessed by its MIME type. Returns an empty string on failure. Can be called synchronously

func (*Client) GetFileMimeType

func (client *Client) GetFileMimeType(req *GetFileMimeTypeRequest) (*Text, error)

Returns the MIME type of a file, guessed by its extension. Returns an empty string on failure. Can be called synchronously

func (*Client) GetGameHighScores

func (client *Client) GetGameHighScores(req *GetGameHighScoresRequest) (*GameHighScores, error)

Returns the high scores for a game and some part of the high score table in the range of the specified user; for bots only

func (*Client) GetGroupsInCommon

func (client *Client) GetGroupsInCommon(req *GetGroupsInCommonRequest) (*Chats, error)

Returns a list of common group chats with a given user. Chats are sorted by their type and creation date

func (*Client) GetImportedContactCount

func (client *Client) GetImportedContactCount() (*Count, error)

Returns the total number of imported contacts

func (*Client) GetInactiveSupergroupChats

func (client *Client) GetInactiveSupergroupChats() (*Chats, error)

Returns a list of recently inactive supergroups and channels. Can be used when user reaches limit on the number of joined supergroups and channels and receives CHANNELS_TOO_MUCH error

func (*Client) GetInlineGameHighScores

func (client *Client) GetInlineGameHighScores(req *GetInlineGameHighScoresRequest) (*GameHighScores, error)

Returns game high scores and some part of the high score table in the range of the specified user; for bots only

func (*Client) GetInlineQueryResults

func (client *Client) GetInlineQueryResults(req *GetInlineQueryResultsRequest) (*InlineQueryResults, error)

Sends an inline query to a bot and returns its results. Returns an error with code 502 if the bot fails to answer the query before the query timeout expires

func (*Client) GetInstalledStickerSets

func (client *Client) GetInstalledStickerSets(req *GetInstalledStickerSetsRequest) (*StickerSets, error)

Returns a list of installed sticker sets

func (*Client) GetInviteText

func (client *Client) GetInviteText() (*Text, error)

Returns the default text for invitation messages to be used as a placeholder when the current user invites friends to Telegram

func (*Client) GetJsonString

func (client *Client) GetJsonString(req *GetJsonStringRequest) (*Text, error)

Converts a JsonValue object to corresponding JSON-serialized string. Can be called synchronously

func (*Client) GetJsonValue

func (client *Client) GetJsonValue(req *GetJsonValueRequest) (JsonValue, error)

Converts a JSON-serialized string to corresponding JsonValue object. Can be called synchronously

func (*Client) GetLanguagePackInfo

func (client *Client) GetLanguagePackInfo(req *GetLanguagePackInfoRequest) (*LanguagePackInfo, error)

Returns information about a language pack. Returned language pack identifier may be different from a provided one. Can be called before authorization

func (*Client) GetLanguagePackString

func (client *Client) GetLanguagePackString(req *GetLanguagePackStringRequest) (LanguagePackStringValue, error)

Returns a string stored in the local database from the specified localization target and language pack by its key. Returns a 404 error if the string is not found. Can be called synchronously

func (*Client) GetLanguagePackStrings

func (client *Client) GetLanguagePackStrings(req *GetLanguagePackStringsRequest) (*LanguagePackStrings, error)

Returns strings from a language pack in the current localization target by their keys. Can be called before authorization

func (*Client) GetListener

func (client *Client) GetListener() *Listener

func (*Client) GetLocalizationTargetInfo

func (client *Client) GetLocalizationTargetInfo(req *GetLocalizationTargetInfoRequest) (*LocalizationTargetInfo, error)

Returns information about the current localization target. This is an offline request if only_local is true. Can be called before authorization

func (*Client) GetLogStream

func (client *Client) GetLogStream() (LogStream, error)

Returns information about currently used log stream for internal logging of TDLib. Can be called synchronously

func (*Client) GetLogTagVerbosityLevel

func (client *Client) GetLogTagVerbosityLevel(req *GetLogTagVerbosityLevelRequest) (*LogVerbosityLevel, error)

Returns current verbosity level for a specified TDLib internal log tag. Can be called synchronously

func (*Client) GetLogTags

func (client *Client) GetLogTags() (*LogTags, error)

Returns list of available TDLib internal log tags, for example, ["actor", "binlog", "connections", "notifications", "proxy"]. Can be called synchronously

func (*Client) GetLogVerbosityLevel

func (client *Client) GetLogVerbosityLevel() (*LogVerbosityLevel, error)

Returns current verbosity level of the internal logging of TDLib. Can be called synchronously

func (*Client) GetLoginUrl

func (client *Client) GetLoginUrl(req *GetLoginUrlRequest) (*HttpUrl, error)

Returns an HTTP URL which can be used to automatically authorize the user on a website after clicking an inline button of type inlineKeyboardButtonTypeLoginUrl. Use the method getLoginUrlInfo to find whether a prior user confirmation is needed. If an error is returned, then the button must be handled as an ordinary URL button

func (*Client) GetLoginUrlInfo

func (client *Client) GetLoginUrlInfo(req *GetLoginUrlInfoRequest) (LoginUrlInfo, error)

Returns information about a button of type inlineKeyboardButtonTypeLoginUrl. The method needs to be called when the user presses the button

func (*Client) GetMapThumbnailFile

func (client *Client) GetMapThumbnailFile(req *GetMapThumbnailFileRequest) (*File, error)

Returns information about a file with a map thumbnail in PNG format. Only map thumbnail files with size less than 1MB can be downloaded

func (*Client) GetMarkdownText

func (client *Client) GetMarkdownText(req *GetMarkdownTextRequest) (*FormattedText, error)

Replaces text entities with Markdown formatting in a human-friendly format. Entities that can't be represented in Markdown unambiguously are kept as is. Can be called synchronously

func (*Client) GetMe

func (client *Client) GetMe() (*User, error)

Returns the current user

func (*Client) GetMessage

func (client *Client) GetMessage(req *GetMessageRequest) (*Message, error)

Returns information about a message

func (*Client) GetMessageEmbeddingCode

func (client *Client) GetMessageEmbeddingCode(req *GetMessageEmbeddingCodeRequest) (*Text, error)

Returns an HTML code for embedding the message. Available only for messages in supergroups and channels with a username

func (client *Client) GetMessageLink(req *GetMessageLinkRequest) (*MessageLink, error)

Returns an HTTPS link to a message in a chat. Available only for already sent messages in supergroups and channels. This is an offline request

func (*Client) GetMessageLinkInfo

func (client *Client) GetMessageLinkInfo(req *GetMessageLinkInfoRequest) (*MessageLinkInfo, error)

Returns information about a public or private message link

func (*Client) GetMessageLocally

func (client *Client) GetMessageLocally(req *GetMessageLocallyRequest) (*Message, error)

Returns information about a message, if it is available locally without sending network request. This is an offline request

func (*Client) GetMessagePublicForwards

func (client *Client) GetMessagePublicForwards(req *GetMessagePublicForwardsRequest) (*FoundMessages, error)

Returns forwarded copies of a channel message to different public channels. For optimal performance the number of returned messages is chosen by the library

func (*Client) GetMessageStatistics

func (client *Client) GetMessageStatistics(req *GetMessageStatisticsRequest) (*MessageStatistics, error)

Returns detailed statistics about a message. Can be used only if Message.can_get_statistics == true

func (*Client) GetMessageThread

func (client *Client) GetMessageThread(req *GetMessageThreadRequest) (*MessageThreadInfo, error)

Returns information about a message thread. Can be used only if message.can_get_message_thread == true

func (*Client) GetMessageThreadHistory

func (client *Client) GetMessageThreadHistory(req *GetMessageThreadHistoryRequest) (*Messages, error)

Returns messages in a message thread of a message. Can be used only if message.can_get_message_thread == true. Message thread of a channel message is in the channel's linked supergroup. The messages are returned in a reverse chronological order (i.e., in order of decreasing message_id). For optimal performance the number of returned messages is chosen by the library

func (*Client) GetMessages

func (client *Client) GetMessages(req *GetMessagesRequest) (*Messages, error)

Returns information about messages. If a message is not found, returns null on the corresponding position of the result

func (*Client) GetNetworkStatistics

func (client *Client) GetNetworkStatistics(req *GetNetworkStatisticsRequest) (*NetworkStatistics, error)

Returns network data usage statistics. Can be called before authorization

func (*Client) GetOption

func (client *Client) GetOption(req *GetOptionRequest) (OptionValue, error)

Returns the value of an option by its name. (Check the list of available options on https://core.telegram.org/tdlib/options.) Can be called before authorization

func (*Client) GetPassportAuthorizationForm

func (client *Client) GetPassportAuthorizationForm(req *GetPassportAuthorizationFormRequest) (*PassportAuthorizationForm, error)

Returns a Telegram Passport authorization form for sharing data with a service

func (*Client) GetPassportAuthorizationFormAvailableElements

func (client *Client) GetPassportAuthorizationFormAvailableElements(req *GetPassportAuthorizationFormAvailableElementsRequest) (*PassportElementsWithErrors, error)

Returns already available Telegram Passport elements suitable for completing a Telegram Passport authorization form. Result can be received only once for each authorization form

func (*Client) GetPassportElement

func (client *Client) GetPassportElement(req *GetPassportElementRequest) (PassportElement, error)

Returns one of the available Telegram Passport elements

func (*Client) GetPasswordState

func (client *Client) GetPasswordState() (*PasswordState, error)

Returns the current state of 2-step verification

func (*Client) GetPaymentForm

func (client *Client) GetPaymentForm(req *GetPaymentFormRequest) (*PaymentForm, error)

Returns an invoice payment form. This method should be called when the user presses inlineKeyboardButtonBuy

func (*Client) GetPaymentReceipt

func (client *Client) GetPaymentReceipt(req *GetPaymentReceiptRequest) (*PaymentReceipt, error)

Returns information about a successful payment

func (*Client) GetPhoneNumberInfo

func (client *Client) GetPhoneNumberInfo(req *GetPhoneNumberInfoRequest) (*PhoneNumberInfo, error)

Returns information about a phone number by its prefix. Can be called before authorization

func (*Client) GetPollVoters

func (client *Client) GetPollVoters(req *GetPollVotersRequest) (*Users, error)

Returns users voted for the specified option in a non-anonymous polls. For the optimal performance the number of returned users is chosen by the library

func (*Client) GetPreferredCountryLanguage

func (client *Client) GetPreferredCountryLanguage(req *GetPreferredCountryLanguageRequest) (*Text, error)

Returns an IETF language tag of the language preferred in the country, which should be used to fill native fields in Telegram Passport personal details. Returns a 404 error if unknown

func (*Client) GetProxies

func (client *Client) GetProxies() (*Proxies, error)

Returns list of proxies that are currently set up. Can be called before authorization

func (client *Client) GetProxyLink(req *GetProxyLinkRequest) (*Text, error)

Returns an HTTPS link, which can be used to add a proxy. Available only for SOCKS5 and MTProto proxies. Can be called before authorization

func (*Client) GetPushReceiverId

func (client *Client) GetPushReceiverId(req *GetPushReceiverIdRequest) (*PushReceiverId, error)

Returns a globally unique push notification subscription identifier for identification of an account, which has received a push notification. Can be called synchronously

func (*Client) GetRecentInlineBots

func (client *Client) GetRecentInlineBots() (*Users, error)

Returns up to 20 recently used inline bots in the order of their last usage

func (*Client) GetRecentStickers

func (client *Client) GetRecentStickers(req *GetRecentStickersRequest) (*Stickers, error)

Returns a list of recently used stickers

func (*Client) GetRecentlyVisitedTMeUrls

func (client *Client) GetRecentlyVisitedTMeUrls(req *GetRecentlyVisitedTMeUrlsRequest) (*TMeUrls, error)

Returns t.me URLs recently visited by a newly registered user

func (*Client) GetRecommendedChatFilters

func (client *Client) GetRecommendedChatFilters() (*RecommendedChatFilters, error)

Returns recommended chat filters for the current user

func (*Client) GetRecoveryEmailAddress

func (client *Client) GetRecoveryEmailAddress(req *GetRecoveryEmailAddressRequest) (*RecoveryEmailAddress, error)

Returns a 2-step verification recovery email address that was previously set up. This method can be used to verify a password provided by the user

func (*Client) GetRemoteFile

func (client *Client) GetRemoteFile(req *GetRemoteFileRequest) (*File, error)

Returns information about a file by its remote ID; this is an offline request. Can be used to register a URL as a file for further uploading, or sending as a message. Even the request succeeds, the file can be used only if it is still accessible to the user. For example, if the file is from a message, then the message must be not deleted and accessible to the user. If the file database is disabled, then the corresponding object with the file must be preloaded by the application

func (*Client) GetRepliedMessage

func (client *Client) GetRepliedMessage(req *GetRepliedMessageRequest) (*Message, error)

Returns information about a message that is replied by a given message. Also returns the pinned message, the game message, and the invoice message for messages of the types messagePinMessage, messageGameScore, and messagePaymentSuccessful respectively

func (*Client) GetSavedAnimations

func (client *Client) GetSavedAnimations() (*Animations, error)

Returns saved animations

func (*Client) GetSavedOrderInfo

func (client *Client) GetSavedOrderInfo() (*OrderInfo, error)

Returns saved order info, if any

func (*Client) GetScopeNotificationSettings

func (client *Client) GetScopeNotificationSettings(req *GetScopeNotificationSettingsRequest) (*ScopeNotificationSettings, error)

Returns the notification settings for chats of a given type

func (*Client) GetSecretChat

func (client *Client) GetSecretChat(req *GetSecretChatRequest) (*SecretChat, error)

Returns information about a secret chat by its identifier. This is an offline request

func (*Client) GetStatisticalGraph

func (client *Client) GetStatisticalGraph(req *GetStatisticalGraphRequest) (StatisticalGraph, error)

Loads an asynchronous or a zoomed in statistical graph

func (*Client) GetStickerEmojis

func (client *Client) GetStickerEmojis(req *GetStickerEmojisRequest) (*Emojis, error)

Returns emoji corresponding to a sticker. The list is only for informational purposes, because a sticker is always sent with a fixed emoji from the corresponding Sticker object

func (*Client) GetStickerSet

func (client *Client) GetStickerSet(req *GetStickerSetRequest) (*StickerSet, error)

Returns information about a sticker set by its identifier

func (*Client) GetStickers

func (client *Client) GetStickers(req *GetStickersRequest) (*Stickers, error)

Returns stickers from the installed sticker sets that correspond to a given emoji. If the emoji is not empty, favorite and recently used stickers may also be returned

func (*Client) GetStorageStatistics

func (client *Client) GetStorageStatistics(req *GetStorageStatisticsRequest) (*StorageStatistics, error)

Returns storage usage statistics. Can be called before authorization

func (*Client) GetStorageStatisticsFast

func (client *Client) GetStorageStatisticsFast() (*StorageStatisticsFast, error)

Quickly returns approximate storage usage statistics. Can be called before authorization

func (*Client) GetSuitableDiscussionChats

func (client *Client) GetSuitableDiscussionChats() (*Chats, error)

Returns a list of basic group and supergroup chats, which can be used as a discussion group for a channel. Returned basic group chats must be first upgraded to supergroups before they can be set as a discussion group. To set a returned supergroup as a discussion group, access to its old messages must be enabled using toggleSupergroupIsAllHistoryAvailable first

func (*Client) GetSupergroup

func (client *Client) GetSupergroup(req *GetSupergroupRequest) (*Supergroup, error)

Returns information about a supergroup or a channel by its identifier. This is an offline request if the current user is not a bot

func (*Client) GetSupergroupFullInfo

func (client *Client) GetSupergroupFullInfo(req *GetSupergroupFullInfoRequest) (*SupergroupFullInfo, error)

Returns full information about a supergroup or a channel by its identifier, cached for up to 1 minute

func (*Client) GetSupergroupMembers

func (client *Client) GetSupergroupMembers(req *GetSupergroupMembersRequest) (*ChatMembers, error)

Returns information about members or banned users in a supergroup or channel. Can be used only if SupergroupFullInfo.can_get_members == true; additionally, administrator privileges may be required for some filters

func (*Client) GetSupportUser

func (client *Client) GetSupportUser() (*User, error)

Returns a user that can be contacted to get support

func (*Client) GetTemporaryPasswordState

func (client *Client) GetTemporaryPasswordState() (*TemporaryPasswordState, error)

Returns information about the current temporary password

func (*Client) GetTextEntities

func (client *Client) GetTextEntities(req *GetTextEntitiesRequest) (*TextEntities, error)

Returns all entities (mentions, hashtags, cashtags, bot commands, bank card numbers, URLs, and email addresses) contained in the text. Can be called synchronously

func (*Client) GetTopChats

func (client *Client) GetTopChats(req *GetTopChatsRequest) (*Chats, error)

Returns a list of frequently used chats. Supported only if the chat info database is enabled

func (*Client) GetTrendingStickerSets

func (client *Client) GetTrendingStickerSets(req *GetTrendingStickerSetsRequest) (*StickerSets, error)

Returns a list of trending sticker sets. For the optimal performance the number of returned sticker sets is chosen by the library

func (*Client) GetUser

func (client *Client) GetUser(req *GetUserRequest) (*User, error)

Returns information about a user by their identifier. This is an offline request if the current user is not a bot

func (*Client) GetUserFullInfo

func (client *Client) GetUserFullInfo(req *GetUserFullInfoRequest) (*UserFullInfo, error)

Returns full information about a user by their identifier

func (*Client) GetUserPrivacySettingRules

func (client *Client) GetUserPrivacySettingRules(req *GetUserPrivacySettingRulesRequest) (*UserPrivacySettingRules, error)

Returns the current privacy settings

func (*Client) GetUserProfilePhotos

func (client *Client) GetUserProfilePhotos(req *GetUserProfilePhotosRequest) (*ChatPhotos, error)

Returns the profile photos of a user. The result of this query may be outdated: some photos might have been deleted already

func (*Client) GetWebPageInstantView

func (client *Client) GetWebPageInstantView(req *GetWebPageInstantViewRequest) (*WebPageInstantView, error)

Returns an instant view version of a web page if available. Returns a 404 error if the web page has no instant view page

func (*Client) GetWebPagePreview

func (client *Client) GetWebPagePreview(req *GetWebPagePreviewRequest) (*WebPage, error)

Returns a web page preview by the text of the message. Do not call this function too often. Returns a 404 error if the web page has no preview

func (*Client) HideSuggestedAction

func (client *Client) HideSuggestedAction(req *HideSuggestedActionRequest) (*Ok, error)

Hides a suggested action

func (*Client) ImportContacts

func (client *Client) ImportContacts(req *ImportContactsRequest) (*ImportedContacts, error)

Adds new contacts or edits existing contacts by their phone numbers; contacts' user identifiers are ignored

func (*Client) JoinChat

func (client *Client) JoinChat(req *JoinChatRequest) (*Ok, error)

Adds current user as a new member to a chat. Private and secret chats can't be joined using this method

func (client *Client) JoinChatByInviteLink(req *JoinChatByInviteLinkRequest) (*Chat, error)

Uses an invite link to add the current user to the chat if possible. The new member will not be added until the chat state has been synchronized with the server

func (*Client) LeaveChat

func (client *Client) LeaveChat(req *LeaveChatRequest) (*Ok, error)

Removes current user from chat members. Private and secret chats can't be left using this method

func (*Client) LogOut

func (client *Client) LogOut() (*Ok, error)

Closes the TDLib instance after a proper logout. Requires an available network connection. All local data will be destroyed. After the logout completes, updateAuthorizationState with authorizationStateClosed will be sent

func (*Client) OpenChat

func (client *Client) OpenChat(req *OpenChatRequest) (*Ok, error)

Informs TDLib that the chat is opened by the user. Many useful activities depend on the chat being opened or closed (e.g., in supergroups and channels all updates are received only for opened chats)

func (*Client) OpenMessageContent

func (client *Client) OpenMessageContent(req *OpenMessageContentRequest) (*Ok, error)

Informs TDLib that the message content has been opened (e.g., the user has opened a photo, video, document, location or venue, or has listened to an audio file or voice note message). An updateMessageContentOpened update will be generated if something has changed

func (*Client) OptimizeStorage

func (client *Client) OptimizeStorage(req *OptimizeStorageRequest) (*StorageStatistics, error)

Optimizes storage usage, i.e. deletes some files and returns new storage usage statistics. Secret thumbnails can't be deleted

func (*Client) ParseMarkdown

func (client *Client) ParseMarkdown(req *ParseMarkdownRequest) (*FormattedText, error)

Parses Markdown entities in a human-friendly format, ignoring markup errors. Can be called synchronously

func (*Client) ParseTextEntities

func (client *Client) ParseTextEntities(req *ParseTextEntitiesRequest) (*FormattedText, error)

Parses Bold, Italic, Underline, Strikethrough, Code, Pre, PreCode, TextUrl and MentionName entities contained in the text. Can be called synchronously

func (*Client) PinChatMessage

func (client *Client) PinChatMessage(req *PinChatMessageRequest) (*Ok, error)

Pins a message in a chat; requires can_pin_messages rights or can_edit_messages rights in the channel

func (*Client) PingProxy

func (client *Client) PingProxy(req *PingProxyRequest) (*Seconds, error)

Computes time needed to receive a response from a Telegram server through a proxy. Can be called before authorization

func (*Client) ProcessPushNotification

func (client *Client) ProcessPushNotification(req *ProcessPushNotificationRequest) (*Ok, error)

Handles a push notification. Returns error with code 406 if the push notification is not supported and connection to the server is required to fetch new data. Can be called before authorization

func (*Client) ReadAllChatMentions

func (client *Client) ReadAllChatMentions(req *ReadAllChatMentionsRequest) (*Ok, error)

Marks all mentions in a chat as read

func (*Client) ReadFilePart

func (client *Client) ReadFilePart(req *ReadFilePartRequest) (*FilePart, error)

Reads a part of a file from the TDLib file cache and returns read bytes. This method is intended to be used only if the application has no direct access to TDLib's file system, because it is usually slower than a direct read from the file

func (*Client) RecoverAuthenticationPassword

func (client *Client) RecoverAuthenticationPassword(req *RecoverAuthenticationPasswordRequest) (*Ok, error)

Recovers the password with a password recovery code sent to an email address that was previously set up. Works only when the current authorization state is authorizationStateWaitPassword

func (*Client) RecoverPassword

func (client *Client) RecoverPassword(req *RecoverPasswordRequest) (*PasswordState, error)

Recovers the password using a recovery code sent to an email address that was previously set up

func (*Client) RegisterDevice

func (client *Client) RegisterDevice(req *RegisterDeviceRequest) (*PushReceiverId, error)

Registers the currently used device for receiving push notifications. Returns a globally unique identifier of the push notification subscription

func (*Client) RegisterUser

func (client *Client) RegisterUser(req *RegisterUserRequest) (*Ok, error)

Finishes user registration. Works only when the current authorization state is authorizationStateWaitRegistration

func (*Client) RemoveBackground

func (client *Client) RemoveBackground(req *RemoveBackgroundRequest) (*Ok, error)

Removes background from the list of installed backgrounds

func (*Client) RemoveChatActionBar

func (client *Client) RemoveChatActionBar(req *RemoveChatActionBarRequest) (*Ok, error)

Removes a chat action bar without any other action

func (*Client) RemoveContacts

func (client *Client) RemoveContacts(req *RemoveContactsRequest) (*Ok, error)

Removes users from the contact list

func (*Client) RemoveFavoriteSticker

func (client *Client) RemoveFavoriteSticker(req *RemoveFavoriteStickerRequest) (*Ok, error)

Removes a sticker from the list of favorite stickers

func (*Client) RemoveNotification

func (client *Client) RemoveNotification(req *RemoveNotificationRequest) (*Ok, error)

Removes an active notification from notification list. Needs to be called only if the notification is removed by the current user

func (*Client) RemoveNotificationGroup

func (client *Client) RemoveNotificationGroup(req *RemoveNotificationGroupRequest) (*Ok, error)

Removes a group of active notifications. Needs to be called only if the notification group is removed by the current user

func (*Client) RemoveProxy

func (client *Client) RemoveProxy(req *RemoveProxyRequest) (*Ok, error)

Removes a proxy server. Can be called before authorization

func (*Client) RemoveRecentHashtag

func (client *Client) RemoveRecentHashtag(req *RemoveRecentHashtagRequest) (*Ok, error)

Removes a hashtag from the list of recently used hashtags

func (*Client) RemoveRecentSticker

func (client *Client) RemoveRecentSticker(req *RemoveRecentStickerRequest) (*Ok, error)

Removes a sticker from the list of recently used stickers

func (*Client) RemoveRecentlyFoundChat

func (client *Client) RemoveRecentlyFoundChat(req *RemoveRecentlyFoundChatRequest) (*Ok, error)

Removes a chat from the list of recently found chats

func (*Client) RemoveSavedAnimation

func (client *Client) RemoveSavedAnimation(req *RemoveSavedAnimationRequest) (*Ok, error)

Removes an animation from the list of saved animations

func (*Client) RemoveStickerFromSet

func (client *Client) RemoveStickerFromSet(req *RemoveStickerFromSetRequest) (*Ok, error)

Removes a sticker from the set to which it belongs; for bots only. The sticker set must have been created by the bot

func (*Client) RemoveTopChat

func (client *Client) RemoveTopChat(req *RemoveTopChatRequest) (*Ok, error)

Removes a chat from the list of frequently used chats. Supported only if the chat info database is enabled

func (*Client) ReorderChatFilters

func (client *Client) ReorderChatFilters(req *ReorderChatFiltersRequest) (*Ok, error)

Changes the order of chat filters

func (*Client) ReorderInstalledStickerSets

func (client *Client) ReorderInstalledStickerSets(req *ReorderInstalledStickerSetsRequest) (*Ok, error)

Changes the order of installed sticker sets

func (*Client) ReportChat

func (client *Client) ReportChat(req *ReportChatRequest) (*Ok, error)

Reports a chat to the Telegram moderators. A chat can be reported only from the chat action bar, or if this is a private chats with a bot, a private chat with a user sharing their location, a supergroup, or a channel, since other chats can't be checked by moderators

func (*Client) ReportSupergroupSpam

func (client *Client) ReportSupergroupSpam(req *ReportSupergroupSpamRequest) (*Ok, error)

Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup

func (*Client) RequestAuthenticationPasswordRecovery

func (client *Client) RequestAuthenticationPasswordRecovery() (*Ok, error)

Requests to send a password recovery code to an email address that was previously set up. Works only when the current authorization state is authorizationStateWaitPassword

func (*Client) RequestPasswordRecovery

func (client *Client) RequestPasswordRecovery() (*EmailAddressAuthenticationCodeInfo, error)

Requests to send a password recovery code to an email address that was previously set up

func (*Client) RequestQrCodeAuthentication

func (client *Client) RequestQrCodeAuthentication(req *RequestQrCodeAuthenticationRequest) (*Ok, error)

Requests QR code authentication by scanning a QR code on another logged in device. Works only when the current authorization state is authorizationStateWaitPhoneNumber, or if there is no pending authentication query and the current authorization state is authorizationStateWaitCode, authorizationStateWaitRegistration, or authorizationStateWaitPassword

func (*Client) ResendAuthenticationCode

func (client *Client) ResendAuthenticationCode() (*Ok, error)

Re-sends an authentication code to the user. Works only when the current authorization state is authorizationStateWaitCode and the next_code_type of the result is not null

func (*Client) ResendChangePhoneNumberCode

func (client *Client) ResendChangePhoneNumberCode() (*AuthenticationCodeInfo, error)

Re-sends the authentication code sent to confirm a new phone number for the user. Works only if the previously received authenticationCodeInfo next_code_type was not null

func (*Client) ResendEmailAddressVerificationCode

func (client *Client) ResendEmailAddressVerificationCode() (*EmailAddressAuthenticationCodeInfo, error)

Re-sends the code to verify an email address to be added to a user's Telegram Passport

func (*Client) ResendMessages

func (client *Client) ResendMessages(req *ResendMessagesRequest) (*Messages, error)

Resends messages which failed to send. Can be called only for messages for which messageSendingStateFailed.can_retry is true and after specified in messageSendingStateFailed.retry_after time passed. If a message is re-sent, the corresponding failed to send message is deleted. Returns the sent messages in the same order as the message identifiers passed in message_ids. If a message can't be re-sent, null will be returned instead of the message

func (*Client) ResendPhoneNumberConfirmationCode

func (client *Client) ResendPhoneNumberConfirmationCode() (*AuthenticationCodeInfo, error)

Resends phone number confirmation code

func (*Client) ResendPhoneNumberVerificationCode

func (client *Client) ResendPhoneNumberVerificationCode() (*AuthenticationCodeInfo, error)

Re-sends the code to verify a phone number to be added to a user's Telegram Passport

func (*Client) ResendRecoveryEmailAddressCode

func (client *Client) ResendRecoveryEmailAddressCode() (*PasswordState, error)

Resends the 2-step verification recovery email address verification code

func (*Client) ResetAllNotificationSettings

func (client *Client) ResetAllNotificationSettings() (*Ok, error)

Resets all notification settings to their default values. By default, all chats are unmuted, the sound is set to "default" and message previews are shown

func (*Client) ResetBackgrounds

func (client *Client) ResetBackgrounds() (*Ok, error)

Resets list of installed backgrounds to its default value

func (*Client) ResetNetworkStatistics

func (client *Client) ResetNetworkStatistics() (*Ok, error)

Resets all network data usage statistics to zero. Can be called before authorization

func (*Client) SaveApplicationLogEvent

func (client *Client) SaveApplicationLogEvent(req *SaveApplicationLogEventRequest) (*Ok, error)

Saves application log event on the server. Can be called before authorization

func (*Client) SearchBackground

func (client *Client) SearchBackground(req *SearchBackgroundRequest) (*Background, error)

Searches for a background by its name

func (*Client) SearchCallMessages

func (client *Client) SearchCallMessages(req *SearchCallMessagesRequest) (*Messages, error)

Searches for call messages. Returns the results in reverse chronological order (i. e., in order of decreasing message_id). For optimal performance the number of returned messages is chosen by the library

func (*Client) SearchChatMembers

func (client *Client) SearchChatMembers(req *SearchChatMembersRequest) (*ChatMembers, error)

Searches for a specified query in the first name, last name and username of the members of a specified chat. Requires administrator rights in channels

func (*Client) SearchChatMessages

func (client *Client) SearchChatMessages(req *SearchChatMessagesRequest) (*Messages, error)

Searches for messages with given words in the chat. Returns the results in reverse chronological order, i.e. in order of decreasing message_id. Cannot be used in secret chats with a non-empty query (searchSecretMessages should be used instead), or without an enabled message database. For optimal performance the number of returned messages is chosen by the library

func (*Client) SearchChatRecentLocationMessages

func (client *Client) SearchChatRecentLocationMessages(req *SearchChatRecentLocationMessagesRequest) (*Messages, error)

Returns information about the recent locations of chat members that were sent to the chat. Returns up to 1 location message per user

func (*Client) SearchChats

func (client *Client) SearchChats(req *SearchChatsRequest) (*Chats, error)

Searches for the specified query in the title and username of already known chats, this is an offline request. Returns chats in the order seen in the main chat list

func (*Client) SearchChatsNearby

func (client *Client) SearchChatsNearby(req *SearchChatsNearbyRequest) (*ChatsNearby, error)

Returns a list of users and location-based supergroups nearby. The list of users nearby will be updated for 60 seconds after the request by the updates updateUsersNearby. The request should be sent again every 25 seconds with adjusted location to not miss new chats

func (*Client) SearchChatsOnServer

func (client *Client) SearchChatsOnServer(req *SearchChatsOnServerRequest) (*Chats, error)

Searches for the specified query in the title and username of already known chats via request to the server. Returns chats in the order seen in the main chat list

func (*Client) SearchContacts

func (client *Client) SearchContacts(req *SearchContactsRequest) (*Users, error)

Searches for the specified query in the first names, last names and usernames of the known user contacts

func (*Client) SearchEmojis

func (client *Client) SearchEmojis(req *SearchEmojisRequest) (*Emojis, error)

Searches for emojis by keywords. Supported only if the file database is enabled

func (*Client) SearchHashtags

func (client *Client) SearchHashtags(req *SearchHashtagsRequest) (*Hashtags, error)

Searches for recently used hashtags by their prefix

func (*Client) SearchInstalledStickerSets

func (client *Client) SearchInstalledStickerSets(req *SearchInstalledStickerSetsRequest) (*StickerSets, error)

Searches for installed sticker sets by looking for specified query in their title and name

func (*Client) SearchMessages

func (client *Client) SearchMessages(req *SearchMessagesRequest) (*Messages, error)

Searches for messages in all chats except secret chats. Returns the results in reverse chronological order (i.e., in order of decreasing (date, chat_id, message_id)). For optimal performance the number of returned messages is chosen by the library

func (*Client) SearchPublicChat

func (client *Client) SearchPublicChat(req *SearchPublicChatRequest) (*Chat, error)

Searches a public chat by its username. Currently only private chats, supergroups and channels can be public. Returns the chat if found; otherwise an error is returned

func (*Client) SearchPublicChats

func (client *Client) SearchPublicChats(req *SearchPublicChatsRequest) (*Chats, error)

Searches public chats by looking for specified query in their username and title. Currently only private chats, supergroups and channels can be public. Returns a meaningful number of results. Returns nothing if the length of the searched username prefix is less than 5. Excludes private chats with contacts and chats from the chat list from the results

func (*Client) SearchSecretMessages

func (client *Client) SearchSecretMessages(req *SearchSecretMessagesRequest) (*FoundMessages, error)

Searches for messages in secret chats. Returns the results in reverse chronological order. For optimal performance the number of returned messages is chosen by the library

func (*Client) SearchStickerSet

func (client *Client) SearchStickerSet(req *SearchStickerSetRequest) (*StickerSet, error)

Searches for a sticker set by its name

func (*Client) SearchStickerSets

func (client *Client) SearchStickerSets(req *SearchStickerSetsRequest) (*StickerSets, error)

Searches for ordinary sticker sets by looking for specified query in their title and name. Excludes installed sticker sets from the results

func (*Client) SearchStickers

func (client *Client) SearchStickers(req *SearchStickersRequest) (*Stickers, error)

Searches for stickers from public sticker sets that correspond to a given emoji

func (*Client) Send

func (client *Client) Send(req Request) (*Response, error)

func (*Client) SendBotStartMessage

func (client *Client) SendBotStartMessage(req *SendBotStartMessageRequest) (*Message, error)

Invites a bot to a chat (if it is not yet a member) and sends it the /start command. Bots can't be invited to a private chat other than the chat with the bot. Bots can't be invited to channels (although they can be added as admins) and secret chats. Returns the sent message

func (*Client) SendCallDebugInformation

func (client *Client) SendCallDebugInformation(req *SendCallDebugInformationRequest) (*Ok, error)

Sends debug information for a call

func (*Client) SendCallRating

func (client *Client) SendCallRating(req *SendCallRatingRequest) (*Ok, error)

Sends a call rating

func (*Client) SendCallSignalingData

func (client *Client) SendCallSignalingData(req *SendCallSignalingDataRequest) (*Ok, error)

Sends call signaling data

func (*Client) SendChatAction

func (client *Client) SendChatAction(req *SendChatActionRequest) (*Ok, error)

Sends a notification about user activity in a chat

func (*Client) SendChatScreenshotTakenNotification

func (client *Client) SendChatScreenshotTakenNotification(req *SendChatScreenshotTakenNotificationRequest) (*Ok, error)

Sends a notification about a screenshot taken in a chat. Supported only in private and secret chats

func (*Client) SendChatSetTtlMessage

func (client *Client) SendChatSetTtlMessage(req *SendChatSetTtlMessageRequest) (*Message, error)

Changes the current TTL setting (sets a new self-destruct timer) in a secret chat and sends the corresponding message

func (*Client) SendCustomRequest

func (client *Client) SendCustomRequest(req *SendCustomRequestRequest) (*CustomRequestResult, error)

Sends a custom request; for bots only

func (*Client) SendEmailAddressVerificationCode

func (client *Client) SendEmailAddressVerificationCode(req *SendEmailAddressVerificationCodeRequest) (*EmailAddressAuthenticationCodeInfo, error)

Sends a code to verify an email address to be added to a user's Telegram Passport

func (*Client) SendInlineQueryResultMessage

func (client *Client) SendInlineQueryResultMessage(req *SendInlineQueryResultMessageRequest) (*Message, error)

Sends the result of an inline query as a message. Returns the sent message. Always clears a chat draft message

func (*Client) SendMessage

func (client *Client) SendMessage(req *SendMessageRequest) (*Message, error)

Sends a message. Returns the sent message

func (*Client) SendMessageAlbum

func (client *Client) SendMessageAlbum(req *SendMessageAlbumRequest) (*Messages, error)

Sends messages grouped together into an album. Currently only audio, document, photo and video messages can be grouped into an album. Documents and audio files can be only grouped in an album with messages of the same type. Returns sent messages

func (*Client) SendPassportAuthorizationForm

func (client *Client) SendPassportAuthorizationForm(req *SendPassportAuthorizationFormRequest) (*Ok, error)

Sends a Telegram Passport authorization form, effectively sharing data with the service. This method must be called after getPassportAuthorizationFormAvailableElements if some previously available elements are going to be reused

func (*Client) SendPaymentForm

func (client *Client) SendPaymentForm(req *SendPaymentFormRequest) (*PaymentResult, error)

Sends a filled-out payment form to the bot for final verification

func (*Client) SendPhoneNumberConfirmationCode

func (client *Client) SendPhoneNumberConfirmationCode(req *SendPhoneNumberConfirmationCodeRequest) (*AuthenticationCodeInfo, error)

Sends phone number confirmation code. Should be called when user presses "https://t.me/confirmphone?phone=*******&hash=**********" or "tg://confirmphone?phone=*******&hash=**********" link

func (*Client) SendPhoneNumberVerificationCode

func (client *Client) SendPhoneNumberVerificationCode(req *SendPhoneNumberVerificationCodeRequest) (*AuthenticationCodeInfo, error)

Sends a code to verify a phone number to be added to a user's Telegram Passport

func (*Client) SetAccountTtl

func (client *Client) SetAccountTtl(req *SetAccountTtlRequest) (*Ok, error)

Changes the period of inactivity after which the account of the current user will automatically be deleted

func (*Client) SetAlarm

func (client *Client) SetAlarm(req *SetAlarmRequest) (*Ok, error)

Succeeds after a specified amount of time has passed. Can be called before initialization

func (*Client) SetAuthenticationPhoneNumber

func (client *Client) SetAuthenticationPhoneNumber(req *SetAuthenticationPhoneNumberRequest) (*Ok, error)

Sets the phone number of the user and sends an authentication code to the user. Works only when the current authorization state is authorizationStateWaitPhoneNumber, or if there is no pending authentication query and the current authorization state is authorizationStateWaitCode, authorizationStateWaitRegistration, or authorizationStateWaitPassword

func (*Client) SetAutoDownloadSettings

func (client *Client) SetAutoDownloadSettings(req *SetAutoDownloadSettingsRequest) (*Ok, error)

Sets auto-download settings

func (*Client) SetBackground

func (client *Client) SetBackground(req *SetBackgroundRequest) (*Background, error)

Changes the background selected by the user; adds background to the list of installed backgrounds

func (*Client) SetBio

func (client *Client) SetBio(req *SetBioRequest) (*Ok, error)

Changes the bio of the current user

func (*Client) SetBotUpdatesStatus

func (client *Client) SetBotUpdatesStatus(req *SetBotUpdatesStatusRequest) (*Ok, error)

Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only

func (*Client) SetChatClientData

func (client *Client) SetChatClientData(req *SetChatClientDataRequest) (*Ok, error)

Changes application-specific data associated with a chat

func (*Client) SetChatDescription

func (client *Client) SetChatDescription(req *SetChatDescriptionRequest) (*Ok, error)

Changes information about a chat. Available for basic groups, supergroups, and channels. Requires can_change_info rights

func (*Client) SetChatDiscussionGroup

func (client *Client) SetChatDiscussionGroup(req *SetChatDiscussionGroupRequest) (*Ok, error)

Changes the discussion group of a channel chat; requires can_change_info rights in the channel if it is specified

func (*Client) SetChatDraftMessage

func (client *Client) SetChatDraftMessage(req *SetChatDraftMessageRequest) (*Ok, error)

Changes the draft message in a chat

func (*Client) SetChatLocation

func (client *Client) SetChatLocation(req *SetChatLocationRequest) (*Ok, error)

Changes the location of a chat. Available only for some location-based supergroups, use supergroupFullInfo.can_set_location to check whether the method is allowed to use

func (*Client) SetChatMemberStatus

func (client *Client) SetChatMemberStatus(req *SetChatMemberStatusRequest) (*Ok, error)

Changes the status of a chat member, needs appropriate privileges. This function is currently not suitable for adding new members to the chat and transferring chat ownership; instead, use addChatMember or transferChatOwnership. The chat member status will not be changed until it has been synchronized with the server

func (*Client) SetChatNotificationSettings

func (client *Client) SetChatNotificationSettings(req *SetChatNotificationSettingsRequest) (*Ok, error)

Changes the notification settings of a chat. Notification settings of a chat with the current user (Saved Messages) can't be changed

func (*Client) SetChatPermissions

func (client *Client) SetChatPermissions(req *SetChatPermissionsRequest) (*Ok, error)

Changes the chat members permissions. Supported only for basic groups and supergroups. Requires can_restrict_members administrator right

func (*Client) SetChatPhoto

func (client *Client) SetChatPhoto(req *SetChatPhotoRequest) (*Ok, error)

Changes the photo of a chat. Supported only for basic groups, supergroups and channels. Requires can_change_info rights

func (*Client) SetChatSlowModeDelay

func (client *Client) SetChatSlowModeDelay(req *SetChatSlowModeDelayRequest) (*Ok, error)

Changes the slow mode delay of a chat. Available only for supergroups; requires can_restrict_members rights

func (*Client) SetChatTitle

func (client *Client) SetChatTitle(req *SetChatTitleRequest) (*Ok, error)

Changes the chat title. Supported only for basic groups, supergroups and channels. Requires can_change_info rights

func (*Client) SetCommands

func (client *Client) SetCommands(req *SetCommandsRequest) (*Ok, error)

Sets the list of commands supported by the bot; for bots only

func (*Client) SetCustomLanguagePack

func (client *Client) SetCustomLanguagePack(req *SetCustomLanguagePackRequest) (*Ok, error)

Adds or changes a custom local language pack to the current localization target

func (*Client) SetCustomLanguagePackString

func (client *Client) SetCustomLanguagePackString(req *SetCustomLanguagePackStringRequest) (*Ok, error)

Adds, edits or deletes a string in a custom local language pack. Can be called before authorization

func (*Client) SetDatabaseEncryptionKey

func (client *Client) SetDatabaseEncryptionKey(req *SetDatabaseEncryptionKeyRequest) (*Ok, error)

Changes the database encryption key. Usually the encryption key is never changed and is stored in some OS keychain

func (*Client) SetFileGenerationProgress

func (client *Client) SetFileGenerationProgress(req *SetFileGenerationProgressRequest) (*Ok, error)

Informs TDLib on a file generation progress

func (*Client) SetGameScore

func (client *Client) SetGameScore(req *SetGameScoreRequest) (*Message, error)

Updates the game score of the specified user in the game; for bots only

func (*Client) SetInlineGameScore

func (client *Client) SetInlineGameScore(req *SetInlineGameScoreRequest) (*Ok, error)

Updates the game score of the specified user in a game; for bots only

func (*Client) SetLocation

func (client *Client) SetLocation(req *SetLocationRequest) (*Ok, error)

Changes the location of the current user. Needs to be called if GetOption("is_location_visible") is true and location changes for more than 1 kilometer

func (*Client) SetLogStream

func (client *Client) SetLogStream(req *SetLogStreamRequest) (*Ok, error)

Sets new log stream for internal logging of TDLib. Can be called synchronously

func (*Client) SetLogTagVerbosityLevel

func (client *Client) SetLogTagVerbosityLevel(req *SetLogTagVerbosityLevelRequest) (*Ok, error)

Sets the verbosity level for a specified TDLib internal log tag. Can be called synchronously

func (*Client) SetLogVerbosityLevel

func (client *Client) SetLogVerbosityLevel(req *SetLogVerbosityLevelRequest) (*Ok, error)

Sets the verbosity level of the internal logging of TDLib. Can be called synchronously

func (*Client) SetName

func (client *Client) SetName(req *SetNameRequest) (*Ok, error)

Changes the first and last name of the current user

func (*Client) SetNetworkType

func (client *Client) SetNetworkType(req *SetNetworkTypeRequest) (*Ok, error)

Sets the current network type. Can be called before authorization. Calling this method forces all network connections to reopen, mitigating the delay in switching between different networks, so it should be called whenever the network is changed, even if the network type remains the same. Network type is used to check whether the library can use the network at all and also for collecting detailed network data usage statistics

func (*Client) SetOption

func (client *Client) SetOption(req *SetOptionRequest) (*Ok, error)

Sets the value of an option. (Check the list of available options on https://core.telegram.org/tdlib/options.) Only writable options can be set. Can be called before authorization

func (*Client) SetPassportElement

func (client *Client) SetPassportElement(req *SetPassportElementRequest) (PassportElement, error)

Adds an element to the user's Telegram Passport. May return an error with a message "PHONE_VERIFICATION_NEEDED" or "EMAIL_VERIFICATION_NEEDED" if the chosen phone number or the chosen email address must be verified first

func (*Client) SetPassportElementErrors

func (client *Client) SetPassportElementErrors(req *SetPassportElementErrorsRequest) (*Ok, error)

Informs the user that some of the elements in their Telegram Passport contain errors; for bots only. The user will not be able to resend the elements, until the errors are fixed

func (*Client) SetPassword

func (client *Client) SetPassword(req *SetPasswordRequest) (*PasswordState, error)

Changes the password for the user. If a new recovery email address is specified, then the change will not be applied until the new recovery email address is confirmed

func (*Client) SetPinnedChats

func (client *Client) SetPinnedChats(req *SetPinnedChatsRequest) (*Ok, error)

Changes the order of pinned chats

func (*Client) SetPollAnswer

func (client *Client) SetPollAnswer(req *SetPollAnswerRequest) (*Ok, error)

Changes the user answer to a poll. A poll in quiz mode can be answered only once

func (*Client) SetProfilePhoto

func (client *Client) SetProfilePhoto(req *SetProfilePhotoRequest) (*Ok, error)

Changes a profile photo for the current user

func (*Client) SetRecoveryEmailAddress

func (client *Client) SetRecoveryEmailAddress(req *SetRecoveryEmailAddressRequest) (*PasswordState, error)

Changes the 2-step verification recovery email address of the user. If a new recovery email address is specified, then the change will not be applied until the new recovery email address is confirmed. If new_recovery_email_address is the same as the email address that is currently set up, this call succeeds immediately and aborts all other requests waiting for an email confirmation

func (*Client) SetScopeNotificationSettings

func (client *Client) SetScopeNotificationSettings(req *SetScopeNotificationSettingsRequest) (*Ok, error)

Changes notification settings for chats of a given type

func (*Client) SetStickerPositionInSet

func (client *Client) SetStickerPositionInSet(req *SetStickerPositionInSetRequest) (*Ok, error)

Changes the position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot

func (*Client) SetStickerSetThumbnail

func (client *Client) SetStickerSetThumbnail(req *SetStickerSetThumbnailRequest) (*StickerSet, error)

Sets a sticker set thumbnail; for bots only. Returns the sticker set

func (*Client) SetSupergroupStickerSet

func (client *Client) SetSupergroupStickerSet(req *SetSupergroupStickerSetRequest) (*Ok, error)

Changes the sticker set of a supergroup; requires can_change_info rights

func (*Client) SetSupergroupUsername

func (client *Client) SetSupergroupUsername(req *SetSupergroupUsernameRequest) (*Ok, error)

Changes the username of a supergroup or channel, requires owner privileges in the supergroup or channel

func (*Client) SetTdlibParameters

func (client *Client) SetTdlibParameters(req *SetTdlibParametersRequest) (*Ok, error)

Sets the parameters for TDLib initialization. Works only when the current authorization state is authorizationStateWaitTdlibParameters

func (*Client) SetUserPrivacySettingRules

func (client *Client) SetUserPrivacySettingRules(req *SetUserPrivacySettingRulesRequest) (*Ok, error)

Changes user privacy settings

func (*Client) SetUsername

func (client *Client) SetUsername(req *SetUsernameRequest) (*Ok, error)

Changes the username of the current user

func (*Client) SharePhoneNumber

func (client *Client) SharePhoneNumber(req *SharePhoneNumberRequest) (*Ok, error)

Shares the phone number of the current user with a mutual contact. Supposed to be called when the user clicks on chatActionBarSharePhoneNumber

func (*Client) Stop

func (client *Client) Stop()

func (*Client) StopPoll

func (client *Client) StopPoll(req *StopPollRequest) (*Ok, error)

Stops a poll. A poll in a message can be stopped when the message has can_be_edited flag set

func (*Client) SynchronizeLanguagePack

func (client *Client) SynchronizeLanguagePack(req *SynchronizeLanguagePackRequest) (*Ok, error)

Fetches the latest versions of all strings from a language pack in the current localization target from the server. This method shouldn't be called explicitly for the current used/base language packs. Can be called before authorization

func (*Client) TerminateAllOtherSessions

func (client *Client) TerminateAllOtherSessions() (*Ok, error)

Terminates all other sessions of the current user

func (*Client) TerminateSession

func (client *Client) TerminateSession(req *TerminateSessionRequest) (*Ok, error)

Terminates a session of the current user

func (*Client) TestCallBytes

func (client *Client) TestCallBytes(req *TestCallBytesRequest) (*TestBytes, error)

Returns the received bytes; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallEmpty

func (client *Client) TestCallEmpty() (*Ok, error)

Does nothing; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallString

func (client *Client) TestCallString(req *TestCallStringRequest) (*TestString, error)

Returns the received string; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallVectorInt

func (client *Client) TestCallVectorInt(req *TestCallVectorIntRequest) (*TestVectorInt, error)

Returns the received vector of numbers; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallVectorIntObject

func (client *Client) TestCallVectorIntObject(req *TestCallVectorIntObjectRequest) (*TestVectorIntObject, error)

Returns the received vector of objects containing a number; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallVectorString

func (client *Client) TestCallVectorString(req *TestCallVectorStringRequest) (*TestVectorString, error)

Returns the received vector of strings; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestCallVectorStringObject

func (client *Client) TestCallVectorStringObject(req *TestCallVectorStringObjectRequest) (*TestVectorStringObject, error)

Returns the received vector of objects containing a string; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestGetDifference

func (client *Client) TestGetDifference() (*Ok, error)

Forces an updates.getDifference call to the Telegram servers; for testing only

func (*Client) TestNetwork

func (client *Client) TestNetwork() (*Ok, error)

Sends a simple network request to the Telegram servers; for testing only. Can be called before authorization

func (*Client) TestProxy

func (client *Client) TestProxy(req *TestProxyRequest) (*Ok, error)

Sends a simple network request to the Telegram servers via proxy; for testing only. Can be called before authorization

func (*Client) TestReturnError

func (client *Client) TestReturnError(req *TestReturnErrorRequest) (*Error, error)

Returns the specified error and ensures that the Error object is used; for testing only. Can be called synchronously

func (*Client) TestSquareInt

func (client *Client) TestSquareInt(req *TestSquareIntRequest) (*TestInt, error)

Returns the squared received number; for testing only. This is an offline method. Can be called before authorization

func (*Client) TestUseUpdate

func (client *Client) TestUseUpdate() (Update, error)

Does nothing and ensures that the Update object is used; for testing only. This is an offline method. Can be called before authorization

func (*Client) ToggleChatDefaultDisableNotification

func (client *Client) ToggleChatDefaultDisableNotification(req *ToggleChatDefaultDisableNotificationRequest) (*Ok, error)

Changes the value of the default disable_notification parameter, used when a message is sent to a chat

func (*Client) ToggleChatIsMarkedAsUnread

func (client *Client) ToggleChatIsMarkedAsUnread(req *ToggleChatIsMarkedAsUnreadRequest) (*Ok, error)

Changes the marked as unread state of a chat

func (*Client) ToggleChatIsPinned

func (client *Client) ToggleChatIsPinned(req *ToggleChatIsPinnedRequest) (*Ok, error)

Changes the pinned state of a chat. There can be up to GetOption("pinned_chat_count_max")/GetOption("pinned_archived_chat_count_max") pinned non-secret chats and the same number of secret chats in the main/arhive chat list

func (*Client) ToggleMessageSenderIsBlocked

func (client *Client) ToggleMessageSenderIsBlocked(req *ToggleMessageSenderIsBlockedRequest) (*Ok, error)

Changes the block state of a message sender. Currently, only users and supergroup chats can be blocked

func (*Client) ToggleSupergroupIsAllHistoryAvailable

func (client *Client) ToggleSupergroupIsAllHistoryAvailable(req *ToggleSupergroupIsAllHistoryAvailableRequest) (*Ok, error)

Toggles whether the message history of a supergroup is available to new members; requires can_change_info rights

func (*Client) ToggleSupergroupSignMessages

func (client *Client) ToggleSupergroupSignMessages(req *ToggleSupergroupSignMessagesRequest) (*Ok, error)

Toggles sender signatures messages sent in a channel; requires can_change_info rights

func (*Client) TransferChatOwnership

func (client *Client) TransferChatOwnership(req *TransferChatOwnershipRequest) (*Ok, error)

Changes the owner of a chat. The current user must be a current owner of the chat. Use the method canTransferOwnership to check whether the ownership can be transferred from the current session. Available only for supergroups and channel chats

func (*Client) UnpinAllChatMessages

func (client *Client) UnpinAllChatMessages(req *UnpinAllChatMessagesRequest) (*Ok, error)

Removes all pinned messages from a chat; requires can_pin_messages rights in the group or can_edit_messages rights in the channel

func (*Client) UnpinChatMessage

func (client *Client) UnpinChatMessage(req *UnpinChatMessageRequest) (*Ok, error)

Removes a pinned message from a chat; requires can_pin_messages rights in the group or can_edit_messages rights in the channel

func (*Client) UpgradeBasicGroupChatToSupergroupChat

func (client *Client) UpgradeBasicGroupChatToSupergroupChat(req *UpgradeBasicGroupChatToSupergroupChatRequest) (*Chat, error)

Creates a new supergroup from an existing basic group and sends a corresponding messageChatUpgradeTo and messageChatUpgradeFrom; requires creator privileges. Deactivates the original basic group

func (*Client) UploadFile

func (client *Client) UploadFile(req *UploadFileRequest) (*File, error)

Asynchronously uploads a file to the cloud without sending it in a message. updateFile will be used to notify about upload progress and successful completion of the upload. The file will not have a persistent remote identifier until it will be sent in a message

func (*Client) UploadStickerFile

func (client *Client) UploadStickerFile(req *UploadStickerFileRequest) (*File, error)

Uploads a PNG image with a sticker; for bots only; returns the uploaded file

func (*Client) ValidateOrderInfo

func (client *Client) ValidateOrderInfo(req *ValidateOrderInfoRequest) (*ValidatedOrderInfo, error)

Validates the order information provided by a user and returns the available shipping options for a flexible invoice

func (*Client) ViewMessages

func (client *Client) ViewMessages(req *ViewMessagesRequest) (*Ok, error)

Informs TDLib that messages are being viewed by the user. Many useful activities depend on whether the messages are currently being viewed or not (e.g., marking messages as read, incrementing a view counter, updating a view counter, removing deleted messages in supergroups and channels)

func (*Client) ViewTrendingStickerSets

func (client *Client) ViewTrendingStickerSets(req *ViewTrendingStickerSetsRequest) (*Ok, error)

Informs the server that some trending sticker sets have been viewed by the user

func (*Client) WriteGeneratedFilePart

func (client *Client) WriteGeneratedFilePart(req *WriteGeneratedFilePartRequest) (*Ok, error)

Writes a part of a generated file. This method is intended to be used only if the application has no direct access to TDLib's file system, because it is usually slower than a direct write to the destination file

type CloseChatRequest

type CloseChatRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type CloseSecretChatRequest

type CloseSecretChatRequest struct {
	// Secret chat identifier
	SecretChatId int32 `json:"secret_chat_id"`
}

type ConfirmQrCodeAuthenticationRequest

type ConfirmQrCodeAuthenticationRequest struct {
	// A link from a QR code. The link must be scanned by the in-app camera
	Link string `json:"link"`
}

type ConnectedWebsite

type ConnectedWebsite struct {

	// Website identifier
	Id JsonInt64 `json:"id"`
	// The domain name of the website
	DomainName string `json:"domain_name"`
	// User identifier of a bot linked with the website
	BotUserId int32 `json:"bot_user_id"`
	// The version of a browser used to log in
	Browser string `json:"browser"`
	// Operating system the browser is running on
	Platform string `json:"platform"`
	// Point in time (Unix timestamp) when the user was logged in
	LogInDate int32 `json:"log_in_date"`
	// Point in time (Unix timestamp) when obtained authorization was last used
	LastActiveDate int32 `json:"last_active_date"`
	// IP address from which the user was logged in, in human-readable format
	Ip string `json:"ip"`
	// Human-readable description of a country and a region, from which the user was logged in, based on the IP address
	Location string `json:"location"`
	// contains filtered or unexported fields
}

Contains information about one website the current user is logged in with Telegram

func UnmarshalConnectedWebsite

func UnmarshalConnectedWebsite(data json.RawMessage) (*ConnectedWebsite, error)

func (*ConnectedWebsite) GetClass

func (*ConnectedWebsite) GetClass() string

func (*ConnectedWebsite) GetType

func (*ConnectedWebsite) GetType() string

func (*ConnectedWebsite) MarshalJSON

func (entity *ConnectedWebsite) MarshalJSON() ([]byte, error)

type ConnectedWebsites

type ConnectedWebsites struct {

	// List of connected websites
	Websites []*ConnectedWebsite `json:"websites"`
	// contains filtered or unexported fields
}

Contains a list of websites the current user is logged in with Telegram

func UnmarshalConnectedWebsites

func UnmarshalConnectedWebsites(data json.RawMessage) (*ConnectedWebsites, error)

func (*ConnectedWebsites) GetClass

func (*ConnectedWebsites) GetClass() string

func (*ConnectedWebsites) GetType

func (*ConnectedWebsites) GetType() string

func (*ConnectedWebsites) MarshalJSON

func (entity *ConnectedWebsites) MarshalJSON() ([]byte, error)

type ConnectionState

type ConnectionState interface {
	ConnectionStateType() string
}

Describes the current state of the connection to Telegram servers

func UnmarshalConnectionState

func UnmarshalConnectionState(data json.RawMessage) (ConnectionState, error)

func UnmarshalListOfConnectionState

func UnmarshalListOfConnectionState(dataList []json.RawMessage) ([]ConnectionState, error)

type ConnectionStateConnecting

type ConnectionStateConnecting struct {
	// contains filtered or unexported fields
}

Currently establishing a connection to the Telegram servers

func UnmarshalConnectionStateConnecting

func UnmarshalConnectionStateConnecting(data json.RawMessage) (*ConnectionStateConnecting, error)

func (*ConnectionStateConnecting) ConnectionStateType

func (*ConnectionStateConnecting) ConnectionStateType() string

func (*ConnectionStateConnecting) GetClass

func (*ConnectionStateConnecting) GetClass() string

func (*ConnectionStateConnecting) GetType

func (*ConnectionStateConnecting) GetType() string

func (*ConnectionStateConnecting) MarshalJSON

func (entity *ConnectionStateConnecting) MarshalJSON() ([]byte, error)

type ConnectionStateConnectingToProxy

type ConnectionStateConnectingToProxy struct {
	// contains filtered or unexported fields
}

Currently establishing a connection with a proxy server

func UnmarshalConnectionStateConnectingToProxy

func UnmarshalConnectionStateConnectingToProxy(data json.RawMessage) (*ConnectionStateConnectingToProxy, error)

func (*ConnectionStateConnectingToProxy) ConnectionStateType

func (*ConnectionStateConnectingToProxy) ConnectionStateType() string

func (*ConnectionStateConnectingToProxy) GetClass

func (*ConnectionStateConnectingToProxy) GetType

func (*ConnectionStateConnectingToProxy) MarshalJSON

func (entity *ConnectionStateConnectingToProxy) MarshalJSON() ([]byte, error)

type ConnectionStateReady

type ConnectionStateReady struct {
	// contains filtered or unexported fields
}

There is a working connection to the Telegram servers

func UnmarshalConnectionStateReady

func UnmarshalConnectionStateReady(data json.RawMessage) (*ConnectionStateReady, error)

func (*ConnectionStateReady) ConnectionStateType

func (*ConnectionStateReady) ConnectionStateType() string

func (*ConnectionStateReady) GetClass

func (*ConnectionStateReady) GetClass() string

func (*ConnectionStateReady) GetType

func (*ConnectionStateReady) GetType() string

func (*ConnectionStateReady) MarshalJSON

func (entity *ConnectionStateReady) MarshalJSON() ([]byte, error)

type ConnectionStateUpdating

type ConnectionStateUpdating struct {
	// contains filtered or unexported fields
}

Downloading data received while the application was offline

func UnmarshalConnectionStateUpdating

func UnmarshalConnectionStateUpdating(data json.RawMessage) (*ConnectionStateUpdating, error)

func (*ConnectionStateUpdating) ConnectionStateType

func (*ConnectionStateUpdating) ConnectionStateType() string

func (*ConnectionStateUpdating) GetClass

func (*ConnectionStateUpdating) GetClass() string

func (*ConnectionStateUpdating) GetType

func (*ConnectionStateUpdating) GetType() string

func (*ConnectionStateUpdating) MarshalJSON

func (entity *ConnectionStateUpdating) MarshalJSON() ([]byte, error)

type ConnectionStateWaitingForNetwork

type ConnectionStateWaitingForNetwork struct {
	// contains filtered or unexported fields
}

Currently waiting for the network to become available. Use setNetworkType to change the available network type

func UnmarshalConnectionStateWaitingForNetwork

func UnmarshalConnectionStateWaitingForNetwork(data json.RawMessage) (*ConnectionStateWaitingForNetwork, error)

func (*ConnectionStateWaitingForNetwork) ConnectionStateType

func (*ConnectionStateWaitingForNetwork) ConnectionStateType() string

func (*ConnectionStateWaitingForNetwork) GetClass

func (*ConnectionStateWaitingForNetwork) GetType

func (*ConnectionStateWaitingForNetwork) MarshalJSON

func (entity *ConnectionStateWaitingForNetwork) MarshalJSON() ([]byte, error)

type Contact

type Contact struct {

	// Phone number of the user
	PhoneNumber string `json:"phone_number"`
	// First name of the user; 1-255 characters in length
	FirstName string `json:"first_name"`
	// Last name of the user
	LastName string `json:"last_name"`
	// Additional data about the user in a form of vCard; 0-2048 bytes in length
	Vcard string `json:"vcard"`
	// Identifier of the user, if known; otherwise 0
	UserId int32 `json:"user_id"`
	// contains filtered or unexported fields
}

Describes a user contact

func UnmarshalContact

func UnmarshalContact(data json.RawMessage) (*Contact, error)

func (*Contact) GetClass

func (*Contact) GetClass() string

func (*Contact) GetType

func (*Contact) GetType() string

func (*Contact) MarshalJSON

func (entity *Contact) MarshalJSON() ([]byte, error)

type Count

type Count struct {

	// Count
	Count int32 `json:"count"`
	// contains filtered or unexported fields
}

Contains a counter

func UnmarshalCount

func UnmarshalCount(data json.RawMessage) (*Count, error)

func (*Count) GetClass

func (*Count) GetClass() string

func (*Count) GetType

func (*Count) GetType() string

func (*Count) MarshalJSON

func (entity *Count) MarshalJSON() ([]byte, error)

type Countries

type Countries struct {

	// The list of countries
	Countries []*CountryInfo `json:"countries"`
	// contains filtered or unexported fields
}

Contains information about countries

func UnmarshalCountries

func UnmarshalCountries(data json.RawMessage) (*Countries, error)

func (*Countries) GetClass

func (*Countries) GetClass() string

func (*Countries) GetType

func (*Countries) GetType() string

func (*Countries) MarshalJSON

func (entity *Countries) MarshalJSON() ([]byte, error)

type CountryInfo

type CountryInfo struct {

	// A two-letter ISO 3166-1 alpha-2 country code
	CountryCode string `json:"country_code"`
	// Native name of the country
	Name string `json:"name"`
	// English name of the country
	EnglishName string `json:"english_name"`
	// True, if the country should be hidden from the list of all countries
	IsHidden bool `json:"is_hidden"`
	// List of country calling codes
	CallingCodes []string `json:"calling_codes"`
	// contains filtered or unexported fields
}

Contains information about a country

func UnmarshalCountryInfo

func UnmarshalCountryInfo(data json.RawMessage) (*CountryInfo, error)

func (*CountryInfo) GetClass

func (*CountryInfo) GetClass() string

func (*CountryInfo) GetType

func (*CountryInfo) GetType() string

func (*CountryInfo) MarshalJSON

func (entity *CountryInfo) MarshalJSON() ([]byte, error)

type CreateBasicGroupChatRequest

type CreateBasicGroupChatRequest struct {
	// Basic group identifier
	BasicGroupId int32 `json:"basic_group_id"`
	// If true, the chat will be created without network request. In this case all information about the chat except its type, title and photo can be incorrect
	Force bool `json:"force"`
}

type CreateCallRequest

type CreateCallRequest struct {
	// Identifier of the user to be called
	UserId int32 `json:"user_id"`
	// Description of the call protocols supported by the application
	Protocol *CallProtocol `json:"protocol"`
	// True, if a video call needs to be created
	IsVideo bool `json:"is_video"`
}

type CreateChatFilterRequest

type CreateChatFilterRequest struct {
	// Chat filter
	Filter *ChatFilter `json:"filter"`
}

type CreateNewBasicGroupChatRequest

type CreateNewBasicGroupChatRequest struct {
	// Identifiers of users to be added to the basic group
	UserIds []int32 `json:"user_ids"`
	// Title of the new basic group; 1-128 characters
	Title string `json:"title"`
}

type CreateNewSecretChatRequest

type CreateNewSecretChatRequest struct {
	// Identifier of the target user
	UserId int32 `json:"user_id"`
}

type CreateNewStickerSetRequest

type CreateNewStickerSetRequest struct {
	// Sticker set owner
	UserId int32 `json:"user_id"`
	// Sticker set title; 1-64 characters
	Title string `json:"title"`
	// Sticker set name. Can contain only English letters, digits and underscores. Must end with *"_by_<bot username>"* (*<bot_username>* is case insensitive); 1-64 characters
	Name string `json:"name"`
	// True, if stickers are masks. Animated stickers can't be masks
	IsMasks bool `json:"is_masks"`
	// List of stickers to be added to the set; must be non-empty. All stickers must be of the same type
	Stickers []InputSticker `json:"stickers"`
}

type CreateNewSupergroupChatRequest

type CreateNewSupergroupChatRequest struct {
	// Title of the new chat; 1-128 characters
	Title string `json:"title"`
	// True, if a channel chat should be created
	IsChannel bool `json:"is_channel"`
	// Chat description; 0-255 characters
	Description string `json:"description"`
	// Chat location if a location-based supergroup is being created
	Location *ChatLocation `json:"location"`
}

type CreatePrivateChatRequest

type CreatePrivateChatRequest struct {
	// User identifier
	UserId int32 `json:"user_id"`
	// If true, the chat will be created without network request. In this case all information about the chat except its type, title and photo can be incorrect
	Force bool `json:"force"`
}

type CreateSecretChatRequest

type CreateSecretChatRequest struct {
	// Secret chat identifier
	SecretChatId int32 `json:"secret_chat_id"`
}

type CreateSupergroupChatRequest

type CreateSupergroupChatRequest struct {
	// Supergroup or channel identifier
	SupergroupId int32 `json:"supergroup_id"`
	// If true, the chat will be created without network request. In this case all information about the chat except its type, title and photo can be incorrect
	Force bool `json:"force"`
}

type CreateTemporaryPasswordRequest

type CreateTemporaryPasswordRequest struct {
	// Persistent user password
	Password string `json:"password"`
	// Time during which the temporary password will be valid, in seconds; should be between 60 and 86400
	ValidFor int32 `json:"valid_for"`
}

type CustomRequestResult

type CustomRequestResult struct {

	// A JSON-serialized result
	Result string `json:"result"`
	// contains filtered or unexported fields
}

Contains the result of a custom request

func UnmarshalCustomRequestResult

func UnmarshalCustomRequestResult(data json.RawMessage) (*CustomRequestResult, error)

func (*CustomRequestResult) GetClass

func (*CustomRequestResult) GetClass() string

func (*CustomRequestResult) GetType

func (*CustomRequestResult) GetType() string

func (*CustomRequestResult) MarshalJSON

func (entity *CustomRequestResult) MarshalJSON() ([]byte, error)

type DatabaseStatistics

type DatabaseStatistics struct {

	// Database statistics in an unspecified human-readable format
	Statistics string `json:"statistics"`
	// contains filtered or unexported fields
}

Contains database statistics

func UnmarshalDatabaseStatistics

func UnmarshalDatabaseStatistics(data json.RawMessage) (*DatabaseStatistics, error)

func (*DatabaseStatistics) GetClass

func (*DatabaseStatistics) GetClass() string

func (*DatabaseStatistics) GetType

func (*DatabaseStatistics) GetType() string

func (*DatabaseStatistics) MarshalJSON

func (entity *DatabaseStatistics) MarshalJSON() ([]byte, error)

type Date

type Date struct {

	// Day of the month, 1-31
	Day int32 `json:"day"`
	// Month, 1-12
	Month int32 `json:"month"`
	// Year, 1-9999
	Year int32 `json:"year"`
	// contains filtered or unexported fields
}

Represents a date according to the Gregorian calendar

func UnmarshalDate

func UnmarshalDate(data json.RawMessage) (*Date, error)

func (*Date) GetClass

func (*Date) GetClass() string

func (*Date) GetType

func (*Date) GetType() string

func (*Date) MarshalJSON

func (entity *Date) MarshalJSON() ([]byte, error)

type DateRange

type DateRange struct {

	// Point in time (Unix timestamp) at which the date range begins
	StartDate int32 `json:"start_date"`
	// Point in time (Unix timestamp) at which the date range ends
	EndDate int32 `json:"end_date"`
	// contains filtered or unexported fields
}

Represents a date range

func UnmarshalDateRange

func UnmarshalDateRange(data json.RawMessage) (*DateRange, error)

func (*DateRange) GetClass

func (*DateRange) GetClass() string

func (*DateRange) GetType

func (*DateRange) GetType() string

func (*DateRange) MarshalJSON

func (entity *DateRange) MarshalJSON() ([]byte, error)

type DatedFile

type DatedFile struct {

	// The file
	File *File `json:"file"`
	// Point in time (Unix timestamp) when the file was uploaded
	Date int32 `json:"date"`
	// contains filtered or unexported fields
}

File with the date it was uploaded

func UnmarshalDatedFile

func UnmarshalDatedFile(data json.RawMessage) (*DatedFile, error)

func (*DatedFile) GetClass

func (*DatedFile) GetClass() string

func (*DatedFile) GetType

func (*DatedFile) GetType() string

func (*DatedFile) MarshalJSON

func (entity *DatedFile) MarshalJSON() ([]byte, error)

type DeepLinkInfo

type DeepLinkInfo struct {

	// Text to be shown to the user
	Text *FormattedText `json:"text"`
	// True, if user should be asked to update the application
	NeedUpdateApplication bool `json:"need_update_application"`
	// contains filtered or unexported fields
}

Contains information about a tg:// deep link

func UnmarshalDeepLinkInfo

func UnmarshalDeepLinkInfo(data json.RawMessage) (*DeepLinkInfo, error)

func (*DeepLinkInfo) GetClass

func (*DeepLinkInfo) GetClass() string

func (*DeepLinkInfo) GetType

func (*DeepLinkInfo) GetType() string

func (*DeepLinkInfo) MarshalJSON

func (entity *DeepLinkInfo) MarshalJSON() ([]byte, error)

type DeleteAccountRequest

type DeleteAccountRequest struct {
	// The reason why the account was deleted; optional
	Reason string `json:"reason"`
}

type DeleteChatFilterRequest

type DeleteChatFilterRequest struct {
	// Chat filter identifier
	ChatFilterId int32 `json:"chat_filter_id"`
}

type DeleteChatHistoryRequest

type DeleteChatHistoryRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Pass true if the chat should be removed from the chat list
	RemoveFromChatList bool `json:"remove_from_chat_list"`
	// Pass true to try to delete chat history for all users
	Revoke bool `json:"revoke"`
}

type DeleteChatMessagesFromUserRequest

type DeleteChatMessagesFromUserRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// User identifier
	UserId int32 `json:"user_id"`
}

type DeleteChatReplyMarkupRequest

type DeleteChatReplyMarkupRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// The message identifier of the used keyboard
	MessageId int64 `json:"message_id"`
}

type DeleteFileRequest

type DeleteFileRequest struct {
	// Identifier of the file to delete
	FileId int32 `json:"file_id"`
}

type DeleteLanguagePackRequest

type DeleteLanguagePackRequest struct {
	// Identifier of the language pack to delete
	LanguagePackId string `json:"language_pack_id"`
}

type DeleteMessagesRequest

type DeleteMessagesRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Identifiers of the messages to be deleted
	MessageIds []int64 `json:"message_ids"`
	// Pass true to try to delete messages for all chat members. Always true for supergroups, channels and secret chats
	Revoke bool `json:"revoke"`
}

type DeletePassportElementRequest

type DeletePassportElementRequest struct {
	// Element type
	Type PassportElementType `json:"type"`
}

type DeleteProfilePhotoRequest

type DeleteProfilePhotoRequest struct {
	// Identifier of the profile photo to delete
	ProfilePhotoId JsonInt64 `json:"profile_photo_id"`
}

type DeleteSupergroupRequest

type DeleteSupergroupRequest struct {
	// Identifier of the supergroup or channel
	SupergroupId int32 `json:"supergroup_id"`
}

type DeviceToken

type DeviceToken interface {
	DeviceTokenType() string
}

Represents a data needed to subscribe for push notifications through registerDevice method. To use specific push notification service, the correct application platform must be specified and a valid server authentication data must be uploaded at https://my.telegram.org

func UnmarshalDeviceToken

func UnmarshalDeviceToken(data json.RawMessage) (DeviceToken, error)

func UnmarshalListOfDeviceToken

func UnmarshalListOfDeviceToken(dataList []json.RawMessage) ([]DeviceToken, error)

type DeviceTokenApplePush

type DeviceTokenApplePush struct {

	// Device token; may be empty to de-register a device
	DeviceToken string `json:"device_token"`
	// True, if App Sandbox is enabled
	IsAppSandbox bool `json:"is_app_sandbox"`
	// contains filtered or unexported fields
}

A token for Apple Push Notification service

func UnmarshalDeviceTokenApplePush

func UnmarshalDeviceTokenApplePush(data json.RawMessage) (*DeviceTokenApplePush, error)

func (*DeviceTokenApplePush) DeviceTokenType

func (*DeviceTokenApplePush) DeviceTokenType() string

func (*DeviceTokenApplePush) GetClass

func (*DeviceTokenApplePush) GetClass() string

func (*DeviceTokenApplePush) GetType

func (*DeviceTokenApplePush) GetType() string

func (*DeviceTokenApplePush) MarshalJSON

func (entity *DeviceTokenApplePush) MarshalJSON() ([]byte, error)

type DeviceTokenApplePushVoIP

type DeviceTokenApplePushVoIP struct {

	// Device token; may be empty to de-register a device
	DeviceToken string `json:"device_token"`
	// True, if App Sandbox is enabled
	IsAppSandbox bool `json:"is_app_sandbox"`
	// True, if push notifications should be additionally encrypted
	Encrypt bool `json:"encrypt"`
	// contains filtered or unexported fields
}

A token for Apple Push Notification service VoIP notifications

func UnmarshalDeviceTokenApplePushVoIP

func UnmarshalDeviceTokenApplePushVoIP(data json.RawMessage) (*DeviceTokenApplePushVoIP, error)

func (*DeviceTokenApplePushVoIP) DeviceTokenType

func (*DeviceTokenApplePushVoIP) DeviceTokenType() string

func (*DeviceTokenApplePushVoIP) GetClass

func (*DeviceTokenApplePushVoIP) GetClass() string

func (*DeviceTokenApplePushVoIP) GetType

func (*DeviceTokenApplePushVoIP) GetType() string

func (*DeviceTokenApplePushVoIP) MarshalJSON

func (entity *DeviceTokenApplePushVoIP) MarshalJSON() ([]byte, error)

type DeviceTokenBlackBerryPush

type DeviceTokenBlackBerryPush struct {

	// Token; may be empty to de-register a device
	Token string `json:"token"`
	// contains filtered or unexported fields
}

A token for BlackBerry Push Service

func UnmarshalDeviceTokenBlackBerryPush

func UnmarshalDeviceTokenBlackBerryPush(data json.RawMessage) (*DeviceTokenBlackBerryPush, error)

func (*DeviceTokenBlackBerryPush) DeviceTokenType

func (*DeviceTokenBlackBerryPush) DeviceTokenType() string

func (*DeviceTokenBlackBerryPush) GetClass

func (*DeviceTokenBlackBerryPush) GetClass() string

func (*DeviceTokenBlackBerryPush) GetType

func (*DeviceTokenBlackBerryPush) GetType() string

func (*DeviceTokenBlackBerryPush) MarshalJSON

func (entity *DeviceTokenBlackBerryPush) MarshalJSON() ([]byte, error)

type DeviceTokenFirebaseCloudMessaging

type DeviceTokenFirebaseCloudMessaging struct {

	// Device registration token; may be empty to de-register a device
	Token string `json:"token"`
	// True, if push notifications should be additionally encrypted
	Encrypt bool `json:"encrypt"`
	// contains filtered or unexported fields
}

A token for Firebase Cloud Messaging

func UnmarshalDeviceTokenFirebaseCloudMessaging

func UnmarshalDeviceTokenFirebaseCloudMessaging(data json.RawMessage) (*DeviceTokenFirebaseCloudMessaging, error)

func (*DeviceTokenFirebaseCloudMessaging) DeviceTokenType

func (*DeviceTokenFirebaseCloudMessaging) DeviceTokenType() string

func (*DeviceTokenFirebaseCloudMessaging) GetClass

func (*DeviceTokenFirebaseCloudMessaging) GetType

func (*DeviceTokenFirebaseCloudMessaging) MarshalJSON

func (entity *DeviceTokenFirebaseCloudMessaging) MarshalJSON() ([]byte, error)

type DeviceTokenMicrosoftPush

type DeviceTokenMicrosoftPush struct {

	// Push notification channel URI; may be empty to de-register a device
	ChannelUri string `json:"channel_uri"`
	// contains filtered or unexported fields
}

A token for Microsoft Push Notification Service

func UnmarshalDeviceTokenMicrosoftPush

func UnmarshalDeviceTokenMicrosoftPush(data json.RawMessage) (*DeviceTokenMicrosoftPush, error)

func (*DeviceTokenMicrosoftPush) DeviceTokenType

func (*DeviceTokenMicrosoftPush) DeviceTokenType() string

func (*DeviceTokenMicrosoftPush) GetClass

func (*DeviceTokenMicrosoftPush) GetClass() string

func (*DeviceTokenMicrosoftPush) GetType

func (*DeviceTokenMicrosoftPush) GetType() string

func (*DeviceTokenMicrosoftPush) MarshalJSON

func (entity *DeviceTokenMicrosoftPush) MarshalJSON() ([]byte, error)

type DeviceTokenMicrosoftPushVoIP

type DeviceTokenMicrosoftPushVoIP struct {

	// Push notification channel URI; may be empty to de-register a device
	ChannelUri string `json:"channel_uri"`
	// contains filtered or unexported fields
}

A token for Microsoft Push Notification Service VoIP channel

func UnmarshalDeviceTokenMicrosoftPushVoIP

func UnmarshalDeviceTokenMicrosoftPushVoIP(data json.RawMessage) (*DeviceTokenMicrosoftPushVoIP, error)

func (*DeviceTokenMicrosoftPushVoIP) DeviceTokenType

func (*DeviceTokenMicrosoftPushVoIP) DeviceTokenType() string

func (*DeviceTokenMicrosoftPushVoIP) GetClass

func (*DeviceTokenMicrosoftPushVoIP) GetType

func (*DeviceTokenMicrosoftPushVoIP) MarshalJSON

func (entity *DeviceTokenMicrosoftPushVoIP) MarshalJSON() ([]byte, error)

type DeviceTokenSimplePush

type DeviceTokenSimplePush struct {

	// Absolute URL exposed by the push service where the application server can send push messages; may be empty to de-register a device
	Endpoint string `json:"endpoint"`
	// contains filtered or unexported fields
}

A token for Simple Push API for Firefox OS

func UnmarshalDeviceTokenSimplePush

func UnmarshalDeviceTokenSimplePush(data json.RawMessage) (*DeviceTokenSimplePush, error)

func (*DeviceTokenSimplePush) DeviceTokenType

func (*DeviceTokenSimplePush) DeviceTokenType() string

func (*DeviceTokenSimplePush) GetClass

func (*DeviceTokenSimplePush) GetClass() string

func (*DeviceTokenSimplePush) GetType

func (*DeviceTokenSimplePush) GetType() string

func (*DeviceTokenSimplePush) MarshalJSON

func (entity *DeviceTokenSimplePush) MarshalJSON() ([]byte, error)

type DeviceTokenTizenPush

type DeviceTokenTizenPush struct {

	// Push service registration identifier; may be empty to de-register a device
	RegId string `json:"reg_id"`
	// contains filtered or unexported fields
}

A token for Tizen Push Service

func UnmarshalDeviceTokenTizenPush

func UnmarshalDeviceTokenTizenPush(data json.RawMessage) (*DeviceTokenTizenPush, error)

func (*DeviceTokenTizenPush) DeviceTokenType

func (*DeviceTokenTizenPush) DeviceTokenType() string

func (*DeviceTokenTizenPush) GetClass

func (*DeviceTokenTizenPush) GetClass() string

func (*DeviceTokenTizenPush) GetType

func (*DeviceTokenTizenPush) GetType() string

func (*DeviceTokenTizenPush) MarshalJSON

func (entity *DeviceTokenTizenPush) MarshalJSON() ([]byte, error)

type DeviceTokenUbuntuPush

type DeviceTokenUbuntuPush struct {

	// Token; may be empty to de-register a device
	Token string `json:"token"`
	// contains filtered or unexported fields
}

A token for Ubuntu Push Client service

func UnmarshalDeviceTokenUbuntuPush

func UnmarshalDeviceTokenUbuntuPush(data json.RawMessage) (*DeviceTokenUbuntuPush, error)

func (*DeviceTokenUbuntuPush) DeviceTokenType

func (*DeviceTokenUbuntuPush) DeviceTokenType() string

func (*DeviceTokenUbuntuPush) GetClass

func (*DeviceTokenUbuntuPush) GetClass() string

func (*DeviceTokenUbuntuPush) GetType

func (*DeviceTokenUbuntuPush) GetType() string

func (*DeviceTokenUbuntuPush) MarshalJSON

func (entity *DeviceTokenUbuntuPush) MarshalJSON() ([]byte, error)

type DeviceTokenWebPush

type DeviceTokenWebPush struct {

	// Absolute URL exposed by the push service where the application server can send push messages; may be empty to de-register a device
	Endpoint string `json:"endpoint"`
	// Base64url-encoded P-256 elliptic curve Diffie-Hellman public key
	P256dhBase64url string `json:"p256dh_base64url"`
	// Base64url-encoded authentication secret
	AuthBase64url string `json:"auth_base64url"`
	// contains filtered or unexported fields
}

A token for web Push API

func UnmarshalDeviceTokenWebPush

func UnmarshalDeviceTokenWebPush(data json.RawMessage) (*DeviceTokenWebPush, error)

func (*DeviceTokenWebPush) DeviceTokenType

func (*DeviceTokenWebPush) DeviceTokenType() string

func (*DeviceTokenWebPush) GetClass

func (*DeviceTokenWebPush) GetClass() string

func (*DeviceTokenWebPush) GetType

func (*DeviceTokenWebPush) GetType() string

func (*DeviceTokenWebPush) MarshalJSON

func (entity *DeviceTokenWebPush) MarshalJSON() ([]byte, error)

type DeviceTokenWindowsPush

type DeviceTokenWindowsPush struct {

	// The access token that will be used to send notifications; may be empty to de-register a device
	AccessToken string `json:"access_token"`
	// contains filtered or unexported fields
}

A token for Windows Push Notification Services

func UnmarshalDeviceTokenWindowsPush

func UnmarshalDeviceTokenWindowsPush(data json.RawMessage) (*DeviceTokenWindowsPush, error)

func (*DeviceTokenWindowsPush) DeviceTokenType

func (*DeviceTokenWindowsPush) DeviceTokenType() string

func (*DeviceTokenWindowsPush) GetClass

func (*DeviceTokenWindowsPush) GetClass() string

func (*DeviceTokenWindowsPush) GetType

func (*DeviceTokenWindowsPush) GetType() string

func (*DeviceTokenWindowsPush) MarshalJSON

func (entity *DeviceTokenWindowsPush) MarshalJSON() ([]byte, error)

type DiceStickers

type DiceStickers interface {
	DiceStickersType() string
}

Contains animated stickers which should be used for dice animation rendering

func UnmarshalDiceStickers

func UnmarshalDiceStickers(data json.RawMessage) (DiceStickers, error)

func UnmarshalListOfDiceStickers

func UnmarshalListOfDiceStickers(dataList []json.RawMessage) ([]DiceStickers, error)

type DiceStickersRegular

type DiceStickersRegular struct {

	// The animated sticker with the dice animation
	Sticker *Sticker `json:"sticker"`
	// contains filtered or unexported fields
}

A regular animated sticker

func UnmarshalDiceStickersRegular

func UnmarshalDiceStickersRegular(data json.RawMessage) (*DiceStickersRegular, error)

func (*DiceStickersRegular) DiceStickersType

func (*DiceStickersRegular) DiceStickersType() string

func (*DiceStickersRegular) GetClass

func (*DiceStickersRegular) GetClass() string

func (*DiceStickersRegular) GetType

func (*DiceStickersRegular) GetType() string

func (*DiceStickersRegular) MarshalJSON

func (entity *DiceStickersRegular) MarshalJSON() ([]byte, error)

type DiceStickersSlotMachine

type DiceStickersSlotMachine struct {

	// The animated sticker with the slot machine background. The background animation must start playing after all reel animations finish
	Background *Sticker `json:"background"`
	// The animated sticker with the lever animation. The lever animation must play once in the initial dice state
	Lever *Sticker `json:"lever"`
	// The animated sticker with the left reel
	LeftReel *Sticker `json:"left_reel"`
	// The animated sticker with the center reel
	CenterReel *Sticker `json:"center_reel"`
	// The animated sticker with the right reel
	RightReel *Sticker `json:"right_reel"`
	// contains filtered or unexported fields
}

Animated stickers to be combined into a slot machine

func UnmarshalDiceStickersSlotMachine

func UnmarshalDiceStickersSlotMachine(data json.RawMessage) (*DiceStickersSlotMachine, error)

func (*DiceStickersSlotMachine) DiceStickersType

func (*DiceStickersSlotMachine) DiceStickersType() string

func (*DiceStickersSlotMachine) GetClass

func (*DiceStickersSlotMachine) GetClass() string

func (*DiceStickersSlotMachine) GetType

func (*DiceStickersSlotMachine) GetType() string

func (*DiceStickersSlotMachine) MarshalJSON

func (entity *DiceStickersSlotMachine) MarshalJSON() ([]byte, error)

type DiscardCallRequest

type DiscardCallRequest struct {
	// Call identifier
	CallId int32 `json:"call_id"`
	// True, if the user was disconnected
	IsDisconnected bool `json:"is_disconnected"`
	// The call duration, in seconds
	Duration int32 `json:"duration"`
	// True, if the call was a video call
	IsVideo bool `json:"is_video"`
	// Identifier of the connection used during the call
	ConnectionId JsonInt64 `json:"connection_id"`
}

type DisconnectWebsiteRequest

type DisconnectWebsiteRequest struct {
	// Website identifier
	WebsiteId JsonInt64 `json:"website_id"`
}

type Document

type Document struct {

	// Original name of the file; as defined by the sender
	FileName string `json:"file_name"`
	// MIME type of the file; as defined by the sender
	MimeType string `json:"mime_type"`
	// Document minithumbnail; may be null
	Minithumbnail *Minithumbnail `json:"minithumbnail"`
	// Document thumbnail in JPEG or PNG format (PNG will be used only for background patterns); as defined by the sender; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// File containing the document
	Document *File `json:"document"`
	// contains filtered or unexported fields
}

Describes a document of any type

func UnmarshalDocument

func UnmarshalDocument(data json.RawMessage) (*Document, error)

func (*Document) GetClass

func (*Document) GetClass() string

func (*Document) GetType

func (*Document) GetType() string

func (*Document) MarshalJSON

func (entity *Document) MarshalJSON() ([]byte, error)

type DownloadFileRequest

type DownloadFileRequest struct {
	// Identifier of the file to download
	FileId int32 `json:"file_id"`
	// Priority of the download (1-32). The higher the priority, the earlier the file will be downloaded. If the priorities of two files are equal, then the last one for which downloadFile was called will be downloaded first
	Priority int32 `json:"priority"`
	// The starting position from which the file should be downloaded
	Offset int32 `json:"offset"`
	// Number of bytes which should be downloaded starting from the "offset" position before the download will be automatically cancelled; use 0 to download without a limit
	Limit int32 `json:"limit"`
	// If false, this request returns file state just after the download has been started. If true, this request returns file state only after the download has succeeded, has failed, has been cancelled or a new downloadFile request with different offset/limit parameters was sent
	Synchronous bool `json:"synchronous"`
}

type DraftMessage

type DraftMessage struct {

	// Identifier of the message to reply to; 0 if none
	ReplyToMessageId int64 `json:"reply_to_message_id"`
	// Point in time (Unix timestamp) when the draft was created
	Date int32 `json:"date"`
	// Content of the message draft; this should always be of type inputMessageText
	InputMessageText InputMessageContent `json:"input_message_text"`
	// contains filtered or unexported fields
}

Contains information about a message draft

func UnmarshalDraftMessage

func UnmarshalDraftMessage(data json.RawMessage) (*DraftMessage, error)

func (*DraftMessage) GetClass

func (*DraftMessage) GetClass() string

func (*DraftMessage) GetType

func (*DraftMessage) GetType() string

func (*DraftMessage) MarshalJSON

func (entity *DraftMessage) MarshalJSON() ([]byte, error)

func (*DraftMessage) UnmarshalJSON

func (draftMessage *DraftMessage) UnmarshalJSON(data []byte) error

type EditChatFilterRequest

type EditChatFilterRequest struct {
	// Chat filter identifier
	ChatFilterId int32 `json:"chat_filter_id"`
	// The edited chat filter
	Filter *ChatFilter `json:"filter"`
}

type EditCustomLanguagePackInfoRequest

type EditCustomLanguagePackInfoRequest struct {
	// New information about the custom local language pack
	Info *LanguagePackInfo `json:"info"`
}

type EditInlineMessageCaptionRequest

type EditInlineMessageCaptionRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// The new message reply markup
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New message content caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
}

type EditInlineMessageLiveLocationRequest

type EditInlineMessageLiveLocationRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// The new message reply markup
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New location content of the message; may be null. Pass null to stop sharing the live location
	Location *Location `json:"location"`
	// The new direction in which the location moves, in degrees; 1-360. Pass 0 if unknown
	Heading int32 `json:"heading"`
	// The new maximum distance for proximity alerts, in meters (0-100000). Pass 0 if the notification is disabled
	ProximityAlertRadius int32 `json:"proximity_alert_radius"`
}

type EditInlineMessageMediaRequest

type EditInlineMessageMediaRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// The new message reply markup; for bots only
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New content of the message. Must be one of the following types: InputMessageAnimation, InputMessageAudio, InputMessageDocument, InputMessagePhoto or InputMessageVideo
	InputMessageContent InputMessageContent `json:"input_message_content"`
}

type EditInlineMessageReplyMarkupRequest

type EditInlineMessageReplyMarkupRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// The new message reply markup
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
}

type EditInlineMessageTextRequest

type EditInlineMessageTextRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// The new message reply markup
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New text content of the message. Should be of type InputMessageText
	InputMessageContent InputMessageContent `json:"input_message_content"`
}

type EditMessageCaptionRequest

type EditMessageCaptionRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message reply markup; for bots only
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New message content caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
}

type EditMessageLiveLocationRequest

type EditMessageLiveLocationRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message reply markup; for bots only
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New location content of the message; may be null. Pass null to stop sharing the live location
	Location *Location `json:"location"`
	// The new direction in which the location moves, in degrees; 1-360. Pass 0 if unknown
	Heading int32 `json:"heading"`
	// The new maximum distance for proximity alerts, in meters (0-100000). Pass 0 if the notification is disabled
	ProximityAlertRadius int32 `json:"proximity_alert_radius"`
}

type EditMessageMediaRequest

type EditMessageMediaRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message reply markup; for bots only
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New content of the message. Must be one of the following types: InputMessageAnimation, InputMessageAudio, InputMessageDocument, InputMessagePhoto or InputMessageVideo
	InputMessageContent InputMessageContent `json:"input_message_content"`
}

type EditMessageReplyMarkupRequest

type EditMessageReplyMarkupRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message reply markup
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
}

type EditMessageSchedulingStateRequest

type EditMessageSchedulingStateRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message scheduling state. Pass null to send the message immediately
	SchedulingState MessageSchedulingState `json:"scheduling_state"`
}

type EditMessageTextRequest

type EditMessageTextRequest struct {
	// The chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// The new message reply markup; for bots only
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// New text content of the message. Should be of type InputMessageText
	InputMessageContent InputMessageContent `json:"input_message_content"`
}

type EditProxyRequest

type EditProxyRequest struct {
	// Proxy identifier
	ProxyId int32 `json:"proxy_id"`
	// Proxy server IP address
	Server string `json:"server"`
	// Proxy server port
	Port int32 `json:"port"`
	// True, if the proxy should be enabled
	Enable bool `json:"enable"`
	// Proxy type
	Type ProxyType `json:"type"`
}

type EmailAddressAuthenticationCodeInfo

type EmailAddressAuthenticationCodeInfo struct {

	// Pattern of the email address to which an authentication code was sent
	EmailAddressPattern string `json:"email_address_pattern"`
	// Length of the code; 0 if unknown
	Length int32 `json:"length"`
	// contains filtered or unexported fields
}

Information about the email address authentication code that was sent

func UnmarshalEmailAddressAuthenticationCodeInfo

func UnmarshalEmailAddressAuthenticationCodeInfo(data json.RawMessage) (*EmailAddressAuthenticationCodeInfo, error)

func (*EmailAddressAuthenticationCodeInfo) GetClass

func (*EmailAddressAuthenticationCodeInfo) GetType

func (*EmailAddressAuthenticationCodeInfo) MarshalJSON

func (entity *EmailAddressAuthenticationCodeInfo) MarshalJSON() ([]byte, error)

type Emojis

type Emojis struct {

	// List of emojis
	Emojis []string `json:"emojis"`
	// contains filtered or unexported fields
}

Represents a list of emoji

func UnmarshalEmojis

func UnmarshalEmojis(data json.RawMessage) (*Emojis, error)

func (*Emojis) GetClass

func (*Emojis) GetClass() string

func (*Emojis) GetType

func (*Emojis) GetType() string

func (*Emojis) MarshalJSON

func (entity *Emojis) MarshalJSON() ([]byte, error)

type EnableProxyRequest

type EnableProxyRequest struct {
	// Proxy identifier
	ProxyId int32 `json:"proxy_id"`
}

type EncryptedCredentials

type EncryptedCredentials struct {

	// The encrypted credentials
	Data []byte `json:"data"`
	// The decrypted data hash
	Hash []byte `json:"hash"`
	// Secret for data decryption, encrypted with the service's public key
	Secret []byte `json:"secret"`
	// contains filtered or unexported fields
}

Contains encrypted Telegram Passport data credentials

func UnmarshalEncryptedCredentials

func UnmarshalEncryptedCredentials(data json.RawMessage) (*EncryptedCredentials, error)

func (*EncryptedCredentials) GetClass

func (*EncryptedCredentials) GetClass() string

func (*EncryptedCredentials) GetType

func (*EncryptedCredentials) GetType() string

func (*EncryptedCredentials) MarshalJSON

func (entity *EncryptedCredentials) MarshalJSON() ([]byte, error)

type EncryptedPassportElement

type EncryptedPassportElement struct {

	// Type of Telegram Passport element
	Type PassportElementType `json:"type"`
	// Encrypted JSON-encoded data about the user
	Data []byte `json:"data"`
	// The front side of an identity document
	FrontSide *DatedFile `json:"front_side"`
	// The reverse side of an identity document; may be null
	ReverseSide *DatedFile `json:"reverse_side"`
	// Selfie with the document; may be null
	Selfie *DatedFile `json:"selfie"`
	// List of files containing a certified English translation of the document
	Translation []*DatedFile `json:"translation"`
	// List of attached files
	Files []*DatedFile `json:"files"`
	// Unencrypted data, phone number or email address
	Value string `json:"value"`
	// Hash of the entire element
	Hash string `json:"hash"`
	// contains filtered or unexported fields
}

Contains information about an encrypted Telegram Passport element; for bots only

func UnmarshalEncryptedPassportElement

func UnmarshalEncryptedPassportElement(data json.RawMessage) (*EncryptedPassportElement, error)

func (*EncryptedPassportElement) GetClass

func (*EncryptedPassportElement) GetClass() string

func (*EncryptedPassportElement) GetType

func (*EncryptedPassportElement) GetType() string

func (*EncryptedPassportElement) MarshalJSON

func (entity *EncryptedPassportElement) MarshalJSON() ([]byte, error)

func (*EncryptedPassportElement) UnmarshalJSON

func (encryptedPassportElement *EncryptedPassportElement) UnmarshalJSON(data []byte) error

type Error

type Error struct {

	// Error code; subject to future changes. If the error code is 406, the error message must not be processed in any way and must not be displayed to the user
	Code int32 `json:"code"`
	// Error message; subject to future changes
	Message string `json:"message"`
	// contains filtered or unexported fields
}

An object of this type can be returned on every function call, in case of an error

func UnmarshalError

func UnmarshalError(data json.RawMessage) (*Error, error)

func (*Error) GetClass

func (*Error) GetClass() string

func (*Error) GetType

func (*Error) GetType() string

func (*Error) MarshalJSON

func (entity *Error) MarshalJSON() ([]byte, error)

type ExtraGenerator

type ExtraGenerator func() string

func UuidV4Generator

func UuidV4Generator() ExtraGenerator

type File

type File struct {

	// Unique file identifier
	Id int32 `json:"id"`
	// File size; 0 if unknown
	Size int32 `json:"size"`
	// Expected file size in case the exact file size is unknown, but an approximate size is known. Can be used to show download/upload progress
	ExpectedSize int32 `json:"expected_size"`
	// Information about the local copy of the file
	Local *LocalFile `json:"local"`
	// Information about the remote copy of the file
	Remote *RemoteFile `json:"remote"`
	// contains filtered or unexported fields
}

Represents a file

func UnmarshalFile

func UnmarshalFile(data json.RawMessage) (*File, error)

func (*File) GetClass

func (*File) GetClass() string

func (*File) GetType

func (*File) GetType() string

func (*File) MarshalJSON

func (entity *File) MarshalJSON() ([]byte, error)

type FilePart

type FilePart struct {

	// File bytes
	Data []byte `json:"data"`
	// contains filtered or unexported fields
}

Contains a part of a file

func UnmarshalFilePart

func UnmarshalFilePart(data json.RawMessage) (*FilePart, error)

func (*FilePart) GetClass

func (*FilePart) GetClass() string

func (*FilePart) GetType

func (*FilePart) GetType() string

func (*FilePart) MarshalJSON

func (entity *FilePart) MarshalJSON() ([]byte, error)

type FileType

type FileType interface {
	FileTypeType() string
}

Represents the type of a file

func UnmarshalFileType

func UnmarshalFileType(data json.RawMessage) (FileType, error)

func UnmarshalListOfFileType

func UnmarshalListOfFileType(dataList []json.RawMessage) ([]FileType, error)

type FileTypeAnimation

type FileTypeAnimation struct {
	// contains filtered or unexported fields
}

The file is an animation

func UnmarshalFileTypeAnimation

func UnmarshalFileTypeAnimation(data json.RawMessage) (*FileTypeAnimation, error)

func (*FileTypeAnimation) FileTypeType

func (*FileTypeAnimation) FileTypeType() string

func (*FileTypeAnimation) GetClass

func (*FileTypeAnimation) GetClass() string

func (*FileTypeAnimation) GetType

func (*FileTypeAnimation) GetType() string

func (*FileTypeAnimation) MarshalJSON

func (entity *FileTypeAnimation) MarshalJSON() ([]byte, error)

type FileTypeAudio

type FileTypeAudio struct {
	// contains filtered or unexported fields
}

The file is an audio file

func UnmarshalFileTypeAudio

func UnmarshalFileTypeAudio(data json.RawMessage) (*FileTypeAudio, error)

func (*FileTypeAudio) FileTypeType

func (*FileTypeAudio) FileTypeType() string

func (*FileTypeAudio) GetClass

func (*FileTypeAudio) GetClass() string

func (*FileTypeAudio) GetType

func (*FileTypeAudio) GetType() string

func (*FileTypeAudio) MarshalJSON

func (entity *FileTypeAudio) MarshalJSON() ([]byte, error)

type FileTypeDocument

type FileTypeDocument struct {
	// contains filtered or unexported fields
}

The file is a document

func UnmarshalFileTypeDocument

func UnmarshalFileTypeDocument(data json.RawMessage) (*FileTypeDocument, error)

func (*FileTypeDocument) FileTypeType

func (*FileTypeDocument) FileTypeType() string

func (*FileTypeDocument) GetClass

func (*FileTypeDocument) GetClass() string

func (*FileTypeDocument) GetType

func (*FileTypeDocument) GetType() string

func (*FileTypeDocument) MarshalJSON

func (entity *FileTypeDocument) MarshalJSON() ([]byte, error)

type FileTypeNone

type FileTypeNone struct {
	// contains filtered or unexported fields
}

The data is not a file

func UnmarshalFileTypeNone

func UnmarshalFileTypeNone(data json.RawMessage) (*FileTypeNone, error)

func (*FileTypeNone) FileTypeType

func (*FileTypeNone) FileTypeType() string

func (*FileTypeNone) GetClass

func (*FileTypeNone) GetClass() string

func (*FileTypeNone) GetType

func (*FileTypeNone) GetType() string

func (*FileTypeNone) MarshalJSON

func (entity *FileTypeNone) MarshalJSON() ([]byte, error)

type FileTypePhoto

type FileTypePhoto struct {
	// contains filtered or unexported fields
}

The file is a photo

func UnmarshalFileTypePhoto

func UnmarshalFileTypePhoto(data json.RawMessage) (*FileTypePhoto, error)

func (*FileTypePhoto) FileTypeType

func (*FileTypePhoto) FileTypeType() string

func (*FileTypePhoto) GetClass

func (*FileTypePhoto) GetClass() string

func (*FileTypePhoto) GetType

func (*FileTypePhoto) GetType() string

func (*FileTypePhoto) MarshalJSON

func (entity *FileTypePhoto) MarshalJSON() ([]byte, error)

type FileTypeProfilePhoto

type FileTypeProfilePhoto struct {
	// contains filtered or unexported fields
}

The file is a profile photo

func UnmarshalFileTypeProfilePhoto

func UnmarshalFileTypeProfilePhoto(data json.RawMessage) (*FileTypeProfilePhoto, error)

func (*FileTypeProfilePhoto) FileTypeType

func (*FileTypeProfilePhoto) FileTypeType() string

func (*FileTypeProfilePhoto) GetClass

func (*FileTypeProfilePhoto) GetClass() string

func (*FileTypeProfilePhoto) GetType

func (*FileTypeProfilePhoto) GetType() string

func (*FileTypeProfilePhoto) MarshalJSON

func (entity *FileTypeProfilePhoto) MarshalJSON() ([]byte, error)

type FileTypeSecret

type FileTypeSecret struct {
	// contains filtered or unexported fields
}

The file was sent to a secret chat (the file type is not known to the server)

func UnmarshalFileTypeSecret

func UnmarshalFileTypeSecret(data json.RawMessage) (*FileTypeSecret, error)

func (*FileTypeSecret) FileTypeType

func (*FileTypeSecret) FileTypeType() string

func (*FileTypeSecret) GetClass

func (*FileTypeSecret) GetClass() string

func (*FileTypeSecret) GetType

func (*FileTypeSecret) GetType() string

func (*FileTypeSecret) MarshalJSON

func (entity *FileTypeSecret) MarshalJSON() ([]byte, error)

type FileTypeSecretThumbnail

type FileTypeSecretThumbnail struct {
	// contains filtered or unexported fields
}

The file is a thumbnail of a file from a secret chat

func UnmarshalFileTypeSecretThumbnail

func UnmarshalFileTypeSecretThumbnail(data json.RawMessage) (*FileTypeSecretThumbnail, error)

func (*FileTypeSecretThumbnail) FileTypeType

func (*FileTypeSecretThumbnail) FileTypeType() string

func (*FileTypeSecretThumbnail) GetClass

func (*FileTypeSecretThumbnail) GetClass() string

func (*FileTypeSecretThumbnail) GetType

func (*FileTypeSecretThumbnail) GetType() string

func (*FileTypeSecretThumbnail) MarshalJSON

func (entity *FileTypeSecretThumbnail) MarshalJSON() ([]byte, error)

type FileTypeSecure

type FileTypeSecure struct {
	// contains filtered or unexported fields
}

The file is a file from Secure storage used for storing Telegram Passport files

func UnmarshalFileTypeSecure

func UnmarshalFileTypeSecure(data json.RawMessage) (*FileTypeSecure, error)

func (*FileTypeSecure) FileTypeType

func (*FileTypeSecure) FileTypeType() string

func (*FileTypeSecure) GetClass

func (*FileTypeSecure) GetClass() string

func (*FileTypeSecure) GetType

func (*FileTypeSecure) GetType() string

func (*FileTypeSecure) MarshalJSON

func (entity *FileTypeSecure) MarshalJSON() ([]byte, error)

type FileTypeSticker

type FileTypeSticker struct {
	// contains filtered or unexported fields
}

The file is a sticker

func UnmarshalFileTypeSticker

func UnmarshalFileTypeSticker(data json.RawMessage) (*FileTypeSticker, error)

func (*FileTypeSticker) FileTypeType

func (*FileTypeSticker) FileTypeType() string

func (*FileTypeSticker) GetClass

func (*FileTypeSticker) GetClass() string

func (*FileTypeSticker) GetType

func (*FileTypeSticker) GetType() string

func (*FileTypeSticker) MarshalJSON

func (entity *FileTypeSticker) MarshalJSON() ([]byte, error)

type FileTypeThumbnail

type FileTypeThumbnail struct {
	// contains filtered or unexported fields
}

The file is a thumbnail of another file

func UnmarshalFileTypeThumbnail

func UnmarshalFileTypeThumbnail(data json.RawMessage) (*FileTypeThumbnail, error)

func (*FileTypeThumbnail) FileTypeType

func (*FileTypeThumbnail) FileTypeType() string

func (*FileTypeThumbnail) GetClass

func (*FileTypeThumbnail) GetClass() string

func (*FileTypeThumbnail) GetType

func (*FileTypeThumbnail) GetType() string

func (*FileTypeThumbnail) MarshalJSON

func (entity *FileTypeThumbnail) MarshalJSON() ([]byte, error)

type FileTypeUnknown

type FileTypeUnknown struct {
	// contains filtered or unexported fields
}

The file type is not yet known

func UnmarshalFileTypeUnknown

func UnmarshalFileTypeUnknown(data json.RawMessage) (*FileTypeUnknown, error)

func (*FileTypeUnknown) FileTypeType

func (*FileTypeUnknown) FileTypeType() string

func (*FileTypeUnknown) GetClass

func (*FileTypeUnknown) GetClass() string

func (*FileTypeUnknown) GetType

func (*FileTypeUnknown) GetType() string

func (*FileTypeUnknown) MarshalJSON

func (entity *FileTypeUnknown) MarshalJSON() ([]byte, error)

type FileTypeVideo

type FileTypeVideo struct {
	// contains filtered or unexported fields
}

The file is a video

func UnmarshalFileTypeVideo

func UnmarshalFileTypeVideo(data json.RawMessage) (*FileTypeVideo, error)

func (*FileTypeVideo) FileTypeType

func (*FileTypeVideo) FileTypeType() string

func (*FileTypeVideo) GetClass

func (*FileTypeVideo) GetClass() string

func (*FileTypeVideo) GetType

func (*FileTypeVideo) GetType() string

func (*FileTypeVideo) MarshalJSON

func (entity *FileTypeVideo) MarshalJSON() ([]byte, error)

type FileTypeVideoNote

type FileTypeVideoNote struct {
	// contains filtered or unexported fields
}

The file is a video note

func UnmarshalFileTypeVideoNote

func UnmarshalFileTypeVideoNote(data json.RawMessage) (*FileTypeVideoNote, error)

func (*FileTypeVideoNote) FileTypeType

func (*FileTypeVideoNote) FileTypeType() string

func (*FileTypeVideoNote) GetClass

func (*FileTypeVideoNote) GetClass() string

func (*FileTypeVideoNote) GetType

func (*FileTypeVideoNote) GetType() string

func (*FileTypeVideoNote) MarshalJSON

func (entity *FileTypeVideoNote) MarshalJSON() ([]byte, error)

type FileTypeVoiceNote

type FileTypeVoiceNote struct {
	// contains filtered or unexported fields
}

The file is a voice note

func UnmarshalFileTypeVoiceNote

func UnmarshalFileTypeVoiceNote(data json.RawMessage) (*FileTypeVoiceNote, error)

func (*FileTypeVoiceNote) FileTypeType

func (*FileTypeVoiceNote) FileTypeType() string

func (*FileTypeVoiceNote) GetClass

func (*FileTypeVoiceNote) GetClass() string

func (*FileTypeVoiceNote) GetType

func (*FileTypeVoiceNote) GetType() string

func (*FileTypeVoiceNote) MarshalJSON

func (entity *FileTypeVoiceNote) MarshalJSON() ([]byte, error)

type FileTypeWallpaper

type FileTypeWallpaper struct {
	// contains filtered or unexported fields
}

The file is a wallpaper or a background pattern

func UnmarshalFileTypeWallpaper

func UnmarshalFileTypeWallpaper(data json.RawMessage) (*FileTypeWallpaper, error)

func (*FileTypeWallpaper) FileTypeType

func (*FileTypeWallpaper) FileTypeType() string

func (*FileTypeWallpaper) GetClass

func (*FileTypeWallpaper) GetClass() string

func (*FileTypeWallpaper) GetType

func (*FileTypeWallpaper) GetType() string

func (*FileTypeWallpaper) MarshalJSON

func (entity *FileTypeWallpaper) MarshalJSON() ([]byte, error)

type FinishFileGenerationRequest

type FinishFileGenerationRequest struct {
	// The identifier of the generation process
	GenerationId JsonInt64 `json:"generation_id"`
	// If set, means that file generation has failed and should be terminated
	Error *Error `json:"error"`
}

type FormattedText

type FormattedText struct {

	// The text
	Text string `json:"text"`
	// Entities contained in the text. Entities can be nested, but must not mutually intersect with each other. Pre, Code and PreCode entities can't contain other entities. Bold, Italic, Underline and Strikethrough entities can contain and to be contained in all other entities. All other entities can't contain each other
	Entities []*TextEntity `json:"entities"`
	// contains filtered or unexported fields
}

A text with some entities

func UnmarshalFormattedText

func UnmarshalFormattedText(data json.RawMessage) (*FormattedText, error)

func (*FormattedText) GetClass

func (*FormattedText) GetClass() string

func (*FormattedText) GetType

func (*FormattedText) GetType() string

func (*FormattedText) MarshalJSON

func (entity *FormattedText) MarshalJSON() ([]byte, error)

type ForwardMessagesRequest

type ForwardMessagesRequest struct {
	// Identifier of the chat to which to forward messages
	ChatId int64 `json:"chat_id"`
	// Identifier of the chat from which to forward messages
	FromChatId int64 `json:"from_chat_id"`
	// Identifiers of the messages to forward. Message identifiers must be in a strictly increasing order
	MessageIds []int64 `json:"message_ids"`
	// Options to be used to send the messages
	Options *MessageSendOptions `json:"options"`
	// True, if content of the messages needs to be copied without links to the original messages. Always true if the messages are forwarded to a secret chat
	SendCopy bool `json:"send_copy"`
	// True, if media caption of message copies needs to be removed. Ignored if send_copy is false
	RemoveCaption bool `json:"remove_caption"`
}

type FoundMessages

type FoundMessages struct {

	// Approximate total count of messages found; -1 if unknown
	TotalCount int32 `json:"total_count"`
	// List of messages
	Messages []*Message `json:"messages"`
	// The offset for the next request. If empty, there are no more results
	NextOffset string `json:"next_offset"`
	// contains filtered or unexported fields
}

Contains a list of messages found by a search

func UnmarshalFoundMessages

func UnmarshalFoundMessages(data json.RawMessage) (*FoundMessages, error)

func (*FoundMessages) GetClass

func (*FoundMessages) GetClass() string

func (*FoundMessages) GetType

func (*FoundMessages) GetType() string

func (*FoundMessages) MarshalJSON

func (entity *FoundMessages) MarshalJSON() ([]byte, error)

type Game

type Game struct {

	// Game ID
	Id JsonInt64 `json:"id"`
	// Game short name. To share a game use the URL https://t.me/{bot_username}?game={game_short_name}
	ShortName string `json:"short_name"`
	// Game title
	Title string `json:"title"`
	// Game text, usually containing scoreboards for a game
	Text *FormattedText `json:"text"`
	// Game description
	Description string `json:"description"`
	// Game photo
	Photo *Photo `json:"photo"`
	// Game animation; may be null
	Animation *Animation `json:"animation"`
	// contains filtered or unexported fields
}

Describes a game

func UnmarshalGame

func UnmarshalGame(data json.RawMessage) (*Game, error)

func (*Game) GetClass

func (*Game) GetClass() string

func (*Game) GetType

func (*Game) GetType() string

func (*Game) MarshalJSON

func (entity *Game) MarshalJSON() ([]byte, error)

type GameHighScore

type GameHighScore struct {

	// Position in the high score table
	Position int32 `json:"position"`
	// User identifier
	UserId int32 `json:"user_id"`
	// User score
	Score int32 `json:"score"`
	// contains filtered or unexported fields
}

Contains one row of the game high score table

func UnmarshalGameHighScore

func UnmarshalGameHighScore(data json.RawMessage) (*GameHighScore, error)

func (*GameHighScore) GetClass

func (*GameHighScore) GetClass() string

func (*GameHighScore) GetType

func (*GameHighScore) GetType() string

func (*GameHighScore) MarshalJSON

func (entity *GameHighScore) MarshalJSON() ([]byte, error)

type GameHighScores

type GameHighScores struct {

	// A list of game high scores
	Scores []*GameHighScore `json:"scores"`
	// contains filtered or unexported fields
}

Contains a list of game high scores

func UnmarshalGameHighScores

func UnmarshalGameHighScores(data json.RawMessage) (*GameHighScores, error)

func (*GameHighScores) GetClass

func (*GameHighScores) GetClass() string

func (*GameHighScores) GetType

func (*GameHighScores) GetType() string

func (*GameHighScores) MarshalJSON

func (entity *GameHighScores) MarshalJSON() ([]byte, error)

type GenerateChatInviteLinkRequest

type GenerateChatInviteLinkRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type GetAllPassportElementsRequest

type GetAllPassportElementsRequest struct {
	// Password of the current user
	Password string `json:"password"`
}

type GetArchivedStickerSetsRequest

type GetArchivedStickerSetsRequest struct {
	// Pass true to return mask stickers sets; pass false to return ordinary sticker sets
	IsMasks bool `json:"is_masks"`
	// Identifier of the sticker set from which to return the result
	OffsetStickerSetId JsonInt64 `json:"offset_sticker_set_id"`
	// The maximum number of sticker sets to return
	Limit int32 `json:"limit"`
}

type GetAttachedStickerSetsRequest

type GetAttachedStickerSetsRequest struct {
	// File identifier
	FileId int32 `json:"file_id"`
}

type GetBackgroundUrlRequest

type GetBackgroundUrlRequest struct {
	// Background name
	Name string `json:"name"`
	// Background type
	Type BackgroundType `json:"type"`
}

type GetBackgroundsRequest

type GetBackgroundsRequest struct {
	// True, if the backgrounds must be ordered for dark theme
	ForDarkTheme bool `json:"for_dark_theme"`
}

type GetBankCardInfoRequest

type GetBankCardInfoRequest struct {
	// The bank card number
	BankCardNumber string `json:"bank_card_number"`
}

type GetBasicGroupFullInfoRequest

type GetBasicGroupFullInfoRequest struct {
	// Basic group identifier
	BasicGroupId int32 `json:"basic_group_id"`
}

type GetBasicGroupRequest

type GetBasicGroupRequest struct {
	// Basic group identifier
	BasicGroupId int32 `json:"basic_group_id"`
}

type GetBlockedMessageSendersRequest

type GetBlockedMessageSendersRequest struct {
	// Number of users and chats to skip in the result; must be non-negative
	Offset int32 `json:"offset"`
	// The maximum number of users and chats to return; up to 100
	Limit int32 `json:"limit"`
}

type GetCallbackQueryAnswerRequest

type GetCallbackQueryAnswerRequest struct {
	// Identifier of the chat with the message
	ChatId int64 `json:"chat_id"`
	// Identifier of the message from which the query originated
	MessageId int64 `json:"message_id"`
	// Query payload
	Payload CallbackQueryPayload `json:"payload"`
}

type GetCallbackQueryMessageRequest

type GetCallbackQueryMessageRequest struct {
	// Identifier of the chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Message identifier
	MessageId int64 `json:"message_id"`
	// Identifier of the callback query
	CallbackQueryId JsonInt64 `json:"callback_query_id"`
}

type GetChatAdministratorsRequest

type GetChatAdministratorsRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type GetChatEventLogRequest

type GetChatEventLogRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Search query by which to filter events
	Query string `json:"query"`
	// Identifier of an event from which to return results. Use 0 to get results from the latest events
	FromEventId JsonInt64 `json:"from_event_id"`
	// The maximum number of events to return; up to 100
	Limit int32 `json:"limit"`
	// The types of events to return. By default, all types will be returned
	Filters *ChatEventLogFilters `json:"filters"`
	// User identifiers by which to filter events. By default, events relating to all users will be returned
	UserIds []int32 `json:"user_ids"`
}

type GetChatFilterDefaultIconNameRequest

type GetChatFilterDefaultIconNameRequest struct {
	// Chat filter
	Filter *ChatFilter `json:"filter"`
}

type GetChatFilterRequest

type GetChatFilterRequest struct {
	// Chat filter identifier
	ChatFilterId int32 `json:"chat_filter_id"`
}

type GetChatHistoryRequest

type GetChatHistoryRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Identifier of the message starting from which history must be fetched; use 0 to get results from the last message
	FromMessageId int64 `json:"from_message_id"`
	// Specify 0 to get results from exactly the from_message_id or a negative offset up to 99 to get additionally some newer messages
	Offset int32 `json:"offset"`
	// The maximum number of messages to be returned; must be positive and can't be greater than 100. If the offset is negative, the limit must be greater than or equal to -offset. Fewer messages may be returned than specified by the limit, even if the end of the message history has not been reached
	Limit int32 `json:"limit"`
	// If true, returns only messages that are available locally without sending network requests
	OnlyLocal bool `json:"only_local"`
}

type GetChatListsToAddChatRequest

type GetChatListsToAddChatRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type GetChatMemberRequest

type GetChatMemberRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// User identifier
	UserId int32 `json:"user_id"`
}

type GetChatMessageByDateRequest

type GetChatMessageByDateRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Point in time (Unix timestamp) relative to which to search for messages
	Date int32 `json:"date"`
}

type GetChatMessageCountRequest

type GetChatMessageCountRequest struct {
	// Identifier of the chat in which to count messages
	ChatId int64 `json:"chat_id"`
	// Filter for message content; searchMessagesFilterEmpty is unsupported in this function
	Filter SearchMessagesFilter `json:"filter"`
	// If true, returns count that is available locally without sending network requests, returning -1 if the number of messages is unknown
	ReturnLocal bool `json:"return_local"`
}

type GetChatNotificationSettingsExceptionsRequest

type GetChatNotificationSettingsExceptionsRequest struct {
	// If specified, only chats from the specified scope will be returned
	Scope NotificationSettingsScope `json:"scope"`
	// If true, also chats with non-default sound will be returned
	CompareSound bool `json:"compare_sound"`
}

type GetChatPinnedMessageRequest

type GetChatPinnedMessageRequest struct {
	// Identifier of the chat the message belongs to
	ChatId int64 `json:"chat_id"`
}

type GetChatRequest

type GetChatRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type GetChatScheduledMessagesRequest

type GetChatScheduledMessagesRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
}

type GetChatStatisticsRequest

type GetChatStatisticsRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Pass true if a dark theme is used by the application
	IsDark bool `json:"is_dark"`
}

type GetChatStatisticsUrlRequest

type GetChatStatisticsUrlRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Parameters from "tg://statsrefresh?params=******" link
	Parameters string `json:"parameters"`
	// Pass true if a URL with the dark theme must be returned
	IsDark bool `json:"is_dark"`
}

type GetChatsRequest

type GetChatsRequest struct {
	// The chat list in which to return chats
	ChatList ChatList `json:"chat_list"`
	// Chat order to return chats from
	OffsetOrder JsonInt64 `json:"offset_order"`
	// Chat identifier to return chats from
	OffsetChatId int64 `json:"offset_chat_id"`
	// The maximum number of chats to be returned. It is possible that fewer chats than the limit are returned even if the end of the list is not reached
	Limit int32 `json:"limit"`
}

type GetCreatedPublicChatsRequest

type GetCreatedPublicChatsRequest struct {
	// Type of the public chats to return
	Type PublicChatType `json:"type"`
}

type GetDeepLinkInfoRequest

type GetDeepLinkInfoRequest struct {
	// The link
	Link string `json:"link"`
}

type GetEmojiSuggestionsUrlRequest

type GetEmojiSuggestionsUrlRequest struct {
	// Language code for which the emoji replacements will be suggested
	LanguageCode string `json:"language_code"`
}

type GetFileDownloadedPrefixSizeRequest

type GetFileDownloadedPrefixSizeRequest struct {
	// Identifier of the file
	FileId int32 `json:"file_id"`
	// Offset from which downloaded prefix size should be calculated
	Offset int32 `json:"offset"`
}

type GetFileExtensionRequest

type GetFileExtensionRequest struct {
	// The MIME type of the file
	MimeType string `json:"mime_type"`
}

type GetFileMimeTypeRequest

type GetFileMimeTypeRequest struct {
	// The name of the file or path to the file
	FileName string `json:"file_name"`
}

type GetFileRequest

type GetFileRequest struct {
	// Identifier of the file to get
	FileId int32 `json:"file_id"`
}

type GetGameHighScoresRequest

type GetGameHighScoresRequest struct {
	// The chat that contains the message with the game
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// User identifier
	UserId int32 `json:"user_id"`
}

type GetGroupsInCommonRequest

type GetGroupsInCommonRequest struct {
	// User identifier
	UserId int32 `json:"user_id"`
	// Chat identifier starting from which to return chats; use 0 for the first request
	OffsetChatId int64 `json:"offset_chat_id"`
	// The maximum number of chats to be returned; up to 100
	Limit int32 `json:"limit"`
}

type GetInlineGameHighScoresRequest

type GetInlineGameHighScoresRequest struct {
	// Inline message identifier
	InlineMessageId string `json:"inline_message_id"`
	// User identifier
	UserId int32 `json:"user_id"`
}

type GetInlineQueryResultsRequest

type GetInlineQueryResultsRequest struct {
	// The identifier of the target bot
	BotUserId int32 `json:"bot_user_id"`
	// Identifier of the chat where the query was sent
	ChatId int64 `json:"chat_id"`
	// Location of the user, only if needed
	UserLocation *Location `json:"user_location"`
	// Text of the query
	Query string `json:"query"`
	// Offset of the first entry to return
	Offset string `json:"offset"`
}

type GetInstalledStickerSetsRequest

type GetInstalledStickerSetsRequest struct {
	// Pass true to return mask sticker sets; pass false to return ordinary sticker sets
	IsMasks bool `json:"is_masks"`
}

type GetJsonStringRequest

type GetJsonStringRequest struct {
	// The JsonValue object
	JsonValue JsonValue `json:"json_value"`
}

type GetJsonValueRequest

type GetJsonValueRequest struct {
	// The JSON-serialized string
	Json string `json:"json"`
}

type GetLanguagePackInfoRequest

type GetLanguagePackInfoRequest struct {
	// Language pack identifier
	LanguagePackId string `json:"language_pack_id"`
}

type GetLanguagePackStringRequest

type GetLanguagePackStringRequest struct {
	// Path to the language pack database in which strings are stored
	LanguagePackDatabasePath string `json:"language_pack_database_path"`
	// Localization target to which the language pack belongs
	LocalizationTarget string `json:"localization_target"`
	// Language pack identifier
	LanguagePackId string `json:"language_pack_id"`
	// Language pack key of the string to be returned
	Key string `json:"key"`
}

type GetLanguagePackStringsRequest

type GetLanguagePackStringsRequest struct {
	// Language pack identifier of the strings to be returned
	LanguagePackId string `json:"language_pack_id"`
	// Language pack keys of the strings to be returned; leave empty to request all available strings
	Keys []string `json:"keys"`
}

type GetLocalizationTargetInfoRequest

type GetLocalizationTargetInfoRequest struct {
	// If true, returns only locally available information without sending network requests
	OnlyLocal bool `json:"only_local"`
}

type GetLogTagVerbosityLevelRequest

type GetLogTagVerbosityLevelRequest struct {
	// Logging tag to change verbosity level
	Tag string `json:"tag"`
}

type GetLoginUrlInfoRequest

type GetLoginUrlInfoRequest struct {
	// Chat identifier of the message with the button
	ChatId int64 `json:"chat_id"`
	// Message identifier of the message with the button
	MessageId int64 `json:"message_id"`
	// Button identifier
	ButtonId int32 `json:"button_id"`
}

type GetLoginUrlRequest

type GetLoginUrlRequest struct {
	// Chat identifier of the message with the button
	ChatId int64 `json:"chat_id"`
	// Message identifier of the message with the button
	MessageId int64 `json:"message_id"`
	// Button identifier
	ButtonId int32 `json:"button_id"`
	// True, if the user allowed the bot to send them messages
	AllowWriteAccess bool `json:"allow_write_access"`
}

type GetMapThumbnailFileRequest

type GetMapThumbnailFileRequest struct {
	// Location of the map center
	Location *Location `json:"location"`
	// Map zoom level; 13-20
	Zoom int32 `json:"zoom"`
	// Map width in pixels before applying scale; 16-1024
	Width int32 `json:"width"`
	// Map height in pixels before applying scale; 16-1024
	Height int32 `json:"height"`
	// Map scale; 1-3
	Scale int32 `json:"scale"`
	// Identifier of a chat, in which the thumbnail will be shown. Use 0 if unknown
	ChatId int64 `json:"chat_id"`
}

type GetMarkdownTextRequest

type GetMarkdownTextRequest struct {
	// The text
	Text *FormattedText `json:"text"`
}

type GetMessageEmbeddingCodeRequest

type GetMessageEmbeddingCodeRequest struct {
	// Identifier of the chat to which the message belongs
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// Pass true to return an HTML code for embedding of the whole media album
	ForAlbum bool `json:"for_album"`
}

type GetMessageLinkInfoRequest

type GetMessageLinkInfoRequest struct {
	// The message link in the format "https://t.me/c/...", or "tg://privatepost?...", or "https://t.me/username/...", or "tg://resolve?..."
	Url string `json:"url"`
}

type GetMessageLinkRequest

type GetMessageLinkRequest struct {
	// Identifier of the chat to which the message belongs
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
	// Pass true to create a link for the whole media album
	ForAlbum bool `json:"for_album"`
	// Pass true to create a link to the message as a channel post comment, or from a message thread
	ForComment bool `json:"for_comment"`
}

type GetMessageLocallyRequest

type GetMessageLocallyRequest struct {
	// Identifier of the chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message to get
	MessageId int64 `json:"message_id"`
}

type GetMessagePublicForwardsRequest

type GetMessagePublicForwardsRequest struct {
	// Chat identifier of the message
	ChatId int64 `json:"chat_id"`
	// Message identifier
	MessageId int64 `json:"message_id"`
	// Offset of the first entry to return as received from the previous request; use empty string to get first chunk of results
	Offset string `json:"offset"`
	// The maximum number of messages to be returned; must be positive and can't be greater than 100. Fewer messages may be returned than specified by the limit, even if the end of the list has not been reached
	Limit int32 `json:"limit"`
}

type GetMessageRequest

type GetMessageRequest struct {
	// Identifier of the chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message to get
	MessageId int64 `json:"message_id"`
}

type GetMessageStatisticsRequest

type GetMessageStatisticsRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Message identifier
	MessageId int64 `json:"message_id"`
	// Pass true if a dark theme is used by the application
	IsDark bool `json:"is_dark"`
}

type GetMessageThreadHistoryRequest

type GetMessageThreadHistoryRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Message identifier, which thread history needs to be returned
	MessageId int64 `json:"message_id"`
	// Identifier of the message starting from which history must be fetched; use 0 to get results from the last message
	FromMessageId int64 `json:"from_message_id"`
	// Specify 0 to get results from exactly the from_message_id or a negative offset up to 99 to get additionally some newer messages
	Offset int32 `json:"offset"`
	// The maximum number of messages to be returned; must be positive and can't be greater than 100. If the offset is negative, the limit must be greater than or equal to -offset. Fewer messages may be returned than specified by the limit, even if the end of the message thread history has not been reached
	Limit int32 `json:"limit"`
}

type GetMessageThreadRequest

type GetMessageThreadRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// Identifier of the message
	MessageId int64 `json:"message_id"`
}

type GetMessagesRequest

type GetMessagesRequest struct {
	// Identifier of the chat the messages belong to
	ChatId int64 `json:"chat_id"`
	// Identifiers of the messages to get
	MessageIds []int64 `json:"message_ids"`
}

type GetNetworkStatisticsRequest

type GetNetworkStatisticsRequest struct {
	// If true, returns only data for the current library launch
	OnlyCurrent bool `json:"only_current"`
}

type GetOptionRequest

type GetOptionRequest struct {
	// The name of the option
	Name string `json:"name"`
}

type GetPassportAuthorizationFormAvailableElementsRequest

type GetPassportAuthorizationFormAvailableElementsRequest struct {
	// Authorization form identifier
	AutorizationFormId int32 `json:"autorization_form_id"`
	// Password of the current user
	Password string `json:"password"`
}

type GetPassportAuthorizationFormRequest

type GetPassportAuthorizationFormRequest struct {
	// User identifier of the service's bot
	BotUserId int32 `json:"bot_user_id"`
	// Telegram Passport element types requested by the service
	Scope string `json:"scope"`
	// Service's public_key
	PublicKey string `json:"public_key"`
	// Authorization form nonce provided by the service
	Nonce string `json:"nonce"`
}

type GetPassportElementRequest

type GetPassportElementRequest struct {
	// Telegram Passport element type
	Type PassportElementType `json:"type"`
	// Password of the current user
	Password string `json:"password"`
}

type GetPaymentFormRequest

type GetPaymentFormRequest struct {
	// Chat identifier of the Invoice message
	ChatId int64 `json:"chat_id"`
	// Message identifier
	MessageId int64 `json:"message_id"`
}

type GetPaymentReceiptRequest

type GetPaymentReceiptRequest struct {
	// Chat identifier of the PaymentSuccessful message
	ChatId int64 `json:"chat_id"`
	// Message identifier
	MessageId int64 `json:"message_id"`
}

type GetPhoneNumberInfoRequest

type GetPhoneNumberInfoRequest struct {
	// The phone number prefix
	PhoneNumberPrefix string `json:"phone_number_prefix"`
}

type GetPollVotersRequest

type GetPollVotersRequest struct {
	// Identifier of the chat to which the poll belongs
	ChatId int64 `json:"chat_id"`
	// Identifier of the message containing the poll
	MessageId int64 `json:"message_id"`
	// 0-based identifier of the answer option
	OptionId int32 `json:"option_id"`
	// Number of users to skip in the result; must be non-negative
	Offset int32 `json:"offset"`
	// The maximum number of users to be returned; must be positive and can't be greater than 50. Fewer users may be returned than specified by the limit, even if the end of the voter list has not been reached
	Limit int32 `json:"limit"`
}

type GetPreferredCountryLanguageRequest

type GetPreferredCountryLanguageRequest struct {
	// A two-letter ISO 3166-1 alpha-2 country code
	CountryCode string `json:"country_code"`
}

type GetProxyLinkRequest

type GetProxyLinkRequest struct {
	// Proxy identifier
	ProxyId int32 `json:"proxy_id"`
}

type GetPushReceiverIdRequest

type GetPushReceiverIdRequest struct {
	// JSON-encoded push notification payload
	Payload string `json:"payload"`
}

type GetRecentStickersRequest

type GetRecentStickersRequest struct {
	// Pass true to return stickers and masks that were recently attached to photos or video files; pass false to return recently sent stickers
	IsAttached bool `json:"is_attached"`
}

type GetRecentlyVisitedTMeUrlsRequest

type GetRecentlyVisitedTMeUrlsRequest struct {
	// Google Play referrer to identify the user
	Referrer string `json:"referrer"`
}

type GetRecoveryEmailAddressRequest

type GetRecoveryEmailAddressRequest struct {
	// The password for the current user
	Password string `json:"password"`
}

type GetRemoteFileRequest

type GetRemoteFileRequest struct {
	// Remote identifier of the file to get
	RemoteFileId string `json:"remote_file_id"`
	// File type, if known
	FileType FileType `json:"file_type"`
}

type GetRepliedMessageRequest

type GetRepliedMessageRequest struct {
	// Identifier of the chat the message belongs to
	ChatId int64 `json:"chat_id"`
	// Identifier of the message reply to which to get
	MessageId int64 `json:"message_id"`
}

type GetScopeNotificationSettingsRequest

type GetScopeNotificationSettingsRequest struct {
	// Types of chats for which to return the notification settings information
	Scope NotificationSettingsScope `json:"scope"`
}

type GetSecretChatRequest

type GetSecretChatRequest struct {
	// Secret chat identifier
	SecretChatId int32 `json:"secret_chat_id"`
}

type GetStatisticalGraphRequest

type GetStatisticalGraphRequest struct {
	// Chat identifier
	ChatId int64 `json:"chat_id"`
	// The token for graph loading
	Token string `json:"token"`
	// X-value for zoomed in graph or 0 otherwise
	X int64 `json:"x"`
}

type GetStickerEmojisRequest

type GetStickerEmojisRequest struct {
	// Sticker file identifier
	Sticker InputFile `json:"sticker"`
}

type GetStickerSetRequest

type GetStickerSetRequest struct {
	// Identifier of the sticker set
	SetId JsonInt64 `json:"set_id"`
}

type GetStickersRequest

type GetStickersRequest struct {
	// String representation of emoji. If empty, returns all known installed stickers
	Emoji string `json:"emoji"`
	// The maximum number of stickers to be returned
	Limit int32 `json:"limit"`
}

type GetStorageStatisticsRequest

type GetStorageStatisticsRequest struct {
	// The maximum number of chats with the largest storage usage for which separate statistics should be returned. All other chats will be grouped in entries with chat_id == 0. If the chat info database is not used, the chat_limit is ignored and is always set to 0
	ChatLimit int32 `json:"chat_limit"`
}

type GetSupergroupFullInfoRequest

type GetSupergroupFullInfoRequest struct {
	// Supergroup or channel identifier
	SupergroupId int32 `json:"supergroup_id"`
}

type GetSupergroupMembersRequest

type GetSupergroupMembersRequest struct {
	// Identifier of the supergroup or channel
	SupergroupId int32 `json:"supergroup_id"`
	// The type of users to return. By default, supergroupMembersFilterRecent
	Filter SupergroupMembersFilter `json:"filter"`
	// Number of users to skip
	Offset int32 `json:"offset"`
	// The maximum number of users be returned; up to 200
	Limit int32 `json:"limit"`
}

type GetSupergroupRequest

type GetSupergroupRequest struct {
	// Supergroup or channel identifier
	SupergroupId int32 `json:"supergroup_id"`
}

type GetTextEntitiesRequest

type GetTextEntitiesRequest struct {
	// The text in which to look for entites
	Text string `json:"text"`
}

type GetTopChatsRequest

type GetTopChatsRequest struct {
	// Category of chats to be returned
	Category TopChatCategory `json:"category"`
	// The maximum number of chats to be returned; up to 30
	Limit int32 `json:"limit"`
}

type GetTrendingStickerSetsRequest

type GetTrendingStickerSetsRequest struct {
	// The offset from which to return the sticker sets; must be non-negative
	Offset int32 `json:"offset"`
	// The maximum number of sticker sets to be returned; must be non-negative. Fewer sticker sets may be returned than specified by the limit, even if the end of the list has not been reached
	Limit int32 `json:"limit"`
}

type GetUserFullInfoRequest

type GetUserFullInfoRequest struct {
	// User identifier
	UserId int32 `json:"user_id"`
}

type GetUserPrivacySettingRulesRequest

type GetUserPrivacySettingRulesRequest struct {
	// The privacy setting
	Setting UserPrivacySetting `json:"setting"`
}

type GetUserProfilePhotosRequest

type GetUserProfilePhotosRequest struct {
	// User identifier
	UserId int32 `json:"user_id"`
	// The number of photos to skip; must be non-negative
	Offset int32 `json:"offset"`
	// The maximum number of photos to be returned; up to 100
	Limit int32 `json:"limit"`
}

type GetUserRequest

type GetUserRequest struct {
	// User identifier
	UserId int32 `json:"user_id"`
}

type GetWebPageInstantViewRequest

type GetWebPageInstantViewRequest struct {
	// The web page URL
	Url string `json:"url"`
	// If true, the full instant view for the web page will be returned
	ForceFull bool `json:"force_full"`
}

type GetWebPagePreviewRequest

type GetWebPagePreviewRequest struct {
	// Message text with formatting
	Text *FormattedText `json:"text"`
}

type Hashtags

type Hashtags struct {

	// A list of hashtags
	Hashtags []string `json:"hashtags"`
	// contains filtered or unexported fields
}

Contains a list of hashtags

func UnmarshalHashtags

func UnmarshalHashtags(data json.RawMessage) (*Hashtags, error)

func (*Hashtags) GetClass

func (*Hashtags) GetClass() string

func (*Hashtags) GetType

func (*Hashtags) GetType() string

func (*Hashtags) MarshalJSON

func (entity *Hashtags) MarshalJSON() ([]byte, error)

type HideSuggestedActionRequest

type HideSuggestedActionRequest struct {
	// Suggested action to hide
	Action SuggestedAction `json:"action"`
}

type HttpUrl

type HttpUrl struct {

	// The URL
	Url string `json:"url"`
	// contains filtered or unexported fields
}

Contains an HTTP URL

func UnmarshalHttpUrl

func UnmarshalHttpUrl(data json.RawMessage) (*HttpUrl, error)

func (*HttpUrl) GetClass

func (*HttpUrl) GetClass() string

func (*HttpUrl) GetType

func (*HttpUrl) GetType() string

func (*HttpUrl) MarshalJSON

func (entity *HttpUrl) MarshalJSON() ([]byte, error)

type IdentityDocument

type IdentityDocument struct {

	// Document number; 1-24 characters
	Number string `json:"number"`
	// Document expiry date; may be null
	ExpiryDate *Date `json:"expiry_date"`
	// Front side of the document
	FrontSide *DatedFile `json:"front_side"`
	// Reverse side of the document; only for driver license and identity card
	ReverseSide *DatedFile `json:"reverse_side"`
	// Selfie with the document; may be null
	Selfie *DatedFile `json:"selfie"`
	// List of files containing a certified English translation of the document
	Translation []*DatedFile `json:"translation"`
	// contains filtered or unexported fields
}

An identity document

func UnmarshalIdentityDocument

func UnmarshalIdentityDocument(data json.RawMessage) (*IdentityDocument, error)

func (*IdentityDocument) GetClass

func (*IdentityDocument) GetClass() string

func (*IdentityDocument) GetType

func (*IdentityDocument) GetType() string

func (*IdentityDocument) MarshalJSON

func (entity *IdentityDocument) MarshalJSON() ([]byte, error)

type ImportContactsRequest

type ImportContactsRequest struct {
	// The list of contacts to import or edit; contacts' vCard are ignored and are not imported
	Contacts []*Contact `json:"contacts"`
}

type ImportedContacts

type ImportedContacts struct {

	// User identifiers of the imported contacts in the same order as they were specified in the request; 0 if the contact is not yet a registered user
	UserIds []int64 `json:"user_ids"`
	// The number of users that imported the corresponding contact; 0 for already registered users or if unavailable
	ImporterCount []int32 `json:"importer_count"`
	// contains filtered or unexported fields
}

Represents the result of an ImportContacts request

func UnmarshalImportedContacts

func UnmarshalImportedContacts(data json.RawMessage) (*ImportedContacts, error)

func (*ImportedContacts) GetClass

func (*ImportedContacts) GetClass() string

func (*ImportedContacts) GetType

func (*ImportedContacts) GetType() string

func (*ImportedContacts) MarshalJSON

func (entity *ImportedContacts) MarshalJSON() ([]byte, error)

type InlineKeyboardButton

type InlineKeyboardButton struct {

	// Text of the button
	Text string `json:"text"`
	// Type of the button
	Type InlineKeyboardButtonType `json:"type"`
	// contains filtered or unexported fields
}

Represents a single button in an inline keyboard

func UnmarshalInlineKeyboardButton

func UnmarshalInlineKeyboardButton(data json.RawMessage) (*InlineKeyboardButton, error)

func (*InlineKeyboardButton) GetClass

func (*InlineKeyboardButton) GetClass() string

func (*InlineKeyboardButton) GetType

func (*InlineKeyboardButton) GetType() string

func (*InlineKeyboardButton) MarshalJSON

func (entity *InlineKeyboardButton) MarshalJSON() ([]byte, error)

func (*InlineKeyboardButton) UnmarshalJSON

func (inlineKeyboardButton *InlineKeyboardButton) UnmarshalJSON(data []byte) error

type InlineKeyboardButtonType

type InlineKeyboardButtonType interface {
	InlineKeyboardButtonTypeType() string
}

Describes the type of an inline keyboard button

func UnmarshalInlineKeyboardButtonType

func UnmarshalInlineKeyboardButtonType(data json.RawMessage) (InlineKeyboardButtonType, error)

func UnmarshalListOfInlineKeyboardButtonType

func UnmarshalListOfInlineKeyboardButtonType(dataList []json.RawMessage) ([]InlineKeyboardButtonType, error)

type InlineKeyboardButtonTypeBuy

type InlineKeyboardButtonTypeBuy struct {
	// contains filtered or unexported fields
}

A button to buy something. This button must be in the first column and row of the keyboard and can be attached only to a message with content of the type messageInvoice

func UnmarshalInlineKeyboardButtonTypeBuy

func UnmarshalInlineKeyboardButtonTypeBuy(data json.RawMessage) (*InlineKeyboardButtonTypeBuy, error)

func (*InlineKeyboardButtonTypeBuy) GetClass

func (*InlineKeyboardButtonTypeBuy) GetClass() string

func (*InlineKeyboardButtonTypeBuy) GetType

func (*InlineKeyboardButtonTypeBuy) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeBuy) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeBuy) MarshalJSON

func (entity *InlineKeyboardButtonTypeBuy) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeCallback

type InlineKeyboardButtonTypeCallback struct {

	// Data to be sent to the bot via a callback query
	Data []byte `json:"data"`
	// contains filtered or unexported fields
}

A button that sends a callback query to a bot

func UnmarshalInlineKeyboardButtonTypeCallback

func UnmarshalInlineKeyboardButtonTypeCallback(data json.RawMessage) (*InlineKeyboardButtonTypeCallback, error)

func (*InlineKeyboardButtonTypeCallback) GetClass

func (*InlineKeyboardButtonTypeCallback) GetType

func (*InlineKeyboardButtonTypeCallback) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeCallback) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeCallback) MarshalJSON

func (entity *InlineKeyboardButtonTypeCallback) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeCallbackGame

type InlineKeyboardButtonTypeCallbackGame struct {
	// contains filtered or unexported fields
}

A button with a game that sends a callback query to a bot. This button must be in the first column and row of the keyboard and can be attached only to a message with content of the type messageGame

func UnmarshalInlineKeyboardButtonTypeCallbackGame

func UnmarshalInlineKeyboardButtonTypeCallbackGame(data json.RawMessage) (*InlineKeyboardButtonTypeCallbackGame, error)

func (*InlineKeyboardButtonTypeCallbackGame) GetClass

func (*InlineKeyboardButtonTypeCallbackGame) GetType

func (*InlineKeyboardButtonTypeCallbackGame) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeCallbackGame) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeCallbackGame) MarshalJSON

func (entity *InlineKeyboardButtonTypeCallbackGame) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeCallbackWithPassword

type InlineKeyboardButtonTypeCallbackWithPassword struct {

	// Data to be sent to the bot via a callback query
	Data []byte `json:"data"`
	// contains filtered or unexported fields
}

A button that asks for password of the current user and then sends a callback query to a bot

func UnmarshalInlineKeyboardButtonTypeCallbackWithPassword

func UnmarshalInlineKeyboardButtonTypeCallbackWithPassword(data json.RawMessage) (*InlineKeyboardButtonTypeCallbackWithPassword, error)

func (*InlineKeyboardButtonTypeCallbackWithPassword) GetClass

func (*InlineKeyboardButtonTypeCallbackWithPassword) GetType

func (*InlineKeyboardButtonTypeCallbackWithPassword) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeCallbackWithPassword) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeCallbackWithPassword) MarshalJSON

func (entity *InlineKeyboardButtonTypeCallbackWithPassword) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeLoginUrl

type InlineKeyboardButtonTypeLoginUrl struct {

	// An HTTP URL to open
	Url string `json:"url"`
	// Unique button identifier
	Id int32 `json:"id"`
	// If non-empty, new text of the button in forwarded messages
	ForwardText string `json:"forward_text"`
	// contains filtered or unexported fields
}

A button that opens a specified URL and automatically logs in in current user if they allowed to do that

func UnmarshalInlineKeyboardButtonTypeLoginUrl

func UnmarshalInlineKeyboardButtonTypeLoginUrl(data json.RawMessage) (*InlineKeyboardButtonTypeLoginUrl, error)

func (*InlineKeyboardButtonTypeLoginUrl) GetClass

func (*InlineKeyboardButtonTypeLoginUrl) GetType

func (*InlineKeyboardButtonTypeLoginUrl) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeLoginUrl) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeLoginUrl) MarshalJSON

func (entity *InlineKeyboardButtonTypeLoginUrl) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeSwitchInline

type InlineKeyboardButtonTypeSwitchInline struct {

	// Inline query to be sent to the bot
	Query string `json:"query"`
	// True, if the inline query should be sent from the current chat
	InCurrentChat bool `json:"in_current_chat"`
	// contains filtered or unexported fields
}

A button that forces an inline query to the bot to be inserted in the input field

func UnmarshalInlineKeyboardButtonTypeSwitchInline

func UnmarshalInlineKeyboardButtonTypeSwitchInline(data json.RawMessage) (*InlineKeyboardButtonTypeSwitchInline, error)

func (*InlineKeyboardButtonTypeSwitchInline) GetClass

func (*InlineKeyboardButtonTypeSwitchInline) GetType

func (*InlineKeyboardButtonTypeSwitchInline) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeSwitchInline) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeSwitchInline) MarshalJSON

func (entity *InlineKeyboardButtonTypeSwitchInline) MarshalJSON() ([]byte, error)

type InlineKeyboardButtonTypeUrl

type InlineKeyboardButtonTypeUrl struct {

	// HTTP or tg:// URL to open
	Url string `json:"url"`
	// contains filtered or unexported fields
}

A button that opens a specified URL

func UnmarshalInlineKeyboardButtonTypeUrl

func UnmarshalInlineKeyboardButtonTypeUrl(data json.RawMessage) (*InlineKeyboardButtonTypeUrl, error)

func (*InlineKeyboardButtonTypeUrl) GetClass

func (*InlineKeyboardButtonTypeUrl) GetClass() string

func (*InlineKeyboardButtonTypeUrl) GetType

func (*InlineKeyboardButtonTypeUrl) InlineKeyboardButtonTypeType

func (*InlineKeyboardButtonTypeUrl) InlineKeyboardButtonTypeType() string

func (*InlineKeyboardButtonTypeUrl) MarshalJSON

func (entity *InlineKeyboardButtonTypeUrl) MarshalJSON() ([]byte, error)

type InlineQueryResult

type InlineQueryResult interface {
	InlineQueryResultType() string
}

Represents a single result of an inline query

func UnmarshalInlineQueryResult

func UnmarshalInlineQueryResult(data json.RawMessage) (InlineQueryResult, error)

func UnmarshalListOfInlineQueryResult

func UnmarshalListOfInlineQueryResult(dataList []json.RawMessage) ([]InlineQueryResult, error)

type InlineQueryResultAnimation

type InlineQueryResultAnimation struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Animation file
	Animation *Animation `json:"animation"`
	// Animation title
	Title string `json:"title"`
	// contains filtered or unexported fields
}

Represents an animation file

func UnmarshalInlineQueryResultAnimation

func UnmarshalInlineQueryResultAnimation(data json.RawMessage) (*InlineQueryResultAnimation, error)

func (*InlineQueryResultAnimation) GetClass

func (*InlineQueryResultAnimation) GetClass() string

func (*InlineQueryResultAnimation) GetType

func (*InlineQueryResultAnimation) InlineQueryResultType

func (*InlineQueryResultAnimation) InlineQueryResultType() string

func (*InlineQueryResultAnimation) MarshalJSON

func (entity *InlineQueryResultAnimation) MarshalJSON() ([]byte, error)

type InlineQueryResultArticle

type InlineQueryResultArticle struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// URL of the result, if it exists
	Url string `json:"url"`
	// True, if the URL must be not shown
	HideUrl bool `json:"hide_url"`
	// Title of the result
	Title string `json:"title"`
	// A short description of the result
	Description string `json:"description"`
	// Result thumbnail in JPEG format; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// contains filtered or unexported fields
}

Represents a link to an article or web page

func UnmarshalInlineQueryResultArticle

func UnmarshalInlineQueryResultArticle(data json.RawMessage) (*InlineQueryResultArticle, error)

func (*InlineQueryResultArticle) GetClass

func (*InlineQueryResultArticle) GetClass() string

func (*InlineQueryResultArticle) GetType

func (*InlineQueryResultArticle) GetType() string

func (*InlineQueryResultArticle) InlineQueryResultType

func (*InlineQueryResultArticle) InlineQueryResultType() string

func (*InlineQueryResultArticle) MarshalJSON

func (entity *InlineQueryResultArticle) MarshalJSON() ([]byte, error)

type InlineQueryResultAudio

type InlineQueryResultAudio struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Audio file
	Audio *Audio `json:"audio"`
	// contains filtered or unexported fields
}

Represents an audio file

func UnmarshalInlineQueryResultAudio

func UnmarshalInlineQueryResultAudio(data json.RawMessage) (*InlineQueryResultAudio, error)

func (*InlineQueryResultAudio) GetClass

func (*InlineQueryResultAudio) GetClass() string

func (*InlineQueryResultAudio) GetType

func (*InlineQueryResultAudio) GetType() string

func (*InlineQueryResultAudio) InlineQueryResultType

func (*InlineQueryResultAudio) InlineQueryResultType() string

func (*InlineQueryResultAudio) MarshalJSON

func (entity *InlineQueryResultAudio) MarshalJSON() ([]byte, error)

type InlineQueryResultContact

type InlineQueryResultContact struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// A user contact
	Contact *Contact `json:"contact"`
	// Result thumbnail in JPEG format; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// contains filtered or unexported fields
}

Represents a user contact

func UnmarshalInlineQueryResultContact

func UnmarshalInlineQueryResultContact(data json.RawMessage) (*InlineQueryResultContact, error)

func (*InlineQueryResultContact) GetClass

func (*InlineQueryResultContact) GetClass() string

func (*InlineQueryResultContact) GetType

func (*InlineQueryResultContact) GetType() string

func (*InlineQueryResultContact) InlineQueryResultType

func (*InlineQueryResultContact) InlineQueryResultType() string

func (*InlineQueryResultContact) MarshalJSON

func (entity *InlineQueryResultContact) MarshalJSON() ([]byte, error)

type InlineQueryResultDocument

type InlineQueryResultDocument struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Document
	Document *Document `json:"document"`
	// Document title
	Title string `json:"title"`
	// Document description
	Description string `json:"description"`
	// contains filtered or unexported fields
}

Represents a document

func UnmarshalInlineQueryResultDocument

func UnmarshalInlineQueryResultDocument(data json.RawMessage) (*InlineQueryResultDocument, error)

func (*InlineQueryResultDocument) GetClass

func (*InlineQueryResultDocument) GetClass() string

func (*InlineQueryResultDocument) GetType

func (*InlineQueryResultDocument) GetType() string

func (*InlineQueryResultDocument) InlineQueryResultType

func (*InlineQueryResultDocument) InlineQueryResultType() string

func (*InlineQueryResultDocument) MarshalJSON

func (entity *InlineQueryResultDocument) MarshalJSON() ([]byte, error)

type InlineQueryResultGame

type InlineQueryResultGame struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Game result
	Game *Game `json:"game"`
	// contains filtered or unexported fields
}

Represents information about a game

func UnmarshalInlineQueryResultGame

func UnmarshalInlineQueryResultGame(data json.RawMessage) (*InlineQueryResultGame, error)

func (*InlineQueryResultGame) GetClass

func (*InlineQueryResultGame) GetClass() string

func (*InlineQueryResultGame) GetType

func (*InlineQueryResultGame) GetType() string

func (*InlineQueryResultGame) InlineQueryResultType

func (*InlineQueryResultGame) InlineQueryResultType() string

func (*InlineQueryResultGame) MarshalJSON

func (entity *InlineQueryResultGame) MarshalJSON() ([]byte, error)

type InlineQueryResultLocation

type InlineQueryResultLocation struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Location result
	Location *Location `json:"location"`
	// Title of the result
	Title string `json:"title"`
	// Result thumbnail in JPEG format; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// contains filtered or unexported fields
}

Represents a point on the map

func UnmarshalInlineQueryResultLocation

func UnmarshalInlineQueryResultLocation(data json.RawMessage) (*InlineQueryResultLocation, error)

func (*InlineQueryResultLocation) GetClass

func (*InlineQueryResultLocation) GetClass() string

func (*InlineQueryResultLocation) GetType

func (*InlineQueryResultLocation) GetType() string

func (*InlineQueryResultLocation) InlineQueryResultType

func (*InlineQueryResultLocation) InlineQueryResultType() string

func (*InlineQueryResultLocation) MarshalJSON

func (entity *InlineQueryResultLocation) MarshalJSON() ([]byte, error)

type InlineQueryResultPhoto

type InlineQueryResultPhoto struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Photo
	Photo *Photo `json:"photo"`
	// Title of the result, if known
	Title string `json:"title"`
	// A short description of the result, if known
	Description string `json:"description"`
	// contains filtered or unexported fields
}

Represents a photo

func UnmarshalInlineQueryResultPhoto

func UnmarshalInlineQueryResultPhoto(data json.RawMessage) (*InlineQueryResultPhoto, error)

func (*InlineQueryResultPhoto) GetClass

func (*InlineQueryResultPhoto) GetClass() string

func (*InlineQueryResultPhoto) GetType

func (*InlineQueryResultPhoto) GetType() string

func (*InlineQueryResultPhoto) InlineQueryResultType

func (*InlineQueryResultPhoto) InlineQueryResultType() string

func (*InlineQueryResultPhoto) MarshalJSON

func (entity *InlineQueryResultPhoto) MarshalJSON() ([]byte, error)

type InlineQueryResultSticker

type InlineQueryResultSticker struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Sticker
	Sticker *Sticker `json:"sticker"`
	// contains filtered or unexported fields
}

Represents a sticker

func UnmarshalInlineQueryResultSticker

func UnmarshalInlineQueryResultSticker(data json.RawMessage) (*InlineQueryResultSticker, error)

func (*InlineQueryResultSticker) GetClass

func (*InlineQueryResultSticker) GetClass() string

func (*InlineQueryResultSticker) GetType

func (*InlineQueryResultSticker) GetType() string

func (*InlineQueryResultSticker) InlineQueryResultType

func (*InlineQueryResultSticker) InlineQueryResultType() string

func (*InlineQueryResultSticker) MarshalJSON

func (entity *InlineQueryResultSticker) MarshalJSON() ([]byte, error)

type InlineQueryResultVenue

type InlineQueryResultVenue struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Venue result
	Venue *Venue `json:"venue"`
	// Result thumbnail in JPEG format; may be null
	Thumbnail *Thumbnail `json:"thumbnail"`
	// contains filtered or unexported fields
}

Represents information about a venue

func UnmarshalInlineQueryResultVenue

func UnmarshalInlineQueryResultVenue(data json.RawMessage) (*InlineQueryResultVenue, error)

func (*InlineQueryResultVenue) GetClass

func (*InlineQueryResultVenue) GetClass() string

func (*InlineQueryResultVenue) GetType

func (*InlineQueryResultVenue) GetType() string

func (*InlineQueryResultVenue) InlineQueryResultType

func (*InlineQueryResultVenue) InlineQueryResultType() string

func (*InlineQueryResultVenue) MarshalJSON

func (entity *InlineQueryResultVenue) MarshalJSON() ([]byte, error)

type InlineQueryResultVideo

type InlineQueryResultVideo struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Video
	Video *Video `json:"video"`
	// Title of the video
	Title string `json:"title"`
	// Description of the video
	Description string `json:"description"`
	// contains filtered or unexported fields
}

Represents a video

func UnmarshalInlineQueryResultVideo

func UnmarshalInlineQueryResultVideo(data json.RawMessage) (*InlineQueryResultVideo, error)

func (*InlineQueryResultVideo) GetClass

func (*InlineQueryResultVideo) GetClass() string

func (*InlineQueryResultVideo) GetType

func (*InlineQueryResultVideo) GetType() string

func (*InlineQueryResultVideo) InlineQueryResultType

func (*InlineQueryResultVideo) InlineQueryResultType() string

func (*InlineQueryResultVideo) MarshalJSON

func (entity *InlineQueryResultVideo) MarshalJSON() ([]byte, error)

type InlineQueryResultVoiceNote

type InlineQueryResultVoiceNote struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Voice note
	VoiceNote *VoiceNote `json:"voice_note"`
	// Title of the voice note
	Title string `json:"title"`
	// contains filtered or unexported fields
}

Represents a voice note

func UnmarshalInlineQueryResultVoiceNote

func UnmarshalInlineQueryResultVoiceNote(data json.RawMessage) (*InlineQueryResultVoiceNote, error)

func (*InlineQueryResultVoiceNote) GetClass

func (*InlineQueryResultVoiceNote) GetClass() string

func (*InlineQueryResultVoiceNote) GetType

func (*InlineQueryResultVoiceNote) InlineQueryResultType

func (*InlineQueryResultVoiceNote) InlineQueryResultType() string

func (*InlineQueryResultVoiceNote) MarshalJSON

func (entity *InlineQueryResultVoiceNote) MarshalJSON() ([]byte, error)

type InlineQueryResults

type InlineQueryResults struct {

	// Unique identifier of the inline query
	InlineQueryId JsonInt64 `json:"inline_query_id"`
	// The offset for the next request. If empty, there are no more results
	NextOffset string `json:"next_offset"`
	// Results of the query
	Results []InlineQueryResult `json:"results"`
	// If non-empty, this text should be shown on the button, which opens a private chat with the bot and sends the bot a start message with the switch_pm_parameter
	SwitchPmText string `json:"switch_pm_text"`
	// Parameter for the bot start message
	SwitchPmParameter string `json:"switch_pm_parameter"`
	// contains filtered or unexported fields
}

Represents the results of the inline query. Use sendInlineQueryResultMessage to send the result of the query

func UnmarshalInlineQueryResults

func UnmarshalInlineQueryResults(data json.RawMessage) (*InlineQueryResults, error)

func (*InlineQueryResults) GetClass

func (*InlineQueryResults) GetClass() string

func (*InlineQueryResults) GetType

func (*InlineQueryResults) GetType() string

func (*InlineQueryResults) MarshalJSON

func (entity *InlineQueryResults) MarshalJSON() ([]byte, error)

func (*InlineQueryResults) UnmarshalJSON

func (inlineQueryResults *InlineQueryResults) UnmarshalJSON(data []byte) error

type InputBackground

type InputBackground interface {
	InputBackgroundType() string
}

Contains information about background to set

func UnmarshalInputBackground

func UnmarshalInputBackground(data json.RawMessage) (InputBackground, error)

func UnmarshalListOfInputBackground

func UnmarshalListOfInputBackground(dataList []json.RawMessage) ([]InputBackground, error)

type InputBackgroundLocal

type InputBackgroundLocal struct {

	// Background file to use. Only inputFileLocal and inputFileGenerated are supported. The file must be in JPEG format for wallpapers and in PNG format for patterns
	Background InputFile `json:"background"`
	// contains filtered or unexported fields
}

A background from a local file

func UnmarshalInputBackgroundLocal

func UnmarshalInputBackgroundLocal(data json.RawMessage) (*InputBackgroundLocal, error)

func (*InputBackgroundLocal) GetClass

func (*InputBackgroundLocal) GetClass() string

func (*InputBackgroundLocal) GetType

func (*InputBackgroundLocal) GetType() string

func (*InputBackgroundLocal) InputBackgroundType

func (*InputBackgroundLocal) InputBackgroundType() string

func (*InputBackgroundLocal) MarshalJSON

func (entity *InputBackgroundLocal) MarshalJSON() ([]byte, error)

func (*InputBackgroundLocal) UnmarshalJSON

func (inputBackgroundLocal *InputBackgroundLocal) UnmarshalJSON(data []byte) error

type InputBackgroundRemote

type InputBackgroundRemote struct {

	// The background identifier
	BackgroundId JsonInt64 `json:"background_id"`
	// contains filtered or unexported fields
}

A background from the server

func UnmarshalInputBackgroundRemote

func UnmarshalInputBackgroundRemote(data json.RawMessage) (*InputBackgroundRemote, error)

func (*InputBackgroundRemote) GetClass

func (*InputBackgroundRemote) GetClass() string

func (*InputBackgroundRemote) GetType

func (*InputBackgroundRemote) GetType() string

func (*InputBackgroundRemote) InputBackgroundType

func (*InputBackgroundRemote) InputBackgroundType() string

func (*InputBackgroundRemote) MarshalJSON

func (entity *InputBackgroundRemote) MarshalJSON() ([]byte, error)

type InputChatPhoto

type InputChatPhoto interface {
	InputChatPhotoType() string
}

Describes a photo to be set as a user profile or chat photo

func UnmarshalInputChatPhoto

func UnmarshalInputChatPhoto(data json.RawMessage) (InputChatPhoto, error)

func UnmarshalListOfInputChatPhoto

func UnmarshalListOfInputChatPhoto(dataList []json.RawMessage) ([]InputChatPhoto, error)

type InputChatPhotoAnimation

type InputChatPhotoAnimation struct {

	// Animation to be set as profile photo. Only inputFileLocal and inputFileGenerated are allowed
	Animation InputFile `json:"animation"`
	// Timestamp of the frame, which will be used as static chat photo
	MainFrameTimestamp float64 `json:"main_frame_timestamp"`
	// contains filtered or unexported fields
}

An animation in MPEG4 format; must be square, at most 10 seconds long, have width between 160 and 800 and be at most 2MB in size

func UnmarshalInputChatPhotoAnimation

func UnmarshalInputChatPhotoAnimation(data json.RawMessage) (*InputChatPhotoAnimation, error)

func (*InputChatPhotoAnimation) GetClass

func (*InputChatPhotoAnimation) GetClass() string

func (*InputChatPhotoAnimation) GetType

func (*InputChatPhotoAnimation) GetType() string

func (*InputChatPhotoAnimation) InputChatPhotoType

func (*InputChatPhotoAnimation) InputChatPhotoType() string

func (*InputChatPhotoAnimation) MarshalJSON

func (entity *InputChatPhotoAnimation) MarshalJSON() ([]byte, error)

func (*InputChatPhotoAnimation) UnmarshalJSON

func (inputChatPhotoAnimation *InputChatPhotoAnimation) UnmarshalJSON(data []byte) error

type InputChatPhotoPrevious

type InputChatPhotoPrevious struct {

	// Identifier of the profile photo to reuse
	ChatPhotoId JsonInt64 `json:"chat_photo_id"`
	// contains filtered or unexported fields
}

A previously used profile photo of the current user

func UnmarshalInputChatPhotoPrevious

func UnmarshalInputChatPhotoPrevious(data json.RawMessage) (*InputChatPhotoPrevious, error)

func (*InputChatPhotoPrevious) GetClass

func (*InputChatPhotoPrevious) GetClass() string

func (*InputChatPhotoPrevious) GetType

func (*InputChatPhotoPrevious) GetType() string

func (*InputChatPhotoPrevious) InputChatPhotoType

func (*InputChatPhotoPrevious) InputChatPhotoType() string

func (*InputChatPhotoPrevious) MarshalJSON

func (entity *InputChatPhotoPrevious) MarshalJSON() ([]byte, error)

type InputChatPhotoStatic

type InputChatPhotoStatic struct {

	// Photo to be set as profile photo. Only inputFileLocal and inputFileGenerated are allowed
	Photo InputFile `json:"photo"`
	// contains filtered or unexported fields
}

A static photo in JPEG format

func UnmarshalInputChatPhotoStatic

func UnmarshalInputChatPhotoStatic(data json.RawMessage) (*InputChatPhotoStatic, error)

func (*InputChatPhotoStatic) GetClass

func (*InputChatPhotoStatic) GetClass() string

func (*InputChatPhotoStatic) GetType

func (*InputChatPhotoStatic) GetType() string

func (*InputChatPhotoStatic) InputChatPhotoType

func (*InputChatPhotoStatic) InputChatPhotoType() string

func (*InputChatPhotoStatic) MarshalJSON

func (entity *InputChatPhotoStatic) MarshalJSON() ([]byte, error)

func (*InputChatPhotoStatic) UnmarshalJSON

func (inputChatPhotoStatic *InputChatPhotoStatic) UnmarshalJSON(data []byte) error

type InputCredentials

type InputCredentials interface {
	InputCredentialsType() string
}

Contains information about the payment method chosen by the user

func UnmarshalInputCredentials

func UnmarshalInputCredentials(data json.RawMessage) (InputCredentials, error)

func UnmarshalListOfInputCredentials

func UnmarshalListOfInputCredentials(dataList []json.RawMessage) ([]InputCredentials, error)

type InputCredentialsAndroidPay

type InputCredentialsAndroidPay struct {

	// JSON-encoded data with the credential identifier
	Data string `json:"data"`
	// contains filtered or unexported fields
}

Applies if a user enters new credentials using Android Pay

func UnmarshalInputCredentialsAndroidPay

func UnmarshalInputCredentialsAndroidPay(data json.RawMessage) (*InputCredentialsAndroidPay, error)

func (*InputCredentialsAndroidPay) GetClass

func (*InputCredentialsAndroidPay) GetClass() string

func (*InputCredentialsAndroidPay) GetType

func (*InputCredentialsAndroidPay) InputCredentialsType

func (*InputCredentialsAndroidPay) InputCredentialsType() string

func (*InputCredentialsAndroidPay) MarshalJSON

func (entity *InputCredentialsAndroidPay) MarshalJSON() ([]byte, error)

type InputCredentialsApplePay

type InputCredentialsApplePay struct {

	// JSON-encoded data with the credential identifier
	Data string `json:"data"`
	// contains filtered or unexported fields
}

Applies if a user enters new credentials using Apple Pay

func UnmarshalInputCredentialsApplePay

func UnmarshalInputCredentialsApplePay(data json.RawMessage) (*InputCredentialsApplePay, error)

func (*InputCredentialsApplePay) GetClass

func (*InputCredentialsApplePay) GetClass() string

func (*InputCredentialsApplePay) GetType

func (*InputCredentialsApplePay) GetType() string

func (*InputCredentialsApplePay) InputCredentialsType

func (*InputCredentialsApplePay) InputCredentialsType() string

func (*InputCredentialsApplePay) MarshalJSON

func (entity *InputCredentialsApplePay) MarshalJSON() ([]byte, error)

type InputCredentialsNew

type InputCredentialsNew struct {

	// Contains JSON-encoded data with a credential identifier from the payment provider
	Data string `json:"data"`
	// True, if the credential identifier can be saved on the server side
	AllowSave bool `json:"allow_save"`
	// contains filtered or unexported fields
}

Applies if a user enters new credentials on a payment provider website

func UnmarshalInputCredentialsNew

func UnmarshalInputCredentialsNew(data json.RawMessage) (*InputCredentialsNew, error)

func (*InputCredentialsNew) GetClass

func (*InputCredentialsNew) GetClass() string

func (*InputCredentialsNew) GetType

func (*InputCredentialsNew) GetType() string

func (*InputCredentialsNew) InputCredentialsType

func (*InputCredentialsNew) InputCredentialsType() string

func (*InputCredentialsNew) MarshalJSON

func (entity *InputCredentialsNew) MarshalJSON() ([]byte, error)

type InputCredentialsSaved

type InputCredentialsSaved struct {

	// Identifier of the saved credentials
	SavedCredentialsId string `json:"saved_credentials_id"`
	// contains filtered or unexported fields
}

Applies if a user chooses some previously saved payment credentials. To use their previously saved credentials, the user must have a valid temporary password

func UnmarshalInputCredentialsSaved

func UnmarshalInputCredentialsSaved(data json.RawMessage) (*InputCredentialsSaved, error)

func (*InputCredentialsSaved) GetClass

func (*InputCredentialsSaved) GetClass() string

func (*InputCredentialsSaved) GetType

func (*InputCredentialsSaved) GetType() string

func (*InputCredentialsSaved) InputCredentialsType

func (*InputCredentialsSaved) InputCredentialsType() string

func (*InputCredentialsSaved) MarshalJSON

func (entity *InputCredentialsSaved) MarshalJSON() ([]byte, error)

type InputFile

type InputFile interface {
	InputFileType() string
}

Points to a file

func UnmarshalInputFile

func UnmarshalInputFile(data json.RawMessage) (InputFile, error)

func UnmarshalListOfInputFile

func UnmarshalListOfInputFile(dataList []json.RawMessage) ([]InputFile, error)

type InputFileGenerated

type InputFileGenerated struct {

	// Local path to a file from which the file is generated; may be empty if there is no such file
	OriginalPath string `json:"original_path"`
	// String specifying the conversion applied to the original file; should be persistent across application restarts. Conversions beginning with '#' are reserved for internal TDLib usage
	Conversion string `json:"conversion"`
	// Expected size of the generated file; 0 if unknown
	ExpectedSize int32 `json:"expected_size"`
	// contains filtered or unexported fields
}

A file generated by the application

func UnmarshalInputFileGenerated

func UnmarshalInputFileGenerated(data json.RawMessage) (*InputFileGenerated, error)

func (*InputFileGenerated) GetClass

func (*InputFileGenerated) GetClass() string

func (*InputFileGenerated) GetType

func (*InputFileGenerated) GetType() string

func (*InputFileGenerated) InputFileType

func (*InputFileGenerated) InputFileType() string

func (*InputFileGenerated) MarshalJSON

func (entity *InputFileGenerated) MarshalJSON() ([]byte, error)

type InputFileId

type InputFileId struct {

	// Unique file identifier
	Id int32 `json:"id"`
	// contains filtered or unexported fields
}

A file defined by its unique ID

func UnmarshalInputFileId

func UnmarshalInputFileId(data json.RawMessage) (*InputFileId, error)

func (*InputFileId) GetClass

func (*InputFileId) GetClass() string

func (*InputFileId) GetType

func (*InputFileId) GetType() string

func (*InputFileId) InputFileType

func (*InputFileId) InputFileType() string

func (*InputFileId) MarshalJSON

func (entity *InputFileId) MarshalJSON() ([]byte, error)

type InputFileLocal

type InputFileLocal struct {

	// Local path to the file
	Path string `json:"path"`
	// contains filtered or unexported fields
}

A file defined by a local path

func UnmarshalInputFileLocal

func UnmarshalInputFileLocal(data json.RawMessage) (*InputFileLocal, error)

func (*InputFileLocal) GetClass

func (*InputFileLocal) GetClass() string

func (*InputFileLocal) GetType

func (*InputFileLocal) GetType() string

func (*InputFileLocal) InputFileType

func (*InputFileLocal) InputFileType() string

func (*InputFileLocal) MarshalJSON

func (entity *InputFileLocal) MarshalJSON() ([]byte, error)

type InputFileRemote

type InputFileRemote struct {

	// Remote file identifier
	Id string `json:"id"`
	// contains filtered or unexported fields
}

A file defined by its remote ID. The remote ID is guaranteed to be usable only if the corresponding file is still accessible to the user and known to TDLib. For example, if the file is from a message, then the message must be not deleted and accessible to the user. If the file database is disabled, then the corresponding object with the file must be preloaded by the application

func UnmarshalInputFileRemote

func UnmarshalInputFileRemote(data json.RawMessage) (*InputFileRemote, error)

func (*InputFileRemote) GetClass

func (*InputFileRemote) GetClass() string

func (*InputFileRemote) GetType

func (*InputFileRemote) GetType() string

func (*InputFileRemote) InputFileType

func (*InputFileRemote) InputFileType() string

func (*InputFileRemote) MarshalJSON

func (entity *InputFileRemote) MarshalJSON() ([]byte, error)

type InputIdentityDocument

type InputIdentityDocument struct {

	// Document number; 1-24 characters
	Number string `json:"number"`
	// Document expiry date, if available
	ExpiryDate *Date `json:"expiry_date"`
	// Front side of the document
	FrontSide InputFile `json:"front_side"`
	// Reverse side of the document; only for driver license and identity card
	ReverseSide InputFile `json:"reverse_side"`
	// Selfie with the document, if available
	Selfie InputFile `json:"selfie"`
	// List of files containing a certified English translation of the document
	Translation []InputFile `json:"translation"`
	// contains filtered or unexported fields
}

An identity document to be saved to Telegram Passport

func UnmarshalInputIdentityDocument

func UnmarshalInputIdentityDocument(data json.RawMessage) (*InputIdentityDocument, error)

func (*InputIdentityDocument) GetClass

func (*InputIdentityDocument) GetClass() string

func (*InputIdentityDocument) GetType

func (*InputIdentityDocument) GetType() string

func (*InputIdentityDocument) MarshalJSON

func (entity *InputIdentityDocument) MarshalJSON() ([]byte, error)

func (*InputIdentityDocument) UnmarshalJSON

func (inputIdentityDocument *InputIdentityDocument) UnmarshalJSON(data []byte) error

type InputInlineQueryResult

type InputInlineQueryResult interface {
	InputInlineQueryResultType() string
}

Represents a single result of an inline query; for bots only

func UnmarshalInputInlineQueryResult

func UnmarshalInputInlineQueryResult(data json.RawMessage) (InputInlineQueryResult, error)

func UnmarshalListOfInputInlineQueryResult

func UnmarshalListOfInputInlineQueryResult(dataList []json.RawMessage) ([]InputInlineQueryResult, error)

type InputInlineQueryResultAnimation

type InputInlineQueryResultAnimation struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the query result
	Title string `json:"title"`
	// URL of the result thumbnail (JPEG, GIF, or MPEG4), if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// MIME type of the video thumbnail. If non-empty, must be one of "image/jpeg", "image/gif" and "video/mp4"
	ThumbnailMimeType string `json:"thumbnail_mime_type"`
	// The URL of the video file (file size must not exceed 1MB)
	VideoUrl string `json:"video_url"`
	// MIME type of the video file. Must be one of "image/gif" and "video/mp4"
	VideoMimeType string `json:"video_mime_type"`
	// Duration of the video, in seconds
	VideoDuration int32 `json:"video_duration"`
	// Width of the video
	VideoWidth int32 `json:"video_width"`
	// Height of the video
	VideoHeight int32 `json:"video_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageAnimation, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to an animated GIF or an animated (i.e. without sound) H.264/MPEG-4 AVC video

func UnmarshalInputInlineQueryResultAnimation

func UnmarshalInputInlineQueryResultAnimation(data json.RawMessage) (*InputInlineQueryResultAnimation, error)

func (*InputInlineQueryResultAnimation) GetClass

func (*InputInlineQueryResultAnimation) GetType

func (*InputInlineQueryResultAnimation) InputInlineQueryResultType

func (*InputInlineQueryResultAnimation) InputInlineQueryResultType() string

func (*InputInlineQueryResultAnimation) MarshalJSON

func (entity *InputInlineQueryResultAnimation) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultAnimation) UnmarshalJSON

func (inputInlineQueryResultAnimation *InputInlineQueryResultAnimation) UnmarshalJSON(data []byte) error

type InputInlineQueryResultArticle

type InputInlineQueryResultArticle struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// URL of the result, if it exists
	Url string `json:"url"`
	// True, if the URL must be not shown
	HideUrl bool `json:"hide_url"`
	// Title of the result
	Title string `json:"title"`
	// A short description of the result
	Description string `json:"description"`
	// URL of the result thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// Thumbnail width, if known
	ThumbnailWidth int32 `json:"thumbnail_width"`
	// Thumbnail height, if known
	ThumbnailHeight int32 `json:"thumbnail_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to an article or web page

func UnmarshalInputInlineQueryResultArticle

func UnmarshalInputInlineQueryResultArticle(data json.RawMessage) (*InputInlineQueryResultArticle, error)

func (*InputInlineQueryResultArticle) GetClass

func (*InputInlineQueryResultArticle) GetType

func (*InputInlineQueryResultArticle) InputInlineQueryResultType

func (*InputInlineQueryResultArticle) InputInlineQueryResultType() string

func (*InputInlineQueryResultArticle) MarshalJSON

func (entity *InputInlineQueryResultArticle) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultArticle) UnmarshalJSON

func (inputInlineQueryResultArticle *InputInlineQueryResultArticle) UnmarshalJSON(data []byte) error

type InputInlineQueryResultAudio

type InputInlineQueryResultAudio struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the audio file
	Title string `json:"title"`
	// Performer of the audio file
	Performer string `json:"performer"`
	// The URL of the audio file
	AudioUrl string `json:"audio_url"`
	// Audio file duration, in seconds
	AudioDuration int32 `json:"audio_duration"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageAudio, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to an MP3 audio file

func UnmarshalInputInlineQueryResultAudio

func UnmarshalInputInlineQueryResultAudio(data json.RawMessage) (*InputInlineQueryResultAudio, error)

func (*InputInlineQueryResultAudio) GetClass

func (*InputInlineQueryResultAudio) GetClass() string

func (*InputInlineQueryResultAudio) GetType

func (*InputInlineQueryResultAudio) InputInlineQueryResultType

func (*InputInlineQueryResultAudio) InputInlineQueryResultType() string

func (*InputInlineQueryResultAudio) MarshalJSON

func (entity *InputInlineQueryResultAudio) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultAudio) UnmarshalJSON

func (inputInlineQueryResultAudio *InputInlineQueryResultAudio) UnmarshalJSON(data []byte) error

type InputInlineQueryResultContact

type InputInlineQueryResultContact struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// User contact
	Contact *Contact `json:"contact"`
	// URL of the result thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// Thumbnail width, if known
	ThumbnailWidth int32 `json:"thumbnail_width"`
	// Thumbnail height, if known
	ThumbnailHeight int32 `json:"thumbnail_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a user contact

func UnmarshalInputInlineQueryResultContact

func UnmarshalInputInlineQueryResultContact(data json.RawMessage) (*InputInlineQueryResultContact, error)

func (*InputInlineQueryResultContact) GetClass

func (*InputInlineQueryResultContact) GetType

func (*InputInlineQueryResultContact) InputInlineQueryResultType

func (*InputInlineQueryResultContact) InputInlineQueryResultType() string

func (*InputInlineQueryResultContact) MarshalJSON

func (entity *InputInlineQueryResultContact) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultContact) UnmarshalJSON

func (inputInlineQueryResultContact *InputInlineQueryResultContact) UnmarshalJSON(data []byte) error

type InputInlineQueryResultDocument

type InputInlineQueryResultDocument struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the resulting file
	Title string `json:"title"`
	// Short description of the result, if known
	Description string `json:"description"`
	// URL of the file
	DocumentUrl string `json:"document_url"`
	// MIME type of the file content; only "application/pdf" and "application/zip" are currently allowed
	MimeType string `json:"mime_type"`
	// The URL of the file thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// Width of the thumbnail
	ThumbnailWidth int32 `json:"thumbnail_width"`
	// Height of the thumbnail
	ThumbnailHeight int32 `json:"thumbnail_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageDocument, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to a file

func UnmarshalInputInlineQueryResultDocument

func UnmarshalInputInlineQueryResultDocument(data json.RawMessage) (*InputInlineQueryResultDocument, error)

func (*InputInlineQueryResultDocument) GetClass

func (*InputInlineQueryResultDocument) GetType

func (*InputInlineQueryResultDocument) InputInlineQueryResultType

func (*InputInlineQueryResultDocument) InputInlineQueryResultType() string

func (*InputInlineQueryResultDocument) MarshalJSON

func (entity *InputInlineQueryResultDocument) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultDocument) UnmarshalJSON

func (inputInlineQueryResultDocument *InputInlineQueryResultDocument) UnmarshalJSON(data []byte) error

type InputInlineQueryResultGame

type InputInlineQueryResultGame struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Short name of the game
	GameShortName string `json:"game_short_name"`
	// Message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// contains filtered or unexported fields
}

Represents a game

func UnmarshalInputInlineQueryResultGame

func UnmarshalInputInlineQueryResultGame(data json.RawMessage) (*InputInlineQueryResultGame, error)

func (*InputInlineQueryResultGame) GetClass

func (*InputInlineQueryResultGame) GetClass() string

func (*InputInlineQueryResultGame) GetType

func (*InputInlineQueryResultGame) InputInlineQueryResultType

func (*InputInlineQueryResultGame) InputInlineQueryResultType() string

func (*InputInlineQueryResultGame) MarshalJSON

func (entity *InputInlineQueryResultGame) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultGame) UnmarshalJSON

func (inputInlineQueryResultGame *InputInlineQueryResultGame) UnmarshalJSON(data []byte) error

type InputInlineQueryResultLocation

type InputInlineQueryResultLocation struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Location result
	Location *Location `json:"location"`
	// Amount of time relative to the message sent time until the location can be updated, in seconds
	LivePeriod int32 `json:"live_period"`
	// Title of the result
	Title string `json:"title"`
	// URL of the result thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// Thumbnail width, if known
	ThumbnailWidth int32 `json:"thumbnail_width"`
	// Thumbnail height, if known
	ThumbnailHeight int32 `json:"thumbnail_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a point on the map

func UnmarshalInputInlineQueryResultLocation

func UnmarshalInputInlineQueryResultLocation(data json.RawMessage) (*InputInlineQueryResultLocation, error)

func (*InputInlineQueryResultLocation) GetClass

func (*InputInlineQueryResultLocation) GetType

func (*InputInlineQueryResultLocation) InputInlineQueryResultType

func (*InputInlineQueryResultLocation) InputInlineQueryResultType() string

func (*InputInlineQueryResultLocation) MarshalJSON

func (entity *InputInlineQueryResultLocation) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultLocation) UnmarshalJSON

func (inputInlineQueryResultLocation *InputInlineQueryResultLocation) UnmarshalJSON(data []byte) error

type InputInlineQueryResultPhoto

type InputInlineQueryResultPhoto struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the result, if known
	Title string `json:"title"`
	// A short description of the result, if known
	Description string `json:"description"`
	// URL of the photo thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// The URL of the JPEG photo (photo size must not exceed 5MB)
	PhotoUrl string `json:"photo_url"`
	// Width of the photo
	PhotoWidth int32 `json:"photo_width"`
	// Height of the photo
	PhotoHeight int32 `json:"photo_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessagePhoto, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents link to a JPEG image

func UnmarshalInputInlineQueryResultPhoto

func UnmarshalInputInlineQueryResultPhoto(data json.RawMessage) (*InputInlineQueryResultPhoto, error)

func (*InputInlineQueryResultPhoto) GetClass

func (*InputInlineQueryResultPhoto) GetClass() string

func (*InputInlineQueryResultPhoto) GetType

func (*InputInlineQueryResultPhoto) InputInlineQueryResultType

func (*InputInlineQueryResultPhoto) InputInlineQueryResultType() string

func (*InputInlineQueryResultPhoto) MarshalJSON

func (entity *InputInlineQueryResultPhoto) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultPhoto) UnmarshalJSON

func (inputInlineQueryResultPhoto *InputInlineQueryResultPhoto) UnmarshalJSON(data []byte) error

type InputInlineQueryResultSticker

type InputInlineQueryResultSticker struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// URL of the sticker thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// The URL of the WEBP or TGS sticker (sticker file size must not exceed 5MB)
	StickerUrl string `json:"sticker_url"`
	// Width of the sticker
	StickerWidth int32 `json:"sticker_width"`
	// Height of the sticker
	StickerHeight int32 `json:"sticker_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, inputMessageSticker, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to a WEBP or TGS sticker

func UnmarshalInputInlineQueryResultSticker

func UnmarshalInputInlineQueryResultSticker(data json.RawMessage) (*InputInlineQueryResultSticker, error)

func (*InputInlineQueryResultSticker) GetClass

func (*InputInlineQueryResultSticker) GetType

func (*InputInlineQueryResultSticker) InputInlineQueryResultType

func (*InputInlineQueryResultSticker) InputInlineQueryResultType() string

func (*InputInlineQueryResultSticker) MarshalJSON

func (entity *InputInlineQueryResultSticker) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultSticker) UnmarshalJSON

func (inputInlineQueryResultSticker *InputInlineQueryResultSticker) UnmarshalJSON(data []byte) error

type InputInlineQueryResultVenue

type InputInlineQueryResultVenue struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Venue result
	Venue *Venue `json:"venue"`
	// URL of the result thumbnail, if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// Thumbnail width, if known
	ThumbnailWidth int32 `json:"thumbnail_width"`
	// Thumbnail height, if known
	ThumbnailHeight int32 `json:"thumbnail_height"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents information about a venue

func UnmarshalInputInlineQueryResultVenue

func UnmarshalInputInlineQueryResultVenue(data json.RawMessage) (*InputInlineQueryResultVenue, error)

func (*InputInlineQueryResultVenue) GetClass

func (*InputInlineQueryResultVenue) GetClass() string

func (*InputInlineQueryResultVenue) GetType

func (*InputInlineQueryResultVenue) InputInlineQueryResultType

func (*InputInlineQueryResultVenue) InputInlineQueryResultType() string

func (*InputInlineQueryResultVenue) MarshalJSON

func (entity *InputInlineQueryResultVenue) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultVenue) UnmarshalJSON

func (inputInlineQueryResultVenue *InputInlineQueryResultVenue) UnmarshalJSON(data []byte) error

type InputInlineQueryResultVideo

type InputInlineQueryResultVideo struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the result
	Title string `json:"title"`
	// A short description of the result, if known
	Description string `json:"description"`
	// The URL of the video thumbnail (JPEG), if it exists
	ThumbnailUrl string `json:"thumbnail_url"`
	// URL of the embedded video player or video file
	VideoUrl string `json:"video_url"`
	// MIME type of the content of the video URL, only "text/html" or "video/mp4" are currently supported
	MimeType string `json:"mime_type"`
	// Width of the video
	VideoWidth int32 `json:"video_width"`
	// Height of the video
	VideoHeight int32 `json:"video_height"`
	// Video duration, in seconds
	VideoDuration int32 `json:"video_duration"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageVideo, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to a page containing an embedded video player or a video file

func UnmarshalInputInlineQueryResultVideo

func UnmarshalInputInlineQueryResultVideo(data json.RawMessage) (*InputInlineQueryResultVideo, error)

func (*InputInlineQueryResultVideo) GetClass

func (*InputInlineQueryResultVideo) GetClass() string

func (*InputInlineQueryResultVideo) GetType

func (*InputInlineQueryResultVideo) InputInlineQueryResultType

func (*InputInlineQueryResultVideo) InputInlineQueryResultType() string

func (*InputInlineQueryResultVideo) MarshalJSON

func (entity *InputInlineQueryResultVideo) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultVideo) UnmarshalJSON

func (inputInlineQueryResultVideo *InputInlineQueryResultVideo) UnmarshalJSON(data []byte) error

type InputInlineQueryResultVoiceNote

type InputInlineQueryResultVoiceNote struct {

	// Unique identifier of the query result
	Id string `json:"id"`
	// Title of the voice note
	Title string `json:"title"`
	// The URL of the voice note file
	VoiceNoteUrl string `json:"voice_note_url"`
	// Duration of the voice note, in seconds
	VoiceNoteDuration int32 `json:"voice_note_duration"`
	// The message reply markup. Must be of type replyMarkupInlineKeyboard or null
	ReplyMarkup ReplyMarkup `json:"reply_markup"`
	// The content of the message to be sent. Must be one of the following types: InputMessageText, InputMessageVoiceNote, InputMessageLocation, InputMessageVenue or InputMessageContact
	InputMessageContent InputMessageContent `json:"input_message_content"`
	// contains filtered or unexported fields
}

Represents a link to an opus-encoded audio file within an OGG container, single channel audio

func UnmarshalInputInlineQueryResultVoiceNote

func UnmarshalInputInlineQueryResultVoiceNote(data json.RawMessage) (*InputInlineQueryResultVoiceNote, error)

func (*InputInlineQueryResultVoiceNote) GetClass

func (*InputInlineQueryResultVoiceNote) GetType

func (*InputInlineQueryResultVoiceNote) InputInlineQueryResultType

func (*InputInlineQueryResultVoiceNote) InputInlineQueryResultType() string

func (*InputInlineQueryResultVoiceNote) MarshalJSON

func (entity *InputInlineQueryResultVoiceNote) MarshalJSON() ([]byte, error)

func (*InputInlineQueryResultVoiceNote) UnmarshalJSON

func (inputInlineQueryResultVoiceNote *InputInlineQueryResultVoiceNote) UnmarshalJSON(data []byte) error

type InputMessageAnimation

type InputMessageAnimation struct {

	// Animation file to be sent
	Animation InputFile `json:"animation"`
	// Animation thumbnail, if available
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// File identifiers of the stickers added to the animation, if applicable
	AddedStickerFileIds []int32 `json:"added_sticker_file_ids"`
	// Duration of the animation, in seconds
	Duration int32 `json:"duration"`
	// Width of the animation; may be replaced by the server
	Width int32 `json:"width"`
	// Height of the animation; may be replaced by the server
	Height int32 `json:"height"`
	// Animation caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// contains filtered or unexported fields
}

An animation message (GIF-style).

func UnmarshalInputMessageAnimation

func UnmarshalInputMessageAnimation(data json.RawMessage) (*InputMessageAnimation, error)

func (*InputMessageAnimation) GetClass

func (*InputMessageAnimation) GetClass() string

func (*InputMessageAnimation) GetType

func (*InputMessageAnimation) GetType() string

func (*InputMessageAnimation) InputMessageContentType

func (*InputMessageAnimation) InputMessageContentType() string

func (*InputMessageAnimation) MarshalJSON

func (entity *InputMessageAnimation) MarshalJSON() ([]byte, error)

func (*InputMessageAnimation) UnmarshalJSON

func (inputMessageAnimation *InputMessageAnimation) UnmarshalJSON(data []byte) error

type InputMessageAudio

type InputMessageAudio struct {

	// Audio file to be sent
	Audio InputFile `json:"audio"`
	// Thumbnail of the cover for the album, if available
	AlbumCoverThumbnail *InputThumbnail `json:"album_cover_thumbnail"`
	// Duration of the audio, in seconds; may be replaced by the server
	Duration int32 `json:"duration"`
	// Title of the audio; 0-64 characters; may be replaced by the server
	Title string `json:"title"`
	// Performer of the audio; 0-64 characters, may be replaced by the server
	Performer string `json:"performer"`
	// Audio caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// contains filtered or unexported fields
}

An audio message

func UnmarshalInputMessageAudio

func UnmarshalInputMessageAudio(data json.RawMessage) (*InputMessageAudio, error)

func (*InputMessageAudio) GetClass

func (*InputMessageAudio) GetClass() string

func (*InputMessageAudio) GetType

func (*InputMessageAudio) GetType() string

func (*InputMessageAudio) InputMessageContentType

func (*InputMessageAudio) InputMessageContentType() string

func (*InputMessageAudio) MarshalJSON

func (entity *InputMessageAudio) MarshalJSON() ([]byte, error)

func (*InputMessageAudio) UnmarshalJSON

func (inputMessageAudio *InputMessageAudio) UnmarshalJSON(data []byte) error

type InputMessageContact

type InputMessageContact struct {

	// Contact to send
	Contact *Contact `json:"contact"`
	// contains filtered or unexported fields
}

A message containing a user contact

func UnmarshalInputMessageContact

func UnmarshalInputMessageContact(data json.RawMessage) (*InputMessageContact, error)

func (*InputMessageContact) GetClass

func (*InputMessageContact) GetClass() string

func (*InputMessageContact) GetType

func (*InputMessageContact) GetType() string

func (*InputMessageContact) InputMessageContentType

func (*InputMessageContact) InputMessageContentType() string

func (*InputMessageContact) MarshalJSON

func (entity *InputMessageContact) MarshalJSON() ([]byte, error)

type InputMessageContent

type InputMessageContent interface {
	InputMessageContentType() string
}

The content of a message to send

func UnmarshalInputMessageContent

func UnmarshalInputMessageContent(data json.RawMessage) (InputMessageContent, error)

func UnmarshalListOfInputMessageContent

func UnmarshalListOfInputMessageContent(dataList []json.RawMessage) ([]InputMessageContent, error)

type InputMessageDice

type InputMessageDice struct {

	// Emoji on which the dice throw animation is based
	Emoji string `json:"emoji"`
	// True, if a chat message draft should be deleted
	ClearDraft bool `json:"clear_draft"`
	// contains filtered or unexported fields
}

A dice message

func UnmarshalInputMessageDice

func UnmarshalInputMessageDice(data json.RawMessage) (*InputMessageDice, error)

func (*InputMessageDice) GetClass

func (*InputMessageDice) GetClass() string

func (*InputMessageDice) GetType

func (*InputMessageDice) GetType() string

func (*InputMessageDice) InputMessageContentType

func (*InputMessageDice) InputMessageContentType() string

func (*InputMessageDice) MarshalJSON

func (entity *InputMessageDice) MarshalJSON() ([]byte, error)

type InputMessageDocument

type InputMessageDocument struct {

	// Document to be sent
	Document InputFile `json:"document"`
	// Document thumbnail, if available
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// If true, automatic file type detection will be disabled and the document will be always sent as file. Always true for files sent to secret chats
	DisableContentTypeDetection bool `json:"disable_content_type_detection"`
	// Document caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// contains filtered or unexported fields
}

A document message (general file)

func UnmarshalInputMessageDocument

func UnmarshalInputMessageDocument(data json.RawMessage) (*InputMessageDocument, error)

func (*InputMessageDocument) GetClass

func (*InputMessageDocument) GetClass() string

func (*InputMessageDocument) GetType

func (*InputMessageDocument) GetType() string

func (*InputMessageDocument) InputMessageContentType

func (*InputMessageDocument) InputMessageContentType() string

func (*InputMessageDocument) MarshalJSON

func (entity *InputMessageDocument) MarshalJSON() ([]byte, error)

func (*InputMessageDocument) UnmarshalJSON

func (inputMessageDocument *InputMessageDocument) UnmarshalJSON(data []byte) error

type InputMessageForwarded

type InputMessageForwarded struct {

	// Identifier for the chat this forwarded message came from
	FromChatId int64 `json:"from_chat_id"`
	// Identifier of the message to forward
	MessageId int64 `json:"message_id"`
	// True, if a game message should be shared within a launched game; applies only to game messages
	InGameShare bool `json:"in_game_share"`
	// Options to be used to copy content of the message without a link to the original message
	CopyOptions *MessageCopyOptions `json:"copy_options"`
	// contains filtered or unexported fields
}

A forwarded message

func UnmarshalInputMessageForwarded

func UnmarshalInputMessageForwarded(data json.RawMessage) (*InputMessageForwarded, error)

func (*InputMessageForwarded) GetClass

func (*InputMessageForwarded) GetClass() string

func (*InputMessageForwarded) GetType

func (*InputMessageForwarded) GetType() string

func (*InputMessageForwarded) InputMessageContentType

func (*InputMessageForwarded) InputMessageContentType() string

func (*InputMessageForwarded) MarshalJSON

func (entity *InputMessageForwarded) MarshalJSON() ([]byte, error)

type InputMessageGame

type InputMessageGame struct {

	// User identifier of the bot that owns the game
	BotUserId int32 `json:"bot_user_id"`
	// Short name of the game
	GameShortName string `json:"game_short_name"`
	// contains filtered or unexported fields
}

A message with a game; not supported for channels or secret chats

func UnmarshalInputMessageGame

func UnmarshalInputMessageGame(data json.RawMessage) (*InputMessageGame, error)

func (*InputMessageGame) GetClass

func (*InputMessageGame) GetClass() string

func (*InputMessageGame) GetType

func (*InputMessageGame) GetType() string

func (*InputMessageGame) InputMessageContentType

func (*InputMessageGame) InputMessageContentType() string

func (*InputMessageGame) MarshalJSON

func (entity *InputMessageGame) MarshalJSON() ([]byte, error)

type InputMessageInvoice

type InputMessageInvoice struct {

	// Invoice
	Invoice *Invoice `json:"invoice"`
	// Product title; 1-32 characters
	Title string `json:"title"`
	// Product description; 0-255 characters
	Description string `json:"description"`
	// Product photo URL; optional
	PhotoUrl string `json:"photo_url"`
	// Product photo size
	PhotoSize int32 `json:"photo_size"`
	// Product photo width
	PhotoWidth int32 `json:"photo_width"`
	// Product photo height
	PhotoHeight int32 `json:"photo_height"`
	// The invoice payload
	Payload []byte `json:"payload"`
	// Payment provider token
	ProviderToken string `json:"provider_token"`
	// JSON-encoded data about the invoice, which will be shared with the payment provider
	ProviderData string `json:"provider_data"`
	// Unique invoice bot start_parameter for the generation of this invoice
	StartParameter string `json:"start_parameter"`
	// contains filtered or unexported fields
}

A message with an invoice; can be used only by bots and only in private chats

func UnmarshalInputMessageInvoice

func UnmarshalInputMessageInvoice(data json.RawMessage) (*InputMessageInvoice, error)

func (*InputMessageInvoice) GetClass

func (*InputMessageInvoice) GetClass() string

func (*InputMessageInvoice) GetType

func (*InputMessageInvoice) GetType() string

func (*InputMessageInvoice) InputMessageContentType

func (*InputMessageInvoice) InputMessageContentType() string

func (*InputMessageInvoice) MarshalJSON

func (entity *InputMessageInvoice) MarshalJSON() ([]byte, error)

type InputMessageLocation

type InputMessageLocation struct {

	// Location to be sent
	Location *Location `json:"location"`
	// Period for which the location can be updated, in seconds; should be between 60 and 86400 for a live location and 0 otherwise
	LivePeriod int32 `json:"live_period"`
	// For live locations, a direction in which the location moves, in degrees; 1-360. Pass 0 if unknown
	Heading int32 `json:"heading"`
	// For live locations, a maximum distance to another chat member for proximity alerts, in meters (0-100000). Pass 0 if the notification is disabled. Can't be enabled in channels and Saved Messages
	ProximityAlertRadius int32 `json:"proximity_alert_radius"`
	// contains filtered or unexported fields
}

A message with a location

func UnmarshalInputMessageLocation

func UnmarshalInputMessageLocation(data json.RawMessage) (*InputMessageLocation, error)

func (*InputMessageLocation) GetClass

func (*InputMessageLocation) GetClass() string

func (*InputMessageLocation) GetType

func (*InputMessageLocation) GetType() string

func (*InputMessageLocation) InputMessageContentType

func (*InputMessageLocation) InputMessageContentType() string

func (*InputMessageLocation) MarshalJSON

func (entity *InputMessageLocation) MarshalJSON() ([]byte, error)

type InputMessagePhoto

type InputMessagePhoto struct {

	// Photo to send
	Photo InputFile `json:"photo"`
	// Photo thumbnail to be sent, this is sent to the other party in secret chats only
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// File identifiers of the stickers added to the photo, if applicable
	AddedStickerFileIds []int32 `json:"added_sticker_file_ids"`
	// Photo width
	Width int32 `json:"width"`
	// Photo height
	Height int32 `json:"height"`
	// Photo caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// Photo TTL (Time To Live), in seconds (0-60). A non-zero TTL can be specified only in private chats
	Ttl int32 `json:"ttl"`
	// contains filtered or unexported fields
}

A photo message

func UnmarshalInputMessagePhoto

func UnmarshalInputMessagePhoto(data json.RawMessage) (*InputMessagePhoto, error)

func (*InputMessagePhoto) GetClass

func (*InputMessagePhoto) GetClass() string

func (*InputMessagePhoto) GetType

func (*InputMessagePhoto) GetType() string

func (*InputMessagePhoto) InputMessageContentType

func (*InputMessagePhoto) InputMessageContentType() string

func (*InputMessagePhoto) MarshalJSON

func (entity *InputMessagePhoto) MarshalJSON() ([]byte, error)

func (*InputMessagePhoto) UnmarshalJSON

func (inputMessagePhoto *InputMessagePhoto) UnmarshalJSON(data []byte) error

type InputMessagePoll

type InputMessagePoll struct {

	// Poll question, 1-255 characters (up to 300 characters for bots)
	Question string `json:"question"`
	// List of poll answer options, 2-10 strings 1-100 characters each
	Options []string `json:"options"`
	// True, if the poll voters are anonymous. Non-anonymous polls can't be sent or forwarded to channels
	IsAnonymous bool `json:"is_anonymous"`
	// Type of the poll
	Type PollType `json:"type"`
	// Amount of time the poll will be active after creation, in seconds; for bots only
	OpenPeriod int32 `json:"open_period"`
	// Point in time (Unix timestamp) when the poll will be automatically closed; for bots only
	CloseDate int32 `json:"close_date"`
	// True, if the poll needs to be sent already closed; for bots only
	IsClosed bool `json:"is_closed"`
	// contains filtered or unexported fields
}

A message with a poll. Polls can't be sent to secret chats. Polls can be sent only to a private chat with a bot

func UnmarshalInputMessagePoll

func UnmarshalInputMessagePoll(data json.RawMessage) (*InputMessagePoll, error)

func (*InputMessagePoll) GetClass

func (*InputMessagePoll) GetClass() string

func (*InputMessagePoll) GetType

func (*InputMessagePoll) GetType() string

func (*InputMessagePoll) InputMessageContentType

func (*InputMessagePoll) InputMessageContentType() string

func (*InputMessagePoll) MarshalJSON

func (entity *InputMessagePoll) MarshalJSON() ([]byte, error)

func (*InputMessagePoll) UnmarshalJSON

func (inputMessagePoll *InputMessagePoll) UnmarshalJSON(data []byte) error

type InputMessageSticker

type InputMessageSticker struct {

	// Sticker to be sent
	Sticker InputFile `json:"sticker"`
	// Sticker thumbnail, if available
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// Sticker width
	Width int32 `json:"width"`
	// Sticker height
	Height int32 `json:"height"`
	// contains filtered or unexported fields
}

A sticker message

func UnmarshalInputMessageSticker

func UnmarshalInputMessageSticker(data json.RawMessage) (*InputMessageSticker, error)

func (*InputMessageSticker) GetClass

func (*InputMessageSticker) GetClass() string

func (*InputMessageSticker) GetType

func (*InputMessageSticker) GetType() string

func (*InputMessageSticker) InputMessageContentType

func (*InputMessageSticker) InputMessageContentType() string

func (*InputMessageSticker) MarshalJSON

func (entity *InputMessageSticker) MarshalJSON() ([]byte, error)

func (*InputMessageSticker) UnmarshalJSON

func (inputMessageSticker *InputMessageSticker) UnmarshalJSON(data []byte) error

type InputMessageText

type InputMessageText struct {

	// Formatted text to be sent; 1-GetOption("message_text_length_max") characters. Only Bold, Italic, Underline, Strikethrough, Code, Pre, PreCode, TextUrl and MentionName entities are allowed to be specified manually
	Text *FormattedText `json:"text"`
	// True, if rich web page previews for URLs in the message text should be disabled
	DisableWebPagePreview bool `json:"disable_web_page_preview"`
	// True, if a chat message draft should be deleted
	ClearDraft bool `json:"clear_draft"`
	// contains filtered or unexported fields
}

A text message

func UnmarshalInputMessageText

func UnmarshalInputMessageText(data json.RawMessage) (*InputMessageText, error)

func (*InputMessageText) GetClass

func (*InputMessageText) GetClass() string

func (*InputMessageText) GetType

func (*InputMessageText) GetType() string

func (*InputMessageText) InputMessageContentType

func (*InputMessageText) InputMessageContentType() string

func (*InputMessageText) MarshalJSON

func (entity *InputMessageText) MarshalJSON() ([]byte, error)

type InputMessageVenue

type InputMessageVenue struct {

	// Venue to send
	Venue *Venue `json:"venue"`
	// contains filtered or unexported fields
}

A message with information about a venue

func UnmarshalInputMessageVenue

func UnmarshalInputMessageVenue(data json.RawMessage) (*InputMessageVenue, error)

func (*InputMessageVenue) GetClass

func (*InputMessageVenue) GetClass() string

func (*InputMessageVenue) GetType

func (*InputMessageVenue) GetType() string

func (*InputMessageVenue) InputMessageContentType

func (*InputMessageVenue) InputMessageContentType() string

func (*InputMessageVenue) MarshalJSON

func (entity *InputMessageVenue) MarshalJSON() ([]byte, error)

type InputMessageVideo

type InputMessageVideo struct {

	// Video to be sent
	Video InputFile `json:"video"`
	// Video thumbnail, if available
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// File identifiers of the stickers added to the video, if applicable
	AddedStickerFileIds []int32 `json:"added_sticker_file_ids"`
	// Duration of the video, in seconds
	Duration int32 `json:"duration"`
	// Video width
	Width int32 `json:"width"`
	// Video height
	Height int32 `json:"height"`
	// True, if the video should be tried to be streamed
	SupportsStreaming bool `json:"supports_streaming"`
	// Video caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// Video TTL (Time To Live), in seconds (0-60). A non-zero TTL can be specified only in private chats
	Ttl int32 `json:"ttl"`
	// contains filtered or unexported fields
}

A video message

func UnmarshalInputMessageVideo

func UnmarshalInputMessageVideo(data json.RawMessage) (*InputMessageVideo, error)

func (*InputMessageVideo) GetClass

func (*InputMessageVideo) GetClass() string

func (*InputMessageVideo) GetType

func (*InputMessageVideo) GetType() string

func (*InputMessageVideo) InputMessageContentType

func (*InputMessageVideo) InputMessageContentType() string

func (*InputMessageVideo) MarshalJSON

func (entity *InputMessageVideo) MarshalJSON() ([]byte, error)

func (*InputMessageVideo) UnmarshalJSON

func (inputMessageVideo *InputMessageVideo) UnmarshalJSON(data []byte) error

type InputMessageVideoNote

type InputMessageVideoNote struct {

	// Video note to be sent
	VideoNote InputFile `json:"video_note"`
	// Video thumbnail, if available
	Thumbnail *InputThumbnail `json:"thumbnail"`
	// Duration of the video, in seconds
	Duration int32 `json:"duration"`
	// Video width and height; must be positive and not greater than 640
	Length int32 `json:"length"`
	// contains filtered or unexported fields
}

A video note message

func UnmarshalInputMessageVideoNote

func UnmarshalInputMessageVideoNote(data json.RawMessage) (*InputMessageVideoNote, error)

func (*InputMessageVideoNote) GetClass

func (*InputMessageVideoNote) GetClass() string

func (*InputMessageVideoNote) GetType

func (*InputMessageVideoNote) GetType() string

func (*InputMessageVideoNote) InputMessageContentType

func (*InputMessageVideoNote) InputMessageContentType() string

func (*InputMessageVideoNote) MarshalJSON

func (entity *InputMessageVideoNote) MarshalJSON() ([]byte, error)

func (*InputMessageVideoNote) UnmarshalJSON

func (inputMessageVideoNote *InputMessageVideoNote) UnmarshalJSON(data []byte) error

type InputMessageVoiceNote

type InputMessageVoiceNote struct {

	// Voice note to be sent
	VoiceNote InputFile `json:"voice_note"`
	// Duration of the voice note, in seconds
	Duration int32 `json:"duration"`
	// Waveform representation of the voice note, in 5-bit format
	Waveform []byte `json:"waveform"`
	// Voice note caption; 0-GetOption("message_caption_length_max") characters
	Caption *FormattedText `json:"caption"`
	// contains filtered or unexported fields
}

A voice note message

func UnmarshalInputMessageVoiceNote

func UnmarshalInputMessageVoiceNote(data json.RawMessage) (*InputMessageVoiceNote, error)

func (*InputMessageVoiceNote) GetClass

func (*InputMessageVoiceNote) GetClass() string

func (*InputMessageVoiceNote) GetType

func (*InputMessageVoiceNote) GetType() string

func (*InputMessageVoiceNote) InputMessageContentType

func (*InputMessageVoiceNote) InputMessageContentType() string

func (*InputMessageVoiceNote) MarshalJSON

func (entity *InputMessageVoiceNote) MarshalJSON() ([]byte, error)

func (*InputMessageVoiceNote) UnmarshalJSON

func (inputMessageVoiceNote *InputMessageVoiceNote) UnmarshalJSON(data []byte) error

type InputPassportElement

type InputPassportElement interface {
	InputPassportElementType() string
}

Contains information about a Telegram Passport element to be saved

func UnmarshalInputPassportElement

func UnmarshalInputPassportElement(data json.RawMessage) (InputPassportElement, error)

func UnmarshalListOfInputPassportElement

func UnmarshalListOfInputPassportElement(dataList []json.RawMessage) ([]InputPassportElement, error)

type InputPassportElementAddress

type InputPassportElementAddress struct {

	// The address to be saved
	Address *Address `json:"address"`
	// contains filtered or unexported fields
}

A Telegram Passport element to be saved containing the user's address

func UnmarshalInputPassportElementAddress

func UnmarshalInputPassportElementAddress(data json.RawMessage) (*InputPassportElementAddress, error)

func (*InputPassportElementAddress) GetClass

func (*InputPassportElementAddress) GetClass() string

func (*InputPassportElementAddress) GetType

func (*InputPassportElementAddress) InputPassportElementType

func (*InputPassportElementAddress) InputPassportElementType() string

func (*InputPassportElementAddress) MarshalJSON

func (entity *InputPassportElementAddress) MarshalJSON() ([]byte, error)

type InputPassportElementBankStatement

type InputPassportElementBankStatement struct {

	// The bank statement to be saved
	BankStatement *InputPersonalDocument `json:"bank_statement"`
	// contains filtered or unexported fields
}

A Telegram Passport element to be saved containing the user's bank statement

func UnmarshalInputPassportElementBankStatement

func UnmarshalInputPassportElementBankStatement(data json.RawMessage) (*InputPassportElementBankStatement, error)

func (*InputPassportElementBankStatement) GetClass

func (*InputPassportElementBankStatement) GetType

func (*InputPassportElementBankStatement) InputPassportElementType

func (*InputPassportElementBankStatement) InputPassportElementType() string

func (*InputPassportElementBankStatement) MarshalJSON

func (entity *InputPassportElementBankStatement) MarshalJSON() ([]byte, error)

type InputPassportElementDriverLicense

type InputPassportElementDriverLicense struct {

	// The driver license to be saved
	DriverLicense *InputIdentityDocument `json:"driver_license"`
	// contains filtered or unexported fields
}

A Telegram Passport element to be saved containing the user's driver license

func UnmarshalInputPassportElementDriverLicense

func UnmarshalInputPassportElementDriverLicense(data json.RawMessage) (*InputPassportElementDriverLicense, error)

func (*InputPassportElementDriverLicense) GetClass

func (*InputPassportElementDriverLicense) GetType

func (*InputPassportElementDriverLicense) InputPassportElementType

func (*InputPassportElementDriverLicense) InputPassportElementType() string

func (*InputPassportElementDriverLicense) MarshalJSON

func (entity *InputPassportElementDriverLicense) MarshalJSON() ([]byte, error)

type InputPassportElementEmailAddress

type InputPassportElementEmailAddress struct {

	// The email address to be saved
	EmailAddress string `json:"email_address"`
	// contains filtered or unexported fields
}

A Telegram Passport element to be saved containing the user's email address

func UnmarshalInputPassportElementEmailAddress

func UnmarshalInputPassportElementEmailAddress(data json.RawMessage) (*InputPassportElementEmailAddress, error)

func (*InputPassportElementEmailAddress) GetClass

func (*InputPassportElementEmailAddress) GetType

func (*InputPassportElementEmailAddress) InputPassportElementType

func (*InputPassportElementEmailAddress) InputPassportElementType() string

func (*InputPassportElementEmailAddress) MarshalJSON

func (entity *InputPassportElementEmailAddress) MarshalJSON() ([]byte, error)

type InputPassportElementError

type InputPassportElementError struct {

	// Type of Telegram Passport element that has the error
	Type PassportElementType `json:"type"`
	// Error message
	Message string `json:"message"`
	// Error source
	Source InputPassportElementErrorSource `json:"source"`
	// contains filtered or unexported fields
}

Contains the description of an error in a Telegram Passport element; for bots only

func UnmarshalInputPassportElementError

func UnmarshalInputPassportElementError(data json.RawMessage) (*InputPassportElementError, error)

func (*InputPassportElementError) GetClass

func (*InputPassportElementError) GetClass() string

func (*InputPassportElementError) GetType

func (*InputPassportElementError) GetType() string

func (*InputPassportElementError) MarshalJSON

func (entity *InputPassportElementError) MarshalJSON() ([]byte, error)

func (*InputPassportElementError) UnmarshalJSON

func (inputPassportElementError *InputPassportElementError) UnmarshalJSON(data []byte) error

type InputPassportElementErrorSource

type InputPassportElementErrorSource interface {
	InputPassportElementErrorSourceType() string
}

Contains the description of an error in a Telegram Passport element; for bots only

func UnmarshalInputPassportElementErrorSource

func UnmarshalInputPassportElementErrorSource(data json.RawMessage) (InputPassportElementErrorSource, error)

func UnmarshalListOfInputPassportElementErrorSource

func UnmarshalListOfInputPassportElementErrorSource(dataList []json.RawMessage) ([]InputPassportElementErrorSource, error)

type InputPassportElementErrorSourceDataField

type InputPassportElementErrorSourceDataField struct {

	// Field name
	FieldName string `json:"field_name"`
	// Current data hash
	DataHash []byte `json:"data_hash"`
	// contains filtered or unexported fields
}

A data field contains an error. The error is considered resolved when the field's value changes

func UnmarshalInputPassportElementErrorSourceDataField

func UnmarshalInputPassportElementErrorSourceDataField(data json.RawMessage) (*InputPassportElementErrorSourceDataField, error)

func (*InputPassportElementErrorSourceDataField) GetClass

func (*InputPassportElementErrorSourceDataField) GetType

func (*InputPassportElementErrorSourceDataField) InputPassportElementErrorSourceType

func (*InputPassportElementErrorSourceDataField) InputPassportElementErrorSourceType() string