Documentation
¶
Overview ¶
Package tg contains generated types from MTProto Telegram API.
Index ¶
- Constants
- func TypesConstructorMap() map[uint32]func() bin.Object
- func TypesMap() map[uint32]string
- type AccountAcceptAuthorizationRequest
- type AccountAuthorizationForm
- func (a *AccountAuthorizationForm) Decode(b *bin.Buffer) error
- func (a *AccountAuthorizationForm) Encode(b *bin.Buffer) error
- func (a *AccountAuthorizationForm) GetPrivacyPolicyURL() (value string, ok bool)
- func (a *AccountAuthorizationForm) SetPrivacyPolicyURL(value string)
- func (a *AccountAuthorizationForm) String() string
- type AccountAuthorizations
- type AccountAutoDownloadSettings
- type AccountCancelPasswordEmailRequest
- type AccountChangePhoneRequest
- type AccountCheckUsernameRequest
- type AccountConfirmPasswordEmailRequest
- type AccountConfirmPhoneRequest
- type AccountContentSettings
- func (c *AccountContentSettings) Decode(b *bin.Buffer) error
- func (c *AccountContentSettings) Encode(b *bin.Buffer) error
- func (c *AccountContentSettings) SetSensitiveCanChange(value bool)
- func (c *AccountContentSettings) SetSensitiveEnabled(value bool)
- func (c *AccountContentSettings) String() string
- type AccountCreateThemeRequest
- func (c *AccountCreateThemeRequest) Decode(b *bin.Buffer) error
- func (c *AccountCreateThemeRequest) Encode(b *bin.Buffer) error
- func (c *AccountCreateThemeRequest) GetDocument() (value InputDocumentClass, ok bool)
- func (c *AccountCreateThemeRequest) GetSettings() (value InputThemeSettings, ok bool)
- func (c *AccountCreateThemeRequest) SetDocument(value InputDocumentClass)
- func (c *AccountCreateThemeRequest) SetSettings(value InputThemeSettings)
- func (c *AccountCreateThemeRequest) String() string
- type AccountDaysTTL
- type AccountDeleteAccountRequest
- type AccountDeleteSecureValueRequest
- type AccountFinishTakeoutSessionRequest
- type AccountGetAccountTTLRequest
- type AccountGetAllSecureValuesRequest
- type AccountGetAuthorizationFormRequest
- type AccountGetAuthorizationsRequest
- type AccountGetAutoDownloadSettingsRequest
- type AccountGetContactSignUpNotificationRequest
- type AccountGetContentSettingsRequest
- type AccountGetGlobalPrivacySettingsRequest
- type AccountGetMultiWallPapersRequest
- type AccountGetNotifyExceptionsRequest
- func (g *AccountGetNotifyExceptionsRequest) Decode(b *bin.Buffer) error
- func (g *AccountGetNotifyExceptionsRequest) Encode(b *bin.Buffer) error
- func (g *AccountGetNotifyExceptionsRequest) GetPeer() (value InputNotifyPeerClass, ok bool)
- func (g *AccountGetNotifyExceptionsRequest) SetCompareSound(value bool)
- func (g *AccountGetNotifyExceptionsRequest) SetPeer(value InputNotifyPeerClass)
- func (g *AccountGetNotifyExceptionsRequest) String() string
- type AccountGetNotifySettingsRequest
- type AccountGetPasswordRequest
- type AccountGetPasswordSettingsRequest
- type AccountGetPrivacyRequest
- type AccountGetSecureValueRequest
- type AccountGetThemeRequest
- type AccountGetThemesRequest
- type AccountGetTmpPasswordRequest
- type AccountGetWallPaperRequest
- type AccountGetWallPapersRequest
- type AccountGetWebAuthorizationsRequest
- type AccountInitTakeoutSessionRequest
- func (i *AccountInitTakeoutSessionRequest) Decode(b *bin.Buffer) error
- func (i *AccountInitTakeoutSessionRequest) Encode(b *bin.Buffer) error
- func (i *AccountInitTakeoutSessionRequest) GetFileMaxSize() (value int, ok bool)
- func (i *AccountInitTakeoutSessionRequest) SetContacts(value bool)
- func (i *AccountInitTakeoutSessionRequest) SetFileMaxSize(value int)
- func (i *AccountInitTakeoutSessionRequest) SetFiles(value bool)
- func (i *AccountInitTakeoutSessionRequest) SetMessageChannels(value bool)
- func (i *AccountInitTakeoutSessionRequest) SetMessageChats(value bool)
- func (i *AccountInitTakeoutSessionRequest) SetMessageMegagroups(value bool)
- func (i *AccountInitTakeoutSessionRequest) SetMessageUsers(value bool)
- func (i *AccountInitTakeoutSessionRequest) String() string
- type AccountInstallThemeRequest
- func (i *AccountInstallThemeRequest) Decode(b *bin.Buffer) error
- func (i *AccountInstallThemeRequest) Encode(b *bin.Buffer) error
- func (i *AccountInstallThemeRequest) GetFormat() (value string, ok bool)
- func (i *AccountInstallThemeRequest) GetTheme() (value InputThemeClass, ok bool)
- func (i *AccountInstallThemeRequest) SetDark(value bool)
- func (i *AccountInstallThemeRequest) SetFormat(value string)
- func (i *AccountInstallThemeRequest) SetTheme(value InputThemeClass)
- func (i *AccountInstallThemeRequest) String() string
- type AccountInstallWallPaperRequest
- type AccountPassword
- func (p *AccountPassword) Decode(b *bin.Buffer) error
- func (p *AccountPassword) Encode(b *bin.Buffer) error
- func (p *AccountPassword) GetCurrentAlgo() (value PasswordKdfAlgoClass, ok bool)
- func (p *AccountPassword) GetEmailUnconfirmedPattern() (value string, ok bool)
- func (p *AccountPassword) GetHint() (value string, ok bool)
- func (p *AccountPassword) GetSrpB() (value []byte, ok bool)
- func (p *AccountPassword) GetSrpID() (value int64, ok bool)
- func (p *AccountPassword) SetCurrentAlgo(value PasswordKdfAlgoClass)
- func (p *AccountPassword) SetEmailUnconfirmedPattern(value string)
- func (p *AccountPassword) SetHasPassword(value bool)
- func (p *AccountPassword) SetHasRecovery(value bool)
- func (p *AccountPassword) SetHasSecureValues(value bool)
- func (p *AccountPassword) SetHint(value string)
- func (p *AccountPassword) SetSrpB(value []byte)
- func (p *AccountPassword) SetSrpID(value int64)
- func (p *AccountPassword) String() string
- type AccountPasswordInputSettings
- func (p *AccountPasswordInputSettings) Decode(b *bin.Buffer) error
- func (p *AccountPasswordInputSettings) Encode(b *bin.Buffer) error
- func (p *AccountPasswordInputSettings) GetEmail() (value string, ok bool)
- func (p *AccountPasswordInputSettings) GetHint() (value string, ok bool)
- func (p *AccountPasswordInputSettings) GetNewAlgo() (value PasswordKdfAlgoClass, ok bool)
- func (p *AccountPasswordInputSettings) GetNewPasswordHash() (value []byte, ok bool)
- func (p *AccountPasswordInputSettings) GetNewSecureSettings() (value SecureSecretSettings, ok bool)
- func (p *AccountPasswordInputSettings) SetEmail(value string)
- func (p *AccountPasswordInputSettings) SetHint(value string)
- func (p *AccountPasswordInputSettings) SetNewAlgo(value PasswordKdfAlgoClass)
- func (p *AccountPasswordInputSettings) SetNewPasswordHash(value []byte)
- func (p *AccountPasswordInputSettings) SetNewSecureSettings(value SecureSecretSettings)
- func (p *AccountPasswordInputSettings) String() string
- type AccountPasswordSettings
- func (p *AccountPasswordSettings) Decode(b *bin.Buffer) error
- func (p *AccountPasswordSettings) Encode(b *bin.Buffer) error
- func (p *AccountPasswordSettings) GetEmail() (value string, ok bool)
- func (p *AccountPasswordSettings) GetSecureSettings() (value SecureSecretSettings, ok bool)
- func (p *AccountPasswordSettings) SetEmail(value string)
- func (p *AccountPasswordSettings) SetSecureSettings(value SecureSecretSettings)
- func (p *AccountPasswordSettings) String() string
- type AccountPrivacyRules
- type AccountRegisterDeviceRequest
- type AccountReportPeerRequest
- type AccountResendPasswordEmailRequest
- type AccountResetAuthorizationRequest
- type AccountResetNotifySettingsRequest
- type AccountResetWallPapersRequest
- type AccountResetWebAuthorizationRequest
- type AccountResetWebAuthorizationsRequest
- type AccountSaveAutoDownloadSettingsRequest
- func (s *AccountSaveAutoDownloadSettingsRequest) Decode(b *bin.Buffer) error
- func (s *AccountSaveAutoDownloadSettingsRequest) Encode(b *bin.Buffer) error
- func (s *AccountSaveAutoDownloadSettingsRequest) SetHigh(value bool)
- func (s *AccountSaveAutoDownloadSettingsRequest) SetLow(value bool)
- func (s *AccountSaveAutoDownloadSettingsRequest) String() string
- type AccountSaveSecureValueRequest
- type AccountSaveThemeRequest
- type AccountSaveWallPaperRequest
- type AccountSendChangePhoneCodeRequest
- type AccountSendConfirmPhoneCodeRequest
- type AccountSendVerifyEmailCodeRequest
- type AccountSendVerifyPhoneCodeRequest
- type AccountSentEmailCode
- type AccountSetAccountTTLRequest
- type AccountSetContactSignUpNotificationRequest
- type AccountSetContentSettingsRequest
- type AccountSetGlobalPrivacySettingsRequest
- type AccountSetPrivacyRequest
- type AccountTakeout
- type AccountThemes
- type AccountThemesBox
- type AccountThemesClass
- type AccountThemesNotModified
- type AccountTmpPassword
- type AccountUnregisterDeviceRequest
- type AccountUpdateDeviceLockedRequest
- type AccountUpdateNotifySettingsRequest
- type AccountUpdatePasswordSettingsRequest
- type AccountUpdateProfileRequest
- func (u *AccountUpdateProfileRequest) Decode(b *bin.Buffer) error
- func (u *AccountUpdateProfileRequest) Encode(b *bin.Buffer) error
- func (u *AccountUpdateProfileRequest) GetAbout() (value string, ok bool)
- func (u *AccountUpdateProfileRequest) GetFirstName() (value string, ok bool)
- func (u *AccountUpdateProfileRequest) GetLastName() (value string, ok bool)
- func (u *AccountUpdateProfileRequest) SetAbout(value string)
- func (u *AccountUpdateProfileRequest) SetFirstName(value string)
- func (u *AccountUpdateProfileRequest) SetLastName(value string)
- func (u *AccountUpdateProfileRequest) String() string
- type AccountUpdateStatusRequest
- type AccountUpdateThemeRequest
- func (u *AccountUpdateThemeRequest) Decode(b *bin.Buffer) error
- func (u *AccountUpdateThemeRequest) Encode(b *bin.Buffer) error
- func (u *AccountUpdateThemeRequest) GetDocument() (value InputDocumentClass, ok bool)
- func (u *AccountUpdateThemeRequest) GetSettings() (value InputThemeSettings, ok bool)
- func (u *AccountUpdateThemeRequest) GetSlug() (value string, ok bool)
- func (u *AccountUpdateThemeRequest) GetTitle() (value string, ok bool)
- func (u *AccountUpdateThemeRequest) SetDocument(value InputDocumentClass)
- func (u *AccountUpdateThemeRequest) SetSettings(value InputThemeSettings)
- func (u *AccountUpdateThemeRequest) SetSlug(value string)
- func (u *AccountUpdateThemeRequest) SetTitle(value string)
- func (u *AccountUpdateThemeRequest) String() string
- type AccountUpdateUsernameRequest
- type AccountUploadThemeRequest
- func (u *AccountUploadThemeRequest) Decode(b *bin.Buffer) error
- func (u *AccountUploadThemeRequest) Encode(b *bin.Buffer) error
- func (u *AccountUploadThemeRequest) GetThumb() (value InputFileClass, ok bool)
- func (u *AccountUploadThemeRequest) SetThumb(value InputFileClass)
- func (u *AccountUploadThemeRequest) String() string
- type AccountUploadWallPaperRequest
- type AccountVerifyEmailRequest
- type AccountVerifyPhoneRequest
- type AccountWallPapers
- type AccountWallPapersBox
- type AccountWallPapersClass
- type AccountWallPapersNotModified
- type AccountWebAuthorizations
- type AuthAcceptLoginTokenRequest
- type AuthAuthorization
- type AuthAuthorizationBox
- type AuthAuthorizationClass
- type AuthAuthorizationSignUpRequired
- func (a *AuthAuthorizationSignUpRequired) Decode(b *bin.Buffer) error
- func (a *AuthAuthorizationSignUpRequired) Encode(b *bin.Buffer) error
- func (a *AuthAuthorizationSignUpRequired) GetTermsOfService() (value HelpTermsOfService, ok bool)
- func (a *AuthAuthorizationSignUpRequired) SetTermsOfService(value HelpTermsOfService)
- func (a *AuthAuthorizationSignUpRequired) String() string
- type AuthBindTempAuthKeyRequest
- type AuthCancelCodeRequest
- type AuthCheckPasswordRequest
- type AuthCodeTypeBox
- type AuthCodeTypeCall
- type AuthCodeTypeClass
- type AuthCodeTypeFlashCall
- type AuthCodeTypeSms
- type AuthDropTempAuthKeysRequest
- type AuthExportAuthorizationRequest
- type AuthExportLoginTokenRequest
- type AuthExportedAuthorization
- type AuthImportAuthorizationRequest
- type AuthImportBotAuthorizationRequest
- type AuthImportLoginTokenRequest
- type AuthLogOutRequest
- type AuthLoginToken
- type AuthLoginTokenBox
- type AuthLoginTokenClass
- type AuthLoginTokenMigrateTo
- type AuthLoginTokenSuccess
- type AuthPasswordRecovery
- type AuthRecoverPasswordRequest
- type AuthRequestPasswordRecoveryRequest
- type AuthResendCodeRequest
- type AuthResetAuthorizationsRequest
- type AuthSendCodeRequest
- type AuthSentCode
- func (s *AuthSentCode) Decode(b *bin.Buffer) error
- func (s *AuthSentCode) Encode(b *bin.Buffer) error
- func (s *AuthSentCode) GetNextType() (value AuthCodeTypeClass, ok bool)
- func (s *AuthSentCode) GetTimeout() (value int, ok bool)
- func (s *AuthSentCode) SetNextType(value AuthCodeTypeClass)
- func (s *AuthSentCode) SetTimeout(value int)
- func (s *AuthSentCode) String() string
- type AuthSentCodeTypeApp
- type AuthSentCodeTypeBox
- type AuthSentCodeTypeCall
- type AuthSentCodeTypeClass
- type AuthSentCodeTypeFlashCall
- type AuthSentCodeTypeSms
- type AuthSignInRequest
- type AuthSignUpRequest
- type Authorization
- type AutoDownloadSettings
- func (a *AutoDownloadSettings) Decode(b *bin.Buffer) error
- func (a *AutoDownloadSettings) Encode(b *bin.Buffer) error
- func (a *AutoDownloadSettings) SetAudioPreloadNext(value bool)
- func (a *AutoDownloadSettings) SetDisabled(value bool)
- func (a *AutoDownloadSettings) SetPhonecallsLessData(value bool)
- func (a *AutoDownloadSettings) SetVideoPreloadLarge(value bool)
- func (a *AutoDownloadSettings) String() string
- type BankCardOpenUrl
- type BaseThemeArctic
- type BaseThemeBox
- type BaseThemeClass
- type BaseThemeClassic
- type BaseThemeDay
- type BaseThemeNight
- type BaseThemeTinted
- type BoolBox
- type BoolClass
- type BoolFalse
- type BoolTrue
- type BotCallbackQueryHandler
- type BotCommand
- type BotInfo
- type BotInlineMediaResult
- func (b *BotInlineMediaResult) Decode(buf *bin.Buffer) error
- func (b *BotInlineMediaResult) Encode(buf *bin.Buffer) error
- func (b *BotInlineMediaResult) GetDescription() (value string, ok bool)
- func (b *BotInlineMediaResult) GetDocument() (value DocumentClass, ok bool)
- func (b *BotInlineMediaResult) GetPhoto() (value PhotoClass, ok bool)
- func (b *BotInlineMediaResult) GetTitle() (value string, ok bool)
- func (b *BotInlineMediaResult) SetDescription(value string)
- func (b *BotInlineMediaResult) SetDocument(value DocumentClass)
- func (b *BotInlineMediaResult) SetPhoto(value PhotoClass)
- func (b *BotInlineMediaResult) SetTitle(value string)
- func (b *BotInlineMediaResult) String() string
- type BotInlineMessageBox
- type BotInlineMessageClass
- type BotInlineMessageMediaAuto
- func (b *BotInlineMessageMediaAuto) Decode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaAuto) Encode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaAuto) GetEntities() (value []MessageEntityClass, ok bool)
- func (b *BotInlineMessageMediaAuto) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (b *BotInlineMessageMediaAuto) SetEntities(value []MessageEntityClass)
- func (b *BotInlineMessageMediaAuto) SetReplyMarkup(value ReplyMarkupClass)
- func (b *BotInlineMessageMediaAuto) String() string
- type BotInlineMessageMediaContact
- func (b *BotInlineMessageMediaContact) Decode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaContact) Encode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaContact) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (b *BotInlineMessageMediaContact) SetReplyMarkup(value ReplyMarkupClass)
- func (b *BotInlineMessageMediaContact) String() string
- type BotInlineMessageMediaGeo
- func (b *BotInlineMessageMediaGeo) Decode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaGeo) Encode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaGeo) GetHeading() (value int, ok bool)
- func (b *BotInlineMessageMediaGeo) GetPeriod() (value int, ok bool)
- func (b *BotInlineMessageMediaGeo) GetProximityNotificationRadius() (value int, ok bool)
- func (b *BotInlineMessageMediaGeo) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (b *BotInlineMessageMediaGeo) SetHeading(value int)
- func (b *BotInlineMessageMediaGeo) SetPeriod(value int)
- func (b *BotInlineMessageMediaGeo) SetProximityNotificationRadius(value int)
- func (b *BotInlineMessageMediaGeo) SetReplyMarkup(value ReplyMarkupClass)
- func (b *BotInlineMessageMediaGeo) String() string
- type BotInlineMessageMediaVenue
- func (b *BotInlineMessageMediaVenue) Decode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaVenue) Encode(buf *bin.Buffer) error
- func (b *BotInlineMessageMediaVenue) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (b *BotInlineMessageMediaVenue) SetReplyMarkup(value ReplyMarkupClass)
- func (b *BotInlineMessageMediaVenue) String() string
- type BotInlineMessageText
- func (b *BotInlineMessageText) Decode(buf *bin.Buffer) error
- func (b *BotInlineMessageText) Encode(buf *bin.Buffer) error
- func (b *BotInlineMessageText) GetEntities() (value []MessageEntityClass, ok bool)
- func (b *BotInlineMessageText) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (b *BotInlineMessageText) SetEntities(value []MessageEntityClass)
- func (b *BotInlineMessageText) SetNoWebpage(value bool)
- func (b *BotInlineMessageText) SetReplyMarkup(value ReplyMarkupClass)
- func (b *BotInlineMessageText) String() string
- type BotInlineQueryHandler
- type BotInlineResult
- func (b *BotInlineResult) Decode(buf *bin.Buffer) error
- func (b *BotInlineResult) Encode(buf *bin.Buffer) error
- func (b *BotInlineResult) GetContent() (value WebDocumentClass, ok bool)
- func (b *BotInlineResult) GetDescription() (value string, ok bool)
- func (b *BotInlineResult) GetThumb() (value WebDocumentClass, ok bool)
- func (b *BotInlineResult) GetTitle() (value string, ok bool)
- func (b *BotInlineResult) GetURL() (value string, ok bool)
- func (b *BotInlineResult) SetContent(value WebDocumentClass)
- func (b *BotInlineResult) SetDescription(value string)
- func (b *BotInlineResult) SetThumb(value WebDocumentClass)
- func (b *BotInlineResult) SetTitle(value string)
- func (b *BotInlineResult) SetURL(value string)
- func (b *BotInlineResult) String() string
- type BotInlineResultBox
- type BotInlineResultClass
- type BotInlineSendHandler
- type BotPrecheckoutQueryHandler
- type BotShippingQueryHandler
- type BotWebhookJSONHandler
- type BotWebhookJSONQueryHandler
- type BotsAnswerWebhookJSONQueryRequest
- type BotsSendCustomRequestRequest
- type BotsSetBotCommandsRequest
- type CdnConfig
- type CdnPublicKey
- type Channel
- func (c *Channel) Decode(b *bin.Buffer) error
- func (c *Channel) Encode(b *bin.Buffer) error
- func (c *Channel) GetAccessHash() (value int64, ok bool)
- func (c *Channel) GetAdminRights() (value ChatAdminRights, ok bool)
- func (c *Channel) GetBannedRights() (value ChatBannedRights, ok bool)
- func (c *Channel) GetDefaultBannedRights() (value ChatBannedRights, ok bool)
- func (c *Channel) GetParticipantsCount() (value int, ok bool)
- func (c *Channel) GetRestrictionReason() (value []RestrictionReason, ok bool)
- func (c *Channel) GetUsername() (value string, ok bool)
- func (c *Channel) SetAccessHash(value int64)
- func (c *Channel) SetAdminRights(value ChatAdminRights)
- func (c *Channel) SetBannedRights(value ChatBannedRights)
- func (c *Channel) SetBroadcast(value bool)
- func (c *Channel) SetCallActive(value bool)
- func (c *Channel) SetCallNotEmpty(value bool)
- func (c *Channel) SetCreator(value bool)
- func (c *Channel) SetDefaultBannedRights(value ChatBannedRights)
- func (c *Channel) SetHasGeo(value bool)
- func (c *Channel) SetHasLink(value bool)
- func (c *Channel) SetLeft(value bool)
- func (c *Channel) SetMegagroup(value bool)
- func (c *Channel) SetMin(value bool)
- func (c *Channel) SetParticipantsCount(value int)
- func (c *Channel) SetRestricted(value bool)
- func (c *Channel) SetRestrictionReason(value []RestrictionReason)
- func (c *Channel) SetScam(value bool)
- func (c *Channel) SetSignatures(value bool)
- func (c *Channel) SetSlowmodeEnabled(value bool)
- func (c *Channel) SetUsername(value string)
- func (c *Channel) SetVerified(value bool)
- func (c *Channel) String() string
- type ChannelAdminLogEvent
- type ChannelAdminLogEventActionBox
- type ChannelAdminLogEventActionChangeAbout
- type ChannelAdminLogEventActionChangeLinkedChat
- type ChannelAdminLogEventActionChangeLocation
- type ChannelAdminLogEventActionChangePhoto
- type ChannelAdminLogEventActionChangeStickerSet
- type ChannelAdminLogEventActionChangeTitle
- type ChannelAdminLogEventActionChangeUsername
- type ChannelAdminLogEventActionClass
- type ChannelAdminLogEventActionDefaultBannedRights
- type ChannelAdminLogEventActionDeleteMessage
- type ChannelAdminLogEventActionDiscardGroupCall
- type ChannelAdminLogEventActionEditMessage
- type ChannelAdminLogEventActionParticipantInvite
- type ChannelAdminLogEventActionParticipantJoin
- type ChannelAdminLogEventActionParticipantLeave
- type ChannelAdminLogEventActionParticipantMute
- type ChannelAdminLogEventActionParticipantToggleAdmin
- type ChannelAdminLogEventActionParticipantToggleBan
- type ChannelAdminLogEventActionParticipantUnmute
- type ChannelAdminLogEventActionStartGroupCall
- type ChannelAdminLogEventActionStopPoll
- type ChannelAdminLogEventActionToggleGroupCallSetting
- type ChannelAdminLogEventActionToggleInvites
- type ChannelAdminLogEventActionTogglePreHistoryHidden
- type ChannelAdminLogEventActionToggleSignatures
- type ChannelAdminLogEventActionToggleSlowMode
- type ChannelAdminLogEventActionUpdatePinned
- type ChannelAdminLogEventsFilter
- func (c *ChannelAdminLogEventsFilter) Decode(b *bin.Buffer) error
- func (c *ChannelAdminLogEventsFilter) Encode(b *bin.Buffer) error
- func (c *ChannelAdminLogEventsFilter) SetBan(value bool)
- func (c *ChannelAdminLogEventsFilter) SetDelete(value bool)
- func (c *ChannelAdminLogEventsFilter) SetDemote(value bool)
- func (c *ChannelAdminLogEventsFilter) SetEdit(value bool)
- func (c *ChannelAdminLogEventsFilter) SetGroupCall(value bool)
- func (c *ChannelAdminLogEventsFilter) SetInfo(value bool)
- func (c *ChannelAdminLogEventsFilter) SetInvite(value bool)
- func (c *ChannelAdminLogEventsFilter) SetJoin(value bool)
- func (c *ChannelAdminLogEventsFilter) SetKick(value bool)
- func (c *ChannelAdminLogEventsFilter) SetLeave(value bool)
- func (c *ChannelAdminLogEventsFilter) SetPinned(value bool)
- func (c *ChannelAdminLogEventsFilter) SetPromote(value bool)
- func (c *ChannelAdminLogEventsFilter) SetSettings(value bool)
- func (c *ChannelAdminLogEventsFilter) SetUnban(value bool)
- func (c *ChannelAdminLogEventsFilter) SetUnkick(value bool)
- func (c *ChannelAdminLogEventsFilter) String() string
- type ChannelAvailableMessagesHandler
- type ChannelForbidden
- func (c *ChannelForbidden) Decode(b *bin.Buffer) error
- func (c *ChannelForbidden) Encode(b *bin.Buffer) error
- func (c *ChannelForbidden) GetUntilDate() (value int, ok bool)
- func (c *ChannelForbidden) SetBroadcast(value bool)
- func (c *ChannelForbidden) SetMegagroup(value bool)
- func (c *ChannelForbidden) SetUntilDate(value int)
- func (c *ChannelForbidden) String() string
- type ChannelFull
- func (c *ChannelFull) Decode(b *bin.Buffer) error
- func (c *ChannelFull) Encode(b *bin.Buffer) error
- func (c *ChannelFull) GetAdminsCount() (value int, ok bool)
- func (c *ChannelFull) GetAvailableMinID() (value int, ok bool)
- func (c *ChannelFull) GetBannedCount() (value int, ok bool)
- func (c *ChannelFull) GetCall() (value InputGroupCall, ok bool)
- func (c *ChannelFull) GetFolderID() (value int, ok bool)
- func (c *ChannelFull) GetKickedCount() (value int, ok bool)
- func (c *ChannelFull) GetLinkedChatID() (value int, ok bool)
- func (c *ChannelFull) GetLocation() (value ChannelLocationClass, ok bool)
- func (c *ChannelFull) GetMigratedFromChatID() (value int, ok bool)
- func (c *ChannelFull) GetMigratedFromMaxID() (value int, ok bool)
- func (c *ChannelFull) GetOnlineCount() (value int, ok bool)
- func (c *ChannelFull) GetParticipantsCount() (value int, ok bool)
- func (c *ChannelFull) GetPinnedMsgID() (value int, ok bool)
- func (c *ChannelFull) GetSlowmodeNextSendDate() (value int, ok bool)
- func (c *ChannelFull) GetSlowmodeSeconds() (value int, ok bool)
- func (c *ChannelFull) GetStatsDC() (value int, ok bool)
- func (c *ChannelFull) GetStickerset() (value StickerSet, ok bool)
- func (c *ChannelFull) SetAdminsCount(value int)
- func (c *ChannelFull) SetAvailableMinID(value int)
- func (c *ChannelFull) SetBannedCount(value int)
- func (c *ChannelFull) SetBlocked(value bool)
- func (c *ChannelFull) SetCall(value InputGroupCall)
- func (c *ChannelFull) SetCanSetLocation(value bool)
- func (c *ChannelFull) SetCanSetStickers(value bool)
- func (c *ChannelFull) SetCanSetUsername(value bool)
- func (c *ChannelFull) SetCanViewParticipants(value bool)
- func (c *ChannelFull) SetCanViewStats(value bool)
- func (c *ChannelFull) SetFolderID(value int)
- func (c *ChannelFull) SetHasScheduled(value bool)
- func (c *ChannelFull) SetHiddenPrehistory(value bool)
- func (c *ChannelFull) SetKickedCount(value int)
- func (c *ChannelFull) SetLinkedChatID(value int)
- func (c *ChannelFull) SetLocation(value ChannelLocationClass)
- func (c *ChannelFull) SetMigratedFromChatID(value int)
- func (c *ChannelFull) SetMigratedFromMaxID(value int)
- func (c *ChannelFull) SetOnlineCount(value int)
- func (c *ChannelFull) SetParticipantsCount(value int)
- func (c *ChannelFull) SetPinnedMsgID(value int)
- func (c *ChannelFull) SetSlowmodeNextSendDate(value int)
- func (c *ChannelFull) SetSlowmodeSeconds(value int)
- func (c *ChannelFull) SetStatsDC(value int)
- func (c *ChannelFull) SetStickerset(value StickerSet)
- func (c *ChannelFull) String() string
- type ChannelHandler
- type ChannelLocation
- type ChannelLocationBox
- type ChannelLocationClass
- type ChannelLocationEmpty
- type ChannelMessageForwardsHandler
- type ChannelMessageViewsHandler
- type ChannelMessagesFilter
- type ChannelMessagesFilterBox
- type ChannelMessagesFilterClass
- type ChannelMessagesFilterEmpty
- type ChannelParticipant
- type ChannelParticipantAdmin
- func (c *ChannelParticipantAdmin) Decode(b *bin.Buffer) error
- func (c *ChannelParticipantAdmin) Encode(b *bin.Buffer) error
- func (c *ChannelParticipantAdmin) GetInviterID() (value int, ok bool)
- func (c *ChannelParticipantAdmin) GetRank() (value string, ok bool)
- func (c *ChannelParticipantAdmin) SetCanEdit(value bool)
- func (c *ChannelParticipantAdmin) SetInviterID(value int)
- func (c *ChannelParticipantAdmin) SetRank(value string)
- func (c *ChannelParticipantAdmin) SetSelf(value bool)
- func (c *ChannelParticipantAdmin) String() string
- type ChannelParticipantBanned
- type ChannelParticipantBox
- type ChannelParticipantClass
- type ChannelParticipantCreator
- func (c *ChannelParticipantCreator) Decode(b *bin.Buffer) error
- func (c *ChannelParticipantCreator) Encode(b *bin.Buffer) error
- func (c *ChannelParticipantCreator) GetRank() (value string, ok bool)
- func (c *ChannelParticipantCreator) SetRank(value string)
- func (c *ChannelParticipantCreator) String() string
- type ChannelParticipantHandler
- type ChannelParticipantLeft
- type ChannelParticipantSelf
- type ChannelParticipantsAdmins
- type ChannelParticipantsBanned
- type ChannelParticipantsBots
- type ChannelParticipantsContacts
- type ChannelParticipantsFilterBox
- type ChannelParticipantsFilterClass
- type ChannelParticipantsKicked
- type ChannelParticipantsMentions
- func (c *ChannelParticipantsMentions) Decode(b *bin.Buffer) error
- func (c *ChannelParticipantsMentions) Encode(b *bin.Buffer) error
- func (c *ChannelParticipantsMentions) GetQ() (value string, ok bool)
- func (c *ChannelParticipantsMentions) GetTopMsgID() (value int, ok bool)
- func (c *ChannelParticipantsMentions) SetQ(value string)
- func (c *ChannelParticipantsMentions) SetTopMsgID(value int)
- func (c *ChannelParticipantsMentions) String() string
- type ChannelParticipantsRecent
- type ChannelParticipantsSearch
- type ChannelReadMessagesContentsHandler
- type ChannelTooLongHandler
- type ChannelUserTypingHandler
- type ChannelWebPageHandler
- type ChannelsAdminLogResults
- type ChannelsChannelParticipant
- type ChannelsChannelParticipants
- type ChannelsChannelParticipantsBox
- type ChannelsChannelParticipantsClass
- type ChannelsChannelParticipantsNotModified
- type ChannelsCheckUsernameRequest
- type ChannelsCreateChannelRequest
- func (c *ChannelsCreateChannelRequest) Decode(b *bin.Buffer) error
- func (c *ChannelsCreateChannelRequest) Encode(b *bin.Buffer) error
- func (c *ChannelsCreateChannelRequest) GetAddress() (value string, ok bool)
- func (c *ChannelsCreateChannelRequest) GetGeoPoint() (value InputGeoPointClass, ok bool)
- func (c *ChannelsCreateChannelRequest) SetAddress(value string)
- func (c *ChannelsCreateChannelRequest) SetBroadcast(value bool)
- func (c *ChannelsCreateChannelRequest) SetGeoPoint(value InputGeoPointClass)
- func (c *ChannelsCreateChannelRequest) SetMegagroup(value bool)
- func (c *ChannelsCreateChannelRequest) String() string
- type ChannelsDeleteChannelRequest
- type ChannelsDeleteHistoryRequest
- type ChannelsDeleteMessagesRequest
- type ChannelsDeleteUserHistoryRequest
- type ChannelsEditAdminRequest
- type ChannelsEditBannedRequest
- type ChannelsEditCreatorRequest
- type ChannelsEditLocationRequest
- type ChannelsEditPhotoRequest
- type ChannelsEditTitleRequest
- type ChannelsExportMessageLinkRequest
- func (e *ChannelsExportMessageLinkRequest) Decode(b *bin.Buffer) error
- func (e *ChannelsExportMessageLinkRequest) Encode(b *bin.Buffer) error
- func (e *ChannelsExportMessageLinkRequest) SetGrouped(value bool)
- func (e *ChannelsExportMessageLinkRequest) SetThread(value bool)
- func (e *ChannelsExportMessageLinkRequest) String() string
- type ChannelsGetAdminLogRequest
- func (g *ChannelsGetAdminLogRequest) Decode(b *bin.Buffer) error
- func (g *ChannelsGetAdminLogRequest) Encode(b *bin.Buffer) error
- func (g *ChannelsGetAdminLogRequest) GetAdmins() (value []InputUserClass, ok bool)
- func (g *ChannelsGetAdminLogRequest) GetEventsFilter() (value ChannelAdminLogEventsFilter, ok bool)
- func (g *ChannelsGetAdminLogRequest) SetAdmins(value []InputUserClass)
- func (g *ChannelsGetAdminLogRequest) SetEventsFilter(value ChannelAdminLogEventsFilter)
- func (g *ChannelsGetAdminLogRequest) String() string
- type ChannelsGetAdminedPublicChannelsRequest
- func (g *ChannelsGetAdminedPublicChannelsRequest) Decode(b *bin.Buffer) error
- func (g *ChannelsGetAdminedPublicChannelsRequest) Encode(b *bin.Buffer) error
- func (g *ChannelsGetAdminedPublicChannelsRequest) SetByLocation(value bool)
- func (g *ChannelsGetAdminedPublicChannelsRequest) SetCheckLimit(value bool)
- func (g *ChannelsGetAdminedPublicChannelsRequest) String() string
- type ChannelsGetChannelsRequest
- type ChannelsGetFullChannelRequest
- type ChannelsGetGroupsForDiscussionRequest
- type ChannelsGetInactiveChannelsRequest
- type ChannelsGetLeftChannelsRequest
- type ChannelsGetMessagesRequest
- type ChannelsGetParticipantRequest
- type ChannelsGetParticipantsRequest
- type ChannelsInviteToChannelRequest
- type ChannelsJoinChannelRequest
- type ChannelsLeaveChannelRequest
- type ChannelsReadHistoryRequest
- type ChannelsReadMessageContentsRequest
- type ChannelsReportSpamRequest
- type ChannelsSetDiscussionGroupRequest
- type ChannelsSetStickersRequest
- type ChannelsTogglePreHistoryHiddenRequest
- type ChannelsToggleSignaturesRequest
- type ChannelsToggleSlowModeRequest
- type ChannelsUpdateUsernameRequest
- type Chat
- func (c *Chat) Decode(b *bin.Buffer) error
- func (c *Chat) Encode(b *bin.Buffer) error
- func (c *Chat) GetAdminRights() (value ChatAdminRights, ok bool)
- func (c *Chat) GetDefaultBannedRights() (value ChatBannedRights, ok bool)
- func (c *Chat) GetMigratedTo() (value InputChannelClass, ok bool)
- func (c *Chat) SetAdminRights(value ChatAdminRights)
- func (c *Chat) SetCallActive(value bool)
- func (c *Chat) SetCallNotEmpty(value bool)
- func (c *Chat) SetCreator(value bool)
- func (c *Chat) SetDeactivated(value bool)
- func (c *Chat) SetDefaultBannedRights(value ChatBannedRights)
- func (c *Chat) SetKicked(value bool)
- func (c *Chat) SetLeft(value bool)
- func (c *Chat) SetMigratedTo(value InputChannelClass)
- func (c *Chat) String() string
- type ChatAdminRights
- func (c *ChatAdminRights) Decode(b *bin.Buffer) error
- func (c *ChatAdminRights) Encode(b *bin.Buffer) error
- func (c *ChatAdminRights) SetAddAdmins(value bool)
- func (c *ChatAdminRights) SetAnonymous(value bool)
- func (c *ChatAdminRights) SetBanUsers(value bool)
- func (c *ChatAdminRights) SetChangeInfo(value bool)
- func (c *ChatAdminRights) SetDeleteMessages(value bool)
- func (c *ChatAdminRights) SetEditMessages(value bool)
- func (c *ChatAdminRights) SetInviteUsers(value bool)
- func (c *ChatAdminRights) SetManageCall(value bool)
- func (c *ChatAdminRights) SetPinMessages(value bool)
- func (c *ChatAdminRights) SetPostMessages(value bool)
- func (c *ChatAdminRights) String() string
- type ChatBannedRights
- func (c *ChatBannedRights) Decode(b *bin.Buffer) error
- func (c *ChatBannedRights) Encode(b *bin.Buffer) error
- func (c *ChatBannedRights) SetChangeInfo(value bool)
- func (c *ChatBannedRights) SetEmbedLinks(value bool)
- func (c *ChatBannedRights) SetInviteUsers(value bool)
- func (c *ChatBannedRights) SetPinMessages(value bool)
- func (c *ChatBannedRights) SetSendGames(value bool)
- func (c *ChatBannedRights) SetSendGifs(value bool)
- func (c *ChatBannedRights) SetSendInline(value bool)
- func (c *ChatBannedRights) SetSendMedia(value bool)
- func (c *ChatBannedRights) SetSendMessages(value bool)
- func (c *ChatBannedRights) SetSendPolls(value bool)
- func (c *ChatBannedRights) SetSendStickers(value bool)
- func (c *ChatBannedRights) SetViewMessages(value bool)
- func (c *ChatBannedRights) String() string
- type ChatBox
- type ChatClass
- type ChatDefaultBannedRightsHandler
- type ChatEmpty
- type ChatForbidden
- type ChatFull
- func (c *ChatFull) Decode(b *bin.Buffer) error
- func (c *ChatFull) Encode(b *bin.Buffer) error
- func (c *ChatFull) GetBotInfo() (value []BotInfo, ok bool)
- func (c *ChatFull) GetCall() (value InputGroupCall, ok bool)
- func (c *ChatFull) GetChatPhoto() (value PhotoClass, ok bool)
- func (c *ChatFull) GetFolderID() (value int, ok bool)
- func (c *ChatFull) GetPinnedMsgID() (value int, ok bool)
- func (c *ChatFull) SetBotInfo(value []BotInfo)
- func (c *ChatFull) SetCall(value InputGroupCall)
- func (c *ChatFull) SetCanSetUsername(value bool)
- func (c *ChatFull) SetChatPhoto(value PhotoClass)
- func (c *ChatFull) SetFolderID(value int)
- func (c *ChatFull) SetHasScheduled(value bool)
- func (c *ChatFull) SetPinnedMsgID(value int)
- func (c *ChatFull) String() string
- type ChatFullBox
- type ChatFullClass
- type ChatHandler
- type ChatInvite
- func (c *ChatInvite) Decode(b *bin.Buffer) error
- func (c *ChatInvite) Encode(b *bin.Buffer) error
- func (c *ChatInvite) GetParticipants() (value []UserClass, ok bool)
- func (c *ChatInvite) SetBroadcast(value bool)
- func (c *ChatInvite) SetChannel(value bool)
- func (c *ChatInvite) SetMegagroup(value bool)
- func (c *ChatInvite) SetParticipants(value []UserClass)
- func (c *ChatInvite) SetPublic(value bool)
- func (c *ChatInvite) String() string
- type ChatInviteAlready
- type ChatInviteBox
- type ChatInviteClass
- type ChatInviteEmpty
- type ChatInviteExported
- type ChatInvitePeek
- type ChatOnlines
- type ChatParticipant
- type ChatParticipantAddHandler
- type ChatParticipantAdmin
- type ChatParticipantAdminHandler
- type ChatParticipantBox
- type ChatParticipantClass
- type ChatParticipantCreator
- type ChatParticipantDeleteHandler
- type ChatParticipants
- type ChatParticipantsBox
- type ChatParticipantsClass
- type ChatParticipantsForbidden
- func (c *ChatParticipantsForbidden) Decode(b *bin.Buffer) error
- func (c *ChatParticipantsForbidden) Encode(b *bin.Buffer) error
- func (c *ChatParticipantsForbidden) GetSelfParticipant() (value ChatParticipantClass, ok bool)
- func (c *ChatParticipantsForbidden) SetSelfParticipant(value ChatParticipantClass)
- func (c *ChatParticipantsForbidden) String() string
- type ChatParticipantsHandler
- type ChatPhoto
- type ChatPhotoBox
- type ChatPhotoClass
- type ChatPhotoEmpty
- type ChatUserTypingHandler
- type Client
- func (c *Client) AccountAcceptAuthorization(ctx context.Context, request *AccountAcceptAuthorizationRequest) (bool, error)
- func (c *Client) AccountCancelPasswordEmail(ctx context.Context) (bool, error)
- func (c *Client) AccountChangePhone(ctx context.Context, request *AccountChangePhoneRequest) (UserClass, error)
- func (c *Client) AccountCheckUsername(ctx context.Context, username string) (bool, error)
- func (c *Client) AccountConfirmPasswordEmail(ctx context.Context, code string) (bool, error)
- func (c *Client) AccountConfirmPhone(ctx context.Context, request *AccountConfirmPhoneRequest) (bool, error)
- func (c *Client) AccountCreateTheme(ctx context.Context, request *AccountCreateThemeRequest) (*Theme, error)
- func (c *Client) AccountDeleteAccount(ctx context.Context, reason string) (bool, error)
- func (c *Client) AccountDeleteSecureValue(ctx context.Context, types []SecureValueTypeClass) (bool, error)
- func (c *Client) AccountFinishTakeoutSession(ctx context.Context, request *AccountFinishTakeoutSessionRequest) (bool, error)
- func (c *Client) AccountGetAccountTTL(ctx context.Context) (*AccountDaysTTL, error)
- func (c *Client) AccountGetAllSecureValues(ctx context.Context) ([]SecureValue, error)
- func (c *Client) AccountGetAuthorizationForm(ctx context.Context, request *AccountGetAuthorizationFormRequest) (*AccountAuthorizationForm, error)
- func (c *Client) AccountGetAuthorizations(ctx context.Context) (*AccountAuthorizations, error)
- func (c *Client) AccountGetAutoDownloadSettings(ctx context.Context) (*AccountAutoDownloadSettings, error)
- func (c *Client) AccountGetContactSignUpNotification(ctx context.Context) (bool, error)
- func (c *Client) AccountGetContentSettings(ctx context.Context) (*AccountContentSettings, error)
- func (c *Client) AccountGetGlobalPrivacySettings(ctx context.Context) (*GlobalPrivacySettings, error)
- func (c *Client) AccountGetMultiWallPapers(ctx context.Context, wallpapers []InputWallPaperClass) ([]WallPaperClass, error)
- func (c *Client) AccountGetNotifyExceptions(ctx context.Context, request *AccountGetNotifyExceptionsRequest) (UpdatesClass, error)
- func (c *Client) AccountGetNotifySettings(ctx context.Context, peer InputNotifyPeerClass) (*PeerNotifySettings, error)
- func (c *Client) AccountGetPassword(ctx context.Context) (*AccountPassword, error)
- func (c *Client) AccountGetPasswordSettings(ctx context.Context, password InputCheckPasswordSRPClass) (*AccountPasswordSettings, error)
- func (c *Client) AccountGetPrivacy(ctx context.Context, key InputPrivacyKeyClass) (*AccountPrivacyRules, error)
- func (c *Client) AccountGetSecureValue(ctx context.Context, types []SecureValueTypeClass) ([]SecureValue, error)
- func (c *Client) AccountGetTheme(ctx context.Context, request *AccountGetThemeRequest) (*Theme, error)
- func (c *Client) AccountGetThemes(ctx context.Context, request *AccountGetThemesRequest) (AccountThemesClass, error)
- func (c *Client) AccountGetTmpPassword(ctx context.Context, request *AccountGetTmpPasswordRequest) (*AccountTmpPassword, error)
- func (c *Client) AccountGetWallPaper(ctx context.Context, wallpaper InputWallPaperClass) (WallPaperClass, error)
- func (c *Client) AccountGetWallPapers(ctx context.Context, hash int) (AccountWallPapersClass, error)
- func (c *Client) AccountGetWebAuthorizations(ctx context.Context) (*AccountWebAuthorizations, error)
- func (c *Client) AccountInitTakeoutSession(ctx context.Context, request *AccountInitTakeoutSessionRequest) (*AccountTakeout, error)
- func (c *Client) AccountInstallTheme(ctx context.Context, request *AccountInstallThemeRequest) (bool, error)
- func (c *Client) AccountInstallWallPaper(ctx context.Context, request *AccountInstallWallPaperRequest) (bool, error)
- func (c *Client) AccountRegisterDevice(ctx context.Context, request *AccountRegisterDeviceRequest) (bool, error)
- func (c *Client) AccountReportPeer(ctx context.Context, request *AccountReportPeerRequest) (bool, error)
- func (c *Client) AccountResendPasswordEmail(ctx context.Context) (bool, error)
- func (c *Client) AccountResetAuthorization(ctx context.Context, hash int64) (bool, error)
- func (c *Client) AccountResetNotifySettings(ctx context.Context) (bool, error)
- func (c *Client) AccountResetWallPapers(ctx context.Context) (bool, error)
- func (c *Client) AccountResetWebAuthorization(ctx context.Context, hash int64) (bool, error)
- func (c *Client) AccountResetWebAuthorizations(ctx context.Context) (bool, error)
- func (c *Client) AccountSaveAutoDownloadSettings(ctx context.Context, request *AccountSaveAutoDownloadSettingsRequest) (bool, error)
- func (c *Client) AccountSaveSecureValue(ctx context.Context, request *AccountSaveSecureValueRequest) (*SecureValue, error)
- func (c *Client) AccountSaveTheme(ctx context.Context, request *AccountSaveThemeRequest) (bool, error)
- func (c *Client) AccountSaveWallPaper(ctx context.Context, request *AccountSaveWallPaperRequest) (bool, error)
- func (c *Client) AccountSendChangePhoneCode(ctx context.Context, request *AccountSendChangePhoneCodeRequest) (*AuthSentCode, error)
- func (c *Client) AccountSendConfirmPhoneCode(ctx context.Context, request *AccountSendConfirmPhoneCodeRequest) (*AuthSentCode, error)
- func (c *Client) AccountSendVerifyEmailCode(ctx context.Context, email string) (*AccountSentEmailCode, error)
- func (c *Client) AccountSendVerifyPhoneCode(ctx context.Context, request *AccountSendVerifyPhoneCodeRequest) (*AuthSentCode, error)
- func (c *Client) AccountSetAccountTTL(ctx context.Context, ttl AccountDaysTTL) (bool, error)
- func (c *Client) AccountSetContactSignUpNotification(ctx context.Context, silent bool) (bool, error)
- func (c *Client) AccountSetContentSettings(ctx context.Context, request *AccountSetContentSettingsRequest) (bool, error)
- func (c *Client) AccountSetGlobalPrivacySettings(ctx context.Context, settings GlobalPrivacySettings) (*GlobalPrivacySettings, error)
- func (c *Client) AccountSetPrivacy(ctx context.Context, request *AccountSetPrivacyRequest) (*AccountPrivacyRules, error)
- func (c *Client) AccountUnregisterDevice(ctx context.Context, request *AccountUnregisterDeviceRequest) (bool, error)
- func (c *Client) AccountUpdateDeviceLocked(ctx context.Context, period int) (bool, error)
- func (c *Client) AccountUpdateNotifySettings(ctx context.Context, request *AccountUpdateNotifySettingsRequest) (bool, error)
- func (c *Client) AccountUpdatePasswordSettings(ctx context.Context, request *AccountUpdatePasswordSettingsRequest) (bool, error)
- func (c *Client) AccountUpdateProfile(ctx context.Context, request *AccountUpdateProfileRequest) (UserClass, error)
- func (c *Client) AccountUpdateStatus(ctx context.Context, offline bool) (bool, error)
- func (c *Client) AccountUpdateTheme(ctx context.Context, request *AccountUpdateThemeRequest) (*Theme, error)
- func (c *Client) AccountUpdateUsername(ctx context.Context, username string) (UserClass, error)
- func (c *Client) AccountUploadTheme(ctx context.Context, request *AccountUploadThemeRequest) (DocumentClass, error)
- func (c *Client) AccountUploadWallPaper(ctx context.Context, request *AccountUploadWallPaperRequest) (WallPaperClass, error)
- func (c *Client) AccountVerifyEmail(ctx context.Context, request *AccountVerifyEmailRequest) (bool, error)
- func (c *Client) AccountVerifyPhone(ctx context.Context, request *AccountVerifyPhoneRequest) (bool, error)
- func (c *Client) AuthAcceptLoginToken(ctx context.Context, token []byte) (*Authorization, error)
- func (c *Client) AuthBindTempAuthKey(ctx context.Context, request *AuthBindTempAuthKeyRequest) (bool, error)
- func (c *Client) AuthCancelCode(ctx context.Context, request *AuthCancelCodeRequest) (bool, error)
- func (c *Client) AuthCheckPassword(ctx context.Context, password InputCheckPasswordSRPClass) (AuthAuthorizationClass, error)
- func (c *Client) AuthDropTempAuthKeys(ctx context.Context, exceptauthkeys []int64) (bool, error)
- func (c *Client) AuthExportAuthorization(ctx context.Context, dcid int) (*AuthExportedAuthorization, error)
- func (c *Client) AuthExportLoginToken(ctx context.Context, request *AuthExportLoginTokenRequest) (AuthLoginTokenClass, error)
- func (c *Client) AuthImportAuthorization(ctx context.Context, request *AuthImportAuthorizationRequest) (AuthAuthorizationClass, error)
- func (c *Client) AuthImportBotAuthorization(ctx context.Context, request *AuthImportBotAuthorizationRequest) (AuthAuthorizationClass, error)
- func (c *Client) AuthImportLoginToken(ctx context.Context, token []byte) (AuthLoginTokenClass, error)
- func (c *Client) AuthLogOut(ctx context.Context) (bool, error)
- func (c *Client) AuthRecoverPassword(ctx context.Context, code string) (AuthAuthorizationClass, error)
- func (c *Client) AuthRequestPasswordRecovery(ctx context.Context) (*AuthPasswordRecovery, error)
- func (c *Client) AuthResendCode(ctx context.Context, request *AuthResendCodeRequest) (*AuthSentCode, error)
- func (c *Client) AuthResetAuthorizations(ctx context.Context) (bool, error)
- func (c *Client) AuthSendCode(ctx context.Context, request *AuthSendCodeRequest) (*AuthSentCode, error)
- func (c *Client) AuthSignIn(ctx context.Context, request *AuthSignInRequest) (AuthAuthorizationClass, error)
- func (c *Client) AuthSignUp(ctx context.Context, request *AuthSignUpRequest) (AuthAuthorizationClass, error)
- func (c *Client) BotsAnswerWebhookJSONQuery(ctx context.Context, request *BotsAnswerWebhookJSONQueryRequest) (bool, error)
- func (c *Client) BotsSendCustomRequest(ctx context.Context, request *BotsSendCustomRequestRequest) (*DataJSON, error)
- func (c *Client) BotsSetBotCommands(ctx context.Context, commands []BotCommand) (bool, error)
- func (c *Client) ChannelsCheckUsername(ctx context.Context, request *ChannelsCheckUsernameRequest) (bool, error)
- func (c *Client) ChannelsCreateChannel(ctx context.Context, request *ChannelsCreateChannelRequest) (UpdatesClass, error)
- func (c *Client) ChannelsDeleteChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
- func (c *Client) ChannelsDeleteHistory(ctx context.Context, request *ChannelsDeleteHistoryRequest) (bool, error)
- func (c *Client) ChannelsDeleteMessages(ctx context.Context, request *ChannelsDeleteMessagesRequest) (*MessagesAffectedMessages, error)
- func (c *Client) ChannelsDeleteUserHistory(ctx context.Context, request *ChannelsDeleteUserHistoryRequest) (*MessagesAffectedHistory, error)
- func (c *Client) ChannelsEditAdmin(ctx context.Context, request *ChannelsEditAdminRequest) (UpdatesClass, error)
- func (c *Client) ChannelsEditBanned(ctx context.Context, request *ChannelsEditBannedRequest) (UpdatesClass, error)
- func (c *Client) ChannelsEditCreator(ctx context.Context, request *ChannelsEditCreatorRequest) (UpdatesClass, error)
- func (c *Client) ChannelsEditLocation(ctx context.Context, request *ChannelsEditLocationRequest) (bool, error)
- func (c *Client) ChannelsEditPhoto(ctx context.Context, request *ChannelsEditPhotoRequest) (UpdatesClass, error)
- func (c *Client) ChannelsEditTitle(ctx context.Context, request *ChannelsEditTitleRequest) (UpdatesClass, error)
- func (c *Client) ChannelsExportMessageLink(ctx context.Context, request *ChannelsExportMessageLinkRequest) (*ExportedMessageLink, error)
- func (c *Client) ChannelsGetAdminLog(ctx context.Context, request *ChannelsGetAdminLogRequest) (*ChannelsAdminLogResults, error)
- func (c *Client) ChannelsGetAdminedPublicChannels(ctx context.Context, request *ChannelsGetAdminedPublicChannelsRequest) (MessagesChatsClass, error)
- func (c *Client) ChannelsGetChannels(ctx context.Context, id []InputChannelClass) (MessagesChatsClass, error)
- func (c *Client) ChannelsGetFullChannel(ctx context.Context, channel InputChannelClass) (*MessagesChatFull, error)
- func (c *Client) ChannelsGetGroupsForDiscussion(ctx context.Context) (MessagesChatsClass, error)
- func (c *Client) ChannelsGetInactiveChannels(ctx context.Context) (*MessagesInactiveChats, error)
- func (c *Client) ChannelsGetLeftChannels(ctx context.Context, offset int) (MessagesChatsClass, error)
- func (c *Client) ChannelsGetMessages(ctx context.Context, request *ChannelsGetMessagesRequest) (MessagesMessagesClass, error)
- func (c *Client) ChannelsGetParticipant(ctx context.Context, request *ChannelsGetParticipantRequest) (*ChannelsChannelParticipant, error)
- func (c *Client) ChannelsGetParticipants(ctx context.Context, request *ChannelsGetParticipantsRequest) (ChannelsChannelParticipantsClass, error)
- func (c *Client) ChannelsInviteToChannel(ctx context.Context, request *ChannelsInviteToChannelRequest) (UpdatesClass, error)
- func (c *Client) ChannelsJoinChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
- func (c *Client) ChannelsLeaveChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
- func (c *Client) ChannelsReadHistory(ctx context.Context, request *ChannelsReadHistoryRequest) (bool, error)
- func (c *Client) ChannelsReadMessageContents(ctx context.Context, request *ChannelsReadMessageContentsRequest) (bool, error)
- func (c *Client) ChannelsReportSpam(ctx context.Context, request *ChannelsReportSpamRequest) (bool, error)
- func (c *Client) ChannelsSetDiscussionGroup(ctx context.Context, request *ChannelsSetDiscussionGroupRequest) (bool, error)
- func (c *Client) ChannelsSetStickers(ctx context.Context, request *ChannelsSetStickersRequest) (bool, error)
- func (c *Client) ChannelsTogglePreHistoryHidden(ctx context.Context, request *ChannelsTogglePreHistoryHiddenRequest) (UpdatesClass, error)
- func (c *Client) ChannelsToggleSignatures(ctx context.Context, request *ChannelsToggleSignaturesRequest) (UpdatesClass, error)
- func (c *Client) ChannelsToggleSlowMode(ctx context.Context, request *ChannelsToggleSlowModeRequest) (UpdatesClass, error)
- func (c *Client) ChannelsUpdateUsername(ctx context.Context, request *ChannelsUpdateUsernameRequest) (bool, error)
- func (c *Client) ContactsAcceptContact(ctx context.Context, id InputUserClass) (UpdatesClass, error)
- func (c *Client) ContactsAddContact(ctx context.Context, request *ContactsAddContactRequest) (UpdatesClass, error)
- func (c *Client) ContactsBlock(ctx context.Context, id InputPeerClass) (bool, error)
- func (c *Client) ContactsBlockFromReplies(ctx context.Context, request *ContactsBlockFromRepliesRequest) (UpdatesClass, error)
- func (c *Client) ContactsDeleteByPhones(ctx context.Context, phones []string) (bool, error)
- func (c *Client) ContactsDeleteContacts(ctx context.Context, id []InputUserClass) (UpdatesClass, error)
- func (c *Client) ContactsGetBlocked(ctx context.Context, request *ContactsGetBlockedRequest) (ContactsBlockedClass, error)
- func (c *Client) ContactsGetContactIDs(ctx context.Context, hash int) ([]int, error)
- func (c *Client) ContactsGetContacts(ctx context.Context, hash int) (ContactsContactsClass, error)
- func (c *Client) ContactsGetLocated(ctx context.Context, request *ContactsGetLocatedRequest) (UpdatesClass, error)
- func (c *Client) ContactsGetSaved(ctx context.Context) ([]SavedPhoneContact, error)
- func (c *Client) ContactsGetStatuses(ctx context.Context) ([]ContactStatus, error)
- func (c *Client) ContactsGetTopPeers(ctx context.Context, request *ContactsGetTopPeersRequest) (ContactsTopPeersClass, error)
- func (c *Client) ContactsImportContacts(ctx context.Context, contacts []InputPhoneContact) (*ContactsImportedContacts, error)
- func (c *Client) ContactsResetSaved(ctx context.Context) (bool, error)
- func (c *Client) ContactsResetTopPeerRating(ctx context.Context, request *ContactsResetTopPeerRatingRequest) (bool, error)
- func (c *Client) ContactsResolveUsername(ctx context.Context, username string) (*ContactsResolvedPeer, error)
- func (c *Client) ContactsSearch(ctx context.Context, request *ContactsSearchRequest) (*ContactsFound, error)
- func (c *Client) ContactsToggleTopPeers(ctx context.Context, enabled bool) (bool, error)
- func (c *Client) ContactsUnblock(ctx context.Context, id InputPeerClass) (bool, error)
- func (c *Client) FoldersDeleteFolder(ctx context.Context, folderid int) (UpdatesClass, error)
- func (c *Client) FoldersEditPeerFolders(ctx context.Context, folderpeers []InputFolderPeer) (UpdatesClass, error)
- func (c *Client) HelpAcceptTermsOfService(ctx context.Context, id DataJSON) (bool, error)
- func (c *Client) HelpDismissSuggestion(ctx context.Context, suggestion string) (bool, error)
- func (c *Client) HelpEditUserInfo(ctx context.Context, request *HelpEditUserInfoRequest) (HelpUserInfoClass, error)
- func (c *Client) HelpGetAppChangelog(ctx context.Context, prevappversion string) (UpdatesClass, error)
- func (c *Client) HelpGetAppConfig(ctx context.Context) (JSONValueClass, error)
- func (c *Client) HelpGetAppUpdate(ctx context.Context, source string) (HelpAppUpdateClass, error)
- func (c *Client) HelpGetCdnConfig(ctx context.Context) (*CdnConfig, error)
- func (c *Client) HelpGetConfig(ctx context.Context) (*Config, error)
- func (c *Client) HelpGetCountriesList(ctx context.Context, request *HelpGetCountriesListRequest) (HelpCountriesListClass, error)
- func (c *Client) HelpGetDeepLinkInfo(ctx context.Context, path string) (HelpDeepLinkInfoClass, error)
- func (c *Client) HelpGetInviteText(ctx context.Context) (*HelpInviteText, error)
- func (c *Client) HelpGetNearestDc(ctx context.Context) (*NearestDc, error)
- func (c *Client) HelpGetPassportConfig(ctx context.Context, hash int) (HelpPassportConfigClass, error)
- func (c *Client) HelpGetPromoData(ctx context.Context) (HelpPromoDataClass, error)
- func (c *Client) HelpGetRecentMeUrls(ctx context.Context, referer string) (*HelpRecentMeUrls, error)
- func (c *Client) HelpGetSupport(ctx context.Context) (*HelpSupport, error)
- func (c *Client) HelpGetSupportName(ctx context.Context) (*HelpSupportName, error)
- func (c *Client) HelpGetTermsOfServiceUpdate(ctx context.Context) (HelpTermsOfServiceUpdateClass, error)
- func (c *Client) HelpGetUserInfo(ctx context.Context, userid InputUserClass) (HelpUserInfoClass, error)
- func (c *Client) HelpHidePromoData(ctx context.Context, peer InputPeerClass) (bool, error)
- func (c *Client) HelpSaveAppLog(ctx context.Context, events []InputAppEvent) (bool, error)
- func (c *Client) HelpSetBotUpdatesStatus(ctx context.Context, request *HelpSetBotUpdatesStatusRequest) (bool, error)
- func (c *Client) LangpackGetDifference(ctx context.Context, request *LangpackGetDifferenceRequest) (*LangPackDifference, error)
- func (c *Client) LangpackGetLangPack(ctx context.Context, request *LangpackGetLangPackRequest) (*LangPackDifference, error)
- func (c *Client) LangpackGetLanguage(ctx context.Context, request *LangpackGetLanguageRequest) (*LangPackLanguage, error)
- func (c *Client) LangpackGetLanguages(ctx context.Context, langpack string) ([]LangPackLanguage, error)
- func (c *Client) LangpackGetStrings(ctx context.Context, request *LangpackGetStringsRequest) ([]LangPackStringClass, error)
- func (c *Client) MessagesAcceptEncryption(ctx context.Context, request *MessagesAcceptEncryptionRequest) (EncryptedChatClass, error)
- func (c *Client) MessagesAcceptUrlAuth(ctx context.Context, request *MessagesAcceptUrlAuthRequest) (UrlAuthResultClass, error)
- func (c *Client) MessagesAddChatUser(ctx context.Context, request *MessagesAddChatUserRequest) (UpdatesClass, error)
- func (c *Client) MessagesCheckChatInvite(ctx context.Context, hash string) (ChatInviteClass, error)
- func (c *Client) MessagesClearAllDrafts(ctx context.Context) (bool, error)
- func (c *Client) MessagesClearRecentStickers(ctx context.Context, request *MessagesClearRecentStickersRequest) (bool, error)
- func (c *Client) MessagesCreateChat(ctx context.Context, request *MessagesCreateChatRequest) (UpdatesClass, error)
- func (c *Client) MessagesDeleteChatUser(ctx context.Context, request *MessagesDeleteChatUserRequest) (UpdatesClass, error)
- func (c *Client) MessagesDeleteHistory(ctx context.Context, request *MessagesDeleteHistoryRequest) (*MessagesAffectedHistory, error)
- func (c *Client) MessagesDeleteMessages(ctx context.Context, request *MessagesDeleteMessagesRequest) (*MessagesAffectedMessages, error)
- func (c *Client) MessagesDeleteScheduledMessages(ctx context.Context, request *MessagesDeleteScheduledMessagesRequest) (UpdatesClass, error)
- func (c *Client) MessagesDiscardEncryption(ctx context.Context, chatid int) (bool, error)
- func (c *Client) MessagesEditChatAbout(ctx context.Context, request *MessagesEditChatAboutRequest) (bool, error)
- func (c *Client) MessagesEditChatAdmin(ctx context.Context, request *MessagesEditChatAdminRequest) (bool, error)
- func (c *Client) MessagesEditChatDefaultBannedRights(ctx context.Context, request *MessagesEditChatDefaultBannedRightsRequest) (UpdatesClass, error)
- func (c *Client) MessagesEditChatPhoto(ctx context.Context, request *MessagesEditChatPhotoRequest) (UpdatesClass, error)
- func (c *Client) MessagesEditChatTitle(ctx context.Context, request *MessagesEditChatTitleRequest) (UpdatesClass, error)
- func (c *Client) MessagesEditInlineBotMessage(ctx context.Context, request *MessagesEditInlineBotMessageRequest) (bool, error)
- func (c *Client) MessagesEditMessage(ctx context.Context, request *MessagesEditMessageRequest) (UpdatesClass, error)
- func (c *Client) MessagesExportChatInvite(ctx context.Context, peer InputPeerClass) (ExportedChatInviteClass, error)
- func (c *Client) MessagesFaveSticker(ctx context.Context, request *MessagesFaveStickerRequest) (bool, error)
- func (c *Client) MessagesForwardMessages(ctx context.Context, request *MessagesForwardMessagesRequest) (UpdatesClass, error)
- func (c *Client) MessagesGetAllChats(ctx context.Context, exceptids []int) (MessagesChatsClass, error)
- func (c *Client) MessagesGetAllDrafts(ctx context.Context) (UpdatesClass, error)
- func (c *Client) MessagesGetAllStickers(ctx context.Context, hash int) (MessagesAllStickersClass, error)
- func (c *Client) MessagesGetArchivedStickers(ctx context.Context, request *MessagesGetArchivedStickersRequest) (*MessagesArchivedStickers, error)
- func (c *Client) MessagesGetAttachedStickers(ctx context.Context, media InputStickeredMediaClass) ([]StickerSetCoveredClass, error)
- func (c *Client) MessagesGetBotCallbackAnswer(ctx context.Context, request *MessagesGetBotCallbackAnswerRequest) (*MessagesBotCallbackAnswer, error)
- func (c *Client) MessagesGetChats(ctx context.Context, id []int) (MessagesChatsClass, error)
- func (c *Client) MessagesGetCommonChats(ctx context.Context, request *MessagesGetCommonChatsRequest) (MessagesChatsClass, error)
- func (c *Client) MessagesGetDhConfig(ctx context.Context, request *MessagesGetDhConfigRequest) (MessagesDhConfigClass, error)
- func (c *Client) MessagesGetDialogFilters(ctx context.Context) ([]DialogFilter, error)
- func (c *Client) MessagesGetDialogUnreadMarks(ctx context.Context) ([]DialogPeerClass, error)
- func (c *Client) MessagesGetDialogs(ctx context.Context, request *MessagesGetDialogsRequest) (MessagesDialogsClass, error)
- func (c *Client) MessagesGetDiscussionMessage(ctx context.Context, request *MessagesGetDiscussionMessageRequest) (*MessagesDiscussionMessage, error)
- func (c *Client) MessagesGetDocumentByHash(ctx context.Context, request *MessagesGetDocumentByHashRequest) (DocumentClass, error)
- func (c *Client) MessagesGetEmojiKeywords(ctx context.Context, langcode string) (*EmojiKeywordsDifference, error)
- func (c *Client) MessagesGetEmojiKeywordsDifference(ctx context.Context, request *MessagesGetEmojiKeywordsDifferenceRequest) (*EmojiKeywordsDifference, error)
- func (c *Client) MessagesGetEmojiKeywordsLanguages(ctx context.Context, langcodes []string) ([]EmojiLanguage, error)
- func (c *Client) MessagesGetEmojiURL(ctx context.Context, langcode string) (*EmojiURL, error)
- func (c *Client) MessagesGetFavedStickers(ctx context.Context, hash int) (MessagesFavedStickersClass, error)
- func (c *Client) MessagesGetFeaturedStickers(ctx context.Context, hash int) (MessagesFeaturedStickersClass, error)
- func (c *Client) MessagesGetFullChat(ctx context.Context, chatid int) (*MessagesChatFull, error)
- func (c *Client) MessagesGetGameHighScores(ctx context.Context, request *MessagesGetGameHighScoresRequest) (*MessagesHighScores, error)
- func (c *Client) MessagesGetHistory(ctx context.Context, request *MessagesGetHistoryRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetInlineBotResults(ctx context.Context, request *MessagesGetInlineBotResultsRequest) (*MessagesBotResults, error)
- func (c *Client) MessagesGetInlineGameHighScores(ctx context.Context, request *MessagesGetInlineGameHighScoresRequest) (*MessagesHighScores, error)
- func (c *Client) MessagesGetMaskStickers(ctx context.Context, hash int) (MessagesAllStickersClass, error)
- func (c *Client) MessagesGetMessageEditData(ctx context.Context, request *MessagesGetMessageEditDataRequest) (*MessagesMessageEditData, error)
- func (c *Client) MessagesGetMessages(ctx context.Context, id []InputMessageClass) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetMessagesViews(ctx context.Context, request *MessagesGetMessagesViewsRequest) (*MessagesMessageViews, error)
- func (c *Client) MessagesGetOldFeaturedStickers(ctx context.Context, request *MessagesGetOldFeaturedStickersRequest) (MessagesFeaturedStickersClass, error)
- func (c *Client) MessagesGetOnlines(ctx context.Context, peer InputPeerClass) (*ChatOnlines, error)
- func (c *Client) MessagesGetPeerDialogs(ctx context.Context, peers []InputDialogPeerClass) (*MessagesPeerDialogs, error)
- func (c *Client) MessagesGetPeerSettings(ctx context.Context, peer InputPeerClass) (*PeerSettings, error)
- func (c *Client) MessagesGetPinnedDialogs(ctx context.Context, folderid int) (*MessagesPeerDialogs, error)
- func (c *Client) MessagesGetPollResults(ctx context.Context, request *MessagesGetPollResultsRequest) (UpdatesClass, error)
- func (c *Client) MessagesGetPollVotes(ctx context.Context, request *MessagesGetPollVotesRequest) (*MessagesVotesList, error)
- func (c *Client) MessagesGetRecentLocations(ctx context.Context, request *MessagesGetRecentLocationsRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetRecentStickers(ctx context.Context, request *MessagesGetRecentStickersRequest) (MessagesRecentStickersClass, error)
- func (c *Client) MessagesGetReplies(ctx context.Context, request *MessagesGetRepliesRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetSavedGifs(ctx context.Context, hash int) (MessagesSavedGifsClass, error)
- func (c *Client) MessagesGetScheduledHistory(ctx context.Context, request *MessagesGetScheduledHistoryRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetScheduledMessages(ctx context.Context, request *MessagesGetScheduledMessagesRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetSearchCounters(ctx context.Context, request *MessagesGetSearchCountersRequest) ([]MessagesSearchCounter, error)
- func (c *Client) MessagesGetSplitRanges(ctx context.Context) ([]MessageRange, error)
- func (c *Client) MessagesGetStatsURL(ctx context.Context, request *MessagesGetStatsURLRequest) (*StatsURL, error)
- func (c *Client) MessagesGetStickerSet(ctx context.Context, stickerset InputStickerSetClass) (*MessagesStickerSet, error)
- func (c *Client) MessagesGetStickers(ctx context.Context, request *MessagesGetStickersRequest) (MessagesStickersClass, error)
- func (c *Client) MessagesGetSuggestedDialogFilters(ctx context.Context) ([]DialogFilterSuggested, error)
- func (c *Client) MessagesGetUnreadMentions(ctx context.Context, request *MessagesGetUnreadMentionsRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesGetWebPage(ctx context.Context, request *MessagesGetWebPageRequest) (WebPageClass, error)
- func (c *Client) MessagesGetWebPagePreview(ctx context.Context, request *MessagesGetWebPagePreviewRequest) (MessageMediaClass, error)
- func (c *Client) MessagesHidePeerSettingsBar(ctx context.Context, peer InputPeerClass) (bool, error)
- func (c *Client) MessagesImportChatInvite(ctx context.Context, hash string) (UpdatesClass, error)
- func (c *Client) MessagesInstallStickerSet(ctx context.Context, request *MessagesInstallStickerSetRequest) (MessagesStickerSetInstallResultClass, error)
- func (c *Client) MessagesMarkDialogUnread(ctx context.Context, request *MessagesMarkDialogUnreadRequest) (bool, error)
- func (c *Client) MessagesMigrateChat(ctx context.Context, chatid int) (UpdatesClass, error)
- func (c *Client) MessagesReadDiscussion(ctx context.Context, request *MessagesReadDiscussionRequest) (bool, error)
- func (c *Client) MessagesReadEncryptedHistory(ctx context.Context, request *MessagesReadEncryptedHistoryRequest) (bool, error)
- func (c *Client) MessagesReadFeaturedStickers(ctx context.Context, id []int64) (bool, error)
- func (c *Client) MessagesReadHistory(ctx context.Context, request *MessagesReadHistoryRequest) (*MessagesAffectedMessages, error)
- func (c *Client) MessagesReadMentions(ctx context.Context, peer InputPeerClass) (*MessagesAffectedHistory, error)
- func (c *Client) MessagesReadMessageContents(ctx context.Context, id []int) (*MessagesAffectedMessages, error)
- func (c *Client) MessagesReceivedMessages(ctx context.Context, maxid int) ([]ReceivedNotifyMessage, error)
- func (c *Client) MessagesReceivedQueue(ctx context.Context, maxqts int) ([]int64, error)
- func (c *Client) MessagesReorderPinnedDialogs(ctx context.Context, request *MessagesReorderPinnedDialogsRequest) (bool, error)
- func (c *Client) MessagesReorderStickerSets(ctx context.Context, request *MessagesReorderStickerSetsRequest) (bool, error)
- func (c *Client) MessagesReport(ctx context.Context, request *MessagesReportRequest) (bool, error)
- func (c *Client) MessagesReportEncryptedSpam(ctx context.Context, peer InputEncryptedChat) (bool, error)
- func (c *Client) MessagesReportSpam(ctx context.Context, peer InputPeerClass) (bool, error)
- func (c *Client) MessagesRequestEncryption(ctx context.Context, request *MessagesRequestEncryptionRequest) (EncryptedChatClass, error)
- func (c *Client) MessagesRequestUrlAuth(ctx context.Context, request *MessagesRequestUrlAuthRequest) (UrlAuthResultClass, error)
- func (c *Client) MessagesSaveDraft(ctx context.Context, request *MessagesSaveDraftRequest) (bool, error)
- func (c *Client) MessagesSaveGif(ctx context.Context, request *MessagesSaveGifRequest) (bool, error)
- func (c *Client) MessagesSaveRecentSticker(ctx context.Context, request *MessagesSaveRecentStickerRequest) (bool, error)
- func (c *Client) MessagesSearch(ctx context.Context, request *MessagesSearchRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesSearchGlobal(ctx context.Context, request *MessagesSearchGlobalRequest) (MessagesMessagesClass, error)
- func (c *Client) MessagesSearchStickerSets(ctx context.Context, request *MessagesSearchStickerSetsRequest) (MessagesFoundStickerSetsClass, error)
- func (c *Client) MessagesSendEncrypted(ctx context.Context, request *MessagesSendEncryptedRequest) (MessagesSentEncryptedMessageClass, error)
- func (c *Client) MessagesSendEncryptedFile(ctx context.Context, request *MessagesSendEncryptedFileRequest) (MessagesSentEncryptedMessageClass, error)
- func (c *Client) MessagesSendEncryptedService(ctx context.Context, request *MessagesSendEncryptedServiceRequest) (MessagesSentEncryptedMessageClass, error)
- func (c *Client) MessagesSendInlineBotResult(ctx context.Context, request *MessagesSendInlineBotResultRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendMedia(ctx context.Context, request *MessagesSendMediaRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendMessage(ctx context.Context, request *MessagesSendMessageRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendMultiMedia(ctx context.Context, request *MessagesSendMultiMediaRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendScheduledMessages(ctx context.Context, request *MessagesSendScheduledMessagesRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendScreenshotNotification(ctx context.Context, request *MessagesSendScreenshotNotificationRequest) (UpdatesClass, error)
- func (c *Client) MessagesSendVote(ctx context.Context, request *MessagesSendVoteRequest) (UpdatesClass, error)
- func (c *Client) MessagesSetBotCallbackAnswer(ctx context.Context, request *MessagesSetBotCallbackAnswerRequest) (bool, error)
- func (c *Client) MessagesSetBotPrecheckoutResults(ctx context.Context, request *MessagesSetBotPrecheckoutResultsRequest) (bool, error)
- func (c *Client) MessagesSetBotShippingResults(ctx context.Context, request *MessagesSetBotShippingResultsRequest) (bool, error)
- func (c *Client) MessagesSetEncryptedTyping(ctx context.Context, request *MessagesSetEncryptedTypingRequest) (bool, error)
- func (c *Client) MessagesSetGameScore(ctx context.Context, request *MessagesSetGameScoreRequest) (UpdatesClass, error)
- func (c *Client) MessagesSetInlineBotResults(ctx context.Context, request *MessagesSetInlineBotResultsRequest) (bool, error)
- func (c *Client) MessagesSetInlineGameScore(ctx context.Context, request *MessagesSetInlineGameScoreRequest) (bool, error)
- func (c *Client) MessagesSetTyping(ctx context.Context, request *MessagesSetTypingRequest) (bool, error)
- func (c *Client) MessagesStartBot(ctx context.Context, request *MessagesStartBotRequest) (UpdatesClass, error)
- func (c *Client) MessagesToggleDialogPin(ctx context.Context, request *MessagesToggleDialogPinRequest) (bool, error)
- func (c *Client) MessagesToggleStickerSets(ctx context.Context, request *MessagesToggleStickerSetsRequest) (bool, error)
- func (c *Client) MessagesUninstallStickerSet(ctx context.Context, stickerset InputStickerSetClass) (bool, error)
- func (c *Client) MessagesUnpinAllMessages(ctx context.Context, peer InputPeerClass) (*MessagesAffectedHistory, error)
- func (c *Client) MessagesUpdateDialogFilter(ctx context.Context, request *MessagesUpdateDialogFilterRequest) (bool, error)
- func (c *Client) MessagesUpdateDialogFiltersOrder(ctx context.Context, order []int) (bool, error)
- func (c *Client) MessagesUpdatePinnedMessage(ctx context.Context, request *MessagesUpdatePinnedMessageRequest) (UpdatesClass, error)
- func (c *Client) MessagesUploadEncryptedFile(ctx context.Context, request *MessagesUploadEncryptedFileRequest) (EncryptedFileClass, error)
- func (c *Client) MessagesUploadMedia(ctx context.Context, request *MessagesUploadMediaRequest) (MessageMediaClass, error)
- func (c *Client) PaymentsClearSavedInfo(ctx context.Context, request *PaymentsClearSavedInfoRequest) (bool, error)
- func (c *Client) PaymentsGetBankCardData(ctx context.Context, number string) (*PaymentsBankCardData, error)
- func (c *Client) PaymentsGetPaymentForm(ctx context.Context, msgid int) (*PaymentsPaymentForm, error)
- func (c *Client) PaymentsGetPaymentReceipt(ctx context.Context, msgid int) (*PaymentsPaymentReceipt, error)
- func (c *Client) PaymentsGetSavedInfo(ctx context.Context) (*PaymentsSavedInfo, error)
- func (c *Client) PaymentsSendPaymentForm(ctx context.Context, request *PaymentsSendPaymentFormRequest) (PaymentsPaymentResultClass, error)
- func (c *Client) PaymentsValidateRequestedInfo(ctx context.Context, request *PaymentsValidateRequestedInfoRequest) (*PaymentsValidatedRequestedInfo, error)
- func (c *Client) PhoneAcceptCall(ctx context.Context, request *PhoneAcceptCallRequest) (*PhonePhoneCall, error)
- func (c *Client) PhoneCheckGroupCall(ctx context.Context, request *PhoneCheckGroupCallRequest) (bool, error)
- func (c *Client) PhoneConfirmCall(ctx context.Context, request *PhoneConfirmCallRequest) (*PhonePhoneCall, error)
- func (c *Client) PhoneCreateGroupCall(ctx context.Context, request *PhoneCreateGroupCallRequest) (UpdatesClass, error)
- func (c *Client) PhoneDiscardCall(ctx context.Context, request *PhoneDiscardCallRequest) (UpdatesClass, error)
- func (c *Client) PhoneDiscardGroupCall(ctx context.Context, call InputGroupCall) (UpdatesClass, error)
- func (c *Client) PhoneEditGroupCallMember(ctx context.Context, request *PhoneEditGroupCallMemberRequest) (UpdatesClass, error)
- func (c *Client) PhoneGetCallConfig(ctx context.Context) (*DataJSON, error)
- func (c *Client) PhoneGetGroupCall(ctx context.Context, call InputGroupCall) (*PhoneGroupCall, error)
- func (c *Client) PhoneGetGroupParticipants(ctx context.Context, request *PhoneGetGroupParticipantsRequest) (*PhoneGroupParticipants, error)
- func (c *Client) PhoneInviteToGroupCall(ctx context.Context, request *PhoneInviteToGroupCallRequest) (UpdatesClass, error)
- func (c *Client) PhoneJoinGroupCall(ctx context.Context, request *PhoneJoinGroupCallRequest) (UpdatesClass, error)
- func (c *Client) PhoneLeaveGroupCall(ctx context.Context, request *PhoneLeaveGroupCallRequest) (UpdatesClass, error)
- func (c *Client) PhoneReceivedCall(ctx context.Context, peer InputPhoneCall) (bool, error)
- func (c *Client) PhoneRequestCall(ctx context.Context, request *PhoneRequestCallRequest) (*PhonePhoneCall, error)
- func (c *Client) PhoneSaveCallDebug(ctx context.Context, request *PhoneSaveCallDebugRequest) (bool, error)
- func (c *Client) PhoneSendSignalingData(ctx context.Context, request *PhoneSendSignalingDataRequest) (bool, error)
- func (c *Client) PhoneSetCallRating(ctx context.Context, request *PhoneSetCallRatingRequest) (UpdatesClass, error)
- func (c *Client) PhoneToggleGroupCallSettings(ctx context.Context, request *PhoneToggleGroupCallSettingsRequest) (UpdatesClass, error)
- func (c *Client) PhotosDeletePhotos(ctx context.Context, id []InputPhotoClass) ([]int64, error)
- func (c *Client) PhotosGetUserPhotos(ctx context.Context, request *PhotosGetUserPhotosRequest) (PhotosPhotosClass, error)
- func (c *Client) PhotosUpdateProfilePhoto(ctx context.Context, id InputPhotoClass) (*PhotosPhoto, error)
- func (c *Client) PhotosUploadProfilePhoto(ctx context.Context, request *PhotosUploadProfilePhotoRequest) (*PhotosPhoto, error)
- func (c *Client) StatsGetBroadcastStats(ctx context.Context, request *StatsGetBroadcastStatsRequest) (*StatsBroadcastStats, error)
- func (c *Client) StatsGetMegagroupStats(ctx context.Context, request *StatsGetMegagroupStatsRequest) (*StatsMegagroupStats, error)
- func (c *Client) StatsGetMessagePublicForwards(ctx context.Context, request *StatsGetMessagePublicForwardsRequest) (MessagesMessagesClass, error)
- func (c *Client) StatsGetMessageStats(ctx context.Context, request *StatsGetMessageStatsRequest) (*StatsMessageStats, error)
- func (c *Client) StatsLoadAsyncGraph(ctx context.Context, request *StatsLoadAsyncGraphRequest) (StatsGraphClass, error)
- func (c *Client) StickersAddStickerToSet(ctx context.Context, request *StickersAddStickerToSetRequest) (*MessagesStickerSet, error)
- func (c *Client) StickersChangeStickerPosition(ctx context.Context, request *StickersChangeStickerPositionRequest) (*MessagesStickerSet, error)
- func (c *Client) StickersCreateStickerSet(ctx context.Context, request *StickersCreateStickerSetRequest) (*MessagesStickerSet, error)
- func (c *Client) StickersRemoveStickerFromSet(ctx context.Context, sticker InputDocumentClass) (*MessagesStickerSet, error)
- func (c *Client) StickersSetStickerSetThumb(ctx context.Context, request *StickersSetStickerSetThumbRequest) (*MessagesStickerSet, error)
- func (c *Client) UpdatesGetChannelDifference(ctx context.Context, request *UpdatesGetChannelDifferenceRequest) (UpdatesChannelDifferenceClass, error)
- func (c *Client) UpdatesGetDifference(ctx context.Context, request *UpdatesGetDifferenceRequest) (UpdatesDifferenceClass, error)
- func (c *Client) UpdatesGetState(ctx context.Context) (*UpdatesState, error)
- func (c *Client) UploadGetCdnFile(ctx context.Context, request *UploadGetCdnFileRequest) (UploadCdnFileClass, error)
- func (c *Client) UploadGetCdnFileHashes(ctx context.Context, request *UploadGetCdnFileHashesRequest) ([]FileHash, error)
- func (c *Client) UploadGetFile(ctx context.Context, request *UploadGetFileRequest) (UploadFileClass, error)
- func (c *Client) UploadGetFileHashes(ctx context.Context, request *UploadGetFileHashesRequest) ([]FileHash, error)
- func (c *Client) UploadGetWebFile(ctx context.Context, request *UploadGetWebFileRequest) (*UploadWebFile, error)
- func (c *Client) UploadReuploadCdnFile(ctx context.Context, request *UploadReuploadCdnFileRequest) ([]FileHash, error)
- func (c *Client) UploadSaveBigFilePart(ctx context.Context, request *UploadSaveBigFilePartRequest) (bool, error)
- func (c *Client) UploadSaveFilePart(ctx context.Context, request *UploadSaveFilePartRequest) (bool, error)
- func (c *Client) UsersGetFullUser(ctx context.Context, id InputUserClass) (*UserFull, error)
- func (c *Client) UsersGetUsers(ctx context.Context, id []InputUserClass) ([]UserClass, error)
- func (c *Client) UsersSetSecureValueErrors(ctx context.Context, request *UsersSetSecureValueErrorsRequest) (bool, error)
- type CodeSettings
- type Config
- func (c *Config) Decode(b *bin.Buffer) error
- func (c *Config) Encode(b *bin.Buffer) error
- func (c *Config) GetAutoupdateURLPrefix() (value string, ok bool)
- func (c *Config) GetBaseLangPackVersion() (value int, ok bool)
- func (c *Config) GetGifSearchUsername() (value string, ok bool)
- func (c *Config) GetImgSearchUsername() (value string, ok bool)
- func (c *Config) GetLangPackVersion() (value int, ok bool)
- func (c *Config) GetStaticMapsProvider() (value string, ok bool)
- func (c *Config) GetSuggestedLangCode() (value string, ok bool)
- func (c *Config) GetTmpSessions() (value int, ok bool)
- func (c *Config) GetVenueSearchUsername() (value string, ok bool)
- func (c *Config) SetAutoupdateURLPrefix(value string)
- func (c *Config) SetBaseLangPackVersion(value int)
- func (c *Config) SetBlockedMode(value bool)
- func (c *Config) SetDefaultP2PContacts(value bool)
- func (c *Config) SetGifSearchUsername(value string)
- func (c *Config) SetIgnorePhoneEntities(value bool)
- func (c *Config) SetImgSearchUsername(value string)
- func (c *Config) SetLangPackVersion(value int)
- func (c *Config) SetPFSEnabled(value bool)
- func (c *Config) SetPhonecallsEnabled(value bool)
- func (c *Config) SetPreloadFeaturedStickers(value bool)
- func (c *Config) SetRevokePmInbox(value bool)
- func (c *Config) SetStaticMapsProvider(value string)
- func (c *Config) SetSuggestedLangCode(value string)
- func (c *Config) SetTmpSessions(value int)
- func (c *Config) SetVenueSearchUsername(value string)
- func (c *Config) String() string
- type ConfigHandler
- type Contact
- type ContactStatus
- type ContactStatusVector
- type ContactsAcceptContactRequest
- type ContactsAddContactRequest
- type ContactsBlockFromRepliesRequest
- func (b *ContactsBlockFromRepliesRequest) Decode(buf *bin.Buffer) error
- func (b *ContactsBlockFromRepliesRequest) Encode(buf *bin.Buffer) error
- func (b *ContactsBlockFromRepliesRequest) SetDeleteHistory(value bool)
- func (b *ContactsBlockFromRepliesRequest) SetDeleteMessage(value bool)
- func (b *ContactsBlockFromRepliesRequest) SetReportSpam(value bool)
- func (b *ContactsBlockFromRepliesRequest) String() string
- type ContactsBlockRequest
- type ContactsBlocked
- type ContactsBlockedBox
- type ContactsBlockedClass
- type ContactsBlockedSlice
- type ContactsContacts
- type ContactsContactsBox
- type ContactsContactsClass
- type ContactsContactsNotModified
- type ContactsDeleteByPhonesRequest
- type ContactsDeleteContactsRequest
- type ContactsFound
- type ContactsGetBlockedRequest
- type ContactsGetContactIDsRequest
- type ContactsGetContactsRequest
- type ContactsGetLocatedRequest
- func (g *ContactsGetLocatedRequest) Decode(b *bin.Buffer) error
- func (g *ContactsGetLocatedRequest) Encode(b *bin.Buffer) error
- func (g *ContactsGetLocatedRequest) GetSelfExpires() (value int, ok bool)
- func (g *ContactsGetLocatedRequest) SetBackground(value bool)
- func (g *ContactsGetLocatedRequest) SetSelfExpires(value int)
- func (g *ContactsGetLocatedRequest) String() string
- type ContactsGetSavedRequest
- type ContactsGetStatusesRequest
- type ContactsGetTopPeersRequest
- func (g *ContactsGetTopPeersRequest) Decode(b *bin.Buffer) error
- func (g *ContactsGetTopPeersRequest) Encode(b *bin.Buffer) error
- func (g *ContactsGetTopPeersRequest) SetBotsInline(value bool)
- func (g *ContactsGetTopPeersRequest) SetBotsPm(value bool)
- func (g *ContactsGetTopPeersRequest) SetChannels(value bool)
- func (g *ContactsGetTopPeersRequest) SetCorrespondents(value bool)
- func (g *ContactsGetTopPeersRequest) SetForwardChats(value bool)
- func (g *ContactsGetTopPeersRequest) SetForwardUsers(value bool)
- func (g *ContactsGetTopPeersRequest) SetGroups(value bool)
- func (g *ContactsGetTopPeersRequest) SetPhoneCalls(value bool)
- func (g *ContactsGetTopPeersRequest) String() string
- type ContactsImportContactsRequest
- type ContactsImportedContacts
- type ContactsResetHandler
- type ContactsResetSavedRequest
- type ContactsResetTopPeerRatingRequest
- type ContactsResolveUsernameRequest
- type ContactsResolvedPeer
- type ContactsSearchRequest
- type ContactsToggleTopPeersRequest
- type ContactsTopPeers
- type ContactsTopPeersBox
- type ContactsTopPeersClass
- type ContactsTopPeersDisabled
- type ContactsTopPeersNotModified
- type ContactsUnblockRequest
- type DataJSON
- type DcOption
- func (d *DcOption) Decode(b *bin.Buffer) error
- func (d *DcOption) Encode(b *bin.Buffer) error
- func (d *DcOption) GetSecret() (value []byte, ok bool)
- func (d *DcOption) SetCDN(value bool)
- func (d *DcOption) SetIpv6(value bool)
- func (d *DcOption) SetMediaOnly(value bool)
- func (d *DcOption) SetSecret(value []byte)
- func (d *DcOption) SetStatic(value bool)
- func (d *DcOption) SetTcpoOnly(value bool)
- func (d *DcOption) String() string
- type DcOptionsHandler
- type DeleteChannelMessagesHandler
- type DeleteMessagesHandler
- type DeleteScheduledMessagesHandler
- type Dialog
- func (d *Dialog) Decode(b *bin.Buffer) error
- func (d *Dialog) Encode(b *bin.Buffer) error
- func (d *Dialog) GetDraft() (value DraftMessageClass, ok bool)
- func (d *Dialog) GetFolderID() (value int, ok bool)
- func (d *Dialog) GetPts() (value int, ok bool)
- func (d *Dialog) SetDraft(value DraftMessageClass)
- func (d *Dialog) SetFolderID(value int)
- func (d *Dialog) SetPinned(value bool)
- func (d *Dialog) SetPts(value int)
- func (d *Dialog) SetUnreadMark(value bool)
- func (d *Dialog) String() string
- type DialogBox
- type DialogClass
- type DialogFilter
- func (d *DialogFilter) Decode(b *bin.Buffer) error
- func (d *DialogFilter) Encode(b *bin.Buffer) error
- func (d *DialogFilter) GetEmoticon() (value string, ok bool)
- func (d *DialogFilter) SetBots(value bool)
- func (d *DialogFilter) SetBroadcasts(value bool)
- func (d *DialogFilter) SetContacts(value bool)
- func (d *DialogFilter) SetEmoticon(value string)
- func (d *DialogFilter) SetExcludeArchived(value bool)
- func (d *DialogFilter) SetExcludeMuted(value bool)
- func (d *DialogFilter) SetExcludeRead(value bool)
- func (d *DialogFilter) SetGroups(value bool)
- func (d *DialogFilter) SetNonContacts(value bool)
- func (d *DialogFilter) String() string
- type DialogFilterHandler
- type DialogFilterOrderHandler
- type DialogFilterSuggested
- type DialogFilterSuggestedVector
- type DialogFilterVector
- type DialogFiltersHandler
- type DialogFolder
- type DialogPeer
- type DialogPeerBox
- type DialogPeerClass
- type DialogPeerClassVector
- type DialogPeerFolder
- type DialogPinnedHandler
- type DialogUnreadMarkHandler
- type Document
- func (d *Document) Decode(b *bin.Buffer) error
- func (d *Document) Encode(b *bin.Buffer) error
- func (d *Document) GetThumbs() (value []PhotoSizeClass, ok bool)
- func (d *Document) GetVideoThumbs() (value []VideoSize, ok bool)
- func (d *Document) SetThumbs(value []PhotoSizeClass)
- func (d *Document) SetVideoThumbs(value []VideoSize)
- func (d *Document) String() string
- type DocumentAttributeAnimated
- type DocumentAttributeAudio
- func (d *DocumentAttributeAudio) Decode(b *bin.Buffer) error
- func (d *DocumentAttributeAudio) Encode(b *bin.Buffer) error
- func (d *DocumentAttributeAudio) GetPerformer() (value string, ok bool)
- func (d *DocumentAttributeAudio) GetTitle() (value string, ok bool)
- func (d *DocumentAttributeAudio) GetWaveform() (value []byte, ok bool)
- func (d *DocumentAttributeAudio) SetPerformer(value string)
- func (d *DocumentAttributeAudio) SetTitle(value string)
- func (d *DocumentAttributeAudio) SetVoice(value bool)
- func (d *DocumentAttributeAudio) SetWaveform(value []byte)
- func (d *DocumentAttributeAudio) String() string
- type DocumentAttributeBox
- type DocumentAttributeClass
- type DocumentAttributeFilename
- type DocumentAttributeHasStickers
- type DocumentAttributeImageSize
- type DocumentAttributeSticker
- func (d *DocumentAttributeSticker) Decode(b *bin.Buffer) error
- func (d *DocumentAttributeSticker) Encode(b *bin.Buffer) error
- func (d *DocumentAttributeSticker) GetMaskCoords() (value MaskCoords, ok bool)
- func (d *DocumentAttributeSticker) SetMask(value bool)
- func (d *DocumentAttributeSticker) SetMaskCoords(value MaskCoords)
- func (d *DocumentAttributeSticker) String() string
- type DocumentAttributeVideo
- type DocumentBox
- type DocumentClass
- type DocumentEmpty
- type DraftMessage
- func (d *DraftMessage) Decode(b *bin.Buffer) error
- func (d *DraftMessage) Encode(b *bin.Buffer) error
- func (d *DraftMessage) GetEntities() (value []MessageEntityClass, ok bool)
- func (d *DraftMessage) GetReplyToMsgID() (value int, ok bool)
- func (d *DraftMessage) SetEntities(value []MessageEntityClass)
- func (d *DraftMessage) SetNoWebpage(value bool)
- func (d *DraftMessage) SetReplyToMsgID(value int)
- func (d *DraftMessage) String() string
- type DraftMessageBox
- type DraftMessageClass
- type DraftMessageEmpty
- type DraftMessageHandler
- type EditChannelMessageHandler
- type EditMessageHandler
- type EmojiKeyword
- type EmojiKeywordBox
- type EmojiKeywordClass
- type EmojiKeywordDeleted
- type EmojiKeywordsDifference
- type EmojiLanguage
- type EmojiLanguageVector
- type EmojiURL
- type EncryptedChat
- type EncryptedChatBox
- type EncryptedChatClass
- type EncryptedChatDiscarded
- type EncryptedChatEmpty
- type EncryptedChatRequested
- type EncryptedChatTypingHandler
- type EncryptedChatWaiting
- type EncryptedFile
- type EncryptedFileBox
- type EncryptedFileClass
- type EncryptedFileEmpty
- type EncryptedMessage
- type EncryptedMessageBox
- type EncryptedMessageClass
- type EncryptedMessageService
- type EncryptedMessagesReadHandler
- type EncryptionHandler
- type Error
- type ExportedChatInviteBox
- type ExportedChatInviteClass
- type ExportedMessageLink
- type FavedStickersHandler
- type FileHash
- type FileHashVector
- type FileLocationToBeDeprecated
- type Folder
- func (f *Folder) Decode(b *bin.Buffer) error
- func (f *Folder) Encode(b *bin.Buffer) error
- func (f *Folder) GetPhoto() (value ChatPhotoClass, ok bool)
- func (f *Folder) SetAutofillNewBroadcasts(value bool)
- func (f *Folder) SetAutofillNewCorrespondents(value bool)
- func (f *Folder) SetAutofillPublicGroups(value bool)
- func (f *Folder) SetPhoto(value ChatPhotoClass)
- func (f *Folder) String() string
- type FolderPeer
- type FolderPeersHandler
- type FoldersDeleteFolderRequest
- type FoldersEditPeerFoldersRequest
- type Game
- type GeoLiveViewedHandler
- type GeoPoint
- type GeoPointBox
- type GeoPointClass
- type GeoPointEmpty
- type GlobalPrivacySettings
- func (g *GlobalPrivacySettings) Decode(b *bin.Buffer) error
- func (g *GlobalPrivacySettings) Encode(b *bin.Buffer) error
- func (g *GlobalPrivacySettings) GetArchiveAndMuteNewNoncontactPeers() (value bool, ok bool)
- func (g *GlobalPrivacySettings) SetArchiveAndMuteNewNoncontactPeers(value bool)
- func (g *GlobalPrivacySettings) String() string
- type GroupCall
- func (g *GroupCall) Decode(b *bin.Buffer) error
- func (g *GroupCall) Encode(b *bin.Buffer) error
- func (g *GroupCall) GetParams() (value DataJSON, ok bool)
- func (g *GroupCall) SetCanChangeJoinMuted(value bool)
- func (g *GroupCall) SetJoinMuted(value bool)
- func (g *GroupCall) SetParams(value DataJSON)
- func (g *GroupCall) String() string
- type GroupCallBox
- type GroupCallClass
- type GroupCallDiscarded
- type GroupCallHandler
- type GroupCallParticipant
- func (g *GroupCallParticipant) Decode(b *bin.Buffer) error
- func (g *GroupCallParticipant) Encode(b *bin.Buffer) error
- func (g *GroupCallParticipant) GetActiveDate() (value int, ok bool)
- func (g *GroupCallParticipant) SetActiveDate(value int)
- func (g *GroupCallParticipant) SetCanSelfUnmute(value bool)
- func (g *GroupCallParticipant) SetJustJoined(value bool)
- func (g *GroupCallParticipant) SetLeft(value bool)
- func (g *GroupCallParticipant) SetMuted(value bool)
- func (g *GroupCallParticipant) SetVersioned(value bool)
- func (g *GroupCallParticipant) String() string
- type GroupCallParticipantsHandler
- type HelpAcceptTermsOfServiceRequest
- type HelpAppUpdate
- func (a *HelpAppUpdate) Decode(b *bin.Buffer) error
- func (a *HelpAppUpdate) Encode(b *bin.Buffer) error
- func (a *HelpAppUpdate) GetDocument() (value DocumentClass, ok bool)
- func (a *HelpAppUpdate) GetURL() (value string, ok bool)
- func (a *HelpAppUpdate) SetCanNotSkip(value bool)
- func (a *HelpAppUpdate) SetDocument(value DocumentClass)
- func (a *HelpAppUpdate) SetURL(value string)
- func (a *HelpAppUpdate) String() string
- type HelpAppUpdateBox
- type HelpAppUpdateClass
- type HelpCountriesList
- type HelpCountriesListBox
- type HelpCountriesListClass
- type HelpCountriesListNotModified
- type HelpCountry
- type HelpCountryCode
- func (c *HelpCountryCode) Decode(b *bin.Buffer) error
- func (c *HelpCountryCode) Encode(b *bin.Buffer) error
- func (c *HelpCountryCode) GetPatterns() (value []string, ok bool)
- func (c *HelpCountryCode) GetPrefixes() (value []string, ok bool)
- func (c *HelpCountryCode) SetPatterns(value []string)
- func (c *HelpCountryCode) SetPrefixes(value []string)
- func (c *HelpCountryCode) String() string
- type HelpDeepLinkInfo
- func (d *HelpDeepLinkInfo) Decode(b *bin.Buffer) error
- func (d *HelpDeepLinkInfo) Encode(b *bin.Buffer) error
- func (d *HelpDeepLinkInfo) GetEntities() (value []MessageEntityClass, ok bool)
- func (d *HelpDeepLinkInfo) SetEntities(value []MessageEntityClass)
- func (d *HelpDeepLinkInfo) SetUpdateApp(value bool)
- func (d *HelpDeepLinkInfo) String() string
- type HelpDeepLinkInfoBox
- type HelpDeepLinkInfoClass
- type HelpDeepLinkInfoEmpty
- type HelpDismissSuggestionRequest
- type HelpEditUserInfoRequest
- type HelpGetAppChangelogRequest
- type HelpGetAppConfigRequest
- type HelpGetAppUpdateRequest
- type HelpGetCdnConfigRequest
- type HelpGetConfigRequest
- type HelpGetCountriesListRequest
- type HelpGetDeepLinkInfoRequest
- type HelpGetInviteTextRequest
- type HelpGetNearestDcRequest
- type HelpGetPassportConfigRequest
- type HelpGetPromoDataRequest
- type HelpGetRecentMeUrlsRequest
- type HelpGetSupportNameRequest
- type HelpGetSupportRequest
- type HelpGetTermsOfServiceUpdateRequest
- type HelpGetUserInfoRequest
- type HelpHidePromoDataRequest
- type HelpInviteText
- type HelpNoAppUpdate
- type HelpPassportConfig
- type HelpPassportConfigBox
- type HelpPassportConfigClass
- type HelpPassportConfigNotModified
- type HelpPromoData
- func (p *HelpPromoData) Decode(b *bin.Buffer) error
- func (p *HelpPromoData) Encode(b *bin.Buffer) error
- func (p *HelpPromoData) GetPsaMessage() (value string, ok bool)
- func (p *HelpPromoData) GetPsaType() (value string, ok bool)
- func (p *HelpPromoData) SetProxy(value bool)
- func (p *HelpPromoData) SetPsaMessage(value string)
- func (p *HelpPromoData) SetPsaType(value string)
- func (p *HelpPromoData) String() string
- type HelpPromoDataBox
- type HelpPromoDataClass
- type HelpPromoDataEmpty
- type HelpRecentMeUrls
- type HelpSaveAppLogRequest
- type HelpSetBotUpdatesStatusRequest
- type HelpSupport
- type HelpSupportName
- type HelpTermsOfService
- func (t *HelpTermsOfService) Decode(b *bin.Buffer) error
- func (t *HelpTermsOfService) Encode(b *bin.Buffer) error
- func (t *HelpTermsOfService) GetMinAgeConfirm() (value int, ok bool)
- func (t *HelpTermsOfService) SetMinAgeConfirm(value int)
- func (t *HelpTermsOfService) SetPopup(value bool)
- func (t *HelpTermsOfService) String() string
- type HelpTermsOfServiceUpdate
- type HelpTermsOfServiceUpdateBox
- type HelpTermsOfServiceUpdateClass
- type HelpTermsOfServiceUpdateEmpty
- type HelpUserInfo
- type HelpUserInfoBox
- type HelpUserInfoClass
- type HelpUserInfoEmpty
- type HighScore
- type ImportedContact
- type InitConnectionRequest
- func (i *InitConnectionRequest) Decode(b *bin.Buffer) error
- func (i *InitConnectionRequest) Encode(b *bin.Buffer) error
- func (i *InitConnectionRequest) GetParams() (value JSONValueClass, ok bool)
- func (i *InitConnectionRequest) GetProxy() (value InputClientProxy, ok bool)
- func (i *InitConnectionRequest) SetParams(value JSONValueClass)
- func (i *InitConnectionRequest) SetProxy(value InputClientProxy)
- func (i *InitConnectionRequest) String() string
- type InlineBotCallbackQueryHandler
- type InlineBotSwitchPM
- type InlineQueryPeerTypeBox
- type InlineQueryPeerTypeBroadcast
- type InlineQueryPeerTypeChat
- type InlineQueryPeerTypeClass
- type InlineQueryPeerTypeMegagroup
- type InlineQueryPeerTypePM
- type InlineQueryPeerTypeSameBotPM
- type InputAppEvent
- type InputBotInlineMessageBox
- type InputBotInlineMessageClass
- type InputBotInlineMessageGame
- func (i *InputBotInlineMessageGame) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageGame) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageGame) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageGame) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageGame) String() string
- type InputBotInlineMessageID
- type InputBotInlineMessageMediaAuto
- func (i *InputBotInlineMessageMediaAuto) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaAuto) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaAuto) GetEntities() (value []MessageEntityClass, ok bool)
- func (i *InputBotInlineMessageMediaAuto) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageMediaAuto) SetEntities(value []MessageEntityClass)
- func (i *InputBotInlineMessageMediaAuto) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageMediaAuto) String() string
- type InputBotInlineMessageMediaContact
- func (i *InputBotInlineMessageMediaContact) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaContact) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaContact) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageMediaContact) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageMediaContact) String() string
- type InputBotInlineMessageMediaGeo
- func (i *InputBotInlineMessageMediaGeo) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaGeo) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaGeo) GetHeading() (value int, ok bool)
- func (i *InputBotInlineMessageMediaGeo) GetPeriod() (value int, ok bool)
- func (i *InputBotInlineMessageMediaGeo) GetProximityNotificationRadius() (value int, ok bool)
- func (i *InputBotInlineMessageMediaGeo) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageMediaGeo) SetHeading(value int)
- func (i *InputBotInlineMessageMediaGeo) SetPeriod(value int)
- func (i *InputBotInlineMessageMediaGeo) SetProximityNotificationRadius(value int)
- func (i *InputBotInlineMessageMediaGeo) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageMediaGeo) String() string
- type InputBotInlineMessageMediaVenue
- func (i *InputBotInlineMessageMediaVenue) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaVenue) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageMediaVenue) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageMediaVenue) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageMediaVenue) String() string
- type InputBotInlineMessageText
- func (i *InputBotInlineMessageText) Decode(b *bin.Buffer) error
- func (i *InputBotInlineMessageText) Encode(b *bin.Buffer) error
- func (i *InputBotInlineMessageText) GetEntities() (value []MessageEntityClass, ok bool)
- func (i *InputBotInlineMessageText) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (i *InputBotInlineMessageText) SetEntities(value []MessageEntityClass)
- func (i *InputBotInlineMessageText) SetNoWebpage(value bool)
- func (i *InputBotInlineMessageText) SetReplyMarkup(value ReplyMarkupClass)
- func (i *InputBotInlineMessageText) String() string
- type InputBotInlineResult
- func (i *InputBotInlineResult) Decode(b *bin.Buffer) error
- func (i *InputBotInlineResult) Encode(b *bin.Buffer) error
- func (i *InputBotInlineResult) GetContent() (value InputWebDocument, ok bool)
- func (i *InputBotInlineResult) GetDescription() (value string, ok bool)
- func (i *InputBotInlineResult) GetThumb() (value InputWebDocument, ok bool)
- func (i *InputBotInlineResult) GetTitle() (value string, ok bool)
- func (i *InputBotInlineResult) GetURL() (value string, ok bool)
- func (i *InputBotInlineResult) SetContent(value InputWebDocument)
- func (i *InputBotInlineResult) SetDescription(value string)
- func (i *InputBotInlineResult) SetThumb(value InputWebDocument)
- func (i *InputBotInlineResult) SetTitle(value string)
- func (i *InputBotInlineResult) SetURL(value string)
- func (i *InputBotInlineResult) String() string
- type InputBotInlineResultBox
- type InputBotInlineResultClass
- type InputBotInlineResultDocument
- func (i *InputBotInlineResultDocument) Decode(b *bin.Buffer) error
- func (i *InputBotInlineResultDocument) Encode(b *bin.Buffer) error
- func (i *InputBotInlineResultDocument) GetDescription() (value string, ok bool)
- func (i *InputBotInlineResultDocument) GetTitle() (value string, ok bool)
- func (i *InputBotInlineResultDocument) SetDescription(value string)
- func (i *InputBotInlineResultDocument) SetTitle(value string)
- func (i *InputBotInlineResultDocument) String() string
- type InputBotInlineResultGame
- type InputBotInlineResultPhoto
- type InputChannel
- type InputChannelBox
- type InputChannelClass
- type InputChannelEmpty
- type InputChannelFromMessage
- type InputChatPhoto
- type InputChatPhotoBox
- type InputChatPhotoClass
- type InputChatPhotoEmpty
- type InputChatUploadedPhoto
- func (i *InputChatUploadedPhoto) Decode(b *bin.Buffer) error
- func (i *InputChatUploadedPhoto) Encode(b *bin.Buffer) error
- func (i *InputChatUploadedPhoto) GetFile() (value InputFileClass, ok bool)
- func (i *InputChatUploadedPhoto) GetVideo() (value InputFileClass, ok bool)
- func (i *InputChatUploadedPhoto) GetVideoStartTs() (value float64, ok bool)
- func (i *InputChatUploadedPhoto) SetFile(value InputFileClass)
- func (i *InputChatUploadedPhoto) SetVideo(value InputFileClass)
- func (i *InputChatUploadedPhoto) SetVideoStartTs(value float64)
- func (i *InputChatUploadedPhoto) String() string
- type InputCheckPasswordEmpty
- type InputCheckPasswordSRP
- type InputCheckPasswordSRPBox
- type InputCheckPasswordSRPClass
- type InputClientProxy
- type InputDialogPeer
- type InputDialogPeerBox
- type InputDialogPeerClass
- type InputDialogPeerFolder
- type InputDocument
- type InputDocumentBox
- type InputDocumentClass
- type InputDocumentEmpty
- type InputDocumentFileLocation
- type InputEncryptedChat
- type InputEncryptedFile
- type InputEncryptedFileBigUploaded
- type InputEncryptedFileBox
- type InputEncryptedFileClass
- type InputEncryptedFileEmpty
- type InputEncryptedFileLocation
- type InputEncryptedFileUploaded
- type InputFile
- type InputFileBig
- type InputFileBox
- type InputFileClass
- type InputFileLocation
- type InputFileLocationBox
- type InputFileLocationClass
- type InputFolderPeer
- type InputGameBox
- type InputGameClass
- type InputGameID
- type InputGameShortName
- type InputGeoPoint
- type InputGeoPointBox
- type InputGeoPointClass
- type InputGeoPointEmpty
- type InputGroupCall
- type InputKeyboardButtonUrlAuth
- func (i *InputKeyboardButtonUrlAuth) Decode(b *bin.Buffer) error
- func (i *InputKeyboardButtonUrlAuth) Encode(b *bin.Buffer) error
- func (i *InputKeyboardButtonUrlAuth) GetFwdText() (value string, ok bool)
- func (i *InputKeyboardButtonUrlAuth) SetFwdText(value string)
- func (i *InputKeyboardButtonUrlAuth) SetRequestWriteAccess(value bool)
- func (i *InputKeyboardButtonUrlAuth) String() string
- type InputMediaBox
- type InputMediaClass
- type InputMediaContact
- type InputMediaDice
- type InputMediaDocument
- func (i *InputMediaDocument) Decode(b *bin.Buffer) error
- func (i *InputMediaDocument) Encode(b *bin.Buffer) error
- func (i *InputMediaDocument) GetQuery() (value string, ok bool)
- func (i *InputMediaDocument) GetTTLSeconds() (value int, ok bool)
- func (i *InputMediaDocument) SetQuery(value string)
- func (i *InputMediaDocument) SetTTLSeconds(value int)
- func (i *InputMediaDocument) String() string
- type InputMediaDocumentExternal
- func (i *InputMediaDocumentExternal) Decode(b *bin.Buffer) error
- func (i *InputMediaDocumentExternal) Encode(b *bin.Buffer) error
- func (i *InputMediaDocumentExternal) GetTTLSeconds() (value int, ok bool)
- func (i *InputMediaDocumentExternal) SetTTLSeconds(value int)
- func (i *InputMediaDocumentExternal) String() string
- type InputMediaEmpty
- type InputMediaGame
- type InputMediaGeoLive
- func (i *InputMediaGeoLive) Decode(b *bin.Buffer) error
- func (i *InputMediaGeoLive) Encode(b *bin.Buffer) error
- func (i *InputMediaGeoLive) GetHeading() (value int, ok bool)
- func (i *InputMediaGeoLive) GetPeriod() (value int, ok bool)
- func (i *InputMediaGeoLive) GetProximityNotificationRadius() (value int, ok bool)
- func (i *InputMediaGeoLive) SetHeading(value int)
- func (i *InputMediaGeoLive) SetPeriod(value int)
- func (i *InputMediaGeoLive) SetProximityNotificationRadius(value int)
- func (i *InputMediaGeoLive) SetStopped(value bool)
- func (i *InputMediaGeoLive) String() string
- type InputMediaGeoPoint
- type InputMediaInvoice
- type InputMediaPhoto
- type InputMediaPhotoExternal
- func (i *InputMediaPhotoExternal) Decode(b *bin.Buffer) error
- func (i *InputMediaPhotoExternal) Encode(b *bin.Buffer) error
- func (i *InputMediaPhotoExternal) GetTTLSeconds() (value int, ok bool)
- func (i *InputMediaPhotoExternal) SetTTLSeconds(value int)
- func (i *InputMediaPhotoExternal) String() string
- type InputMediaPoll
- func (i *InputMediaPoll) Decode(b *bin.Buffer) error
- func (i *InputMediaPoll) Encode(b *bin.Buffer) error
- func (i *InputMediaPoll) GetCorrectAnswers() (value [][]byte, ok bool)
- func (i *InputMediaPoll) GetSolution() (value string, ok bool)
- func (i *InputMediaPoll) GetSolutionEntities() (value []MessageEntityClass, ok bool)
- func (i *InputMediaPoll) SetCorrectAnswers(value [][]byte)
- func (i *InputMediaPoll) SetSolution(value string)
- func (i *InputMediaPoll) SetSolutionEntities(value []MessageEntityClass)
- func (i *InputMediaPoll) String() string
- type InputMediaUploadedDocument
- func (i *InputMediaUploadedDocument) Decode(b *bin.Buffer) error
- func (i *InputMediaUploadedDocument) Encode(b *bin.Buffer) error
- func (i *InputMediaUploadedDocument) GetStickers() (value []InputDocumentClass, ok bool)
- func (i *InputMediaUploadedDocument) GetTTLSeconds() (value int, ok bool)
- func (i *InputMediaUploadedDocument) GetThumb() (value InputFileClass, ok bool)
- func (i *InputMediaUploadedDocument) SetForceFile(value bool)
- func (i *InputMediaUploadedDocument) SetNosoundVideo(value bool)
- func (i *InputMediaUploadedDocument) SetStickers(value []InputDocumentClass)
- func (i *InputMediaUploadedDocument) SetTTLSeconds(value int)
- func (i *InputMediaUploadedDocument) SetThumb(value InputFileClass)
- func (i *InputMediaUploadedDocument) String() string
- type InputMediaUploadedPhoto
- func (i *InputMediaUploadedPhoto) Decode(b *bin.Buffer) error
- func (i *InputMediaUploadedPhoto) Encode(b *bin.Buffer) error
- func (i *InputMediaUploadedPhoto) GetStickers() (value []InputDocumentClass, ok bool)
- func (i *InputMediaUploadedPhoto) GetTTLSeconds() (value int, ok bool)
- func (i *InputMediaUploadedPhoto) SetStickers(value []InputDocumentClass)
- func (i *InputMediaUploadedPhoto) SetTTLSeconds(value int)
- func (i *InputMediaUploadedPhoto) String() string
- type InputMediaVenue
- type InputMessageBox
- type InputMessageCallbackQuery
- type InputMessageClass
- type InputMessageEntityMentionName
- type InputMessageID
- type InputMessagePinned
- type InputMessageReplyTo
- type InputMessagesFilterChatPhotos
- type InputMessagesFilterContacts
- type InputMessagesFilterDocument
- type InputMessagesFilterEmpty
- type InputMessagesFilterGeo
- type InputMessagesFilterGif
- type InputMessagesFilterMusic
- type InputMessagesFilterMyMentions
- type InputMessagesFilterPhoneCalls
- type InputMessagesFilterPhotoVideo
- type InputMessagesFilterPhotos
- type InputMessagesFilterPinned
- type InputMessagesFilterRoundVideo
- type InputMessagesFilterRoundVoice
- type InputMessagesFilterUrl
- type InputMessagesFilterVideo
- type InputMessagesFilterVoice
- type InputNotifyBroadcasts
- type InputNotifyChats
- type InputNotifyPeer
- type InputNotifyPeerBox
- type InputNotifyPeerClass
- type InputNotifyUsers
- type InputPaymentCredentials
- type InputPaymentCredentialsAndroidPay
- type InputPaymentCredentialsApplePay
- type InputPaymentCredentialsBox
- type InputPaymentCredentialsClass
- type InputPaymentCredentialsSaved
- type InputPeerBox
- type InputPeerChannel
- type InputPeerChannelFromMessage
- type InputPeerChat
- type InputPeerClass
- type InputPeerEmpty
- type InputPeerNotifySettings
- func (i *InputPeerNotifySettings) Decode(b *bin.Buffer) error
- func (i *InputPeerNotifySettings) Encode(b *bin.Buffer) error
- func (i *InputPeerNotifySettings) GetMuteUntil() (value int, ok bool)
- func (i *InputPeerNotifySettings) GetShowPreviews() (value bool, ok bool)
- func (i *InputPeerNotifySettings) GetSilent() (value bool, ok bool)
- func (i *InputPeerNotifySettings) GetSound() (value string, ok bool)
- func (i *InputPeerNotifySettings) SetMuteUntil(value int)
- func (i *InputPeerNotifySettings) SetShowPreviews(value bool)
- func (i *InputPeerNotifySettings) SetSilent(value bool)
- func (i *InputPeerNotifySettings) SetSound(value string)
- func (i *InputPeerNotifySettings) String() string
- type InputPeerPhotoFileLocation
- type InputPeerSelf
- type InputPeerUser
- type InputPeerUserFromMessage
- type InputPhoneCall
- type InputPhoneContact
- type InputPhoto
- type InputPhotoBox
- type InputPhotoClass
- type InputPhotoEmpty
- type InputPhotoFileLocation
- type InputPhotoLegacyFileLocation
- type InputPrivacyKeyAddedByPhone
- type InputPrivacyKeyBox
- type InputPrivacyKeyChatInvite
- type InputPrivacyKeyClass
- type InputPrivacyKeyForwards
- type InputPrivacyKeyPhoneCall
- type InputPrivacyKeyPhoneNumber
- type InputPrivacyKeyPhoneP2P
- type InputPrivacyKeyProfilePhoto
- type InputPrivacyKeyStatusTimestamp
- type InputPrivacyRuleBox
- type InputPrivacyRuleClass
- type InputPrivacyValueAllowAll
- type InputPrivacyValueAllowChatParticipants
- type InputPrivacyValueAllowContacts
- type InputPrivacyValueAllowUsers
- type InputPrivacyValueDisallowAll
- type InputPrivacyValueDisallowChatParticipants
- type InputPrivacyValueDisallowContacts
- type InputPrivacyValueDisallowUsers
- type InputReportReasonChildAbuse
- type InputReportReasonCopyright
- type InputReportReasonGeoIrrelevant
- type InputReportReasonOther
- type InputReportReasonPornography
- type InputReportReasonSpam
- type InputReportReasonViolence
- type InputSecureFile
- type InputSecureFileBox
- type InputSecureFileClass
- type InputSecureFileLocation
- type InputSecureFileUploaded
- type InputSecureValue
- func (i *InputSecureValue) Decode(b *bin.Buffer) error
- func (i *InputSecureValue) Encode(b *bin.Buffer) error
- func (i *InputSecureValue) GetData() (value SecureData, ok bool)
- func (i *InputSecureValue) GetFiles() (value []InputSecureFileClass, ok bool)
- func (i *InputSecureValue) GetFrontSide() (value InputSecureFileClass, ok bool)
- func (i *InputSecureValue) GetPlainData() (value SecurePlainDataClass, ok bool)
- func (i *InputSecureValue) GetReverseSide() (value InputSecureFileClass, ok bool)
- func (i *InputSecureValue) GetSelfie() (value InputSecureFileClass, ok bool)
- func (i *InputSecureValue) GetTranslation() (value []InputSecureFileClass, ok bool)
- func (i *InputSecureValue) SetData(value SecureData)
- func (i *InputSecureValue) SetFiles(value []InputSecureFileClass)
- func (i *InputSecureValue) SetFrontSide(value InputSecureFileClass)
- func (i *InputSecureValue) SetPlainData(value SecurePlainDataClass)
- func (i *InputSecureValue) SetReverseSide(value InputSecureFileClass)
- func (i *InputSecureValue) SetSelfie(value InputSecureFileClass)
- func (i *InputSecureValue) SetTranslation(value []InputSecureFileClass)
- func (i *InputSecureValue) String() string
- type InputSingleMedia
- type InputStickerSetAnimatedEmoji
- type InputStickerSetBox
- type InputStickerSetClass
- type InputStickerSetDice
- type InputStickerSetEmpty
- type InputStickerSetID
- type InputStickerSetItem
- type InputStickerSetShortName
- type InputStickerSetThumb
- type InputStickeredMediaBox
- type InputStickeredMediaClass
- type InputStickeredMediaDocument
- type InputStickeredMediaPhoto
- type InputTakeoutFileLocation
- type InputTheme
- type InputThemeBox
- type InputThemeClass
- type InputThemeSettings
- func (i *InputThemeSettings) Decode(b *bin.Buffer) error
- func (i *InputThemeSettings) Encode(b *bin.Buffer) error
- func (i *InputThemeSettings) GetMessageBottomColor() (value int, ok bool)
- func (i *InputThemeSettings) GetMessageTopColor() (value int, ok bool)
- func (i *InputThemeSettings) GetWallpaper() (value InputWallPaperClass, ok bool)
- func (i *InputThemeSettings) GetWallpaperSettings() (value WallPaperSettings, ok bool)
- func (i *InputThemeSettings) SetMessageBottomColor(value int)
- func (i *InputThemeSettings) SetMessageTopColor(value int)
- func (i *InputThemeSettings) SetWallpaper(value InputWallPaperClass)
- func (i *InputThemeSettings) SetWallpaperSettings(value WallPaperSettings)
- func (i *InputThemeSettings) String() string
- type InputThemeSlug
- type InputUser
- type InputUserBox
- type InputUserClass
- type InputUserEmpty
- type InputUserFromMessage
- type InputUserSelf
- type InputWallPaper
- type InputWallPaperBox
- type InputWallPaperClass
- type InputWallPaperNoFile
- type InputWallPaperSlug
- type InputWebDocument
- type InputWebFileGeoPointLocation
- type InputWebFileLocation
- type InputWebFileLocationBox
- type InputWebFileLocationClass
- type IntVector
- type Invoice
- func (i *Invoice) Decode(b *bin.Buffer) error
- func (i *Invoice) Encode(b *bin.Buffer) error
- func (i *Invoice) SetEmailRequested(value bool)
- func (i *Invoice) SetEmailToProvider(value bool)
- func (i *Invoice) SetFlexible(value bool)
- func (i *Invoice) SetNameRequested(value bool)
- func (i *Invoice) SetPhoneRequested(value bool)
- func (i *Invoice) SetPhoneToProvider(value bool)
- func (i *Invoice) SetShippingAddressRequested(value bool)
- func (i *Invoice) SetTest(value bool)
- func (i *Invoice) String() string
- type InvokeAfterMsgRequest
- type InvokeAfterMsgsRequest
- type InvokeWithLayerRequest
- type InvokeWithMessagesRangeRequest
- type InvokeWithTakeoutRequest
- type InvokeWithoutUpdatesRequest
- type Invoker
- type JSONValueBox
- type JSONValueClass
- type JsonArray
- type JsonBool
- type JsonNull
- type JsonNumber
- type JsonObject
- type JsonObjectValue
- type JsonString
- type KeyboardButton
- type KeyboardButtonBox
- type KeyboardButtonBuy
- type KeyboardButtonCallback
- type KeyboardButtonClass
- type KeyboardButtonGame
- type KeyboardButtonRequestGeoLocation
- type KeyboardButtonRequestPhone
- type KeyboardButtonRequestPoll
- func (k *KeyboardButtonRequestPoll) Decode(b *bin.Buffer) error
- func (k *KeyboardButtonRequestPoll) Encode(b *bin.Buffer) error
- func (k *KeyboardButtonRequestPoll) GetQuiz() (value bool, ok bool)
- func (k *KeyboardButtonRequestPoll) SetQuiz(value bool)
- func (k *KeyboardButtonRequestPoll) String() string
- type KeyboardButtonRow
- type KeyboardButtonSwitchInline
- type KeyboardButtonUrl
- type KeyboardButtonUrlAuth
- type LabeledPrice
- type LangPackDifference
- type LangPackHandler
- type LangPackLanguage
- func (l *LangPackLanguage) Decode(b *bin.Buffer) error
- func (l *LangPackLanguage) Encode(b *bin.Buffer) error
- func (l *LangPackLanguage) GetBaseLangCode() (value string, ok bool)
- func (l *LangPackLanguage) SetBaseLangCode(value string)
- func (l *LangPackLanguage) SetBeta(value bool)
- func (l *LangPackLanguage) SetOfficial(value bool)
- func (l *LangPackLanguage) SetRtl(value bool)
- func (l *LangPackLanguage) String() string
- type LangPackLanguageVector
- type LangPackString
- type LangPackStringBox
- type LangPackStringClass
- type LangPackStringClassVector
- type LangPackStringDeleted
- type LangPackStringPluralized
- func (l *LangPackStringPluralized) Decode(b *bin.Buffer) error
- func (l *LangPackStringPluralized) Encode(b *bin.Buffer) error
- func (l *LangPackStringPluralized) GetFewValue() (value string, ok bool)
- func (l *LangPackStringPluralized) GetManyValue() (value string, ok bool)
- func (l *LangPackStringPluralized) GetOneValue() (value string, ok bool)
- func (l *LangPackStringPluralized) GetTwoValue() (value string, ok bool)
- func (l *LangPackStringPluralized) GetZeroValue() (value string, ok bool)
- func (l *LangPackStringPluralized) SetFewValue(value string)
- func (l *LangPackStringPluralized) SetManyValue(value string)
- func (l *LangPackStringPluralized) SetOneValue(value string)
- func (l *LangPackStringPluralized) SetTwoValue(value string)
- func (l *LangPackStringPluralized) SetZeroValue(value string)
- func (l *LangPackStringPluralized) String() string
- type LangPackTooLongHandler
- type LangpackGetDifferenceRequest
- type LangpackGetLangPackRequest
- type LangpackGetLanguageRequest
- type LangpackGetLanguagesRequest
- type LangpackGetStringsRequest
- type LoginTokenHandler
- type LongVector
- type MaskCoords
- type Message
- func (m *Message) Decode(b *bin.Buffer) error
- func (m *Message) Encode(b *bin.Buffer) error
- func (m *Message) GetEditDate() (value int, ok bool)
- func (m *Message) GetEntities() (value []MessageEntityClass, ok bool)
- func (m *Message) GetForwards() (value int, ok bool)
- func (m *Message) GetFromID() (value PeerClass, ok bool)
- func (m *Message) GetFwdFrom() (value MessageFwdHeader, ok bool)
- func (m *Message) GetGroupedID() (value int64, ok bool)
- func (m *Message) GetMedia() (value MessageMediaClass, ok bool)
- func (m *Message) GetPostAuthor() (value string, ok bool)
- func (m *Message) GetReplies() (value MessageReplies, ok bool)
- func (m *Message) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (m *Message) GetReplyTo() (value MessageReplyHeader, ok bool)
- func (m *Message) GetRestrictionReason() (value []RestrictionReason, ok bool)
- func (m *Message) GetViaBotID() (value int, ok bool)
- func (m *Message) GetViews() (value int, ok bool)
- func (m *Message) SetEditDate(value int)
- func (m *Message) SetEditHide(value bool)
- func (m *Message) SetEntities(value []MessageEntityClass)
- func (m *Message) SetForwards(value int)
- func (m *Message) SetFromID(value PeerClass)
- func (m *Message) SetFromScheduled(value bool)
- func (m *Message) SetFwdFrom(value MessageFwdHeader)
- func (m *Message) SetGroupedID(value int64)
- func (m *Message) SetLegacy(value bool)
- func (m *Message) SetMedia(value MessageMediaClass)
- func (m *Message) SetMediaUnread(value bool)
- func (m *Message) SetMentioned(value bool)
- func (m *Message) SetOut(value bool)
- func (m *Message) SetPinned(value bool)
- func (m *Message) SetPost(value bool)
- func (m *Message) SetPostAuthor(value string)
- func (m *Message) SetReplies(value MessageReplies)
- func (m *Message) SetReplyMarkup(value ReplyMarkupClass)
- func (m *Message) SetReplyTo(value MessageReplyHeader)
- func (m *Message) SetRestrictionReason(value []RestrictionReason)
- func (m *Message) SetSilent(value bool)
- func (m *Message) SetViaBotID(value int)
- func (m *Message) SetViews(value int)
- func (m *Message) String() string
- type MessageActionBotAllowed
- type MessageActionBox
- type MessageActionChannelCreate
- type MessageActionChannelMigrateFrom
- type MessageActionChatAddUser
- type MessageActionChatCreate
- type MessageActionChatDeletePhoto
- type MessageActionChatDeleteUser
- type MessageActionChatEditPhoto
- type MessageActionChatEditTitle
- type MessageActionChatJoinedByLink
- type MessageActionChatMigrateTo
- type MessageActionClass
- type MessageActionContactSignUp
- type MessageActionCustomAction
- type MessageActionEmpty
- type MessageActionGameScore
- type MessageActionGeoProximityReached
- type MessageActionGroupCall
- type MessageActionHistoryClear
- type MessageActionInviteToGroupCall
- type MessageActionPaymentSent
- type MessageActionPaymentSentMe
- func (m *MessageActionPaymentSentMe) Decode(b *bin.Buffer) error
- func (m *MessageActionPaymentSentMe) Encode(b *bin.Buffer) error
- func (m *MessageActionPaymentSentMe) GetInfo() (value PaymentRequestedInfo, ok bool)
- func (m *MessageActionPaymentSentMe) GetShippingOptionID() (value string, ok bool)
- func (m *MessageActionPaymentSentMe) SetInfo(value PaymentRequestedInfo)
- func (m *MessageActionPaymentSentMe) SetShippingOptionID(value string)
- func (m *MessageActionPaymentSentMe) String() string
- type MessageActionPhoneCall
- func (m *MessageActionPhoneCall) Decode(b *bin.Buffer) error
- func (m *MessageActionPhoneCall) Encode(b *bin.Buffer) error
- func (m *MessageActionPhoneCall) GetDuration() (value int, ok bool)
- func (m *MessageActionPhoneCall) GetReason() (value PhoneCallDiscardReasonClass, ok bool)
- func (m *MessageActionPhoneCall) SetDuration(value int)
- func (m *MessageActionPhoneCall) SetReason(value PhoneCallDiscardReasonClass)
- func (m *MessageActionPhoneCall) SetVideo(value bool)
- func (m *MessageActionPhoneCall) String() string
- type MessageActionPinMessage
- type MessageActionScreenshotTaken
- type MessageActionSecureValuesSent
- type MessageActionSecureValuesSentMe
- type MessageBox
- type MessageClass
- type MessageEmpty
- type MessageEntityBankCard
- type MessageEntityBlockquote
- type MessageEntityBold
- type MessageEntityBotCommand
- type MessageEntityBox
- type MessageEntityCashtag
- type MessageEntityClass
- type MessageEntityCode
- type MessageEntityEmail
- type MessageEntityHashtag
- type MessageEntityItalic
- type MessageEntityMention
- type MessageEntityMentionName
- type MessageEntityPhone
- type MessageEntityPre
- type MessageEntityStrike
- type MessageEntityTextUrl
- type MessageEntityUnderline
- type MessageEntityUnknown
- type MessageEntityUrl
- type MessageFwdHeader
- func (m *MessageFwdHeader) Decode(b *bin.Buffer) error
- func (m *MessageFwdHeader) Encode(b *bin.Buffer) error
- func (m *MessageFwdHeader) GetChannelPost() (value int, ok bool)
- func (m *MessageFwdHeader) GetFromID() (value PeerClass, ok bool)
- func (m *MessageFwdHeader) GetFromName() (value string, ok bool)
- func (m *MessageFwdHeader) GetPostAuthor() (value string, ok bool)
- func (m *MessageFwdHeader) GetPsaType() (value string, ok bool)
- func (m *MessageFwdHeader) GetSavedFromMsgID() (value int, ok bool)
- func (m *MessageFwdHeader) GetSavedFromPeer() (value PeerClass, ok bool)
- func (m *MessageFwdHeader) SetChannelPost(value int)
- func (m *MessageFwdHeader) SetFromID(value PeerClass)
- func (m *MessageFwdHeader) SetFromName(value string)
- func (m *MessageFwdHeader) SetPostAuthor(value string)
- func (m *MessageFwdHeader) SetPsaType(value string)
- func (m *MessageFwdHeader) SetSavedFromMsgID(value int)
- func (m *MessageFwdHeader) SetSavedFromPeer(value PeerClass)
- func (m *MessageFwdHeader) String() string
- type MessageIDHandler
- type MessageInteractionCounters
- type MessageMediaBox
- type MessageMediaClass
- type MessageMediaContact
- type MessageMediaDice
- type MessageMediaDocument
- func (m *MessageMediaDocument) Decode(b *bin.Buffer) error
- func (m *MessageMediaDocument) Encode(b *bin.Buffer) error
- func (m *MessageMediaDocument) GetDocument() (value DocumentClass, ok bool)
- func (m *MessageMediaDocument) GetTTLSeconds() (value int, ok bool)
- func (m *MessageMediaDocument) SetDocument(value DocumentClass)
- func (m *MessageMediaDocument) SetTTLSeconds(value int)
- func (m *MessageMediaDocument) String() string
- type MessageMediaEmpty
- type MessageMediaGame
- type MessageMediaGeo
- type MessageMediaGeoLive
- func (m *MessageMediaGeoLive) Decode(b *bin.Buffer) error
- func (m *MessageMediaGeoLive) Encode(b *bin.Buffer) error
- func (m *MessageMediaGeoLive) GetHeading() (value int, ok bool)
- func (m *MessageMediaGeoLive) GetProximityNotificationRadius() (value int, ok bool)
- func (m *MessageMediaGeoLive) SetHeading(value int)
- func (m *MessageMediaGeoLive) SetProximityNotificationRadius(value int)
- func (m *MessageMediaGeoLive) String() string
- type MessageMediaInvoice
- func (m *MessageMediaInvoice) Decode(b *bin.Buffer) error
- func (m *MessageMediaInvoice) Encode(b *bin.Buffer) error
- func (m *MessageMediaInvoice) GetPhoto() (value WebDocumentClass, ok bool)
- func (m *MessageMediaInvoice) GetReceiptMsgID() (value int, ok bool)
- func (m *MessageMediaInvoice) SetPhoto(value WebDocumentClass)
- func (m *MessageMediaInvoice) SetReceiptMsgID(value int)
- func (m *MessageMediaInvoice) SetShippingAddressRequested(value bool)
- func (m *MessageMediaInvoice) SetTest(value bool)
- func (m *MessageMediaInvoice) String() string
- type MessageMediaPhoto
- func (m *MessageMediaPhoto) Decode(b *bin.Buffer) error
- func (m *MessageMediaPhoto) Encode(b *bin.Buffer) error
- func (m *MessageMediaPhoto) GetPhoto() (value PhotoClass, ok bool)
- func (m *MessageMediaPhoto) GetTTLSeconds() (value int, ok bool)
- func (m *MessageMediaPhoto) SetPhoto(value PhotoClass)
- func (m *MessageMediaPhoto) SetTTLSeconds(value int)
- func (m *MessageMediaPhoto) String() string
- type MessageMediaPoll
- type MessageMediaUnsupported
- type MessageMediaVenue
- type MessageMediaWebPage
- type MessagePollHandler
- type MessagePollVoteHandler
- type MessageRange
- type MessageRangeVector
- type MessageReplies
- func (m *MessageReplies) Decode(b *bin.Buffer) error
- func (m *MessageReplies) Encode(b *bin.Buffer) error
- func (m *MessageReplies) GetChannelID() (value int, ok bool)
- func (m *MessageReplies) GetMaxID() (value int, ok bool)
- func (m *MessageReplies) GetReadMaxID() (value int, ok bool)
- func (m *MessageReplies) GetRecentRepliers() (value []PeerClass, ok bool)
- func (m *MessageReplies) SetChannelID(value int)
- func (m *MessageReplies) SetComments(value bool)
- func (m *MessageReplies) SetMaxID(value int)
- func (m *MessageReplies) SetReadMaxID(value int)
- func (m *MessageReplies) SetRecentRepliers(value []PeerClass)
- func (m *MessageReplies) String() string
- type MessageReplyHeader
- func (m *MessageReplyHeader) Decode(b *bin.Buffer) error
- func (m *MessageReplyHeader) Encode(b *bin.Buffer) error
- func (m *MessageReplyHeader) GetReplyToPeerID() (value PeerClass, ok bool)
- func (m *MessageReplyHeader) GetReplyToTopID() (value int, ok bool)
- func (m *MessageReplyHeader) SetReplyToPeerID(value PeerClass)
- func (m *MessageReplyHeader) SetReplyToTopID(value int)
- func (m *MessageReplyHeader) String() string
- type MessageService
- func (m *MessageService) Decode(b *bin.Buffer) error
- func (m *MessageService) Encode(b *bin.Buffer) error
- func (m *MessageService) GetFromID() (value PeerClass, ok bool)
- func (m *MessageService) GetReplyTo() (value MessageReplyHeader, ok bool)
- func (m *MessageService) SetFromID(value PeerClass)
- func (m *MessageService) SetLegacy(value bool)
- func (m *MessageService) SetMediaUnread(value bool)
- func (m *MessageService) SetMentioned(value bool)
- func (m *MessageService) SetOut(value bool)
- func (m *MessageService) SetPost(value bool)
- func (m *MessageService) SetReplyTo(value MessageReplyHeader)
- func (m *MessageService) SetSilent(value bool)
- func (m *MessageService) String() string
- type MessageUserVote
- type MessageUserVoteBox
- type MessageUserVoteClass
- type MessageUserVoteInputOption
- type MessageUserVoteMultiple
- type MessageViews
- func (m *MessageViews) Decode(b *bin.Buffer) error
- func (m *MessageViews) Encode(b *bin.Buffer) error
- func (m *MessageViews) GetForwards() (value int, ok bool)
- func (m *MessageViews) GetReplies() (value MessageReplies, ok bool)
- func (m *MessageViews) GetViews() (value int, ok bool)
- func (m *MessageViews) SetForwards(value int)
- func (m *MessageViews) SetReplies(value MessageReplies)
- func (m *MessageViews) SetViews(value int)
- func (m *MessageViews) String() string
- type MessagesAcceptEncryptionRequest
- type MessagesAcceptUrlAuthRequest
- type MessagesAddChatUserRequest
- type MessagesAffectedHistory
- type MessagesAffectedMessages
- type MessagesAllStickers
- type MessagesAllStickersBox
- type MessagesAllStickersClass
- type MessagesAllStickersNotModified
- type MessagesArchivedStickers
- type MessagesBotCallbackAnswer
- func (b *MessagesBotCallbackAnswer) Decode(buf *bin.Buffer) error
- func (b *MessagesBotCallbackAnswer) Encode(buf *bin.Buffer) error
- func (b *MessagesBotCallbackAnswer) GetMessage() (value string, ok bool)
- func (b *MessagesBotCallbackAnswer) GetURL() (value string, ok bool)
- func (b *MessagesBotCallbackAnswer) SetAlert(value bool)
- func (b *MessagesBotCallbackAnswer) SetHasURL(value bool)
- func (b *MessagesBotCallbackAnswer) SetMessage(value string)
- func (b *MessagesBotCallbackAnswer) SetNativeUI(value bool)
- func (b *MessagesBotCallbackAnswer) SetURL(value string)
- func (b *MessagesBotCallbackAnswer) String() string
- type MessagesBotResults
- func (b *MessagesBotResults) Decode(buf *bin.Buffer) error
- func (b *MessagesBotResults) Encode(buf *bin.Buffer) error
- func (b *MessagesBotResults) GetNextOffset() (value string, ok bool)
- func (b *MessagesBotResults) GetSwitchPm() (value InlineBotSwitchPM, ok bool)
- func (b *MessagesBotResults) SetGallery(value bool)
- func (b *MessagesBotResults) SetNextOffset(value string)
- func (b *MessagesBotResults) SetSwitchPm(value InlineBotSwitchPM)
- func (b *MessagesBotResults) String() string
- type MessagesChannelMessages
- func (c *MessagesChannelMessages) Decode(b *bin.Buffer) error
- func (c *MessagesChannelMessages) Encode(b *bin.Buffer) error
- func (c *MessagesChannelMessages) GetOffsetIDOffset() (value int, ok bool)
- func (c *MessagesChannelMessages) SetInexact(value bool)
- func (c *MessagesChannelMessages) SetOffsetIDOffset(value int)
- func (c *MessagesChannelMessages) String() string
- type MessagesChatFull
- type MessagesChats
- type MessagesChatsBox
- type MessagesChatsClass
- type MessagesChatsSlice
- type MessagesCheckChatInviteRequest
- type MessagesClearAllDraftsRequest
- type MessagesClearRecentStickersRequest
- type MessagesCreateChatRequest
- type MessagesDeleteChatUserRequest
- type MessagesDeleteHistoryRequest
- func (d *MessagesDeleteHistoryRequest) Decode(b *bin.Buffer) error
- func (d *MessagesDeleteHistoryRequest) Encode(b *bin.Buffer) error
- func (d *MessagesDeleteHistoryRequest) SetJustClear(value bool)
- func (d *MessagesDeleteHistoryRequest) SetRevoke(value bool)
- func (d *MessagesDeleteHistoryRequest) String() string
- type MessagesDeleteMessagesRequest
- type MessagesDeleteScheduledMessagesRequest
- type MessagesDhConfig
- type MessagesDhConfigBox
- type MessagesDhConfigClass
- type MessagesDhConfigNotModified
- type MessagesDialogs
- type MessagesDialogsBox
- type MessagesDialogsClass
- type MessagesDialogsNotModified
- type MessagesDialogsSlice
- type MessagesDiscardEncryptionRequest
- type MessagesDiscussionMessage
- func (d *MessagesDiscussionMessage) Decode(b *bin.Buffer) error
- func (d *MessagesDiscussionMessage) Encode(b *bin.Buffer) error
- func (d *MessagesDiscussionMessage) GetMaxID() (value int, ok bool)
- func (d *MessagesDiscussionMessage) GetReadInboxMaxID() (value int, ok bool)
- func (d *MessagesDiscussionMessage) GetReadOutboxMaxID() (value int, ok bool)
- func (d *MessagesDiscussionMessage) SetMaxID(value int)
- func (d *MessagesDiscussionMessage) SetReadInboxMaxID(value int)
- func (d *MessagesDiscussionMessage) SetReadOutboxMaxID(value int)
- func (d *MessagesDiscussionMessage) String() string
- type MessagesEditChatAboutRequest
- type MessagesEditChatAdminRequest
- type MessagesEditChatDefaultBannedRightsRequest
- type MessagesEditChatPhotoRequest
- type MessagesEditChatTitleRequest
- type MessagesEditInlineBotMessageRequest
- func (e *MessagesEditInlineBotMessageRequest) Decode(b *bin.Buffer) error
- func (e *MessagesEditInlineBotMessageRequest) Encode(b *bin.Buffer) error
- func (e *MessagesEditInlineBotMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (e *MessagesEditInlineBotMessageRequest) GetMedia() (value InputMediaClass, ok bool)
- func (e *MessagesEditInlineBotMessageRequest) GetMessage() (value string, ok bool)
- func (e *MessagesEditInlineBotMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (e *MessagesEditInlineBotMessageRequest) SetEntities(value []MessageEntityClass)
- func (e *MessagesEditInlineBotMessageRequest) SetMedia(value InputMediaClass)
- func (e *MessagesEditInlineBotMessageRequest) SetMessage(value string)
- func (e *MessagesEditInlineBotMessageRequest) SetNoWebpage(value bool)
- func (e *MessagesEditInlineBotMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
- func (e *MessagesEditInlineBotMessageRequest) String() string
- type MessagesEditMessageRequest
- func (e *MessagesEditMessageRequest) Decode(b *bin.Buffer) error
- func (e *MessagesEditMessageRequest) Encode(b *bin.Buffer) error
- func (e *MessagesEditMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (e *MessagesEditMessageRequest) GetMedia() (value InputMediaClass, ok bool)
- func (e *MessagesEditMessageRequest) GetMessage() (value string, ok bool)
- func (e *MessagesEditMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (e *MessagesEditMessageRequest) GetScheduleDate() (value int, ok bool)
- func (e *MessagesEditMessageRequest) SetEntities(value []MessageEntityClass)
- func (e *MessagesEditMessageRequest) SetMedia(value InputMediaClass)
- func (e *MessagesEditMessageRequest) SetMessage(value string)
- func (e *MessagesEditMessageRequest) SetNoWebpage(value bool)
- func (e *MessagesEditMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
- func (e *MessagesEditMessageRequest) SetScheduleDate(value int)
- func (e *MessagesEditMessageRequest) String() string
- type MessagesExportChatInviteRequest
- type MessagesFaveStickerRequest
- type MessagesFavedStickers
- type MessagesFavedStickersBox
- type MessagesFavedStickersClass
- type MessagesFavedStickersNotModified
- type MessagesFeaturedStickers
- type MessagesFeaturedStickersBox
- type MessagesFeaturedStickersClass
- type MessagesFeaturedStickersNotModified
- type MessagesFilterBox
- type MessagesFilterClass
- type MessagesForwardMessagesRequest
- func (f *MessagesForwardMessagesRequest) Decode(b *bin.Buffer) error
- func (f *MessagesForwardMessagesRequest) Encode(b *bin.Buffer) error
- func (f *MessagesForwardMessagesRequest) GetScheduleDate() (value int, ok bool)
- func (f *MessagesForwardMessagesRequest) SetBackground(value bool)
- func (f *MessagesForwardMessagesRequest) SetScheduleDate(value int)
- func (f *MessagesForwardMessagesRequest) SetSilent(value bool)
- func (f *MessagesForwardMessagesRequest) SetWithMyScore(value bool)
- func (f *MessagesForwardMessagesRequest) String() string
- type MessagesFoundStickerSets
- type MessagesFoundStickerSetsBox
- type MessagesFoundStickerSetsClass
- type MessagesFoundStickerSetsNotModified
- type MessagesGetAllChatsRequest
- type MessagesGetAllDraftsRequest
- type MessagesGetAllStickersRequest
- type MessagesGetArchivedStickersRequest
- type MessagesGetAttachedStickersRequest
- type MessagesGetBotCallbackAnswerRequest
- func (g *MessagesGetBotCallbackAnswerRequest) Decode(b *bin.Buffer) error
- func (g *MessagesGetBotCallbackAnswerRequest) Encode(b *bin.Buffer) error
- func (g *MessagesGetBotCallbackAnswerRequest) GetData() (value []byte, ok bool)
- func (g *MessagesGetBotCallbackAnswerRequest) GetPassword() (value InputCheckPasswordSRPClass, ok bool)
- func (g *MessagesGetBotCallbackAnswerRequest) SetData(value []byte)
- func (g *MessagesGetBotCallbackAnswerRequest) SetGame(value bool)
- func (g *MessagesGetBotCallbackAnswerRequest) SetPassword(value InputCheckPasswordSRPClass)
- func (g *MessagesGetBotCallbackAnswerRequest) String() string
- type MessagesGetChatsRequest
- type MessagesGetCommonChatsRequest
- type MessagesGetDhConfigRequest
- type MessagesGetDialogFiltersRequest
- type MessagesGetDialogUnreadMarksRequest
- type MessagesGetDialogsRequest
- func (g *MessagesGetDialogsRequest) Decode(b *bin.Buffer) error
- func (g *MessagesGetDialogsRequest) Encode(b *bin.Buffer) error
- func (g *MessagesGetDialogsRequest) GetFolderID() (value int, ok bool)
- func (g *MessagesGetDialogsRequest) SetExcludePinned(value bool)
- func (g *MessagesGetDialogsRequest) SetFolderID(value int)
- func (g *MessagesGetDialogsRequest) String() string
- type MessagesGetDiscussionMessageRequest
- type MessagesGetDocumentByHashRequest
- type MessagesGetEmojiKeywordsDifferenceRequest
- type MessagesGetEmojiKeywordsLanguagesRequest
- type MessagesGetEmojiKeywordsRequest
- type MessagesGetEmojiURLRequest
- type MessagesGetFavedStickersRequest
- type MessagesGetFeaturedStickersRequest
- type MessagesGetFullChatRequest
- type MessagesGetGameHighScoresRequest
- type MessagesGetHistoryRequest
- type MessagesGetInlineBotResultsRequest
- func (g *MessagesGetInlineBotResultsRequest) Decode(b *bin.Buffer) error
- func (g *MessagesGetInlineBotResultsRequest) Encode(b *bin.Buffer) error
- func (g *MessagesGetInlineBotResultsRequest) GetGeoPoint() (value InputGeoPointClass, ok bool)
- func (g *MessagesGetInlineBotResultsRequest) SetGeoPoint(value InputGeoPointClass)
- func (g *MessagesGetInlineBotResultsRequest) String() string
- type MessagesGetInlineGameHighScoresRequest
- type MessagesGetMaskStickersRequest
- type MessagesGetMessageEditDataRequest
- type MessagesGetMessagesRequest
- type MessagesGetMessagesViewsRequest
- type MessagesGetOldFeaturedStickersRequest
- type MessagesGetOnlinesRequest
- type MessagesGetPeerDialogsRequest
- type MessagesGetPeerSettingsRequest
- type MessagesGetPinnedDialogsRequest
- type MessagesGetPollResultsRequest
- type MessagesGetPollVotesRequest
- func (g *MessagesGetPollVotesRequest) Decode(b *bin.Buffer) error
- func (g *MessagesGetPollVotesRequest) Encode(b *bin.Buffer) error
- func (g *MessagesGetPollVotesRequest) GetOffset() (value string, ok bool)
- func (g *MessagesGetPollVotesRequest) GetOption() (value []byte, ok bool)
- func (g *MessagesGetPollVotesRequest) SetOffset(value string)
- func (g *MessagesGetPollVotesRequest) SetOption(value []byte)
- func (g *MessagesGetPollVotesRequest) String() string
- type MessagesGetRecentLocationsRequest
- type MessagesGetRecentStickersRequest
- type MessagesGetRepliesRequest
- type MessagesGetSavedGifsRequest
- type MessagesGetScheduledHistoryRequest
- type MessagesGetScheduledMessagesRequest
- type MessagesGetSearchCountersRequest
- type MessagesGetSplitRangesRequest
- type MessagesGetStatsURLRequest
- type MessagesGetStickerSetRequest
- type MessagesGetStickersRequest
- type MessagesGetSuggestedDialogFiltersRequest
- type MessagesGetUnreadMentionsRequest
- type MessagesGetWebPagePreviewRequest
- func (g *MessagesGetWebPagePreviewRequest) Decode(b *bin.Buffer) error
- func (g *MessagesGetWebPagePreviewRequest) Encode(b *bin.Buffer) error
- func (g *MessagesGetWebPagePreviewRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (g *MessagesGetWebPagePreviewRequest) SetEntities(value []MessageEntityClass)
- func (g *MessagesGetWebPagePreviewRequest) String() string
- type MessagesGetWebPageRequest
- type MessagesHidePeerSettingsBarRequest
- type MessagesHighScores
- type MessagesImportChatInviteRequest
- type MessagesInactiveChats
- type MessagesInstallStickerSetRequest
- type MessagesMarkDialogUnreadRequest
- type MessagesMessageEditData
- type MessagesMessageViews
- type MessagesMessages
- type MessagesMessagesBox
- type MessagesMessagesClass
- type MessagesMessagesNotModified
- type MessagesMessagesSlice
- func (m *MessagesMessagesSlice) Decode(b *bin.Buffer) error
- func (m *MessagesMessagesSlice) Encode(b *bin.Buffer) error
- func (m *MessagesMessagesSlice) GetNextRate() (value int, ok bool)
- func (m *MessagesMessagesSlice) GetOffsetIDOffset() (value int, ok bool)
- func (m *MessagesMessagesSlice) SetInexact(value bool)
- func (m *MessagesMessagesSlice) SetNextRate(value int)
- func (m *MessagesMessagesSlice) SetOffsetIDOffset(value int)
- func (m *MessagesMessagesSlice) String() string
- type MessagesMigrateChatRequest
- type MessagesPeerDialogs
- type MessagesReadDiscussionRequest
- type MessagesReadEncryptedHistoryRequest
- type MessagesReadFeaturedStickersRequest
- type MessagesReadHistoryRequest
- type MessagesReadMentionsRequest
- type MessagesReadMessageContentsRequest
- type MessagesReceivedMessagesRequest
- type MessagesReceivedQueueRequest
- type MessagesRecentStickers
- type MessagesRecentStickersBox
- type MessagesRecentStickersClass
- type MessagesRecentStickersNotModified
- type MessagesReorderPinnedDialogsRequest
- type MessagesReorderStickerSetsRequest
- type MessagesReportEncryptedSpamRequest
- type MessagesReportRequest
- type MessagesReportSpamRequest
- type MessagesRequestEncryptionRequest
- type MessagesRequestUrlAuthRequest
- type MessagesSaveDraftRequest
- func (s *MessagesSaveDraftRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSaveDraftRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSaveDraftRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (s *MessagesSaveDraftRequest) GetReplyToMsgID() (value int, ok bool)
- func (s *MessagesSaveDraftRequest) SetEntities(value []MessageEntityClass)
- func (s *MessagesSaveDraftRequest) SetNoWebpage(value bool)
- func (s *MessagesSaveDraftRequest) SetReplyToMsgID(value int)
- func (s *MessagesSaveDraftRequest) String() string
- type MessagesSaveGifRequest
- type MessagesSaveRecentStickerRequest
- type MessagesSavedGifs
- type MessagesSavedGifsBox
- type MessagesSavedGifsClass
- type MessagesSavedGifsNotModified
- type MessagesSearchCounter
- type MessagesSearchCounterVector
- type MessagesSearchGlobalRequest
- func (s *MessagesSearchGlobalRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSearchGlobalRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSearchGlobalRequest) GetFolderID() (value int, ok bool)
- func (s *MessagesSearchGlobalRequest) SetFolderID(value int)
- func (s *MessagesSearchGlobalRequest) String() string
- type MessagesSearchRequest
- func (s *MessagesSearchRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSearchRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSearchRequest) GetFromID() (value InputPeerClass, ok bool)
- func (s *MessagesSearchRequest) GetTopMsgID() (value int, ok bool)
- func (s *MessagesSearchRequest) SetFromID(value InputPeerClass)
- func (s *MessagesSearchRequest) SetTopMsgID(value int)
- func (s *MessagesSearchRequest) String() string
- type MessagesSearchStickerSetsRequest
- type MessagesSendEncryptedFileRequest
- type MessagesSendEncryptedRequest
- type MessagesSendEncryptedServiceRequest
- type MessagesSendInlineBotResultRequest
- func (s *MessagesSendInlineBotResultRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSendInlineBotResultRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSendInlineBotResultRequest) GetReplyToMsgID() (value int, ok bool)
- func (s *MessagesSendInlineBotResultRequest) GetScheduleDate() (value int, ok bool)
- func (s *MessagesSendInlineBotResultRequest) SetBackground(value bool)
- func (s *MessagesSendInlineBotResultRequest) SetClearDraft(value bool)
- func (s *MessagesSendInlineBotResultRequest) SetHideVia(value bool)
- func (s *MessagesSendInlineBotResultRequest) SetReplyToMsgID(value int)
- func (s *MessagesSendInlineBotResultRequest) SetScheduleDate(value int)
- func (s *MessagesSendInlineBotResultRequest) SetSilent(value bool)
- func (s *MessagesSendInlineBotResultRequest) String() string
- type MessagesSendMediaRequest
- func (s *MessagesSendMediaRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSendMediaRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSendMediaRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (s *MessagesSendMediaRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (s *MessagesSendMediaRequest) GetReplyToMsgID() (value int, ok bool)
- func (s *MessagesSendMediaRequest) GetScheduleDate() (value int, ok bool)
- func (s *MessagesSendMediaRequest) SetBackground(value bool)
- func (s *MessagesSendMediaRequest) SetClearDraft(value bool)
- func (s *MessagesSendMediaRequest) SetEntities(value []MessageEntityClass)
- func (s *MessagesSendMediaRequest) SetReplyMarkup(value ReplyMarkupClass)
- func (s *MessagesSendMediaRequest) SetReplyToMsgID(value int)
- func (s *MessagesSendMediaRequest) SetScheduleDate(value int)
- func (s *MessagesSendMediaRequest) SetSilent(value bool)
- func (s *MessagesSendMediaRequest) String() string
- type MessagesSendMessageRequest
- func (s *MessagesSendMessageRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSendMessageRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSendMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
- func (s *MessagesSendMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
- func (s *MessagesSendMessageRequest) GetReplyToMsgID() (value int, ok bool)
- func (s *MessagesSendMessageRequest) GetScheduleDate() (value int, ok bool)
- func (s *MessagesSendMessageRequest) SetBackground(value bool)
- func (s *MessagesSendMessageRequest) SetClearDraft(value bool)
- func (s *MessagesSendMessageRequest) SetEntities(value []MessageEntityClass)
- func (s *MessagesSendMessageRequest) SetNoWebpage(value bool)
- func (s *MessagesSendMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
- func (s *MessagesSendMessageRequest) SetReplyToMsgID(value int)
- func (s *MessagesSendMessageRequest) SetScheduleDate(value int)
- func (s *MessagesSendMessageRequest) SetSilent(value bool)
- func (s *MessagesSendMessageRequest) String() string
- type MessagesSendMultiMediaRequest
- func (s *MessagesSendMultiMediaRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSendMultiMediaRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSendMultiMediaRequest) GetReplyToMsgID() (value int, ok bool)
- func (s *MessagesSendMultiMediaRequest) GetScheduleDate() (value int, ok bool)
- func (s *MessagesSendMultiMediaRequest) SetBackground(value bool)
- func (s *MessagesSendMultiMediaRequest) SetClearDraft(value bool)
- func (s *MessagesSendMultiMediaRequest) SetReplyToMsgID(value int)
- func (s *MessagesSendMultiMediaRequest) SetScheduleDate(value int)
- func (s *MessagesSendMultiMediaRequest) SetSilent(value bool)
- func (s *MessagesSendMultiMediaRequest) String() string
- type MessagesSendScheduledMessagesRequest
- type MessagesSendScreenshotNotificationRequest
- type MessagesSendVoteRequest
- type MessagesSentEncryptedFile
- type MessagesSentEncryptedMessage
- type MessagesSentEncryptedMessageBox
- type MessagesSentEncryptedMessageClass
- type MessagesSetBotCallbackAnswerRequest
- func (s *MessagesSetBotCallbackAnswerRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetBotCallbackAnswerRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetBotCallbackAnswerRequest) GetMessage() (value string, ok bool)
- func (s *MessagesSetBotCallbackAnswerRequest) GetURL() (value string, ok bool)
- func (s *MessagesSetBotCallbackAnswerRequest) SetAlert(value bool)
- func (s *MessagesSetBotCallbackAnswerRequest) SetMessage(value string)
- func (s *MessagesSetBotCallbackAnswerRequest) SetURL(value string)
- func (s *MessagesSetBotCallbackAnswerRequest) String() string
- type MessagesSetBotPrecheckoutResultsRequest
- func (s *MessagesSetBotPrecheckoutResultsRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetBotPrecheckoutResultsRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetBotPrecheckoutResultsRequest) GetError() (value string, ok bool)
- func (s *MessagesSetBotPrecheckoutResultsRequest) SetError(value string)
- func (s *MessagesSetBotPrecheckoutResultsRequest) SetSuccess(value bool)
- func (s *MessagesSetBotPrecheckoutResultsRequest) String() string
- type MessagesSetBotShippingResultsRequest
- func (s *MessagesSetBotShippingResultsRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetBotShippingResultsRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetBotShippingResultsRequest) GetError() (value string, ok bool)
- func (s *MessagesSetBotShippingResultsRequest) GetShippingOptions() (value []ShippingOption, ok bool)
- func (s *MessagesSetBotShippingResultsRequest) SetError(value string)
- func (s *MessagesSetBotShippingResultsRequest) SetShippingOptions(value []ShippingOption)
- func (s *MessagesSetBotShippingResultsRequest) String() string
- type MessagesSetEncryptedTypingRequest
- type MessagesSetGameScoreRequest
- func (s *MessagesSetGameScoreRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetGameScoreRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetGameScoreRequest) SetEditMessage(value bool)
- func (s *MessagesSetGameScoreRequest) SetForce(value bool)
- func (s *MessagesSetGameScoreRequest) String() string
- type MessagesSetInlineBotResultsRequest
- func (s *MessagesSetInlineBotResultsRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetInlineBotResultsRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetInlineBotResultsRequest) GetNextOffset() (value string, ok bool)
- func (s *MessagesSetInlineBotResultsRequest) GetSwitchPm() (value InlineBotSwitchPM, ok bool)
- func (s *MessagesSetInlineBotResultsRequest) SetGallery(value bool)
- func (s *MessagesSetInlineBotResultsRequest) SetNextOffset(value string)
- func (s *MessagesSetInlineBotResultsRequest) SetPrivate(value bool)
- func (s *MessagesSetInlineBotResultsRequest) SetSwitchPm(value InlineBotSwitchPM)
- func (s *MessagesSetInlineBotResultsRequest) String() string
- type MessagesSetInlineGameScoreRequest
- func (s *MessagesSetInlineGameScoreRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetInlineGameScoreRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetInlineGameScoreRequest) SetEditMessage(value bool)
- func (s *MessagesSetInlineGameScoreRequest) SetForce(value bool)
- func (s *MessagesSetInlineGameScoreRequest) String() string
- type MessagesSetTypingRequest
- func (s *MessagesSetTypingRequest) Decode(b *bin.Buffer) error
- func (s *MessagesSetTypingRequest) Encode(b *bin.Buffer) error
- func (s *MessagesSetTypingRequest) GetTopMsgID() (value int, ok bool)
- func (s *MessagesSetTypingRequest) SetTopMsgID(value int)
- func (s *MessagesSetTypingRequest) String() string
- type MessagesStartBotRequest
- type MessagesStickerSet
- type MessagesStickerSetInstallResultArchive
- type MessagesStickerSetInstallResultBox
- type MessagesStickerSetInstallResultClass
- type MessagesStickerSetInstallResultSuccess
- type MessagesStickers
- type MessagesStickersBox
- type MessagesStickersClass
- type MessagesStickersNotModified
- type MessagesToggleDialogPinRequest
- type MessagesToggleStickerSetsRequest
- func (t *MessagesToggleStickerSetsRequest) Decode(b *bin.Buffer) error
- func (t *MessagesToggleStickerSetsRequest) Encode(b *bin.Buffer) error
- func (t *MessagesToggleStickerSetsRequest) SetArchive(value bool)
- func (t *MessagesToggleStickerSetsRequest) SetUnarchive(value bool)
- func (t *MessagesToggleStickerSetsRequest) SetUninstall(value bool)
- func (t *MessagesToggleStickerSetsRequest) String() string
- type MessagesUninstallStickerSetRequest
- type MessagesUnpinAllMessagesRequest
- type MessagesUpdateDialogFilterRequest
- func (u *MessagesUpdateDialogFilterRequest) Decode(b *bin.Buffer) error
- func (u *MessagesUpdateDialogFilterRequest) Encode(b *bin.Buffer) error
- func (u *MessagesUpdateDialogFilterRequest) GetFilter() (value DialogFilter, ok bool)
- func (u *MessagesUpdateDialogFilterRequest) SetFilter(value DialogFilter)
- func (u *MessagesUpdateDialogFilterRequest) String() string
- type MessagesUpdateDialogFiltersOrderRequest
- type MessagesUpdatePinnedMessageRequest
- func (u *MessagesUpdatePinnedMessageRequest) Decode(b *bin.Buffer) error
- func (u *MessagesUpdatePinnedMessageRequest) Encode(b *bin.Buffer) error
- func (u *MessagesUpdatePinnedMessageRequest) SetPmOneside(value bool)
- func (u *MessagesUpdatePinnedMessageRequest) SetSilent(value bool)
- func (u *MessagesUpdatePinnedMessageRequest) SetUnpin(value bool)
- func (u *MessagesUpdatePinnedMessageRequest) String() string
- type MessagesUploadEncryptedFileRequest
- type MessagesUploadMediaRequest
- type MessagesVotesList
- type NearestDc
- type NewChannelMessageHandler
- type NewEncryptedMessageHandler
- type NewMessageHandler
- type NewScheduledMessageHandler
- type NewStickerSetHandler
- type NotifyBroadcasts
- type NotifyChats
- type NotifyPeer
- type NotifyPeerBox
- type NotifyPeerClass
- type NotifySettingsHandler
- type NotifyUsers
- type Null
- type Page
- func (p *Page) Decode(b *bin.Buffer) error
- func (p *Page) Encode(b *bin.Buffer) error
- func (p *Page) GetViews() (value int, ok bool)
- func (p *Page) SetPart(value bool)
- func (p *Page) SetRtl(value bool)
- func (p *Page) SetV2(value bool)
- func (p *Page) SetViews(value int)
- func (p *Page) String() string
- type PageBlockAnchor
- type PageBlockAudio
- type PageBlockAuthorDate
- type PageBlockBlockquote
- type PageBlockBox
- type PageBlockChannel
- type PageBlockClass
- type PageBlockCollage
- type PageBlockCover
- type PageBlockDetails
- type PageBlockDivider
- type PageBlockEmbed
- func (p *PageBlockEmbed) Decode(b *bin.Buffer) error
- func (p *PageBlockEmbed) Encode(b *bin.Buffer) error
- func (p *PageBlockEmbed) GetH() (value int, ok bool)
- func (p *PageBlockEmbed) GetHTML() (value string, ok bool)
- func (p *PageBlockEmbed) GetPosterPhotoID() (value int64, ok bool)
- func (p *PageBlockEmbed) GetURL() (value string, ok bool)
- func (p *PageBlockEmbed) GetW() (value int, ok bool)
- func (p *PageBlockEmbed) SetAllowScrolling(value bool)
- func (p *PageBlockEmbed) SetFullWidth(value bool)
- func (p *PageBlockEmbed) SetH(value int)
- func (p *PageBlockEmbed) SetHTML(value string)
- func (p *PageBlockEmbed) SetPosterPhotoID(value int64)
- func (p *PageBlockEmbed) SetURL(value string)
- func (p *PageBlockEmbed) SetW(value int)
- func (p *PageBlockEmbed) String() string
- type PageBlockEmbedPost
- type PageBlockFooter
- type PageBlockHeader
- type PageBlockKicker
- type PageBlockList
- type PageBlockMap
- type PageBlockOrderedList
- type PageBlockParagraph
- type PageBlockPhoto
- func (p *PageBlockPhoto) Decode(b *bin.Buffer) error
- func (p *PageBlockPhoto) Encode(b *bin.Buffer) error
- func (p *PageBlockPhoto) GetURL() (value string, ok bool)
- func (p *PageBlockPhoto) GetWebpageID() (value int64, ok bool)
- func (p *PageBlockPhoto) SetURL(value string)
- func (p *PageBlockPhoto) SetWebpageID(value int64)
- func (p *PageBlockPhoto) String() string
- type PageBlockPreformatted
- type PageBlockPullquote
- type PageBlockRelatedArticles
- type PageBlockSlideshow
- type PageBlockSubheader
- type PageBlockSubtitle
- type PageBlockTable
- type PageBlockTitle
- type PageBlockUnsupported
- type PageBlockVideo
- type PageCaption
- type PageListItemBlocks
- type PageListItemBox
- type PageListItemClass
- type PageListItemText
- type PageListOrderedItemBlocks
- type PageListOrderedItemBox
- type PageListOrderedItemClass
- type PageListOrderedItemText
- type PageRelatedArticle
- func (p *PageRelatedArticle) Decode(b *bin.Buffer) error
- func (p *PageRelatedArticle) Encode(b *bin.Buffer) error
- func (p *PageRelatedArticle) GetAuthor() (value string, ok bool)
- func (p *PageRelatedArticle) GetDescription() (value string, ok bool)
- func (p *PageRelatedArticle) GetPhotoID() (value int64, ok bool)
- func (p *PageRelatedArticle) GetPublishedDate() (value int, ok bool)
- func (p *PageRelatedArticle) GetTitle() (value string, ok bool)
- func (p *PageRelatedArticle) SetAuthor(value string)
- func (p *PageRelatedArticle) SetDescription(value string)
- func (p *PageRelatedArticle) SetPhotoID(value int64)
- func (p *PageRelatedArticle) SetPublishedDate(value int)
- func (p *PageRelatedArticle) SetTitle(value string)
- func (p *PageRelatedArticle) String() string
- type PageTableCell
- func (p *PageTableCell) Decode(b *bin.Buffer) error
- func (p *PageTableCell) Encode(b *bin.Buffer) error
- func (p *PageTableCell) GetColspan() (value int, ok bool)
- func (p *PageTableCell) GetRowspan() (value int, ok bool)
- func (p *PageTableCell) GetText() (value RichTextClass, ok bool)
- func (p *PageTableCell) SetAlignCenter(value bool)
- func (p *PageTableCell) SetAlignRight(value bool)
- func (p *PageTableCell) SetColspan(value int)
- func (p *PageTableCell) SetHeader(value bool)
- func (p *PageTableCell) SetRowspan(value int)
- func (p *PageTableCell) SetText(value RichTextClass)
- func (p *PageTableCell) SetValignBottom(value bool)
- func (p *PageTableCell) SetValignMiddle(value bool)
- func (p *PageTableCell) String() string
- type PageTableRow
- type PasswordKdfAlgoBox
- type PasswordKdfAlgoClass
- type PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow
- type PasswordKdfAlgoUnknown
- type PaymentCharge
- type PaymentRequestedInfo
- func (p *PaymentRequestedInfo) Decode(b *bin.Buffer) error
- func (p *PaymentRequestedInfo) Encode(b *bin.Buffer) error
- func (p *PaymentRequestedInfo) GetEmail() (value string, ok bool)
- func (p *PaymentRequestedInfo) GetName() (value string, ok bool)
- func (p *PaymentRequestedInfo) GetPhone() (value string, ok bool)
- func (p *PaymentRequestedInfo) GetShippingAddress() (value PostAddress, ok bool)
- func (p *PaymentRequestedInfo) SetEmail(value string)
- func (p *PaymentRequestedInfo) SetName(value string)
- func (p *PaymentRequestedInfo) SetPhone(value string)
- func (p *PaymentRequestedInfo) SetShippingAddress(value PostAddress)
- func (p *PaymentRequestedInfo) String() string
- type PaymentSavedCredentialsCard
- type PaymentsBankCardData
- type PaymentsClearSavedInfoRequest
- func (c *PaymentsClearSavedInfoRequest) Decode(b *bin.Buffer) error
- func (c *PaymentsClearSavedInfoRequest) Encode(b *bin.Buffer) error
- func (c *PaymentsClearSavedInfoRequest) SetCredentials(value bool)
- func (c *PaymentsClearSavedInfoRequest) SetInfo(value bool)
- func (c *PaymentsClearSavedInfoRequest) String() string
- type PaymentsGetBankCardDataRequest
- type PaymentsGetPaymentFormRequest
- type PaymentsGetPaymentReceiptRequest
- type PaymentsGetSavedInfoRequest
- type PaymentsPaymentForm
- func (p *PaymentsPaymentForm) Decode(b *bin.Buffer) error
- func (p *PaymentsPaymentForm) Encode(b *bin.Buffer) error
- func (p *PaymentsPaymentForm) GetNativeParams() (value DataJSON, ok bool)
- func (p *PaymentsPaymentForm) GetNativeProvider() (value string, ok bool)
- func (p *PaymentsPaymentForm) GetSavedCredentials() (value PaymentSavedCredentialsCard, ok bool)
- func (p *PaymentsPaymentForm) GetSavedInfo() (value PaymentRequestedInfo, ok bool)
- func (p *PaymentsPaymentForm) SetCanSaveCredentials(value bool)
- func (p *PaymentsPaymentForm) SetNativeParams(value DataJSON)
- func (p *PaymentsPaymentForm) SetNativeProvider(value string)
- func (p *PaymentsPaymentForm) SetPasswordMissing(value bool)
- func (p *PaymentsPaymentForm) SetSavedCredentials(value PaymentSavedCredentialsCard)
- func (p *PaymentsPaymentForm) SetSavedInfo(value PaymentRequestedInfo)
- func (p *PaymentsPaymentForm) String() string
- type PaymentsPaymentReceipt
- func (p *PaymentsPaymentReceipt) Decode(b *bin.Buffer) error
- func (p *PaymentsPaymentReceipt) Encode(b *bin.Buffer) error
- func (p *PaymentsPaymentReceipt) GetInfo() (value PaymentRequestedInfo, ok bool)
- func (p *PaymentsPaymentReceipt) GetShipping() (value ShippingOption, ok bool)
- func (p *PaymentsPaymentReceipt) SetInfo(value PaymentRequestedInfo)
- func (p *PaymentsPaymentReceipt) SetShipping(value ShippingOption)
- func (p *PaymentsPaymentReceipt) String() string
- type PaymentsPaymentResult
- type PaymentsPaymentResultBox
- type PaymentsPaymentResultClass
- type PaymentsPaymentVerificationNeeded
- type PaymentsSavedInfo
- func (s *PaymentsSavedInfo) Decode(b *bin.Buffer) error
- func (s *PaymentsSavedInfo) Encode(b *bin.Buffer) error
- func (s *PaymentsSavedInfo) GetSavedInfo() (value PaymentRequestedInfo, ok bool)
- func (s *PaymentsSavedInfo) SetHasSavedCredentials(value bool)
- func (s *PaymentsSavedInfo) SetSavedInfo(value PaymentRequestedInfo)
- func (s *PaymentsSavedInfo) String() string
- type PaymentsSendPaymentFormRequest
- func (s *PaymentsSendPaymentFormRequest) Decode(b *bin.Buffer) error
- func (s *PaymentsSendPaymentFormRequest) Encode(b *bin.Buffer) error
- func (s *PaymentsSendPaymentFormRequest) GetRequestedInfoID() (value string, ok bool)
- func (s *PaymentsSendPaymentFormRequest) GetShippingOptionID() (value string, ok bool)
- func (s *PaymentsSendPaymentFormRequest) SetRequestedInfoID(value string)
- func (s *PaymentsSendPaymentFormRequest) SetShippingOptionID(value string)
- func (s *PaymentsSendPaymentFormRequest) String() string
- type PaymentsValidateRequestedInfoRequest
- type PaymentsValidatedRequestedInfo
- func (v *PaymentsValidatedRequestedInfo) Decode(b *bin.Buffer) error
- func (v *PaymentsValidatedRequestedInfo) Encode(b *bin.Buffer) error
- func (v *PaymentsValidatedRequestedInfo) GetID() (value string, ok bool)
- func (v *PaymentsValidatedRequestedInfo) GetShippingOptions() (value []ShippingOption, ok bool)
- func (v *PaymentsValidatedRequestedInfo) SetID(value string)
- func (v *PaymentsValidatedRequestedInfo) SetShippingOptions(value []ShippingOption)
- func (v *PaymentsValidatedRequestedInfo) String() string
- type PeerBlocked
- type PeerBlockedHandler
- type PeerBox
- type PeerChannel
- type PeerChat
- type PeerClass
- type PeerLocated
- type PeerLocatedBox
- type PeerLocatedClass
- type PeerLocatedHandler
- type PeerNotifySettings
- func (p *PeerNotifySettings) Decode(b *bin.Buffer) error
- func (p *PeerNotifySettings) Encode(b *bin.Buffer) error
- func (p *PeerNotifySettings) GetMuteUntil() (value int, ok bool)
- func (p *PeerNotifySettings) GetShowPreviews() (value bool, ok bool)
- func (p *PeerNotifySettings) GetSilent() (value bool, ok bool)
- func (p *PeerNotifySettings) GetSound() (value string, ok bool)
- func (p *PeerNotifySettings) SetMuteUntil(value int)
- func (p *PeerNotifySettings) SetShowPreviews(value bool)
- func (p *PeerNotifySettings) SetSilent(value bool)
- func (p *PeerNotifySettings) SetSound(value string)
- func (p *PeerNotifySettings) String() string
- type PeerSelfLocated
- type PeerSettings
- func (p *PeerSettings) Decode(b *bin.Buffer) error
- func (p *PeerSettings) Encode(b *bin.Buffer) error
- func (p *PeerSettings) GetGeoDistance() (value int, ok bool)
- func (p *PeerSettings) SetAddContact(value bool)
- func (p *PeerSettings) SetAutoarchived(value bool)
- func (p *PeerSettings) SetBlockContact(value bool)
- func (p *PeerSettings) SetGeoDistance(value int)
- func (p *PeerSettings) SetNeedContactsException(value bool)
- func (p *PeerSettings) SetReportGeo(value bool)
- func (p *PeerSettings) SetReportSpam(value bool)
- func (p *PeerSettings) SetShareContact(value bool)
- func (p *PeerSettings) String() string
- type PeerSettingsHandler
- type PeerUser
- type PhoneAcceptCallRequest
- type PhoneCall
- type PhoneCallAccepted
- type PhoneCallBox
- type PhoneCallClass
- type PhoneCallDiscardReasonBox
- type PhoneCallDiscardReasonBusy
- type PhoneCallDiscardReasonClass
- type PhoneCallDiscardReasonDisconnect
- type PhoneCallDiscardReasonHangup
- type PhoneCallDiscardReasonMissed
- type PhoneCallDiscarded
- func (p *PhoneCallDiscarded) Decode(b *bin.Buffer) error
- func (p *PhoneCallDiscarded) Encode(b *bin.Buffer) error
- func (p *PhoneCallDiscarded) GetDuration() (value int, ok bool)
- func (p *PhoneCallDiscarded) GetReason() (value PhoneCallDiscardReasonClass, ok bool)
- func (p *PhoneCallDiscarded) SetDuration(value int)
- func (p *PhoneCallDiscarded) SetNeedDebug(value bool)
- func (p *PhoneCallDiscarded) SetNeedRating(value bool)
- func (p *PhoneCallDiscarded) SetReason(value PhoneCallDiscardReasonClass)
- func (p *PhoneCallDiscarded) SetVideo(value bool)
- func (p *PhoneCallDiscarded) String() string
- type PhoneCallEmpty
- type PhoneCallHandler
- type PhoneCallProtocol
- type PhoneCallRequested
- type PhoneCallSignalingDataHandler
- type PhoneCallWaiting
- func (p *PhoneCallWaiting) Decode(b *bin.Buffer) error
- func (p *PhoneCallWaiting) Encode(b *bin.Buffer) error
- func (p *PhoneCallWaiting) GetReceiveDate() (value int, ok bool)
- func (p *PhoneCallWaiting) SetReceiveDate(value int)
- func (p *PhoneCallWaiting) SetVideo(value bool)
- func (p *PhoneCallWaiting) String() string
- type PhoneCheckGroupCallRequest
- type PhoneConfirmCallRequest
- type PhoneConnection
- type PhoneConnectionBox
- type PhoneConnectionClass
- type PhoneConnectionWebrtc
- type PhoneCreateGroupCallRequest
- type PhoneDiscardCallRequest
- type PhoneDiscardGroupCallRequest
- type PhoneEditGroupCallMemberRequest
- type PhoneGetCallConfigRequest
- type PhoneGetGroupCallRequest
- type PhoneGetGroupParticipantsRequest
- type PhoneGroupCall
- type PhoneGroupParticipants
- type PhoneInviteToGroupCallRequest
- type PhoneJoinGroupCallRequest
- type PhoneLeaveGroupCallRequest
- type PhonePhoneCall
- type PhoneReceivedCallRequest
- type PhoneRequestCallRequest
- type PhoneSaveCallDebugRequest
- type PhoneSendSignalingDataRequest
- type PhoneSetCallRatingRequest
- type PhoneToggleGroupCallSettingsRequest
- func (t *PhoneToggleGroupCallSettingsRequest) Decode(b *bin.Buffer) error
- func (t *PhoneToggleGroupCallSettingsRequest) Encode(b *bin.Buffer) error
- func (t *PhoneToggleGroupCallSettingsRequest) GetJoinMuted() (value bool, ok bool)
- func (t *PhoneToggleGroupCallSettingsRequest) SetJoinMuted(value bool)
- func (t *PhoneToggleGroupCallSettingsRequest) String() string
- type Photo
- type PhotoBox
- type PhotoCachedSize
- type PhotoClass
- type PhotoEmpty
- type PhotoPathSize
- type PhotoSize
- type PhotoSizeBox
- type PhotoSizeClass
- type PhotoSizeEmpty
- type PhotoSizeProgressive
- type PhotoStrippedSize
- type PhotosDeletePhotosRequest
- type PhotosGetUserPhotosRequest
- type PhotosPhoto
- type PhotosPhotos
- type PhotosPhotosBox
- type PhotosPhotosClass
- type PhotosPhotosSlice
- type PhotosUpdateProfilePhotoRequest
- type PhotosUploadProfilePhotoRequest
- func (u *PhotosUploadProfilePhotoRequest) Decode(b *bin.Buffer) error
- func (u *PhotosUploadProfilePhotoRequest) Encode(b *bin.Buffer) error
- func (u *PhotosUploadProfilePhotoRequest) GetFile() (value InputFileClass, ok bool)
- func (u *PhotosUploadProfilePhotoRequest) GetVideo() (value InputFileClass, ok bool)
- func (u *PhotosUploadProfilePhotoRequest) GetVideoStartTs() (value float64, ok bool)
- func (u *PhotosUploadProfilePhotoRequest) SetFile(value InputFileClass)
- func (u *PhotosUploadProfilePhotoRequest) SetVideo(value InputFileClass)
- func (u *PhotosUploadProfilePhotoRequest) SetVideoStartTs(value float64)
- func (u *PhotosUploadProfilePhotoRequest) String() string
- type PinnedChannelMessagesHandler
- type PinnedDialogsHandler
- type PinnedMessagesHandler
- type Poll
- func (p *Poll) Decode(b *bin.Buffer) error
- func (p *Poll) Encode(b *bin.Buffer) error
- func (p *Poll) GetCloseDate() (value int, ok bool)
- func (p *Poll) GetClosePeriod() (value int, ok bool)
- func (p *Poll) SetCloseDate(value int)
- func (p *Poll) SetClosePeriod(value int)
- func (p *Poll) SetClosed(value bool)
- func (p *Poll) SetMultipleChoice(value bool)
- func (p *Poll) SetPublicVoters(value bool)
- func (p *Poll) SetQuiz(value bool)
- func (p *Poll) String() string
- type PollAnswer
- type PollAnswerVoters
- type PollResults
- func (p *PollResults) Decode(b *bin.Buffer) error
- func (p *PollResults) Encode(b *bin.Buffer) error
- func (p *PollResults) GetRecentVoters() (value []int, ok bool)
- func (p *PollResults) GetResults() (value []PollAnswerVoters, ok bool)
- func (p *PollResults) GetSolution() (value string, ok bool)
- func (p *PollResults) GetSolutionEntities() (value []MessageEntityClass, ok bool)
- func (p *PollResults) GetTotalVoters() (value int, ok bool)
- func (p *PollResults) SetMin(value bool)
- func (p *PollResults) SetRecentVoters(value []int)
- func (p *PollResults) SetResults(value []PollAnswerVoters)
- func (p *PollResults) SetSolution(value string)
- func (p *PollResults) SetSolutionEntities(value []MessageEntityClass)
- func (p *PollResults) SetTotalVoters(value int)
- func (p *PollResults) String() string
- type PopularContact
- type PostAddress
- type PrivacyHandler
- type PrivacyKeyAddedByPhone
- type PrivacyKeyBox
- type PrivacyKeyChatInvite
- type PrivacyKeyClass
- type PrivacyKeyForwards
- type PrivacyKeyPhoneCall
- type PrivacyKeyPhoneNumber
- type PrivacyKeyPhoneP2P
- type PrivacyKeyProfilePhoto
- type PrivacyKeyStatusTimestamp
- type PrivacyRuleBox
- type PrivacyRuleClass
- type PrivacyValueAllowAll
- type PrivacyValueAllowChatParticipants
- type PrivacyValueAllowContacts
- type PrivacyValueAllowUsers
- type PrivacyValueDisallowAll
- type PrivacyValueDisallowChatParticipants
- type PrivacyValueDisallowContacts
- type PrivacyValueDisallowUsers
- type PtsChangedHandler
- type ReadChannelDiscussionInboxHandler
- type ReadChannelDiscussionOutboxHandler
- type ReadChannelInboxHandler
- type ReadChannelOutboxHandler
- type ReadFeaturedStickersHandler
- type ReadHistoryInboxHandler
- type ReadHistoryOutboxHandler
- type ReadMessagesContentsHandler
- type ReceivedNotifyMessage
- type ReceivedNotifyMessageVector
- type RecentMeUrlBox
- type RecentMeUrlChat
- type RecentMeUrlChatInvite
- type RecentMeUrlClass
- type RecentMeUrlStickerSet
- type RecentMeUrlUnknown
- type RecentMeUrlUser
- type RecentStickersHandler
- type ReplyInlineMarkup
- type ReplyKeyboardForceReply
- type ReplyKeyboardHide
- type ReplyKeyboardMarkup
- func (r *ReplyKeyboardMarkup) Decode(b *bin.Buffer) error
- func (r *ReplyKeyboardMarkup) Encode(b *bin.Buffer) error
- func (r *ReplyKeyboardMarkup) SetResize(value bool)
- func (r *ReplyKeyboardMarkup) SetSelective(value bool)
- func (r *ReplyKeyboardMarkup) SetSingleUse(value bool)
- func (r *ReplyKeyboardMarkup) String() string
- type ReplyMarkupBox
- type ReplyMarkupClass
- type ReportReasonBox
- type ReportReasonClass
- type RestrictionReason
- type RichTextBox
- type RichTextClass
- type SavedGifsHandler
- type SavedPhoneContact
- type SavedPhoneContactVector
- type SecureCredentialsEncrypted
- type SecureData
- type SecureFile
- type SecureFileBox
- type SecureFileClass
- type SecureFileEmpty
- type SecurePasswordKdfAlgoBox
- type SecurePasswordKdfAlgoClass
- type SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000
- type SecurePasswordKdfAlgoSHA512
- type SecurePasswordKdfAlgoUnknown
- type SecurePlainDataBox
- type SecurePlainDataClass
- type SecurePlainEmail
- type SecurePlainPhone
- type SecureRequiredType
- func (s *SecureRequiredType) Decode(b *bin.Buffer) error
- func (s *SecureRequiredType) Encode(b *bin.Buffer) error
- func (s *SecureRequiredType) SetNativeNames(value bool)
- func (s *SecureRequiredType) SetSelfieRequired(value bool)
- func (s *SecureRequiredType) SetTranslationRequired(value bool)
- func (s *SecureRequiredType) String() string
- type SecureRequiredTypeBox
- type SecureRequiredTypeClass
- type SecureRequiredTypeOneOf
- type SecureSecretSettings
- type SecureValue
- func (s *SecureValue) Decode(b *bin.Buffer) error
- func (s *SecureValue) Encode(b *bin.Buffer) error
- func (s *SecureValue) GetData() (value SecureData, ok bool)
- func (s *SecureValue) GetFiles() (value []SecureFileClass, ok bool)
- func (s *SecureValue) GetFrontSide() (value SecureFileClass, ok bool)
- func (s *SecureValue) GetPlainData() (value SecurePlainDataClass, ok bool)
- func (s *SecureValue) GetReverseSide() (value SecureFileClass, ok bool)
- func (s *SecureValue) GetSelfie() (value SecureFileClass, ok bool)
- func (s *SecureValue) GetTranslation() (value []SecureFileClass, ok bool)
- func (s *SecureValue) SetData(value SecureData)
- func (s *SecureValue) SetFiles(value []SecureFileClass)
- func (s *SecureValue) SetFrontSide(value SecureFileClass)
- func (s *SecureValue) SetPlainData(value SecurePlainDataClass)
- func (s *SecureValue) SetReverseSide(value SecureFileClass)
- func (s *SecureValue) SetSelfie(value SecureFileClass)
- func (s *SecureValue) SetTranslation(value []SecureFileClass)
- func (s *SecureValue) String() string
- type SecureValueError
- type SecureValueErrorBox
- type SecureValueErrorClass
- type SecureValueErrorData
- type SecureValueErrorFile
- type SecureValueErrorFiles
- type SecureValueErrorFrontSide
- type SecureValueErrorReverseSide
- type SecureValueErrorSelfie
- type SecureValueErrorTranslationFile
- type SecureValueErrorTranslationFiles
- type SecureValueHash
- type SecureValueTypeAddress
- type SecureValueTypeBankStatement
- type SecureValueTypeBox
- type SecureValueTypeClass
- type SecureValueTypeDriverLicense
- type SecureValueTypeEmail
- type SecureValueTypeIdentityCard
- type SecureValueTypeInternalPassport
- type SecureValueTypePassport
- type SecureValueTypePassportRegistration
- type SecureValueTypePersonalDetails
- type SecureValueTypePhone
- type SecureValueTypeRentalAgreement
- type SecureValueTypeTemporaryRegistration
- type SecureValueTypeUtilityBill
- type SecureValueVector
- type SendMessageActionBox
- type SendMessageActionClass
- type SendMessageCancelAction
- type SendMessageChooseContactAction
- type SendMessageGamePlayAction
- type SendMessageGeoLocationAction
- type SendMessageRecordAudioAction
- type SendMessageRecordRoundAction
- type SendMessageRecordVideoAction
- type SendMessageTypingAction
- type SendMessageUploadAudioAction
- type SendMessageUploadDocumentAction
- type SendMessageUploadPhotoAction
- type SendMessageUploadRoundAction
- type SendMessageUploadVideoAction
- type ServiceNotificationHandler
- type ShippingOption
- type SpeakingInGroupCallAction
- type StatsAbsValueAndPrev
- type StatsBroadcastStats
- type StatsDateRangeDays
- type StatsGetBroadcastStatsRequest
- type StatsGetMegagroupStatsRequest
- type StatsGetMessagePublicForwardsRequest
- type StatsGetMessageStatsRequest
- type StatsGraph
- type StatsGraphAsync
- type StatsGraphBox
- type StatsGraphClass
- type StatsGraphError
- type StatsGroupTopAdmin
- type StatsGroupTopInviter
- type StatsGroupTopPoster
- type StatsLoadAsyncGraphRequest
- func (l *StatsLoadAsyncGraphRequest) Decode(b *bin.Buffer) error
- func (l *StatsLoadAsyncGraphRequest) Encode(b *bin.Buffer) error
- func (l *StatsLoadAsyncGraphRequest) GetX() (value int64, ok bool)
- func (l *StatsLoadAsyncGraphRequest) SetX(value int64)
- func (l *StatsLoadAsyncGraphRequest) String() string
- type StatsMegagroupStats
- type StatsMessageStats
- type StatsPercentValue
- type StatsURL
- type StickerPack
- type StickerSet
- func (s *StickerSet) Decode(b *bin.Buffer) error
- func (s *StickerSet) Encode(b *bin.Buffer) error
- func (s *StickerSet) GetInstalledDate() (value int, ok bool)
- func (s *StickerSet) GetThumbDCID() (value int, ok bool)
- func (s *StickerSet) GetThumbs() (value []PhotoSizeClass, ok bool)
- func (s *StickerSet) SetAnimated(value bool)
- func (s *StickerSet) SetArchived(value bool)
- func (s *StickerSet) SetInstalledDate(value int)
- func (s *StickerSet) SetMasks(value bool)
- func (s *StickerSet) SetOfficial(value bool)
- func (s *StickerSet) SetThumbDCID(value int)
- func (s *StickerSet) SetThumbs(value []PhotoSizeClass)
- func (s *StickerSet) String() string
- type StickerSetCovered
- type StickerSetCoveredBox
- type StickerSetCoveredClass
- type StickerSetCoveredClassVector
- type StickerSetMultiCovered
- type StickerSetsHandler
- type StickerSetsOrderHandler
- type StickersAddStickerToSetRequest
- type StickersChangeStickerPositionRequest
- type StickersCreateStickerSetRequest
- func (c *StickersCreateStickerSetRequest) Decode(b *bin.Buffer) error
- func (c *StickersCreateStickerSetRequest) Encode(b *bin.Buffer) error
- func (c *StickersCreateStickerSetRequest) GetThumb() (value InputDocumentClass, ok bool)
- func (c *StickersCreateStickerSetRequest) SetAnimated(value bool)
- func (c *StickersCreateStickerSetRequest) SetMasks(value bool)
- func (c *StickersCreateStickerSetRequest) SetThumb(value InputDocumentClass)
- func (c *StickersCreateStickerSetRequest) String() string
- type StickersRemoveStickerFromSetRequest
- type StickersSetStickerSetThumbRequest
- type StorageFileGif
- type StorageFileJpeg
- type StorageFileMov
- type StorageFileMp3
- type StorageFileMp4
- type StorageFilePartial
- type StorageFilePdf
- type StorageFilePng
- type StorageFileTypeBox
- type StorageFileTypeClass
- type StorageFileUnknown
- type StorageFileWebp
- type TextAnchor
- type TextBold
- type TextConcat
- type TextEmail
- type TextEmpty
- type TextFixed
- type TextImage
- type TextItalic
- type TextMarked
- type TextPhone
- type TextPlain
- type TextStrike
- type TextSubscript
- type TextSuperscript
- type TextUnderline
- type TextUrl
- type Theme
- func (t *Theme) Decode(b *bin.Buffer) error
- func (t *Theme) Encode(b *bin.Buffer) error
- func (t *Theme) GetDocument() (value DocumentClass, ok bool)
- func (t *Theme) GetSettings() (value ThemeSettings, ok bool)
- func (t *Theme) SetCreator(value bool)
- func (t *Theme) SetDefault(value bool)
- func (t *Theme) SetDocument(value DocumentClass)
- func (t *Theme) SetSettings(value ThemeSettings)
- func (t *Theme) String() string
- type ThemeHandler
- type ThemeSettings
- func (t *ThemeSettings) Decode(b *bin.Buffer) error
- func (t *ThemeSettings) Encode(b *bin.Buffer) error
- func (t *ThemeSettings) GetMessageBottomColor() (value int, ok bool)
- func (t *ThemeSettings) GetMessageTopColor() (value int, ok bool)
- func (t *ThemeSettings) GetWallpaper() (value WallPaperClass, ok bool)
- func (t *ThemeSettings) SetMessageBottomColor(value int)
- func (t *ThemeSettings) SetMessageTopColor(value int)
- func (t *ThemeSettings) SetWallpaper(value WallPaperClass)
- func (t *ThemeSettings) String() string
- type TopPeer
- type TopPeerCategoryBotsInline
- type TopPeerCategoryBotsPM
- type TopPeerCategoryBox
- type TopPeerCategoryChannels
- type TopPeerCategoryClass
- type TopPeerCategoryCorrespondents
- type TopPeerCategoryForwardChats
- type TopPeerCategoryForwardUsers
- type TopPeerCategoryGroups
- type TopPeerCategoryPeers
- type TopPeerCategoryPhoneCalls
- type True
- type UpdateBotCallbackQuery
- func (u *UpdateBotCallbackQuery) Decode(b *bin.Buffer) error
- func (u *UpdateBotCallbackQuery) Encode(b *bin.Buffer) error
- func (u *UpdateBotCallbackQuery) GetData() (value []byte, ok bool)
- func (u *UpdateBotCallbackQuery) GetGameShortName() (value string, ok bool)
- func (u *UpdateBotCallbackQuery) SetData(value []byte)
- func (u *UpdateBotCallbackQuery) SetGameShortName(value string)
- func (u *UpdateBotCallbackQuery) String() string
- type UpdateBotInlineQuery
- func (u *UpdateBotInlineQuery) Decode(b *bin.Buffer) error
- func (u *UpdateBotInlineQuery) Encode(b *bin.Buffer) error
- func (u *UpdateBotInlineQuery) GetGeo() (value GeoPointClass, ok bool)
- func (u *UpdateBotInlineQuery) GetPeerType() (value InlineQueryPeerTypeClass, ok bool)
- func (u *UpdateBotInlineQuery) SetGeo(value GeoPointClass)
- func (u *UpdateBotInlineQuery) SetPeerType(value InlineQueryPeerTypeClass)
- func (u *UpdateBotInlineQuery) String() string
- type UpdateBotInlineSend
- func (u *UpdateBotInlineSend) Decode(b *bin.Buffer) error
- func (u *UpdateBotInlineSend) Encode(b *bin.Buffer) error
- func (u *UpdateBotInlineSend) GetGeo() (value GeoPointClass, ok bool)
- func (u *UpdateBotInlineSend) GetMsgID() (value InputBotInlineMessageID, ok bool)
- func (u *UpdateBotInlineSend) SetGeo(value GeoPointClass)
- func (u *UpdateBotInlineSend) SetMsgID(value InputBotInlineMessageID)
- func (u *UpdateBotInlineSend) String() string
- type UpdateBotPrecheckoutQuery
- func (u *UpdateBotPrecheckoutQuery) Decode(b *bin.Buffer) error
- func (u *UpdateBotPrecheckoutQuery) Encode(b *bin.Buffer) error
- func (u *UpdateBotPrecheckoutQuery) GetInfo() (value PaymentRequestedInfo, ok bool)
- func (u *UpdateBotPrecheckoutQuery) GetShippingOptionID() (value string, ok bool)
- func (u *UpdateBotPrecheckoutQuery) SetInfo(value PaymentRequestedInfo)
- func (u *UpdateBotPrecheckoutQuery) SetShippingOptionID(value string)
- func (u *UpdateBotPrecheckoutQuery) String() string
- type UpdateBotShippingQuery
- type UpdateBotWebhookJSON
- type UpdateBotWebhookJSONQuery
- type UpdateBox
- type UpdateChannel
- type UpdateChannelAvailableMessages
- type UpdateChannelMessageForwards
- type UpdateChannelMessageViews
- type UpdateChannelParticipant
- func (u *UpdateChannelParticipant) Decode(b *bin.Buffer) error
- func (u *UpdateChannelParticipant) Encode(b *bin.Buffer) error
- func (u *UpdateChannelParticipant) GetNewParticipant() (value ChannelParticipantClass, ok bool)
- func (u *UpdateChannelParticipant) GetPrevParticipant() (value ChannelParticipantClass, ok bool)
- func (u *UpdateChannelParticipant) SetNewParticipant(value ChannelParticipantClass)
- func (u *UpdateChannelParticipant) SetPrevParticipant(value ChannelParticipantClass)
- func (u *UpdateChannelParticipant) String() string
- type UpdateChannelReadMessagesContents
- type UpdateChannelTooLong
- type UpdateChannelUserTyping
- type UpdateChannelWebPage
- type UpdateChat
- type UpdateChatDefaultBannedRights
- type UpdateChatParticipantAdd
- type UpdateChatParticipantAdmin
- type UpdateChatParticipantDelete
- type UpdateChatParticipants
- type UpdateChatUserTyping
- type UpdateClass
- type UpdateConfig
- type UpdateContactsReset
- type UpdateContext
- type UpdateDcOptions
- type UpdateDeleteChannelMessages
- type UpdateDeleteMessages
- type UpdateDeleteScheduledMessages
- type UpdateDialogFilter
- type UpdateDialogFilterOrder
- type UpdateDialogFilters
- type UpdateDialogPinned
- func (u *UpdateDialogPinned) Decode(b *bin.Buffer) error
- func (u *UpdateDialogPinned) Encode(b *bin.Buffer) error
- func (u *UpdateDialogPinned) GetFolderID() (value int, ok bool)
- func (u *UpdateDialogPinned) SetFolderID(value int)
- func (u *UpdateDialogPinned) SetPinned(value bool)
- func (u *UpdateDialogPinned) String() string
- type UpdateDialogUnreadMark
- type UpdateDispatcher
- func (u UpdateDispatcher) Handle(ctx context.Context, updates *Updates) error
- func (u UpdateDispatcher) OnBotCallbackQuery(handler BotCallbackQueryHandler)
- func (u UpdateDispatcher) OnBotInlineQuery(handler BotInlineQueryHandler)
- func (u UpdateDispatcher) OnBotInlineSend(handler BotInlineSendHandler)
- func (u UpdateDispatcher) OnBotPrecheckoutQuery(handler BotPrecheckoutQueryHandler)
- func (u UpdateDispatcher) OnBotShippingQuery(handler BotShippingQueryHandler)
- func (u UpdateDispatcher) OnBotWebhookJSON(handler BotWebhookJSONHandler)
- func (u UpdateDispatcher) OnBotWebhookJSONQuery(handler BotWebhookJSONQueryHandler)
- func (u UpdateDispatcher) OnChannel(handler ChannelHandler)
- func (u UpdateDispatcher) OnChannelAvailableMessages(handler ChannelAvailableMessagesHandler)
- func (u UpdateDispatcher) OnChannelMessageForwards(handler ChannelMessageForwardsHandler)
- func (u UpdateDispatcher) OnChannelMessageViews(handler ChannelMessageViewsHandler)
- func (u UpdateDispatcher) OnChannelParticipant(handler ChannelParticipantHandler)
- func (u UpdateDispatcher) OnChannelReadMessagesContents(handler ChannelReadMessagesContentsHandler)
- func (u UpdateDispatcher) OnChannelTooLong(handler ChannelTooLongHandler)
- func (u UpdateDispatcher) OnChannelUserTyping(handler ChannelUserTypingHandler)
- func (u UpdateDispatcher) OnChannelWebPage(handler ChannelWebPageHandler)
- func (u UpdateDispatcher) OnChat(handler ChatHandler)
- func (u UpdateDispatcher) OnChatDefaultBannedRights(handler ChatDefaultBannedRightsHandler)
- func (u UpdateDispatcher) OnChatParticipantAdd(handler ChatParticipantAddHandler)
- func (u UpdateDispatcher) OnChatParticipantAdmin(handler ChatParticipantAdminHandler)
- func (u UpdateDispatcher) OnChatParticipantDelete(handler ChatParticipantDeleteHandler)
- func (u UpdateDispatcher) OnChatParticipants(handler ChatParticipantsHandler)
- func (u UpdateDispatcher) OnChatUserTyping(handler ChatUserTypingHandler)
- func (u UpdateDispatcher) OnConfig(handler ConfigHandler)
- func (u UpdateDispatcher) OnContactsReset(handler ContactsResetHandler)
- func (u UpdateDispatcher) OnDcOptions(handler DcOptionsHandler)
- func (u UpdateDispatcher) OnDeleteChannelMessages(handler DeleteChannelMessagesHandler)
- func (u UpdateDispatcher) OnDeleteMessages(handler DeleteMessagesHandler)
- func (u UpdateDispatcher) OnDeleteScheduledMessages(handler DeleteScheduledMessagesHandler)
- func (u UpdateDispatcher) OnDialogFilter(handler DialogFilterHandler)
- func (u UpdateDispatcher) OnDialogFilterOrder(handler DialogFilterOrderHandler)
- func (u UpdateDispatcher) OnDialogFilters(handler DialogFiltersHandler)
- func (u UpdateDispatcher) OnDialogPinned(handler DialogPinnedHandler)
- func (u UpdateDispatcher) OnDialogUnreadMark(handler DialogUnreadMarkHandler)
- func (u UpdateDispatcher) OnDraftMessage(handler DraftMessageHandler)
- func (u UpdateDispatcher) OnEditChannelMessage(handler EditChannelMessageHandler)
- func (u UpdateDispatcher) OnEditMessage(handler EditMessageHandler)
- func (u UpdateDispatcher) OnEncryptedChatTyping(handler EncryptedChatTypingHandler)
- func (u UpdateDispatcher) OnEncryptedMessagesRead(handler EncryptedMessagesReadHandler)
- func (u UpdateDispatcher) OnEncryption(handler EncryptionHandler)
- func (u UpdateDispatcher) OnFavedStickers(handler FavedStickersHandler)
- func (u UpdateDispatcher) OnFolderPeers(handler FolderPeersHandler)
- func (u UpdateDispatcher) OnGeoLiveViewed(handler GeoLiveViewedHandler)
- func (u UpdateDispatcher) OnGroupCall(handler GroupCallHandler)
- func (u UpdateDispatcher) OnGroupCallParticipants(handler GroupCallParticipantsHandler)
- func (u UpdateDispatcher) OnInlineBotCallbackQuery(handler InlineBotCallbackQueryHandler)
- func (u UpdateDispatcher) OnLangPack(handler LangPackHandler)
- func (u UpdateDispatcher) OnLangPackTooLong(handler LangPackTooLongHandler)
- func (u UpdateDispatcher) OnLoginToken(handler LoginTokenHandler)
- func (u UpdateDispatcher) OnMessageID(handler MessageIDHandler)
- func (u UpdateDispatcher) OnMessagePoll(handler MessagePollHandler)
- func (u UpdateDispatcher) OnMessagePollVote(handler MessagePollVoteHandler)
- func (u UpdateDispatcher) OnNewChannelMessage(handler NewChannelMessageHandler)
- func (u UpdateDispatcher) OnNewEncryptedMessage(handler NewEncryptedMessageHandler)
- func (u UpdateDispatcher) OnNewMessage(handler NewMessageHandler)
- func (u UpdateDispatcher) OnNewScheduledMessage(handler NewScheduledMessageHandler)
- func (u UpdateDispatcher) OnNewStickerSet(handler NewStickerSetHandler)
- func (u UpdateDispatcher) OnNotifySettings(handler NotifySettingsHandler)
- func (u UpdateDispatcher) OnPeerBlocked(handler PeerBlockedHandler)
- func (u UpdateDispatcher) OnPeerLocated(handler PeerLocatedHandler)
- func (u UpdateDispatcher) OnPeerSettings(handler PeerSettingsHandler)
- func (u UpdateDispatcher) OnPhoneCall(handler PhoneCallHandler)
- func (u UpdateDispatcher) OnPhoneCallSignalingData(handler PhoneCallSignalingDataHandler)
- func (u UpdateDispatcher) OnPinnedChannelMessages(handler PinnedChannelMessagesHandler)
- func (u UpdateDispatcher) OnPinnedDialogs(handler PinnedDialogsHandler)
- func (u UpdateDispatcher) OnPinnedMessages(handler PinnedMessagesHandler)
- func (u UpdateDispatcher) OnPrivacy(handler PrivacyHandler)
- func (u UpdateDispatcher) OnPtsChanged(handler PtsChangedHandler)
- func (u UpdateDispatcher) OnReadChannelDiscussionInbox(handler ReadChannelDiscussionInboxHandler)
- func (u UpdateDispatcher) OnReadChannelDiscussionOutbox(handler ReadChannelDiscussionOutboxHandler)
- func (u UpdateDispatcher) OnReadChannelInbox(handler ReadChannelInboxHandler)
- func (u UpdateDispatcher) OnReadChannelOutbox(handler ReadChannelOutboxHandler)
- func (u UpdateDispatcher) OnReadFeaturedStickers(handler ReadFeaturedStickersHandler)
- func (u UpdateDispatcher) OnReadHistoryInbox(handler ReadHistoryInboxHandler)
- func (u UpdateDispatcher) OnReadHistoryOutbox(handler ReadHistoryOutboxHandler)
- func (u UpdateDispatcher) OnReadMessagesContents(handler ReadMessagesContentsHandler)
- func (u UpdateDispatcher) OnRecentStickers(handler RecentStickersHandler)
- func (u UpdateDispatcher) OnSavedGifs(handler SavedGifsHandler)
- func (u UpdateDispatcher) OnServiceNotification(handler ServiceNotificationHandler)
- func (u UpdateDispatcher) OnStickerSets(handler StickerSetsHandler)
- func (u UpdateDispatcher) OnStickerSetsOrder(handler StickerSetsOrderHandler)
- func (u UpdateDispatcher) OnTheme(handler ThemeHandler)
- func (u UpdateDispatcher) OnUserName(handler UserNameHandler)
- func (u UpdateDispatcher) OnUserPhone(handler UserPhoneHandler)
- func (u UpdateDispatcher) OnUserPhoto(handler UserPhotoHandler)
- func (u UpdateDispatcher) OnUserStatus(handler UserStatusHandler)
- func (u UpdateDispatcher) OnUserTyping(handler UserTypingHandler)
- func (u UpdateDispatcher) OnWebPage(handler WebPageHandler)
- type UpdateDraftMessage
- type UpdateEditChannelMessage
- type UpdateEditMessage
- type UpdateEncryptedChatTyping
- type UpdateEncryptedMessagesRead
- type UpdateEncryption
- type UpdateFavedStickers
- type UpdateFolderPeers
- type UpdateGeoLiveViewed
- type UpdateGroupCall
- type UpdateGroupCallParticipants
- type UpdateInlineBotCallbackQuery
- func (u *UpdateInlineBotCallbackQuery) Decode(b *bin.Buffer) error
- func (u *UpdateInlineBotCallbackQuery) Encode(b *bin.Buffer) error
- func (u *UpdateInlineBotCallbackQuery) GetData() (value []byte, ok bool)
- func (u *UpdateInlineBotCallbackQuery) GetGameShortName() (value string, ok bool)
- func (u *UpdateInlineBotCallbackQuery) SetData(value []byte)
- func (u *UpdateInlineBotCallbackQuery) SetGameShortName(value string)
- func (u *UpdateInlineBotCallbackQuery) String() string
- type UpdateLangPack
- type UpdateLangPackTooLong
- type UpdateLoginToken
- type UpdateMessageID
- type UpdateMessagePoll
- type UpdateMessagePollVote
- type UpdateNewChannelMessage
- type UpdateNewEncryptedMessage
- type UpdateNewMessage
- type UpdateNewScheduledMessage
- type UpdateNewStickerSet
- type UpdateNotifySettings
- type UpdatePeerBlocked
- type UpdatePeerLocated
- type UpdatePeerSettings
- type UpdatePhoneCall
- type UpdatePhoneCallSignalingData
- type UpdatePinnedChannelMessages
- type UpdatePinnedDialogs
- func (u *UpdatePinnedDialogs) Decode(b *bin.Buffer) error
- func (u *UpdatePinnedDialogs) Encode(b *bin.Buffer) error
- func (u *UpdatePinnedDialogs) GetFolderID() (value int, ok bool)
- func (u *UpdatePinnedDialogs) GetOrder() (value []DialogPeerClass, ok bool)
- func (u *UpdatePinnedDialogs) SetFolderID(value int)
- func (u *UpdatePinnedDialogs) SetOrder(value []DialogPeerClass)
- func (u *UpdatePinnedDialogs) String() string
- type UpdatePinnedMessages
- type UpdatePrivacy
- type UpdatePtsChanged
- type UpdateReadChannelDiscussionInbox
- func (u *UpdateReadChannelDiscussionInbox) Decode(b *bin.Buffer) error
- func (u *UpdateReadChannelDiscussionInbox) Encode(b *bin.Buffer) error
- func (u *UpdateReadChannelDiscussionInbox) GetBroadcastID() (value int, ok bool)
- func (u *UpdateReadChannelDiscussionInbox) GetBroadcastPost() (value int, ok bool)
- func (u *UpdateReadChannelDiscussionInbox) SetBroadcastID(value int)
- func (u *UpdateReadChannelDiscussionInbox) SetBroadcastPost(value int)
- func (u *UpdateReadChannelDiscussionInbox) String() string
- type UpdateReadChannelDiscussionOutbox
- type UpdateReadChannelInbox
- type UpdateReadChannelOutbox
- type UpdateReadFeaturedStickers
- type UpdateReadHistoryInbox
- type UpdateReadHistoryOutbox
- type UpdateReadMessagesContents
- type UpdateRecentStickers
- type UpdateSavedGifs
- type UpdateServiceNotification
- func (u *UpdateServiceNotification) Decode(b *bin.Buffer) error
- func (u *UpdateServiceNotification) Encode(b *bin.Buffer) error
- func (u *UpdateServiceNotification) GetInboxDate() (value int, ok bool)
- func (u *UpdateServiceNotification) SetInboxDate(value int)
- func (u *UpdateServiceNotification) SetPopup(value bool)
- func (u *UpdateServiceNotification) String() string
- type UpdateShort
- type UpdateShortChatMessage
- func (u *UpdateShortChatMessage) Decode(b *bin.Buffer) error
- func (u *UpdateShortChatMessage) Encode(b *bin.Buffer) error
- func (u *UpdateShortChatMessage) GetEntities() (value []MessageEntityClass, ok bool)
- func (u *UpdateShortChatMessage) GetFwdFrom() (value MessageFwdHeader, ok bool)
- func (u *UpdateShortChatMessage) GetReplyTo() (value MessageReplyHeader, ok bool)
- func (u *UpdateShortChatMessage) GetViaBotID() (value int, ok bool)
- func (u *UpdateShortChatMessage) SetEntities(value []MessageEntityClass)
- func (u *UpdateShortChatMessage) SetFwdFrom(value MessageFwdHeader)
- func (u *UpdateShortChatMessage) SetMediaUnread(value bool)
- func (u *UpdateShortChatMessage) SetMentioned(value bool)
- func (u *UpdateShortChatMessage) SetOut(value bool)
- func (u *UpdateShortChatMessage) SetReplyTo(value MessageReplyHeader)
- func (u *UpdateShortChatMessage) SetSilent(value bool)
- func (u *UpdateShortChatMessage) SetViaBotID(value int)
- func (u *UpdateShortChatMessage) String() string
- type UpdateShortMessage
- func (u *UpdateShortMessage) Decode(b *bin.Buffer) error
- func (u *UpdateShortMessage) Encode(b *bin.Buffer) error
- func (u *UpdateShortMessage) GetEntities() (value []MessageEntityClass, ok bool)
- func (u *UpdateShortMessage) GetFwdFrom() (value MessageFwdHeader, ok bool)
- func (u *UpdateShortMessage) GetReplyTo() (value MessageReplyHeader, ok bool)
- func (u *UpdateShortMessage) GetViaBotID() (value int, ok bool)
- func (u *UpdateShortMessage) SetEntities(value []MessageEntityClass)
- func (u *UpdateShortMessage) SetFwdFrom(value MessageFwdHeader)
- func (u *UpdateShortMessage) SetMediaUnread(value bool)
- func (u *UpdateShortMessage) SetMentioned(value bool)
- func (u *UpdateShortMessage) SetOut(value bool)
- func (u *UpdateShortMessage) SetReplyTo(value MessageReplyHeader)
- func (u *UpdateShortMessage) SetSilent(value bool)
- func (u *UpdateShortMessage) SetViaBotID(value int)
- func (u *UpdateShortMessage) String() string
- type UpdateShortSentMessage
- func (u *UpdateShortSentMessage) Decode(b *bin.Buffer) error
- func (u *UpdateShortSentMessage) Encode(b *bin.Buffer) error
- func (u *UpdateShortSentMessage) GetEntities() (value []MessageEntityClass, ok bool)
- func (u *UpdateShortSentMessage) GetMedia() (value MessageMediaClass, ok bool)
- func (u *UpdateShortSentMessage) SetEntities(value []MessageEntityClass)
- func (u *UpdateShortSentMessage) SetMedia(value MessageMediaClass)
- func (u *UpdateShortSentMessage) SetOut(value bool)
- func (u *UpdateShortSentMessage) String() string
- type UpdateStickerSets
- type UpdateStickerSetsOrder
- type UpdateTheme
- type UpdateUserName
- type UpdateUserPhone
- type UpdateUserPhoto
- type UpdateUserStatus
- type UpdateUserTyping
- type UpdateWebPage
- type Updates
- type UpdatesBox
- type UpdatesChannelDifference
- func (c *UpdatesChannelDifference) Decode(b *bin.Buffer) error
- func (c *UpdatesChannelDifference) Encode(b *bin.Buffer) error
- func (c *UpdatesChannelDifference) GetTimeout() (value int, ok bool)
- func (c *UpdatesChannelDifference) SetFinal(value bool)
- func (c *UpdatesChannelDifference) SetTimeout(value int)
- func (c *UpdatesChannelDifference) String() string
- type UpdatesChannelDifferenceBox
- type UpdatesChannelDifferenceClass
- type UpdatesChannelDifferenceEmpty
- func (c *UpdatesChannelDifferenceEmpty) Decode(b *bin.Buffer) error
- func (c *UpdatesChannelDifferenceEmpty) Encode(b *bin.Buffer) error
- func (c *UpdatesChannelDifferenceEmpty) GetTimeout() (value int, ok bool)
- func (c *UpdatesChannelDifferenceEmpty) SetFinal(value bool)
- func (c *UpdatesChannelDifferenceEmpty) SetTimeout(value int)
- func (c *UpdatesChannelDifferenceEmpty) String() string
- type UpdatesChannelDifferenceTooLong
- func (c *UpdatesChannelDifferenceTooLong) Decode(b *bin.Buffer) error
- func (c *UpdatesChannelDifferenceTooLong) Encode(b *bin.Buffer) error
- func (c *UpdatesChannelDifferenceTooLong) GetTimeout() (value int, ok bool)
- func (c *UpdatesChannelDifferenceTooLong) SetFinal(value bool)
- func (c *UpdatesChannelDifferenceTooLong) SetTimeout(value int)
- func (c *UpdatesChannelDifferenceTooLong) String() string
- type UpdatesClass
- type UpdatesCombined
- type UpdatesDifference
- type UpdatesDifferenceBox
- type UpdatesDifferenceClass
- type UpdatesDifferenceEmpty
- type UpdatesDifferenceSlice
- type UpdatesDifferenceTooLong
- type UpdatesGetChannelDifferenceRequest
- type UpdatesGetDifferenceRequest
- func (g *UpdatesGetDifferenceRequest) Decode(b *bin.Buffer) error
- func (g *UpdatesGetDifferenceRequest) Encode(b *bin.Buffer) error
- func (g *UpdatesGetDifferenceRequest) GetPtsTotalLimit() (value int, ok bool)
- func (g *UpdatesGetDifferenceRequest) SetPtsTotalLimit(value int)
- func (g *UpdatesGetDifferenceRequest) String() string
- type UpdatesGetStateRequest
- type UpdatesState
- type UpdatesTooLong
- type UploadCdnFile
- type UploadCdnFileBox
- type UploadCdnFileClass
- type UploadCdnFileReuploadNeeded
- type UploadFile
- type UploadFileBox
- type UploadFileCdnRedirect
- type UploadFileClass
- type UploadGetCdnFileHashesRequest
- type UploadGetCdnFileRequest
- type UploadGetFileHashesRequest
- type UploadGetFileRequest
- type UploadGetWebFileRequest
- type UploadReuploadCdnFileRequest
- type UploadSaveBigFilePartRequest
- type UploadSaveFilePartRequest
- type UploadWebFile
- type UrlAuthResultAccepted
- type UrlAuthResultBox
- type UrlAuthResultClass
- type UrlAuthResultDefault
- type UrlAuthResultRequest
- type User
- func (u *User) Decode(b *bin.Buffer) error
- func (u *User) Encode(b *bin.Buffer) error
- func (u *User) GetAccessHash() (value int64, ok bool)
- func (u *User) GetBotInfoVersion() (value int, ok bool)
- func (u *User) GetBotInlinePlaceholder() (value string, ok bool)
- func (u *User) GetFirstName() (value string, ok bool)
- func (u *User) GetLangCode() (value string, ok bool)
- func (u *User) GetLastName() (value string, ok bool)
- func (u *User) GetPhone() (value string, ok bool)
- func (u *User) GetPhoto() (value UserProfilePhotoClass, ok bool)
- func (u *User) GetRestrictionReason() (value []RestrictionReason, ok bool)
- func (u *User) GetStatus() (value UserStatusClass, ok bool)
- func (u *User) GetUsername() (value string, ok bool)
- func (u *User) SetAccessHash(value int64)
- func (u *User) SetApplyMinPhoto(value bool)
- func (u *User) SetBot(value bool)
- func (u *User) SetBotChatHistory(value bool)
- func (u *User) SetBotInfoVersion(value int)
- func (u *User) SetBotInlineGeo(value bool)
- func (u *User) SetBotInlinePlaceholder(value string)
- func (u *User) SetBotNochats(value bool)
- func (u *User) SetContact(value bool)
- func (u *User) SetDeleted(value bool)
- func (u *User) SetFirstName(value string)
- func (u *User) SetLangCode(value string)
- func (u *User) SetLastName(value string)
- func (u *User) SetMin(value bool)
- func (u *User) SetMutualContact(value bool)
- func (u *User) SetPhone(value string)
- func (u *User) SetPhoto(value UserProfilePhotoClass)
- func (u *User) SetRestricted(value bool)
- func (u *User) SetRestrictionReason(value []RestrictionReason)
- func (u *User) SetScam(value bool)
- func (u *User) SetSelf(value bool)
- func (u *User) SetStatus(value UserStatusClass)
- func (u *User) SetSupport(value bool)
- func (u *User) SetUsername(value string)
- func (u *User) SetVerified(value bool)
- func (u *User) String() string
- type UserBox
- type UserClass
- type UserClassVector
- type UserEmpty
- type UserFull
- func (u *UserFull) Decode(b *bin.Buffer) error
- func (u *UserFull) Encode(b *bin.Buffer) error
- func (u *UserFull) GetAbout() (value string, ok bool)
- func (u *UserFull) GetBotInfo() (value BotInfo, ok bool)
- func (u *UserFull) GetFolderID() (value int, ok bool)
- func (u *UserFull) GetPinnedMsgID() (value int, ok bool)
- func (u *UserFull) GetProfilePhoto() (value PhotoClass, ok bool)
- func (u *UserFull) SetAbout(value string)
- func (u *UserFull) SetBlocked(value bool)
- func (u *UserFull) SetBotInfo(value BotInfo)
- func (u *UserFull) SetCanPinMessage(value bool)
- func (u *UserFull) SetFolderID(value int)
- func (u *UserFull) SetHasScheduled(value bool)
- func (u *UserFull) SetPhoneCallsAvailable(value bool)
- func (u *UserFull) SetPhoneCallsPrivate(value bool)
- func (u *UserFull) SetPinnedMsgID(value int)
- func (u *UserFull) SetProfilePhoto(value PhotoClass)
- func (u *UserFull) SetVideoCallsAvailable(value bool)
- func (u *UserFull) String() string
- type UserNameHandler
- type UserPhoneHandler
- type UserPhotoHandler
- type UserProfilePhoto
- type UserProfilePhotoBox
- type UserProfilePhotoClass
- type UserProfilePhotoEmpty
- type UserStatusBox
- type UserStatusClass
- type UserStatusEmpty
- type UserStatusHandler
- type UserStatusLastMonth
- type UserStatusLastWeek
- type UserStatusOffline
- type UserStatusOnline
- type UserStatusRecently
- type UserTypingHandler
- type UsersGetFullUserRequest
- type UsersGetUsersRequest
- type UsersSetSecureValueErrorsRequest
- type VideoSize
- type WallPaper
- func (w *WallPaper) Decode(b *bin.Buffer) error
- func (w *WallPaper) Encode(b *bin.Buffer) error
- func (w *WallPaper) GetSettings() (value WallPaperSettings, ok bool)
- func (w *WallPaper) SetCreator(value bool)
- func (w *WallPaper) SetDark(value bool)
- func (w *WallPaper) SetDefault(value bool)
- func (w *WallPaper) SetPattern(value bool)
- func (w *WallPaper) SetSettings(value WallPaperSettings)
- func (w *WallPaper) String() string
- type WallPaperBox
- type WallPaperClass
- type WallPaperClassVector
- type WallPaperNoFile
- func (w *WallPaperNoFile) Decode(b *bin.Buffer) error
- func (w *WallPaperNoFile) Encode(b *bin.Buffer) error
- func (w *WallPaperNoFile) GetSettings() (value WallPaperSettings, ok bool)
- func (w *WallPaperNoFile) SetDark(value bool)
- func (w *WallPaperNoFile) SetDefault(value bool)
- func (w *WallPaperNoFile) SetSettings(value WallPaperSettings)
- func (w *WallPaperNoFile) String() string
- type WallPaperSettings
- func (w *WallPaperSettings) Decode(b *bin.Buffer) error
- func (w *WallPaperSettings) Encode(b *bin.Buffer) error
- func (w *WallPaperSettings) GetBackgroundColor() (value int, ok bool)
- func (w *WallPaperSettings) GetIntensity() (value int, ok bool)
- func (w *WallPaperSettings) GetRotation() (value int, ok bool)
- func (w *WallPaperSettings) GetSecondBackgroundColor() (value int, ok bool)
- func (w *WallPaperSettings) SetBackgroundColor(value int)
- func (w *WallPaperSettings) SetBlur(value bool)
- func (w *WallPaperSettings) SetIntensity(value int)
- func (w *WallPaperSettings) SetMotion(value bool)
- func (w *WallPaperSettings) SetRotation(value int)
- func (w *WallPaperSettings) SetSecondBackgroundColor(value int)
- func (w *WallPaperSettings) String() string
- type WebAuthorization
- type WebDocument
- type WebDocumentBox
- type WebDocumentClass
- type WebDocumentNoProxy
- type WebPage
- func (w *WebPage) Decode(b *bin.Buffer) error
- func (w *WebPage) Encode(b *bin.Buffer) error
- func (w *WebPage) GetAttributes() (value []WebPageAttributeTheme, ok bool)
- func (w *WebPage) GetAuthor() (value string, ok bool)
- func (w *WebPage) GetCachedPage() (value Page, ok bool)
- func (w *WebPage) GetDescription() (value string, ok bool)
- func (w *WebPage) GetDocument() (value DocumentClass, ok bool)
- func (w *WebPage) GetDuration() (value int, ok bool)
- func (w *WebPage) GetEmbedHeight() (value int, ok bool)
- func (w *WebPage) GetEmbedType() (value string, ok bool)
- func (w *WebPage) GetEmbedURL() (value string, ok bool)
- func (w *WebPage) GetEmbedWidth() (value int, ok bool)
- func (w *WebPage) GetPhoto() (value PhotoClass, ok bool)
- func (w *WebPage) GetSiteName() (value string, ok bool)
- func (w *WebPage) GetTitle() (value string, ok bool)
- func (w *WebPage) GetType() (value string, ok bool)
- func (w *WebPage) SetAttributes(value []WebPageAttributeTheme)
- func (w *WebPage) SetAuthor(value string)
- func (w *WebPage) SetCachedPage(value Page)
- func (w *WebPage) SetDescription(value string)
- func (w *WebPage) SetDocument(value DocumentClass)
- func (w *WebPage) SetDuration(value int)
- func (w *WebPage) SetEmbedHeight(value int)
- func (w *WebPage) SetEmbedType(value string)
- func (w *WebPage) SetEmbedURL(value string)
- func (w *WebPage) SetEmbedWidth(value int)
- func (w *WebPage) SetPhoto(value PhotoClass)
- func (w *WebPage) SetSiteName(value string)
- func (w *WebPage) SetTitle(value string)
- func (w *WebPage) SetType(value string)
- func (w *WebPage) String() string
- type WebPageAttributeTheme
- func (w *WebPageAttributeTheme) Decode(b *bin.Buffer) error
- func (w *WebPageAttributeTheme) Encode(b *bin.Buffer) error
- func (w *WebPageAttributeTheme) GetDocuments() (value []DocumentClass, ok bool)
- func (w *WebPageAttributeTheme) GetSettings() (value ThemeSettings, ok bool)
- func (w *WebPageAttributeTheme) SetDocuments(value []DocumentClass)
- func (w *WebPageAttributeTheme) SetSettings(value ThemeSettings)
- func (w *WebPageAttributeTheme) String() string
- type WebPageBox
- type WebPageClass
- type WebPageEmpty
- type WebPageHandler
- type WebPageNotModified
- type WebPagePending
Constants ¶
const AccountAcceptAuthorizationRequestTypeID = 0xe7027c94
AccountAcceptAuthorizationRequestTypeID is TL type id of AccountAcceptAuthorizationRequest.
const AccountAuthorizationFormTypeID = 0xad2e1cd8
AccountAuthorizationFormTypeID is TL type id of AccountAuthorizationForm.
const AccountAuthorizationsTypeID = 0x1250abde
AccountAuthorizationsTypeID is TL type id of AccountAuthorizations.
const AccountAutoDownloadSettingsTypeID = 0x63cacf26
AccountAutoDownloadSettingsTypeID is TL type id of AccountAutoDownloadSettings.
const AccountCancelPasswordEmailRequestTypeID = 0xc1cbd5b6
AccountCancelPasswordEmailRequestTypeID is TL type id of AccountCancelPasswordEmailRequest.
const AccountChangePhoneRequestTypeID = 0x70c32edb
AccountChangePhoneRequestTypeID is TL type id of AccountChangePhoneRequest.
const AccountCheckUsernameRequestTypeID = 0x2714d86c
AccountCheckUsernameRequestTypeID is TL type id of AccountCheckUsernameRequest.
const AccountConfirmPasswordEmailRequestTypeID = 0x8fdf1920
AccountConfirmPasswordEmailRequestTypeID is TL type id of AccountConfirmPasswordEmailRequest.
const AccountConfirmPhoneRequestTypeID = 0x5f2178c3
AccountConfirmPhoneRequestTypeID is TL type id of AccountConfirmPhoneRequest.
const AccountContentSettingsTypeID = 0x57e28221
AccountContentSettingsTypeID is TL type id of AccountContentSettings.
const AccountCreateThemeRequestTypeID = 0x8432c21f
AccountCreateThemeRequestTypeID is TL type id of AccountCreateThemeRequest.
const AccountDaysTTLTypeID = 0xb8d0afdf
AccountDaysTTLTypeID is TL type id of AccountDaysTTL.
const AccountDeleteAccountRequestTypeID = 0x418d4e0b
AccountDeleteAccountRequestTypeID is TL type id of AccountDeleteAccountRequest.
const AccountDeleteSecureValueRequestTypeID = 0xb880bc4b
AccountDeleteSecureValueRequestTypeID is TL type id of AccountDeleteSecureValueRequest.
const AccountFinishTakeoutSessionRequestTypeID = 0x1d2652ee
AccountFinishTakeoutSessionRequestTypeID is TL type id of AccountFinishTakeoutSessionRequest.
const AccountGetAccountTTLRequestTypeID = 0x8fc711d
AccountGetAccountTTLRequestTypeID is TL type id of AccountGetAccountTTLRequest.
const AccountGetAllSecureValuesRequestTypeID = 0xb288bc7d
AccountGetAllSecureValuesRequestTypeID is TL type id of AccountGetAllSecureValuesRequest.
const AccountGetAuthorizationFormRequestTypeID = 0xb86ba8e1
AccountGetAuthorizationFormRequestTypeID is TL type id of AccountGetAuthorizationFormRequest.
const AccountGetAuthorizationsRequestTypeID = 0xe320c158
AccountGetAuthorizationsRequestTypeID is TL type id of AccountGetAuthorizationsRequest.
const AccountGetAutoDownloadSettingsRequestTypeID = 0x56da0b3f
AccountGetAutoDownloadSettingsRequestTypeID is TL type id of AccountGetAutoDownloadSettingsRequest.
const AccountGetContactSignUpNotificationRequestTypeID = 0x9f07c728
AccountGetContactSignUpNotificationRequestTypeID is TL type id of AccountGetContactSignUpNotificationRequest.
const AccountGetContentSettingsRequestTypeID = 0x8b9b4dae
AccountGetContentSettingsRequestTypeID is TL type id of AccountGetContentSettingsRequest.
const AccountGetGlobalPrivacySettingsRequestTypeID = 0xeb2b4cf6
AccountGetGlobalPrivacySettingsRequestTypeID is TL type id of AccountGetGlobalPrivacySettingsRequest.
const AccountGetMultiWallPapersRequestTypeID = 0x65ad71dc
AccountGetMultiWallPapersRequestTypeID is TL type id of AccountGetMultiWallPapersRequest.
const AccountGetNotifyExceptionsRequestTypeID = 0x53577479
AccountGetNotifyExceptionsRequestTypeID is TL type id of AccountGetNotifyExceptionsRequest.
const AccountGetNotifySettingsRequestTypeID = 0x12b3ad31
AccountGetNotifySettingsRequestTypeID is TL type id of AccountGetNotifySettingsRequest.
const AccountGetPasswordRequestTypeID = 0x548a30f5
AccountGetPasswordRequestTypeID is TL type id of AccountGetPasswordRequest.
const AccountGetPasswordSettingsRequestTypeID = 0x9cd4eaf9
AccountGetPasswordSettingsRequestTypeID is TL type id of AccountGetPasswordSettingsRequest.
const AccountGetPrivacyRequestTypeID = 0xdadbc950
AccountGetPrivacyRequestTypeID is TL type id of AccountGetPrivacyRequest.
const AccountGetSecureValueRequestTypeID = 0x73665bc2
AccountGetSecureValueRequestTypeID is TL type id of AccountGetSecureValueRequest.
const AccountGetThemeRequestTypeID = 0x8d9d742b
AccountGetThemeRequestTypeID is TL type id of AccountGetThemeRequest.
const AccountGetThemesRequestTypeID = 0x285946f8
AccountGetThemesRequestTypeID is TL type id of AccountGetThemesRequest.
const AccountGetTmpPasswordRequestTypeID = 0x449e0b51
AccountGetTmpPasswordRequestTypeID is TL type id of AccountGetTmpPasswordRequest.
const AccountGetWallPaperRequestTypeID = 0xfc8ddbea
AccountGetWallPaperRequestTypeID is TL type id of AccountGetWallPaperRequest.
const AccountGetWallPapersRequestTypeID = 0xaabb1763
AccountGetWallPapersRequestTypeID is TL type id of AccountGetWallPapersRequest.
const AccountGetWebAuthorizationsRequestTypeID = 0x182e6d6f
AccountGetWebAuthorizationsRequestTypeID is TL type id of AccountGetWebAuthorizationsRequest.
const AccountInitTakeoutSessionRequestTypeID = 0xf05b4804
AccountInitTakeoutSessionRequestTypeID is TL type id of AccountInitTakeoutSessionRequest.
const AccountInstallThemeRequestTypeID = 0x7ae43737
AccountInstallThemeRequestTypeID is TL type id of AccountInstallThemeRequest.
const AccountInstallWallPaperRequestTypeID = 0xfeed5769
AccountInstallWallPaperRequestTypeID is TL type id of AccountInstallWallPaperRequest.
const AccountPasswordInputSettingsTypeID = 0xc23727c9
AccountPasswordInputSettingsTypeID is TL type id of AccountPasswordInputSettings.
const AccountPasswordSettingsTypeID = 0x9a5c33e5
AccountPasswordSettingsTypeID is TL type id of AccountPasswordSettings.
const AccountPasswordTypeID = 0xad2641f8
AccountPasswordTypeID is TL type id of AccountPassword.
const AccountPrivacyRulesTypeID = 0x50a04e45
AccountPrivacyRulesTypeID is TL type id of AccountPrivacyRules.
const AccountRegisterDeviceRequestTypeID = 0x68976c6f
AccountRegisterDeviceRequestTypeID is TL type id of AccountRegisterDeviceRequest.
const AccountReportPeerRequestTypeID = 0xae189d5f
AccountReportPeerRequestTypeID is TL type id of AccountReportPeerRequest.
const AccountResendPasswordEmailRequestTypeID = 0x7a7f2a15
AccountResendPasswordEmailRequestTypeID is TL type id of AccountResendPasswordEmailRequest.
const AccountResetAuthorizationRequestTypeID = 0xdf77f3bc
AccountResetAuthorizationRequestTypeID is TL type id of AccountResetAuthorizationRequest.
const AccountResetNotifySettingsRequestTypeID = 0xdb7e1747
AccountResetNotifySettingsRequestTypeID is TL type id of AccountResetNotifySettingsRequest.
const AccountResetWallPapersRequestTypeID = 0xbb3b9804
AccountResetWallPapersRequestTypeID is TL type id of AccountResetWallPapersRequest.
const AccountResetWebAuthorizationRequestTypeID = 0x2d01b9ef
AccountResetWebAuthorizationRequestTypeID is TL type id of AccountResetWebAuthorizationRequest.
const AccountResetWebAuthorizationsRequestTypeID = 0x682d2594
AccountResetWebAuthorizationsRequestTypeID is TL type id of AccountResetWebAuthorizationsRequest.
const AccountSaveAutoDownloadSettingsRequestTypeID = 0x76f36233
AccountSaveAutoDownloadSettingsRequestTypeID is TL type id of AccountSaveAutoDownloadSettingsRequest.
const AccountSaveSecureValueRequestTypeID = 0x899fe31d
AccountSaveSecureValueRequestTypeID is TL type id of AccountSaveSecureValueRequest.
const AccountSaveThemeRequestTypeID = 0xf257106c
AccountSaveThemeRequestTypeID is TL type id of AccountSaveThemeRequest.
const AccountSaveWallPaperRequestTypeID = 0x6c5a5b37
AccountSaveWallPaperRequestTypeID is TL type id of AccountSaveWallPaperRequest.
const AccountSendChangePhoneCodeRequestTypeID = 0x82574ae5
AccountSendChangePhoneCodeRequestTypeID is TL type id of AccountSendChangePhoneCodeRequest.
const AccountSendConfirmPhoneCodeRequestTypeID = 0x1b3faa88
AccountSendConfirmPhoneCodeRequestTypeID is TL type id of AccountSendConfirmPhoneCodeRequest.
const AccountSendVerifyEmailCodeRequestTypeID = 0x7011509f
AccountSendVerifyEmailCodeRequestTypeID is TL type id of AccountSendVerifyEmailCodeRequest.
const AccountSendVerifyPhoneCodeRequestTypeID = 0xa5a356f9
AccountSendVerifyPhoneCodeRequestTypeID is TL type id of AccountSendVerifyPhoneCodeRequest.
const AccountSentEmailCodeTypeID = 0x811f854f
AccountSentEmailCodeTypeID is TL type id of AccountSentEmailCode.
const AccountSetAccountTTLRequestTypeID = 0x2442485e
AccountSetAccountTTLRequestTypeID is TL type id of AccountSetAccountTTLRequest.
const AccountSetContactSignUpNotificationRequestTypeID = 0xcff43f61
AccountSetContactSignUpNotificationRequestTypeID is TL type id of AccountSetContactSignUpNotificationRequest.
const AccountSetContentSettingsRequestTypeID = 0xb574b16b
AccountSetContentSettingsRequestTypeID is TL type id of AccountSetContentSettingsRequest.
const AccountSetGlobalPrivacySettingsRequestTypeID = 0x1edaaac2
AccountSetGlobalPrivacySettingsRequestTypeID is TL type id of AccountSetGlobalPrivacySettingsRequest.
const AccountSetPrivacyRequestTypeID = 0xc9f81ce8
AccountSetPrivacyRequestTypeID is TL type id of AccountSetPrivacyRequest.
const AccountTakeoutTypeID = 0x4dba4501
AccountTakeoutTypeID is TL type id of AccountTakeout.
const AccountThemesNotModifiedTypeID = 0xf41eb622
AccountThemesNotModifiedTypeID is TL type id of AccountThemesNotModified.
const AccountThemesTypeID = 0x7f676421
AccountThemesTypeID is TL type id of AccountThemes.
const AccountTmpPasswordTypeID = 0xdb64fd34
AccountTmpPasswordTypeID is TL type id of AccountTmpPassword.
const AccountUnregisterDeviceRequestTypeID = 0x3076c4bf
AccountUnregisterDeviceRequestTypeID is TL type id of AccountUnregisterDeviceRequest.
const AccountUpdateDeviceLockedRequestTypeID = 0x38df3532
AccountUpdateDeviceLockedRequestTypeID is TL type id of AccountUpdateDeviceLockedRequest.
const AccountUpdateNotifySettingsRequestTypeID = 0x84be5b93
AccountUpdateNotifySettingsRequestTypeID is TL type id of AccountUpdateNotifySettingsRequest.
const AccountUpdatePasswordSettingsRequestTypeID = 0xa59b102f
AccountUpdatePasswordSettingsRequestTypeID is TL type id of AccountUpdatePasswordSettingsRequest.
const AccountUpdateProfileRequestTypeID = 0x78515775
AccountUpdateProfileRequestTypeID is TL type id of AccountUpdateProfileRequest.
const AccountUpdateStatusRequestTypeID = 0x6628562c
AccountUpdateStatusRequestTypeID is TL type id of AccountUpdateStatusRequest.
const AccountUpdateThemeRequestTypeID = 0x5cb367d5
AccountUpdateThemeRequestTypeID is TL type id of AccountUpdateThemeRequest.
const AccountUpdateUsernameRequestTypeID = 0x3e0bdd7c
AccountUpdateUsernameRequestTypeID is TL type id of AccountUpdateUsernameRequest.
const AccountUploadThemeRequestTypeID = 0x1c3db333
AccountUploadThemeRequestTypeID is TL type id of AccountUploadThemeRequest.
const AccountUploadWallPaperRequestTypeID = 0xdd853661
AccountUploadWallPaperRequestTypeID is TL type id of AccountUploadWallPaperRequest.
const AccountVerifyEmailRequestTypeID = 0xecba39db
AccountVerifyEmailRequestTypeID is TL type id of AccountVerifyEmailRequest.
const AccountVerifyPhoneRequestTypeID = 0x4dd3a7f6
AccountVerifyPhoneRequestTypeID is TL type id of AccountVerifyPhoneRequest.
const AccountWallPapersNotModifiedTypeID = 0x1c199183
AccountWallPapersNotModifiedTypeID is TL type id of AccountWallPapersNotModified.
const AccountWallPapersTypeID = 0x702b65a9
AccountWallPapersTypeID is TL type id of AccountWallPapers.
const AccountWebAuthorizationsTypeID = 0xed56c9fc
AccountWebAuthorizationsTypeID is TL type id of AccountWebAuthorizations.
const AuthAcceptLoginTokenRequestTypeID = 0xe894ad4d
AuthAcceptLoginTokenRequestTypeID is TL type id of AuthAcceptLoginTokenRequest.
const AuthAuthorizationSignUpRequiredTypeID = 0x44747e9a
AuthAuthorizationSignUpRequiredTypeID is TL type id of AuthAuthorizationSignUpRequired.
const AuthAuthorizationTypeID = 0xcd050916
AuthAuthorizationTypeID is TL type id of AuthAuthorization.
const AuthBindTempAuthKeyRequestTypeID = 0xcdd42a05
AuthBindTempAuthKeyRequestTypeID is TL type id of AuthBindTempAuthKeyRequest.
const AuthCancelCodeRequestTypeID = 0x1f040578
AuthCancelCodeRequestTypeID is TL type id of AuthCancelCodeRequest.
const AuthCheckPasswordRequestTypeID = 0xd18b4d16
AuthCheckPasswordRequestTypeID is TL type id of AuthCheckPasswordRequest.
const AuthCodeTypeCallTypeID = 0x741cd3e3
AuthCodeTypeCallTypeID is TL type id of AuthCodeTypeCall.
const AuthCodeTypeFlashCallTypeID = 0x226ccefb
AuthCodeTypeFlashCallTypeID is TL type id of AuthCodeTypeFlashCall.
const AuthCodeTypeSmsTypeID = 0x72a3158c
AuthCodeTypeSmsTypeID is TL type id of AuthCodeTypeSms.
const AuthDropTempAuthKeysRequestTypeID = 0x8e48a188
AuthDropTempAuthKeysRequestTypeID is TL type id of AuthDropTempAuthKeysRequest.
const AuthExportAuthorizationRequestTypeID = 0xe5bfffcd
AuthExportAuthorizationRequestTypeID is TL type id of AuthExportAuthorizationRequest.
const AuthExportLoginTokenRequestTypeID = 0xb1b41517
AuthExportLoginTokenRequestTypeID is TL type id of AuthExportLoginTokenRequest.
const AuthExportedAuthorizationTypeID = 0xdf969c2d
AuthExportedAuthorizationTypeID is TL type id of AuthExportedAuthorization.
const AuthImportAuthorizationRequestTypeID = 0xe3ef9613
AuthImportAuthorizationRequestTypeID is TL type id of AuthImportAuthorizationRequest.
const AuthImportBotAuthorizationRequestTypeID = 0x67a3ff2c
AuthImportBotAuthorizationRequestTypeID is TL type id of AuthImportBotAuthorizationRequest.
const AuthImportLoginTokenRequestTypeID = 0x95ac5ce4
AuthImportLoginTokenRequestTypeID is TL type id of AuthImportLoginTokenRequest.
const AuthLogOutRequestTypeID = 0x5717da40
AuthLogOutRequestTypeID is TL type id of AuthLogOutRequest.
const AuthLoginTokenMigrateToTypeID = 0x68e9916
AuthLoginTokenMigrateToTypeID is TL type id of AuthLoginTokenMigrateTo.
const AuthLoginTokenSuccessTypeID = 0x390d5c5e
AuthLoginTokenSuccessTypeID is TL type id of AuthLoginTokenSuccess.
const AuthLoginTokenTypeID = 0x629f1980
AuthLoginTokenTypeID is TL type id of AuthLoginToken.
const AuthPasswordRecoveryTypeID = 0x137948a5
AuthPasswordRecoveryTypeID is TL type id of AuthPasswordRecovery.
const AuthRecoverPasswordRequestTypeID = 0x4ea56e92
AuthRecoverPasswordRequestTypeID is TL type id of AuthRecoverPasswordRequest.
const AuthRequestPasswordRecoveryRequestTypeID = 0xd897bc66
AuthRequestPasswordRecoveryRequestTypeID is TL type id of AuthRequestPasswordRecoveryRequest.
const AuthResendCodeRequestTypeID = 0x3ef1a9bf
AuthResendCodeRequestTypeID is TL type id of AuthResendCodeRequest.
const AuthResetAuthorizationsRequestTypeID = 0x9fab0d1a
AuthResetAuthorizationsRequestTypeID is TL type id of AuthResetAuthorizationsRequest.
const AuthSendCodeRequestTypeID = 0xa677244f
AuthSendCodeRequestTypeID is TL type id of AuthSendCodeRequest.
const AuthSentCodeTypeAppTypeID = 0x3dbb5986
AuthSentCodeTypeAppTypeID is TL type id of AuthSentCodeTypeApp.
const AuthSentCodeTypeCallTypeID = 0x5353e5a7
AuthSentCodeTypeCallTypeID is TL type id of AuthSentCodeTypeCall.
const AuthSentCodeTypeFlashCallTypeID = 0xab03c6d9
AuthSentCodeTypeFlashCallTypeID is TL type id of AuthSentCodeTypeFlashCall.
const AuthSentCodeTypeID = 0x5e002502
AuthSentCodeTypeID is TL type id of AuthSentCode.
const AuthSentCodeTypeSmsTypeID = 0xc000bba2
AuthSentCodeTypeSmsTypeID is TL type id of AuthSentCodeTypeSms.
const AuthSignInRequestTypeID = 0xbcd51581
AuthSignInRequestTypeID is TL type id of AuthSignInRequest.
const AuthSignUpRequestTypeID = 0x80eee427
AuthSignUpRequestTypeID is TL type id of AuthSignUpRequest.
const AuthorizationTypeID = 0xad01d61d
AuthorizationTypeID is TL type id of Authorization.
const AutoDownloadSettingsTypeID = 0xe04232f3
AutoDownloadSettingsTypeID is TL type id of AutoDownloadSettings.
const BankCardOpenUrlTypeID = 0xf568028a
BankCardOpenUrlTypeID is TL type id of BankCardOpenUrl.
const BaseThemeArcticTypeID = 0x5b11125a
BaseThemeArcticTypeID is TL type id of BaseThemeArctic.
const BaseThemeClassicTypeID = 0xc3a12462
BaseThemeClassicTypeID is TL type id of BaseThemeClassic.
const BaseThemeDayTypeID = 0xfbd81688
BaseThemeDayTypeID is TL type id of BaseThemeDay.
const BaseThemeNightTypeID = 0xb7b31ea8
BaseThemeNightTypeID is TL type id of BaseThemeNight.
const BaseThemeTintedTypeID = 0x6d5f77ee
BaseThemeTintedTypeID is TL type id of BaseThemeTinted.
const BoolFalseTypeID = 0xbc799737
BoolFalseTypeID is TL type id of BoolFalse.
const BoolTrueTypeID = 0x997275b5
BoolTrueTypeID is TL type id of BoolTrue.
const BotCommandTypeID = 0xc27ac8c7
BotCommandTypeID is TL type id of BotCommand.
const BotInfoTypeID = 0x98e81d3a
BotInfoTypeID is TL type id of BotInfo.
const BotInlineMediaResultTypeID = 0x17db940b
BotInlineMediaResultTypeID is TL type id of BotInlineMediaResult.
const BotInlineMessageMediaAutoTypeID = 0x764cf810
BotInlineMessageMediaAutoTypeID is TL type id of BotInlineMessageMediaAuto.
const BotInlineMessageMediaContactTypeID = 0x18d1cdc2
BotInlineMessageMediaContactTypeID is TL type id of BotInlineMessageMediaContact.
const BotInlineMessageMediaGeoTypeID = 0x51846fd
BotInlineMessageMediaGeoTypeID is TL type id of BotInlineMessageMediaGeo.
const BotInlineMessageMediaVenueTypeID = 0x8a86659c
BotInlineMessageMediaVenueTypeID is TL type id of BotInlineMessageMediaVenue.
const BotInlineMessageTextTypeID = 0x8c7f65e2
BotInlineMessageTextTypeID is TL type id of BotInlineMessageText.
const BotInlineResultTypeID = 0x11965f3a
BotInlineResultTypeID is TL type id of BotInlineResult.
const BotsAnswerWebhookJSONQueryRequestTypeID = 0xe6213f4d
BotsAnswerWebhookJSONQueryRequestTypeID is TL type id of BotsAnswerWebhookJSONQueryRequest.
const BotsSendCustomRequestRequestTypeID = 0xaa2769ed
BotsSendCustomRequestRequestTypeID is TL type id of BotsSendCustomRequestRequest.
const BotsSetBotCommandsRequestTypeID = 0x805d46f6
BotsSetBotCommandsRequestTypeID is TL type id of BotsSetBotCommandsRequest.
const CdnConfigTypeID = 0x5725e40a
CdnConfigTypeID is TL type id of CdnConfig.
const CdnPublicKeyTypeID = 0xc982eaba
CdnPublicKeyTypeID is TL type id of CdnPublicKey.
const ChannelAdminLogEventActionChangeAboutTypeID = 0x55188a2e
ChannelAdminLogEventActionChangeAboutTypeID is TL type id of ChannelAdminLogEventActionChangeAbout.
const ChannelAdminLogEventActionChangeLinkedChatTypeID = 0xa26f881b
ChannelAdminLogEventActionChangeLinkedChatTypeID is TL type id of ChannelAdminLogEventActionChangeLinkedChat.
const ChannelAdminLogEventActionChangeLocationTypeID = 0xe6b76ae
ChannelAdminLogEventActionChangeLocationTypeID is TL type id of ChannelAdminLogEventActionChangeLocation.
const ChannelAdminLogEventActionChangePhotoTypeID = 0x434bd2af
ChannelAdminLogEventActionChangePhotoTypeID is TL type id of ChannelAdminLogEventActionChangePhoto.
const ChannelAdminLogEventActionChangeStickerSetTypeID = 0xb1c3caa7
ChannelAdminLogEventActionChangeStickerSetTypeID is TL type id of ChannelAdminLogEventActionChangeStickerSet.
const ChannelAdminLogEventActionChangeTitleTypeID = 0xe6dfb825
ChannelAdminLogEventActionChangeTitleTypeID is TL type id of ChannelAdminLogEventActionChangeTitle.
const ChannelAdminLogEventActionChangeUsernameTypeID = 0x6a4afc38
ChannelAdminLogEventActionChangeUsernameTypeID is TL type id of ChannelAdminLogEventActionChangeUsername.
const ChannelAdminLogEventActionDefaultBannedRightsTypeID = 0x2df5fc0a
ChannelAdminLogEventActionDefaultBannedRightsTypeID is TL type id of ChannelAdminLogEventActionDefaultBannedRights.
const ChannelAdminLogEventActionDeleteMessageTypeID = 0x42e047bb
ChannelAdminLogEventActionDeleteMessageTypeID is TL type id of ChannelAdminLogEventActionDeleteMessage.
const ChannelAdminLogEventActionDiscardGroupCallTypeID = 0xdb9f9140
ChannelAdminLogEventActionDiscardGroupCallTypeID is TL type id of ChannelAdminLogEventActionDiscardGroupCall.
const ChannelAdminLogEventActionEditMessageTypeID = 0x709b2405
ChannelAdminLogEventActionEditMessageTypeID is TL type id of ChannelAdminLogEventActionEditMessage.
const ChannelAdminLogEventActionParticipantInviteTypeID = 0xe31c34d8
ChannelAdminLogEventActionParticipantInviteTypeID is TL type id of ChannelAdminLogEventActionParticipantInvite.
const ChannelAdminLogEventActionParticipantJoinTypeID = 0x183040d3
ChannelAdminLogEventActionParticipantJoinTypeID is TL type id of ChannelAdminLogEventActionParticipantJoin.
const ChannelAdminLogEventActionParticipantLeaveTypeID = 0xf89777f2
ChannelAdminLogEventActionParticipantLeaveTypeID is TL type id of ChannelAdminLogEventActionParticipantLeave.
const ChannelAdminLogEventActionParticipantMuteTypeID = 0xf92424d2
ChannelAdminLogEventActionParticipantMuteTypeID is TL type id of ChannelAdminLogEventActionParticipantMute.
const ChannelAdminLogEventActionParticipantToggleAdminTypeID = 0xd5676710
ChannelAdminLogEventActionParticipantToggleAdminTypeID is TL type id of ChannelAdminLogEventActionParticipantToggleAdmin.
const ChannelAdminLogEventActionParticipantToggleBanTypeID = 0xe6d83d7e
ChannelAdminLogEventActionParticipantToggleBanTypeID is TL type id of ChannelAdminLogEventActionParticipantToggleBan.
const ChannelAdminLogEventActionParticipantUnmuteTypeID = 0xe64429c0
ChannelAdminLogEventActionParticipantUnmuteTypeID is TL type id of ChannelAdminLogEventActionParticipantUnmute.
const ChannelAdminLogEventActionStartGroupCallTypeID = 0x23209745
ChannelAdminLogEventActionStartGroupCallTypeID is TL type id of ChannelAdminLogEventActionStartGroupCall.
const ChannelAdminLogEventActionStopPollTypeID = 0x8f079643
ChannelAdminLogEventActionStopPollTypeID is TL type id of ChannelAdminLogEventActionStopPoll.
const ChannelAdminLogEventActionToggleGroupCallSettingTypeID = 0x56d6a247
ChannelAdminLogEventActionToggleGroupCallSettingTypeID is TL type id of ChannelAdminLogEventActionToggleGroupCallSetting.
const ChannelAdminLogEventActionToggleInvitesTypeID = 0x1b7907ae
ChannelAdminLogEventActionToggleInvitesTypeID is TL type id of ChannelAdminLogEventActionToggleInvites.
const ChannelAdminLogEventActionTogglePreHistoryHiddenTypeID = 0x5f5c95f1
ChannelAdminLogEventActionTogglePreHistoryHiddenTypeID is TL type id of ChannelAdminLogEventActionTogglePreHistoryHidden.
const ChannelAdminLogEventActionToggleSignaturesTypeID = 0x26ae0971
ChannelAdminLogEventActionToggleSignaturesTypeID is TL type id of ChannelAdminLogEventActionToggleSignatures.
const ChannelAdminLogEventActionToggleSlowModeTypeID = 0x53909779
ChannelAdminLogEventActionToggleSlowModeTypeID is TL type id of ChannelAdminLogEventActionToggleSlowMode.
const ChannelAdminLogEventActionUpdatePinnedTypeID = 0xe9e82c18
ChannelAdminLogEventActionUpdatePinnedTypeID is TL type id of ChannelAdminLogEventActionUpdatePinned.
const ChannelAdminLogEventTypeID = 0x3b5a3e40
ChannelAdminLogEventTypeID is TL type id of ChannelAdminLogEvent.
const ChannelAdminLogEventsFilterTypeID = 0xea107ae4
ChannelAdminLogEventsFilterTypeID is TL type id of ChannelAdminLogEventsFilter.
const ChannelForbiddenTypeID = 0x289da732
ChannelForbiddenTypeID is TL type id of ChannelForbidden.
const ChannelFullTypeID = 0xef3a6acd
ChannelFullTypeID is TL type id of ChannelFull.
const ChannelLocationEmptyTypeID = 0xbfb5ad8b
ChannelLocationEmptyTypeID is TL type id of ChannelLocationEmpty.
const ChannelLocationTypeID = 0x209b82db
ChannelLocationTypeID is TL type id of ChannelLocation.
const ChannelMessagesFilterEmptyTypeID = 0x94d42ee7
ChannelMessagesFilterEmptyTypeID is TL type id of ChannelMessagesFilterEmpty.
const ChannelMessagesFilterTypeID = 0xcd77d957
ChannelMessagesFilterTypeID is TL type id of ChannelMessagesFilter.
const ChannelParticipantAdminTypeID = 0xccbebbaf
ChannelParticipantAdminTypeID is TL type id of ChannelParticipantAdmin.
const ChannelParticipantBannedTypeID = 0x1c0facaf
ChannelParticipantBannedTypeID is TL type id of ChannelParticipantBanned.
const ChannelParticipantCreatorTypeID = 0x447dca4b
ChannelParticipantCreatorTypeID is TL type id of ChannelParticipantCreator.
const ChannelParticipantLeftTypeID = 0xc3c6796b
ChannelParticipantLeftTypeID is TL type id of ChannelParticipantLeft.
const ChannelParticipantSelfTypeID = 0xa3289a6d
ChannelParticipantSelfTypeID is TL type id of ChannelParticipantSelf.
const ChannelParticipantTypeID = 0x15ebac1d
ChannelParticipantTypeID is TL type id of ChannelParticipant.
const ChannelParticipantsAdminsTypeID = 0xb4608969
ChannelParticipantsAdminsTypeID is TL type id of ChannelParticipantsAdmins.
const ChannelParticipantsBannedTypeID = 0x1427a5e1
ChannelParticipantsBannedTypeID is TL type id of ChannelParticipantsBanned.
const ChannelParticipantsBotsTypeID = 0xb0d1865b
ChannelParticipantsBotsTypeID is TL type id of ChannelParticipantsBots.
const ChannelParticipantsContactsTypeID = 0xbb6ae88d
ChannelParticipantsContactsTypeID is TL type id of ChannelParticipantsContacts.
const ChannelParticipantsKickedTypeID = 0xa3b54985
ChannelParticipantsKickedTypeID is TL type id of ChannelParticipantsKicked.
const ChannelParticipantsMentionsTypeID = 0xe04b5ceb
ChannelParticipantsMentionsTypeID is TL type id of ChannelParticipantsMentions.
const ChannelParticipantsRecentTypeID = 0xde3f3c79
ChannelParticipantsRecentTypeID is TL type id of ChannelParticipantsRecent.
const ChannelParticipantsSearchTypeID = 0x656ac4b
ChannelParticipantsSearchTypeID is TL type id of ChannelParticipantsSearch.
const ChannelTypeID = 0xd31a961e
ChannelTypeID is TL type id of Channel.
const ChannelsAdminLogResultsTypeID = 0xed8af74d
ChannelsAdminLogResultsTypeID is TL type id of ChannelsAdminLogResults.
const ChannelsChannelParticipantTypeID = 0xd0d9b163
ChannelsChannelParticipantTypeID is TL type id of ChannelsChannelParticipant.
const ChannelsChannelParticipantsNotModifiedTypeID = 0xf0173fe9
ChannelsChannelParticipantsNotModifiedTypeID is TL type id of ChannelsChannelParticipantsNotModified.
const ChannelsChannelParticipantsTypeID = 0xf56ee2a8
ChannelsChannelParticipantsTypeID is TL type id of ChannelsChannelParticipants.
const ChannelsCheckUsernameRequestTypeID = 0x10e6bd2c
ChannelsCheckUsernameRequestTypeID is TL type id of ChannelsCheckUsernameRequest.
const ChannelsCreateChannelRequestTypeID = 0x3d5fb10f
ChannelsCreateChannelRequestTypeID is TL type id of ChannelsCreateChannelRequest.
const ChannelsDeleteChannelRequestTypeID = 0xc0111fe3
ChannelsDeleteChannelRequestTypeID is TL type id of ChannelsDeleteChannelRequest.
const ChannelsDeleteHistoryRequestTypeID = 0xaf369d42
ChannelsDeleteHistoryRequestTypeID is TL type id of ChannelsDeleteHistoryRequest.
const ChannelsDeleteMessagesRequestTypeID = 0x84c1fd4e
ChannelsDeleteMessagesRequestTypeID is TL type id of ChannelsDeleteMessagesRequest.
const ChannelsDeleteUserHistoryRequestTypeID = 0xd10dd71b
ChannelsDeleteUserHistoryRequestTypeID is TL type id of ChannelsDeleteUserHistoryRequest.
const ChannelsEditAdminRequestTypeID = 0xd33c8902
ChannelsEditAdminRequestTypeID is TL type id of ChannelsEditAdminRequest.
const ChannelsEditBannedRequestTypeID = 0x72796912
ChannelsEditBannedRequestTypeID is TL type id of ChannelsEditBannedRequest.
const ChannelsEditCreatorRequestTypeID = 0x8f38cd1f
ChannelsEditCreatorRequestTypeID is TL type id of ChannelsEditCreatorRequest.
const ChannelsEditLocationRequestTypeID = 0x58e63f6d
ChannelsEditLocationRequestTypeID is TL type id of ChannelsEditLocationRequest.
const ChannelsEditPhotoRequestTypeID = 0xf12e57c9
ChannelsEditPhotoRequestTypeID is TL type id of ChannelsEditPhotoRequest.
const ChannelsEditTitleRequestTypeID = 0x566decd0
ChannelsEditTitleRequestTypeID is TL type id of ChannelsEditTitleRequest.
const ChannelsExportMessageLinkRequestTypeID = 0xe63fadeb
ChannelsExportMessageLinkRequestTypeID is TL type id of ChannelsExportMessageLinkRequest.
const ChannelsGetAdminLogRequestTypeID = 0x33ddf480
ChannelsGetAdminLogRequestTypeID is TL type id of ChannelsGetAdminLogRequest.
const ChannelsGetAdminedPublicChannelsRequestTypeID = 0xf8b036af
ChannelsGetAdminedPublicChannelsRequestTypeID is TL type id of ChannelsGetAdminedPublicChannelsRequest.
const ChannelsGetChannelsRequestTypeID = 0xa7f6bbb
ChannelsGetChannelsRequestTypeID is TL type id of ChannelsGetChannelsRequest.
const ChannelsGetFullChannelRequestTypeID = 0x8736a09
ChannelsGetFullChannelRequestTypeID is TL type id of ChannelsGetFullChannelRequest.
const ChannelsGetGroupsForDiscussionRequestTypeID = 0xf5dad378
ChannelsGetGroupsForDiscussionRequestTypeID is TL type id of ChannelsGetGroupsForDiscussionRequest.
const ChannelsGetInactiveChannelsRequestTypeID = 0x11e831ee
ChannelsGetInactiveChannelsRequestTypeID is TL type id of ChannelsGetInactiveChannelsRequest.
const ChannelsGetLeftChannelsRequestTypeID = 0x8341ecc0
ChannelsGetLeftChannelsRequestTypeID is TL type id of ChannelsGetLeftChannelsRequest.
const ChannelsGetMessagesRequestTypeID = 0xad8c9a23
ChannelsGetMessagesRequestTypeID is TL type id of ChannelsGetMessagesRequest.
const ChannelsGetParticipantRequestTypeID = 0x546dd7a6
ChannelsGetParticipantRequestTypeID is TL type id of ChannelsGetParticipantRequest.
const ChannelsGetParticipantsRequestTypeID = 0x123e05e9
ChannelsGetParticipantsRequestTypeID is TL type id of ChannelsGetParticipantsRequest.
const ChannelsInviteToChannelRequestTypeID = 0x199f3a6c
ChannelsInviteToChannelRequestTypeID is TL type id of ChannelsInviteToChannelRequest.
const ChannelsJoinChannelRequestTypeID = 0x24b524c5
ChannelsJoinChannelRequestTypeID is TL type id of ChannelsJoinChannelRequest.
const ChannelsLeaveChannelRequestTypeID = 0xf836aa95
ChannelsLeaveChannelRequestTypeID is TL type id of ChannelsLeaveChannelRequest.
const ChannelsReadHistoryRequestTypeID = 0xcc104937
ChannelsReadHistoryRequestTypeID is TL type id of ChannelsReadHistoryRequest.
const ChannelsReadMessageContentsRequestTypeID = 0xeab5dc38
ChannelsReadMessageContentsRequestTypeID is TL type id of ChannelsReadMessageContentsRequest.
const ChannelsReportSpamRequestTypeID = 0xfe087810
ChannelsReportSpamRequestTypeID is TL type id of ChannelsReportSpamRequest.
const ChannelsSetDiscussionGroupRequestTypeID = 0x40582bb2
ChannelsSetDiscussionGroupRequestTypeID is TL type id of ChannelsSetDiscussionGroupRequest.
const ChannelsSetStickersRequestTypeID = 0xea8ca4f9
ChannelsSetStickersRequestTypeID is TL type id of ChannelsSetStickersRequest.
const ChannelsTogglePreHistoryHiddenRequestTypeID = 0xeabbb94c
ChannelsTogglePreHistoryHiddenRequestTypeID is TL type id of ChannelsTogglePreHistoryHiddenRequest.
const ChannelsToggleSignaturesRequestTypeID = 0x1f69b606
ChannelsToggleSignaturesRequestTypeID is TL type id of ChannelsToggleSignaturesRequest.
const ChannelsToggleSlowModeRequestTypeID = 0xedd49ef0
ChannelsToggleSlowModeRequestTypeID is TL type id of ChannelsToggleSlowModeRequest.
const ChannelsUpdateUsernameRequestTypeID = 0x3514b3de
ChannelsUpdateUsernameRequestTypeID is TL type id of ChannelsUpdateUsernameRequest.
const ChatAdminRightsTypeID = 0x5fb224d5
ChatAdminRightsTypeID is TL type id of ChatAdminRights.
const ChatBannedRightsTypeID = 0x9f120418
ChatBannedRightsTypeID is TL type id of ChatBannedRights.
const ChatEmptyTypeID = 0x9ba2d800
ChatEmptyTypeID is TL type id of ChatEmpty.
const ChatForbiddenTypeID = 0x7328bdb
ChatForbiddenTypeID is TL type id of ChatForbidden.
const ChatFullTypeID = 0xdc8c181
ChatFullTypeID is TL type id of ChatFull.
const ChatInviteAlreadyTypeID = 0x5a686d7c
ChatInviteAlreadyTypeID is TL type id of ChatInviteAlready.
const ChatInviteEmptyTypeID = 0x69df3769
ChatInviteEmptyTypeID is TL type id of ChatInviteEmpty.
const ChatInviteExportedTypeID = 0xfc2e05bc
ChatInviteExportedTypeID is TL type id of ChatInviteExported.
const ChatInvitePeekTypeID = 0x61695cb0
ChatInvitePeekTypeID is TL type id of ChatInvitePeek.
const ChatInviteTypeID = 0xdfc2f58e
ChatInviteTypeID is TL type id of ChatInvite.
const ChatOnlinesTypeID = 0xf041e250
ChatOnlinesTypeID is TL type id of ChatOnlines.
const ChatParticipantAdminTypeID = 0xe2d6e436
ChatParticipantAdminTypeID is TL type id of ChatParticipantAdmin.
const ChatParticipantCreatorTypeID = 0xda13538a
ChatParticipantCreatorTypeID is TL type id of ChatParticipantCreator.
const ChatParticipantTypeID = 0xc8d7493e
ChatParticipantTypeID is TL type id of ChatParticipant.
const ChatParticipantsForbiddenTypeID = 0xfc900c2b
ChatParticipantsForbiddenTypeID is TL type id of ChatParticipantsForbidden.
const ChatParticipantsTypeID = 0x3f460fed
ChatParticipantsTypeID is TL type id of ChatParticipants.
const ChatPhotoEmptyTypeID = 0x37c1011c
ChatPhotoEmptyTypeID is TL type id of ChatPhotoEmpty.
const ChatPhotoTypeID = 0xd20b9f3c
ChatPhotoTypeID is TL type id of ChatPhoto.
const ChatTypeID = 0x3bda1bde
ChatTypeID is TL type id of Chat.
const CodeSettingsTypeID = 0xdebebe83
CodeSettingsTypeID is TL type id of CodeSettings.
const ConfigTypeID = 0x330b4067
ConfigTypeID is TL type id of Config.
const ContactStatusTypeID = 0xd3680c61
ContactStatusTypeID is TL type id of ContactStatus.
const ContactTypeID = 0xf911c994
ContactTypeID is TL type id of Contact.
const ContactsAcceptContactRequestTypeID = 0xf831a20f
ContactsAcceptContactRequestTypeID is TL type id of ContactsAcceptContactRequest.
const ContactsAddContactRequestTypeID = 0xe8f463d0
ContactsAddContactRequestTypeID is TL type id of ContactsAddContactRequest.
const ContactsBlockFromRepliesRequestTypeID = 0x29a8962c
ContactsBlockFromRepliesRequestTypeID is TL type id of ContactsBlockFromRepliesRequest.
const ContactsBlockRequestTypeID = 0x68cc1411
ContactsBlockRequestTypeID is TL type id of ContactsBlockRequest.
const ContactsBlockedSliceTypeID = 0xe1664194
ContactsBlockedSliceTypeID is TL type id of ContactsBlockedSlice.
const ContactsBlockedTypeID = 0xade1591
ContactsBlockedTypeID is TL type id of ContactsBlocked.
const ContactsContactsNotModifiedTypeID = 0xb74ba9d2
ContactsContactsNotModifiedTypeID is TL type id of ContactsContactsNotModified.
const ContactsContactsTypeID = 0xeae87e42
ContactsContactsTypeID is TL type id of ContactsContacts.
const ContactsDeleteByPhonesRequestTypeID = 0x1013fd9e
ContactsDeleteByPhonesRequestTypeID is TL type id of ContactsDeleteByPhonesRequest.
const ContactsDeleteContactsRequestTypeID = 0x96a0e00
ContactsDeleteContactsRequestTypeID is TL type id of ContactsDeleteContactsRequest.
const ContactsFoundTypeID = 0xb3134d9d
ContactsFoundTypeID is TL type id of ContactsFound.
const ContactsGetBlockedRequestTypeID = 0xf57c350f
ContactsGetBlockedRequestTypeID is TL type id of ContactsGetBlockedRequest.
const ContactsGetContactIDsRequestTypeID = 0x2caa4a42
ContactsGetContactIDsRequestTypeID is TL type id of ContactsGetContactIDsRequest.
const ContactsGetContactsRequestTypeID = 0xc023849f
ContactsGetContactsRequestTypeID is TL type id of ContactsGetContactsRequest.
const ContactsGetLocatedRequestTypeID = 0xd348bc44
ContactsGetLocatedRequestTypeID is TL type id of ContactsGetLocatedRequest.
const ContactsGetSavedRequestTypeID = 0x82f1e39f
ContactsGetSavedRequestTypeID is TL type id of ContactsGetSavedRequest.
const ContactsGetStatusesRequestTypeID = 0xc4a353ee
ContactsGetStatusesRequestTypeID is TL type id of ContactsGetStatusesRequest.
const ContactsGetTopPeersRequestTypeID = 0xd4982db5
ContactsGetTopPeersRequestTypeID is TL type id of ContactsGetTopPeersRequest.
const ContactsImportContactsRequestTypeID = 0x2c800be5
ContactsImportContactsRequestTypeID is TL type id of ContactsImportContactsRequest.
const ContactsImportedContactsTypeID = 0x77d01c3b
ContactsImportedContactsTypeID is TL type id of ContactsImportedContacts.
const ContactsResetSavedRequestTypeID = 0x879537f1
ContactsResetSavedRequestTypeID is TL type id of ContactsResetSavedRequest.
const ContactsResetTopPeerRatingRequestTypeID = 0x1ae373ac
ContactsResetTopPeerRatingRequestTypeID is TL type id of ContactsResetTopPeerRatingRequest.
const ContactsResolveUsernameRequestTypeID = 0xf93ccba3
ContactsResolveUsernameRequestTypeID is TL type id of ContactsResolveUsernameRequest.
const ContactsResolvedPeerTypeID = 0x7f077ad9
ContactsResolvedPeerTypeID is TL type id of ContactsResolvedPeer.
const ContactsSearchRequestTypeID = 0x11f812d8
ContactsSearchRequestTypeID is TL type id of ContactsSearchRequest.
const ContactsToggleTopPeersRequestTypeID = 0x8514bdda
ContactsToggleTopPeersRequestTypeID is TL type id of ContactsToggleTopPeersRequest.
const ContactsTopPeersDisabledTypeID = 0xb52c939d
ContactsTopPeersDisabledTypeID is TL type id of ContactsTopPeersDisabled.
const ContactsTopPeersNotModifiedTypeID = 0xde266ef5
ContactsTopPeersNotModifiedTypeID is TL type id of ContactsTopPeersNotModified.
const ContactsTopPeersTypeID = 0x70b772a8
ContactsTopPeersTypeID is TL type id of ContactsTopPeers.
const ContactsUnblockRequestTypeID = 0xbea65d50
ContactsUnblockRequestTypeID is TL type id of ContactsUnblockRequest.
const DataJSONTypeID = 0x7d748d04
DataJSONTypeID is TL type id of DataJSON.
const DcOptionTypeID = 0x18b7a10d
DcOptionTypeID is TL type id of DcOption.
const DialogFilterSuggestedTypeID = 0x77744d4a
DialogFilterSuggestedTypeID is TL type id of DialogFilterSuggested.
const DialogFilterTypeID = 0x7438f7e8
DialogFilterTypeID is TL type id of DialogFilter.
const DialogFolderTypeID = 0x71bd134c
DialogFolderTypeID is TL type id of DialogFolder.
const DialogPeerFolderTypeID = 0x514519e2
DialogPeerFolderTypeID is TL type id of DialogPeerFolder.
const DialogPeerTypeID = 0xe56dbf05
DialogPeerTypeID is TL type id of DialogPeer.
const DialogTypeID = 0x2c171f72
DialogTypeID is TL type id of Dialog.
const DocumentAttributeAnimatedTypeID = 0x11b58939
DocumentAttributeAnimatedTypeID is TL type id of DocumentAttributeAnimated.
const DocumentAttributeAudioTypeID = 0x9852f9c6
DocumentAttributeAudioTypeID is TL type id of DocumentAttributeAudio.
const DocumentAttributeFilenameTypeID = 0x15590068
DocumentAttributeFilenameTypeID is TL type id of DocumentAttributeFilename.
const DocumentAttributeHasStickersTypeID = 0x9801d2f7
DocumentAttributeHasStickersTypeID is TL type id of DocumentAttributeHasStickers.
const DocumentAttributeImageSizeTypeID = 0x6c37c15c
DocumentAttributeImageSizeTypeID is TL type id of DocumentAttributeImageSize.
const DocumentAttributeStickerTypeID = 0x6319d612
DocumentAttributeStickerTypeID is TL type id of DocumentAttributeSticker.
const DocumentAttributeVideoTypeID = 0xef02ce6
DocumentAttributeVideoTypeID is TL type id of DocumentAttributeVideo.
const DocumentEmptyTypeID = 0x36f8c871
DocumentEmptyTypeID is TL type id of DocumentEmpty.
const DocumentTypeID = 0x1e87342b
DocumentTypeID is TL type id of Document.
const DraftMessageEmptyTypeID = 0x1b0c841a
DraftMessageEmptyTypeID is TL type id of DraftMessageEmpty.
const DraftMessageTypeID = 0xfd8e711f
DraftMessageTypeID is TL type id of DraftMessage.
const EmojiKeywordDeletedTypeID = 0x236df622
EmojiKeywordDeletedTypeID is TL type id of EmojiKeywordDeleted.
const EmojiKeywordTypeID = 0xd5b3b9f9
EmojiKeywordTypeID is TL type id of EmojiKeyword.
const EmojiKeywordsDifferenceTypeID = 0x5cc761bd
EmojiKeywordsDifferenceTypeID is TL type id of EmojiKeywordsDifference.
const EmojiLanguageTypeID = 0xb3fb5361
EmojiLanguageTypeID is TL type id of EmojiLanguage.
const EmojiURLTypeID = 0xa575739d
EmojiURLTypeID is TL type id of EmojiURL.
const EncryptedChatDiscardedTypeID = 0x13d6dd27
EncryptedChatDiscardedTypeID is TL type id of EncryptedChatDiscarded.
const EncryptedChatEmptyTypeID = 0xab7ec0a0
EncryptedChatEmptyTypeID is TL type id of EncryptedChatEmpty.
const EncryptedChatRequestedTypeID = 0x62718a82
EncryptedChatRequestedTypeID is TL type id of EncryptedChatRequested.
const EncryptedChatTypeID = 0xfa56ce36
EncryptedChatTypeID is TL type id of EncryptedChat.
const EncryptedChatWaitingTypeID = 0x3bf703dc
EncryptedChatWaitingTypeID is TL type id of EncryptedChatWaiting.
const EncryptedFileEmptyTypeID = 0xc21f497e
EncryptedFileEmptyTypeID is TL type id of EncryptedFileEmpty.
const EncryptedFileTypeID = 0x4a70994c
EncryptedFileTypeID is TL type id of EncryptedFile.
const EncryptedMessageServiceTypeID = 0x23734b06
EncryptedMessageServiceTypeID is TL type id of EncryptedMessageService.
const EncryptedMessageTypeID = 0xed18c118
EncryptedMessageTypeID is TL type id of EncryptedMessage.
const ErrorTypeID = 0xc4b9f9bb
ErrorTypeID is TL type id of Error.
const ExportedMessageLinkTypeID = 0x5dab1af4
ExportedMessageLinkTypeID is TL type id of ExportedMessageLink.
const FileHashTypeID = 0x6242c773
FileHashTypeID is TL type id of FileHash.
const FileLocationToBeDeprecatedTypeID = 0xbc7fc6cd
FileLocationToBeDeprecatedTypeID is TL type id of FileLocationToBeDeprecated.
const FolderPeerTypeID = 0xe9baa668
FolderPeerTypeID is TL type id of FolderPeer.
const FolderTypeID = 0xff544e65
FolderTypeID is TL type id of Folder.
const FoldersDeleteFolderRequestTypeID = 0x1c295881
FoldersDeleteFolderRequestTypeID is TL type id of FoldersDeleteFolderRequest.
const FoldersEditPeerFoldersRequestTypeID = 0x6847d0ab
FoldersEditPeerFoldersRequestTypeID is TL type id of FoldersEditPeerFoldersRequest.
const GameTypeID = 0xbdf9653b
GameTypeID is TL type id of Game.
const GeoPointEmptyTypeID = 0x1117dd5f
GeoPointEmptyTypeID is TL type id of GeoPointEmpty.
const GeoPointTypeID = 0xb2a2f663
GeoPointTypeID is TL type id of GeoPoint.
const GlobalPrivacySettingsTypeID = 0xbea2f424
GlobalPrivacySettingsTypeID is TL type id of GlobalPrivacySettings.
const GroupCallDiscardedTypeID = 0x7780bcb4
GroupCallDiscardedTypeID is TL type id of GroupCallDiscarded.
const GroupCallParticipantTypeID = 0x56b087c9
GroupCallParticipantTypeID is TL type id of GroupCallParticipant.
const GroupCallTypeID = 0x55903081
GroupCallTypeID is TL type id of GroupCall.
const HelpAcceptTermsOfServiceRequestTypeID = 0xee72f79a
HelpAcceptTermsOfServiceRequestTypeID is TL type id of HelpAcceptTermsOfServiceRequest.
const HelpAppUpdateTypeID = 0x1da7158f
HelpAppUpdateTypeID is TL type id of HelpAppUpdate.
const HelpCountriesListNotModifiedTypeID = 0x93cc1f32
HelpCountriesListNotModifiedTypeID is TL type id of HelpCountriesListNotModified.
const HelpCountriesListTypeID = 0x87d0759e
HelpCountriesListTypeID is TL type id of HelpCountriesList.
const HelpCountryCodeTypeID = 0x4203c5ef
HelpCountryCodeTypeID is TL type id of HelpCountryCode.
const HelpCountryTypeID = 0xc3878e23
HelpCountryTypeID is TL type id of HelpCountry.
const HelpDeepLinkInfoEmptyTypeID = 0x66afa166
HelpDeepLinkInfoEmptyTypeID is TL type id of HelpDeepLinkInfoEmpty.
const HelpDeepLinkInfoTypeID = 0x6a4ee832
HelpDeepLinkInfoTypeID is TL type id of HelpDeepLinkInfo.
const HelpDismissSuggestionRequestTypeID = 0x77fa99f
HelpDismissSuggestionRequestTypeID is TL type id of HelpDismissSuggestionRequest.
const HelpEditUserInfoRequestTypeID = 0x66b91b70
HelpEditUserInfoRequestTypeID is TL type id of HelpEditUserInfoRequest.
const HelpGetAppChangelogRequestTypeID = 0x9010ef6f
HelpGetAppChangelogRequestTypeID is TL type id of HelpGetAppChangelogRequest.
const HelpGetAppConfigRequestTypeID = 0x98914110
HelpGetAppConfigRequestTypeID is TL type id of HelpGetAppConfigRequest.
const HelpGetAppUpdateRequestTypeID = 0x522d5a7d
HelpGetAppUpdateRequestTypeID is TL type id of HelpGetAppUpdateRequest.
const HelpGetCdnConfigRequestTypeID = 0x52029342
HelpGetCdnConfigRequestTypeID is TL type id of HelpGetCdnConfigRequest.
const HelpGetConfigRequestTypeID = 0xc4f9186b
HelpGetConfigRequestTypeID is TL type id of HelpGetConfigRequest.
const HelpGetCountriesListRequestTypeID = 0x735787a8
HelpGetCountriesListRequestTypeID is TL type id of HelpGetCountriesListRequest.
const HelpGetDeepLinkInfoRequestTypeID = 0x3fedc75f
HelpGetDeepLinkInfoRequestTypeID is TL type id of HelpGetDeepLinkInfoRequest.
const HelpGetInviteTextRequestTypeID = 0x4d392343
HelpGetInviteTextRequestTypeID is TL type id of HelpGetInviteTextRequest.
const HelpGetNearestDcRequestTypeID = 0x1fb33026
HelpGetNearestDcRequestTypeID is TL type id of HelpGetNearestDcRequest.
const HelpGetPassportConfigRequestTypeID = 0xc661ad08
HelpGetPassportConfigRequestTypeID is TL type id of HelpGetPassportConfigRequest.
const HelpGetPromoDataRequestTypeID = 0xc0977421
HelpGetPromoDataRequestTypeID is TL type id of HelpGetPromoDataRequest.
const HelpGetRecentMeUrlsRequestTypeID = 0x3dc0f114
HelpGetRecentMeUrlsRequestTypeID is TL type id of HelpGetRecentMeUrlsRequest.
const HelpGetSupportNameRequestTypeID = 0xd360e72c
HelpGetSupportNameRequestTypeID is TL type id of HelpGetSupportNameRequest.
const HelpGetSupportRequestTypeID = 0x9cdf08cd
HelpGetSupportRequestTypeID is TL type id of HelpGetSupportRequest.
const HelpGetTermsOfServiceUpdateRequestTypeID = 0x2ca51fd1
HelpGetTermsOfServiceUpdateRequestTypeID is TL type id of HelpGetTermsOfServiceUpdateRequest.
const HelpGetUserInfoRequestTypeID = 0x38a08d3
HelpGetUserInfoRequestTypeID is TL type id of HelpGetUserInfoRequest.
const HelpHidePromoDataRequestTypeID = 0x1e251c95
HelpHidePromoDataRequestTypeID is TL type id of HelpHidePromoDataRequest.
const HelpInviteTextTypeID = 0x18cb9f78
HelpInviteTextTypeID is TL type id of HelpInviteText.
const HelpNoAppUpdateTypeID = 0xc45a6536
HelpNoAppUpdateTypeID is TL type id of HelpNoAppUpdate.
const HelpPassportConfigNotModifiedTypeID = 0xbfb9f457
HelpPassportConfigNotModifiedTypeID is TL type id of HelpPassportConfigNotModified.
const HelpPassportConfigTypeID = 0xa098d6af
HelpPassportConfigTypeID is TL type id of HelpPassportConfig.
const HelpPromoDataEmptyTypeID = 0x98f6ac75
HelpPromoDataEmptyTypeID is TL type id of HelpPromoDataEmpty.
const HelpPromoDataTypeID = 0x8c39793f
HelpPromoDataTypeID is TL type id of HelpPromoData.
const HelpRecentMeUrlsTypeID = 0xe0310d7
HelpRecentMeUrlsTypeID is TL type id of HelpRecentMeUrls.
const HelpSaveAppLogRequestTypeID = 0x6f02f748
HelpSaveAppLogRequestTypeID is TL type id of HelpSaveAppLogRequest.
const HelpSetBotUpdatesStatusRequestTypeID = 0xec22cfcd
HelpSetBotUpdatesStatusRequestTypeID is TL type id of HelpSetBotUpdatesStatusRequest.
const HelpSupportNameTypeID = 0x8c05f1c9
HelpSupportNameTypeID is TL type id of HelpSupportName.
const HelpSupportTypeID = 0x17c6b5f6
HelpSupportTypeID is TL type id of HelpSupport.
const HelpTermsOfServiceTypeID = 0x780a0310
HelpTermsOfServiceTypeID is TL type id of HelpTermsOfService.
const HelpTermsOfServiceUpdateEmptyTypeID = 0xe3309f7f
HelpTermsOfServiceUpdateEmptyTypeID is TL type id of HelpTermsOfServiceUpdateEmpty.
const HelpTermsOfServiceUpdateTypeID = 0x28ecf961
HelpTermsOfServiceUpdateTypeID is TL type id of HelpTermsOfServiceUpdate.
const HelpUserInfoEmptyTypeID = 0xf3ae2eed
HelpUserInfoEmptyTypeID is TL type id of HelpUserInfoEmpty.
const HelpUserInfoTypeID = 0x1eb3758
HelpUserInfoTypeID is TL type id of HelpUserInfo.
const HighScoreTypeID = 0x58fffcd0
HighScoreTypeID is TL type id of HighScore.
const ImportedContactTypeID = 0xd0028438
ImportedContactTypeID is TL type id of ImportedContact.
const InitConnectionRequestTypeID = 0xc1cd5ea9
InitConnectionRequestTypeID is TL type id of InitConnectionRequest.
const InlineBotSwitchPMTypeID = 0x3c20629f
InlineBotSwitchPMTypeID is TL type id of InlineBotSwitchPM.
const InlineQueryPeerTypeBroadcastTypeID = 0x6334ee9a
InlineQueryPeerTypeBroadcastTypeID is TL type id of InlineQueryPeerTypeBroadcast.
const InlineQueryPeerTypeChatTypeID = 0xd766c50a
InlineQueryPeerTypeChatTypeID is TL type id of InlineQueryPeerTypeChat.
const InlineQueryPeerTypeMegagroupTypeID = 0x5ec4be43
InlineQueryPeerTypeMegagroupTypeID is TL type id of InlineQueryPeerTypeMegagroup.
const InlineQueryPeerTypePMTypeID = 0x833c0fac
InlineQueryPeerTypePMTypeID is TL type id of InlineQueryPeerTypePM.
const InlineQueryPeerTypeSameBotPMTypeID = 0x3081ed9d
InlineQueryPeerTypeSameBotPMTypeID is TL type id of InlineQueryPeerTypeSameBotPM.
const InputAppEventTypeID = 0x1d1b1245
InputAppEventTypeID is TL type id of InputAppEvent.
const InputBotInlineMessageGameTypeID = 0x4b425864
InputBotInlineMessageGameTypeID is TL type id of InputBotInlineMessageGame.
const InputBotInlineMessageIDTypeID = 0x890c3d89
InputBotInlineMessageIDTypeID is TL type id of InputBotInlineMessageID.
const InputBotInlineMessageMediaAutoTypeID = 0x3380c786
InputBotInlineMessageMediaAutoTypeID is TL type id of InputBotInlineMessageMediaAuto.
const InputBotInlineMessageMediaContactTypeID = 0xa6edbffd
InputBotInlineMessageMediaContactTypeID is TL type id of InputBotInlineMessageMediaContact.
const InputBotInlineMessageMediaGeoTypeID = 0x96929a85
InputBotInlineMessageMediaGeoTypeID is TL type id of InputBotInlineMessageMediaGeo.
const InputBotInlineMessageMediaVenueTypeID = 0x417bbf11
InputBotInlineMessageMediaVenueTypeID is TL type id of InputBotInlineMessageMediaVenue.
const InputBotInlineMessageTextTypeID = 0x3dcd7a87
InputBotInlineMessageTextTypeID is TL type id of InputBotInlineMessageText.
const InputBotInlineResultDocumentTypeID = 0xfff8fdc4
InputBotInlineResultDocumentTypeID is TL type id of InputBotInlineResultDocument.
const InputBotInlineResultGameTypeID = 0x4fa417f2
InputBotInlineResultGameTypeID is TL type id of InputBotInlineResultGame.
const InputBotInlineResultPhotoTypeID = 0xa8d864a7
InputBotInlineResultPhotoTypeID is TL type id of InputBotInlineResultPhoto.
const InputBotInlineResultTypeID = 0x88bf9319
InputBotInlineResultTypeID is TL type id of InputBotInlineResult.
const InputChannelEmptyTypeID = 0xee8c1e86
InputChannelEmptyTypeID is TL type id of InputChannelEmpty.
const InputChannelFromMessageTypeID = 0x2a286531
InputChannelFromMessageTypeID is TL type id of InputChannelFromMessage.
const InputChannelTypeID = 0xafeb712e
InputChannelTypeID is TL type id of InputChannel.
const InputChatPhotoEmptyTypeID = 0x1ca48f57
InputChatPhotoEmptyTypeID is TL type id of InputChatPhotoEmpty.
const InputChatPhotoTypeID = 0x8953ad37
InputChatPhotoTypeID is TL type id of InputChatPhoto.
const InputChatUploadedPhotoTypeID = 0xc642724e
InputChatUploadedPhotoTypeID is TL type id of InputChatUploadedPhoto.
const InputCheckPasswordEmptyTypeID = 0x9880f658
InputCheckPasswordEmptyTypeID is TL type id of InputCheckPasswordEmpty.
const InputCheckPasswordSRPTypeID = 0xd27ff082
InputCheckPasswordSRPTypeID is TL type id of InputCheckPasswordSRP.
const InputClientProxyTypeID = 0x75588b3f
InputClientProxyTypeID is TL type id of InputClientProxy.
const InputDialogPeerFolderTypeID = 0x64600527
InputDialogPeerFolderTypeID is TL type id of InputDialogPeerFolder.
const InputDialogPeerTypeID = 0xfcaafeb7
InputDialogPeerTypeID is TL type id of InputDialogPeer.
const InputDocumentEmptyTypeID = 0x72f0eaae
InputDocumentEmptyTypeID is TL type id of InputDocumentEmpty.
const InputDocumentFileLocationTypeID = 0xbad07584
InputDocumentFileLocationTypeID is TL type id of InputDocumentFileLocation.
const InputDocumentTypeID = 0x1abfb575
InputDocumentTypeID is TL type id of InputDocument.
const InputEncryptedChatTypeID = 0xf141b5e1
InputEncryptedChatTypeID is TL type id of InputEncryptedChat.
const InputEncryptedFileBigUploadedTypeID = 0x2dc173c8
InputEncryptedFileBigUploadedTypeID is TL type id of InputEncryptedFileBigUploaded.
const InputEncryptedFileEmptyTypeID = 0x1837c364
InputEncryptedFileEmptyTypeID is TL type id of InputEncryptedFileEmpty.
const InputEncryptedFileLocationTypeID = 0xf5235d55
InputEncryptedFileLocationTypeID is TL type id of InputEncryptedFileLocation.
const InputEncryptedFileTypeID = 0x5a17b5e5
InputEncryptedFileTypeID is TL type id of InputEncryptedFile.
const InputEncryptedFileUploadedTypeID = 0x64bd0306
InputEncryptedFileUploadedTypeID is TL type id of InputEncryptedFileUploaded.
const InputFileBigTypeID = 0xfa4f0bb5
InputFileBigTypeID is TL type id of InputFileBig.
const InputFileLocationTypeID = 0xdfdaabe1
InputFileLocationTypeID is TL type id of InputFileLocation.
const InputFileTypeID = 0xf52ff27f
InputFileTypeID is TL type id of InputFile.
const InputFolderPeerTypeID = 0xfbd2c296
InputFolderPeerTypeID is TL type id of InputFolderPeer.
const InputGameIDTypeID = 0x32c3e77
InputGameIDTypeID is TL type id of InputGameID.
const InputGameShortNameTypeID = 0xc331e80a
InputGameShortNameTypeID is TL type id of InputGameShortName.
const InputGeoPointEmptyTypeID = 0xe4c123d6
InputGeoPointEmptyTypeID is TL type id of InputGeoPointEmpty.
const InputGeoPointTypeID = 0x48222faf
InputGeoPointTypeID is TL type id of InputGeoPoint.
const InputGroupCallTypeID = 0xd8aa840f
InputGroupCallTypeID is TL type id of InputGroupCall.
const InputKeyboardButtonUrlAuthTypeID = 0xd02e7fd4
InputKeyboardButtonUrlAuthTypeID is TL type id of InputKeyboardButtonUrlAuth.
const InputMediaContactTypeID = 0xf8ab7dfb
InputMediaContactTypeID is TL type id of InputMediaContact.
const InputMediaDiceTypeID = 0xe66fbf7b
InputMediaDiceTypeID is TL type id of InputMediaDice.
const InputMediaDocumentExternalTypeID = 0xfb52dc99
InputMediaDocumentExternalTypeID is TL type id of InputMediaDocumentExternal.
const InputMediaDocumentTypeID = 0x33473058
InputMediaDocumentTypeID is TL type id of InputMediaDocument.
const InputMediaEmptyTypeID = 0x9664f57f
InputMediaEmptyTypeID is TL type id of InputMediaEmpty.
const InputMediaGameTypeID = 0xd33f43f3
InputMediaGameTypeID is TL type id of InputMediaGame.
const InputMediaGeoLiveTypeID = 0x971fa843
InputMediaGeoLiveTypeID is TL type id of InputMediaGeoLive.
const InputMediaGeoPointTypeID = 0xf9c44144
InputMediaGeoPointTypeID is TL type id of InputMediaGeoPoint.
const InputMediaInvoiceTypeID = 0xf4e096c3
InputMediaInvoiceTypeID is TL type id of InputMediaInvoice.
const InputMediaPhotoExternalTypeID = 0xe5bbfe1a
InputMediaPhotoExternalTypeID is TL type id of InputMediaPhotoExternal.
const InputMediaPhotoTypeID = 0xb3ba0635
InputMediaPhotoTypeID is TL type id of InputMediaPhoto.
const InputMediaPollTypeID = 0xf94e5f1
InputMediaPollTypeID is TL type id of InputMediaPoll.
const InputMediaUploadedDocumentTypeID = 0x5b38c6c1
InputMediaUploadedDocumentTypeID is TL type id of InputMediaUploadedDocument.
const InputMediaUploadedPhotoTypeID = 0x1e287d04
InputMediaUploadedPhotoTypeID is TL type id of InputMediaUploadedPhoto.
const InputMediaVenueTypeID = 0xc13d1c11
InputMediaVenueTypeID is TL type id of InputMediaVenue.
const InputMessageCallbackQueryTypeID = 0xacfa1a7e
InputMessageCallbackQueryTypeID is TL type id of InputMessageCallbackQuery.
const InputMessageEntityMentionNameTypeID = 0x208e68c9
InputMessageEntityMentionNameTypeID is TL type id of InputMessageEntityMentionName.
const InputMessageIDTypeID = 0xa676a322
InputMessageIDTypeID is TL type id of InputMessageID.
const InputMessagePinnedTypeID = 0x86872538
InputMessagePinnedTypeID is TL type id of InputMessagePinned.
const InputMessageReplyToTypeID = 0xbad88395
InputMessageReplyToTypeID is TL type id of InputMessageReplyTo.
const InputMessagesFilterChatPhotosTypeID = 0x3a20ecb8
InputMessagesFilterChatPhotosTypeID is TL type id of InputMessagesFilterChatPhotos.
const InputMessagesFilterContactsTypeID = 0xe062db83
InputMessagesFilterContactsTypeID is TL type id of InputMessagesFilterContacts.
const InputMessagesFilterDocumentTypeID = 0x9eddf188
InputMessagesFilterDocumentTypeID is TL type id of InputMessagesFilterDocument.
const InputMessagesFilterEmptyTypeID = 0x57e2f66c
InputMessagesFilterEmptyTypeID is TL type id of InputMessagesFilterEmpty.
const InputMessagesFilterGeoTypeID = 0xe7026d0d
InputMessagesFilterGeoTypeID is TL type id of InputMessagesFilterGeo.
const InputMessagesFilterGifTypeID = 0xffc86587
InputMessagesFilterGifTypeID is TL type id of InputMessagesFilterGif.
const InputMessagesFilterMusicTypeID = 0x3751b49e
InputMessagesFilterMusicTypeID is TL type id of InputMessagesFilterMusic.
const InputMessagesFilterMyMentionsTypeID = 0xc1f8e69a
InputMessagesFilterMyMentionsTypeID is TL type id of InputMessagesFilterMyMentions.
const InputMessagesFilterPhoneCallsTypeID = 0x80c99768
InputMessagesFilterPhoneCallsTypeID is TL type id of InputMessagesFilterPhoneCalls.
const InputMessagesFilterPhotoVideoTypeID = 0x56e9f0e4
InputMessagesFilterPhotoVideoTypeID is TL type id of InputMessagesFilterPhotoVideo.
const InputMessagesFilterPhotosTypeID = 0x9609a51c
InputMessagesFilterPhotosTypeID is TL type id of InputMessagesFilterPhotos.
const InputMessagesFilterPinnedTypeID = 0x1bb00451
InputMessagesFilterPinnedTypeID is TL type id of InputMessagesFilterPinned.
const InputMessagesFilterRoundVideoTypeID = 0xb549da53
InputMessagesFilterRoundVideoTypeID is TL type id of InputMessagesFilterRoundVideo.
const InputMessagesFilterRoundVoiceTypeID = 0x7a7c17a4
InputMessagesFilterRoundVoiceTypeID is TL type id of InputMessagesFilterRoundVoice.
const InputMessagesFilterUrlTypeID = 0x7ef0dd87
InputMessagesFilterUrlTypeID is TL type id of InputMessagesFilterUrl.
const InputMessagesFilterVideoTypeID = 0x9fc00e65
InputMessagesFilterVideoTypeID is TL type id of InputMessagesFilterVideo.
const InputMessagesFilterVoiceTypeID = 0x50f5c392
InputMessagesFilterVoiceTypeID is TL type id of InputMessagesFilterVoice.
const InputNotifyBroadcastsTypeID = 0xb1db7c7e
InputNotifyBroadcastsTypeID is TL type id of InputNotifyBroadcasts.
const InputNotifyChatsTypeID = 0x4a95e84e
InputNotifyChatsTypeID is TL type id of InputNotifyChats.
const InputNotifyPeerTypeID = 0xb8bc5b0c
InputNotifyPeerTypeID is TL type id of InputNotifyPeer.
const InputNotifyUsersTypeID = 0x193b4417
InputNotifyUsersTypeID is TL type id of InputNotifyUsers.
const InputPaymentCredentialsAndroidPayTypeID = 0xca05d50e
InputPaymentCredentialsAndroidPayTypeID is TL type id of InputPaymentCredentialsAndroidPay.
const InputPaymentCredentialsApplePayTypeID = 0xaa1c39f
InputPaymentCredentialsApplePayTypeID is TL type id of InputPaymentCredentialsApplePay.
const InputPaymentCredentialsSavedTypeID = 0xc10eb2cf
InputPaymentCredentialsSavedTypeID is TL type id of InputPaymentCredentialsSaved.
const InputPaymentCredentialsTypeID = 0x3417d728
InputPaymentCredentialsTypeID is TL type id of InputPaymentCredentials.
const InputPeerChannelFromMessageTypeID = 0x9c95f7bb
InputPeerChannelFromMessageTypeID is TL type id of InputPeerChannelFromMessage.
const InputPeerChannelTypeID = 0x20adaef8
InputPeerChannelTypeID is TL type id of InputPeerChannel.
const InputPeerChatTypeID = 0x179be863
InputPeerChatTypeID is TL type id of InputPeerChat.
const InputPeerEmptyTypeID = 0x7f3b18ea
InputPeerEmptyTypeID is TL type id of InputPeerEmpty.
const InputPeerNotifySettingsTypeID = 0x9c3d198e
InputPeerNotifySettingsTypeID is TL type id of InputPeerNotifySettings.
const InputPeerPhotoFileLocationTypeID = 0x27d69997
InputPeerPhotoFileLocationTypeID is TL type id of InputPeerPhotoFileLocation.
const InputPeerSelfTypeID = 0x7da07ec9
InputPeerSelfTypeID is TL type id of InputPeerSelf.
const InputPeerUserFromMessageTypeID = 0x17bae2e6
InputPeerUserFromMessageTypeID is TL type id of InputPeerUserFromMessage.
const InputPeerUserTypeID = 0x7b8e7de6
InputPeerUserTypeID is TL type id of InputPeerUser.
const InputPhoneCallTypeID = 0x1e36fded
InputPhoneCallTypeID is TL type id of InputPhoneCall.
const InputPhoneContactTypeID = 0xf392b7f4
InputPhoneContactTypeID is TL type id of InputPhoneContact.
const InputPhotoEmptyTypeID = 0x1cd7bf0d
InputPhotoEmptyTypeID is TL type id of InputPhotoEmpty.
const InputPhotoFileLocationTypeID = 0x40181ffe
InputPhotoFileLocationTypeID is TL type id of InputPhotoFileLocation.
const InputPhotoLegacyFileLocationTypeID = 0xd83466f3
InputPhotoLegacyFileLocationTypeID is TL type id of InputPhotoLegacyFileLocation.
const InputPhotoTypeID = 0x3bb3b94a
InputPhotoTypeID is TL type id of InputPhoto.
const InputPrivacyKeyAddedByPhoneTypeID = 0xd1219bdd
InputPrivacyKeyAddedByPhoneTypeID is TL type id of InputPrivacyKeyAddedByPhone.
const InputPrivacyKeyChatInviteTypeID = 0xbdfb0426
InputPrivacyKeyChatInviteTypeID is TL type id of InputPrivacyKeyChatInvite.
const InputPrivacyKeyForwardsTypeID = 0xa4dd4c08
InputPrivacyKeyForwardsTypeID is TL type id of InputPrivacyKeyForwards.
const InputPrivacyKeyPhoneCallTypeID = 0xfabadc5f
InputPrivacyKeyPhoneCallTypeID is TL type id of InputPrivacyKeyPhoneCall.
const InputPrivacyKeyPhoneNumberTypeID = 0x352dafa
InputPrivacyKeyPhoneNumberTypeID is TL type id of InputPrivacyKeyPhoneNumber.
const InputPrivacyKeyPhoneP2PTypeID = 0xdb9e70d2
InputPrivacyKeyPhoneP2PTypeID is TL type id of InputPrivacyKeyPhoneP2P.
const InputPrivacyKeyProfilePhotoTypeID = 0x5719bacc
InputPrivacyKeyProfilePhotoTypeID is TL type id of InputPrivacyKeyProfilePhoto.
const InputPrivacyKeyStatusTimestampTypeID = 0x4f96cb18
InputPrivacyKeyStatusTimestampTypeID is TL type id of InputPrivacyKeyStatusTimestamp.
const InputPrivacyValueAllowAllTypeID = 0x184b35ce
InputPrivacyValueAllowAllTypeID is TL type id of InputPrivacyValueAllowAll.
const InputPrivacyValueAllowChatParticipantsTypeID = 0x4c81c1ba
InputPrivacyValueAllowChatParticipantsTypeID is TL type id of InputPrivacyValueAllowChatParticipants.
const InputPrivacyValueAllowContactsTypeID = 0xd09e07b
InputPrivacyValueAllowContactsTypeID is TL type id of InputPrivacyValueAllowContacts.
const InputPrivacyValueAllowUsersTypeID = 0x131cc67f
InputPrivacyValueAllowUsersTypeID is TL type id of InputPrivacyValueAllowUsers.
const InputPrivacyValueDisallowAllTypeID = 0xd66b66c9
InputPrivacyValueDisallowAllTypeID is TL type id of InputPrivacyValueDisallowAll.
const InputPrivacyValueDisallowChatParticipantsTypeID = 0xd82363af
InputPrivacyValueDisallowChatParticipantsTypeID is TL type id of InputPrivacyValueDisallowChatParticipants.
const InputPrivacyValueDisallowContactsTypeID = 0xba52007
InputPrivacyValueDisallowContactsTypeID is TL type id of InputPrivacyValueDisallowContacts.
const InputPrivacyValueDisallowUsersTypeID = 0x90110467
InputPrivacyValueDisallowUsersTypeID is TL type id of InputPrivacyValueDisallowUsers.
const InputReportReasonChildAbuseTypeID = 0xadf44ee3
InputReportReasonChildAbuseTypeID is TL type id of InputReportReasonChildAbuse.
const InputReportReasonCopyrightTypeID = 0x9b89f93a
InputReportReasonCopyrightTypeID is TL type id of InputReportReasonCopyright.
const InputReportReasonGeoIrrelevantTypeID = 0xdbd4feed
InputReportReasonGeoIrrelevantTypeID is TL type id of InputReportReasonGeoIrrelevant.
const InputReportReasonOtherTypeID = 0xe1746d0a
InputReportReasonOtherTypeID is TL type id of InputReportReasonOther.
const InputReportReasonPornographyTypeID = 0x2e59d922
InputReportReasonPornographyTypeID is TL type id of InputReportReasonPornography.
const InputReportReasonSpamTypeID = 0x58dbcab8
InputReportReasonSpamTypeID is TL type id of InputReportReasonSpam.
const InputReportReasonViolenceTypeID = 0x1e22c78d
InputReportReasonViolenceTypeID is TL type id of InputReportReasonViolence.
const InputSecureFileLocationTypeID = 0xcbc7ee28
InputSecureFileLocationTypeID is TL type id of InputSecureFileLocation.
const InputSecureFileTypeID = 0x5367e5be
InputSecureFileTypeID is TL type id of InputSecureFile.
const InputSecureFileUploadedTypeID = 0x3334b0f0
InputSecureFileUploadedTypeID is TL type id of InputSecureFileUploaded.
const InputSecureValueTypeID = 0xdb21d0a7
InputSecureValueTypeID is TL type id of InputSecureValue.
const InputSingleMediaTypeID = 0x1cc6e91f
InputSingleMediaTypeID is TL type id of InputSingleMedia.
const InputStickerSetAnimatedEmojiTypeID = 0x28703c8
InputStickerSetAnimatedEmojiTypeID is TL type id of InputStickerSetAnimatedEmoji.
const InputStickerSetDiceTypeID = 0xe67f520e
InputStickerSetDiceTypeID is TL type id of InputStickerSetDice.
const InputStickerSetEmptyTypeID = 0xffb62b95
InputStickerSetEmptyTypeID is TL type id of InputStickerSetEmpty.
const InputStickerSetIDTypeID = 0x9de7a269
InputStickerSetIDTypeID is TL type id of InputStickerSetID.
const InputStickerSetItemTypeID = 0xffa0a496
InputStickerSetItemTypeID is TL type id of InputStickerSetItem.
const InputStickerSetShortNameTypeID = 0x861cc8a0
InputStickerSetShortNameTypeID is TL type id of InputStickerSetShortName.
const InputStickerSetThumbTypeID = 0xdbaeae9
InputStickerSetThumbTypeID is TL type id of InputStickerSetThumb.
const InputStickeredMediaDocumentTypeID = 0x438865b
InputStickeredMediaDocumentTypeID is TL type id of InputStickeredMediaDocument.
const InputStickeredMediaPhotoTypeID = 0x4a992157
InputStickeredMediaPhotoTypeID is TL type id of InputStickeredMediaPhoto.
const InputTakeoutFileLocationTypeID = 0x29be5899
InputTakeoutFileLocationTypeID is TL type id of InputTakeoutFileLocation.
const InputThemeSettingsTypeID = 0xbd507cd1
InputThemeSettingsTypeID is TL type id of InputThemeSettings.
const InputThemeSlugTypeID = 0xf5890df1
InputThemeSlugTypeID is TL type id of InputThemeSlug.
const InputThemeTypeID = 0x3c5693e9
InputThemeTypeID is TL type id of InputTheme.
const InputUserEmptyTypeID = 0xb98886cf
InputUserEmptyTypeID is TL type id of InputUserEmpty.
const InputUserFromMessageTypeID = 0x2d117597
InputUserFromMessageTypeID is TL type id of InputUserFromMessage.
const InputUserSelfTypeID = 0xf7c1b13f
InputUserSelfTypeID is TL type id of InputUserSelf.
const InputUserTypeID = 0xd8292816
InputUserTypeID is TL type id of InputUser.
const InputWallPaperNoFileTypeID = 0x8427bbac
InputWallPaperNoFileTypeID is TL type id of InputWallPaperNoFile.
const InputWallPaperSlugTypeID = 0x72091c80
InputWallPaperSlugTypeID is TL type id of InputWallPaperSlug.
const InputWallPaperTypeID = 0xe630b979
InputWallPaperTypeID is TL type id of InputWallPaper.
const InputWebDocumentTypeID = 0x9bed434d
InputWebDocumentTypeID is TL type id of InputWebDocument.
const InputWebFileGeoPointLocationTypeID = 0x9f2221c9
InputWebFileGeoPointLocationTypeID is TL type id of InputWebFileGeoPointLocation.
const InputWebFileLocationTypeID = 0xc239d686
InputWebFileLocationTypeID is TL type id of InputWebFileLocation.
const InvoiceTypeID = 0xc30aa358
InvoiceTypeID is TL type id of Invoice.
const InvokeAfterMsgRequestTypeID = 0xcb9f372d
InvokeAfterMsgRequestTypeID is TL type id of InvokeAfterMsgRequest.
const InvokeAfterMsgsRequestTypeID = 0x3dc4b4f0
InvokeAfterMsgsRequestTypeID is TL type id of InvokeAfterMsgsRequest.
const InvokeWithLayerRequestTypeID = 0xda9b0d0d
InvokeWithLayerRequestTypeID is TL type id of InvokeWithLayerRequest.
const InvokeWithMessagesRangeRequestTypeID = 0x365275f2
InvokeWithMessagesRangeRequestTypeID is TL type id of InvokeWithMessagesRangeRequest.
const InvokeWithTakeoutRequestTypeID = 0xaca9fd2e
InvokeWithTakeoutRequestTypeID is TL type id of InvokeWithTakeoutRequest.
const InvokeWithoutUpdatesRequestTypeID = 0xbf9459b7
InvokeWithoutUpdatesRequestTypeID is TL type id of InvokeWithoutUpdatesRequest.
const JsonArrayTypeID = 0xf7444763
JsonArrayTypeID is TL type id of JsonArray.
const JsonBoolTypeID = 0xc7345e6a
JsonBoolTypeID is TL type id of JsonBool.
const JsonNullTypeID = 0x3f6d7b68
JsonNullTypeID is TL type id of JsonNull.
const JsonNumberTypeID = 0x2be0dfa4
JsonNumberTypeID is TL type id of JsonNumber.
const JsonObjectTypeID = 0x99c1d49d
JsonObjectTypeID is TL type id of JsonObject.
const JsonObjectValueTypeID = 0xc0de1bd9
JsonObjectValueTypeID is TL type id of JsonObjectValue.
const JsonStringTypeID = 0xb71e767a
JsonStringTypeID is TL type id of JsonString.
const KeyboardButtonBuyTypeID = 0xafd93fbb
KeyboardButtonBuyTypeID is TL type id of KeyboardButtonBuy.
const KeyboardButtonCallbackTypeID = 0x35bbdb6b
KeyboardButtonCallbackTypeID is TL type id of KeyboardButtonCallback.
const KeyboardButtonGameTypeID = 0x50f41ccf
KeyboardButtonGameTypeID is TL type id of KeyboardButtonGame.
const KeyboardButtonRequestGeoLocationTypeID = 0xfc796b3f
KeyboardButtonRequestGeoLocationTypeID is TL type id of KeyboardButtonRequestGeoLocation.
const KeyboardButtonRequestPhoneTypeID = 0xb16a6c29
KeyboardButtonRequestPhoneTypeID is TL type id of KeyboardButtonRequestPhone.
const KeyboardButtonRequestPollTypeID = 0xbbc7515d
KeyboardButtonRequestPollTypeID is TL type id of KeyboardButtonRequestPoll.
const KeyboardButtonRowTypeID = 0x77608b83
KeyboardButtonRowTypeID is TL type id of KeyboardButtonRow.
const KeyboardButtonSwitchInlineTypeID = 0x568a748
KeyboardButtonSwitchInlineTypeID is TL type id of KeyboardButtonSwitchInline.
const KeyboardButtonTypeID = 0xa2fa4880
KeyboardButtonTypeID is TL type id of KeyboardButton.
const KeyboardButtonUrlAuthTypeID = 0x10b78d29
KeyboardButtonUrlAuthTypeID is TL type id of KeyboardButtonUrlAuth.
const KeyboardButtonUrlTypeID = 0x258aff05
KeyboardButtonUrlTypeID is TL type id of KeyboardButtonUrl.
const LabeledPriceTypeID = 0xcb296bf8
LabeledPriceTypeID is TL type id of LabeledPrice.
const LangPackDifferenceTypeID = 0xf385c1f6
LangPackDifferenceTypeID is TL type id of LangPackDifference.
const LangPackLanguageTypeID = 0xeeca5ce3
LangPackLanguageTypeID is TL type id of LangPackLanguage.
const LangPackStringDeletedTypeID = 0x2979eeb2
LangPackStringDeletedTypeID is TL type id of LangPackStringDeleted.
const LangPackStringPluralizedTypeID = 0x6c47ac9f
LangPackStringPluralizedTypeID is TL type id of LangPackStringPluralized.
const LangPackStringTypeID = 0xcad181f6
LangPackStringTypeID is TL type id of LangPackString.
const LangpackGetDifferenceRequestTypeID = 0xcd984aa5
LangpackGetDifferenceRequestTypeID is TL type id of LangpackGetDifferenceRequest.
const LangpackGetLangPackRequestTypeID = 0xf2f2330a
LangpackGetLangPackRequestTypeID is TL type id of LangpackGetLangPackRequest.
const LangpackGetLanguageRequestTypeID = 0x6a596502
LangpackGetLanguageRequestTypeID is TL type id of LangpackGetLanguageRequest.
const LangpackGetLanguagesRequestTypeID = 0x42c6978f
LangpackGetLanguagesRequestTypeID is TL type id of LangpackGetLanguagesRequest.
const LangpackGetStringsRequestTypeID = 0xefea3803
LangpackGetStringsRequestTypeID is TL type id of LangpackGetStringsRequest.
const Layer = 122
Layer version of schema.
const MaskCoordsTypeID = 0xaed6dbb2
MaskCoordsTypeID is TL type id of MaskCoords.
const MessageActionBotAllowedTypeID = 0xabe9affe
MessageActionBotAllowedTypeID is TL type id of MessageActionBotAllowed.
const MessageActionChannelCreateTypeID = 0x95d2ac92
MessageActionChannelCreateTypeID is TL type id of MessageActionChannelCreate.
const MessageActionChannelMigrateFromTypeID = 0xb055eaee
MessageActionChannelMigrateFromTypeID is TL type id of MessageActionChannelMigrateFrom.
const MessageActionChatAddUserTypeID = 0x488a7337
MessageActionChatAddUserTypeID is TL type id of MessageActionChatAddUser.
const MessageActionChatCreateTypeID = 0xa6638b9a
MessageActionChatCreateTypeID is TL type id of MessageActionChatCreate.
const MessageActionChatDeletePhotoTypeID = 0x95e3fbef
MessageActionChatDeletePhotoTypeID is TL type id of MessageActionChatDeletePhoto.
const MessageActionChatDeleteUserTypeID = 0xb2ae9b0c
MessageActionChatDeleteUserTypeID is TL type id of MessageActionChatDeleteUser.
const MessageActionChatEditPhotoTypeID = 0x7fcb13a8
MessageActionChatEditPhotoTypeID is TL type id of MessageActionChatEditPhoto.
const MessageActionChatEditTitleTypeID = 0xb5a1ce5a
MessageActionChatEditTitleTypeID is TL type id of MessageActionChatEditTitle.
const MessageActionChatJoinedByLinkTypeID = 0xf89cf5e8
MessageActionChatJoinedByLinkTypeID is TL type id of MessageActionChatJoinedByLink.
const MessageActionChatMigrateToTypeID = 0x51bdb021
MessageActionChatMigrateToTypeID is TL type id of MessageActionChatMigrateTo.
const MessageActionContactSignUpTypeID = 0xf3f25f76
MessageActionContactSignUpTypeID is TL type id of MessageActionContactSignUp.
const MessageActionCustomActionTypeID = 0xfae69f56
MessageActionCustomActionTypeID is TL type id of MessageActionCustomAction.
const MessageActionEmptyTypeID = 0xb6aef7b0
MessageActionEmptyTypeID is TL type id of MessageActionEmpty.
const MessageActionGameScoreTypeID = 0x92a72876
MessageActionGameScoreTypeID is TL type id of MessageActionGameScore.
const MessageActionGeoProximityReachedTypeID = 0x98e0d697
MessageActionGeoProximityReachedTypeID is TL type id of MessageActionGeoProximityReached.
const MessageActionGroupCallTypeID = 0x7a0d7f42
MessageActionGroupCallTypeID is TL type id of MessageActionGroupCall.
const MessageActionHistoryClearTypeID = 0x9fbab604
MessageActionHistoryClearTypeID is TL type id of MessageActionHistoryClear.
const MessageActionInviteToGroupCallTypeID = 0x76b9f11a
MessageActionInviteToGroupCallTypeID is TL type id of MessageActionInviteToGroupCall.
const MessageActionPaymentSentMeTypeID = 0x8f31b327
MessageActionPaymentSentMeTypeID is TL type id of MessageActionPaymentSentMe.
const MessageActionPaymentSentTypeID = 0x40699cd0
MessageActionPaymentSentTypeID is TL type id of MessageActionPaymentSent.
const MessageActionPhoneCallTypeID = 0x80e11a7f
MessageActionPhoneCallTypeID is TL type id of MessageActionPhoneCall.
const MessageActionPinMessageTypeID = 0x94bd38ed
MessageActionPinMessageTypeID is TL type id of MessageActionPinMessage.
const MessageActionScreenshotTakenTypeID = 0x4792929b
MessageActionScreenshotTakenTypeID is TL type id of MessageActionScreenshotTaken.
const MessageActionSecureValuesSentMeTypeID = 0x1b287353
MessageActionSecureValuesSentMeTypeID is TL type id of MessageActionSecureValuesSentMe.
const MessageActionSecureValuesSentTypeID = 0xd95c6154
MessageActionSecureValuesSentTypeID is TL type id of MessageActionSecureValuesSent.
const MessageEmptyTypeID = 0x83e5de54
MessageEmptyTypeID is TL type id of MessageEmpty.
const MessageEntityBankCardTypeID = 0x761e6af4
MessageEntityBankCardTypeID is TL type id of MessageEntityBankCard.
const MessageEntityBlockquoteTypeID = 0x20df5d0
MessageEntityBlockquoteTypeID is TL type id of MessageEntityBlockquote.
const MessageEntityBoldTypeID = 0xbd610bc9
MessageEntityBoldTypeID is TL type id of MessageEntityBold.
const MessageEntityBotCommandTypeID = 0x6cef8ac7
MessageEntityBotCommandTypeID is TL type id of MessageEntityBotCommand.
const MessageEntityCashtagTypeID = 0x4c4e743f
MessageEntityCashtagTypeID is TL type id of MessageEntityCashtag.
const MessageEntityCodeTypeID = 0x28a20571
MessageEntityCodeTypeID is TL type id of MessageEntityCode.
const MessageEntityEmailTypeID = 0x64e475c2
MessageEntityEmailTypeID is TL type id of MessageEntityEmail.
const MessageEntityHashtagTypeID = 0x6f635b0d
MessageEntityHashtagTypeID is TL type id of MessageEntityHashtag.
const MessageEntityItalicTypeID = 0x826f8b60
MessageEntityItalicTypeID is TL type id of MessageEntityItalic.
const MessageEntityMentionNameTypeID = 0x352dca58
MessageEntityMentionNameTypeID is TL type id of MessageEntityMentionName.
const MessageEntityMentionTypeID = 0xfa04579d
MessageEntityMentionTypeID is TL type id of MessageEntityMention.
const MessageEntityPhoneTypeID = 0x9b69e34b
MessageEntityPhoneTypeID is TL type id of MessageEntityPhone.
const MessageEntityPreTypeID = 0x73924be0
MessageEntityPreTypeID is TL type id of MessageEntityPre.
const MessageEntityStrikeTypeID = 0xbf0693d4
MessageEntityStrikeTypeID is TL type id of MessageEntityStrike.
const MessageEntityTextUrlTypeID = 0x76a6d327
MessageEntityTextUrlTypeID is TL type id of MessageEntityTextUrl.
const MessageEntityUnderlineTypeID = 0x9c4e7e8b
MessageEntityUnderlineTypeID is TL type id of MessageEntityUnderline.
const MessageEntityUnknownTypeID = 0xbb92ba95
MessageEntityUnknownTypeID is TL type id of MessageEntityUnknown.
const MessageEntityUrlTypeID = 0x6ed02538
MessageEntityUrlTypeID is TL type id of MessageEntityUrl.
const MessageFwdHeaderTypeID = 0x5f777dce
MessageFwdHeaderTypeID is TL type id of MessageFwdHeader.
const MessageInteractionCountersTypeID = 0xad4fc9bd
MessageInteractionCountersTypeID is TL type id of MessageInteractionCounters.
const MessageMediaContactTypeID = 0xcbf24940
MessageMediaContactTypeID is TL type id of MessageMediaContact.
const MessageMediaDiceTypeID = 0x3f7ee58b
MessageMediaDiceTypeID is TL type id of MessageMediaDice.
const MessageMediaDocumentTypeID = 0x9cb070d7
MessageMediaDocumentTypeID is TL type id of MessageMediaDocument.
const MessageMediaEmptyTypeID = 0x3ded6320
MessageMediaEmptyTypeID is TL type id of MessageMediaEmpty.
const MessageMediaGameTypeID = 0xfdb19008
MessageMediaGameTypeID is TL type id of MessageMediaGame.
const MessageMediaGeoLiveTypeID = 0xb940c666
MessageMediaGeoLiveTypeID is TL type id of MessageMediaGeoLive.
const MessageMediaGeoTypeID = 0x56e0d474
MessageMediaGeoTypeID is TL type id of MessageMediaGeo.
const MessageMediaInvoiceTypeID = 0x84551347
MessageMediaInvoiceTypeID is TL type id of MessageMediaInvoice.
const MessageMediaPhotoTypeID = 0x695150d7
MessageMediaPhotoTypeID is TL type id of MessageMediaPhoto.
const MessageMediaPollTypeID = 0x4bd6e798
MessageMediaPollTypeID is TL type id of MessageMediaPoll.
const MessageMediaUnsupportedTypeID = 0x9f84f49e
MessageMediaUnsupportedTypeID is TL type id of MessageMediaUnsupported.
const MessageMediaVenueTypeID = 0x2ec0533f
MessageMediaVenueTypeID is TL type id of MessageMediaVenue.
const MessageMediaWebPageTypeID = 0xa32dd600
MessageMediaWebPageTypeID is TL type id of MessageMediaWebPage.
const MessageRangeTypeID = 0xae30253
MessageRangeTypeID is TL type id of MessageRange.
const MessageRepliesTypeID = 0x4128faac
MessageRepliesTypeID is TL type id of MessageReplies.
const MessageReplyHeaderTypeID = 0xa6d57763
MessageReplyHeaderTypeID is TL type id of MessageReplyHeader.
const MessageServiceTypeID = 0x286fa604
MessageServiceTypeID is TL type id of MessageService.
const MessageTypeID = 0x58ae39c9
MessageTypeID is TL type id of Message.
const MessageUserVoteInputOptionTypeID = 0x36377430
MessageUserVoteInputOptionTypeID is TL type id of MessageUserVoteInputOption.
const MessageUserVoteMultipleTypeID = 0xe8fe0de
MessageUserVoteMultipleTypeID is TL type id of MessageUserVoteMultiple.
const MessageUserVoteTypeID = 0xa28e5559
MessageUserVoteTypeID is TL type id of MessageUserVote.
const MessageViewsTypeID = 0x455b853d
MessageViewsTypeID is TL type id of MessageViews.
const MessagesAcceptEncryptionRequestTypeID = 0x3dbc0415
MessagesAcceptEncryptionRequestTypeID is TL type id of MessagesAcceptEncryptionRequest.
const MessagesAcceptUrlAuthRequestTypeID = 0xf729ea98
MessagesAcceptUrlAuthRequestTypeID is TL type id of MessagesAcceptUrlAuthRequest.
const MessagesAddChatUserRequestTypeID = 0xf9a0aa09
MessagesAddChatUserRequestTypeID is TL type id of MessagesAddChatUserRequest.
const MessagesAffectedHistoryTypeID = 0xb45c69d1
MessagesAffectedHistoryTypeID is TL type id of MessagesAffectedHistory.
const MessagesAffectedMessagesTypeID = 0x84d19185
MessagesAffectedMessagesTypeID is TL type id of MessagesAffectedMessages.
const MessagesAllStickersNotModifiedTypeID = 0xe86602c3
MessagesAllStickersNotModifiedTypeID is TL type id of MessagesAllStickersNotModified.
const MessagesAllStickersTypeID = 0xedfd405f
MessagesAllStickersTypeID is TL type id of MessagesAllStickers.
const MessagesArchivedStickersTypeID = 0x4fcba9c8
MessagesArchivedStickersTypeID is TL type id of MessagesArchivedStickers.
const MessagesBotCallbackAnswerTypeID = 0x36585ea4
MessagesBotCallbackAnswerTypeID is TL type id of MessagesBotCallbackAnswer.
const MessagesBotResultsTypeID = 0x947ca848
MessagesBotResultsTypeID is TL type id of MessagesBotResults.
const MessagesChannelMessagesTypeID = 0x64479808
MessagesChannelMessagesTypeID is TL type id of MessagesChannelMessages.
const MessagesChatFullTypeID = 0xe5d7d19c
MessagesChatFullTypeID is TL type id of MessagesChatFull.
const MessagesChatsSliceTypeID = 0x9cd81144
MessagesChatsSliceTypeID is TL type id of MessagesChatsSlice.
const MessagesChatsTypeID = 0x64ff9fd5
MessagesChatsTypeID is TL type id of MessagesChats.
const MessagesCheckChatInviteRequestTypeID = 0x3eadb1bb
MessagesCheckChatInviteRequestTypeID is TL type id of MessagesCheckChatInviteRequest.
const MessagesClearAllDraftsRequestTypeID = 0x7e58ee9c
MessagesClearAllDraftsRequestTypeID is TL type id of MessagesClearAllDraftsRequest.
const MessagesClearRecentStickersRequestTypeID = 0x8999602d
MessagesClearRecentStickersRequestTypeID is TL type id of MessagesClearRecentStickersRequest.
const MessagesCreateChatRequestTypeID = 0x9cb126e
MessagesCreateChatRequestTypeID is TL type id of MessagesCreateChatRequest.
const MessagesDeleteChatUserRequestTypeID = 0xe0611f16
MessagesDeleteChatUserRequestTypeID is TL type id of MessagesDeleteChatUserRequest.
const MessagesDeleteHistoryRequestTypeID = 0x1c015b09
MessagesDeleteHistoryRequestTypeID is TL type id of MessagesDeleteHistoryRequest.
const MessagesDeleteMessagesRequestTypeID = 0xe58e95d2
MessagesDeleteMessagesRequestTypeID is TL type id of MessagesDeleteMessagesRequest.
const MessagesDeleteScheduledMessagesRequestTypeID = 0x59ae2b16
MessagesDeleteScheduledMessagesRequestTypeID is TL type id of MessagesDeleteScheduledMessagesRequest.
const MessagesDhConfigNotModifiedTypeID = 0xc0e24635
MessagesDhConfigNotModifiedTypeID is TL type id of MessagesDhConfigNotModified.
const MessagesDhConfigTypeID = 0x2c221edd
MessagesDhConfigTypeID is TL type id of MessagesDhConfig.
const MessagesDialogsNotModifiedTypeID = 0xf0e3e596
MessagesDialogsNotModifiedTypeID is TL type id of MessagesDialogsNotModified.
const MessagesDialogsSliceTypeID = 0x71e094f3
MessagesDialogsSliceTypeID is TL type id of MessagesDialogsSlice.
const MessagesDialogsTypeID = 0x15ba6c40
MessagesDialogsTypeID is TL type id of MessagesDialogs.
const MessagesDiscardEncryptionRequestTypeID = 0xedd923c5
MessagesDiscardEncryptionRequestTypeID is TL type id of MessagesDiscardEncryptionRequest.
const MessagesDiscussionMessageTypeID = 0xf5dd8f9d
MessagesDiscussionMessageTypeID is TL type id of MessagesDiscussionMessage.
const MessagesEditChatAboutRequestTypeID = 0xdef60797
MessagesEditChatAboutRequestTypeID is TL type id of MessagesEditChatAboutRequest.
const MessagesEditChatAdminRequestTypeID = 0xa9e69f2e
MessagesEditChatAdminRequestTypeID is TL type id of MessagesEditChatAdminRequest.
const MessagesEditChatDefaultBannedRightsRequestTypeID = 0xa5866b41
MessagesEditChatDefaultBannedRightsRequestTypeID is TL type id of MessagesEditChatDefaultBannedRightsRequest.
const MessagesEditChatPhotoRequestTypeID = 0xca4c79d8
MessagesEditChatPhotoRequestTypeID is TL type id of MessagesEditChatPhotoRequest.
const MessagesEditChatTitleRequestTypeID = 0xdc452855
MessagesEditChatTitleRequestTypeID is TL type id of MessagesEditChatTitleRequest.
const MessagesEditInlineBotMessageRequestTypeID = 0x83557dba
MessagesEditInlineBotMessageRequestTypeID is TL type id of MessagesEditInlineBotMessageRequest.
const MessagesEditMessageRequestTypeID = 0x48f71778
MessagesEditMessageRequestTypeID is TL type id of MessagesEditMessageRequest.
const MessagesExportChatInviteRequestTypeID = 0xdf7534c
MessagesExportChatInviteRequestTypeID is TL type id of MessagesExportChatInviteRequest.
const MessagesFaveStickerRequestTypeID = 0xb9ffc55b
MessagesFaveStickerRequestTypeID is TL type id of MessagesFaveStickerRequest.
const MessagesFavedStickersNotModifiedTypeID = 0x9e8fa6d3
MessagesFavedStickersNotModifiedTypeID is TL type id of MessagesFavedStickersNotModified.
const MessagesFavedStickersTypeID = 0xf37f2f16
MessagesFavedStickersTypeID is TL type id of MessagesFavedStickers.
const MessagesFeaturedStickersNotModifiedTypeID = 0xc6dc0c66
MessagesFeaturedStickersNotModifiedTypeID is TL type id of MessagesFeaturedStickersNotModified.
const MessagesFeaturedStickersTypeID = 0xb6abc341
MessagesFeaturedStickersTypeID is TL type id of MessagesFeaturedStickers.
const MessagesForwardMessagesRequestTypeID = 0xd9fee60e
MessagesForwardMessagesRequestTypeID is TL type id of MessagesForwardMessagesRequest.
const MessagesFoundStickerSetsNotModifiedTypeID = 0xd54b65d
MessagesFoundStickerSetsNotModifiedTypeID is TL type id of MessagesFoundStickerSetsNotModified.
const MessagesFoundStickerSetsTypeID = 0x5108d648
MessagesFoundStickerSetsTypeID is TL type id of MessagesFoundStickerSets.
const MessagesGetAllChatsRequestTypeID = 0xeba80ff0
MessagesGetAllChatsRequestTypeID is TL type id of MessagesGetAllChatsRequest.
const MessagesGetAllDraftsRequestTypeID = 0x6a3f8d65
MessagesGetAllDraftsRequestTypeID is TL type id of MessagesGetAllDraftsRequest.
const MessagesGetAllStickersRequestTypeID = 0x1c9618b1
MessagesGetAllStickersRequestTypeID is TL type id of MessagesGetAllStickersRequest.
const MessagesGetArchivedStickersRequestTypeID = 0x57f17692
MessagesGetArchivedStickersRequestTypeID is TL type id of MessagesGetArchivedStickersRequest.
const MessagesGetAttachedStickersRequestTypeID = 0xcc5b67cc
MessagesGetAttachedStickersRequestTypeID is TL type id of MessagesGetAttachedStickersRequest.
const MessagesGetBotCallbackAnswerRequestTypeID = 0x9342ca07
MessagesGetBotCallbackAnswerRequestTypeID is TL type id of MessagesGetBotCallbackAnswerRequest.
const MessagesGetChatsRequestTypeID = 0x3c6aa187
MessagesGetChatsRequestTypeID is TL type id of MessagesGetChatsRequest.
const MessagesGetCommonChatsRequestTypeID = 0xd0a48c4
MessagesGetCommonChatsRequestTypeID is TL type id of MessagesGetCommonChatsRequest.
const MessagesGetDhConfigRequestTypeID = 0x26cf8950
MessagesGetDhConfigRequestTypeID is TL type id of MessagesGetDhConfigRequest.
const MessagesGetDialogFiltersRequestTypeID = 0xf19ed96d
MessagesGetDialogFiltersRequestTypeID is TL type id of MessagesGetDialogFiltersRequest.
const MessagesGetDialogUnreadMarksRequestTypeID = 0x22e24e22
MessagesGetDialogUnreadMarksRequestTypeID is TL type id of MessagesGetDialogUnreadMarksRequest.
const MessagesGetDialogsRequestTypeID = 0xa0ee3b73
MessagesGetDialogsRequestTypeID is TL type id of MessagesGetDialogsRequest.
const MessagesGetDiscussionMessageRequestTypeID = 0x446972fd
MessagesGetDiscussionMessageRequestTypeID is TL type id of MessagesGetDiscussionMessageRequest.
const MessagesGetDocumentByHashRequestTypeID = 0x338e2464
MessagesGetDocumentByHashRequestTypeID is TL type id of MessagesGetDocumentByHashRequest.
const MessagesGetEmojiKeywordsDifferenceRequestTypeID = 0x1508b6af
MessagesGetEmojiKeywordsDifferenceRequestTypeID is TL type id of MessagesGetEmojiKeywordsDifferenceRequest.
const MessagesGetEmojiKeywordsLanguagesRequestTypeID = 0x4e9963b2
MessagesGetEmojiKeywordsLanguagesRequestTypeID is TL type id of MessagesGetEmojiKeywordsLanguagesRequest.
const MessagesGetEmojiKeywordsRequestTypeID = 0x35a0e062
MessagesGetEmojiKeywordsRequestTypeID is TL type id of MessagesGetEmojiKeywordsRequest.
const MessagesGetEmojiURLRequestTypeID = 0xd5b10c26
MessagesGetEmojiURLRequestTypeID is TL type id of MessagesGetEmojiURLRequest.
const MessagesGetFavedStickersRequestTypeID = 0x21ce0b0e
MessagesGetFavedStickersRequestTypeID is TL type id of MessagesGetFavedStickersRequest.
const MessagesGetFeaturedStickersRequestTypeID = 0x2dacca4f
MessagesGetFeaturedStickersRequestTypeID is TL type id of MessagesGetFeaturedStickersRequest.
const MessagesGetFullChatRequestTypeID = 0x3b831c66
MessagesGetFullChatRequestTypeID is TL type id of MessagesGetFullChatRequest.
const MessagesGetGameHighScoresRequestTypeID = 0xe822649d
MessagesGetGameHighScoresRequestTypeID is TL type id of MessagesGetGameHighScoresRequest.
const MessagesGetHistoryRequestTypeID = 0xdcbb8260
MessagesGetHistoryRequestTypeID is TL type id of MessagesGetHistoryRequest.
const MessagesGetInlineBotResultsRequestTypeID = 0x514e999d
MessagesGetInlineBotResultsRequestTypeID is TL type id of MessagesGetInlineBotResultsRequest.
const MessagesGetInlineGameHighScoresRequestTypeID = 0xf635e1b
MessagesGetInlineGameHighScoresRequestTypeID is TL type id of MessagesGetInlineGameHighScoresRequest.
const MessagesGetMaskStickersRequestTypeID = 0x65b8c79f
MessagesGetMaskStickersRequestTypeID is TL type id of MessagesGetMaskStickersRequest.
const MessagesGetMessageEditDataRequestTypeID = 0xfda68d36
MessagesGetMessageEditDataRequestTypeID is TL type id of MessagesGetMessageEditDataRequest.
const MessagesGetMessagesRequestTypeID = 0x63c66506
MessagesGetMessagesRequestTypeID is TL type id of MessagesGetMessagesRequest.
const MessagesGetMessagesViewsRequestTypeID = 0x5784d3e1
MessagesGetMessagesViewsRequestTypeID is TL type id of MessagesGetMessagesViewsRequest.
const MessagesGetOldFeaturedStickersRequestTypeID = 0x5fe7025b
MessagesGetOldFeaturedStickersRequestTypeID is TL type id of MessagesGetOldFeaturedStickersRequest.
const MessagesGetOnlinesRequestTypeID = 0x6e2be050
MessagesGetOnlinesRequestTypeID is TL type id of MessagesGetOnlinesRequest.
const MessagesGetPeerDialogsRequestTypeID = 0xe470bcfd
MessagesGetPeerDialogsRequestTypeID is TL type id of MessagesGetPeerDialogsRequest.
const MessagesGetPeerSettingsRequestTypeID = 0x3672e09c
MessagesGetPeerSettingsRequestTypeID is TL type id of MessagesGetPeerSettingsRequest.
const MessagesGetPinnedDialogsRequestTypeID = 0xd6b94df2
MessagesGetPinnedDialogsRequestTypeID is TL type id of MessagesGetPinnedDialogsRequest.
const MessagesGetPollResultsRequestTypeID = 0x73bb643b
MessagesGetPollResultsRequestTypeID is TL type id of MessagesGetPollResultsRequest.
const MessagesGetPollVotesRequestTypeID = 0xb86e380e
MessagesGetPollVotesRequestTypeID is TL type id of MessagesGetPollVotesRequest.
const MessagesGetRecentLocationsRequestTypeID = 0xbbc45b09
MessagesGetRecentLocationsRequestTypeID is TL type id of MessagesGetRecentLocationsRequest.
const MessagesGetRecentStickersRequestTypeID = 0x5ea192c9
MessagesGetRecentStickersRequestTypeID is TL type id of MessagesGetRecentStickersRequest.
const MessagesGetRepliesRequestTypeID = 0x24b581ba
MessagesGetRepliesRequestTypeID is TL type id of MessagesGetRepliesRequest.
const MessagesGetSavedGifsRequestTypeID = 0x83bf3d52
MessagesGetSavedGifsRequestTypeID is TL type id of MessagesGetSavedGifsRequest.
const MessagesGetScheduledHistoryRequestTypeID = 0xe2c2685b
MessagesGetScheduledHistoryRequestTypeID is TL type id of MessagesGetScheduledHistoryRequest.
const MessagesGetScheduledMessagesRequestTypeID = 0xbdbb0464
MessagesGetScheduledMessagesRequestTypeID is TL type id of MessagesGetScheduledMessagesRequest.
const MessagesGetSearchCountersRequestTypeID = 0x732eef00
MessagesGetSearchCountersRequestTypeID is TL type id of MessagesGetSearchCountersRequest.
const MessagesGetSplitRangesRequestTypeID = 0x1cff7e08
MessagesGetSplitRangesRequestTypeID is TL type id of MessagesGetSplitRangesRequest.
const MessagesGetStatsURLRequestTypeID = 0x812c2ae6
MessagesGetStatsURLRequestTypeID is TL type id of MessagesGetStatsURLRequest.
const MessagesGetStickerSetRequestTypeID = 0x2619a90e
MessagesGetStickerSetRequestTypeID is TL type id of MessagesGetStickerSetRequest.
const MessagesGetStickersRequestTypeID = 0x43d4f2c
MessagesGetStickersRequestTypeID is TL type id of MessagesGetStickersRequest.
const MessagesGetSuggestedDialogFiltersRequestTypeID = 0xa29cd42c
MessagesGetSuggestedDialogFiltersRequestTypeID is TL type id of MessagesGetSuggestedDialogFiltersRequest.
const MessagesGetUnreadMentionsRequestTypeID = 0x46578472
MessagesGetUnreadMentionsRequestTypeID is TL type id of MessagesGetUnreadMentionsRequest.
const MessagesGetWebPagePreviewRequestTypeID = 0x8b68b0cc
MessagesGetWebPagePreviewRequestTypeID is TL type id of MessagesGetWebPagePreviewRequest.
const MessagesGetWebPageRequestTypeID = 0x32ca8f91
MessagesGetWebPageRequestTypeID is TL type id of MessagesGetWebPageRequest.
const MessagesHidePeerSettingsBarRequestTypeID = 0x4facb138
MessagesHidePeerSettingsBarRequestTypeID is TL type id of MessagesHidePeerSettingsBarRequest.
const MessagesHighScoresTypeID = 0x9a3bfd99
MessagesHighScoresTypeID is TL type id of MessagesHighScores.
const MessagesImportChatInviteRequestTypeID = 0x6c50051c
MessagesImportChatInviteRequestTypeID is TL type id of MessagesImportChatInviteRequest.
const MessagesInactiveChatsTypeID = 0xa927fec5
MessagesInactiveChatsTypeID is TL type id of MessagesInactiveChats.
const MessagesInstallStickerSetRequestTypeID = 0xc78fe460
MessagesInstallStickerSetRequestTypeID is TL type id of MessagesInstallStickerSetRequest.
const MessagesMarkDialogUnreadRequestTypeID = 0xc286d98f
MessagesMarkDialogUnreadRequestTypeID is TL type id of MessagesMarkDialogUnreadRequest.
const MessagesMessageEditDataTypeID = 0x26b5dde6
MessagesMessageEditDataTypeID is TL type id of MessagesMessageEditData.
const MessagesMessageViewsTypeID = 0xb6c4f543
MessagesMessageViewsTypeID is TL type id of MessagesMessageViews.
const MessagesMessagesNotModifiedTypeID = 0x74535f21
MessagesMessagesNotModifiedTypeID is TL type id of MessagesMessagesNotModified.
const MessagesMessagesSliceTypeID = 0x3a54685e
MessagesMessagesSliceTypeID is TL type id of MessagesMessagesSlice.
const MessagesMessagesTypeID = 0x8c718e87
MessagesMessagesTypeID is TL type id of MessagesMessages.
const MessagesMigrateChatRequestTypeID = 0x15a3b8e3
MessagesMigrateChatRequestTypeID is TL type id of MessagesMigrateChatRequest.
const MessagesPeerDialogsTypeID = 0x3371c354
MessagesPeerDialogsTypeID is TL type id of MessagesPeerDialogs.
const MessagesReadDiscussionRequestTypeID = 0xf731a9f4
MessagesReadDiscussionRequestTypeID is TL type id of MessagesReadDiscussionRequest.
const MessagesReadEncryptedHistoryRequestTypeID = 0x7f4b690a
MessagesReadEncryptedHistoryRequestTypeID is TL type id of MessagesReadEncryptedHistoryRequest.
const MessagesReadFeaturedStickersRequestTypeID = 0x5b118126
MessagesReadFeaturedStickersRequestTypeID is TL type id of MessagesReadFeaturedStickersRequest.
const MessagesReadHistoryRequestTypeID = 0xe306d3a
MessagesReadHistoryRequestTypeID is TL type id of MessagesReadHistoryRequest.
const MessagesReadMentionsRequestTypeID = 0xf0189d3
MessagesReadMentionsRequestTypeID is TL type id of MessagesReadMentionsRequest.
const MessagesReadMessageContentsRequestTypeID = 0x36a73f77
MessagesReadMessageContentsRequestTypeID is TL type id of MessagesReadMessageContentsRequest.
const MessagesReceivedMessagesRequestTypeID = 0x5a954c0
MessagesReceivedMessagesRequestTypeID is TL type id of MessagesReceivedMessagesRequest.
const MessagesReceivedQueueRequestTypeID = 0x55a5bb66
MessagesReceivedQueueRequestTypeID is TL type id of MessagesReceivedQueueRequest.
const MessagesRecentStickersNotModifiedTypeID = 0xb17f890
MessagesRecentStickersNotModifiedTypeID is TL type id of MessagesRecentStickersNotModified.
const MessagesRecentStickersTypeID = 0x22f3afb3
MessagesRecentStickersTypeID is TL type id of MessagesRecentStickers.
const MessagesReorderPinnedDialogsRequestTypeID = 0x3b1adf37
MessagesReorderPinnedDialogsRequestTypeID is TL type id of MessagesReorderPinnedDialogsRequest.
const MessagesReorderStickerSetsRequestTypeID = 0x78337739
MessagesReorderStickerSetsRequestTypeID is TL type id of MessagesReorderStickerSetsRequest.
const MessagesReportEncryptedSpamRequestTypeID = 0x4b0c8c0f
MessagesReportEncryptedSpamRequestTypeID is TL type id of MessagesReportEncryptedSpamRequest.
const MessagesReportRequestTypeID = 0xbd82b658
MessagesReportRequestTypeID is TL type id of MessagesReportRequest.
const MessagesReportSpamRequestTypeID = 0xcf1592db
MessagesReportSpamRequestTypeID is TL type id of MessagesReportSpamRequest.
const MessagesRequestEncryptionRequestTypeID = 0xf64daf43
MessagesRequestEncryptionRequestTypeID is TL type id of MessagesRequestEncryptionRequest.
const MessagesRequestUrlAuthRequestTypeID = 0xe33f5613
MessagesRequestUrlAuthRequestTypeID is TL type id of MessagesRequestUrlAuthRequest.
const MessagesSaveDraftRequestTypeID = 0xbc39e14b
MessagesSaveDraftRequestTypeID is TL type id of MessagesSaveDraftRequest.
const MessagesSaveGifRequestTypeID = 0x327a30cb
MessagesSaveGifRequestTypeID is TL type id of MessagesSaveGifRequest.
const MessagesSaveRecentStickerRequestTypeID = 0x392718f8
MessagesSaveRecentStickerRequestTypeID is TL type id of MessagesSaveRecentStickerRequest.
const MessagesSavedGifsNotModifiedTypeID = 0xe8025ca2
MessagesSavedGifsNotModifiedTypeID is TL type id of MessagesSavedGifsNotModified.
const MessagesSavedGifsTypeID = 0x2e0709a5
MessagesSavedGifsTypeID is TL type id of MessagesSavedGifs.
const MessagesSearchCounterTypeID = 0xe844ebff
MessagesSearchCounterTypeID is TL type id of MessagesSearchCounter.
const MessagesSearchGlobalRequestTypeID = 0x4bc6589a
MessagesSearchGlobalRequestTypeID is TL type id of MessagesSearchGlobalRequest.
const MessagesSearchRequestTypeID = 0xc352eec
MessagesSearchRequestTypeID is TL type id of MessagesSearchRequest.
const MessagesSearchStickerSetsRequestTypeID = 0xc2b7d08b
MessagesSearchStickerSetsRequestTypeID is TL type id of MessagesSearchStickerSetsRequest.
const MessagesSendEncryptedFileRequestTypeID = 0x5559481d
MessagesSendEncryptedFileRequestTypeID is TL type id of MessagesSendEncryptedFileRequest.
const MessagesSendEncryptedRequestTypeID = 0x44fa7a15
MessagesSendEncryptedRequestTypeID is TL type id of MessagesSendEncryptedRequest.
const MessagesSendEncryptedServiceRequestTypeID = 0x32d439a4
MessagesSendEncryptedServiceRequestTypeID is TL type id of MessagesSendEncryptedServiceRequest.
const MessagesSendInlineBotResultRequestTypeID = 0x220815b0
MessagesSendInlineBotResultRequestTypeID is TL type id of MessagesSendInlineBotResultRequest.
const MessagesSendMediaRequestTypeID = 0x3491eba9
MessagesSendMediaRequestTypeID is TL type id of MessagesSendMediaRequest.
const MessagesSendMessageRequestTypeID = 0x520c3870
MessagesSendMessageRequestTypeID is TL type id of MessagesSendMessageRequest.
const MessagesSendMultiMediaRequestTypeID = 0xcc0110cb
MessagesSendMultiMediaRequestTypeID is TL type id of MessagesSendMultiMediaRequest.
const MessagesSendScheduledMessagesRequestTypeID = 0xbd38850a
MessagesSendScheduledMessagesRequestTypeID is TL type id of MessagesSendScheduledMessagesRequest.
const MessagesSendScreenshotNotificationRequestTypeID = 0xc97df020
MessagesSendScreenshotNotificationRequestTypeID is TL type id of MessagesSendScreenshotNotificationRequest.
const MessagesSendVoteRequestTypeID = 0x10ea6184
MessagesSendVoteRequestTypeID is TL type id of MessagesSendVoteRequest.
const MessagesSentEncryptedFileTypeID = 0x9493ff32
MessagesSentEncryptedFileTypeID is TL type id of MessagesSentEncryptedFile.
const MessagesSentEncryptedMessageTypeID = 0x560f8935
MessagesSentEncryptedMessageTypeID is TL type id of MessagesSentEncryptedMessage.
const MessagesSetBotCallbackAnswerRequestTypeID = 0xd58f130a
MessagesSetBotCallbackAnswerRequestTypeID is TL type id of MessagesSetBotCallbackAnswerRequest.
const MessagesSetBotPrecheckoutResultsRequestTypeID = 0x9c2dd95
MessagesSetBotPrecheckoutResultsRequestTypeID is TL type id of MessagesSetBotPrecheckoutResultsRequest.
const MessagesSetBotShippingResultsRequestTypeID = 0xe5f672fa
MessagesSetBotShippingResultsRequestTypeID is TL type id of MessagesSetBotShippingResultsRequest.
const MessagesSetEncryptedTypingRequestTypeID = 0x791451ed
MessagesSetEncryptedTypingRequestTypeID is TL type id of MessagesSetEncryptedTypingRequest.
const MessagesSetGameScoreRequestTypeID = 0x8ef8ecc0
MessagesSetGameScoreRequestTypeID is TL type id of MessagesSetGameScoreRequest.
const MessagesSetInlineBotResultsRequestTypeID = 0xeb5ea206
MessagesSetInlineBotResultsRequestTypeID is TL type id of MessagesSetInlineBotResultsRequest.
const MessagesSetInlineGameScoreRequestTypeID = 0x15ad9f64
MessagesSetInlineGameScoreRequestTypeID is TL type id of MessagesSetInlineGameScoreRequest.
const MessagesSetTypingRequestTypeID = 0x58943ee2
MessagesSetTypingRequestTypeID is TL type id of MessagesSetTypingRequest.
const MessagesStartBotRequestTypeID = 0xe6df7378
MessagesStartBotRequestTypeID is TL type id of MessagesStartBotRequest.
const MessagesStickerSetInstallResultArchiveTypeID = 0x35e410a8
MessagesStickerSetInstallResultArchiveTypeID is TL type id of MessagesStickerSetInstallResultArchive.
const MessagesStickerSetInstallResultSuccessTypeID = 0x38641628
MessagesStickerSetInstallResultSuccessTypeID is TL type id of MessagesStickerSetInstallResultSuccess.
const MessagesStickerSetTypeID = 0xb60a24a6
MessagesStickerSetTypeID is TL type id of MessagesStickerSet.
const MessagesStickersNotModifiedTypeID = 0xf1749a22
MessagesStickersNotModifiedTypeID is TL type id of MessagesStickersNotModified.
const MessagesStickersTypeID = 0xe4599bbd
MessagesStickersTypeID is TL type id of MessagesStickers.
const MessagesToggleDialogPinRequestTypeID = 0xa731e257
MessagesToggleDialogPinRequestTypeID is TL type id of MessagesToggleDialogPinRequest.
const MessagesToggleStickerSetsRequestTypeID = 0xb5052fea
MessagesToggleStickerSetsRequestTypeID is TL type id of MessagesToggleStickerSetsRequest.
const MessagesUninstallStickerSetRequestTypeID = 0xf96e55de
MessagesUninstallStickerSetRequestTypeID is TL type id of MessagesUninstallStickerSetRequest.
const MessagesUnpinAllMessagesRequestTypeID = 0xf025bc8b
MessagesUnpinAllMessagesRequestTypeID is TL type id of MessagesUnpinAllMessagesRequest.
const MessagesUpdateDialogFilterRequestTypeID = 0x1ad4a04a
MessagesUpdateDialogFilterRequestTypeID is TL type id of MessagesUpdateDialogFilterRequest.
const MessagesUpdateDialogFiltersOrderRequestTypeID = 0xc563c1e4
MessagesUpdateDialogFiltersOrderRequestTypeID is TL type id of MessagesUpdateDialogFiltersOrderRequest.
const MessagesUpdatePinnedMessageRequestTypeID = 0xd2aaf7ec
MessagesUpdatePinnedMessageRequestTypeID is TL type id of MessagesUpdatePinnedMessageRequest.
const MessagesUploadEncryptedFileRequestTypeID = 0x5057c497
MessagesUploadEncryptedFileRequestTypeID is TL type id of MessagesUploadEncryptedFileRequest.
const MessagesUploadMediaRequestTypeID = 0x519bc2b1
MessagesUploadMediaRequestTypeID is TL type id of MessagesUploadMediaRequest.
const MessagesVotesListTypeID = 0x823f649
MessagesVotesListTypeID is TL type id of MessagesVotesList.
const NearestDcTypeID = 0x8e1a1775
NearestDcTypeID is TL type id of NearestDc.
const NotifyBroadcastsTypeID = 0xd612e8ef
NotifyBroadcastsTypeID is TL type id of NotifyBroadcasts.
const NotifyChatsTypeID = 0xc007cec3
NotifyChatsTypeID is TL type id of NotifyChats.
const NotifyPeerTypeID = 0x9fd40bd8
NotifyPeerTypeID is TL type id of NotifyPeer.
const NotifyUsersTypeID = 0xb4c83b4c
NotifyUsersTypeID is TL type id of NotifyUsers.
const NullTypeID = 0x56730bcc
NullTypeID is TL type id of Null.
const PageBlockAnchorTypeID = 0xce0d37b0
PageBlockAnchorTypeID is TL type id of PageBlockAnchor.
const PageBlockAudioTypeID = 0x804361ea
PageBlockAudioTypeID is TL type id of PageBlockAudio.
const PageBlockAuthorDateTypeID = 0xbaafe5e0
PageBlockAuthorDateTypeID is TL type id of PageBlockAuthorDate.
const PageBlockBlockquoteTypeID = 0x263d7c26
PageBlockBlockquoteTypeID is TL type id of PageBlockBlockquote.
const PageBlockChannelTypeID = 0xef1751b5
PageBlockChannelTypeID is TL type id of PageBlockChannel.
const PageBlockCollageTypeID = 0x65a0fa4d
PageBlockCollageTypeID is TL type id of PageBlockCollage.
const PageBlockCoverTypeID = 0x39f23300
PageBlockCoverTypeID is TL type id of PageBlockCover.
const PageBlockDetailsTypeID = 0x76768bed
PageBlockDetailsTypeID is TL type id of PageBlockDetails.
const PageBlockDividerTypeID = 0xdb20b188
PageBlockDividerTypeID is TL type id of PageBlockDivider.
const PageBlockEmbedPostTypeID = 0xf259a80b
PageBlockEmbedPostTypeID is TL type id of PageBlockEmbedPost.
const PageBlockEmbedTypeID = 0xa8718dc5
PageBlockEmbedTypeID is TL type id of PageBlockEmbed.
PageBlockFooterTypeID is TL type id of PageBlockFooter.
const PageBlockHeaderTypeID = 0xbfd064ec
PageBlockHeaderTypeID is TL type id of PageBlockHeader.
const PageBlockKickerTypeID = 0x1e148390
PageBlockKickerTypeID is TL type id of PageBlockKicker.
const PageBlockListTypeID = 0xe4e88011
PageBlockListTypeID is TL type id of PageBlockList.
const PageBlockMapTypeID = 0xa44f3ef6
PageBlockMapTypeID is TL type id of PageBlockMap.
const PageBlockOrderedListTypeID = 0x9a8ae1e1
PageBlockOrderedListTypeID is TL type id of PageBlockOrderedList.
const PageBlockParagraphTypeID = 0x467a0766
PageBlockParagraphTypeID is TL type id of PageBlockParagraph.
const PageBlockPhotoTypeID = 0x1759c560
PageBlockPhotoTypeID is TL type id of PageBlockPhoto.
const PageBlockPreformattedTypeID = 0xc070d93e
PageBlockPreformattedTypeID is TL type id of PageBlockPreformatted.
const PageBlockPullquoteTypeID = 0x4f4456d3
PageBlockPullquoteTypeID is TL type id of PageBlockPullquote.
const PageBlockRelatedArticlesTypeID = 0x16115a96
PageBlockRelatedArticlesTypeID is TL type id of PageBlockRelatedArticles.
const PageBlockSlideshowTypeID = 0x31f9590
PageBlockSlideshowTypeID is TL type id of PageBlockSlideshow.
const PageBlockSubheaderTypeID = 0xf12bb6e1
PageBlockSubheaderTypeID is TL type id of PageBlockSubheader.
const PageBlockSubtitleTypeID = 0x8ffa9a1f
PageBlockSubtitleTypeID is TL type id of PageBlockSubtitle.
const PageBlockTableTypeID = 0xbf4dea82
PageBlockTableTypeID is TL type id of PageBlockTable.
const PageBlockTitleTypeID = 0x70abc3fd
PageBlockTitleTypeID is TL type id of PageBlockTitle.
const PageBlockUnsupportedTypeID = 0x13567e8a
PageBlockUnsupportedTypeID is TL type id of PageBlockUnsupported.
const PageBlockVideoTypeID = 0x7c8fe7b6
PageBlockVideoTypeID is TL type id of PageBlockVideo.
const PageCaptionTypeID = 0x6f747657
PageCaptionTypeID is TL type id of PageCaption.
const PageListItemBlocksTypeID = 0x25e073fc
PageListItemBlocksTypeID is TL type id of PageListItemBlocks.
const PageListItemTextTypeID = 0xb92fb6cd
PageListItemTextTypeID is TL type id of PageListItemText.
const PageListOrderedItemBlocksTypeID = 0x98dd8936
PageListOrderedItemBlocksTypeID is TL type id of PageListOrderedItemBlocks.
const PageListOrderedItemTextTypeID = 0x5e068047
PageListOrderedItemTextTypeID is TL type id of PageListOrderedItemText.
const PageRelatedArticleTypeID = 0xb390dc08
PageRelatedArticleTypeID is TL type id of PageRelatedArticle.
const PageTableCellTypeID = 0x34566b6a
PageTableCellTypeID is TL type id of PageTableCell.
const PageTableRowTypeID = 0xe0c0c5e5
PageTableRowTypeID is TL type id of PageTableRow.
const PageTypeID = 0x98657f0d
PageTypeID is TL type id of Page.
const PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPowTypeID = 0x3a912d4a
PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPowTypeID is TL type id of PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.
const PasswordKdfAlgoUnknownTypeID = 0xd45ab096
PasswordKdfAlgoUnknownTypeID is TL type id of PasswordKdfAlgoUnknown.
const PaymentChargeTypeID = 0xea02c27e
PaymentChargeTypeID is TL type id of PaymentCharge.
const PaymentRequestedInfoTypeID = 0x909c3f94
PaymentRequestedInfoTypeID is TL type id of PaymentRequestedInfo.
const PaymentSavedCredentialsCardTypeID = 0xcdc27a1f
PaymentSavedCredentialsCardTypeID is TL type id of PaymentSavedCredentialsCard.
const PaymentsBankCardDataTypeID = 0x3e24e573
PaymentsBankCardDataTypeID is TL type id of PaymentsBankCardData.
const PaymentsClearSavedInfoRequestTypeID = 0xd83d70c1
PaymentsClearSavedInfoRequestTypeID is TL type id of PaymentsClearSavedInfoRequest.
const PaymentsGetBankCardDataRequestTypeID = 0x2e79d779
PaymentsGetBankCardDataRequestTypeID is TL type id of PaymentsGetBankCardDataRequest.
const PaymentsGetPaymentFormRequestTypeID = 0x99f09745
PaymentsGetPaymentFormRequestTypeID is TL type id of PaymentsGetPaymentFormRequest.
const PaymentsGetPaymentReceiptRequestTypeID = 0xa092a980
PaymentsGetPaymentReceiptRequestTypeID is TL type id of PaymentsGetPaymentReceiptRequest.
const PaymentsGetSavedInfoRequestTypeID = 0x227d824b
PaymentsGetSavedInfoRequestTypeID is TL type id of PaymentsGetSavedInfoRequest.
const PaymentsPaymentFormTypeID = 0x3f56aea3
PaymentsPaymentFormTypeID is TL type id of PaymentsPaymentForm.
const PaymentsPaymentReceiptTypeID = 0x500911e1
PaymentsPaymentReceiptTypeID is TL type id of PaymentsPaymentReceipt.
const PaymentsPaymentResultTypeID = 0x4e5f810d
PaymentsPaymentResultTypeID is TL type id of PaymentsPaymentResult.
const PaymentsPaymentVerificationNeededTypeID = 0xd8411139
PaymentsPaymentVerificationNeededTypeID is TL type id of PaymentsPaymentVerificationNeeded.
const PaymentsSavedInfoTypeID = 0xfb8fe43c
PaymentsSavedInfoTypeID is TL type id of PaymentsSavedInfo.
const PaymentsSendPaymentFormRequestTypeID = 0x2b8879b3
PaymentsSendPaymentFormRequestTypeID is TL type id of PaymentsSendPaymentFormRequest.
const PaymentsValidateRequestedInfoRequestTypeID = 0x770a8e74
PaymentsValidateRequestedInfoRequestTypeID is TL type id of PaymentsValidateRequestedInfoRequest.
const PaymentsValidatedRequestedInfoTypeID = 0xd1451883
PaymentsValidatedRequestedInfoTypeID is TL type id of PaymentsValidatedRequestedInfo.
const PeerBlockedTypeID = 0xe8fd8014
PeerBlockedTypeID is TL type id of PeerBlocked.
const PeerChannelTypeID = 0xbddde532
PeerChannelTypeID is TL type id of PeerChannel.
const PeerChatTypeID = 0xbad0e5bb
PeerChatTypeID is TL type id of PeerChat.
const PeerLocatedTypeID = 0xca461b5d
PeerLocatedTypeID is TL type id of PeerLocated.
const PeerNotifySettingsTypeID = 0xaf509d20
PeerNotifySettingsTypeID is TL type id of PeerNotifySettings.
const PeerSelfLocatedTypeID = 0xf8ec284b
PeerSelfLocatedTypeID is TL type id of PeerSelfLocated.
const PeerSettingsTypeID = 0x733f2961
PeerSettingsTypeID is TL type id of PeerSettings.
const PeerUserTypeID = 0x9db1bc6d
PeerUserTypeID is TL type id of PeerUser.
const PhoneAcceptCallRequestTypeID = 0x3bd2b4a0
PhoneAcceptCallRequestTypeID is TL type id of PhoneAcceptCallRequest.
const PhoneCallAcceptedTypeID = 0x997c454a
PhoneCallAcceptedTypeID is TL type id of PhoneCallAccepted.
const PhoneCallDiscardReasonBusyTypeID = 0xfaf7e8c9
PhoneCallDiscardReasonBusyTypeID is TL type id of PhoneCallDiscardReasonBusy.
const PhoneCallDiscardReasonDisconnectTypeID = 0xe095c1a0
PhoneCallDiscardReasonDisconnectTypeID is TL type id of PhoneCallDiscardReasonDisconnect.
const PhoneCallDiscardReasonHangupTypeID = 0x57adc690
PhoneCallDiscardReasonHangupTypeID is TL type id of PhoneCallDiscardReasonHangup.
const PhoneCallDiscardReasonMissedTypeID = 0x85e42301
PhoneCallDiscardReasonMissedTypeID is TL type id of PhoneCallDiscardReasonMissed.
const PhoneCallDiscardedTypeID = 0x50ca4de1
PhoneCallDiscardedTypeID is TL type id of PhoneCallDiscarded.
const PhoneCallEmptyTypeID = 0x5366c915
PhoneCallEmptyTypeID is TL type id of PhoneCallEmpty.
const PhoneCallProtocolTypeID = 0xfc878fc8
PhoneCallProtocolTypeID is TL type id of PhoneCallProtocol.
const PhoneCallRequestedTypeID = 0x87eabb53
PhoneCallRequestedTypeID is TL type id of PhoneCallRequested.
const PhoneCallTypeID = 0x8742ae7f
PhoneCallTypeID is TL type id of PhoneCall.
const PhoneCallWaitingTypeID = 0x1b8f4ad1
PhoneCallWaitingTypeID is TL type id of PhoneCallWaiting.
const PhoneCheckGroupCallRequestTypeID = 0xb74a7bea
PhoneCheckGroupCallRequestTypeID is TL type id of PhoneCheckGroupCallRequest.
const PhoneConfirmCallRequestTypeID = 0x2efe1722
PhoneConfirmCallRequestTypeID is TL type id of PhoneConfirmCallRequest.
const PhoneConnectionTypeID = 0x9d4c17c0
PhoneConnectionTypeID is TL type id of PhoneConnection.
const PhoneConnectionWebrtcTypeID = 0x635fe375
PhoneConnectionWebrtcTypeID is TL type id of PhoneConnectionWebrtc.
const PhoneCreateGroupCallRequestTypeID = 0xbd3dabe0
PhoneCreateGroupCallRequestTypeID is TL type id of PhoneCreateGroupCallRequest.
const PhoneDiscardCallRequestTypeID = 0xb2cbc1c0
PhoneDiscardCallRequestTypeID is TL type id of PhoneDiscardCallRequest.
const PhoneDiscardGroupCallRequestTypeID = 0x7a777135
PhoneDiscardGroupCallRequestTypeID is TL type id of PhoneDiscardGroupCallRequest.
const PhoneEditGroupCallMemberRequestTypeID = 0x63146ae4
PhoneEditGroupCallMemberRequestTypeID is TL type id of PhoneEditGroupCallMemberRequest.
const PhoneGetCallConfigRequestTypeID = 0x55451fa9
PhoneGetCallConfigRequestTypeID is TL type id of PhoneGetCallConfigRequest.
const PhoneGetGroupCallRequestTypeID = 0xc7cb017
PhoneGetGroupCallRequestTypeID is TL type id of PhoneGetGroupCallRequest.
const PhoneGetGroupParticipantsRequestTypeID = 0xc9f1d285
PhoneGetGroupParticipantsRequestTypeID is TL type id of PhoneGetGroupParticipantsRequest.
const PhoneGroupCallTypeID = 0x66ab0bfc
PhoneGroupCallTypeID is TL type id of PhoneGroupCall.
const PhoneGroupParticipantsTypeID = 0x9cfeb92d
PhoneGroupParticipantsTypeID is TL type id of PhoneGroupParticipants.
const PhoneInviteToGroupCallRequestTypeID = 0x7b393160
PhoneInviteToGroupCallRequestTypeID is TL type id of PhoneInviteToGroupCallRequest.
const PhoneJoinGroupCallRequestTypeID = 0x5f9c8e62
PhoneJoinGroupCallRequestTypeID is TL type id of PhoneJoinGroupCallRequest.
const PhoneLeaveGroupCallRequestTypeID = 0x500377f9
PhoneLeaveGroupCallRequestTypeID is TL type id of PhoneLeaveGroupCallRequest.
const PhonePhoneCallTypeID = 0xec82e140
PhonePhoneCallTypeID is TL type id of PhonePhoneCall.
const PhoneReceivedCallRequestTypeID = 0x17d54f61
PhoneReceivedCallRequestTypeID is TL type id of PhoneReceivedCallRequest.
const PhoneRequestCallRequestTypeID = 0x42ff96ed
PhoneRequestCallRequestTypeID is TL type id of PhoneRequestCallRequest.
const PhoneSaveCallDebugRequestTypeID = 0x277add7e
PhoneSaveCallDebugRequestTypeID is TL type id of PhoneSaveCallDebugRequest.
const PhoneSendSignalingDataRequestTypeID = 0xff7a9383
PhoneSendSignalingDataRequestTypeID is TL type id of PhoneSendSignalingDataRequest.
const PhoneSetCallRatingRequestTypeID = 0x59ead627
PhoneSetCallRatingRequestTypeID is TL type id of PhoneSetCallRatingRequest.
const PhoneToggleGroupCallSettingsRequestTypeID = 0x74bbb43d
PhoneToggleGroupCallSettingsRequestTypeID is TL type id of PhoneToggleGroupCallSettingsRequest.
const PhotoCachedSizeTypeID = 0xe9a734fa
PhotoCachedSizeTypeID is TL type id of PhotoCachedSize.
const PhotoEmptyTypeID = 0x2331b22d
PhotoEmptyTypeID is TL type id of PhotoEmpty.
const PhotoPathSizeTypeID = 0xd8214d41
PhotoPathSizeTypeID is TL type id of PhotoPathSize.
const PhotoSizeEmptyTypeID = 0xe17e23c
PhotoSizeEmptyTypeID is TL type id of PhotoSizeEmpty.
const PhotoSizeProgressiveTypeID = 0x5aa86a51
PhotoSizeProgressiveTypeID is TL type id of PhotoSizeProgressive.
const PhotoSizeTypeID = 0x77bfb61b
PhotoSizeTypeID is TL type id of PhotoSize.
const PhotoStrippedSizeTypeID = 0xe0b0bc2e
PhotoStrippedSizeTypeID is TL type id of PhotoStrippedSize.
const PhotoTypeID = 0xfb197a65
PhotoTypeID is TL type id of Photo.
const PhotosDeletePhotosRequestTypeID = 0x87cf7f2f
PhotosDeletePhotosRequestTypeID is TL type id of PhotosDeletePhotosRequest.
const PhotosGetUserPhotosRequestTypeID = 0x91cd32a8
PhotosGetUserPhotosRequestTypeID is TL type id of PhotosGetUserPhotosRequest.
const PhotosPhotoTypeID = 0x20212ca8
PhotosPhotoTypeID is TL type id of PhotosPhoto.
const PhotosPhotosSliceTypeID = 0x15051f54
PhotosPhotosSliceTypeID is TL type id of PhotosPhotosSlice.
const PhotosPhotosTypeID = 0x8dca6aa5
PhotosPhotosTypeID is TL type id of PhotosPhotos.
const PhotosUpdateProfilePhotoRequestTypeID = 0x72d4742c
PhotosUpdateProfilePhotoRequestTypeID is TL type id of PhotosUpdateProfilePhotoRequest.
const PhotosUploadProfilePhotoRequestTypeID = 0x89f30f69
PhotosUploadProfilePhotoRequestTypeID is TL type id of PhotosUploadProfilePhotoRequest.
const PollAnswerTypeID = 0x6ca9c2e9
PollAnswerTypeID is TL type id of PollAnswer.
const PollAnswerVotersTypeID = 0x3b6ddad2
PollAnswerVotersTypeID is TL type id of PollAnswerVoters.
const PollResultsTypeID = 0xbadcc1a3
PollResultsTypeID is TL type id of PollResults.
const PollTypeID = 0x86e18161
PollTypeID is TL type id of Poll.
const PopularContactTypeID = 0x5ce14175
PopularContactTypeID is TL type id of PopularContact.
const PostAddressTypeID = 0x1e8caaeb
PostAddressTypeID is TL type id of PostAddress.
const PrivacyKeyAddedByPhoneTypeID = 0x42ffd42b
PrivacyKeyAddedByPhoneTypeID is TL type id of PrivacyKeyAddedByPhone.
const PrivacyKeyChatInviteTypeID = 0x500e6dfa
PrivacyKeyChatInviteTypeID is TL type id of PrivacyKeyChatInvite.
const PrivacyKeyForwardsTypeID = 0x69ec56a3
PrivacyKeyForwardsTypeID is TL type id of PrivacyKeyForwards.
const PrivacyKeyPhoneCallTypeID = 0x3d662b7b
PrivacyKeyPhoneCallTypeID is TL type id of PrivacyKeyPhoneCall.
const PrivacyKeyPhoneNumberTypeID = 0xd19ae46d
PrivacyKeyPhoneNumberTypeID is TL type id of PrivacyKeyPhoneNumber.
const PrivacyKeyPhoneP2PTypeID = 0x39491cc8
PrivacyKeyPhoneP2PTypeID is TL type id of PrivacyKeyPhoneP2P.
const PrivacyKeyProfilePhotoTypeID = 0x96151fed
PrivacyKeyProfilePhotoTypeID is TL type id of PrivacyKeyProfilePhoto.
const PrivacyKeyStatusTimestampTypeID = 0xbc2eab30
PrivacyKeyStatusTimestampTypeID is TL type id of PrivacyKeyStatusTimestamp.
const PrivacyValueAllowAllTypeID = 0x65427b82
PrivacyValueAllowAllTypeID is TL type id of PrivacyValueAllowAll.
const PrivacyValueAllowChatParticipantsTypeID = 0x18be796b
PrivacyValueAllowChatParticipantsTypeID is TL type id of PrivacyValueAllowChatParticipants.
const PrivacyValueAllowContactsTypeID = 0xfffe1bac
PrivacyValueAllowContactsTypeID is TL type id of PrivacyValueAllowContacts.
const PrivacyValueAllowUsersTypeID = 0x4d5bbe0c
PrivacyValueAllowUsersTypeID is TL type id of PrivacyValueAllowUsers.
const PrivacyValueDisallowAllTypeID = 0x8b73e763
PrivacyValueDisallowAllTypeID is TL type id of PrivacyValueDisallowAll.
const PrivacyValueDisallowChatParticipantsTypeID = 0xacae0690
PrivacyValueDisallowChatParticipantsTypeID is TL type id of PrivacyValueDisallowChatParticipants.
const PrivacyValueDisallowContactsTypeID = 0xf888fa1a
PrivacyValueDisallowContactsTypeID is TL type id of PrivacyValueDisallowContacts.
const PrivacyValueDisallowUsersTypeID = 0xc7f49b7
PrivacyValueDisallowUsersTypeID is TL type id of PrivacyValueDisallowUsers.
const ReceivedNotifyMessageTypeID = 0xa384b779
ReceivedNotifyMessageTypeID is TL type id of ReceivedNotifyMessage.
const RecentMeUrlChatInviteTypeID = 0xeb49081d
RecentMeUrlChatInviteTypeID is TL type id of RecentMeUrlChatInvite.
const RecentMeUrlChatTypeID = 0xa01b22f9
RecentMeUrlChatTypeID is TL type id of RecentMeUrlChat.
const RecentMeUrlStickerSetTypeID = 0xbc0a57dc
RecentMeUrlStickerSetTypeID is TL type id of RecentMeUrlStickerSet.
const RecentMeUrlUnknownTypeID = 0x46e1d13d
RecentMeUrlUnknownTypeID is TL type id of RecentMeUrlUnknown.
const RecentMeUrlUserTypeID = 0x8dbc3336
RecentMeUrlUserTypeID is TL type id of RecentMeUrlUser.
const ReplyInlineMarkupTypeID = 0x48a30254
ReplyInlineMarkupTypeID is TL type id of ReplyInlineMarkup.
const ReplyKeyboardForceReplyTypeID = 0xf4108aa0
ReplyKeyboardForceReplyTypeID is TL type id of ReplyKeyboardForceReply.
const ReplyKeyboardHideTypeID = 0xa03e5b85
ReplyKeyboardHideTypeID is TL type id of ReplyKeyboardHide.
const ReplyKeyboardMarkupTypeID = 0x3502758c
ReplyKeyboardMarkupTypeID is TL type id of ReplyKeyboardMarkup.
const RestrictionReasonTypeID = 0xd072acb4
RestrictionReasonTypeID is TL type id of RestrictionReason.
const SavedPhoneContactTypeID = 0x1142bd56
SavedPhoneContactTypeID is TL type id of SavedPhoneContact.
const SecureCredentialsEncryptedTypeID = 0x33f0ea47
SecureCredentialsEncryptedTypeID is TL type id of SecureCredentialsEncrypted.
const SecureDataTypeID = 0x8aeabec3
SecureDataTypeID is TL type id of SecureData.
const SecureFileEmptyTypeID = 0x64199744
SecureFileEmptyTypeID is TL type id of SecureFileEmpty.
const SecureFileTypeID = 0xe0277a62
SecureFileTypeID is TL type id of SecureFile.
const SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000TypeID = 0xbbf2dda0
SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000TypeID is TL type id of SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000.
const SecurePasswordKdfAlgoSHA512TypeID = 0x86471d92
SecurePasswordKdfAlgoSHA512TypeID is TL type id of SecurePasswordKdfAlgoSHA512.
const SecurePasswordKdfAlgoUnknownTypeID = 0x4a8537
SecurePasswordKdfAlgoUnknownTypeID is TL type id of SecurePasswordKdfAlgoUnknown.
const SecurePlainEmailTypeID = 0x21ec5a5f
SecurePlainEmailTypeID is TL type id of SecurePlainEmail.
const SecurePlainPhoneTypeID = 0x7d6099dd
SecurePlainPhoneTypeID is TL type id of SecurePlainPhone.
const SecureRequiredTypeOneOfTypeID = 0x27477b4
SecureRequiredTypeOneOfTypeID is TL type id of SecureRequiredTypeOneOf.
const SecureRequiredTypeTypeID = 0x829d99da
SecureRequiredTypeTypeID is TL type id of SecureRequiredType.
const SecureSecretSettingsTypeID = 0x1527bcac
SecureSecretSettingsTypeID is TL type id of SecureSecretSettings.
const SecureValueErrorDataTypeID = 0xe8a40bd9
SecureValueErrorDataTypeID is TL type id of SecureValueErrorData.
const SecureValueErrorFileTypeID = 0x7a700873
SecureValueErrorFileTypeID is TL type id of SecureValueErrorFile.
const SecureValueErrorFilesTypeID = 0x666220e9
SecureValueErrorFilesTypeID is TL type id of SecureValueErrorFiles.
const SecureValueErrorFrontSideTypeID = 0xbe3dfa
SecureValueErrorFrontSideTypeID is TL type id of SecureValueErrorFrontSide.
const SecureValueErrorReverseSideTypeID = 0x868a2aa5
SecureValueErrorReverseSideTypeID is TL type id of SecureValueErrorReverseSide.
const SecureValueErrorSelfieTypeID = 0xe537ced6
SecureValueErrorSelfieTypeID is TL type id of SecureValueErrorSelfie.
const SecureValueErrorTranslationFileTypeID = 0xa1144770
SecureValueErrorTranslationFileTypeID is TL type id of SecureValueErrorTranslationFile.
const SecureValueErrorTranslationFilesTypeID = 0x34636dd8
SecureValueErrorTranslationFilesTypeID is TL type id of SecureValueErrorTranslationFiles.
const SecureValueErrorTypeID = 0x869d758f
SecureValueErrorTypeID is TL type id of SecureValueError.
const SecureValueHashTypeID = 0xed1ecdb0
SecureValueHashTypeID is TL type id of SecureValueHash.
const SecureValueTypeAddressTypeID = 0xcbe31e26
SecureValueTypeAddressTypeID is TL type id of SecureValueTypeAddress.
const SecureValueTypeBankStatementTypeID = 0x89137c0d
SecureValueTypeBankStatementTypeID is TL type id of SecureValueTypeBankStatement.
const SecureValueTypeDriverLicenseTypeID = 0x6e425c4
SecureValueTypeDriverLicenseTypeID is TL type id of SecureValueTypeDriverLicense.
const SecureValueTypeEmailTypeID = 0x8e3ca7ee
SecureValueTypeEmailTypeID is TL type id of SecureValueTypeEmail.
const SecureValueTypeID = 0x187fa0ca
SecureValueTypeID is TL type id of SecureValue.
const SecureValueTypeIdentityCardTypeID = 0xa0d0744b
SecureValueTypeIdentityCardTypeID is TL type id of SecureValueTypeIdentityCard.
const SecureValueTypeInternalPassportTypeID = 0x99a48f23
SecureValueTypeInternalPassportTypeID is TL type id of SecureValueTypeInternalPassport.
const SecureValueTypePassportRegistrationTypeID = 0x99e3806a
SecureValueTypePassportRegistrationTypeID is TL type id of SecureValueTypePassportRegistration.
const SecureValueTypePassportTypeID = 0x3dac6a00
SecureValueTypePassportTypeID is TL type id of SecureValueTypePassport.
const SecureValueTypePersonalDetailsTypeID = 0x9d2a81e3
SecureValueTypePersonalDetailsTypeID is TL type id of SecureValueTypePersonalDetails.
const SecureValueTypePhoneTypeID = 0xb320aadb
SecureValueTypePhoneTypeID is TL type id of SecureValueTypePhone.
const SecureValueTypeRentalAgreementTypeID = 0x8b883488
SecureValueTypeRentalAgreementTypeID is TL type id of SecureValueTypeRentalAgreement.
const SecureValueTypeTemporaryRegistrationTypeID = 0xea02ec33
SecureValueTypeTemporaryRegistrationTypeID is TL type id of SecureValueTypeTemporaryRegistration.
const SecureValueTypeUtilityBillTypeID = 0xfc36954e
SecureValueTypeUtilityBillTypeID is TL type id of SecureValueTypeUtilityBill.
const SendMessageCancelActionTypeID = 0xfd5ec8f5
SendMessageCancelActionTypeID is TL type id of SendMessageCancelAction.
const SendMessageChooseContactActionTypeID = 0x628cbc6f
SendMessageChooseContactActionTypeID is TL type id of SendMessageChooseContactAction.
const SendMessageGamePlayActionTypeID = 0xdd6a8f48
SendMessageGamePlayActionTypeID is TL type id of SendMessageGamePlayAction.
const SendMessageGeoLocationActionTypeID = 0x176f8ba1
SendMessageGeoLocationActionTypeID is TL type id of SendMessageGeoLocationAction.
const SendMessageRecordAudioActionTypeID = 0xd52f73f7
SendMessageRecordAudioActionTypeID is TL type id of SendMessageRecordAudioAction.
const SendMessageRecordRoundActionTypeID = 0x88f27fbc
SendMessageRecordRoundActionTypeID is TL type id of SendMessageRecordRoundAction.
const SendMessageRecordVideoActionTypeID = 0xa187d66f
SendMessageRecordVideoActionTypeID is TL type id of SendMessageRecordVideoAction.
const SendMessageTypingActionTypeID = 0x16bf744e
SendMessageTypingActionTypeID is TL type id of SendMessageTypingAction.
const SendMessageUploadAudioActionTypeID = 0xf351d7ab
SendMessageUploadAudioActionTypeID is TL type id of SendMessageUploadAudioAction.
const SendMessageUploadDocumentActionTypeID = 0xaa0cd9e4
SendMessageUploadDocumentActionTypeID is TL type id of SendMessageUploadDocumentAction.
const SendMessageUploadPhotoActionTypeID = 0xd1d34a26
SendMessageUploadPhotoActionTypeID is TL type id of SendMessageUploadPhotoAction.
const SendMessageUploadRoundActionTypeID = 0x243e1c66
SendMessageUploadRoundActionTypeID is TL type id of SendMessageUploadRoundAction.
const SendMessageUploadVideoActionTypeID = 0xe9763aec
SendMessageUploadVideoActionTypeID is TL type id of SendMessageUploadVideoAction.
const ShippingOptionTypeID = 0xb6213cdf
ShippingOptionTypeID is TL type id of ShippingOption.
const SpeakingInGroupCallActionTypeID = 0xd92c2285
SpeakingInGroupCallActionTypeID is TL type id of SpeakingInGroupCallAction.
const StatsAbsValueAndPrevTypeID = 0xcb43acde
StatsAbsValueAndPrevTypeID is TL type id of StatsAbsValueAndPrev.
const StatsBroadcastStatsTypeID = 0xbdf78394
StatsBroadcastStatsTypeID is TL type id of StatsBroadcastStats.
const StatsDateRangeDaysTypeID = 0xb637edaf
StatsDateRangeDaysTypeID is TL type id of StatsDateRangeDays.
const StatsGetBroadcastStatsRequestTypeID = 0xab42441a
StatsGetBroadcastStatsRequestTypeID is TL type id of StatsGetBroadcastStatsRequest.
const StatsGetMegagroupStatsRequestTypeID = 0xdcdf8607
StatsGetMegagroupStatsRequestTypeID is TL type id of StatsGetMegagroupStatsRequest.
const StatsGetMessagePublicForwardsRequestTypeID = 0x5630281b
StatsGetMessagePublicForwardsRequestTypeID is TL type id of StatsGetMessagePublicForwardsRequest.
const StatsGetMessageStatsRequestTypeID = 0xb6e0a3f5
StatsGetMessageStatsRequestTypeID is TL type id of StatsGetMessageStatsRequest.
const StatsGraphAsyncTypeID = 0x4a27eb2d
StatsGraphAsyncTypeID is TL type id of StatsGraphAsync.
const StatsGraphErrorTypeID = 0xbedc9822
StatsGraphErrorTypeID is TL type id of StatsGraphError.
const StatsGraphTypeID = 0x8ea464b6
StatsGraphTypeID is TL type id of StatsGraph.
const StatsGroupTopAdminTypeID = 0x6014f412
StatsGroupTopAdminTypeID is TL type id of StatsGroupTopAdmin.
const StatsGroupTopInviterTypeID = 0x31962a4c
StatsGroupTopInviterTypeID is TL type id of StatsGroupTopInviter.
const StatsGroupTopPosterTypeID = 0x18f3d0f7
StatsGroupTopPosterTypeID is TL type id of StatsGroupTopPoster.
const StatsLoadAsyncGraphRequestTypeID = 0x621d5fa0
StatsLoadAsyncGraphRequestTypeID is TL type id of StatsLoadAsyncGraphRequest.
const StatsMegagroupStatsTypeID = 0xef7ff916
StatsMegagroupStatsTypeID is TL type id of StatsMegagroupStats.
const StatsMessageStatsTypeID = 0x8999f295
StatsMessageStatsTypeID is TL type id of StatsMessageStats.
const StatsPercentValueTypeID = 0xcbce2fe0
StatsPercentValueTypeID is TL type id of StatsPercentValue.
const StatsURLTypeID = 0x47a971e0
StatsURLTypeID is TL type id of StatsURL.
const StickerPackTypeID = 0x12b299d4
StickerPackTypeID is TL type id of StickerPack.
const StickerSetCoveredTypeID = 0x6410a5d2
StickerSetCoveredTypeID is TL type id of StickerSetCovered.
const StickerSetMultiCoveredTypeID = 0x3407e51b
StickerSetMultiCoveredTypeID is TL type id of StickerSetMultiCovered.
const StickerSetTypeID = 0x40e237a8
StickerSetTypeID is TL type id of StickerSet.
const StickersAddStickerToSetRequestTypeID = 0x8653febe
StickersAddStickerToSetRequestTypeID is TL type id of StickersAddStickerToSetRequest.
const StickersChangeStickerPositionRequestTypeID = 0xffb6d4ca
StickersChangeStickerPositionRequestTypeID is TL type id of StickersChangeStickerPositionRequest.
const StickersCreateStickerSetRequestTypeID = 0xf1036780
StickersCreateStickerSetRequestTypeID is TL type id of StickersCreateStickerSetRequest.
const StickersRemoveStickerFromSetRequestTypeID = 0xf7760f51
StickersRemoveStickerFromSetRequestTypeID is TL type id of StickersRemoveStickerFromSetRequest.
const StickersSetStickerSetThumbRequestTypeID = 0x9a364e30
StickersSetStickerSetThumbRequestTypeID is TL type id of StickersSetStickerSetThumbRequest.
const StorageFileGifTypeID = 0xcae1aadf
StorageFileGifTypeID is TL type id of StorageFileGif.
const StorageFileJpegTypeID = 0x7efe0e
StorageFileJpegTypeID is TL type id of StorageFileJpeg.
const StorageFileMovTypeID = 0x4b09ebbc
StorageFileMovTypeID is TL type id of StorageFileMov.
const StorageFileMp3TypeID = 0x528a0677
StorageFileMp3TypeID is TL type id of StorageFileMp3.
const StorageFileMp4TypeID = 0xb3cea0e4
StorageFileMp4TypeID is TL type id of StorageFileMp4.
const StorageFilePartialTypeID = 0x40bc6f52
StorageFilePartialTypeID is TL type id of StorageFilePartial.
const StorageFilePdfTypeID = 0xae1e508d
StorageFilePdfTypeID is TL type id of StorageFilePdf.
const StorageFilePngTypeID = 0xa4f63c0
StorageFilePngTypeID is TL type id of StorageFilePng.
const StorageFileUnknownTypeID = 0xaa963b05
StorageFileUnknownTypeID is TL type id of StorageFileUnknown.
const StorageFileWebpTypeID = 0x1081464c
StorageFileWebpTypeID is TL type id of StorageFileWebp.
const TextAnchorTypeID = 0x35553762
TextAnchorTypeID is TL type id of TextAnchor.
const TextBoldTypeID = 0x6724abc4
TextBoldTypeID is TL type id of TextBold.
const TextConcatTypeID = 0x7e6260d7
TextConcatTypeID is TL type id of TextConcat.
const TextEmailTypeID = 0xde5a0dd6
TextEmailTypeID is TL type id of TextEmail.
const TextEmptyTypeID = 0xdc3d824f
TextEmptyTypeID is TL type id of TextEmpty.
const TextFixedTypeID = 0x6c3f19b9
TextFixedTypeID is TL type id of TextFixed.
const TextImageTypeID = 0x81ccf4f
TextImageTypeID is TL type id of TextImage.
const TextItalicTypeID = 0xd912a59c
TextItalicTypeID is TL type id of TextItalic.
const TextMarkedTypeID = 0x34b8621
TextMarkedTypeID is TL type id of TextMarked.
const TextPhoneTypeID = 0x1ccb966a
TextPhoneTypeID is TL type id of TextPhone.
const TextPlainTypeID = 0x744694e0
TextPlainTypeID is TL type id of TextPlain.
const TextStrikeTypeID = 0x9bf8bb95
TextStrikeTypeID is TL type id of TextStrike.
const TextSubscriptTypeID = 0xed6a8504
TextSubscriptTypeID is TL type id of TextSubscript.
const TextSuperscriptTypeID = 0xc7fb5e01
TextSuperscriptTypeID is TL type id of TextSuperscript.
const TextUnderlineTypeID = 0xc12622c4
TextUnderlineTypeID is TL type id of TextUnderline.
const TextUrlTypeID = 0x3c2884c1
TextUrlTypeID is TL type id of TextUrl.
const ThemeSettingsTypeID = 0x9c14984a
ThemeSettingsTypeID is TL type id of ThemeSettings.
const ThemeTypeID = 0x28f1114
ThemeTypeID is TL type id of Theme.
const TopPeerCategoryBotsInlineTypeID = 0x148677e2
TopPeerCategoryBotsInlineTypeID is TL type id of TopPeerCategoryBotsInline.
const TopPeerCategoryBotsPMTypeID = 0xab661b5b
TopPeerCategoryBotsPMTypeID is TL type id of TopPeerCategoryBotsPM.
const TopPeerCategoryChannelsTypeID = 0x161d9628
TopPeerCategoryChannelsTypeID is TL type id of TopPeerCategoryChannels.
const TopPeerCategoryCorrespondentsTypeID = 0x637b7ed
TopPeerCategoryCorrespondentsTypeID is TL type id of TopPeerCategoryCorrespondents.
const TopPeerCategoryForwardChatsTypeID = 0xfbeec0f0
TopPeerCategoryForwardChatsTypeID is TL type id of TopPeerCategoryForwardChats.
const TopPeerCategoryForwardUsersTypeID = 0xa8406ca9
TopPeerCategoryForwardUsersTypeID is TL type id of TopPeerCategoryForwardUsers.
const TopPeerCategoryGroupsTypeID = 0xbd17a14a
TopPeerCategoryGroupsTypeID is TL type id of TopPeerCategoryGroups.
const TopPeerCategoryPeersTypeID = 0xfb834291
TopPeerCategoryPeersTypeID is TL type id of TopPeerCategoryPeers.
const TopPeerCategoryPhoneCallsTypeID = 0x1e76a78c
TopPeerCategoryPhoneCallsTypeID is TL type id of TopPeerCategoryPhoneCalls.
const TopPeerTypeID = 0xedcdc05b
TopPeerTypeID is TL type id of TopPeer.
const TrueTypeID = 0x3fedd339
TrueTypeID is TL type id of True.
const UpdateBotCallbackQueryTypeID = 0xe73547e1
UpdateBotCallbackQueryTypeID is TL type id of UpdateBotCallbackQuery.
const UpdateBotInlineQueryTypeID = 0x3f2038db
UpdateBotInlineQueryTypeID is TL type id of UpdateBotInlineQuery.
const UpdateBotInlineSendTypeID = 0xe48f964
UpdateBotInlineSendTypeID is TL type id of UpdateBotInlineSend.
const UpdateBotPrecheckoutQueryTypeID = 0x5d2f3aa9
UpdateBotPrecheckoutQueryTypeID is TL type id of UpdateBotPrecheckoutQuery.
const UpdateBotShippingQueryTypeID = 0xe0cdc940
UpdateBotShippingQueryTypeID is TL type id of UpdateBotShippingQuery.
const UpdateBotWebhookJSONQueryTypeID = 0x9b9240a6
UpdateBotWebhookJSONQueryTypeID is TL type id of UpdateBotWebhookJSONQuery.
const UpdateBotWebhookJSONTypeID = 0x8317c0c3
UpdateBotWebhookJSONTypeID is TL type id of UpdateBotWebhookJSON.
const UpdateChannelAvailableMessagesTypeID = 0x70db6837
UpdateChannelAvailableMessagesTypeID is TL type id of UpdateChannelAvailableMessages.
const UpdateChannelMessageForwardsTypeID = 0x6e8a84df
UpdateChannelMessageForwardsTypeID is TL type id of UpdateChannelMessageForwards.
const UpdateChannelMessageViewsTypeID = 0x98a12b4b
UpdateChannelMessageViewsTypeID is TL type id of UpdateChannelMessageViews.
const UpdateChannelParticipantTypeID = 0x65d2b464
UpdateChannelParticipantTypeID is TL type id of UpdateChannelParticipant.
const UpdateChannelReadMessagesContentsTypeID = 0x89893b45
UpdateChannelReadMessagesContentsTypeID is TL type id of UpdateChannelReadMessagesContents.
const UpdateChannelTooLongTypeID = 0xeb0467fb
UpdateChannelTooLongTypeID is TL type id of UpdateChannelTooLong.
const UpdateChannelTypeID = 0xb6d45656
UpdateChannelTypeID is TL type id of UpdateChannel.
const UpdateChannelUserTypingTypeID = 0xff2abe9f
UpdateChannelUserTypingTypeID is TL type id of UpdateChannelUserTyping.
const UpdateChannelWebPageTypeID = 0x40771900
UpdateChannelWebPageTypeID is TL type id of UpdateChannelWebPage.
const UpdateChatDefaultBannedRightsTypeID = 0x54c01850
UpdateChatDefaultBannedRightsTypeID is TL type id of UpdateChatDefaultBannedRights.
const UpdateChatParticipantAddTypeID = 0xea4b0e5c
UpdateChatParticipantAddTypeID is TL type id of UpdateChatParticipantAdd.
const UpdateChatParticipantAdminTypeID = 0xb6901959
UpdateChatParticipantAdminTypeID is TL type id of UpdateChatParticipantAdmin.
const UpdateChatParticipantDeleteTypeID = 0x6e5f8c22
UpdateChatParticipantDeleteTypeID is TL type id of UpdateChatParticipantDelete.
const UpdateChatParticipantsTypeID = 0x7761198
UpdateChatParticipantsTypeID is TL type id of UpdateChatParticipants.
const UpdateChatTypeID = 0x1330a196
UpdateChatTypeID is TL type id of UpdateChat.
const UpdateChatUserTypingTypeID = 0x9a65ea1f
UpdateChatUserTypingTypeID is TL type id of UpdateChatUserTyping.
const UpdateConfigTypeID = 0xa229dd06
UpdateConfigTypeID is TL type id of UpdateConfig.
const UpdateContactsResetTypeID = 0x7084a7be
UpdateContactsResetTypeID is TL type id of UpdateContactsReset.
const UpdateDcOptionsTypeID = 0x8e5e9873
UpdateDcOptionsTypeID is TL type id of UpdateDcOptions.
const UpdateDeleteChannelMessagesTypeID = 0xc37521c9
UpdateDeleteChannelMessagesTypeID is TL type id of UpdateDeleteChannelMessages.
const UpdateDeleteMessagesTypeID = 0xa20db0e5
UpdateDeleteMessagesTypeID is TL type id of UpdateDeleteMessages.
const UpdateDeleteScheduledMessagesTypeID = 0x90866cee
UpdateDeleteScheduledMessagesTypeID is TL type id of UpdateDeleteScheduledMessages.
const UpdateDialogFilterOrderTypeID = 0xa5d72105
UpdateDialogFilterOrderTypeID is TL type id of UpdateDialogFilterOrder.
const UpdateDialogFilterTypeID = 0x26ffde7d
UpdateDialogFilterTypeID is TL type id of UpdateDialogFilter.
const UpdateDialogFiltersTypeID = 0x3504914f
UpdateDialogFiltersTypeID is TL type id of UpdateDialogFilters.
const UpdateDialogPinnedTypeID = 0x6e6fe51c
UpdateDialogPinnedTypeID is TL type id of UpdateDialogPinned.
const UpdateDialogUnreadMarkTypeID = 0xe16459c3
UpdateDialogUnreadMarkTypeID is TL type id of UpdateDialogUnreadMark.
const UpdateDraftMessageTypeID = 0xee2bb969
UpdateDraftMessageTypeID is TL type id of UpdateDraftMessage.
const UpdateEditChannelMessageTypeID = 0x1b3f4df7
UpdateEditChannelMessageTypeID is TL type id of UpdateEditChannelMessage.
const UpdateEditMessageTypeID = 0xe40370a3
UpdateEditMessageTypeID is TL type id of UpdateEditMessage.
const UpdateEncryptedChatTypingTypeID = 0x1710f156
UpdateEncryptedChatTypingTypeID is TL type id of UpdateEncryptedChatTyping.
const UpdateEncryptedMessagesReadTypeID = 0x38fe25b7
UpdateEncryptedMessagesReadTypeID is TL type id of UpdateEncryptedMessagesRead.
const UpdateEncryptionTypeID = 0xb4a2e88d
UpdateEncryptionTypeID is TL type id of UpdateEncryption.
const UpdateFavedStickersTypeID = 0xe511996d
UpdateFavedStickersTypeID is TL type id of UpdateFavedStickers.
const UpdateFolderPeersTypeID = 0x19360dc0
UpdateFolderPeersTypeID is TL type id of UpdateFolderPeers.
const UpdateGeoLiveViewedTypeID = 0x871fb939
UpdateGeoLiveViewedTypeID is TL type id of UpdateGeoLiveViewed.
const UpdateGroupCallParticipantsTypeID = 0xf2ebdb4e
UpdateGroupCallParticipantsTypeID is TL type id of UpdateGroupCallParticipants.
const UpdateGroupCallTypeID = 0xa45eb99b
UpdateGroupCallTypeID is TL type id of UpdateGroupCall.
const UpdateInlineBotCallbackQueryTypeID = 0xf9d27a5a
UpdateInlineBotCallbackQueryTypeID is TL type id of UpdateInlineBotCallbackQuery.
const UpdateLangPackTooLongTypeID = 0x46560264
UpdateLangPackTooLongTypeID is TL type id of UpdateLangPackTooLong.
const UpdateLangPackTypeID = 0x56022f4d
UpdateLangPackTypeID is TL type id of UpdateLangPack.
const UpdateLoginTokenTypeID = 0x564fe691
UpdateLoginTokenTypeID is TL type id of UpdateLoginToken.
const UpdateMessageIDTypeID = 0x4e90bfd6
UpdateMessageIDTypeID is TL type id of UpdateMessageID.
const UpdateMessagePollTypeID = 0xaca1657b
UpdateMessagePollTypeID is TL type id of UpdateMessagePoll.
const UpdateMessagePollVoteTypeID = 0x42f88f2c
UpdateMessagePollVoteTypeID is TL type id of UpdateMessagePollVote.
const UpdateNewChannelMessageTypeID = 0x62ba04d9
UpdateNewChannelMessageTypeID is TL type id of UpdateNewChannelMessage.
const UpdateNewEncryptedMessageTypeID = 0x12bcbd9a
UpdateNewEncryptedMessageTypeID is TL type id of UpdateNewEncryptedMessage.
const UpdateNewMessageTypeID = 0x1f2b0afd
UpdateNewMessageTypeID is TL type id of UpdateNewMessage.
const UpdateNewScheduledMessageTypeID = 0x39a51dfb
UpdateNewScheduledMessageTypeID is TL type id of UpdateNewScheduledMessage.
const UpdateNewStickerSetTypeID = 0x688a30aa
UpdateNewStickerSetTypeID is TL type id of UpdateNewStickerSet.
const UpdateNotifySettingsTypeID = 0xbec268ef
UpdateNotifySettingsTypeID is TL type id of UpdateNotifySettings.
const UpdatePeerBlockedTypeID = 0x246a4b22
UpdatePeerBlockedTypeID is TL type id of UpdatePeerBlocked.
const UpdatePeerLocatedTypeID = 0xb4afcfb0
UpdatePeerLocatedTypeID is TL type id of UpdatePeerLocated.
const UpdatePeerSettingsTypeID = 0x6a7e7366
UpdatePeerSettingsTypeID is TL type id of UpdatePeerSettings.
const UpdatePhoneCallSignalingDataTypeID = 0x2661bf09
UpdatePhoneCallSignalingDataTypeID is TL type id of UpdatePhoneCallSignalingData.
const UpdatePhoneCallTypeID = 0xab0f6b1e
UpdatePhoneCallTypeID is TL type id of UpdatePhoneCall.
const UpdatePinnedChannelMessagesTypeID = 0x8588878b
UpdatePinnedChannelMessagesTypeID is TL type id of UpdatePinnedChannelMessages.
const UpdatePinnedDialogsTypeID = 0xfa0f3ca2
UpdatePinnedDialogsTypeID is TL type id of UpdatePinnedDialogs.
const UpdatePinnedMessagesTypeID = 0xed85eab5
UpdatePinnedMessagesTypeID is TL type id of UpdatePinnedMessages.
const UpdatePrivacyTypeID = 0xee3b272a
UpdatePrivacyTypeID is TL type id of UpdatePrivacy.
const UpdatePtsChangedTypeID = 0x3354678f
UpdatePtsChangedTypeID is TL type id of UpdatePtsChanged.
const UpdateReadChannelDiscussionInboxTypeID = 0x1cc7de54
UpdateReadChannelDiscussionInboxTypeID is TL type id of UpdateReadChannelDiscussionInbox.
const UpdateReadChannelDiscussionOutboxTypeID = 0x4638a26c
UpdateReadChannelDiscussionOutboxTypeID is TL type id of UpdateReadChannelDiscussionOutbox.
const UpdateReadChannelInboxTypeID = 0x330b5424
UpdateReadChannelInboxTypeID is TL type id of UpdateReadChannelInbox.
const UpdateReadChannelOutboxTypeID = 0x25d6c9c7
UpdateReadChannelOutboxTypeID is TL type id of UpdateReadChannelOutbox.
const UpdateReadFeaturedStickersTypeID = 0x571d2742
UpdateReadFeaturedStickersTypeID is TL type id of UpdateReadFeaturedStickers.
const UpdateReadHistoryInboxTypeID = 0x9c974fdf
UpdateReadHistoryInboxTypeID is TL type id of UpdateReadHistoryInbox.
const UpdateReadHistoryOutboxTypeID = 0x2f2f21bf
UpdateReadHistoryOutboxTypeID is TL type id of UpdateReadHistoryOutbox.
const UpdateReadMessagesContentsTypeID = 0x68c13933
UpdateReadMessagesContentsTypeID is TL type id of UpdateReadMessagesContents.
const UpdateRecentStickersTypeID = 0x9a422c20
UpdateRecentStickersTypeID is TL type id of UpdateRecentStickers.
const UpdateSavedGifsTypeID = 0x9375341e
UpdateSavedGifsTypeID is TL type id of UpdateSavedGifs.
const UpdateServiceNotificationTypeID = 0xebe46819
UpdateServiceNotificationTypeID is TL type id of UpdateServiceNotification.
const UpdateShortChatMessageTypeID = 0x402d5dbb
UpdateShortChatMessageTypeID is TL type id of UpdateShortChatMessage.
const UpdateShortMessageTypeID = 0x2296d2c8
UpdateShortMessageTypeID is TL type id of UpdateShortMessage.
const UpdateShortSentMessageTypeID = 0x11f1331c
UpdateShortSentMessageTypeID is TL type id of UpdateShortSentMessage.
const UpdateShortTypeID = 0x78d4dec1
UpdateShortTypeID is TL type id of UpdateShort.
const UpdateStickerSetsOrderTypeID = 0xbb2d201
UpdateStickerSetsOrderTypeID is TL type id of UpdateStickerSetsOrder.
const UpdateStickerSetsTypeID = 0x43ae3dec
UpdateStickerSetsTypeID is TL type id of UpdateStickerSets.
const UpdateThemeTypeID = 0x8216fba3
UpdateThemeTypeID is TL type id of UpdateTheme.
const UpdateUserNameTypeID = 0xa7332b73
UpdateUserNameTypeID is TL type id of UpdateUserName.
const UpdateUserPhoneTypeID = 0x12b9417b
UpdateUserPhoneTypeID is TL type id of UpdateUserPhone.
const UpdateUserPhotoTypeID = 0x95313b0c
UpdateUserPhotoTypeID is TL type id of UpdateUserPhoto.
const UpdateUserStatusTypeID = 0x1bfbd823
UpdateUserStatusTypeID is TL type id of UpdateUserStatus.
const UpdateUserTypingTypeID = 0x5c486927
UpdateUserTypingTypeID is TL type id of UpdateUserTyping.
const UpdateWebPageTypeID = 0x7f891213
UpdateWebPageTypeID is TL type id of UpdateWebPage.
const UpdatesChannelDifferenceEmptyTypeID = 0x3e11affb
UpdatesChannelDifferenceEmptyTypeID is TL type id of UpdatesChannelDifferenceEmpty.
const UpdatesChannelDifferenceTooLongTypeID = 0xa4bcc6fe
UpdatesChannelDifferenceTooLongTypeID is TL type id of UpdatesChannelDifferenceTooLong.
const UpdatesChannelDifferenceTypeID = 0x2064674e
UpdatesChannelDifferenceTypeID is TL type id of UpdatesChannelDifference.
const UpdatesCombinedTypeID = 0x725b04c3
UpdatesCombinedTypeID is TL type id of UpdatesCombined.
const UpdatesDifferenceEmptyTypeID = 0x5d75a138
UpdatesDifferenceEmptyTypeID is TL type id of UpdatesDifferenceEmpty.
const UpdatesDifferenceSliceTypeID = 0xa8fb1981
UpdatesDifferenceSliceTypeID is TL type id of UpdatesDifferenceSlice.
const UpdatesDifferenceTooLongTypeID = 0x4afe8f6d
UpdatesDifferenceTooLongTypeID is TL type id of UpdatesDifferenceTooLong.
const UpdatesDifferenceTypeID = 0xf49ca0
UpdatesDifferenceTypeID is TL type id of UpdatesDifference.
const UpdatesGetChannelDifferenceRequestTypeID = 0x3173d78
UpdatesGetChannelDifferenceRequestTypeID is TL type id of UpdatesGetChannelDifferenceRequest.
const UpdatesGetDifferenceRequestTypeID = 0x25939651
UpdatesGetDifferenceRequestTypeID is TL type id of UpdatesGetDifferenceRequest.
const UpdatesGetStateRequestTypeID = 0xedd4882a
UpdatesGetStateRequestTypeID is TL type id of UpdatesGetStateRequest.
const UpdatesStateTypeID = 0xa56c2a3e
UpdatesStateTypeID is TL type id of UpdatesState.
const UpdatesTooLongTypeID = 0xe317af7e
UpdatesTooLongTypeID is TL type id of UpdatesTooLong.
const UpdatesTypeID = 0x74ae4240
UpdatesTypeID is TL type id of Updates.
const UploadCdnFileReuploadNeededTypeID = 0xeea8e46e
UploadCdnFileReuploadNeededTypeID is TL type id of UploadCdnFileReuploadNeeded.
const UploadCdnFileTypeID = 0xa99fca4f
UploadCdnFileTypeID is TL type id of UploadCdnFile.
const UploadFileCdnRedirectTypeID = 0xf18cda44
UploadFileCdnRedirectTypeID is TL type id of UploadFileCdnRedirect.
const UploadFileTypeID = 0x96a18d5
UploadFileTypeID is TL type id of UploadFile.
const UploadGetCdnFileHashesRequestTypeID = 0x4da54231
UploadGetCdnFileHashesRequestTypeID is TL type id of UploadGetCdnFileHashesRequest.
const UploadGetCdnFileRequestTypeID = 0x2000bcc3
UploadGetCdnFileRequestTypeID is TL type id of UploadGetCdnFileRequest.
const UploadGetFileHashesRequestTypeID = 0xc7025931
UploadGetFileHashesRequestTypeID is TL type id of UploadGetFileHashesRequest.
const UploadGetFileRequestTypeID = 0xb15a9afc
UploadGetFileRequestTypeID is TL type id of UploadGetFileRequest.
const UploadGetWebFileRequestTypeID = 0x24e6818d
UploadGetWebFileRequestTypeID is TL type id of UploadGetWebFileRequest.
const UploadReuploadCdnFileRequestTypeID = 0x9b2754a8
UploadReuploadCdnFileRequestTypeID is TL type id of UploadReuploadCdnFileRequest.
const UploadSaveBigFilePartRequestTypeID = 0xde7b673d
UploadSaveBigFilePartRequestTypeID is TL type id of UploadSaveBigFilePartRequest.
const UploadSaveFilePartRequestTypeID = 0xb304a621
UploadSaveFilePartRequestTypeID is TL type id of UploadSaveFilePartRequest.
const UploadWebFileTypeID = 0x21e753bc
UploadWebFileTypeID is TL type id of UploadWebFile.
const UrlAuthResultAcceptedTypeID = 0x8f8c0e4e
UrlAuthResultAcceptedTypeID is TL type id of UrlAuthResultAccepted.
const UrlAuthResultDefaultTypeID = 0xa9d6db1f
UrlAuthResultDefaultTypeID is TL type id of UrlAuthResultDefault.
const UrlAuthResultRequestTypeID = 0x92d33a0e
UrlAuthResultRequestTypeID is TL type id of UrlAuthResultRequest.
const UserEmptyTypeID = 0x200250ba
UserEmptyTypeID is TL type id of UserEmpty.
const UserFullTypeID = 0xedf17c12
UserFullTypeID is TL type id of UserFull.
const UserProfilePhotoEmptyTypeID = 0x4f11bae1
UserProfilePhotoEmptyTypeID is TL type id of UserProfilePhotoEmpty.
const UserProfilePhotoTypeID = 0x69d3ab26
UserProfilePhotoTypeID is TL type id of UserProfilePhoto.
const UserStatusEmptyTypeID = 0x9d05049
UserStatusEmptyTypeID is TL type id of UserStatusEmpty.
const UserStatusLastMonthTypeID = 0x77ebc742
UserStatusLastMonthTypeID is TL type id of UserStatusLastMonth.
const UserStatusLastWeekTypeID = 0x7bf09fc
UserStatusLastWeekTypeID is TL type id of UserStatusLastWeek.
const UserStatusOfflineTypeID = 0x8c703f
UserStatusOfflineTypeID is TL type id of UserStatusOffline.
const UserStatusOnlineTypeID = 0xedb93949
UserStatusOnlineTypeID is TL type id of UserStatusOnline.
const UserStatusRecentlyTypeID = 0xe26f42f1
UserStatusRecentlyTypeID is TL type id of UserStatusRecently.
const UserTypeID = 0x938458c1
UserTypeID is TL type id of User.
const UsersGetFullUserRequestTypeID = 0xca30a5b1
UsersGetFullUserRequestTypeID is TL type id of UsersGetFullUserRequest.
const UsersGetUsersRequestTypeID = 0xd91a548
UsersGetUsersRequestTypeID is TL type id of UsersGetUsersRequest.
const UsersSetSecureValueErrorsRequestTypeID = 0x90c894b5
UsersSetSecureValueErrorsRequestTypeID is TL type id of UsersSetSecureValueErrorsRequest.
const VideoSizeTypeID = 0xe831c556
VideoSizeTypeID is TL type id of VideoSize.
const WallPaperNoFileTypeID = 0x8af40b25
WallPaperNoFileTypeID is TL type id of WallPaperNoFile.
const WallPaperSettingsTypeID = 0x5086cf8
WallPaperSettingsTypeID is TL type id of WallPaperSettings.
const WallPaperTypeID = 0xa437c3ed
WallPaperTypeID is TL type id of WallPaper.
const WebAuthorizationTypeID = 0xcac943f2
WebAuthorizationTypeID is TL type id of WebAuthorization.
const WebDocumentNoProxyTypeID = 0xf9c8bcc6
WebDocumentNoProxyTypeID is TL type id of WebDocumentNoProxy.
const WebDocumentTypeID = 0x1c570ed1
WebDocumentTypeID is TL type id of WebDocument.
const WebPageAttributeThemeTypeID = 0x54b56617
WebPageAttributeThemeTypeID is TL type id of WebPageAttributeTheme.
const WebPageEmptyTypeID = 0xeb1477e8
WebPageEmptyTypeID is TL type id of WebPageEmpty.
const WebPageNotModifiedTypeID = 0x7311ca11
WebPageNotModifiedTypeID is TL type id of WebPageNotModified.
const WebPagePendingTypeID = 0xc586da1c
WebPagePendingTypeID is TL type id of WebPagePending.
const WebPageTypeID = 0xe89c45b2
WebPageTypeID is TL type id of WebPage.
Variables ¶
This section is empty.
Functions ¶
func TypesConstructorMap ¶ added in v0.15.0
TypesConstructorMap maps type ids to constructors.
Types ¶
type AccountAcceptAuthorizationRequest ¶
type AccountAcceptAuthorizationRequest struct {
// Bot ID
BotID int
// Telegram Passport element types requested by the service
Scope string
// Service's public key
PublicKey string
// Types of values sent and their hashes
ValueHashes []SecureValueHash
// Encrypted values
Credentials SecureCredentialsEncrypted
}
AccountAcceptAuthorizationRequest represents TL type `account.acceptAuthorization#e7027c94`. Sends a Telegram Passport authorization form, effectively sharing data with the service
See https://core.telegram.org/method/account.acceptAuthorization for reference.
func (*AccountAcceptAuthorizationRequest) Decode ¶
func (a *AccountAcceptAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountAcceptAuthorizationRequest) Encode ¶
func (a *AccountAcceptAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountAcceptAuthorizationRequest) String ¶ added in v0.12.0
func (a *AccountAcceptAuthorizationRequest) String() string
String implements fmt.Stringer.
type AccountAuthorizationForm ¶
type AccountAuthorizationForm struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Required Telegram Passport¹ documents
//
// Links:
// 1) https://core.telegram.org/passport
RequiredTypes []SecureRequiredTypeClass
// Already submitted Telegram Passport¹ documents
//
// Links:
// 1) https://core.telegram.org/passport
Values []SecureValue
// Telegram Passport¹ errors
//
// Links:
// 1) https://core.telegram.org/passport
Errors []SecureValueErrorClass
// Info about the bot to which the form will be submitted
Users []UserClass
// URL of the service's privacy policy
//
// Use SetPrivacyPolicyURL and GetPrivacyPolicyURL helpers.
PrivacyPolicyURL string
}
AccountAuthorizationForm represents TL type `account.authorizationForm#ad2e1cd8`. Telegram Passport¹ authorization form
Links:
See https://core.telegram.org/constructor/account.authorizationForm for reference.
func (*AccountAuthorizationForm) Decode ¶
func (a *AccountAuthorizationForm) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountAuthorizationForm) Encode ¶
func (a *AccountAuthorizationForm) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountAuthorizationForm) GetPrivacyPolicyURL ¶
func (a *AccountAuthorizationForm) GetPrivacyPolicyURL() (value string, ok bool)
GetPrivacyPolicyURL returns value of PrivacyPolicyURL conditional field and boolean which is true if field was set.
func (*AccountAuthorizationForm) SetPrivacyPolicyURL ¶
func (a *AccountAuthorizationForm) SetPrivacyPolicyURL(value string)
SetPrivacyPolicyURL sets value of PrivacyPolicyURL conditional field.
func (*AccountAuthorizationForm) String ¶ added in v0.12.0
func (a *AccountAuthorizationForm) String() string
String implements fmt.Stringer.
type AccountAuthorizations ¶
type AccountAuthorizations struct {
// Logged-in sessions
Authorizations []Authorization
}
AccountAuthorizations represents TL type `account.authorizations#1250abde`. Logged-in sessions
See https://core.telegram.org/constructor/account.authorizations for reference.
func (*AccountAuthorizations) Decode ¶
func (a *AccountAuthorizations) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountAuthorizations) Encode ¶
func (a *AccountAuthorizations) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountAuthorizations) String ¶ added in v0.12.0
func (a *AccountAuthorizations) String() string
String implements fmt.Stringer.
type AccountAutoDownloadSettings ¶
type AccountAutoDownloadSettings struct {
// Low data usage preset
Low AutoDownloadSettings
// Medium data usage preset
Medium AutoDownloadSettings
// High data usage preset
High AutoDownloadSettings
}
AccountAutoDownloadSettings represents TL type `account.autoDownloadSettings#63cacf26`. Media autodownload settings
See https://core.telegram.org/constructor/account.autoDownloadSettings for reference.
func (*AccountAutoDownloadSettings) Decode ¶
func (a *AccountAutoDownloadSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountAutoDownloadSettings) Encode ¶
func (a *AccountAutoDownloadSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountAutoDownloadSettings) String ¶ added in v0.12.0
func (a *AccountAutoDownloadSettings) String() string
String implements fmt.Stringer.
type AccountCancelPasswordEmailRequest ¶
type AccountCancelPasswordEmailRequest struct {
}
AccountCancelPasswordEmailRequest represents TL type `account.cancelPasswordEmail#c1cbd5b6`. Cancel the code that was sent to verify an email to use as 2FA recovery method¹.
Links:
See https://core.telegram.org/method/account.cancelPasswordEmail for reference.
func (*AccountCancelPasswordEmailRequest) Decode ¶
func (c *AccountCancelPasswordEmailRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountCancelPasswordEmailRequest) Encode ¶
func (c *AccountCancelPasswordEmailRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountCancelPasswordEmailRequest) String ¶ added in v0.12.0
func (c *AccountCancelPasswordEmailRequest) String() string
String implements fmt.Stringer.
type AccountChangePhoneRequest ¶
type AccountChangePhoneRequest struct {
// New phone number
PhoneNumber string
// Phone code hash received when calling account.sendChangePhoneCode¹
//
// Links:
// 1) https://core.telegram.org/method/account.sendChangePhoneCode
PhoneCodeHash string
// Phone code received when calling account.sendChangePhoneCode¹
//
// Links:
// 1) https://core.telegram.org/method/account.sendChangePhoneCode
PhoneCode string
}
AccountChangePhoneRequest represents TL type `account.changePhone#70c32edb`. Change the phone number of the current account
See https://core.telegram.org/method/account.changePhone for reference.
func (*AccountChangePhoneRequest) Decode ¶
func (c *AccountChangePhoneRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountChangePhoneRequest) Encode ¶
func (c *AccountChangePhoneRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountChangePhoneRequest) String ¶ added in v0.12.0
func (c *AccountChangePhoneRequest) String() string
String implements fmt.Stringer.
type AccountCheckUsernameRequest ¶
type AccountCheckUsernameRequest struct {
// usernameAccepted characters: A-z (case-insensitive), 0-9 and underscores.Length: 5-32 characters.
Username string
}
AccountCheckUsernameRequest represents TL type `account.checkUsername#2714d86c`. Validates a username and checks availability.
See https://core.telegram.org/method/account.checkUsername for reference.
func (*AccountCheckUsernameRequest) Decode ¶
func (c *AccountCheckUsernameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountCheckUsernameRequest) Encode ¶
func (c *AccountCheckUsernameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountCheckUsernameRequest) String ¶ added in v0.12.0
func (c *AccountCheckUsernameRequest) String() string
String implements fmt.Stringer.
type AccountConfirmPasswordEmailRequest ¶
type AccountConfirmPasswordEmailRequest struct {
// The phone code that was received after setting a recovery email¹
//
// Links:
// 1) https://core.telegram.org/api/srp#email-verification
Code string
}
AccountConfirmPasswordEmailRequest represents TL type `account.confirmPasswordEmail#8fdf1920`. Verify an email to use as 2FA recovery method¹.
Links:
See https://core.telegram.org/method/account.confirmPasswordEmail for reference.
func (*AccountConfirmPasswordEmailRequest) Decode ¶
func (c *AccountConfirmPasswordEmailRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountConfirmPasswordEmailRequest) Encode ¶
func (c *AccountConfirmPasswordEmailRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountConfirmPasswordEmailRequest) String ¶ added in v0.12.0
func (c *AccountConfirmPasswordEmailRequest) String() string
String implements fmt.Stringer.
type AccountConfirmPhoneRequest ¶
type AccountConfirmPhoneRequest struct {
// Phone code hash, for more info click here »¹
//
// Links:
// 1) https://core.telegram.org/api/account-deletion
PhoneCodeHash string
// SMS code, for more info click here »¹
//
// Links:
// 1) https://core.telegram.org/api/account-deletion
PhoneCode string
}
AccountConfirmPhoneRequest represents TL type `account.confirmPhone#5f2178c3`. Confirm a phone number to cancel account deletion, for more info click here »¹
Links:
See https://core.telegram.org/method/account.confirmPhone for reference.
func (*AccountConfirmPhoneRequest) Decode ¶
func (c *AccountConfirmPhoneRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountConfirmPhoneRequest) Encode ¶
func (c *AccountConfirmPhoneRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountConfirmPhoneRequest) String ¶ added in v0.12.0
func (c *AccountConfirmPhoneRequest) String() string
String implements fmt.Stringer.
type AccountContentSettings ¶
type AccountContentSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether viewing of sensitive (NSFW) content is enabled
SensitiveEnabled bool
// Whether the current client can change the sensitive content settings to view NSFW content
SensitiveCanChange bool
}
AccountContentSettings represents TL type `account.contentSettings#57e28221`. Sensitive content settings
See https://core.telegram.org/constructor/account.contentSettings for reference.
func (*AccountContentSettings) Decode ¶
func (c *AccountContentSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountContentSettings) Encode ¶
func (c *AccountContentSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountContentSettings) SetSensitiveCanChange ¶
func (c *AccountContentSettings) SetSensitiveCanChange(value bool)
SetSensitiveCanChange sets value of SensitiveCanChange conditional field.
func (*AccountContentSettings) SetSensitiveEnabled ¶
func (c *AccountContentSettings) SetSensitiveEnabled(value bool)
SetSensitiveEnabled sets value of SensitiveEnabled conditional field.
func (*AccountContentSettings) String ¶ added in v0.12.0
func (c *AccountContentSettings) String() string
String implements fmt.Stringer.
type AccountCreateThemeRequest ¶
type AccountCreateThemeRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Unique theme ID
Slug string
// Theme name
Title string
// Theme file
//
// Use SetDocument and GetDocument helpers.
Document InputDocumentClass
// Theme settings
//
// Use SetSettings and GetSettings helpers.
Settings InputThemeSettings
}
AccountCreateThemeRequest represents TL type `account.createTheme#8432c21f`. Create a theme
See https://core.telegram.org/method/account.createTheme for reference.
func (*AccountCreateThemeRequest) Decode ¶
func (c *AccountCreateThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountCreateThemeRequest) Encode ¶
func (c *AccountCreateThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountCreateThemeRequest) GetDocument ¶
func (c *AccountCreateThemeRequest) GetDocument() (value InputDocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*AccountCreateThemeRequest) GetSettings ¶
func (c *AccountCreateThemeRequest) GetSettings() (value InputThemeSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*AccountCreateThemeRequest) SetDocument ¶
func (c *AccountCreateThemeRequest) SetDocument(value InputDocumentClass)
SetDocument sets value of Document conditional field.
func (*AccountCreateThemeRequest) SetSettings ¶
func (c *AccountCreateThemeRequest) SetSettings(value InputThemeSettings)
SetSettings sets value of Settings conditional field.
func (*AccountCreateThemeRequest) String ¶ added in v0.12.0
func (c *AccountCreateThemeRequest) String() string
String implements fmt.Stringer.
type AccountDaysTTL ¶
type AccountDaysTTL struct {
// This account will self-destruct in the specified number of days
Days int
}
AccountDaysTTL represents TL type `accountDaysTTL#b8d0afdf`. Time to live in days of the current account
See https://core.telegram.org/constructor/accountDaysTTL for reference.
func (*AccountDaysTTL) Decode ¶
func (a *AccountDaysTTL) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountDaysTTL) Encode ¶
func (a *AccountDaysTTL) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountDaysTTL) String ¶ added in v0.12.0
func (a *AccountDaysTTL) String() string
String implements fmt.Stringer.
type AccountDeleteAccountRequest ¶
type AccountDeleteAccountRequest struct {
// Why is the account being deleted, can be empty
Reason string
}
AccountDeleteAccountRequest represents TL type `account.deleteAccount#418d4e0b`. Delete the user's account from the telegram servers. Can be used, for example, to delete the account of a user that provided the login code, but forgot the 2FA password and no recovery method is configured¹.
Links:
See https://core.telegram.org/method/account.deleteAccount for reference.
func (*AccountDeleteAccountRequest) Decode ¶
func (d *AccountDeleteAccountRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountDeleteAccountRequest) Encode ¶
func (d *AccountDeleteAccountRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountDeleteAccountRequest) String ¶ added in v0.12.0
func (d *AccountDeleteAccountRequest) String() string
String implements fmt.Stringer.
type AccountDeleteSecureValueRequest ¶
type AccountDeleteSecureValueRequest struct {
// Document types to delete
Types []SecureValueTypeClass
}
AccountDeleteSecureValueRequest represents TL type `account.deleteSecureValue#b880bc4b`. Delete stored Telegram Passport¹ documents, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.deleteSecureValue for reference.
func (*AccountDeleteSecureValueRequest) Decode ¶
func (d *AccountDeleteSecureValueRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountDeleteSecureValueRequest) Encode ¶
func (d *AccountDeleteSecureValueRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountDeleteSecureValueRequest) String ¶ added in v0.12.0
func (d *AccountDeleteSecureValueRequest) String() string
String implements fmt.Stringer.
type AccountFinishTakeoutSessionRequest ¶
type AccountFinishTakeoutSessionRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Data exported successfully
Success bool
}
AccountFinishTakeoutSessionRequest represents TL type `account.finishTakeoutSession#1d2652ee`. Finish account takeout session
See https://core.telegram.org/method/account.finishTakeoutSession for reference.
func (*AccountFinishTakeoutSessionRequest) Decode ¶
func (f *AccountFinishTakeoutSessionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountFinishTakeoutSessionRequest) Encode ¶
func (f *AccountFinishTakeoutSessionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountFinishTakeoutSessionRequest) SetSuccess ¶
func (f *AccountFinishTakeoutSessionRequest) SetSuccess(value bool)
SetSuccess sets value of Success conditional field.
func (*AccountFinishTakeoutSessionRequest) String ¶ added in v0.12.0
func (f *AccountFinishTakeoutSessionRequest) String() string
String implements fmt.Stringer.
type AccountGetAccountTTLRequest ¶
type AccountGetAccountTTLRequest struct {
}
AccountGetAccountTTLRequest represents TL type `account.getAccountTTL#8fc711d`. Get days to live of account
See https://core.telegram.org/method/account.getAccountTTL for reference.
func (*AccountGetAccountTTLRequest) Decode ¶
func (g *AccountGetAccountTTLRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetAccountTTLRequest) Encode ¶
func (g *AccountGetAccountTTLRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetAccountTTLRequest) String ¶ added in v0.12.0
func (g *AccountGetAccountTTLRequest) String() string
String implements fmt.Stringer.
type AccountGetAllSecureValuesRequest ¶
type AccountGetAllSecureValuesRequest struct {
}
AccountGetAllSecureValuesRequest represents TL type `account.getAllSecureValues#b288bc7d`. Get all saved Telegram Passport¹ documents, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.getAllSecureValues for reference.
func (*AccountGetAllSecureValuesRequest) Decode ¶
func (g *AccountGetAllSecureValuesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetAllSecureValuesRequest) Encode ¶
func (g *AccountGetAllSecureValuesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetAllSecureValuesRequest) String ¶ added in v0.12.0
func (g *AccountGetAllSecureValuesRequest) String() string
String implements fmt.Stringer.
type AccountGetAuthorizationFormRequest ¶
type AccountGetAuthorizationFormRequest struct {
// User identifier of the service's bot
BotID int
// Telegram Passport element types requested by the service
Scope string
// Service's public key
PublicKey string
}
AccountGetAuthorizationFormRequest represents TL type `account.getAuthorizationForm#b86ba8e1`. Returns a Telegram Passport authorization form for sharing data with a service
See https://core.telegram.org/method/account.getAuthorizationForm for reference.
func (*AccountGetAuthorizationFormRequest) Decode ¶
func (g *AccountGetAuthorizationFormRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetAuthorizationFormRequest) Encode ¶
func (g *AccountGetAuthorizationFormRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetAuthorizationFormRequest) String ¶ added in v0.12.0
func (g *AccountGetAuthorizationFormRequest) String() string
String implements fmt.Stringer.
type AccountGetAuthorizationsRequest ¶
type AccountGetAuthorizationsRequest struct {
}
AccountGetAuthorizationsRequest represents TL type `account.getAuthorizations#e320c158`. Get logged-in sessions
See https://core.telegram.org/method/account.getAuthorizations for reference.
func (*AccountGetAuthorizationsRequest) Decode ¶
func (g *AccountGetAuthorizationsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetAuthorizationsRequest) Encode ¶
func (g *AccountGetAuthorizationsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetAuthorizationsRequest) String ¶ added in v0.12.0
func (g *AccountGetAuthorizationsRequest) String() string
String implements fmt.Stringer.
type AccountGetAutoDownloadSettingsRequest ¶
type AccountGetAutoDownloadSettingsRequest struct {
}
AccountGetAutoDownloadSettingsRequest represents TL type `account.getAutoDownloadSettings#56da0b3f`. Get media autodownload settings
See https://core.telegram.org/method/account.getAutoDownloadSettings for reference.
func (*AccountGetAutoDownloadSettingsRequest) Decode ¶
func (g *AccountGetAutoDownloadSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetAutoDownloadSettingsRequest) Encode ¶
func (g *AccountGetAutoDownloadSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetAutoDownloadSettingsRequest) String ¶ added in v0.12.0
func (g *AccountGetAutoDownloadSettingsRequest) String() string
String implements fmt.Stringer.
type AccountGetContactSignUpNotificationRequest ¶
type AccountGetContactSignUpNotificationRequest struct {
}
AccountGetContactSignUpNotificationRequest represents TL type `account.getContactSignUpNotification#9f07c728`. Whether the user will receive notifications when contacts sign up
See https://core.telegram.org/method/account.getContactSignUpNotification for reference.
func (*AccountGetContactSignUpNotificationRequest) Decode ¶
func (g *AccountGetContactSignUpNotificationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetContactSignUpNotificationRequest) Encode ¶
func (g *AccountGetContactSignUpNotificationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetContactSignUpNotificationRequest) String ¶ added in v0.12.0
func (g *AccountGetContactSignUpNotificationRequest) String() string
String implements fmt.Stringer.
type AccountGetContentSettingsRequest ¶
type AccountGetContentSettingsRequest struct {
}
AccountGetContentSettingsRequest represents TL type `account.getContentSettings#8b9b4dae`. Get sensitive content settings
See https://core.telegram.org/method/account.getContentSettings for reference.
func (*AccountGetContentSettingsRequest) Decode ¶
func (g *AccountGetContentSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetContentSettingsRequest) Encode ¶
func (g *AccountGetContentSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetContentSettingsRequest) String ¶ added in v0.12.0
func (g *AccountGetContentSettingsRequest) String() string
String implements fmt.Stringer.
type AccountGetGlobalPrivacySettingsRequest ¶
type AccountGetGlobalPrivacySettingsRequest struct {
}
AccountGetGlobalPrivacySettingsRequest represents TL type `account.getGlobalPrivacySettings#eb2b4cf6`. Get global privacy settings
See https://core.telegram.org/method/account.getGlobalPrivacySettings for reference.
func (*AccountGetGlobalPrivacySettingsRequest) Decode ¶
func (g *AccountGetGlobalPrivacySettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetGlobalPrivacySettingsRequest) Encode ¶
func (g *AccountGetGlobalPrivacySettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetGlobalPrivacySettingsRequest) String ¶ added in v0.12.0
func (g *AccountGetGlobalPrivacySettingsRequest) String() string
String implements fmt.Stringer.
type AccountGetMultiWallPapersRequest ¶
type AccountGetMultiWallPapersRequest struct {
// Wallpapers to fetch info about
Wallpapers []InputWallPaperClass
}
AccountGetMultiWallPapersRequest represents TL type `account.getMultiWallPapers#65ad71dc`. Get info about multiple wallpapers
See https://core.telegram.org/method/account.getMultiWallPapers for reference.
func (*AccountGetMultiWallPapersRequest) Decode ¶
func (g *AccountGetMultiWallPapersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetMultiWallPapersRequest) Encode ¶
func (g *AccountGetMultiWallPapersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetMultiWallPapersRequest) String ¶ added in v0.12.0
func (g *AccountGetMultiWallPapersRequest) String() string
String implements fmt.Stringer.
type AccountGetNotifyExceptionsRequest ¶
type AccountGetNotifyExceptionsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If true, chats with non-default sound will also be returned
CompareSound bool
// If specified, only chats of the specified category will be returned
//
// Use SetPeer and GetPeer helpers.
Peer InputNotifyPeerClass
}
AccountGetNotifyExceptionsRequest represents TL type `account.getNotifyExceptions#53577479`. Returns list of chats with non-default notification settings
See https://core.telegram.org/method/account.getNotifyExceptions for reference.
func (*AccountGetNotifyExceptionsRequest) Decode ¶
func (g *AccountGetNotifyExceptionsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetNotifyExceptionsRequest) Encode ¶
func (g *AccountGetNotifyExceptionsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetNotifyExceptionsRequest) GetPeer ¶
func (g *AccountGetNotifyExceptionsRequest) GetPeer() (value InputNotifyPeerClass, ok bool)
GetPeer returns value of Peer conditional field and boolean which is true if field was set.
func (*AccountGetNotifyExceptionsRequest) SetCompareSound ¶
func (g *AccountGetNotifyExceptionsRequest) SetCompareSound(value bool)
SetCompareSound sets value of CompareSound conditional field.
func (*AccountGetNotifyExceptionsRequest) SetPeer ¶
func (g *AccountGetNotifyExceptionsRequest) SetPeer(value InputNotifyPeerClass)
SetPeer sets value of Peer conditional field.
func (*AccountGetNotifyExceptionsRequest) String ¶ added in v0.12.0
func (g *AccountGetNotifyExceptionsRequest) String() string
String implements fmt.Stringer.
type AccountGetNotifySettingsRequest ¶
type AccountGetNotifySettingsRequest struct {
// Notification source
Peer InputNotifyPeerClass
}
AccountGetNotifySettingsRequest represents TL type `account.getNotifySettings#12b3ad31`. Gets current notification settings for a given user/group, from all users/all groups.
See https://core.telegram.org/method/account.getNotifySettings for reference.
func (*AccountGetNotifySettingsRequest) Decode ¶
func (g *AccountGetNotifySettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetNotifySettingsRequest) Encode ¶
func (g *AccountGetNotifySettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetNotifySettingsRequest) String ¶ added in v0.12.0
func (g *AccountGetNotifySettingsRequest) String() string
String implements fmt.Stringer.
type AccountGetPasswordRequest ¶
type AccountGetPasswordRequest struct {
}
AccountGetPasswordRequest represents TL type `account.getPassword#548a30f5`. Obtain configuration for two-factor authorization with password
See https://core.telegram.org/method/account.getPassword for reference.
func (*AccountGetPasswordRequest) Decode ¶
func (g *AccountGetPasswordRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetPasswordRequest) Encode ¶
func (g *AccountGetPasswordRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetPasswordRequest) String ¶ added in v0.12.0
func (g *AccountGetPasswordRequest) String() string
String implements fmt.Stringer.
type AccountGetPasswordSettingsRequest ¶
type AccountGetPasswordSettingsRequest struct {
// The password (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
Password InputCheckPasswordSRPClass
}
AccountGetPasswordSettingsRequest represents TL type `account.getPasswordSettings#9cd4eaf9`. Get private info associated to the password info (recovery email, telegram passport¹ info & so on)
Links:
See https://core.telegram.org/method/account.getPasswordSettings for reference.
func (*AccountGetPasswordSettingsRequest) Decode ¶
func (g *AccountGetPasswordSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetPasswordSettingsRequest) Encode ¶
func (g *AccountGetPasswordSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetPasswordSettingsRequest) String ¶ added in v0.12.0
func (g *AccountGetPasswordSettingsRequest) String() string
String implements fmt.Stringer.
type AccountGetPrivacyRequest ¶
type AccountGetPrivacyRequest struct {
// Peer category whose privacy settings should be fetched
Key InputPrivacyKeyClass
}
AccountGetPrivacyRequest represents TL type `account.getPrivacy#dadbc950`. Get privacy settings of current account
See https://core.telegram.org/method/account.getPrivacy for reference.
func (*AccountGetPrivacyRequest) Decode ¶
func (g *AccountGetPrivacyRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetPrivacyRequest) Encode ¶
func (g *AccountGetPrivacyRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetPrivacyRequest) String ¶ added in v0.12.0
func (g *AccountGetPrivacyRequest) String() string
String implements fmt.Stringer.
type AccountGetSecureValueRequest ¶
type AccountGetSecureValueRequest struct {
// Requested value types
Types []SecureValueTypeClass
}
AccountGetSecureValueRequest represents TL type `account.getSecureValue#73665bc2`. Get saved Telegram Passport¹ document, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.getSecureValue for reference.
func (*AccountGetSecureValueRequest) Decode ¶
func (g *AccountGetSecureValueRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetSecureValueRequest) Encode ¶
func (g *AccountGetSecureValueRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetSecureValueRequest) String ¶ added in v0.12.0
func (g *AccountGetSecureValueRequest) String() string
String implements fmt.Stringer.
type AccountGetThemeRequest ¶
type AccountGetThemeRequest struct {
// Theme format, a string that identifies the theming engines supported by the client
Format string
// Theme
Theme InputThemeClass
// Document ID
DocumentID int64
}
AccountGetThemeRequest represents TL type `account.getTheme#8d9d742b`. Get theme information
See https://core.telegram.org/method/account.getTheme for reference.
func (*AccountGetThemeRequest) Decode ¶
func (g *AccountGetThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetThemeRequest) Encode ¶
func (g *AccountGetThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetThemeRequest) String ¶ added in v0.12.0
func (g *AccountGetThemeRequest) String() string
String implements fmt.Stringer.
type AccountGetThemesRequest ¶
type AccountGetThemesRequest struct {
// Theme format, a string that identifies the theming engines supported by the client
Format string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
AccountGetThemesRequest represents TL type `account.getThemes#285946f8`. Get installed themes
See https://core.telegram.org/method/account.getThemes for reference.
func (*AccountGetThemesRequest) Decode ¶
func (g *AccountGetThemesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetThemesRequest) Encode ¶
func (g *AccountGetThemesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetThemesRequest) String ¶ added in v0.12.0
func (g *AccountGetThemesRequest) String() string
String implements fmt.Stringer.
type AccountGetTmpPasswordRequest ¶
type AccountGetTmpPasswordRequest struct {
// SRP password parameters
Password InputCheckPasswordSRPClass
// Time during which the temporary password will be valid, in seconds; should be between 60 and 86400
Period int
}
AccountGetTmpPasswordRequest represents TL type `account.getTmpPassword#449e0b51`. Get temporary payment password
See https://core.telegram.org/method/account.getTmpPassword for reference.
func (*AccountGetTmpPasswordRequest) Decode ¶
func (g *AccountGetTmpPasswordRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetTmpPasswordRequest) Encode ¶
func (g *AccountGetTmpPasswordRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetTmpPasswordRequest) String ¶ added in v0.12.0
func (g *AccountGetTmpPasswordRequest) String() string
String implements fmt.Stringer.
type AccountGetWallPaperRequest ¶
type AccountGetWallPaperRequest struct {
// The wallpaper to get info about
Wallpaper InputWallPaperClass
}
AccountGetWallPaperRequest represents TL type `account.getWallPaper#fc8ddbea`. Get info about a certain wallpaper
See https://core.telegram.org/method/account.getWallPaper for reference.
func (*AccountGetWallPaperRequest) Decode ¶
func (g *AccountGetWallPaperRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetWallPaperRequest) Encode ¶
func (g *AccountGetWallPaperRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetWallPaperRequest) String ¶ added in v0.12.0
func (g *AccountGetWallPaperRequest) String() string
String implements fmt.Stringer.
type AccountGetWallPapersRequest ¶
type AccountGetWallPapersRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
AccountGetWallPapersRequest represents TL type `account.getWallPapers#aabb1763`. Returns a list of available wallpapers.
See https://core.telegram.org/method/account.getWallPapers for reference.
func (*AccountGetWallPapersRequest) Decode ¶
func (g *AccountGetWallPapersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetWallPapersRequest) Encode ¶
func (g *AccountGetWallPapersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetWallPapersRequest) String ¶ added in v0.12.0
func (g *AccountGetWallPapersRequest) String() string
String implements fmt.Stringer.
type AccountGetWebAuthorizationsRequest ¶
type AccountGetWebAuthorizationsRequest struct {
}
AccountGetWebAuthorizationsRequest represents TL type `account.getWebAuthorizations#182e6d6f`. Get web login widget¹ authorizations
Links:
See https://core.telegram.org/method/account.getWebAuthorizations for reference.
func (*AccountGetWebAuthorizationsRequest) Decode ¶
func (g *AccountGetWebAuthorizationsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountGetWebAuthorizationsRequest) Encode ¶
func (g *AccountGetWebAuthorizationsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountGetWebAuthorizationsRequest) String ¶ added in v0.12.0
func (g *AccountGetWebAuthorizationsRequest) String() string
String implements fmt.Stringer.
type AccountInitTakeoutSessionRequest ¶
type AccountInitTakeoutSessionRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to export contacts
Contacts bool
// Whether to export messages in private chats
MessageUsers bool
// Whether to export messages in legacy groups¹
//
// Links:
// 1) https://core.telegram.org/api/channel
MessageChats bool
// Whether to export messages in supergroups¹
//
// Links:
// 1) https://core.telegram.org/api/channel
MessageMegagroups bool
// Whether to export messages in channels¹
//
// Links:
// 1) https://core.telegram.org/api/channel
MessageChannels bool
// Whether to export files
Files bool
// Maximum size of files to export
//
// Use SetFileMaxSize and GetFileMaxSize helpers.
FileMaxSize int
}
AccountInitTakeoutSessionRequest represents TL type `account.initTakeoutSession#f05b4804`. Intialize account takeout session
See https://core.telegram.org/method/account.initTakeoutSession for reference.
func (*AccountInitTakeoutSessionRequest) Decode ¶
func (i *AccountInitTakeoutSessionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountInitTakeoutSessionRequest) Encode ¶
func (i *AccountInitTakeoutSessionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountInitTakeoutSessionRequest) GetFileMaxSize ¶
func (i *AccountInitTakeoutSessionRequest) GetFileMaxSize() (value int, ok bool)
GetFileMaxSize returns value of FileMaxSize conditional field and boolean which is true if field was set.
func (*AccountInitTakeoutSessionRequest) SetContacts ¶
func (i *AccountInitTakeoutSessionRequest) SetContacts(value bool)
SetContacts sets value of Contacts conditional field.
func (*AccountInitTakeoutSessionRequest) SetFileMaxSize ¶
func (i *AccountInitTakeoutSessionRequest) SetFileMaxSize(value int)
SetFileMaxSize sets value of FileMaxSize conditional field.
func (*AccountInitTakeoutSessionRequest) SetFiles ¶
func (i *AccountInitTakeoutSessionRequest) SetFiles(value bool)
SetFiles sets value of Files conditional field.
func (*AccountInitTakeoutSessionRequest) SetMessageChannels ¶
func (i *AccountInitTakeoutSessionRequest) SetMessageChannels(value bool)
SetMessageChannels sets value of MessageChannels conditional field.
func (*AccountInitTakeoutSessionRequest) SetMessageChats ¶
func (i *AccountInitTakeoutSessionRequest) SetMessageChats(value bool)
SetMessageChats sets value of MessageChats conditional field.
func (*AccountInitTakeoutSessionRequest) SetMessageMegagroups ¶
func (i *AccountInitTakeoutSessionRequest) SetMessageMegagroups(value bool)
SetMessageMegagroups sets value of MessageMegagroups conditional field.
func (*AccountInitTakeoutSessionRequest) SetMessageUsers ¶
func (i *AccountInitTakeoutSessionRequest) SetMessageUsers(value bool)
SetMessageUsers sets value of MessageUsers conditional field.
func (*AccountInitTakeoutSessionRequest) String ¶ added in v0.12.0
func (i *AccountInitTakeoutSessionRequest) String() string
String implements fmt.Stringer.
type AccountInstallThemeRequest ¶
type AccountInstallThemeRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to install the dark version
Dark bool
// Theme format, a string that identifies the theming engines supported by the client
//
// Use SetFormat and GetFormat helpers.
Format string
// Theme to install
//
// Use SetTheme and GetTheme helpers.
Theme InputThemeClass
}
AccountInstallThemeRequest represents TL type `account.installTheme#7ae43737`. Install a theme
See https://core.telegram.org/method/account.installTheme for reference.
func (*AccountInstallThemeRequest) Decode ¶
func (i *AccountInstallThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountInstallThemeRequest) Encode ¶
func (i *AccountInstallThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountInstallThemeRequest) GetFormat ¶
func (i *AccountInstallThemeRequest) GetFormat() (value string, ok bool)
GetFormat returns value of Format conditional field and boolean which is true if field was set.
func (*AccountInstallThemeRequest) GetTheme ¶
func (i *AccountInstallThemeRequest) GetTheme() (value InputThemeClass, ok bool)
GetTheme returns value of Theme conditional field and boolean which is true if field was set.
func (*AccountInstallThemeRequest) SetDark ¶
func (i *AccountInstallThemeRequest) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*AccountInstallThemeRequest) SetFormat ¶
func (i *AccountInstallThemeRequest) SetFormat(value string)
SetFormat sets value of Format conditional field.
func (*AccountInstallThemeRequest) SetTheme ¶
func (i *AccountInstallThemeRequest) SetTheme(value InputThemeClass)
SetTheme sets value of Theme conditional field.
func (*AccountInstallThemeRequest) String ¶ added in v0.12.0
func (i *AccountInstallThemeRequest) String() string
String implements fmt.Stringer.
type AccountInstallWallPaperRequest ¶
type AccountInstallWallPaperRequest struct {
// Wallpaper to install
Wallpaper InputWallPaperClass
// Wallpaper settings
Settings WallPaperSettings
}
AccountInstallWallPaperRequest represents TL type `account.installWallPaper#feed5769`. Install wallpaper
See https://core.telegram.org/method/account.installWallPaper for reference.
func (*AccountInstallWallPaperRequest) Decode ¶
func (i *AccountInstallWallPaperRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountInstallWallPaperRequest) Encode ¶
func (i *AccountInstallWallPaperRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountInstallWallPaperRequest) String ¶ added in v0.12.0
func (i *AccountInstallWallPaperRequest) String() string
String implements fmt.Stringer.
type AccountPassword ¶
type AccountPassword struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user has a recovery method configured
HasRecovery bool
// Whether telegram passport¹ is enabled
//
// Links:
// 1) https://core.telegram.org/passport
HasSecureValues bool
// Whether the user has a password
HasPassword bool
// The KDF algorithm for SRP two-factor authentication¹ of the current password
//
// Links:
// 1) https://core.telegram.org/api/srp
//
// Use SetCurrentAlgo and GetCurrentAlgo helpers.
CurrentAlgo PasswordKdfAlgoClass
// Srp B param for SRP authorization¹
//
// Links:
// 1) https://core.telegram.org/api/srp
//
// Use SetSrpB and GetSrpB helpers.
SrpB []byte
// Srp ID param for SRP authorization¹
//
// Links:
// 1) https://core.telegram.org/api/srp
//
// Use SetSrpID and GetSrpID helpers.
SrpID int64
// Text hint for the password
//
// Use SetHint and GetHint helpers.
Hint string
// A password recovery email¹ with the specified pattern² is still awaiting verification
//
// Links:
// 1) https://core.telegram.org/api/srp#email-verification
// 2) https://core.telegram.org/api/pattern
//
// Use SetEmailUnconfirmedPattern and GetEmailUnconfirmedPattern helpers.
EmailUnconfirmedPattern string
// The KDF algorithm for SRP two-factor authentication¹ to use when creating new passwords
//
// Links:
// 1) https://core.telegram.org/api/srp
NewAlgo PasswordKdfAlgoClass
// The KDF algorithm for telegram passport¹
//
// Links:
// 1) https://core.telegram.org/passport
NewSecureAlgo SecurePasswordKdfAlgoClass
// Secure random string
SecureRandom []byte
}
AccountPassword represents TL type `account.password#ad2641f8`. Configuration for two-factor authorization
See https://core.telegram.org/constructor/account.password for reference.
func (*AccountPassword) Decode ¶
func (p *AccountPassword) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountPassword) Encode ¶
func (p *AccountPassword) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountPassword) GetCurrentAlgo ¶
func (p *AccountPassword) GetCurrentAlgo() (value PasswordKdfAlgoClass, ok bool)
GetCurrentAlgo returns value of CurrentAlgo conditional field and boolean which is true if field was set.
func (*AccountPassword) GetEmailUnconfirmedPattern ¶
func (p *AccountPassword) GetEmailUnconfirmedPattern() (value string, ok bool)
GetEmailUnconfirmedPattern returns value of EmailUnconfirmedPattern conditional field and boolean which is true if field was set.
func (*AccountPassword) GetHint ¶
func (p *AccountPassword) GetHint() (value string, ok bool)
GetHint returns value of Hint conditional field and boolean which is true if field was set.
func (*AccountPassword) GetSrpB ¶
func (p *AccountPassword) GetSrpB() (value []byte, ok bool)
GetSrpB returns value of SrpB conditional field and boolean which is true if field was set.
func (*AccountPassword) GetSrpID ¶
func (p *AccountPassword) GetSrpID() (value int64, ok bool)
GetSrpID returns value of SrpID conditional field and boolean which is true if field was set.
func (*AccountPassword) SetCurrentAlgo ¶
func (p *AccountPassword) SetCurrentAlgo(value PasswordKdfAlgoClass)
SetCurrentAlgo sets value of CurrentAlgo conditional field.
func (*AccountPassword) SetEmailUnconfirmedPattern ¶
func (p *AccountPassword) SetEmailUnconfirmedPattern(value string)
SetEmailUnconfirmedPattern sets value of EmailUnconfirmedPattern conditional field.
func (*AccountPassword) SetHasPassword ¶
func (p *AccountPassword) SetHasPassword(value bool)
SetHasPassword sets value of HasPassword conditional field.
func (*AccountPassword) SetHasRecovery ¶
func (p *AccountPassword) SetHasRecovery(value bool)
SetHasRecovery sets value of HasRecovery conditional field.
func (*AccountPassword) SetHasSecureValues ¶
func (p *AccountPassword) SetHasSecureValues(value bool)
SetHasSecureValues sets value of HasSecureValues conditional field.
func (*AccountPassword) SetHint ¶
func (p *AccountPassword) SetHint(value string)
SetHint sets value of Hint conditional field.
func (*AccountPassword) SetSrpB ¶
func (p *AccountPassword) SetSrpB(value []byte)
SetSrpB sets value of SrpB conditional field.
func (*AccountPassword) SetSrpID ¶
func (p *AccountPassword) SetSrpID(value int64)
SetSrpID sets value of SrpID conditional field.
func (*AccountPassword) String ¶ added in v0.12.0
func (p *AccountPassword) String() string
String implements fmt.Stringer.
type AccountPasswordInputSettings ¶
type AccountPasswordInputSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The SRP algorithm¹ to use
//
// Links:
// 1) https://core.telegram.org/api/srp
//
// Use SetNewAlgo and GetNewAlgo helpers.
NewAlgo PasswordKdfAlgoClass
// The computed password hash¹
//
// Links:
// 1) https://core.telegram.org/api/srp
//
// Use SetNewPasswordHash and GetNewPasswordHash helpers.
NewPasswordHash []byte
// Text hint for the password
//
// Use SetHint and GetHint helpers.
Hint string
// Password recovery email
//
// Use SetEmail and GetEmail helpers.
Email string
// Telegram passport¹ settings
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetNewSecureSettings and GetNewSecureSettings helpers.
NewSecureSettings SecureSecretSettings
}
AccountPasswordInputSettings represents TL type `account.passwordInputSettings#c23727c9`. Settings for setting up a new password
See https://core.telegram.org/constructor/account.passwordInputSettings for reference.
func (*AccountPasswordInputSettings) Decode ¶
func (p *AccountPasswordInputSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountPasswordInputSettings) Encode ¶
func (p *AccountPasswordInputSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountPasswordInputSettings) GetEmail ¶
func (p *AccountPasswordInputSettings) GetEmail() (value string, ok bool)
GetEmail returns value of Email conditional field and boolean which is true if field was set.
func (*AccountPasswordInputSettings) GetHint ¶
func (p *AccountPasswordInputSettings) GetHint() (value string, ok bool)
GetHint returns value of Hint conditional field and boolean which is true if field was set.
func (*AccountPasswordInputSettings) GetNewAlgo ¶
func (p *AccountPasswordInputSettings) GetNewAlgo() (value PasswordKdfAlgoClass, ok bool)
GetNewAlgo returns value of NewAlgo conditional field and boolean which is true if field was set.
func (*AccountPasswordInputSettings) GetNewPasswordHash ¶
func (p *AccountPasswordInputSettings) GetNewPasswordHash() (value []byte, ok bool)
GetNewPasswordHash returns value of NewPasswordHash conditional field and boolean which is true if field was set.
func (*AccountPasswordInputSettings) GetNewSecureSettings ¶
func (p *AccountPasswordInputSettings) GetNewSecureSettings() (value SecureSecretSettings, ok bool)
GetNewSecureSettings returns value of NewSecureSettings conditional field and boolean which is true if field was set.
func (*AccountPasswordInputSettings) SetEmail ¶
func (p *AccountPasswordInputSettings) SetEmail(value string)
SetEmail sets value of Email conditional field.
func (*AccountPasswordInputSettings) SetHint ¶
func (p *AccountPasswordInputSettings) SetHint(value string)
SetHint sets value of Hint conditional field.
func (*AccountPasswordInputSettings) SetNewAlgo ¶
func (p *AccountPasswordInputSettings) SetNewAlgo(value PasswordKdfAlgoClass)
SetNewAlgo sets value of NewAlgo conditional field.
func (*AccountPasswordInputSettings) SetNewPasswordHash ¶
func (p *AccountPasswordInputSettings) SetNewPasswordHash(value []byte)
SetNewPasswordHash sets value of NewPasswordHash conditional field.
func (*AccountPasswordInputSettings) SetNewSecureSettings ¶
func (p *AccountPasswordInputSettings) SetNewSecureSettings(value SecureSecretSettings)
SetNewSecureSettings sets value of NewSecureSettings conditional field.
func (*AccountPasswordInputSettings) String ¶ added in v0.12.0
func (p *AccountPasswordInputSettings) String() string
String implements fmt.Stringer.
type AccountPasswordSettings ¶
type AccountPasswordSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// 2FA Recovery email¹
//
// Links:
// 1) https://core.telegram.org/api/srp#email-verification
//
// Use SetEmail and GetEmail helpers.
Email string
// Telegram passport¹ settings
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetSecureSettings and GetSecureSettings helpers.
SecureSettings SecureSecretSettings
}
AccountPasswordSettings represents TL type `account.passwordSettings#9a5c33e5`. Private info associated to the password info (recovery email, telegram passport¹ info & so on)
Links:
See https://core.telegram.org/constructor/account.passwordSettings for reference.
func (*AccountPasswordSettings) Decode ¶
func (p *AccountPasswordSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountPasswordSettings) Encode ¶
func (p *AccountPasswordSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountPasswordSettings) GetEmail ¶
func (p *AccountPasswordSettings) GetEmail() (value string, ok bool)
GetEmail returns value of Email conditional field and boolean which is true if field was set.
func (*AccountPasswordSettings) GetSecureSettings ¶
func (p *AccountPasswordSettings) GetSecureSettings() (value SecureSecretSettings, ok bool)
GetSecureSettings returns value of SecureSettings conditional field and boolean which is true if field was set.
func (*AccountPasswordSettings) SetEmail ¶
func (p *AccountPasswordSettings) SetEmail(value string)
SetEmail sets value of Email conditional field.
func (*AccountPasswordSettings) SetSecureSettings ¶
func (p *AccountPasswordSettings) SetSecureSettings(value SecureSecretSettings)
SetSecureSettings sets value of SecureSettings conditional field.
func (*AccountPasswordSettings) String ¶ added in v0.12.0
func (p *AccountPasswordSettings) String() string
String implements fmt.Stringer.
type AccountPrivacyRules ¶
type AccountPrivacyRules struct {
// Privacy rules
Rules []PrivacyRuleClass
// Chats to which the rules apply
Chats []ChatClass
// Users to which the rules apply
Users []UserClass
}
AccountPrivacyRules represents TL type `account.privacyRules#50a04e45`. Privacy rules
See https://core.telegram.org/constructor/account.privacyRules for reference.
func (*AccountPrivacyRules) Decode ¶
func (p *AccountPrivacyRules) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountPrivacyRules) Encode ¶
func (p *AccountPrivacyRules) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountPrivacyRules) String ¶ added in v0.12.0
func (p *AccountPrivacyRules) String() string
String implements fmt.Stringer.
type AccountRegisterDeviceRequest ¶
type AccountRegisterDeviceRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Avoid receiving (silent and invisible background) notifications. Useful to save battery.
NoMuted bool
// Device token type.Possible values:1 - APNS (device token for apple push)2 - FCM (firebase token for google firebase)3 - MPNS (channel URI for microsoft push)4 - Simple push (endpoint for firefox's simple push API)5 - Ubuntu phone (token for ubuntu push)6 - Blackberry (token for blackberry push)7 - Unused8 - WNS (windows push)9 - APNS VoIP (token for apple push VoIP)10 - Web push (web push, see below)11 - MPNS VoIP (token for microsoft push VoIP)12 - Tizen (token for tizen push)For 10 web push, the token must be a JSON-encoded object containing the keys described in PUSH updates¹
//
// Links:
// 1) https://core.telegram.org/api/push-updates
TokenType int
// Device token
Token string
// If (boolTrue)¹ is transmitted, a sandbox-certificate will be used during transmission.
//
// Links:
// 1) https://core.telegram.org/constructor/boolTrue
AppSandbox bool
// For FCM and APNS VoIP, optional encryption key used to encrypt push notifications
Secret []byte
// List of user identifiers of other users currently using the client
OtherUids []int
}
AccountRegisterDeviceRequest represents TL type `account.registerDevice#68976c6f`. Register device to receive PUSH notifications¹
Links:
See https://core.telegram.org/method/account.registerDevice for reference.
func (*AccountRegisterDeviceRequest) Decode ¶
func (r *AccountRegisterDeviceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountRegisterDeviceRequest) Encode ¶
func (r *AccountRegisterDeviceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountRegisterDeviceRequest) SetNoMuted ¶
func (r *AccountRegisterDeviceRequest) SetNoMuted(value bool)
SetNoMuted sets value of NoMuted conditional field.
func (*AccountRegisterDeviceRequest) String ¶ added in v0.12.0
func (r *AccountRegisterDeviceRequest) String() string
String implements fmt.Stringer.
type AccountReportPeerRequest ¶
type AccountReportPeerRequest struct {
// The peer to report
Peer InputPeerClass
// The reason why this peer is being reported
Reason ReportReasonClass
}
AccountReportPeerRequest represents TL type `account.reportPeer#ae189d5f`. Report a peer for violation of telegram's Terms of Service
See https://core.telegram.org/method/account.reportPeer for reference.
func (*AccountReportPeerRequest) Decode ¶
func (r *AccountReportPeerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountReportPeerRequest) Encode ¶
func (r *AccountReportPeerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountReportPeerRequest) String ¶ added in v0.12.0
func (r *AccountReportPeerRequest) String() string
String implements fmt.Stringer.
type AccountResendPasswordEmailRequest ¶
type AccountResendPasswordEmailRequest struct {
}
AccountResendPasswordEmailRequest represents TL type `account.resendPasswordEmail#7a7f2a15`. Resend the code to verify an email to use as 2FA recovery method¹.
Links:
See https://core.telegram.org/method/account.resendPasswordEmail for reference.
func (*AccountResendPasswordEmailRequest) Decode ¶
func (r *AccountResendPasswordEmailRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResendPasswordEmailRequest) Encode ¶
func (r *AccountResendPasswordEmailRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResendPasswordEmailRequest) String ¶ added in v0.12.0
func (r *AccountResendPasswordEmailRequest) String() string
String implements fmt.Stringer.
type AccountResetAuthorizationRequest ¶
type AccountResetAuthorizationRequest struct {
// Session hash
Hash int64
}
AccountResetAuthorizationRequest represents TL type `account.resetAuthorization#df77f3bc`. Log out an active authorized session¹ by its hash
Links:
See https://core.telegram.org/method/account.resetAuthorization for reference.
func (*AccountResetAuthorizationRequest) Decode ¶
func (r *AccountResetAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResetAuthorizationRequest) Encode ¶
func (r *AccountResetAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResetAuthorizationRequest) String ¶ added in v0.12.0
func (r *AccountResetAuthorizationRequest) String() string
String implements fmt.Stringer.
type AccountResetNotifySettingsRequest ¶
type AccountResetNotifySettingsRequest struct {
}
AccountResetNotifySettingsRequest represents TL type `account.resetNotifySettings#db7e1747`. Resets all notification settings from users and groups.
See https://core.telegram.org/method/account.resetNotifySettings for reference.
func (*AccountResetNotifySettingsRequest) Decode ¶
func (r *AccountResetNotifySettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResetNotifySettingsRequest) Encode ¶
func (r *AccountResetNotifySettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResetNotifySettingsRequest) String ¶ added in v0.12.0
func (r *AccountResetNotifySettingsRequest) String() string
String implements fmt.Stringer.
type AccountResetWallPapersRequest ¶
type AccountResetWallPapersRequest struct {
}
AccountResetWallPapersRequest represents TL type `account.resetWallPapers#bb3b9804`. Delete installed wallpapers
See https://core.telegram.org/method/account.resetWallPapers for reference.
func (*AccountResetWallPapersRequest) Decode ¶
func (r *AccountResetWallPapersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResetWallPapersRequest) Encode ¶
func (r *AccountResetWallPapersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResetWallPapersRequest) String ¶ added in v0.12.0
func (r *AccountResetWallPapersRequest) String() string
String implements fmt.Stringer.
type AccountResetWebAuthorizationRequest ¶
type AccountResetWebAuthorizationRequest struct {
// Session¹ hash
//
// Links:
// 1) https://core.telegram.org/constructor/webAuthorization
Hash int64
}
AccountResetWebAuthorizationRequest represents TL type `account.resetWebAuthorization#2d01b9ef`. Log out an active web telegram login¹ session
Links:
See https://core.telegram.org/method/account.resetWebAuthorization for reference.
func (*AccountResetWebAuthorizationRequest) Decode ¶
func (r *AccountResetWebAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResetWebAuthorizationRequest) Encode ¶
func (r *AccountResetWebAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResetWebAuthorizationRequest) String ¶ added in v0.12.0
func (r *AccountResetWebAuthorizationRequest) String() string
String implements fmt.Stringer.
type AccountResetWebAuthorizationsRequest ¶
type AccountResetWebAuthorizationsRequest struct {
}
AccountResetWebAuthorizationsRequest represents TL type `account.resetWebAuthorizations#682d2594`. Reset all active web telegram login¹ sessions
Links:
See https://core.telegram.org/method/account.resetWebAuthorizations for reference.
func (*AccountResetWebAuthorizationsRequest) Decode ¶
func (r *AccountResetWebAuthorizationsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountResetWebAuthorizationsRequest) Encode ¶
func (r *AccountResetWebAuthorizationsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountResetWebAuthorizationsRequest) String ¶ added in v0.12.0
func (r *AccountResetWebAuthorizationsRequest) String() string
String implements fmt.Stringer.
type AccountSaveAutoDownloadSettingsRequest ¶
type AccountSaveAutoDownloadSettingsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to save settings in the low data usage preset
Low bool
// Whether to save settings in the high data usage preset
High bool
// Media autodownload settings
Settings AutoDownloadSettings
}
AccountSaveAutoDownloadSettingsRequest represents TL type `account.saveAutoDownloadSettings#76f36233`. Change media autodownload settings
See https://core.telegram.org/method/account.saveAutoDownloadSettings for reference.
func (*AccountSaveAutoDownloadSettingsRequest) Decode ¶
func (s *AccountSaveAutoDownloadSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSaveAutoDownloadSettingsRequest) Encode ¶
func (s *AccountSaveAutoDownloadSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSaveAutoDownloadSettingsRequest) SetHigh ¶
func (s *AccountSaveAutoDownloadSettingsRequest) SetHigh(value bool)
SetHigh sets value of High conditional field.
func (*AccountSaveAutoDownloadSettingsRequest) SetLow ¶
func (s *AccountSaveAutoDownloadSettingsRequest) SetLow(value bool)
SetLow sets value of Low conditional field.
func (*AccountSaveAutoDownloadSettingsRequest) String ¶ added in v0.12.0
func (s *AccountSaveAutoDownloadSettingsRequest) String() string
String implements fmt.Stringer.
type AccountSaveSecureValueRequest ¶
type AccountSaveSecureValueRequest struct {
// Secure value, for more info see the passport docs »¹
//
// Links:
// 1) https://core.telegram.org/passport/encryption#encryption
Value InputSecureValue
// Passport secret hash, for more info see the passport docs »¹
//
// Links:
// 1) https://core.telegram.org/passport/encryption#encryption
SecureSecretID int64
}
AccountSaveSecureValueRequest represents TL type `account.saveSecureValue#899fe31d`. Securely save Telegram Passport¹ document, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.saveSecureValue for reference.
func (*AccountSaveSecureValueRequest) Decode ¶
func (s *AccountSaveSecureValueRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSaveSecureValueRequest) Encode ¶
func (s *AccountSaveSecureValueRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSaveSecureValueRequest) String ¶ added in v0.12.0
func (s *AccountSaveSecureValueRequest) String() string
String implements fmt.Stringer.
type AccountSaveThemeRequest ¶
type AccountSaveThemeRequest struct {
// Theme to save
Theme InputThemeClass
// Unsave
Unsave bool
}
AccountSaveThemeRequest represents TL type `account.saveTheme#f257106c`. Save a theme
See https://core.telegram.org/method/account.saveTheme for reference.
func (*AccountSaveThemeRequest) Decode ¶
func (s *AccountSaveThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSaveThemeRequest) Encode ¶
func (s *AccountSaveThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSaveThemeRequest) String ¶ added in v0.12.0
func (s *AccountSaveThemeRequest) String() string
String implements fmt.Stringer.
type AccountSaveWallPaperRequest ¶
type AccountSaveWallPaperRequest struct {
// Wallpaper to save
Wallpaper InputWallPaperClass
// Uninstall wallpaper?
Unsave bool
// Wallpaper settings
Settings WallPaperSettings
}
AccountSaveWallPaperRequest represents TL type `account.saveWallPaper#6c5a5b37`. Install/uninstall wallpaper
See https://core.telegram.org/method/account.saveWallPaper for reference.
func (*AccountSaveWallPaperRequest) Decode ¶
func (s *AccountSaveWallPaperRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSaveWallPaperRequest) Encode ¶
func (s *AccountSaveWallPaperRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSaveWallPaperRequest) String ¶ added in v0.12.0
func (s *AccountSaveWallPaperRequest) String() string
String implements fmt.Stringer.
type AccountSendChangePhoneCodeRequest ¶
type AccountSendChangePhoneCodeRequest struct {
// New phone number
PhoneNumber string
// Phone code settings
Settings CodeSettings
}
AccountSendChangePhoneCodeRequest represents TL type `account.sendChangePhoneCode#82574ae5`. Verify a new phone number to associate to the current account
See https://core.telegram.org/method/account.sendChangePhoneCode for reference.
func (*AccountSendChangePhoneCodeRequest) Decode ¶
func (s *AccountSendChangePhoneCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSendChangePhoneCodeRequest) Encode ¶
func (s *AccountSendChangePhoneCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSendChangePhoneCodeRequest) String ¶ added in v0.12.0
func (s *AccountSendChangePhoneCodeRequest) String() string
String implements fmt.Stringer.
type AccountSendConfirmPhoneCodeRequest ¶
type AccountSendConfirmPhoneCodeRequest struct {
// The hash from the service notification, for more info click here »¹
//
// Links:
// 1) https://core.telegram.org/api/account-deletion
Hash string
// Phone code settings
Settings CodeSettings
}
AccountSendConfirmPhoneCodeRequest represents TL type `account.sendConfirmPhoneCode#1b3faa88`. Send confirmation code to cancel account deletion, for more info click here »¹
Links:
See https://core.telegram.org/method/account.sendConfirmPhoneCode for reference.
func (*AccountSendConfirmPhoneCodeRequest) Decode ¶
func (s *AccountSendConfirmPhoneCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSendConfirmPhoneCodeRequest) Encode ¶
func (s *AccountSendConfirmPhoneCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSendConfirmPhoneCodeRequest) String ¶ added in v0.12.0
func (s *AccountSendConfirmPhoneCodeRequest) String() string
String implements fmt.Stringer.
type AccountSendVerifyEmailCodeRequest ¶
type AccountSendVerifyEmailCodeRequest struct {
// The email where to send the code
Email string
}
AccountSendVerifyEmailCodeRequest represents TL type `account.sendVerifyEmailCode#7011509f`. Send the verification email code for telegram passport¹.
Links:
See https://core.telegram.org/method/account.sendVerifyEmailCode for reference.
func (*AccountSendVerifyEmailCodeRequest) Decode ¶
func (s *AccountSendVerifyEmailCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSendVerifyEmailCodeRequest) Encode ¶
func (s *AccountSendVerifyEmailCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSendVerifyEmailCodeRequest) String ¶ added in v0.12.0
func (s *AccountSendVerifyEmailCodeRequest) String() string
String implements fmt.Stringer.
type AccountSendVerifyPhoneCodeRequest ¶
type AccountSendVerifyPhoneCodeRequest struct {
// The phone number to verify
PhoneNumber string
// Phone code settings
Settings CodeSettings
}
AccountSendVerifyPhoneCodeRequest represents TL type `account.sendVerifyPhoneCode#a5a356f9`. Send the verification phone code for telegram passport¹.
Links:
See https://core.telegram.org/method/account.sendVerifyPhoneCode for reference.
func (*AccountSendVerifyPhoneCodeRequest) Decode ¶
func (s *AccountSendVerifyPhoneCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSendVerifyPhoneCodeRequest) Encode ¶
func (s *AccountSendVerifyPhoneCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSendVerifyPhoneCodeRequest) String ¶ added in v0.12.0
func (s *AccountSendVerifyPhoneCodeRequest) String() string
String implements fmt.Stringer.
type AccountSentEmailCode ¶
type AccountSentEmailCode struct {
// The email (to which the code was sent) must match this pattern¹
//
// Links:
// 1) https://core.telegram.org/api/pattern
EmailPattern string
// The length of the verification code
Length int
}
AccountSentEmailCode represents TL type `account.sentEmailCode#811f854f`. The sent email code
See https://core.telegram.org/constructor/account.sentEmailCode for reference.
func (*AccountSentEmailCode) Decode ¶
func (s *AccountSentEmailCode) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSentEmailCode) Encode ¶
func (s *AccountSentEmailCode) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSentEmailCode) String ¶ added in v0.12.0
func (s *AccountSentEmailCode) String() string
String implements fmt.Stringer.
type AccountSetAccountTTLRequest ¶
type AccountSetAccountTTLRequest struct {
// Time to live in days
TTL AccountDaysTTL
}
AccountSetAccountTTLRequest represents TL type `account.setAccountTTL#2442485e`. Set account self-destruction period
See https://core.telegram.org/method/account.setAccountTTL for reference.
func (*AccountSetAccountTTLRequest) Decode ¶
func (s *AccountSetAccountTTLRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSetAccountTTLRequest) Encode ¶
func (s *AccountSetAccountTTLRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSetAccountTTLRequest) String ¶ added in v0.12.0
func (s *AccountSetAccountTTLRequest) String() string
String implements fmt.Stringer.
type AccountSetContactSignUpNotificationRequest ¶
type AccountSetContactSignUpNotificationRequest struct {
// Whether to disable contact sign up notifications
Silent bool
}
AccountSetContactSignUpNotificationRequest represents TL type `account.setContactSignUpNotification#cff43f61`. Toggle contact sign up notifications
See https://core.telegram.org/method/account.setContactSignUpNotification for reference.
func (*AccountSetContactSignUpNotificationRequest) Decode ¶
func (s *AccountSetContactSignUpNotificationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSetContactSignUpNotificationRequest) Encode ¶
func (s *AccountSetContactSignUpNotificationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSetContactSignUpNotificationRequest) String ¶ added in v0.12.0
func (s *AccountSetContactSignUpNotificationRequest) String() string
String implements fmt.Stringer.
type AccountSetContentSettingsRequest ¶
type AccountSetContentSettingsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Enable NSFW content
SensitiveEnabled bool
}
AccountSetContentSettingsRequest represents TL type `account.setContentSettings#b574b16b`. Set sensitive content settings (for viewing or hiding NSFW content)
See https://core.telegram.org/method/account.setContentSettings for reference.
func (*AccountSetContentSettingsRequest) Decode ¶
func (s *AccountSetContentSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSetContentSettingsRequest) Encode ¶
func (s *AccountSetContentSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSetContentSettingsRequest) SetSensitiveEnabled ¶
func (s *AccountSetContentSettingsRequest) SetSensitiveEnabled(value bool)
SetSensitiveEnabled sets value of SensitiveEnabled conditional field.
func (*AccountSetContentSettingsRequest) String ¶ added in v0.12.0
func (s *AccountSetContentSettingsRequest) String() string
String implements fmt.Stringer.
type AccountSetGlobalPrivacySettingsRequest ¶
type AccountSetGlobalPrivacySettingsRequest struct {
// Global privacy settings
Settings GlobalPrivacySettings
}
AccountSetGlobalPrivacySettingsRequest represents TL type `account.setGlobalPrivacySettings#1edaaac2`. Set global privacy settings
See https://core.telegram.org/method/account.setGlobalPrivacySettings for reference.
func (*AccountSetGlobalPrivacySettingsRequest) Decode ¶
func (s *AccountSetGlobalPrivacySettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSetGlobalPrivacySettingsRequest) Encode ¶
func (s *AccountSetGlobalPrivacySettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSetGlobalPrivacySettingsRequest) String ¶ added in v0.12.0
func (s *AccountSetGlobalPrivacySettingsRequest) String() string
String implements fmt.Stringer.
type AccountSetPrivacyRequest ¶
type AccountSetPrivacyRequest struct {
// Peers to which the privacy rules apply
Key InputPrivacyKeyClass
// New privacy rules
Rules []InputPrivacyRuleClass
}
AccountSetPrivacyRequest represents TL type `account.setPrivacy#c9f81ce8`. Change privacy settings of current account
See https://core.telegram.org/method/account.setPrivacy for reference.
func (*AccountSetPrivacyRequest) Decode ¶
func (s *AccountSetPrivacyRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountSetPrivacyRequest) Encode ¶
func (s *AccountSetPrivacyRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountSetPrivacyRequest) String ¶ added in v0.12.0
func (s *AccountSetPrivacyRequest) String() string
String implements fmt.Stringer.
type AccountTakeout ¶
type AccountTakeout struct {
// Takeout ID
ID int64
}
AccountTakeout represents TL type `account.takeout#4dba4501`. Takout info
See https://core.telegram.org/constructor/account.takeout for reference.
func (*AccountTakeout) Decode ¶
func (t *AccountTakeout) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountTakeout) Encode ¶
func (t *AccountTakeout) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountTakeout) String ¶ added in v0.12.0
func (t *AccountTakeout) String() string
String implements fmt.Stringer.
type AccountThemes ¶
type AccountThemes struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Themes
Themes []Theme
}
AccountThemes represents TL type `account.themes#7f676421`. Installed themes
See https://core.telegram.org/constructor/account.themes for reference.
func (*AccountThemes) Decode ¶
func (t *AccountThemes) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountThemes) Encode ¶
func (t *AccountThemes) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountThemes) String ¶ added in v0.12.0
func (t *AccountThemes) String() string
String implements fmt.Stringer.
type AccountThemesBox ¶
type AccountThemesBox struct {
Themes AccountThemesClass
}
AccountThemes boxes the AccountThemesClass providing a helper.
type AccountThemesClass ¶
type AccountThemesClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AccountThemesClass represents account.Themes generic type.
See https://core.telegram.org/type/account.Themes for reference.
Example:
g, err := DecodeAccountThemes(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AccountThemesNotModified: // account.themesNotModified#f41eb622
case *AccountThemes: // account.themes#7f676421
default: panic(v)
}
func DecodeAccountThemes ¶
func DecodeAccountThemes(buf *bin.Buffer) (AccountThemesClass, error)
DecodeAccountThemes implements binary de-serialization for AccountThemesClass.
type AccountThemesNotModified ¶
type AccountThemesNotModified struct {
}
AccountThemesNotModified represents TL type `account.themesNotModified#f41eb622`. No new themes were installed
See https://core.telegram.org/constructor/account.themesNotModified for reference.
func (*AccountThemesNotModified) Decode ¶
func (t *AccountThemesNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountThemesNotModified) Encode ¶
func (t *AccountThemesNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountThemesNotModified) String ¶ added in v0.12.0
func (t *AccountThemesNotModified) String() string
String implements fmt.Stringer.
type AccountTmpPassword ¶
type AccountTmpPassword struct {
// Temporary password
TmpPassword []byte
// Validity period
ValidUntil int
}
AccountTmpPassword represents TL type `account.tmpPassword#db64fd34`. Temporary payment password
See https://core.telegram.org/constructor/account.tmpPassword for reference.
func (*AccountTmpPassword) Decode ¶
func (t *AccountTmpPassword) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountTmpPassword) Encode ¶
func (t *AccountTmpPassword) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountTmpPassword) String ¶ added in v0.12.0
func (t *AccountTmpPassword) String() string
String implements fmt.Stringer.
type AccountUnregisterDeviceRequest ¶
type AccountUnregisterDeviceRequest struct {
// Device token type.Possible values:1 - APNS (device token for apple push)2 - FCM (firebase token for google firebase)3 - MPNS (channel URI for microsoft push)4 - Simple push (endpoint for firefox's simple push API)5 - Ubuntu phone (token for ubuntu push)6 - Blackberry (token for blackberry push)7 - Unused8 - WNS (windows push)9 - APNS VoIP (token for apple push VoIP)10 - Web push (web push, see below)11 - MPNS VoIP (token for microsoft push VoIP)12 - Tizen (token for tizen push)For 10 web push, the token must be a JSON-encoded object containing the keys described in PUSH updates¹
//
// Links:
// 1) https://core.telegram.org/api/push-updates
TokenType int
// Device token
Token string
// List of user identifiers of other users currently using the client
OtherUids []int
}
AccountUnregisterDeviceRequest represents TL type `account.unregisterDevice#3076c4bf`. Deletes a device by its token, stops sending PUSH-notifications to it.
See https://core.telegram.org/method/account.unregisterDevice for reference.
func (*AccountUnregisterDeviceRequest) Decode ¶
func (u *AccountUnregisterDeviceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUnregisterDeviceRequest) Encode ¶
func (u *AccountUnregisterDeviceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUnregisterDeviceRequest) String ¶ added in v0.12.0
func (u *AccountUnregisterDeviceRequest) String() string
String implements fmt.Stringer.
type AccountUpdateDeviceLockedRequest ¶
type AccountUpdateDeviceLockedRequest struct {
// Inactivity period after which to start hiding message texts in PUSH notifications¹.
//
// Links:
// 1) https://core.telegram.org/api/push-updates
Period int
}
AccountUpdateDeviceLockedRequest represents TL type `account.updateDeviceLocked#38df3532`. When client-side passcode lock feature is enabled, will not show message texts in incoming PUSH notifications¹.
Links:
See https://core.telegram.org/method/account.updateDeviceLocked for reference.
func (*AccountUpdateDeviceLockedRequest) Decode ¶
func (u *AccountUpdateDeviceLockedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateDeviceLockedRequest) Encode ¶
func (u *AccountUpdateDeviceLockedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateDeviceLockedRequest) String ¶ added in v0.12.0
func (u *AccountUpdateDeviceLockedRequest) String() string
String implements fmt.Stringer.
type AccountUpdateNotifySettingsRequest ¶
type AccountUpdateNotifySettingsRequest struct {
// Notification source
Peer InputNotifyPeerClass
// Notification settings
Settings InputPeerNotifySettings
}
AccountUpdateNotifySettingsRequest represents TL type `account.updateNotifySettings#84be5b93`. Edits notification settings from a given user/group, from all users/all groups.
See https://core.telegram.org/method/account.updateNotifySettings for reference.
func (*AccountUpdateNotifySettingsRequest) Decode ¶
func (u *AccountUpdateNotifySettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateNotifySettingsRequest) Encode ¶
func (u *AccountUpdateNotifySettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateNotifySettingsRequest) String ¶ added in v0.12.0
func (u *AccountUpdateNotifySettingsRequest) String() string
String implements fmt.Stringer.
type AccountUpdatePasswordSettingsRequest ¶
type AccountUpdatePasswordSettingsRequest struct {
// The old password (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
Password InputCheckPasswordSRPClass
// The new password (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
NewSettings AccountPasswordInputSettings
}
AccountUpdatePasswordSettingsRequest represents TL type `account.updatePasswordSettings#a59b102f`. Set a new 2FA password
See https://core.telegram.org/method/account.updatePasswordSettings for reference.
func (*AccountUpdatePasswordSettingsRequest) Decode ¶
func (u *AccountUpdatePasswordSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdatePasswordSettingsRequest) Encode ¶
func (u *AccountUpdatePasswordSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdatePasswordSettingsRequest) String ¶ added in v0.12.0
func (u *AccountUpdatePasswordSettingsRequest) String() string
String implements fmt.Stringer.
type AccountUpdateProfileRequest ¶
type AccountUpdateProfileRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// New user first name
//
// Use SetFirstName and GetFirstName helpers.
FirstName string
// New user last name
//
// Use SetLastName and GetLastName helpers.
LastName string
// New bio
//
// Use SetAbout and GetAbout helpers.
About string
}
AccountUpdateProfileRequest represents TL type `account.updateProfile#78515775`. Updates user profile.
See https://core.telegram.org/method/account.updateProfile for reference.
func (*AccountUpdateProfileRequest) Decode ¶
func (u *AccountUpdateProfileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateProfileRequest) Encode ¶
func (u *AccountUpdateProfileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateProfileRequest) GetAbout ¶
func (u *AccountUpdateProfileRequest) GetAbout() (value string, ok bool)
GetAbout returns value of About conditional field and boolean which is true if field was set.
func (*AccountUpdateProfileRequest) GetFirstName ¶
func (u *AccountUpdateProfileRequest) GetFirstName() (value string, ok bool)
GetFirstName returns value of FirstName conditional field and boolean which is true if field was set.
func (*AccountUpdateProfileRequest) GetLastName ¶
func (u *AccountUpdateProfileRequest) GetLastName() (value string, ok bool)
GetLastName returns value of LastName conditional field and boolean which is true if field was set.
func (*AccountUpdateProfileRequest) SetAbout ¶
func (u *AccountUpdateProfileRequest) SetAbout(value string)
SetAbout sets value of About conditional field.
func (*AccountUpdateProfileRequest) SetFirstName ¶
func (u *AccountUpdateProfileRequest) SetFirstName(value string)
SetFirstName sets value of FirstName conditional field.
func (*AccountUpdateProfileRequest) SetLastName ¶
func (u *AccountUpdateProfileRequest) SetLastName(value string)
SetLastName sets value of LastName conditional field.
func (*AccountUpdateProfileRequest) String ¶ added in v0.12.0
func (u *AccountUpdateProfileRequest) String() string
String implements fmt.Stringer.
type AccountUpdateStatusRequest ¶
type AccountUpdateStatusRequest struct {
// If (boolTrue)¹ is transmitted, user status will change to (userStatusOffline)².
//
// Links:
// 1) https://core.telegram.org/constructor/boolTrue
// 2) https://core.telegram.org/constructor/userStatusOffline
Offline bool
}
AccountUpdateStatusRequest represents TL type `account.updateStatus#6628562c`. Updates online user status.
See https://core.telegram.org/method/account.updateStatus for reference.
func (*AccountUpdateStatusRequest) Decode ¶
func (u *AccountUpdateStatusRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateStatusRequest) Encode ¶
func (u *AccountUpdateStatusRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateStatusRequest) String ¶ added in v0.12.0
func (u *AccountUpdateStatusRequest) String() string
String implements fmt.Stringer.
type AccountUpdateThemeRequest ¶
type AccountUpdateThemeRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Theme format, a string that identifies the theming engines supported by the client
Format string
// Theme to update
Theme InputThemeClass
// Unique theme ID
//
// Use SetSlug and GetSlug helpers.
Slug string
// Theme name
//
// Use SetTitle and GetTitle helpers.
Title string
// Theme file
//
// Use SetDocument and GetDocument helpers.
Document InputDocumentClass
// Theme settings
//
// Use SetSettings and GetSettings helpers.
Settings InputThemeSettings
}
AccountUpdateThemeRequest represents TL type `account.updateTheme#5cb367d5`. Update theme
See https://core.telegram.org/method/account.updateTheme for reference.
func (*AccountUpdateThemeRequest) Decode ¶
func (u *AccountUpdateThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateThemeRequest) Encode ¶
func (u *AccountUpdateThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateThemeRequest) GetDocument ¶
func (u *AccountUpdateThemeRequest) GetDocument() (value InputDocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*AccountUpdateThemeRequest) GetSettings ¶
func (u *AccountUpdateThemeRequest) GetSettings() (value InputThemeSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*AccountUpdateThemeRequest) GetSlug ¶
func (u *AccountUpdateThemeRequest) GetSlug() (value string, ok bool)
GetSlug returns value of Slug conditional field and boolean which is true if field was set.
func (*AccountUpdateThemeRequest) GetTitle ¶
func (u *AccountUpdateThemeRequest) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*AccountUpdateThemeRequest) SetDocument ¶
func (u *AccountUpdateThemeRequest) SetDocument(value InputDocumentClass)
SetDocument sets value of Document conditional field.
func (*AccountUpdateThemeRequest) SetSettings ¶
func (u *AccountUpdateThemeRequest) SetSettings(value InputThemeSettings)
SetSettings sets value of Settings conditional field.
func (*AccountUpdateThemeRequest) SetSlug ¶
func (u *AccountUpdateThemeRequest) SetSlug(value string)
SetSlug sets value of Slug conditional field.
func (*AccountUpdateThemeRequest) SetTitle ¶
func (u *AccountUpdateThemeRequest) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*AccountUpdateThemeRequest) String ¶ added in v0.12.0
func (u *AccountUpdateThemeRequest) String() string
String implements fmt.Stringer.
type AccountUpdateUsernameRequest ¶
type AccountUpdateUsernameRequest struct {
// username or empty string if username is to be removedAccepted characters: a-z (case-insensitive), 0-9 and underscores.Length: 5-32 characters.
Username string
}
AccountUpdateUsernameRequest represents TL type `account.updateUsername#3e0bdd7c`. Changes username for the current user.
See https://core.telegram.org/method/account.updateUsername for reference.
func (*AccountUpdateUsernameRequest) Decode ¶
func (u *AccountUpdateUsernameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUpdateUsernameRequest) Encode ¶
func (u *AccountUpdateUsernameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUpdateUsernameRequest) String ¶ added in v0.12.0
func (u *AccountUpdateUsernameRequest) String() string
String implements fmt.Stringer.
type AccountUploadThemeRequest ¶
type AccountUploadThemeRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Theme file uploaded as described in files »¹
//
// Links:
// 1) https://core.telegram.org/api/files
File InputFileClass
// Thumbnail
//
// Use SetThumb and GetThumb helpers.
Thumb InputFileClass
// File name
FileName string
// MIME type, must be application/x-tgtheme-{format}, where format depends on the client
MimeType string
}
AccountUploadThemeRequest represents TL type `account.uploadTheme#1c3db333`. Upload theme
See https://core.telegram.org/method/account.uploadTheme for reference.
func (*AccountUploadThemeRequest) Decode ¶
func (u *AccountUploadThemeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUploadThemeRequest) Encode ¶
func (u *AccountUploadThemeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUploadThemeRequest) GetThumb ¶
func (u *AccountUploadThemeRequest) GetThumb() (value InputFileClass, ok bool)
GetThumb returns value of Thumb conditional field and boolean which is true if field was set.
func (*AccountUploadThemeRequest) SetThumb ¶
func (u *AccountUploadThemeRequest) SetThumb(value InputFileClass)
SetThumb sets value of Thumb conditional field.
func (*AccountUploadThemeRequest) String ¶ added in v0.12.0
func (u *AccountUploadThemeRequest) String() string
String implements fmt.Stringer.
type AccountUploadWallPaperRequest ¶
type AccountUploadWallPaperRequest struct {
// The JPG/PNG wallpaper
File InputFileClass
// MIME type of uploaded wallpaper
MimeType string
// Wallpaper settings
Settings WallPaperSettings
}
AccountUploadWallPaperRequest represents TL type `account.uploadWallPaper#dd853661`. Create and upload a new wallpaper
See https://core.telegram.org/method/account.uploadWallPaper for reference.
func (*AccountUploadWallPaperRequest) Decode ¶
func (u *AccountUploadWallPaperRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountUploadWallPaperRequest) Encode ¶
func (u *AccountUploadWallPaperRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountUploadWallPaperRequest) String ¶ added in v0.12.0
func (u *AccountUploadWallPaperRequest) String() string
String implements fmt.Stringer.
type AccountVerifyEmailRequest ¶
type AccountVerifyEmailRequest struct {
// The email to verify
Email string
// The verification code that was received
Code string
}
AccountVerifyEmailRequest represents TL type `account.verifyEmail#ecba39db`. Verify an email address for telegram passport¹.
Links:
See https://core.telegram.org/method/account.verifyEmail for reference.
func (*AccountVerifyEmailRequest) Decode ¶
func (v *AccountVerifyEmailRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountVerifyEmailRequest) Encode ¶
func (v *AccountVerifyEmailRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountVerifyEmailRequest) String ¶ added in v0.12.0
func (v *AccountVerifyEmailRequest) String() string
String implements fmt.Stringer.
type AccountVerifyPhoneRequest ¶
type AccountVerifyPhoneRequest struct {
// Phone number
PhoneNumber string
// Phone code hash received from the call to account.sendVerifyPhoneCode¹
//
// Links:
// 1) https://core.telegram.org/method/account.sendVerifyPhoneCode
PhoneCodeHash string
// Code received after the call to account.sendVerifyPhoneCode¹
//
// Links:
// 1) https://core.telegram.org/method/account.sendVerifyPhoneCode
PhoneCode string
}
AccountVerifyPhoneRequest represents TL type `account.verifyPhone#4dd3a7f6`. Verify a phone number for telegram passport¹.
Links:
See https://core.telegram.org/method/account.verifyPhone for reference.
func (*AccountVerifyPhoneRequest) Decode ¶
func (v *AccountVerifyPhoneRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountVerifyPhoneRequest) Encode ¶
func (v *AccountVerifyPhoneRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountVerifyPhoneRequest) String ¶ added in v0.12.0
func (v *AccountVerifyPhoneRequest) String() string
String implements fmt.Stringer.
type AccountWallPapers ¶
type AccountWallPapers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Wallpapers
Wallpapers []WallPaperClass
}
AccountWallPapers represents TL type `account.wallPapers#702b65a9`. Installed wallpapers
See https://core.telegram.org/constructor/account.wallPapers for reference.
func (*AccountWallPapers) Decode ¶
func (w *AccountWallPapers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountWallPapers) Encode ¶
func (w *AccountWallPapers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountWallPapers) String ¶ added in v0.12.0
func (w *AccountWallPapers) String() string
String implements fmt.Stringer.
type AccountWallPapersBox ¶
type AccountWallPapersBox struct {
WallPapers AccountWallPapersClass
}
AccountWallPapers boxes the AccountWallPapersClass providing a helper.
type AccountWallPapersClass ¶
type AccountWallPapersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AccountWallPapersClass represents account.WallPapers generic type.
See https://core.telegram.org/type/account.WallPapers for reference.
Example:
g, err := DecodeAccountWallPapers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AccountWallPapersNotModified: // account.wallPapersNotModified#1c199183
case *AccountWallPapers: // account.wallPapers#702b65a9
default: panic(v)
}
func DecodeAccountWallPapers ¶
func DecodeAccountWallPapers(buf *bin.Buffer) (AccountWallPapersClass, error)
DecodeAccountWallPapers implements binary de-serialization for AccountWallPapersClass.
type AccountWallPapersNotModified ¶
type AccountWallPapersNotModified struct {
}
AccountWallPapersNotModified represents TL type `account.wallPapersNotModified#1c199183`. No new wallpapers were found
See https://core.telegram.org/constructor/account.wallPapersNotModified for reference.
func (*AccountWallPapersNotModified) Decode ¶
func (w *AccountWallPapersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountWallPapersNotModified) Encode ¶
func (w *AccountWallPapersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountWallPapersNotModified) String ¶ added in v0.12.0
func (w *AccountWallPapersNotModified) String() string
String implements fmt.Stringer.
type AccountWebAuthorizations ¶
type AccountWebAuthorizations struct {
// Web authorization list
Authorizations []WebAuthorization
// Users
Users []UserClass
}
AccountWebAuthorizations represents TL type `account.webAuthorizations#ed56c9fc`. Web authorizations
See https://core.telegram.org/constructor/account.webAuthorizations for reference.
func (*AccountWebAuthorizations) Decode ¶
func (w *AccountWebAuthorizations) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AccountWebAuthorizations) Encode ¶
func (w *AccountWebAuthorizations) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AccountWebAuthorizations) String ¶ added in v0.12.0
func (w *AccountWebAuthorizations) String() string
String implements fmt.Stringer.
type AuthAcceptLoginTokenRequest ¶
type AuthAcceptLoginTokenRequest struct {
// Login token embedded in QR code, for more info, see login via QR code¹.
//
// Links:
// 1) https://core.telegram.org/api/qr-login
Token []byte
}
AuthAcceptLoginTokenRequest represents TL type `auth.acceptLoginToken#e894ad4d`. Accept QR code login token, logging in the app that generated it. Returns info about the new session. For more info, see login via QR code¹.
Links:
See https://core.telegram.org/method/auth.acceptLoginToken for reference.
func (*AuthAcceptLoginTokenRequest) Decode ¶
func (a *AuthAcceptLoginTokenRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthAcceptLoginTokenRequest) Encode ¶
func (a *AuthAcceptLoginTokenRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthAcceptLoginTokenRequest) String ¶ added in v0.12.0
func (a *AuthAcceptLoginTokenRequest) String() string
String implements fmt.Stringer.
type AuthAuthorization ¶
type AuthAuthorization struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Temporary passport¹ sessions
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetTmpSessions and GetTmpSessions helpers.
TmpSessions int
// Info on authorized user
User UserClass
}
AuthAuthorization represents TL type `auth.authorization#cd050916`. Contains user authorization info.
See https://core.telegram.org/constructor/auth.authorization for reference.
func (*AuthAuthorization) Decode ¶
func (a *AuthAuthorization) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthAuthorization) Encode ¶
func (a *AuthAuthorization) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthAuthorization) GetTmpSessions ¶
func (a *AuthAuthorization) GetTmpSessions() (value int, ok bool)
GetTmpSessions returns value of TmpSessions conditional field and boolean which is true if field was set.
func (*AuthAuthorization) SetTmpSessions ¶
func (a *AuthAuthorization) SetTmpSessions(value int)
SetTmpSessions sets value of TmpSessions conditional field.
func (*AuthAuthorization) String ¶ added in v0.12.0
func (a *AuthAuthorization) String() string
String implements fmt.Stringer.
type AuthAuthorizationBox ¶
type AuthAuthorizationBox struct {
Authorization AuthAuthorizationClass
}
AuthAuthorization boxes the AuthAuthorizationClass providing a helper.
type AuthAuthorizationClass ¶
type AuthAuthorizationClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AuthAuthorizationClass represents auth.Authorization generic type.
See https://core.telegram.org/type/auth.Authorization for reference.
Example:
g, err := DecodeAuthAuthorization(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AuthAuthorization: // auth.authorization#cd050916
case *AuthAuthorizationSignUpRequired: // auth.authorizationSignUpRequired#44747e9a
default: panic(v)
}
func DecodeAuthAuthorization ¶
func DecodeAuthAuthorization(buf *bin.Buffer) (AuthAuthorizationClass, error)
DecodeAuthAuthorization implements binary de-serialization for AuthAuthorizationClass.
type AuthAuthorizationSignUpRequired ¶
type AuthAuthorizationSignUpRequired struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Telegram's terms of service: the user must read and accept the terms of service before signing up to telegram
//
// Use SetTermsOfService and GetTermsOfService helpers.
TermsOfService HelpTermsOfService
}
AuthAuthorizationSignUpRequired represents TL type `auth.authorizationSignUpRequired#44747e9a`. An account with this phone number doesn't exist on telegram: the user has to enter basic information and sign up¹
Links:
See https://core.telegram.org/constructor/auth.authorizationSignUpRequired for reference.
func (*AuthAuthorizationSignUpRequired) Decode ¶
func (a *AuthAuthorizationSignUpRequired) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthAuthorizationSignUpRequired) Encode ¶
func (a *AuthAuthorizationSignUpRequired) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthAuthorizationSignUpRequired) GetTermsOfService ¶
func (a *AuthAuthorizationSignUpRequired) GetTermsOfService() (value HelpTermsOfService, ok bool)
GetTermsOfService returns value of TermsOfService conditional field and boolean which is true if field was set.
func (*AuthAuthorizationSignUpRequired) SetTermsOfService ¶
func (a *AuthAuthorizationSignUpRequired) SetTermsOfService(value HelpTermsOfService)
SetTermsOfService sets value of TermsOfService conditional field.
func (*AuthAuthorizationSignUpRequired) String ¶ added in v0.12.0
func (a *AuthAuthorizationSignUpRequired) String() string
String implements fmt.Stringer.
type AuthBindTempAuthKeyRequest ¶
type AuthBindTempAuthKeyRequest struct {
// Permanent auth_key_id to bind to
PermAuthKeyID int64
// Random long from Binding message contents¹
//
// Links:
// 1) https://core.telegram.org#binding-message-contents
Nonce int64
// Unix timestamp to invalidate temporary key, see Binding message contents¹
//
// Links:
// 1) https://core.telegram.org#binding-message-contents
ExpiresAt int
// See Generating encrypted_message¹
//
// Links:
// 1) https://core.telegram.org#generating-encrypted-message
EncryptedMessage []byte
}
AuthBindTempAuthKeyRequest represents TL type `auth.bindTempAuthKey#cdd42a05`. Binds a temporary authorization key temp_auth_key_id to the permanent authorization key perm_auth_key_id. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one. For more information, see Perfect Forward Secrecy¹.
Links:
See https://core.telegram.org/method/auth.bindTempAuthKey for reference.
func (*AuthBindTempAuthKeyRequest) Decode ¶
func (b *AuthBindTempAuthKeyRequest) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthBindTempAuthKeyRequest) Encode ¶
func (b *AuthBindTempAuthKeyRequest) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthBindTempAuthKeyRequest) String ¶ added in v0.12.0
func (b *AuthBindTempAuthKeyRequest) String() string
String implements fmt.Stringer.
type AuthCancelCodeRequest ¶
type AuthCancelCodeRequest struct {
// Phone number
PhoneNumber string
// Phone code hash from auth.sendCode¹
//
// Links:
// 1) https://core.telegram.org/method/auth.sendCode
PhoneCodeHash string
}
AuthCancelCodeRequest represents TL type `auth.cancelCode#1f040578`. Cancel the login verification code
See https://core.telegram.org/method/auth.cancelCode for reference.
func (*AuthCancelCodeRequest) Decode ¶
func (c *AuthCancelCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthCancelCodeRequest) Encode ¶
func (c *AuthCancelCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthCancelCodeRequest) String ¶ added in v0.12.0
func (c *AuthCancelCodeRequest) String() string
String implements fmt.Stringer.
type AuthCheckPasswordRequest ¶
type AuthCheckPasswordRequest struct {
// The account's password (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
Password InputCheckPasswordSRPClass
}
AuthCheckPasswordRequest represents TL type `auth.checkPassword#d18b4d16`. Try logging to an account protected by a 2FA password¹.
Links:
See https://core.telegram.org/method/auth.checkPassword for reference.
func (*AuthCheckPasswordRequest) Decode ¶
func (c *AuthCheckPasswordRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthCheckPasswordRequest) Encode ¶
func (c *AuthCheckPasswordRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthCheckPasswordRequest) String ¶ added in v0.12.0
func (c *AuthCheckPasswordRequest) String() string
String implements fmt.Stringer.
type AuthCodeTypeBox ¶
type AuthCodeTypeBox struct {
CodeType AuthCodeTypeClass
}
AuthCodeType boxes the AuthCodeTypeClass providing a helper.
type AuthCodeTypeCall ¶
type AuthCodeTypeCall struct {
}
AuthCodeTypeCall represents TL type `auth.codeTypeCall#741cd3e3`. Type of verification code that will be sent next if you call the resendCode method: SMS code
See https://core.telegram.org/constructor/auth.codeTypeCall for reference.
func (*AuthCodeTypeCall) Decode ¶
func (c *AuthCodeTypeCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthCodeTypeCall) Encode ¶
func (c *AuthCodeTypeCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthCodeTypeCall) String ¶ added in v0.12.0
func (c *AuthCodeTypeCall) String() string
String implements fmt.Stringer.
type AuthCodeTypeClass ¶
type AuthCodeTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AuthCodeTypeClass represents auth.CodeType generic type.
See https://core.telegram.org/type/auth.CodeType for reference.
Example:
g, err := DecodeAuthCodeType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AuthCodeTypeSms: // auth.codeTypeSms#72a3158c
case *AuthCodeTypeCall: // auth.codeTypeCall#741cd3e3
case *AuthCodeTypeFlashCall: // auth.codeTypeFlashCall#226ccefb
default: panic(v)
}
func DecodeAuthCodeType ¶
func DecodeAuthCodeType(buf *bin.Buffer) (AuthCodeTypeClass, error)
DecodeAuthCodeType implements binary de-serialization for AuthCodeTypeClass.
type AuthCodeTypeFlashCall ¶
type AuthCodeTypeFlashCall struct {
}
AuthCodeTypeFlashCall represents TL type `auth.codeTypeFlashCall#226ccefb`. Type of verification code that will be sent next if you call the resendCode method: SMS code
See https://core.telegram.org/constructor/auth.codeTypeFlashCall for reference.
func (*AuthCodeTypeFlashCall) Decode ¶
func (c *AuthCodeTypeFlashCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthCodeTypeFlashCall) Encode ¶
func (c *AuthCodeTypeFlashCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthCodeTypeFlashCall) String ¶ added in v0.12.0
func (c *AuthCodeTypeFlashCall) String() string
String implements fmt.Stringer.
type AuthCodeTypeSms ¶
type AuthCodeTypeSms struct {
}
AuthCodeTypeSms represents TL type `auth.codeTypeSms#72a3158c`. Type of verification code that will be sent next if you call the resendCode method: SMS code
See https://core.telegram.org/constructor/auth.codeTypeSms for reference.
func (*AuthCodeTypeSms) Decode ¶
func (c *AuthCodeTypeSms) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthCodeTypeSms) Encode ¶
func (c *AuthCodeTypeSms) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthCodeTypeSms) String ¶ added in v0.12.0
func (c *AuthCodeTypeSms) String() string
String implements fmt.Stringer.
type AuthDropTempAuthKeysRequest ¶
type AuthDropTempAuthKeysRequest struct {
// The auth keys that shouldn't be dropped.
ExceptAuthKeys []int64
}
AuthDropTempAuthKeysRequest represents TL type `auth.dropTempAuthKeys#8e48a188`. Delete all temporary authorization keys except for the ones specified
See https://core.telegram.org/method/auth.dropTempAuthKeys for reference.
func (*AuthDropTempAuthKeysRequest) Decode ¶
func (d *AuthDropTempAuthKeysRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthDropTempAuthKeysRequest) Encode ¶
func (d *AuthDropTempAuthKeysRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthDropTempAuthKeysRequest) String ¶ added in v0.12.0
func (d *AuthDropTempAuthKeysRequest) String() string
String implements fmt.Stringer.
type AuthExportAuthorizationRequest ¶
type AuthExportAuthorizationRequest struct {
// Number of a target data-centre
DCID int
}
AuthExportAuthorizationRequest represents TL type `auth.exportAuthorization#e5bfffcd`. Returns data for copying authorization to another data-centre.
See https://core.telegram.org/method/auth.exportAuthorization for reference.
func (*AuthExportAuthorizationRequest) Decode ¶
func (e *AuthExportAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthExportAuthorizationRequest) Encode ¶
func (e *AuthExportAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthExportAuthorizationRequest) String ¶ added in v0.12.0
func (e *AuthExportAuthorizationRequest) String() string
String implements fmt.Stringer.
type AuthExportLoginTokenRequest ¶
type AuthExportLoginTokenRequest struct {
// Application identifier (see. App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIID int
// Application identifier hash (see. App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIHash string
// List of already logged-in user IDs, to prevent logging in twice with the same user
ExceptIds []int
}
AuthExportLoginTokenRequest represents TL type `auth.exportLoginToken#b1b41517`. Generate a login token, for login via QR code¹. The generated login token should be encoded using base64url, then shown as a tg://login?token=base64encodedtoken URL in the QR code. For more info, see login via QR code¹.
Links:
See https://core.telegram.org/method/auth.exportLoginToken for reference.
func (*AuthExportLoginTokenRequest) Decode ¶
func (e *AuthExportLoginTokenRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthExportLoginTokenRequest) Encode ¶
func (e *AuthExportLoginTokenRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthExportLoginTokenRequest) String ¶ added in v0.12.0
func (e *AuthExportLoginTokenRequest) String() string
String implements fmt.Stringer.
type AuthExportedAuthorization ¶
type AuthExportedAuthorization struct {
// current user identifier
ID int
// authorizes key
Bytes []byte
}
AuthExportedAuthorization represents TL type `auth.exportedAuthorization#df969c2d`. Data for copying of authorization between data centres.
See https://core.telegram.org/constructor/auth.exportedAuthorization for reference.
func (*AuthExportedAuthorization) Decode ¶
func (e *AuthExportedAuthorization) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthExportedAuthorization) Encode ¶
func (e *AuthExportedAuthorization) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthExportedAuthorization) String ¶ added in v0.12.0
func (e *AuthExportedAuthorization) String() string
String implements fmt.Stringer.
type AuthImportAuthorizationRequest ¶
AuthImportAuthorizationRequest represents TL type `auth.importAuthorization#e3ef9613`. Logs in a user using a key transmitted from his native data-centre.
See https://core.telegram.org/method/auth.importAuthorization for reference.
func (*AuthImportAuthorizationRequest) Decode ¶
func (i *AuthImportAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthImportAuthorizationRequest) Encode ¶
func (i *AuthImportAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthImportAuthorizationRequest) String ¶ added in v0.12.0
func (i *AuthImportAuthorizationRequest) String() string
String implements fmt.Stringer.
type AuthImportBotAuthorizationRequest ¶
type AuthImportBotAuthorizationRequest struct {
// Reserved for future use
Flags int
// Application identifier (see. App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIID int
// Application identifier hash (see. App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIHash string
// Bot token (see bots¹)
//
// Links:
// 1) https://core.telegram.org/bots
BotAuthToken string
}
AuthImportBotAuthorizationRequest represents TL type `auth.importBotAuthorization#67a3ff2c`. Login as a bot
See https://core.telegram.org/method/auth.importBotAuthorization for reference.
func (*AuthImportBotAuthorizationRequest) Decode ¶
func (i *AuthImportBotAuthorizationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthImportBotAuthorizationRequest) Encode ¶
func (i *AuthImportBotAuthorizationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthImportBotAuthorizationRequest) String ¶ added in v0.12.0
func (i *AuthImportBotAuthorizationRequest) String() string
String implements fmt.Stringer.
type AuthImportLoginTokenRequest ¶
type AuthImportLoginTokenRequest struct {
// Login token
Token []byte
}
AuthImportLoginTokenRequest represents TL type `auth.importLoginToken#95ac5ce4`. Login using a redirected login token, generated in case of DC mismatch during QR code login¹. For more info, see login via QR code¹.
Links:
See https://core.telegram.org/method/auth.importLoginToken for reference.
func (*AuthImportLoginTokenRequest) Decode ¶
func (i *AuthImportLoginTokenRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthImportLoginTokenRequest) Encode ¶
func (i *AuthImportLoginTokenRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthImportLoginTokenRequest) String ¶ added in v0.12.0
func (i *AuthImportLoginTokenRequest) String() string
String implements fmt.Stringer.
type AuthLogOutRequest ¶
type AuthLogOutRequest struct {
}
AuthLogOutRequest represents TL type `auth.logOut#5717da40`. Logs out the user.
See https://core.telegram.org/method/auth.logOut for reference.
func (*AuthLogOutRequest) Decode ¶
func (l *AuthLogOutRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthLogOutRequest) Encode ¶
func (l *AuthLogOutRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthLogOutRequest) String ¶ added in v0.12.0
func (l *AuthLogOutRequest) String() string
String implements fmt.Stringer.
type AuthLoginToken ¶
type AuthLoginToken struct {
// Expiry date of QR code
Expires int
// Token to render in QR code
Token []byte
}
AuthLoginToken represents TL type `auth.loginToken#629f1980`. Login token (for QR code login¹)
Links:
See https://core.telegram.org/constructor/auth.loginToken for reference.
func (*AuthLoginToken) Decode ¶
func (l *AuthLoginToken) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthLoginToken) Encode ¶
func (l *AuthLoginToken) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthLoginToken) String ¶ added in v0.12.0
func (l *AuthLoginToken) String() string
String implements fmt.Stringer.
type AuthLoginTokenBox ¶
type AuthLoginTokenBox struct {
LoginToken AuthLoginTokenClass
}
AuthLoginToken boxes the AuthLoginTokenClass providing a helper.
type AuthLoginTokenClass ¶
type AuthLoginTokenClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AuthLoginTokenClass represents auth.LoginToken generic type.
See https://core.telegram.org/type/auth.LoginToken for reference.
Example:
g, err := DecodeAuthLoginToken(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AuthLoginToken: // auth.loginToken#629f1980
case *AuthLoginTokenMigrateTo: // auth.loginTokenMigrateTo#68e9916
case *AuthLoginTokenSuccess: // auth.loginTokenSuccess#390d5c5e
default: panic(v)
}
func DecodeAuthLoginToken ¶
func DecodeAuthLoginToken(buf *bin.Buffer) (AuthLoginTokenClass, error)
DecodeAuthLoginToken implements binary de-serialization for AuthLoginTokenClass.
type AuthLoginTokenMigrateTo ¶
AuthLoginTokenMigrateTo represents TL type `auth.loginTokenMigrateTo#68e9916`. Repeat the query to the specified DC
See https://core.telegram.org/constructor/auth.loginTokenMigrateTo for reference.
func (*AuthLoginTokenMigrateTo) Decode ¶
func (l *AuthLoginTokenMigrateTo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthLoginTokenMigrateTo) Encode ¶
func (l *AuthLoginTokenMigrateTo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthLoginTokenMigrateTo) String ¶ added in v0.12.0
func (l *AuthLoginTokenMigrateTo) String() string
String implements fmt.Stringer.
type AuthLoginTokenSuccess ¶
type AuthLoginTokenSuccess struct {
// Authorization info
Authorization AuthAuthorizationClass
}
AuthLoginTokenSuccess represents TL type `auth.loginTokenSuccess#390d5c5e`. Login via token (QR code) succeded!
See https://core.telegram.org/constructor/auth.loginTokenSuccess for reference.
func (*AuthLoginTokenSuccess) Decode ¶
func (l *AuthLoginTokenSuccess) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthLoginTokenSuccess) Encode ¶
func (l *AuthLoginTokenSuccess) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthLoginTokenSuccess) String ¶ added in v0.12.0
func (l *AuthLoginTokenSuccess) String() string
String implements fmt.Stringer.
type AuthPasswordRecovery ¶
type AuthPasswordRecovery struct {
// The email to which the recovery code was sent must match this pattern¹.
//
// Links:
// 1) https://core.telegram.org/api/pattern
EmailPattern string
}
AuthPasswordRecovery represents TL type `auth.passwordRecovery#137948a5`. Recovery info of a 2FA password¹, only for accounts with a recovery email configured².
Links:
See https://core.telegram.org/constructor/auth.passwordRecovery for reference.
func (*AuthPasswordRecovery) Decode ¶
func (p *AuthPasswordRecovery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthPasswordRecovery) Encode ¶
func (p *AuthPasswordRecovery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthPasswordRecovery) String ¶ added in v0.12.0
func (p *AuthPasswordRecovery) String() string
String implements fmt.Stringer.
type AuthRecoverPasswordRequest ¶
type AuthRecoverPasswordRequest struct {
// Code received via email
Code string
}
AuthRecoverPasswordRequest represents TL type `auth.recoverPassword#4ea56e92`. Reset the 2FA password¹ using the recovery code sent using auth.requestPasswordRecovery².
Links:
See https://core.telegram.org/method/auth.recoverPassword for reference.
func (*AuthRecoverPasswordRequest) Decode ¶
func (r *AuthRecoverPasswordRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthRecoverPasswordRequest) Encode ¶
func (r *AuthRecoverPasswordRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthRecoverPasswordRequest) String ¶ added in v0.12.0
func (r *AuthRecoverPasswordRequest) String() string
String implements fmt.Stringer.
type AuthRequestPasswordRecoveryRequest ¶
type AuthRequestPasswordRecoveryRequest struct {
}
AuthRequestPasswordRecoveryRequest represents TL type `auth.requestPasswordRecovery#d897bc66`. Request recovery code of a 2FA password¹, only for accounts with a recovery email configured².
Links:
See https://core.telegram.org/method/auth.requestPasswordRecovery for reference.
func (*AuthRequestPasswordRecoveryRequest) Decode ¶
func (r *AuthRequestPasswordRecoveryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthRequestPasswordRecoveryRequest) Encode ¶
func (r *AuthRequestPasswordRecoveryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthRequestPasswordRecoveryRequest) String ¶ added in v0.12.0
func (r *AuthRequestPasswordRecoveryRequest) String() string
String implements fmt.Stringer.
type AuthResendCodeRequest ¶
type AuthResendCodeRequest struct {
// The phone number
PhoneNumber string
// The phone code hash obtained from auth.sendCode¹
//
// Links:
// 1) https://core.telegram.org/method/auth.sendCode
PhoneCodeHash string
}
AuthResendCodeRequest represents TL type `auth.resendCode#3ef1a9bf`. Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see login¹ for more info.
Links:
See https://core.telegram.org/method/auth.resendCode for reference.
func (*AuthResendCodeRequest) Decode ¶
func (r *AuthResendCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthResendCodeRequest) Encode ¶
func (r *AuthResendCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthResendCodeRequest) String ¶ added in v0.12.0
func (r *AuthResendCodeRequest) String() string
String implements fmt.Stringer.
type AuthResetAuthorizationsRequest ¶
type AuthResetAuthorizationsRequest struct {
}
AuthResetAuthorizationsRequest represents TL type `auth.resetAuthorizations#9fab0d1a`. Terminates all user's authorized sessions except for the current one. After calling this method it is necessary to reregister the current device using the method account.registerDevice¹
Links:
See https://core.telegram.org/method/auth.resetAuthorizations for reference.
func (*AuthResetAuthorizationsRequest) Decode ¶
func (r *AuthResetAuthorizationsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthResetAuthorizationsRequest) Encode ¶
func (r *AuthResetAuthorizationsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthResetAuthorizationsRequest) String ¶ added in v0.12.0
func (r *AuthResetAuthorizationsRequest) String() string
String implements fmt.Stringer.
type AuthSendCodeRequest ¶
type AuthSendCodeRequest struct {
// Phone number in international format
PhoneNumber string
// Application identifier (see App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIID int
// Application secret hash (see App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIHash string
// Settings for the code type to send
Settings CodeSettings
}
AuthSendCodeRequest represents TL type `auth.sendCode#a677244f`. Send the verification code for login
See https://core.telegram.org/method/auth.sendCode for reference.
func (*AuthSendCodeRequest) Decode ¶
func (s *AuthSendCodeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSendCodeRequest) Encode ¶
func (s *AuthSendCodeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSendCodeRequest) String ¶ added in v0.12.0
func (s *AuthSendCodeRequest) String() string
String implements fmt.Stringer.
type AuthSentCode ¶
type AuthSentCode struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Phone code type
Type AuthSentCodeTypeClass
// Phone code hash, to be stored and later re-used with auth.signIn¹
//
// Links:
// 1) https://core.telegram.org/method/auth.signIn
PhoneCodeHash string
// Phone code type that will be sent next, if the phone code is not received within timeout seconds: to send it use auth.resendCode¹
//
// Links:
// 1) https://core.telegram.org/method/auth.resendCode
//
// Use SetNextType and GetNextType helpers.
NextType AuthCodeTypeClass
// Timeout for reception of the phone code
//
// Use SetTimeout and GetTimeout helpers.
Timeout int
}
AuthSentCode represents TL type `auth.sentCode#5e002502`. Contains info about a sent verification code.
See https://core.telegram.org/constructor/auth.sentCode for reference.
func (*AuthSentCode) Decode ¶
func (s *AuthSentCode) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSentCode) Encode ¶
func (s *AuthSentCode) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSentCode) GetNextType ¶
func (s *AuthSentCode) GetNextType() (value AuthCodeTypeClass, ok bool)
GetNextType returns value of NextType conditional field and boolean which is true if field was set.
func (*AuthSentCode) GetTimeout ¶
func (s *AuthSentCode) GetTimeout() (value int, ok bool)
GetTimeout returns value of Timeout conditional field and boolean which is true if field was set.
func (*AuthSentCode) SetNextType ¶
func (s *AuthSentCode) SetNextType(value AuthCodeTypeClass)
SetNextType sets value of NextType conditional field.
func (*AuthSentCode) SetTimeout ¶
func (s *AuthSentCode) SetTimeout(value int)
SetTimeout sets value of Timeout conditional field.
func (*AuthSentCode) String ¶ added in v0.12.0
func (s *AuthSentCode) String() string
String implements fmt.Stringer.
type AuthSentCodeTypeApp ¶
type AuthSentCodeTypeApp struct {
// Length of the code in bytes
Length int
}
AuthSentCodeTypeApp represents TL type `auth.sentCodeTypeApp#3dbb5986`. The code was sent through the telegram app
See https://core.telegram.org/constructor/auth.sentCodeTypeApp for reference.
func (*AuthSentCodeTypeApp) Decode ¶
func (s *AuthSentCodeTypeApp) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSentCodeTypeApp) Encode ¶
func (s *AuthSentCodeTypeApp) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSentCodeTypeApp) String ¶ added in v0.12.0
func (s *AuthSentCodeTypeApp) String() string
String implements fmt.Stringer.
type AuthSentCodeTypeBox ¶
type AuthSentCodeTypeBox struct {
SentCodeType AuthSentCodeTypeClass
}
AuthSentCodeType boxes the AuthSentCodeTypeClass providing a helper.
type AuthSentCodeTypeCall ¶
type AuthSentCodeTypeCall struct {
// Length of the verification code
Length int
}
AuthSentCodeTypeCall represents TL type `auth.sentCodeTypeCall#5353e5a7`. The code will be sent via a phone call: a synthesized voice will tell the user which verification code to input.
See https://core.telegram.org/constructor/auth.sentCodeTypeCall for reference.
func (*AuthSentCodeTypeCall) Decode ¶
func (s *AuthSentCodeTypeCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSentCodeTypeCall) Encode ¶
func (s *AuthSentCodeTypeCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSentCodeTypeCall) String ¶ added in v0.12.0
func (s *AuthSentCodeTypeCall) String() string
String implements fmt.Stringer.
type AuthSentCodeTypeClass ¶
type AuthSentCodeTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
AuthSentCodeTypeClass represents auth.SentCodeType generic type.
See https://core.telegram.org/type/auth.SentCodeType for reference.
Example:
g, err := DecodeAuthSentCodeType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *AuthSentCodeTypeApp: // auth.sentCodeTypeApp#3dbb5986
case *AuthSentCodeTypeSms: // auth.sentCodeTypeSms#c000bba2
case *AuthSentCodeTypeCall: // auth.sentCodeTypeCall#5353e5a7
case *AuthSentCodeTypeFlashCall: // auth.sentCodeTypeFlashCall#ab03c6d9
default: panic(v)
}
func DecodeAuthSentCodeType ¶
func DecodeAuthSentCodeType(buf *bin.Buffer) (AuthSentCodeTypeClass, error)
DecodeAuthSentCodeType implements binary de-serialization for AuthSentCodeTypeClass.
type AuthSentCodeTypeFlashCall ¶
type AuthSentCodeTypeFlashCall struct {
// pattern¹ to match
//
// Links:
// 1) https://core.telegram.org/api/pattern
Pattern string
}
AuthSentCodeTypeFlashCall represents TL type `auth.sentCodeTypeFlashCall#ab03c6d9`. The code will be sent via a flash phone call, that will be closed immediately. The phone code will then be the phone number itself, just make sure that the phone number matches the specified pattern.
See https://core.telegram.org/constructor/auth.sentCodeTypeFlashCall for reference.
func (*AuthSentCodeTypeFlashCall) Decode ¶
func (s *AuthSentCodeTypeFlashCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSentCodeTypeFlashCall) Encode ¶
func (s *AuthSentCodeTypeFlashCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSentCodeTypeFlashCall) String ¶ added in v0.12.0
func (s *AuthSentCodeTypeFlashCall) String() string
String implements fmt.Stringer.
type AuthSentCodeTypeSms ¶
type AuthSentCodeTypeSms struct {
// Length of the code in bytes
Length int
}
AuthSentCodeTypeSms represents TL type `auth.sentCodeTypeSms#c000bba2`. The code was sent via SMS
See https://core.telegram.org/constructor/auth.sentCodeTypeSms for reference.
func (*AuthSentCodeTypeSms) Decode ¶
func (s *AuthSentCodeTypeSms) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSentCodeTypeSms) Encode ¶
func (s *AuthSentCodeTypeSms) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSentCodeTypeSms) String ¶ added in v0.12.0
func (s *AuthSentCodeTypeSms) String() string
String implements fmt.Stringer.
type AuthSignInRequest ¶
type AuthSignInRequest struct {
// Phone number in the international format
PhoneNumber string
// SMS-message ID, obtained from auth.sendCode¹
//
// Links:
// 1) https://core.telegram.org/method/auth.sendCode
PhoneCodeHash string
// Valid numerical code from the SMS-message
PhoneCode string
}
AuthSignInRequest represents TL type `auth.signIn#bcd51581`. Signs in a user with a validated phone number.
See https://core.telegram.org/method/auth.signIn for reference.
func (*AuthSignInRequest) Decode ¶
func (s *AuthSignInRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSignInRequest) Encode ¶
func (s *AuthSignInRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSignInRequest) String ¶ added in v0.12.0
func (s *AuthSignInRequest) String() string
String implements fmt.Stringer.
type AuthSignUpRequest ¶
type AuthSignUpRequest struct {
// Phone number in the international format
PhoneNumber string
// SMS-message ID
PhoneCodeHash string
// New user first name
FirstName string
// New user last name
LastName string
}
AuthSignUpRequest represents TL type `auth.signUp#80eee427`. Registers a validated phone number in the system.
See https://core.telegram.org/method/auth.signUp for reference.
func (*AuthSignUpRequest) Decode ¶
func (s *AuthSignUpRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AuthSignUpRequest) Encode ¶
func (s *AuthSignUpRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AuthSignUpRequest) String ¶ added in v0.12.0
func (s *AuthSignUpRequest) String() string
String implements fmt.Stringer.
type Authorization ¶
type Authorization struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is the current session
Current bool
// Whether the session is from an official app
OfficialApp bool
// Whether the session is still waiting for a 2FA password
PasswordPending bool
// Identifier
Hash int64
// Device model
DeviceModel string
// Platform
Platform string
// System version
SystemVersion string
// API ID¹
//
// Links:
// 1) https://core.telegram.org/api/obtaining_api_id
APIID int
// App name
AppName string
// App version
AppVersion string
// When was the session created
DateCreated int
// When was the session last active
DateActive int
// Last known IP
IP string
// Country determined from IP
Country string
// Region determined from IP
Region string
}
Authorization represents TL type `authorization#ad01d61d`. Logged-in session
See https://core.telegram.org/constructor/authorization for reference.
func (*Authorization) Decode ¶
func (a *Authorization) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*Authorization) Encode ¶
func (a *Authorization) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*Authorization) SetCurrent ¶
func (a *Authorization) SetCurrent(value bool)
SetCurrent sets value of Current conditional field.
func (*Authorization) SetOfficialApp ¶
func (a *Authorization) SetOfficialApp(value bool)
SetOfficialApp sets value of OfficialApp conditional field.
func (*Authorization) SetPasswordPending ¶
func (a *Authorization) SetPasswordPending(value bool)
SetPasswordPending sets value of PasswordPending conditional field.
func (*Authorization) String ¶ added in v0.12.0
func (a *Authorization) String() string
String implements fmt.Stringer.
type AutoDownloadSettings ¶
type AutoDownloadSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable automatic media downloads?
Disabled bool
// Whether to preload the first seconds of videos larger than the specified limit
VideoPreloadLarge bool
// Whether to preload the next audio track when you're listening to music
AudioPreloadNext bool
// Whether to enable data saving mode in phone calls
PhonecallsLessData bool
// Maximum size of photos to preload
PhotoSizeMax int
// Maximum size of videos to preload
VideoSizeMax int
// Maximum size of other files to preload
FileSizeMax int
// Maximum suggested bitrate for uploading videos
VideoUploadMaxbitrate int
}
AutoDownloadSettings represents TL type `autoDownloadSettings#e04232f3`. Autodownload settings
See https://core.telegram.org/constructor/autoDownloadSettings for reference.
func (*AutoDownloadSettings) Decode ¶
func (a *AutoDownloadSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*AutoDownloadSettings) Encode ¶
func (a *AutoDownloadSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*AutoDownloadSettings) SetAudioPreloadNext ¶
func (a *AutoDownloadSettings) SetAudioPreloadNext(value bool)
SetAudioPreloadNext sets value of AudioPreloadNext conditional field.
func (*AutoDownloadSettings) SetDisabled ¶
func (a *AutoDownloadSettings) SetDisabled(value bool)
SetDisabled sets value of Disabled conditional field.
func (*AutoDownloadSettings) SetPhonecallsLessData ¶
func (a *AutoDownloadSettings) SetPhonecallsLessData(value bool)
SetPhonecallsLessData sets value of PhonecallsLessData conditional field.
func (*AutoDownloadSettings) SetVideoPreloadLarge ¶
func (a *AutoDownloadSettings) SetVideoPreloadLarge(value bool)
SetVideoPreloadLarge sets value of VideoPreloadLarge conditional field.
func (*AutoDownloadSettings) String ¶ added in v0.12.0
func (a *AutoDownloadSettings) String() string
String implements fmt.Stringer.
type BankCardOpenUrl ¶
BankCardOpenUrl represents TL type `bankCardOpenUrl#f568028a`. Credit card info URL provided by the bank
See https://core.telegram.org/constructor/bankCardOpenUrl for reference.
func (*BankCardOpenUrl) Decode ¶
func (b *BankCardOpenUrl) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BankCardOpenUrl) Encode ¶
func (b *BankCardOpenUrl) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BankCardOpenUrl) String ¶ added in v0.12.0
func (b *BankCardOpenUrl) String() string
String implements fmt.Stringer.
type BaseThemeArctic ¶
type BaseThemeArctic struct {
}
BaseThemeArctic represents TL type `baseThemeArctic#5b11125a`. Arctic theme
See https://core.telegram.org/constructor/baseThemeArctic for reference.
func (*BaseThemeArctic) Decode ¶
func (b *BaseThemeArctic) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BaseThemeArctic) Encode ¶
func (b *BaseThemeArctic) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BaseThemeArctic) String ¶ added in v0.12.0
func (b *BaseThemeArctic) String() string
String implements fmt.Stringer.
type BaseThemeBox ¶
type BaseThemeBox struct {
BaseTheme BaseThemeClass
}
BaseTheme boxes the BaseThemeClass providing a helper.
type BaseThemeClass ¶
type BaseThemeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
BaseThemeClass represents BaseTheme generic type.
See https://core.telegram.org/type/BaseTheme for reference.
Example:
g, err := DecodeBaseTheme(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *BaseThemeClassic: // baseThemeClassic#c3a12462
case *BaseThemeDay: // baseThemeDay#fbd81688
case *BaseThemeNight: // baseThemeNight#b7b31ea8
case *BaseThemeTinted: // baseThemeTinted#6d5f77ee
case *BaseThemeArctic: // baseThemeArctic#5b11125a
default: panic(v)
}
func DecodeBaseTheme ¶
func DecodeBaseTheme(buf *bin.Buffer) (BaseThemeClass, error)
DecodeBaseTheme implements binary de-serialization for BaseThemeClass.
type BaseThemeClassic ¶
type BaseThemeClassic struct {
}
BaseThemeClassic represents TL type `baseThemeClassic#c3a12462`. Classic theme
See https://core.telegram.org/constructor/baseThemeClassic for reference.
func (*BaseThemeClassic) Decode ¶
func (b *BaseThemeClassic) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BaseThemeClassic) Encode ¶
func (b *BaseThemeClassic) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BaseThemeClassic) String ¶ added in v0.12.0
func (b *BaseThemeClassic) String() string
String implements fmt.Stringer.
type BaseThemeDay ¶
type BaseThemeDay struct {
}
BaseThemeDay represents TL type `baseThemeDay#fbd81688`. Day theme
See https://core.telegram.org/constructor/baseThemeDay for reference.
func (*BaseThemeDay) Decode ¶
func (b *BaseThemeDay) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BaseThemeDay) Encode ¶
func (b *BaseThemeDay) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BaseThemeDay) String ¶ added in v0.12.0
func (b *BaseThemeDay) String() string
String implements fmt.Stringer.
type BaseThemeNight ¶
type BaseThemeNight struct {
}
BaseThemeNight represents TL type `baseThemeNight#b7b31ea8`. Night theme
See https://core.telegram.org/constructor/baseThemeNight for reference.
func (*BaseThemeNight) Decode ¶
func (b *BaseThemeNight) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BaseThemeNight) Encode ¶
func (b *BaseThemeNight) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BaseThemeNight) String ¶ added in v0.12.0
func (b *BaseThemeNight) String() string
String implements fmt.Stringer.
type BaseThemeTinted ¶
type BaseThemeTinted struct {
}
BaseThemeTinted represents TL type `baseThemeTinted#6d5f77ee`. Tinted theme
See https://core.telegram.org/constructor/baseThemeTinted for reference.
func (*BaseThemeTinted) Decode ¶
func (b *BaseThemeTinted) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BaseThemeTinted) Encode ¶
func (b *BaseThemeTinted) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BaseThemeTinted) String ¶ added in v0.12.0
func (b *BaseThemeTinted) String() string
String implements fmt.Stringer.
type BoolBox ¶
type BoolBox struct {
Bool BoolClass
}
Bool boxes the BoolClass providing a helper.
type BoolClass ¶
type BoolClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
BoolClass represents Bool generic type.
See https://core.telegram.org/type/Bool for reference.
Example:
g, err := DecodeBool(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *BoolFalse: // boolFalse#bc799737
case *BoolTrue: // boolTrue#997275b5
default: panic(v)
}
type BoolFalse ¶
type BoolFalse struct {
}
BoolFalse represents TL type `boolFalse#bc799737`. Constructor may be interpreted as a booleanfalse value.
See https://core.telegram.org/constructor/boolFalse for reference.
type BoolTrue ¶
type BoolTrue struct {
}
BoolTrue represents TL type `boolTrue#997275b5`. The constructor can be interpreted as a booleantrue value.
See https://core.telegram.org/constructor/boolTrue for reference.
type BotCallbackQueryHandler ¶ added in v0.9.0
type BotCallbackQueryHandler func(ctx UpdateContext, update *UpdateBotCallbackQuery) error
BotCallbackQueryHandler is a BotCallbackQuery event handler.
type BotCommand ¶
type BotCommand struct {
// /command name
Command string
// Description of the command
Description string
}
BotCommand represents TL type `botCommand#c27ac8c7`. Describes a bot command that can be used in a chat
See https://core.telegram.org/constructor/botCommand for reference.
func (*BotCommand) Decode ¶
func (b *BotCommand) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotCommand) Encode ¶
func (b *BotCommand) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotCommand) String ¶ added in v0.12.0
func (b *BotCommand) String() string
String implements fmt.Stringer.
type BotInfo ¶
type BotInfo struct {
// ID of the bot
UserID int
// Description of the bot
Description string
// Bot commands that can be used in the chat
Commands []BotCommand
}
BotInfo represents TL type `botInfo#98e81d3a`. Info about bots (available bot commands, etc)
See https://core.telegram.org/constructor/botInfo for reference.
type BotInlineMediaResult ¶
type BotInlineMediaResult struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Result ID
ID string
// Result type (see bot API docs¹)
//
// Links:
// 1) https://core.telegram.org/bots/api#inlinequeryresult
Type string
// If type is photo, the photo to send
//
// Use SetPhoto and GetPhoto helpers.
Photo PhotoClass
// If type is document, the document to send
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
// Result title
//
// Use SetTitle and GetTitle helpers.
Title string
// Description
//
// Use SetDescription and GetDescription helpers.
Description string
// Depending on the type and on the constructor¹, contains the caption of the media or the content of the message to be sent instead of the media
//
// Links:
// 1) https://core.telegram.org/type/BotInlineMessage
SendMessage BotInlineMessageClass
}
BotInlineMediaResult represents TL type `botInlineMediaResult#17db940b`. Media result
See https://core.telegram.org/constructor/botInlineMediaResult for reference.
func (*BotInlineMediaResult) Decode ¶
func (b *BotInlineMediaResult) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMediaResult) Encode ¶
func (b *BotInlineMediaResult) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMediaResult) GetDescription ¶
func (b *BotInlineMediaResult) GetDescription() (value string, ok bool)
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*BotInlineMediaResult) GetDocument ¶
func (b *BotInlineMediaResult) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*BotInlineMediaResult) GetPhoto ¶
func (b *BotInlineMediaResult) GetPhoto() (value PhotoClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*BotInlineMediaResult) GetTitle ¶
func (b *BotInlineMediaResult) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*BotInlineMediaResult) SetDescription ¶
func (b *BotInlineMediaResult) SetDescription(value string)
SetDescription sets value of Description conditional field.
func (*BotInlineMediaResult) SetDocument ¶
func (b *BotInlineMediaResult) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
func (*BotInlineMediaResult) SetPhoto ¶
func (b *BotInlineMediaResult) SetPhoto(value PhotoClass)
SetPhoto sets value of Photo conditional field.
func (*BotInlineMediaResult) SetTitle ¶
func (b *BotInlineMediaResult) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*BotInlineMediaResult) String ¶ added in v0.12.0
func (b *BotInlineMediaResult) String() string
String implements fmt.Stringer.
type BotInlineMessageBox ¶
type BotInlineMessageBox struct {
BotInlineMessage BotInlineMessageClass
}
BotInlineMessage boxes the BotInlineMessageClass providing a helper.
type BotInlineMessageClass ¶
type BotInlineMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
BotInlineMessageClass represents BotInlineMessage generic type.
See https://core.telegram.org/type/BotInlineMessage for reference.
Example:
g, err := DecodeBotInlineMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *BotInlineMessageMediaAuto: // botInlineMessageMediaAuto#764cf810
case *BotInlineMessageText: // botInlineMessageText#8c7f65e2
case *BotInlineMessageMediaGeo: // botInlineMessageMediaGeo#51846fd
case *BotInlineMessageMediaVenue: // botInlineMessageMediaVenue#8a86659c
case *BotInlineMessageMediaContact: // botInlineMessageMediaContact#18d1cdc2
default: panic(v)
}
func DecodeBotInlineMessage ¶
func DecodeBotInlineMessage(buf *bin.Buffer) (BotInlineMessageClass, error)
DecodeBotInlineMessage implements binary de-serialization for BotInlineMessageClass.
type BotInlineMessageMediaAuto ¶
type BotInlineMessageMediaAuto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Caption
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
BotInlineMessageMediaAuto represents TL type `botInlineMessageMediaAuto#764cf810`. Send whatever media is attached to the botInlineMediaResult¹
Links:
See https://core.telegram.org/constructor/botInlineMessageMediaAuto for reference.
func (*BotInlineMessageMediaAuto) Decode ¶
func (b *BotInlineMessageMediaAuto) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMessageMediaAuto) Encode ¶
func (b *BotInlineMessageMediaAuto) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMessageMediaAuto) GetEntities ¶
func (b *BotInlineMessageMediaAuto) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaAuto) GetReplyMarkup ¶
func (b *BotInlineMessageMediaAuto) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaAuto) SetEntities ¶
func (b *BotInlineMessageMediaAuto) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*BotInlineMessageMediaAuto) SetReplyMarkup ¶
func (b *BotInlineMessageMediaAuto) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*BotInlineMessageMediaAuto) String ¶ added in v0.12.0
func (b *BotInlineMessageMediaAuto) String() string
String implements fmt.Stringer.
type BotInlineMessageMediaContact ¶
type BotInlineMessageMediaContact struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Phone number
PhoneNumber string
// First name
FirstName string
// Last name
LastName string
// VCard info
Vcard string
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
BotInlineMessageMediaContact represents TL type `botInlineMessageMediaContact#18d1cdc2`. Send a contact
See https://core.telegram.org/constructor/botInlineMessageMediaContact for reference.
func (*BotInlineMessageMediaContact) Decode ¶
func (b *BotInlineMessageMediaContact) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMessageMediaContact) Encode ¶
func (b *BotInlineMessageMediaContact) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMessageMediaContact) GetReplyMarkup ¶
func (b *BotInlineMessageMediaContact) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaContact) SetReplyMarkup ¶
func (b *BotInlineMessageMediaContact) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*BotInlineMessageMediaContact) String ¶ added in v0.12.0
func (b *BotInlineMessageMediaContact) String() string
String implements fmt.Stringer.
type BotInlineMessageMediaGeo ¶
type BotInlineMessageMediaGeo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Geolocation
Geo GeoPointClass
// For live locations¹, a direction in which the location moves, in degrees; 1-360.
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetHeading and GetHeading helpers.
Heading int
// Validity period
//
// Use SetPeriod and GetPeriod helpers.
Period int
// For live locations¹, a maximum distance to another chat member for proximity alerts, in meters (0-100000).
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetProximityNotificationRadius and GetProximityNotificationRadius helpers.
ProximityNotificationRadius int
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
BotInlineMessageMediaGeo represents TL type `botInlineMessageMediaGeo#51846fd`. Send a geolocation
See https://core.telegram.org/constructor/botInlineMessageMediaGeo for reference.
func (*BotInlineMessageMediaGeo) Decode ¶
func (b *BotInlineMessageMediaGeo) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMessageMediaGeo) Encode ¶
func (b *BotInlineMessageMediaGeo) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMessageMediaGeo) GetHeading ¶
func (b *BotInlineMessageMediaGeo) GetHeading() (value int, ok bool)
GetHeading returns value of Heading conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaGeo) GetPeriod ¶
func (b *BotInlineMessageMediaGeo) GetPeriod() (value int, ok bool)
GetPeriod returns value of Period conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaGeo) GetProximityNotificationRadius ¶
func (b *BotInlineMessageMediaGeo) GetProximityNotificationRadius() (value int, ok bool)
GetProximityNotificationRadius returns value of ProximityNotificationRadius conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaGeo) GetReplyMarkup ¶
func (b *BotInlineMessageMediaGeo) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaGeo) SetHeading ¶
func (b *BotInlineMessageMediaGeo) SetHeading(value int)
SetHeading sets value of Heading conditional field.
func (*BotInlineMessageMediaGeo) SetPeriod ¶
func (b *BotInlineMessageMediaGeo) SetPeriod(value int)
SetPeriod sets value of Period conditional field.
func (*BotInlineMessageMediaGeo) SetProximityNotificationRadius ¶
func (b *BotInlineMessageMediaGeo) SetProximityNotificationRadius(value int)
SetProximityNotificationRadius sets value of ProximityNotificationRadius conditional field.
func (*BotInlineMessageMediaGeo) SetReplyMarkup ¶
func (b *BotInlineMessageMediaGeo) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*BotInlineMessageMediaGeo) String ¶ added in v0.12.0
func (b *BotInlineMessageMediaGeo) String() string
String implements fmt.Stringer.
type BotInlineMessageMediaVenue ¶
type BotInlineMessageMediaVenue struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Geolocation of venue
Geo GeoPointClass
// Venue name
Title string
// Address
Address string
// Venue provider: currently only "foursquare" needs to be supported
Provider string
// Venue ID in the provider's database
VenueID string
// Venue type in the provider's database
VenueType string
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
BotInlineMessageMediaVenue represents TL type `botInlineMessageMediaVenue#8a86659c`. Send a venue
See https://core.telegram.org/constructor/botInlineMessageMediaVenue for reference.
func (*BotInlineMessageMediaVenue) Decode ¶
func (b *BotInlineMessageMediaVenue) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMessageMediaVenue) Encode ¶
func (b *BotInlineMessageMediaVenue) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMessageMediaVenue) GetReplyMarkup ¶
func (b *BotInlineMessageMediaVenue) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*BotInlineMessageMediaVenue) SetReplyMarkup ¶
func (b *BotInlineMessageMediaVenue) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*BotInlineMessageMediaVenue) String ¶ added in v0.12.0
func (b *BotInlineMessageMediaVenue) String() string
String implements fmt.Stringer.
type BotInlineMessageText ¶
type BotInlineMessageText struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable webpage preview
NoWebpage bool
// The message
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
BotInlineMessageText represents TL type `botInlineMessageText#8c7f65e2`. Send a simple text message
See https://core.telegram.org/constructor/botInlineMessageText for reference.
func (*BotInlineMessageText) Decode ¶
func (b *BotInlineMessageText) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineMessageText) Encode ¶
func (b *BotInlineMessageText) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineMessageText) GetEntities ¶
func (b *BotInlineMessageText) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*BotInlineMessageText) GetReplyMarkup ¶
func (b *BotInlineMessageText) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*BotInlineMessageText) SetEntities ¶
func (b *BotInlineMessageText) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*BotInlineMessageText) SetNoWebpage ¶
func (b *BotInlineMessageText) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*BotInlineMessageText) SetReplyMarkup ¶
func (b *BotInlineMessageText) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*BotInlineMessageText) String ¶ added in v0.12.0
func (b *BotInlineMessageText) String() string
String implements fmt.Stringer.
type BotInlineQueryHandler ¶ added in v0.9.0
type BotInlineQueryHandler func(ctx UpdateContext, update *UpdateBotInlineQuery) error
BotInlineQueryHandler is a BotInlineQuery event handler.
type BotInlineResult ¶
type BotInlineResult struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Result ID
ID string
// Result type (see bot API docs¹)
//
// Links:
// 1) https://core.telegram.org/bots/api#inlinequeryresult
Type string
// Result title
//
// Use SetTitle and GetTitle helpers.
Title string
// Result description
//
// Use SetDescription and GetDescription helpers.
Description string
// URL of article or webpage
//
// Use SetURL and GetURL helpers.
URL string
// Thumbnail for the result
//
// Use SetThumb and GetThumb helpers.
Thumb WebDocumentClass
// Content of the result
//
// Use SetContent and GetContent helpers.
Content WebDocumentClass
// Message to send
SendMessage BotInlineMessageClass
}
BotInlineResult represents TL type `botInlineResult#11965f3a`. Generic result
See https://core.telegram.org/constructor/botInlineResult for reference.
func (*BotInlineResult) Decode ¶
func (b *BotInlineResult) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotInlineResult) Encode ¶
func (b *BotInlineResult) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotInlineResult) GetContent ¶
func (b *BotInlineResult) GetContent() (value WebDocumentClass, ok bool)
GetContent returns value of Content conditional field and boolean which is true if field was set.
func (*BotInlineResult) GetDescription ¶
func (b *BotInlineResult) GetDescription() (value string, ok bool)
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*BotInlineResult) GetThumb ¶
func (b *BotInlineResult) GetThumb() (value WebDocumentClass, ok bool)
GetThumb returns value of Thumb conditional field and boolean which is true if field was set.
func (*BotInlineResult) GetTitle ¶
func (b *BotInlineResult) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*BotInlineResult) GetURL ¶
func (b *BotInlineResult) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*BotInlineResult) SetContent ¶
func (b *BotInlineResult) SetContent(value WebDocumentClass)
SetContent sets value of Content conditional field.
func (*BotInlineResult) SetDescription ¶
func (b *BotInlineResult) SetDescription(value string)
SetDescription sets value of Description conditional field.
func (*BotInlineResult) SetThumb ¶
func (b *BotInlineResult) SetThumb(value WebDocumentClass)
SetThumb sets value of Thumb conditional field.
func (*BotInlineResult) SetTitle ¶
func (b *BotInlineResult) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*BotInlineResult) SetURL ¶
func (b *BotInlineResult) SetURL(value string)
SetURL sets value of URL conditional field.
func (*BotInlineResult) String ¶ added in v0.12.0
func (b *BotInlineResult) String() string
String implements fmt.Stringer.
type BotInlineResultBox ¶
type BotInlineResultBox struct {
BotInlineResult BotInlineResultClass
}
BotInlineResult boxes the BotInlineResultClass providing a helper.
type BotInlineResultClass ¶
type BotInlineResultClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
BotInlineResultClass represents BotInlineResult generic type.
See https://core.telegram.org/type/BotInlineResult for reference.
Example:
g, err := DecodeBotInlineResult(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *BotInlineResult: // botInlineResult#11965f3a
case *BotInlineMediaResult: // botInlineMediaResult#17db940b
default: panic(v)
}
func DecodeBotInlineResult ¶
func DecodeBotInlineResult(buf *bin.Buffer) (BotInlineResultClass, error)
DecodeBotInlineResult implements binary de-serialization for BotInlineResultClass.
type BotInlineSendHandler ¶ added in v0.9.0
type BotInlineSendHandler func(ctx UpdateContext, update *UpdateBotInlineSend) error
BotInlineSendHandler is a BotInlineSend event handler.
type BotPrecheckoutQueryHandler ¶ added in v0.9.0
type BotPrecheckoutQueryHandler func(ctx UpdateContext, update *UpdateBotPrecheckoutQuery) error
BotPrecheckoutQueryHandler is a BotPrecheckoutQuery event handler.
type BotShippingQueryHandler ¶ added in v0.9.0
type BotShippingQueryHandler func(ctx UpdateContext, update *UpdateBotShippingQuery) error
BotShippingQueryHandler is a BotShippingQuery event handler.
type BotWebhookJSONHandler ¶ added in v0.9.0
type BotWebhookJSONHandler func(ctx UpdateContext, update *UpdateBotWebhookJSON) error
BotWebhookJSONHandler is a BotWebhookJSON event handler.
type BotWebhookJSONQueryHandler ¶ added in v0.9.0
type BotWebhookJSONQueryHandler func(ctx UpdateContext, update *UpdateBotWebhookJSONQuery) error
BotWebhookJSONQueryHandler is a BotWebhookJSONQuery event handler.
type BotsAnswerWebhookJSONQueryRequest ¶
type BotsAnswerWebhookJSONQueryRequest struct {
// Identifier of a custom query
QueryID int64
// JSON-serialized answer to the query
Data DataJSON
}
BotsAnswerWebhookJSONQueryRequest represents TL type `bots.answerWebhookJSONQuery#e6213f4d`. Answers a custom query; for bots only
See https://core.telegram.org/method/bots.answerWebhookJSONQuery for reference.
func (*BotsAnswerWebhookJSONQueryRequest) Decode ¶
func (a *BotsAnswerWebhookJSONQueryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotsAnswerWebhookJSONQueryRequest) Encode ¶
func (a *BotsAnswerWebhookJSONQueryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotsAnswerWebhookJSONQueryRequest) String ¶ added in v0.12.0
func (a *BotsAnswerWebhookJSONQueryRequest) String() string
String implements fmt.Stringer.
type BotsSendCustomRequestRequest ¶
type BotsSendCustomRequestRequest struct {
// The method name
CustomMethod string
// JSON-serialized method parameters
Params DataJSON
}
BotsSendCustomRequestRequest represents TL type `bots.sendCustomRequest#aa2769ed`. Sends a custom request; for bots only
See https://core.telegram.org/method/bots.sendCustomRequest for reference.
func (*BotsSendCustomRequestRequest) Decode ¶
func (s *BotsSendCustomRequestRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotsSendCustomRequestRequest) Encode ¶
func (s *BotsSendCustomRequestRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotsSendCustomRequestRequest) String ¶ added in v0.12.0
func (s *BotsSendCustomRequestRequest) String() string
String implements fmt.Stringer.
type BotsSetBotCommandsRequest ¶
type BotsSetBotCommandsRequest struct {
// Bot commands
Commands []BotCommand
}
BotsSetBotCommandsRequest represents TL type `bots.setBotCommands#805d46f6`. Set bot command list
See https://core.telegram.org/method/bots.setBotCommands for reference.
func (*BotsSetBotCommandsRequest) Decode ¶
func (s *BotsSetBotCommandsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*BotsSetBotCommandsRequest) Encode ¶
func (s *BotsSetBotCommandsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*BotsSetBotCommandsRequest) String ¶ added in v0.12.0
func (s *BotsSetBotCommandsRequest) String() string
String implements fmt.Stringer.
type CdnConfig ¶
type CdnConfig struct {
// Vector of public keys to use only during handshakes to CDN¹ DCs.
//
// Links:
// 1) https://core.telegram.org/cdn
PublicKeys []CdnPublicKey
}
CdnConfig represents TL type `cdnConfig#5725e40a`. Configuration for CDN¹ file downloads.
Links:
See https://core.telegram.org/constructor/cdnConfig for reference.
type CdnPublicKey ¶
type CdnPublicKey struct {
// CDN DC¹ ID
//
// Links:
// 1) https://core.telegram.org/cdn
DCID int
// RSA public key
PublicKey string
}
CdnPublicKey represents TL type `cdnPublicKey#c982eaba`. Public key to use only during handshakes to CDN¹ DCs.
Links:
See https://core.telegram.org/constructor/cdnPublicKey for reference.
func (*CdnPublicKey) Decode ¶
func (c *CdnPublicKey) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*CdnPublicKey) Encode ¶
func (c *CdnPublicKey) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*CdnPublicKey) String ¶ added in v0.12.0
func (c *CdnPublicKey) String() string
String implements fmt.Stringer.
type Channel ¶
type Channel struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the current user is the creator of this channel
Creator bool
// Whether the current user has left this channel
Left bool
// Is this a channel?
Broadcast bool
// Is this channel verified by telegram?
Verified bool
// Is this a supergroup?
Megagroup bool
// Whether viewing/writing in this channel for a reason (see restriction_reason
Restricted bool
// Whether signatures are enabled (channels)
Signatures bool
// See min¹
//
// Links:
// 1) https://core.telegram.org/api/min
Min bool
// This channel/supergroup is probably a scam
Scam bool
// Whether this channel has a private join link
HasLink bool
// Whether this chanel has a geoposition
HasGeo bool
// Whether slow mode is enabled for groups to prevent flood in chat
SlowmodeEnabled bool
// CallActive field of Channel.
CallActive bool
// CallNotEmpty field of Channel.
CallNotEmpty bool
// ID of the channel
ID int
// Access hash
//
// Use SetAccessHash and GetAccessHash helpers.
AccessHash int64
// Title
Title string
// Username
//
// Use SetUsername and GetUsername helpers.
Username string
// Profile photo
Photo ChatPhotoClass
// Date when the user joined the supergroup/channel, or if the user isn't a member, its creation date
Date int
// Version of the channel (always 0)
Version int
// Contains the reason why access to this channel must be restricted.
//
// Use SetRestrictionReason and GetRestrictionReason helpers.
RestrictionReason []RestrictionReason
// Admin rights of the user in this channel (see rights¹)
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetAdminRights and GetAdminRights helpers.
AdminRights ChatAdminRights
// Banned rights of the user in this channel (see rights¹)
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetBannedRights and GetBannedRights helpers.
BannedRights ChatBannedRights
// Default chat rights (see rights¹)
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetDefaultBannedRights and GetDefaultBannedRights helpers.
DefaultBannedRights ChatBannedRights
// Participant count
//
// Use SetParticipantsCount and GetParticipantsCount helpers.
ParticipantsCount int
}
Channel represents TL type `channel#d31a961e`. Channel/supergroup info
See https://core.telegram.org/constructor/channel for reference.
func (*Channel) GetAccessHash ¶
GetAccessHash returns value of AccessHash conditional field and boolean which is true if field was set.
func (*Channel) GetAdminRights ¶
func (c *Channel) GetAdminRights() (value ChatAdminRights, ok bool)
GetAdminRights returns value of AdminRights conditional field and boolean which is true if field was set.
func (*Channel) GetBannedRights ¶
func (c *Channel) GetBannedRights() (value ChatBannedRights, ok bool)
GetBannedRights returns value of BannedRights conditional field and boolean which is true if field was set.
func (*Channel) GetDefaultBannedRights ¶
func (c *Channel) GetDefaultBannedRights() (value ChatBannedRights, ok bool)
GetDefaultBannedRights returns value of DefaultBannedRights conditional field and boolean which is true if field was set.
func (*Channel) GetParticipantsCount ¶
GetParticipantsCount returns value of ParticipantsCount conditional field and boolean which is true if field was set.
func (*Channel) GetRestrictionReason ¶
func (c *Channel) GetRestrictionReason() (value []RestrictionReason, ok bool)
GetRestrictionReason returns value of RestrictionReason conditional field and boolean which is true if field was set.
func (*Channel) GetUsername ¶
GetUsername returns value of Username conditional field and boolean which is true if field was set.
func (*Channel) SetAccessHash ¶
SetAccessHash sets value of AccessHash conditional field.
func (*Channel) SetAdminRights ¶
func (c *Channel) SetAdminRights(value ChatAdminRights)
SetAdminRights sets value of AdminRights conditional field.
func (*Channel) SetBannedRights ¶
func (c *Channel) SetBannedRights(value ChatBannedRights)
SetBannedRights sets value of BannedRights conditional field.
func (*Channel) SetBroadcast ¶
SetBroadcast sets value of Broadcast conditional field.
func (*Channel) SetCallActive ¶
SetCallActive sets value of CallActive conditional field.
func (*Channel) SetCallNotEmpty ¶ added in v0.13.0
SetCallNotEmpty sets value of CallNotEmpty conditional field.
func (*Channel) SetCreator ¶
SetCreator sets value of Creator conditional field.
func (*Channel) SetDefaultBannedRights ¶
func (c *Channel) SetDefaultBannedRights(value ChatBannedRights)
SetDefaultBannedRights sets value of DefaultBannedRights conditional field.
func (*Channel) SetHasLink ¶
SetHasLink sets value of HasLink conditional field.
func (*Channel) SetMegagroup ¶
SetMegagroup sets value of Megagroup conditional field.
func (*Channel) SetParticipantsCount ¶
SetParticipantsCount sets value of ParticipantsCount conditional field.
func (*Channel) SetRestricted ¶
SetRestricted sets value of Restricted conditional field.
func (*Channel) SetRestrictionReason ¶
func (c *Channel) SetRestrictionReason(value []RestrictionReason)
SetRestrictionReason sets value of RestrictionReason conditional field.
func (*Channel) SetSignatures ¶
SetSignatures sets value of Signatures conditional field.
func (*Channel) SetSlowmodeEnabled ¶
SetSlowmodeEnabled sets value of SlowmodeEnabled conditional field.
func (*Channel) SetUsername ¶
SetUsername sets value of Username conditional field.
func (*Channel) SetVerified ¶
SetVerified sets value of Verified conditional field.
type ChannelAdminLogEvent ¶
type ChannelAdminLogEvent struct {
// Event ID
ID int64
// Date
Date int
// User ID
UserID int
// Action
Action ChannelAdminLogEventActionClass
}
ChannelAdminLogEvent represents TL type `channelAdminLogEvent#3b5a3e40`. Admin log event
See https://core.telegram.org/constructor/channelAdminLogEvent for reference.
func (*ChannelAdminLogEvent) Decode ¶
func (c *ChannelAdminLogEvent) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEvent) Encode ¶
func (c *ChannelAdminLogEvent) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEvent) String ¶ added in v0.12.0
func (c *ChannelAdminLogEvent) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionBox ¶
type ChannelAdminLogEventActionBox struct {
ChannelAdminLogEventAction ChannelAdminLogEventActionClass
}
ChannelAdminLogEventAction boxes the ChannelAdminLogEventActionClass providing a helper.
type ChannelAdminLogEventActionChangeAbout ¶
type ChannelAdminLogEventActionChangeAbout struct {
// Previous description
PrevValue string
// New description
NewValue string
}
ChannelAdminLogEventActionChangeAbout represents TL type `channelAdminLogEventActionChangeAbout#55188a2e`. The description was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeAbout for reference.
func (*ChannelAdminLogEventActionChangeAbout) Decode ¶
func (c *ChannelAdminLogEventActionChangeAbout) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeAbout) Encode ¶
func (c *ChannelAdminLogEventActionChangeAbout) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeAbout) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeAbout) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangeLinkedChat ¶
type ChannelAdminLogEventActionChangeLinkedChat struct {
// Previous linked chat
PrevValue int
// New linked chat
NewValue int
}
ChannelAdminLogEventActionChangeLinkedChat represents TL type `channelAdminLogEventActionChangeLinkedChat#a26f881b`. The linked chat was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeLinkedChat for reference.
func (*ChannelAdminLogEventActionChangeLinkedChat) Decode ¶
func (c *ChannelAdminLogEventActionChangeLinkedChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeLinkedChat) Encode ¶
func (c *ChannelAdminLogEventActionChangeLinkedChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeLinkedChat) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeLinkedChat) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangeLocation ¶
type ChannelAdminLogEventActionChangeLocation struct {
// Previous location
PrevValue ChannelLocationClass
// New location
NewValue ChannelLocationClass
}
ChannelAdminLogEventActionChangeLocation represents TL type `channelAdminLogEventActionChangeLocation#e6b76ae`. The geogroup location was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeLocation for reference.
func (*ChannelAdminLogEventActionChangeLocation) Decode ¶
func (c *ChannelAdminLogEventActionChangeLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeLocation) Encode ¶
func (c *ChannelAdminLogEventActionChangeLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeLocation) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeLocation) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangePhoto ¶
type ChannelAdminLogEventActionChangePhoto struct {
// Previous picture
PrevPhoto PhotoClass
// New picture
NewPhoto PhotoClass
}
ChannelAdminLogEventActionChangePhoto represents TL type `channelAdminLogEventActionChangePhoto#434bd2af`. The channel/supergroup's picture was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangePhoto for reference.
func (*ChannelAdminLogEventActionChangePhoto) Decode ¶
func (c *ChannelAdminLogEventActionChangePhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangePhoto) Encode ¶
func (c *ChannelAdminLogEventActionChangePhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangePhoto) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangePhoto) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangeStickerSet ¶
type ChannelAdminLogEventActionChangeStickerSet struct {
// Previous stickerset
PrevStickerset InputStickerSetClass
// New stickerset
NewStickerset InputStickerSetClass
}
ChannelAdminLogEventActionChangeStickerSet represents TL type `channelAdminLogEventActionChangeStickerSet#b1c3caa7`. The supergroup's stickerset was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeStickerSet for reference.
func (*ChannelAdminLogEventActionChangeStickerSet) Decode ¶
func (c *ChannelAdminLogEventActionChangeStickerSet) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeStickerSet) Encode ¶
func (c *ChannelAdminLogEventActionChangeStickerSet) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeStickerSet) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeStickerSet) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangeTitle ¶
type ChannelAdminLogEventActionChangeTitle struct {
// Previous title
PrevValue string
// New title
NewValue string
}
ChannelAdminLogEventActionChangeTitle represents TL type `channelAdminLogEventActionChangeTitle#e6dfb825`. Channel/supergroup title was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeTitle for reference.
func (*ChannelAdminLogEventActionChangeTitle) Decode ¶
func (c *ChannelAdminLogEventActionChangeTitle) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeTitle) Encode ¶
func (c *ChannelAdminLogEventActionChangeTitle) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeTitle) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeTitle) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionChangeUsername ¶
type ChannelAdminLogEventActionChangeUsername struct {
// Old username
PrevValue string
// New username
NewValue string
}
ChannelAdminLogEventActionChangeUsername represents TL type `channelAdminLogEventActionChangeUsername#6a4afc38`. Channel/supergroup username was changed
See https://core.telegram.org/constructor/channelAdminLogEventActionChangeUsername for reference.
func (*ChannelAdminLogEventActionChangeUsername) Decode ¶
func (c *ChannelAdminLogEventActionChangeUsername) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionChangeUsername) Encode ¶
func (c *ChannelAdminLogEventActionChangeUsername) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionChangeUsername) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionChangeUsername) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionClass ¶
type ChannelAdminLogEventActionClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelAdminLogEventActionClass represents ChannelAdminLogEventAction generic type.
See https://core.telegram.org/type/ChannelAdminLogEventAction for reference.
Example:
g, err := DecodeChannelAdminLogEventAction(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelAdminLogEventActionChangeTitle: // channelAdminLogEventActionChangeTitle#e6dfb825
case *ChannelAdminLogEventActionChangeAbout: // channelAdminLogEventActionChangeAbout#55188a2e
case *ChannelAdminLogEventActionChangeUsername: // channelAdminLogEventActionChangeUsername#6a4afc38
case *ChannelAdminLogEventActionChangePhoto: // channelAdminLogEventActionChangePhoto#434bd2af
case *ChannelAdminLogEventActionToggleInvites: // channelAdminLogEventActionToggleInvites#1b7907ae
case *ChannelAdminLogEventActionToggleSignatures: // channelAdminLogEventActionToggleSignatures#26ae0971
case *ChannelAdminLogEventActionUpdatePinned: // channelAdminLogEventActionUpdatePinned#e9e82c18
case *ChannelAdminLogEventActionEditMessage: // channelAdminLogEventActionEditMessage#709b2405
case *ChannelAdminLogEventActionDeleteMessage: // channelAdminLogEventActionDeleteMessage#42e047bb
case *ChannelAdminLogEventActionParticipantJoin: // channelAdminLogEventActionParticipantJoin#183040d3
case *ChannelAdminLogEventActionParticipantLeave: // channelAdminLogEventActionParticipantLeave#f89777f2
case *ChannelAdminLogEventActionParticipantInvite: // channelAdminLogEventActionParticipantInvite#e31c34d8
case *ChannelAdminLogEventActionParticipantToggleBan: // channelAdminLogEventActionParticipantToggleBan#e6d83d7e
case *ChannelAdminLogEventActionParticipantToggleAdmin: // channelAdminLogEventActionParticipantToggleAdmin#d5676710
case *ChannelAdminLogEventActionChangeStickerSet: // channelAdminLogEventActionChangeStickerSet#b1c3caa7
case *ChannelAdminLogEventActionTogglePreHistoryHidden: // channelAdminLogEventActionTogglePreHistoryHidden#5f5c95f1
case *ChannelAdminLogEventActionDefaultBannedRights: // channelAdminLogEventActionDefaultBannedRights#2df5fc0a
case *ChannelAdminLogEventActionStopPoll: // channelAdminLogEventActionStopPoll#8f079643
case *ChannelAdminLogEventActionChangeLinkedChat: // channelAdminLogEventActionChangeLinkedChat#a26f881b
case *ChannelAdminLogEventActionChangeLocation: // channelAdminLogEventActionChangeLocation#e6b76ae
case *ChannelAdminLogEventActionToggleSlowMode: // channelAdminLogEventActionToggleSlowMode#53909779
case *ChannelAdminLogEventActionStartGroupCall: // channelAdminLogEventActionStartGroupCall#23209745
case *ChannelAdminLogEventActionDiscardGroupCall: // channelAdminLogEventActionDiscardGroupCall#db9f9140
case *ChannelAdminLogEventActionParticipantMute: // channelAdminLogEventActionParticipantMute#f92424d2
case *ChannelAdminLogEventActionParticipantUnmute: // channelAdminLogEventActionParticipantUnmute#e64429c0
case *ChannelAdminLogEventActionToggleGroupCallSetting: // channelAdminLogEventActionToggleGroupCallSetting#56d6a247
default: panic(v)
}
func DecodeChannelAdminLogEventAction ¶
func DecodeChannelAdminLogEventAction(buf *bin.Buffer) (ChannelAdminLogEventActionClass, error)
DecodeChannelAdminLogEventAction implements binary de-serialization for ChannelAdminLogEventActionClass.
type ChannelAdminLogEventActionDefaultBannedRights ¶
type ChannelAdminLogEventActionDefaultBannedRights struct {
// Previous global banned rights¹
//
// Links:
// 1) https://core.telegram.org/api/rights
PrevBannedRights ChatBannedRights
// New glboal banned rights¹.
//
// Links:
// 1) https://core.telegram.org/api/rights
NewBannedRights ChatBannedRights
}
ChannelAdminLogEventActionDefaultBannedRights represents TL type `channelAdminLogEventActionDefaultBannedRights#2df5fc0a`. The default banned rights were modified
See https://core.telegram.org/constructor/channelAdminLogEventActionDefaultBannedRights for reference.
func (*ChannelAdminLogEventActionDefaultBannedRights) Decode ¶
func (c *ChannelAdminLogEventActionDefaultBannedRights) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionDefaultBannedRights) Encode ¶
func (c *ChannelAdminLogEventActionDefaultBannedRights) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionDefaultBannedRights) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionDefaultBannedRights) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionDeleteMessage ¶
type ChannelAdminLogEventActionDeleteMessage struct {
// The message that was deleted
Message MessageClass
}
ChannelAdminLogEventActionDeleteMessage represents TL type `channelAdminLogEventActionDeleteMessage#42e047bb`. A message was deleted
See https://core.telegram.org/constructor/channelAdminLogEventActionDeleteMessage for reference.
func (*ChannelAdminLogEventActionDeleteMessage) Decode ¶
func (c *ChannelAdminLogEventActionDeleteMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionDeleteMessage) Encode ¶
func (c *ChannelAdminLogEventActionDeleteMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionDeleteMessage) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionDeleteMessage) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionDiscardGroupCall ¶ added in v0.13.0
type ChannelAdminLogEventActionDiscardGroupCall struct {
// Call field of ChannelAdminLogEventActionDiscardGroupCall.
Call InputGroupCall
}
ChannelAdminLogEventActionDiscardGroupCall represents TL type `channelAdminLogEventActionDiscardGroupCall#db9f9140`.
See https://core.telegram.org/constructor/channelAdminLogEventActionDiscardGroupCall for reference.
func (*ChannelAdminLogEventActionDiscardGroupCall) Decode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionDiscardGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionDiscardGroupCall) Encode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionDiscardGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionDiscardGroupCall) String ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionDiscardGroupCall) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionEditMessage ¶
type ChannelAdminLogEventActionEditMessage struct {
// Old message
PrevMessage MessageClass
// New message
NewMessage MessageClass
}
ChannelAdminLogEventActionEditMessage represents TL type `channelAdminLogEventActionEditMessage#709b2405`. A message was edited
See https://core.telegram.org/constructor/channelAdminLogEventActionEditMessage for reference.
func (*ChannelAdminLogEventActionEditMessage) Decode ¶
func (c *ChannelAdminLogEventActionEditMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionEditMessage) Encode ¶
func (c *ChannelAdminLogEventActionEditMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionEditMessage) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionEditMessage) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantInvite ¶
type ChannelAdminLogEventActionParticipantInvite struct {
// The user that was invited
Participant ChannelParticipantClass
}
ChannelAdminLogEventActionParticipantInvite represents TL type `channelAdminLogEventActionParticipantInvite#e31c34d8`. A user was invited to the group
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantInvite for reference.
func (*ChannelAdminLogEventActionParticipantInvite) Decode ¶
func (c *ChannelAdminLogEventActionParticipantInvite) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantInvite) Encode ¶
func (c *ChannelAdminLogEventActionParticipantInvite) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantInvite) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionParticipantInvite) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantJoin ¶
type ChannelAdminLogEventActionParticipantJoin struct {
}
ChannelAdminLogEventActionParticipantJoin represents TL type `channelAdminLogEventActionParticipantJoin#183040d3`. A user has joined the group (in the case of big groups, info of the user that has joined isn't shown)
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantJoin for reference.
func (*ChannelAdminLogEventActionParticipantJoin) Decode ¶
func (c *ChannelAdminLogEventActionParticipantJoin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantJoin) Encode ¶
func (c *ChannelAdminLogEventActionParticipantJoin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantJoin) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionParticipantJoin) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantLeave ¶
type ChannelAdminLogEventActionParticipantLeave struct {
}
ChannelAdminLogEventActionParticipantLeave represents TL type `channelAdminLogEventActionParticipantLeave#f89777f2`. A user left the channel/supergroup (in the case of big groups, info of the user that has joined isn't shown)
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantLeave for reference.
func (*ChannelAdminLogEventActionParticipantLeave) Decode ¶
func (c *ChannelAdminLogEventActionParticipantLeave) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantLeave) Encode ¶
func (c *ChannelAdminLogEventActionParticipantLeave) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantLeave) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionParticipantLeave) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantMute ¶ added in v0.13.0
type ChannelAdminLogEventActionParticipantMute struct {
// Participant field of ChannelAdminLogEventActionParticipantMute.
Participant GroupCallParticipant
}
ChannelAdminLogEventActionParticipantMute represents TL type `channelAdminLogEventActionParticipantMute#f92424d2`.
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantMute for reference.
func (*ChannelAdminLogEventActionParticipantMute) Decode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantMute) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantMute) Encode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantMute) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantMute) String ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantMute) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantToggleAdmin ¶
type ChannelAdminLogEventActionParticipantToggleAdmin struct {
// Previous admin rights
PrevParticipant ChannelParticipantClass
// New admin rights
NewParticipant ChannelParticipantClass
}
ChannelAdminLogEventActionParticipantToggleAdmin represents TL type `channelAdminLogEventActionParticipantToggleAdmin#d5676710`. The admin rights¹ of a user were changed
Links:
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleAdmin for reference.
func (*ChannelAdminLogEventActionParticipantToggleAdmin) Decode ¶
func (c *ChannelAdminLogEventActionParticipantToggleAdmin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantToggleAdmin) Encode ¶
func (c *ChannelAdminLogEventActionParticipantToggleAdmin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantToggleAdmin) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionParticipantToggleAdmin) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantToggleBan ¶
type ChannelAdminLogEventActionParticipantToggleBan struct {
// Old banned rights of user
PrevParticipant ChannelParticipantClass
// New banned rights of user
NewParticipant ChannelParticipantClass
}
ChannelAdminLogEventActionParticipantToggleBan represents TL type `channelAdminLogEventActionParticipantToggleBan#e6d83d7e`. The banned rights¹ of a user were changed
Links:
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleBan for reference.
func (*ChannelAdminLogEventActionParticipantToggleBan) Decode ¶
func (c *ChannelAdminLogEventActionParticipantToggleBan) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantToggleBan) Encode ¶
func (c *ChannelAdminLogEventActionParticipantToggleBan) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantToggleBan) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionParticipantToggleBan) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionParticipantUnmute ¶ added in v0.13.0
type ChannelAdminLogEventActionParticipantUnmute struct {
// Participant field of ChannelAdminLogEventActionParticipantUnmute.
Participant GroupCallParticipant
}
ChannelAdminLogEventActionParticipantUnmute represents TL type `channelAdminLogEventActionParticipantUnmute#e64429c0`.
See https://core.telegram.org/constructor/channelAdminLogEventActionParticipantUnmute for reference.
func (*ChannelAdminLogEventActionParticipantUnmute) Decode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantUnmute) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionParticipantUnmute) Encode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantUnmute) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionParticipantUnmute) String ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionParticipantUnmute) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionStartGroupCall ¶ added in v0.13.0
type ChannelAdminLogEventActionStartGroupCall struct {
// Call field of ChannelAdminLogEventActionStartGroupCall.
Call InputGroupCall
}
ChannelAdminLogEventActionStartGroupCall represents TL type `channelAdminLogEventActionStartGroupCall#23209745`.
See https://core.telegram.org/constructor/channelAdminLogEventActionStartGroupCall for reference.
func (*ChannelAdminLogEventActionStartGroupCall) Decode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionStartGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionStartGroupCall) Encode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionStartGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionStartGroupCall) String ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionStartGroupCall) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionStopPoll ¶
type ChannelAdminLogEventActionStopPoll struct {
// The poll that was stopped
Message MessageClass
}
ChannelAdminLogEventActionStopPoll represents TL type `channelAdminLogEventActionStopPoll#8f079643`. A poll was stopped
See https://core.telegram.org/constructor/channelAdminLogEventActionStopPoll for reference.
func (*ChannelAdminLogEventActionStopPoll) Decode ¶
func (c *ChannelAdminLogEventActionStopPoll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionStopPoll) Encode ¶
func (c *ChannelAdminLogEventActionStopPoll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionStopPoll) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionStopPoll) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionToggleGroupCallSetting ¶ added in v0.13.0
type ChannelAdminLogEventActionToggleGroupCallSetting struct {
// JoinMuted field of ChannelAdminLogEventActionToggleGroupCallSetting.
JoinMuted bool
}
ChannelAdminLogEventActionToggleGroupCallSetting represents TL type `channelAdminLogEventActionToggleGroupCallSetting#56d6a247`.
See https://core.telegram.org/constructor/channelAdminLogEventActionToggleGroupCallSetting for reference.
func (*ChannelAdminLogEventActionToggleGroupCallSetting) Decode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionToggleGroupCallSetting) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionToggleGroupCallSetting) Encode ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionToggleGroupCallSetting) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionToggleGroupCallSetting) String ¶ added in v0.13.0
func (c *ChannelAdminLogEventActionToggleGroupCallSetting) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionToggleInvites ¶
type ChannelAdminLogEventActionToggleInvites struct {
// New value
NewValue bool
}
ChannelAdminLogEventActionToggleInvites represents TL type `channelAdminLogEventActionToggleInvites#1b7907ae`. Invites were enabled/disabled
See https://core.telegram.org/constructor/channelAdminLogEventActionToggleInvites for reference.
func (*ChannelAdminLogEventActionToggleInvites) Decode ¶
func (c *ChannelAdminLogEventActionToggleInvites) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionToggleInvites) Encode ¶
func (c *ChannelAdminLogEventActionToggleInvites) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionToggleInvites) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionToggleInvites) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionTogglePreHistoryHidden ¶
type ChannelAdminLogEventActionTogglePreHistoryHidden struct {
// New value
NewValue bool
}
ChannelAdminLogEventActionTogglePreHistoryHidden represents TL type `channelAdminLogEventActionTogglePreHistoryHidden#5f5c95f1`. The hidden prehistory setting was changed¹
Links:
See https://core.telegram.org/constructor/channelAdminLogEventActionTogglePreHistoryHidden for reference.
func (*ChannelAdminLogEventActionTogglePreHistoryHidden) Decode ¶
func (c *ChannelAdminLogEventActionTogglePreHistoryHidden) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionTogglePreHistoryHidden) Encode ¶
func (c *ChannelAdminLogEventActionTogglePreHistoryHidden) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionTogglePreHistoryHidden) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionTogglePreHistoryHidden) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionToggleSignatures ¶
type ChannelAdminLogEventActionToggleSignatures struct {
// New value
NewValue bool
}
ChannelAdminLogEventActionToggleSignatures represents TL type `channelAdminLogEventActionToggleSignatures#26ae0971`. Channel signatures were enabled/disabled
See https://core.telegram.org/constructor/channelAdminLogEventActionToggleSignatures for reference.
func (*ChannelAdminLogEventActionToggleSignatures) Decode ¶
func (c *ChannelAdminLogEventActionToggleSignatures) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionToggleSignatures) Encode ¶
func (c *ChannelAdminLogEventActionToggleSignatures) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionToggleSignatures) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionToggleSignatures) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionToggleSlowMode ¶
type ChannelAdminLogEventActionToggleSlowMode struct {
// Previous slow mode value
PrevValue int
// New slow mode value
NewValue int
}
ChannelAdminLogEventActionToggleSlowMode represents TL type `channelAdminLogEventActionToggleSlowMode#53909779`. Slow mode setting for supergroups was changed¹
Links:
See https://core.telegram.org/constructor/channelAdminLogEventActionToggleSlowMode for reference.
func (*ChannelAdminLogEventActionToggleSlowMode) Decode ¶
func (c *ChannelAdminLogEventActionToggleSlowMode) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionToggleSlowMode) Encode ¶
func (c *ChannelAdminLogEventActionToggleSlowMode) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionToggleSlowMode) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionToggleSlowMode) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventActionUpdatePinned ¶
type ChannelAdminLogEventActionUpdatePinned struct {
// The message that was pinned
Message MessageClass
}
ChannelAdminLogEventActionUpdatePinned represents TL type `channelAdminLogEventActionUpdatePinned#e9e82c18`. A message was pinned
See https://core.telegram.org/constructor/channelAdminLogEventActionUpdatePinned for reference.
func (*ChannelAdminLogEventActionUpdatePinned) Decode ¶
func (c *ChannelAdminLogEventActionUpdatePinned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventActionUpdatePinned) Encode ¶
func (c *ChannelAdminLogEventActionUpdatePinned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventActionUpdatePinned) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventActionUpdatePinned) String() string
String implements fmt.Stringer.
type ChannelAdminLogEventsFilter ¶
type ChannelAdminLogEventsFilter struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Join events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantJoin
Join bool
// Leave events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantLeave
Leave bool
// Invite events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantInvite
Invite bool
// Ban events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleBan
Ban bool
// Unban events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleBan
Unban bool
// Kick events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleBan
Kick bool
// Unkick events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleBan
Unkick bool
// Admin promotion events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleAdmin
Promote bool
// Admin demotion events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionParticipantToggleAdmin
Demote bool
// Info change events (when about¹, linked chat², location³, photo⁴, stickerset⁵, title⁶ or username⁷ data of a channel gets modified)
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionChangeAbout
// 2) https://core.telegram.org/constructor/channelAdminLogEventActionChangeLinkedChat
// 3) https://core.telegram.org/constructor/channelAdminLogEventActionChangeLocation
// 4) https://core.telegram.org/constructor/channelAdminLogEventActionChangePhoto
// 5) https://core.telegram.org/constructor/channelAdminLogEventActionChangeStickerSet
// 6) https://core.telegram.org/constructor/channelAdminLogEventActionChangeTitle
// 7) https://core.telegram.org/constructor/channelAdminLogEventActionChangeUsername
Info bool
// Settings change events (invites¹, hidden prehistory², signatures³, default banned rights⁴)
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionToggleInvites
// 2) https://core.telegram.org/constructor/channelAdminLogEventActionTogglePreHistoryHidden
// 3) https://core.telegram.org/constructor/channelAdminLogEventActionToggleSignatures
// 4) https://core.telegram.org/constructor/channelAdminLogEventActionDefaultBannedRights
Settings bool
// Message pin events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionUpdatePinned
Pinned bool
// Message edit events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionEditMessage
Edit bool
// Message deletion events¹
//
// Links:
// 1) https://core.telegram.org/constructor/channelAdminLogEventActionDeleteMessage
Delete bool
// GroupCall field of ChannelAdminLogEventsFilter.
GroupCall bool
}
ChannelAdminLogEventsFilter represents TL type `channelAdminLogEventsFilter#ea107ae4`. Filter only certain admin log events
See https://core.telegram.org/constructor/channelAdminLogEventsFilter for reference.
func (*ChannelAdminLogEventsFilter) Decode ¶
func (c *ChannelAdminLogEventsFilter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelAdminLogEventsFilter) Encode ¶
func (c *ChannelAdminLogEventsFilter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelAdminLogEventsFilter) SetBan ¶
func (c *ChannelAdminLogEventsFilter) SetBan(value bool)
SetBan sets value of Ban conditional field.
func (*ChannelAdminLogEventsFilter) SetDelete ¶
func (c *ChannelAdminLogEventsFilter) SetDelete(value bool)
SetDelete sets value of Delete conditional field.
func (*ChannelAdminLogEventsFilter) SetDemote ¶
func (c *ChannelAdminLogEventsFilter) SetDemote(value bool)
SetDemote sets value of Demote conditional field.
func (*ChannelAdminLogEventsFilter) SetEdit ¶
func (c *ChannelAdminLogEventsFilter) SetEdit(value bool)
SetEdit sets value of Edit conditional field.
func (*ChannelAdminLogEventsFilter) SetGroupCall ¶ added in v0.13.0
func (c *ChannelAdminLogEventsFilter) SetGroupCall(value bool)
SetGroupCall sets value of GroupCall conditional field.
func (*ChannelAdminLogEventsFilter) SetInfo ¶
func (c *ChannelAdminLogEventsFilter) SetInfo(value bool)
SetInfo sets value of Info conditional field.
func (*ChannelAdminLogEventsFilter) SetInvite ¶
func (c *ChannelAdminLogEventsFilter) SetInvite(value bool)
SetInvite sets value of Invite conditional field.
func (*ChannelAdminLogEventsFilter) SetJoin ¶
func (c *ChannelAdminLogEventsFilter) SetJoin(value bool)
SetJoin sets value of Join conditional field.
func (*ChannelAdminLogEventsFilter) SetKick ¶
func (c *ChannelAdminLogEventsFilter) SetKick(value bool)
SetKick sets value of Kick conditional field.
func (*ChannelAdminLogEventsFilter) SetLeave ¶
func (c *ChannelAdminLogEventsFilter) SetLeave(value bool)
SetLeave sets value of Leave conditional field.
func (*ChannelAdminLogEventsFilter) SetPinned ¶
func (c *ChannelAdminLogEventsFilter) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*ChannelAdminLogEventsFilter) SetPromote ¶
func (c *ChannelAdminLogEventsFilter) SetPromote(value bool)
SetPromote sets value of Promote conditional field.
func (*ChannelAdminLogEventsFilter) SetSettings ¶
func (c *ChannelAdminLogEventsFilter) SetSettings(value bool)
SetSettings sets value of Settings conditional field.
func (*ChannelAdminLogEventsFilter) SetUnban ¶
func (c *ChannelAdminLogEventsFilter) SetUnban(value bool)
SetUnban sets value of Unban conditional field.
func (*ChannelAdminLogEventsFilter) SetUnkick ¶
func (c *ChannelAdminLogEventsFilter) SetUnkick(value bool)
SetUnkick sets value of Unkick conditional field.
func (*ChannelAdminLogEventsFilter) String ¶ added in v0.12.0
func (c *ChannelAdminLogEventsFilter) String() string
String implements fmt.Stringer.
type ChannelAvailableMessagesHandler ¶ added in v0.9.0
type ChannelAvailableMessagesHandler func(ctx UpdateContext, update *UpdateChannelAvailableMessages) error
ChannelAvailableMessagesHandler is a ChannelAvailableMessages event handler.
type ChannelForbidden ¶
type ChannelForbidden struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this a channel
Broadcast bool
// Is this a supergroup
Megagroup bool
// Channel ID
ID int
// Access hash
AccessHash int64
// Title
Title string
// The ban is valid until the specified date
//
// Use SetUntilDate and GetUntilDate helpers.
UntilDate int
}
ChannelForbidden represents TL type `channelForbidden#289da732`. Indicates a channel/supergroup we can't access because we were banned, or for some other reason.
See https://core.telegram.org/constructor/channelForbidden for reference.
func (*ChannelForbidden) Decode ¶
func (c *ChannelForbidden) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelForbidden) Encode ¶
func (c *ChannelForbidden) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelForbidden) GetUntilDate ¶
func (c *ChannelForbidden) GetUntilDate() (value int, ok bool)
GetUntilDate returns value of UntilDate conditional field and boolean which is true if field was set.
func (*ChannelForbidden) SetBroadcast ¶
func (c *ChannelForbidden) SetBroadcast(value bool)
SetBroadcast sets value of Broadcast conditional field.
func (*ChannelForbidden) SetMegagroup ¶
func (c *ChannelForbidden) SetMegagroup(value bool)
SetMegagroup sets value of Megagroup conditional field.
func (*ChannelForbidden) SetUntilDate ¶
func (c *ChannelForbidden) SetUntilDate(value int)
SetUntilDate sets value of UntilDate conditional field.
func (*ChannelForbidden) String ¶ added in v0.12.0
func (c *ChannelForbidden) String() string
String implements fmt.Stringer.
type ChannelFull ¶
type ChannelFull struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Can we vew the participant list?
CanViewParticipants bool
// Can we set the channel's username?
CanSetUsername bool
// Can we associate¹ a stickerpack to the supergroup?
//
// Links:
// 1) https://core.telegram.org/method/channels.setStickers
CanSetStickers bool
// Is the history before we joined hidden to us?
HiddenPrehistory bool
// Can we set the geolocation of this group (for geogroups)
CanSetLocation bool
// Whether scheduled messages are available
HasScheduled bool
// Can the user view channel/supergroup statistics¹
//
// Links:
// 1) https://core.telegram.org/api/stats
CanViewStats bool
// Whether any anonymous admin of this supergroup was blocked: if set, you won't receive messages from anonymous group admins in discussion replies via @replies¹
//
// Links:
// 1) https://core.telegram.org/api/discussion
Blocked bool
// ID of the channel
ID int
// Info about the channel
About string
// Number of participants of the channel
//
// Use SetParticipantsCount and GetParticipantsCount helpers.
ParticipantsCount int
// Number of channel admins
//
// Use SetAdminsCount and GetAdminsCount helpers.
AdminsCount int
// Number of users kicked¹ from the channel
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetKickedCount and GetKickedCount helpers.
KickedCount int
// Number of users banned¹ from the channel
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetBannedCount and GetBannedCount helpers.
BannedCount int
// Number of users currently online
//
// Use SetOnlineCount and GetOnlineCount helpers.
OnlineCount int
// Position up to which all incoming messages are read.
ReadInboxMaxID int
// Position up to which all outgoing messages are read.
ReadOutboxMaxID int
// Count of unread messages
UnreadCount int
// Channel picture
ChatPhoto PhotoClass
// Notification settings
NotifySettings PeerNotifySettings
// Invite link
ExportedInvite ExportedChatInviteClass
// Info about bots in the channel/supergrup
BotInfo []BotInfo
// The chat ID from which this group was migrated¹
//
// Links:
// 1) https://core.telegram.org/api/channel
//
// Use SetMigratedFromChatID and GetMigratedFromChatID helpers.
MigratedFromChatID int
// The message ID in the original chat at which this group was migrated¹
//
// Links:
// 1) https://core.telegram.org/api/channel
//
// Use SetMigratedFromMaxID and GetMigratedFromMaxID helpers.
MigratedFromMaxID int
// Message ID of the last pinned message¹
//
// Links:
// 1) https://core.telegram.org/api/pin
//
// Use SetPinnedMsgID and GetPinnedMsgID helpers.
PinnedMsgID int
// Associated stickerset
//
// Use SetStickerset and GetStickerset helpers.
Stickerset StickerSet
// Identifier of a maximum unavailable message in a channel due to hidden history.
//
// Use SetAvailableMinID and GetAvailableMinID helpers.
AvailableMinID int
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// ID of the linked discussion chat¹ for channels
//
// Links:
// 1) https://core.telegram.org/api/discussion
//
// Use SetLinkedChatID and GetLinkedChatID helpers.
LinkedChatID int
// Location of the geogroup
//
// Use SetLocation and GetLocation helpers.
Location ChannelLocationClass
// If specified, users in supergroups will only be able to send one message every slowmode_seconds seconds
//
// Use SetSlowmodeSeconds and GetSlowmodeSeconds helpers.
SlowmodeSeconds int
// Indicates when the user will be allowed to send another message in the supergroup (unixdate)
//
// Use SetSlowmodeNextSendDate and GetSlowmodeNextSendDate helpers.
SlowmodeNextSendDate int
// If set, specifies the DC to use for fetching channel statistics
//
// Use SetStatsDC and GetStatsDC helpers.
StatsDC int
// Latest PTS¹ for this channel
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Call field of ChannelFull.
//
// Use SetCall and GetCall helpers.
Call InputGroupCall
}
ChannelFull represents TL type `channelFull#ef3a6acd`. Full info about a channel/supergroup¹
Links:
See https://core.telegram.org/constructor/channelFull for reference.
func (*ChannelFull) Decode ¶
func (c *ChannelFull) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelFull) Encode ¶
func (c *ChannelFull) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelFull) GetAdminsCount ¶
func (c *ChannelFull) GetAdminsCount() (value int, ok bool)
GetAdminsCount returns value of AdminsCount conditional field and boolean which is true if field was set.
func (*ChannelFull) GetAvailableMinID ¶
func (c *ChannelFull) GetAvailableMinID() (value int, ok bool)
GetAvailableMinID returns value of AvailableMinID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetBannedCount ¶
func (c *ChannelFull) GetBannedCount() (value int, ok bool)
GetBannedCount returns value of BannedCount conditional field and boolean which is true if field was set.
func (*ChannelFull) GetCall ¶ added in v0.13.0
func (c *ChannelFull) GetCall() (value InputGroupCall, ok bool)
GetCall returns value of Call conditional field and boolean which is true if field was set.
func (*ChannelFull) GetFolderID ¶
func (c *ChannelFull) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetKickedCount ¶
func (c *ChannelFull) GetKickedCount() (value int, ok bool)
GetKickedCount returns value of KickedCount conditional field and boolean which is true if field was set.
func (*ChannelFull) GetLinkedChatID ¶
func (c *ChannelFull) GetLinkedChatID() (value int, ok bool)
GetLinkedChatID returns value of LinkedChatID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetLocation ¶
func (c *ChannelFull) GetLocation() (value ChannelLocationClass, ok bool)
GetLocation returns value of Location conditional field and boolean which is true if field was set.
func (*ChannelFull) GetMigratedFromChatID ¶
func (c *ChannelFull) GetMigratedFromChatID() (value int, ok bool)
GetMigratedFromChatID returns value of MigratedFromChatID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetMigratedFromMaxID ¶
func (c *ChannelFull) GetMigratedFromMaxID() (value int, ok bool)
GetMigratedFromMaxID returns value of MigratedFromMaxID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetOnlineCount ¶
func (c *ChannelFull) GetOnlineCount() (value int, ok bool)
GetOnlineCount returns value of OnlineCount conditional field and boolean which is true if field was set.
func (*ChannelFull) GetParticipantsCount ¶
func (c *ChannelFull) GetParticipantsCount() (value int, ok bool)
GetParticipantsCount returns value of ParticipantsCount conditional field and boolean which is true if field was set.
func (*ChannelFull) GetPinnedMsgID ¶
func (c *ChannelFull) GetPinnedMsgID() (value int, ok bool)
GetPinnedMsgID returns value of PinnedMsgID conditional field and boolean which is true if field was set.
func (*ChannelFull) GetSlowmodeNextSendDate ¶
func (c *ChannelFull) GetSlowmodeNextSendDate() (value int, ok bool)
GetSlowmodeNextSendDate returns value of SlowmodeNextSendDate conditional field and boolean which is true if field was set.
func (*ChannelFull) GetSlowmodeSeconds ¶
func (c *ChannelFull) GetSlowmodeSeconds() (value int, ok bool)
GetSlowmodeSeconds returns value of SlowmodeSeconds conditional field and boolean which is true if field was set.
func (*ChannelFull) GetStatsDC ¶
func (c *ChannelFull) GetStatsDC() (value int, ok bool)
GetStatsDC returns value of StatsDC conditional field and boolean which is true if field was set.
func (*ChannelFull) GetStickerset ¶
func (c *ChannelFull) GetStickerset() (value StickerSet, ok bool)
GetStickerset returns value of Stickerset conditional field and boolean which is true if field was set.
func (*ChannelFull) SetAdminsCount ¶
func (c *ChannelFull) SetAdminsCount(value int)
SetAdminsCount sets value of AdminsCount conditional field.
func (*ChannelFull) SetAvailableMinID ¶
func (c *ChannelFull) SetAvailableMinID(value int)
SetAvailableMinID sets value of AvailableMinID conditional field.
func (*ChannelFull) SetBannedCount ¶
func (c *ChannelFull) SetBannedCount(value int)
SetBannedCount sets value of BannedCount conditional field.
func (*ChannelFull) SetBlocked ¶
func (c *ChannelFull) SetBlocked(value bool)
SetBlocked sets value of Blocked conditional field.
func (*ChannelFull) SetCall ¶ added in v0.13.0
func (c *ChannelFull) SetCall(value InputGroupCall)
SetCall sets value of Call conditional field.
func (*ChannelFull) SetCanSetLocation ¶
func (c *ChannelFull) SetCanSetLocation(value bool)
SetCanSetLocation sets value of CanSetLocation conditional field.
func (*ChannelFull) SetCanSetStickers ¶
func (c *ChannelFull) SetCanSetStickers(value bool)
SetCanSetStickers sets value of CanSetStickers conditional field.
func (*ChannelFull) SetCanSetUsername ¶
func (c *ChannelFull) SetCanSetUsername(value bool)
SetCanSetUsername sets value of CanSetUsername conditional field.
func (*ChannelFull) SetCanViewParticipants ¶
func (c *ChannelFull) SetCanViewParticipants(value bool)
SetCanViewParticipants sets value of CanViewParticipants conditional field.
func (*ChannelFull) SetCanViewStats ¶
func (c *ChannelFull) SetCanViewStats(value bool)
SetCanViewStats sets value of CanViewStats conditional field.
func (*ChannelFull) SetFolderID ¶
func (c *ChannelFull) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*ChannelFull) SetHasScheduled ¶
func (c *ChannelFull) SetHasScheduled(value bool)
SetHasScheduled sets value of HasScheduled conditional field.
func (*ChannelFull) SetHiddenPrehistory ¶
func (c *ChannelFull) SetHiddenPrehistory(value bool)
SetHiddenPrehistory sets value of HiddenPrehistory conditional field.
func (*ChannelFull) SetKickedCount ¶
func (c *ChannelFull) SetKickedCount(value int)
SetKickedCount sets value of KickedCount conditional field.
func (*ChannelFull) SetLinkedChatID ¶
func (c *ChannelFull) SetLinkedChatID(value int)
SetLinkedChatID sets value of LinkedChatID conditional field.
func (*ChannelFull) SetLocation ¶
func (c *ChannelFull) SetLocation(value ChannelLocationClass)
SetLocation sets value of Location conditional field.
func (*ChannelFull) SetMigratedFromChatID ¶
func (c *ChannelFull) SetMigratedFromChatID(value int)
SetMigratedFromChatID sets value of MigratedFromChatID conditional field.
func (*ChannelFull) SetMigratedFromMaxID ¶
func (c *ChannelFull) SetMigratedFromMaxID(value int)
SetMigratedFromMaxID sets value of MigratedFromMaxID conditional field.
func (*ChannelFull) SetOnlineCount ¶
func (c *ChannelFull) SetOnlineCount(value int)
SetOnlineCount sets value of OnlineCount conditional field.
func (*ChannelFull) SetParticipantsCount ¶
func (c *ChannelFull) SetParticipantsCount(value int)
SetParticipantsCount sets value of ParticipantsCount conditional field.
func (*ChannelFull) SetPinnedMsgID ¶
func (c *ChannelFull) SetPinnedMsgID(value int)
SetPinnedMsgID sets value of PinnedMsgID conditional field.
func (*ChannelFull) SetSlowmodeNextSendDate ¶
func (c *ChannelFull) SetSlowmodeNextSendDate(value int)
SetSlowmodeNextSendDate sets value of SlowmodeNextSendDate conditional field.
func (*ChannelFull) SetSlowmodeSeconds ¶
func (c *ChannelFull) SetSlowmodeSeconds(value int)
SetSlowmodeSeconds sets value of SlowmodeSeconds conditional field.
func (*ChannelFull) SetStatsDC ¶
func (c *ChannelFull) SetStatsDC(value int)
SetStatsDC sets value of StatsDC conditional field.
func (*ChannelFull) SetStickerset ¶
func (c *ChannelFull) SetStickerset(value StickerSet)
SetStickerset sets value of Stickerset conditional field.
func (*ChannelFull) String ¶ added in v0.12.0
func (c *ChannelFull) String() string
String implements fmt.Stringer.
type ChannelHandler ¶ added in v0.9.0
type ChannelHandler func(ctx UpdateContext, update *UpdateChannel) error
ChannelHandler is a Channel event handler.
type ChannelLocation ¶
type ChannelLocation struct {
// Geographical location of supergrup
GeoPoint GeoPointClass
// Textual description of the address
Address string
}
ChannelLocation represents TL type `channelLocation#209b82db`. Geographical location of supergroup (geogroups)
See https://core.telegram.org/constructor/channelLocation for reference.
func (*ChannelLocation) Decode ¶
func (c *ChannelLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelLocation) Encode ¶
func (c *ChannelLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelLocation) String ¶ added in v0.12.0
func (c *ChannelLocation) String() string
String implements fmt.Stringer.
type ChannelLocationBox ¶
type ChannelLocationBox struct {
ChannelLocation ChannelLocationClass
}
ChannelLocation boxes the ChannelLocationClass providing a helper.
type ChannelLocationClass ¶
type ChannelLocationClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelLocationClass represents ChannelLocation generic type.
See https://core.telegram.org/type/ChannelLocation for reference.
Example:
g, err := DecodeChannelLocation(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelLocationEmpty: // channelLocationEmpty#bfb5ad8b
case *ChannelLocation: // channelLocation#209b82db
default: panic(v)
}
func DecodeChannelLocation ¶
func DecodeChannelLocation(buf *bin.Buffer) (ChannelLocationClass, error)
DecodeChannelLocation implements binary de-serialization for ChannelLocationClass.
type ChannelLocationEmpty ¶
type ChannelLocationEmpty struct {
}
ChannelLocationEmpty represents TL type `channelLocationEmpty#bfb5ad8b`. No location (normal supergroup)
See https://core.telegram.org/constructor/channelLocationEmpty for reference.
func (*ChannelLocationEmpty) Decode ¶
func (c *ChannelLocationEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelLocationEmpty) Encode ¶
func (c *ChannelLocationEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelLocationEmpty) String ¶ added in v0.12.0
func (c *ChannelLocationEmpty) String() string
String implements fmt.Stringer.
type ChannelMessageForwardsHandler ¶ added in v0.9.0
type ChannelMessageForwardsHandler func(ctx UpdateContext, update *UpdateChannelMessageForwards) error
ChannelMessageForwardsHandler is a ChannelMessageForwards event handler.
type ChannelMessageViewsHandler ¶ added in v0.9.0
type ChannelMessageViewsHandler func(ctx UpdateContext, update *UpdateChannelMessageViews) error
ChannelMessageViewsHandler is a ChannelMessageViews event handler.
type ChannelMessagesFilter ¶
type ChannelMessagesFilter struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to exclude new messages from the search
ExcludeNewMessages bool
// A range of messages to fetch
Ranges []MessageRange
}
ChannelMessagesFilter represents TL type `channelMessagesFilter#cd77d957`. Filter for getting only certain types of channel messages
See https://core.telegram.org/constructor/channelMessagesFilter for reference.
func (*ChannelMessagesFilter) Decode ¶
func (c *ChannelMessagesFilter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelMessagesFilter) Encode ¶
func (c *ChannelMessagesFilter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelMessagesFilter) SetExcludeNewMessages ¶
func (c *ChannelMessagesFilter) SetExcludeNewMessages(value bool)
SetExcludeNewMessages sets value of ExcludeNewMessages conditional field.
func (*ChannelMessagesFilter) String ¶ added in v0.12.0
func (c *ChannelMessagesFilter) String() string
String implements fmt.Stringer.
type ChannelMessagesFilterBox ¶
type ChannelMessagesFilterBox struct {
ChannelMessagesFilter ChannelMessagesFilterClass
}
ChannelMessagesFilter boxes the ChannelMessagesFilterClass providing a helper.
type ChannelMessagesFilterClass ¶
type ChannelMessagesFilterClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelMessagesFilterClass represents ChannelMessagesFilter generic type.
See https://core.telegram.org/type/ChannelMessagesFilter for reference.
Example:
g, err := DecodeChannelMessagesFilter(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelMessagesFilterEmpty: // channelMessagesFilterEmpty#94d42ee7
case *ChannelMessagesFilter: // channelMessagesFilter#cd77d957
default: panic(v)
}
func DecodeChannelMessagesFilter ¶
func DecodeChannelMessagesFilter(buf *bin.Buffer) (ChannelMessagesFilterClass, error)
DecodeChannelMessagesFilter implements binary de-serialization for ChannelMessagesFilterClass.
type ChannelMessagesFilterEmpty ¶
type ChannelMessagesFilterEmpty struct {
}
ChannelMessagesFilterEmpty represents TL type `channelMessagesFilterEmpty#94d42ee7`. No filter
See https://core.telegram.org/constructor/channelMessagesFilterEmpty for reference.
func (*ChannelMessagesFilterEmpty) Decode ¶
func (c *ChannelMessagesFilterEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelMessagesFilterEmpty) Encode ¶
func (c *ChannelMessagesFilterEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelMessagesFilterEmpty) String ¶ added in v0.12.0
func (c *ChannelMessagesFilterEmpty) String() string
String implements fmt.Stringer.
type ChannelParticipant ¶
ChannelParticipant represents TL type `channelParticipant#15ebac1d`. Channel/supergroup participant
See https://core.telegram.org/constructor/channelParticipant for reference.
func (*ChannelParticipant) Decode ¶
func (c *ChannelParticipant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipant) Encode ¶
func (c *ChannelParticipant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipant) String ¶ added in v0.12.0
func (c *ChannelParticipant) String() string
String implements fmt.Stringer.
type ChannelParticipantAdmin ¶
type ChannelParticipantAdmin struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Can this admin promote other admins with the same permissions?
CanEdit bool
// Is this the current user
Self bool
// Admin user ID
UserID int
// User that invited the admin to the channel/group
//
// Use SetInviterID and GetInviterID helpers.
InviterID int
// User that promoted the user to admin
PromotedBy int
// When did the user join
Date int
// Admin rights¹
//
// Links:
// 1) https://core.telegram.org/api/rights
AdminRights ChatAdminRights
// The role (rank) of the admin in the group: just an arbitrary string, admin by default
//
// Use SetRank and GetRank helpers.
Rank string
}
ChannelParticipantAdmin represents TL type `channelParticipantAdmin#ccbebbaf`. Admin
See https://core.telegram.org/constructor/channelParticipantAdmin for reference.
func (*ChannelParticipantAdmin) Decode ¶
func (c *ChannelParticipantAdmin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantAdmin) Encode ¶
func (c *ChannelParticipantAdmin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantAdmin) GetInviterID ¶
func (c *ChannelParticipantAdmin) GetInviterID() (value int, ok bool)
GetInviterID returns value of InviterID conditional field and boolean which is true if field was set.
func (*ChannelParticipantAdmin) GetRank ¶
func (c *ChannelParticipantAdmin) GetRank() (value string, ok bool)
GetRank returns value of Rank conditional field and boolean which is true if field was set.
func (*ChannelParticipantAdmin) SetCanEdit ¶
func (c *ChannelParticipantAdmin) SetCanEdit(value bool)
SetCanEdit sets value of CanEdit conditional field.
func (*ChannelParticipantAdmin) SetInviterID ¶
func (c *ChannelParticipantAdmin) SetInviterID(value int)
SetInviterID sets value of InviterID conditional field.
func (*ChannelParticipantAdmin) SetRank ¶
func (c *ChannelParticipantAdmin) SetRank(value string)
SetRank sets value of Rank conditional field.
func (*ChannelParticipantAdmin) SetSelf ¶
func (c *ChannelParticipantAdmin) SetSelf(value bool)
SetSelf sets value of Self conditional field.
func (*ChannelParticipantAdmin) String ¶ added in v0.12.0
func (c *ChannelParticipantAdmin) String() string
String implements fmt.Stringer.
type ChannelParticipantBanned ¶
type ChannelParticipantBanned struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user has left the group
Left bool
// User ID
UserID int
// User was kicked by the specified admin
KickedBy int
// When did the user join the group
Date int
// Banned rights¹
//
// Links:
// 1) https://core.telegram.org/api/rights
BannedRights ChatBannedRights
}
ChannelParticipantBanned represents TL type `channelParticipantBanned#1c0facaf`. Banned/kicked user
See https://core.telegram.org/constructor/channelParticipantBanned for reference.
func (*ChannelParticipantBanned) Decode ¶
func (c *ChannelParticipantBanned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantBanned) Encode ¶
func (c *ChannelParticipantBanned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantBanned) SetLeft ¶
func (c *ChannelParticipantBanned) SetLeft(value bool)
SetLeft sets value of Left conditional field.
func (*ChannelParticipantBanned) String ¶ added in v0.12.0
func (c *ChannelParticipantBanned) String() string
String implements fmt.Stringer.
type ChannelParticipantBox ¶
type ChannelParticipantBox struct {
ChannelParticipant ChannelParticipantClass
}
ChannelParticipant boxes the ChannelParticipantClass providing a helper.
type ChannelParticipantClass ¶
type ChannelParticipantClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelParticipantClass represents ChannelParticipant generic type.
See https://core.telegram.org/type/ChannelParticipant for reference.
Example:
g, err := DecodeChannelParticipant(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelParticipant: // channelParticipant#15ebac1d
case *ChannelParticipantSelf: // channelParticipantSelf#a3289a6d
case *ChannelParticipantCreator: // channelParticipantCreator#447dca4b
case *ChannelParticipantAdmin: // channelParticipantAdmin#ccbebbaf
case *ChannelParticipantBanned: // channelParticipantBanned#1c0facaf
case *ChannelParticipantLeft: // channelParticipantLeft#c3c6796b
default: panic(v)
}
func DecodeChannelParticipant ¶
func DecodeChannelParticipant(buf *bin.Buffer) (ChannelParticipantClass, error)
DecodeChannelParticipant implements binary de-serialization for ChannelParticipantClass.
type ChannelParticipantCreator ¶
type ChannelParticipantCreator struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// User ID
UserID int
// Creator admin rights
AdminRights ChatAdminRights
// The role (rank) of the group creator in the group: just an arbitrary string, admin by default
//
// Use SetRank and GetRank helpers.
Rank string
}
ChannelParticipantCreator represents TL type `channelParticipantCreator#447dca4b`. Channel/supergroup creator
See https://core.telegram.org/constructor/channelParticipantCreator for reference.
func (*ChannelParticipantCreator) Decode ¶
func (c *ChannelParticipantCreator) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantCreator) Encode ¶
func (c *ChannelParticipantCreator) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantCreator) GetRank ¶
func (c *ChannelParticipantCreator) GetRank() (value string, ok bool)
GetRank returns value of Rank conditional field and boolean which is true if field was set.
func (*ChannelParticipantCreator) SetRank ¶
func (c *ChannelParticipantCreator) SetRank(value string)
SetRank sets value of Rank conditional field.
func (*ChannelParticipantCreator) String ¶ added in v0.12.0
func (c *ChannelParticipantCreator) String() string
String implements fmt.Stringer.
type ChannelParticipantHandler ¶ added in v0.9.0
type ChannelParticipantHandler func(ctx UpdateContext, update *UpdateChannelParticipant) error
ChannelParticipantHandler is a ChannelParticipant event handler.
type ChannelParticipantLeft ¶
type ChannelParticipantLeft struct {
// User ID
UserID int
}
ChannelParticipantLeft represents TL type `channelParticipantLeft#c3c6796b`. A participant that left the channel/supergroup
See https://core.telegram.org/constructor/channelParticipantLeft for reference.
func (*ChannelParticipantLeft) Decode ¶
func (c *ChannelParticipantLeft) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantLeft) Encode ¶
func (c *ChannelParticipantLeft) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantLeft) String ¶ added in v0.12.0
func (c *ChannelParticipantLeft) String() string
String implements fmt.Stringer.
type ChannelParticipantSelf ¶
type ChannelParticipantSelf struct {
// User ID
UserID int
// User that invited me to the channel/supergroup
InviterID int
// When did I join the channel/supergroup
Date int
}
ChannelParticipantSelf represents TL type `channelParticipantSelf#a3289a6d`. Myself
See https://core.telegram.org/constructor/channelParticipantSelf for reference.
func (*ChannelParticipantSelf) Decode ¶
func (c *ChannelParticipantSelf) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantSelf) Encode ¶
func (c *ChannelParticipantSelf) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantSelf) String ¶ added in v0.12.0
func (c *ChannelParticipantSelf) String() string
String implements fmt.Stringer.
type ChannelParticipantsAdmins ¶
type ChannelParticipantsAdmins struct {
}
ChannelParticipantsAdmins represents TL type `channelParticipantsAdmins#b4608969`. Fetch only admin participants
See https://core.telegram.org/constructor/channelParticipantsAdmins for reference.
func (*ChannelParticipantsAdmins) Decode ¶
func (c *ChannelParticipantsAdmins) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsAdmins) Encode ¶
func (c *ChannelParticipantsAdmins) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsAdmins) String ¶ added in v0.12.0
func (c *ChannelParticipantsAdmins) String() string
String implements fmt.Stringer.
type ChannelParticipantsBanned ¶
type ChannelParticipantsBanned struct {
// Optional filter for searching banned participants by name (otherwise empty)
Q string
}
ChannelParticipantsBanned represents TL type `channelParticipantsBanned#1427a5e1`. Fetch only banned participants
See https://core.telegram.org/constructor/channelParticipantsBanned for reference.
func (*ChannelParticipantsBanned) Decode ¶
func (c *ChannelParticipantsBanned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsBanned) Encode ¶
func (c *ChannelParticipantsBanned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsBanned) String ¶ added in v0.12.0
func (c *ChannelParticipantsBanned) String() string
String implements fmt.Stringer.
type ChannelParticipantsBots ¶
type ChannelParticipantsBots struct {
}
ChannelParticipantsBots represents TL type `channelParticipantsBots#b0d1865b`. Fetch only bot participants
See https://core.telegram.org/constructor/channelParticipantsBots for reference.
func (*ChannelParticipantsBots) Decode ¶
func (c *ChannelParticipantsBots) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsBots) Encode ¶
func (c *ChannelParticipantsBots) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsBots) String ¶ added in v0.12.0
func (c *ChannelParticipantsBots) String() string
String implements fmt.Stringer.
type ChannelParticipantsContacts ¶
type ChannelParticipantsContacts struct {
// Optional search query for searching contact participants by name
Q string
}
ChannelParticipantsContacts represents TL type `channelParticipantsContacts#bb6ae88d`. Fetch only participants that are also contacts
See https://core.telegram.org/constructor/channelParticipantsContacts for reference.
func (*ChannelParticipantsContacts) Decode ¶
func (c *ChannelParticipantsContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsContacts) Encode ¶
func (c *ChannelParticipantsContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsContacts) String ¶ added in v0.12.0
func (c *ChannelParticipantsContacts) String() string
String implements fmt.Stringer.
type ChannelParticipantsFilterBox ¶
type ChannelParticipantsFilterBox struct {
ChannelParticipantsFilter ChannelParticipantsFilterClass
}
ChannelParticipantsFilter boxes the ChannelParticipantsFilterClass providing a helper.
type ChannelParticipantsFilterClass ¶
type ChannelParticipantsFilterClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelParticipantsFilterClass represents ChannelParticipantsFilter generic type.
See https://core.telegram.org/type/ChannelParticipantsFilter for reference.
Example:
g, err := DecodeChannelParticipantsFilter(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelParticipantsRecent: // channelParticipantsRecent#de3f3c79
case *ChannelParticipantsAdmins: // channelParticipantsAdmins#b4608969
case *ChannelParticipantsKicked: // channelParticipantsKicked#a3b54985
case *ChannelParticipantsBots: // channelParticipantsBots#b0d1865b
case *ChannelParticipantsBanned: // channelParticipantsBanned#1427a5e1
case *ChannelParticipantsSearch: // channelParticipantsSearch#656ac4b
case *ChannelParticipantsContacts: // channelParticipantsContacts#bb6ae88d
case *ChannelParticipantsMentions: // channelParticipantsMentions#e04b5ceb
default: panic(v)
}
func DecodeChannelParticipantsFilter ¶
func DecodeChannelParticipantsFilter(buf *bin.Buffer) (ChannelParticipantsFilterClass, error)
DecodeChannelParticipantsFilter implements binary de-serialization for ChannelParticipantsFilterClass.
type ChannelParticipantsKicked ¶
type ChannelParticipantsKicked struct {
// Optional filter for searching kicked participants by name (otherwise empty)
Q string
}
ChannelParticipantsKicked represents TL type `channelParticipantsKicked#a3b54985`. Fetch only kicked participants
See https://core.telegram.org/constructor/channelParticipantsKicked for reference.
func (*ChannelParticipantsKicked) Decode ¶
func (c *ChannelParticipantsKicked) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsKicked) Encode ¶
func (c *ChannelParticipantsKicked) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsKicked) String ¶ added in v0.12.0
func (c *ChannelParticipantsKicked) String() string
String implements fmt.Stringer.
type ChannelParticipantsMentions ¶
type ChannelParticipantsMentions struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Filter by user name or username
//
// Use SetQ and GetQ helpers.
Q string
// Look only for users that posted in this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetTopMsgID and GetTopMsgID helpers.
TopMsgID int
}
ChannelParticipantsMentions represents TL type `channelParticipantsMentions#e04b5ceb`. This filter is used when looking for supergroup members to mention. This filter will automatically remove anonymous admins, and return even non-participant users that replied to a specific thread¹ through the comment section² of a channel.
Links:
See https://core.telegram.org/constructor/channelParticipantsMentions for reference.
func (*ChannelParticipantsMentions) Decode ¶
func (c *ChannelParticipantsMentions) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsMentions) Encode ¶
func (c *ChannelParticipantsMentions) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsMentions) GetQ ¶
func (c *ChannelParticipantsMentions) GetQ() (value string, ok bool)
GetQ returns value of Q conditional field and boolean which is true if field was set.
func (*ChannelParticipantsMentions) GetTopMsgID ¶
func (c *ChannelParticipantsMentions) GetTopMsgID() (value int, ok bool)
GetTopMsgID returns value of TopMsgID conditional field and boolean which is true if field was set.
func (*ChannelParticipantsMentions) SetQ ¶
func (c *ChannelParticipantsMentions) SetQ(value string)
SetQ sets value of Q conditional field.
func (*ChannelParticipantsMentions) SetTopMsgID ¶
func (c *ChannelParticipantsMentions) SetTopMsgID(value int)
SetTopMsgID sets value of TopMsgID conditional field.
func (*ChannelParticipantsMentions) String ¶ added in v0.12.0
func (c *ChannelParticipantsMentions) String() string
String implements fmt.Stringer.
type ChannelParticipantsRecent ¶
type ChannelParticipantsRecent struct {
}
ChannelParticipantsRecent represents TL type `channelParticipantsRecent#de3f3c79`. Fetch only recent participants
See https://core.telegram.org/constructor/channelParticipantsRecent for reference.
func (*ChannelParticipantsRecent) Decode ¶
func (c *ChannelParticipantsRecent) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsRecent) Encode ¶
func (c *ChannelParticipantsRecent) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsRecent) String ¶ added in v0.12.0
func (c *ChannelParticipantsRecent) String() string
String implements fmt.Stringer.
type ChannelParticipantsSearch ¶
type ChannelParticipantsSearch struct {
// Search query
Q string
}
ChannelParticipantsSearch represents TL type `channelParticipantsSearch#656ac4b`. Query participants by name
See https://core.telegram.org/constructor/channelParticipantsSearch for reference.
func (*ChannelParticipantsSearch) Decode ¶
func (c *ChannelParticipantsSearch) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelParticipantsSearch) Encode ¶
func (c *ChannelParticipantsSearch) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelParticipantsSearch) String ¶ added in v0.12.0
func (c *ChannelParticipantsSearch) String() string
String implements fmt.Stringer.
type ChannelReadMessagesContentsHandler ¶ added in v0.9.0
type ChannelReadMessagesContentsHandler func(ctx UpdateContext, update *UpdateChannelReadMessagesContents) error
ChannelReadMessagesContentsHandler is a ChannelReadMessagesContents event handler.
type ChannelTooLongHandler ¶ added in v0.9.0
type ChannelTooLongHandler func(ctx UpdateContext, update *UpdateChannelTooLong) error
ChannelTooLongHandler is a ChannelTooLong event handler.
type ChannelUserTypingHandler ¶ added in v0.9.0
type ChannelUserTypingHandler func(ctx UpdateContext, update *UpdateChannelUserTyping) error
ChannelUserTypingHandler is a ChannelUserTyping event handler.
type ChannelWebPageHandler ¶ added in v0.9.0
type ChannelWebPageHandler func(ctx UpdateContext, update *UpdateChannelWebPage) error
ChannelWebPageHandler is a ChannelWebPage event handler.
type ChannelsAdminLogResults ¶
type ChannelsAdminLogResults struct {
// Admin log events
Events []ChannelAdminLogEvent
// Chats mentioned in events
Chats []ChatClass
// Users mentioned in events
Users []UserClass
}
ChannelsAdminLogResults represents TL type `channels.adminLogResults#ed8af74d`. Admin log events
See https://core.telegram.org/constructor/channels.adminLogResults for reference.
func (*ChannelsAdminLogResults) Decode ¶
func (a *ChannelsAdminLogResults) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsAdminLogResults) Encode ¶
func (a *ChannelsAdminLogResults) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsAdminLogResults) String ¶ added in v0.12.0
func (a *ChannelsAdminLogResults) String() string
String implements fmt.Stringer.
type ChannelsChannelParticipant ¶
type ChannelsChannelParticipant struct {
// The channel participant
Participant ChannelParticipantClass
// Users
Users []UserClass
}
ChannelsChannelParticipant represents TL type `channels.channelParticipant#d0d9b163`. Represents a channel participant
See https://core.telegram.org/constructor/channels.channelParticipant for reference.
func (*ChannelsChannelParticipant) Decode ¶
func (c *ChannelsChannelParticipant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsChannelParticipant) Encode ¶
func (c *ChannelsChannelParticipant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsChannelParticipant) String ¶ added in v0.12.0
func (c *ChannelsChannelParticipant) String() string
String implements fmt.Stringer.
type ChannelsChannelParticipants ¶
type ChannelsChannelParticipants struct {
// Total number of participants that correspond to the given query
Count int
// Participants
Participants []ChannelParticipantClass
// Users mentioned in participant info
Users []UserClass
}
ChannelsChannelParticipants represents TL type `channels.channelParticipants#f56ee2a8`. Represents multiple channel participants
See https://core.telegram.org/constructor/channels.channelParticipants for reference.
func (*ChannelsChannelParticipants) Decode ¶
func (c *ChannelsChannelParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsChannelParticipants) Encode ¶
func (c *ChannelsChannelParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsChannelParticipants) String ¶ added in v0.12.0
func (c *ChannelsChannelParticipants) String() string
String implements fmt.Stringer.
type ChannelsChannelParticipantsBox ¶
type ChannelsChannelParticipantsBox struct {
ChannelParticipants ChannelsChannelParticipantsClass
}
ChannelsChannelParticipants boxes the ChannelsChannelParticipantsClass providing a helper.
type ChannelsChannelParticipantsClass ¶
type ChannelsChannelParticipantsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChannelsChannelParticipantsClass represents channels.ChannelParticipants generic type.
See https://core.telegram.org/type/channels.ChannelParticipants for reference.
Example:
g, err := DecodeChannelsChannelParticipants(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChannelsChannelParticipants: // channels.channelParticipants#f56ee2a8
case *ChannelsChannelParticipantsNotModified: // channels.channelParticipantsNotModified#f0173fe9
default: panic(v)
}
func DecodeChannelsChannelParticipants ¶
func DecodeChannelsChannelParticipants(buf *bin.Buffer) (ChannelsChannelParticipantsClass, error)
DecodeChannelsChannelParticipants implements binary de-serialization for ChannelsChannelParticipantsClass.
type ChannelsChannelParticipantsNotModified ¶
type ChannelsChannelParticipantsNotModified struct {
}
ChannelsChannelParticipantsNotModified represents TL type `channels.channelParticipantsNotModified#f0173fe9`. No new participant info could be found
See https://core.telegram.org/constructor/channels.channelParticipantsNotModified for reference.
func (*ChannelsChannelParticipantsNotModified) Decode ¶
func (c *ChannelsChannelParticipantsNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsChannelParticipantsNotModified) Encode ¶
func (c *ChannelsChannelParticipantsNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsChannelParticipantsNotModified) String ¶ added in v0.12.0
func (c *ChannelsChannelParticipantsNotModified) String() string
String implements fmt.Stringer.
type ChannelsCheckUsernameRequest ¶
type ChannelsCheckUsernameRequest struct {
// The channel/supergroup¹ that will assigned the specified username
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// The username to check
Username string
}
ChannelsCheckUsernameRequest represents TL type `channels.checkUsername#10e6bd2c`. Check if a username is free and can be assigned to a channel/supergroup
See https://core.telegram.org/method/channels.checkUsername for reference.
func (*ChannelsCheckUsernameRequest) Decode ¶
func (c *ChannelsCheckUsernameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsCheckUsernameRequest) Encode ¶
func (c *ChannelsCheckUsernameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsCheckUsernameRequest) String ¶ added in v0.12.0
func (c *ChannelsCheckUsernameRequest) String() string
String implements fmt.Stringer.
type ChannelsCreateChannelRequest ¶
type ChannelsCreateChannelRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to create a channel¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Broadcast bool
// Whether to create a supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Megagroup bool
// Channel title
Title string
// Channel description
About string
// Geogroup location
//
// Use SetGeoPoint and GetGeoPoint helpers.
GeoPoint InputGeoPointClass
// Geogroup address
//
// Use SetAddress and GetAddress helpers.
Address string
}
ChannelsCreateChannelRequest represents TL type `channels.createChannel#3d5fb10f`. Create a supergroup/channel¹.
Links:
See https://core.telegram.org/method/channels.createChannel for reference.
func (*ChannelsCreateChannelRequest) Decode ¶
func (c *ChannelsCreateChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsCreateChannelRequest) Encode ¶
func (c *ChannelsCreateChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsCreateChannelRequest) GetAddress ¶
func (c *ChannelsCreateChannelRequest) GetAddress() (value string, ok bool)
GetAddress returns value of Address conditional field and boolean which is true if field was set.
func (*ChannelsCreateChannelRequest) GetGeoPoint ¶
func (c *ChannelsCreateChannelRequest) GetGeoPoint() (value InputGeoPointClass, ok bool)
GetGeoPoint returns value of GeoPoint conditional field and boolean which is true if field was set.
func (*ChannelsCreateChannelRequest) SetAddress ¶
func (c *ChannelsCreateChannelRequest) SetAddress(value string)
SetAddress sets value of Address conditional field.
func (*ChannelsCreateChannelRequest) SetBroadcast ¶
func (c *ChannelsCreateChannelRequest) SetBroadcast(value bool)
SetBroadcast sets value of Broadcast conditional field.
func (*ChannelsCreateChannelRequest) SetGeoPoint ¶
func (c *ChannelsCreateChannelRequest) SetGeoPoint(value InputGeoPointClass)
SetGeoPoint sets value of GeoPoint conditional field.
func (*ChannelsCreateChannelRequest) SetMegagroup ¶
func (c *ChannelsCreateChannelRequest) SetMegagroup(value bool)
SetMegagroup sets value of Megagroup conditional field.
func (*ChannelsCreateChannelRequest) String ¶ added in v0.12.0
func (c *ChannelsCreateChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsDeleteChannelRequest ¶
type ChannelsDeleteChannelRequest struct {
// Channel/supergroup¹ to delete
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
}
ChannelsDeleteChannelRequest represents TL type `channels.deleteChannel#c0111fe3`. Delete a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.deleteChannel for reference.
func (*ChannelsDeleteChannelRequest) Decode ¶
func (d *ChannelsDeleteChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsDeleteChannelRequest) Encode ¶
func (d *ChannelsDeleteChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsDeleteChannelRequest) String ¶ added in v0.12.0
func (d *ChannelsDeleteChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsDeleteHistoryRequest ¶
type ChannelsDeleteHistoryRequest struct {
// Supergroup¹ whose history must be deleted
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// ID of message up to which the history must be deleted
MaxID int
}
ChannelsDeleteHistoryRequest represents TL type `channels.deleteHistory#af369d42`. Delete the history of a supergroup¹
Links:
See https://core.telegram.org/method/channels.deleteHistory for reference.
func (*ChannelsDeleteHistoryRequest) Decode ¶
func (d *ChannelsDeleteHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsDeleteHistoryRequest) Encode ¶
func (d *ChannelsDeleteHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsDeleteHistoryRequest) String ¶ added in v0.12.0
func (d *ChannelsDeleteHistoryRequest) String() string
String implements fmt.Stringer.
type ChannelsDeleteMessagesRequest ¶
type ChannelsDeleteMessagesRequest struct {
// Channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// IDs of messages to delete
ID []int
}
ChannelsDeleteMessagesRequest represents TL type `channels.deleteMessages#84c1fd4e`. Delete messages in a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.deleteMessages for reference.
func (*ChannelsDeleteMessagesRequest) Decode ¶
func (d *ChannelsDeleteMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsDeleteMessagesRequest) Encode ¶
func (d *ChannelsDeleteMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsDeleteMessagesRequest) String ¶ added in v0.12.0
func (d *ChannelsDeleteMessagesRequest) String() string
String implements fmt.Stringer.
type ChannelsDeleteUserHistoryRequest ¶
type ChannelsDeleteUserHistoryRequest struct {
// Supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// User whose messages should be deleted
UserID InputUserClass
}
ChannelsDeleteUserHistoryRequest represents TL type `channels.deleteUserHistory#d10dd71b`. Delete all messages sent by a certain user in a supergroup¹
Links:
See https://core.telegram.org/method/channels.deleteUserHistory for reference.
func (*ChannelsDeleteUserHistoryRequest) Decode ¶
func (d *ChannelsDeleteUserHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsDeleteUserHistoryRequest) Encode ¶
func (d *ChannelsDeleteUserHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsDeleteUserHistoryRequest) String ¶ added in v0.12.0
func (d *ChannelsDeleteUserHistoryRequest) String() string
String implements fmt.Stringer.
type ChannelsEditAdminRequest ¶
type ChannelsEditAdminRequest struct {
// The supergroup/channel¹.
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// The ID of the user whose admin rights should be modified
UserID InputUserClass
// The admin rights
AdminRights ChatAdminRights
// Indicates the role (rank) of the admin in the group: just an arbitrary string
Rank string
}
ChannelsEditAdminRequest represents TL type `channels.editAdmin#d33c8902`. Modify the admin rights of a user in a supergroup/channel¹.
Links:
See https://core.telegram.org/method/channels.editAdmin for reference.
func (*ChannelsEditAdminRequest) Decode ¶
func (e *ChannelsEditAdminRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditAdminRequest) Encode ¶
func (e *ChannelsEditAdminRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditAdminRequest) String ¶ added in v0.12.0
func (e *ChannelsEditAdminRequest) String() string
String implements fmt.Stringer.
type ChannelsEditBannedRequest ¶
type ChannelsEditBannedRequest struct {
// The supergroup/channel¹.
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// The ID of the user whose banned rights should be modified
UserID InputUserClass
// The banned rights
BannedRights ChatBannedRights
}
ChannelsEditBannedRequest represents TL type `channels.editBanned#72796912`. Ban/unban/kick a user in a supergroup/channel¹.
Links:
See https://core.telegram.org/method/channels.editBanned for reference.
func (*ChannelsEditBannedRequest) Decode ¶
func (e *ChannelsEditBannedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditBannedRequest) Encode ¶
func (e *ChannelsEditBannedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditBannedRequest) String ¶ added in v0.12.0
func (e *ChannelsEditBannedRequest) String() string
String implements fmt.Stringer.
type ChannelsEditCreatorRequest ¶
type ChannelsEditCreatorRequest struct {
// Channel
Channel InputChannelClass
// New channel owner
UserID InputUserClass
// 2FA password¹ of account
//
// Links:
// 1) https://core.telegram.org/api/srp
Password InputCheckPasswordSRPClass
}
ChannelsEditCreatorRequest represents TL type `channels.editCreator#8f38cd1f`. Transfer channel ownership
See https://core.telegram.org/method/channels.editCreator for reference.
func (*ChannelsEditCreatorRequest) Decode ¶
func (e *ChannelsEditCreatorRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditCreatorRequest) Encode ¶
func (e *ChannelsEditCreatorRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditCreatorRequest) String ¶ added in v0.12.0
func (e *ChannelsEditCreatorRequest) String() string
String implements fmt.Stringer.
type ChannelsEditLocationRequest ¶
type ChannelsEditLocationRequest struct {
// Geogroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// New geolocation
GeoPoint InputGeoPointClass
// Address string
Address string
}
ChannelsEditLocationRequest represents TL type `channels.editLocation#58e63f6d`. Edit location of geogroup
See https://core.telegram.org/method/channels.editLocation for reference.
func (*ChannelsEditLocationRequest) Decode ¶
func (e *ChannelsEditLocationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditLocationRequest) Encode ¶
func (e *ChannelsEditLocationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditLocationRequest) String ¶ added in v0.12.0
func (e *ChannelsEditLocationRequest) String() string
String implements fmt.Stringer.
type ChannelsEditPhotoRequest ¶
type ChannelsEditPhotoRequest struct {
// Channel/supergroup whose photo should be edited
Channel InputChannelClass
// New photo
Photo InputChatPhotoClass
}
ChannelsEditPhotoRequest represents TL type `channels.editPhoto#f12e57c9`. Change the photo of a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.editPhoto for reference.
func (*ChannelsEditPhotoRequest) Decode ¶
func (e *ChannelsEditPhotoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditPhotoRequest) Encode ¶
func (e *ChannelsEditPhotoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditPhotoRequest) String ¶ added in v0.12.0
func (e *ChannelsEditPhotoRequest) String() string
String implements fmt.Stringer.
type ChannelsEditTitleRequest ¶
type ChannelsEditTitleRequest struct {
// Channel/supergroup
Channel InputChannelClass
// New name
Title string
}
ChannelsEditTitleRequest represents TL type `channels.editTitle#566decd0`. Edit the name of a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.editTitle for reference.
func (*ChannelsEditTitleRequest) Decode ¶
func (e *ChannelsEditTitleRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsEditTitleRequest) Encode ¶
func (e *ChannelsEditTitleRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsEditTitleRequest) String ¶ added in v0.12.0
func (e *ChannelsEditTitleRequest) String() string
String implements fmt.Stringer.
type ChannelsExportMessageLinkRequest ¶
type ChannelsExportMessageLinkRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to include other grouped media (for albums)
Grouped bool
// Whether to also include a thread ID, if available, inside of the link
Thread bool
// Channel
Channel InputChannelClass
// Message ID
ID int
}
ChannelsExportMessageLinkRequest represents TL type `channels.exportMessageLink#e63fadeb`. Get link and embed info of a message in a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.exportMessageLink for reference.
func (*ChannelsExportMessageLinkRequest) Decode ¶
func (e *ChannelsExportMessageLinkRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsExportMessageLinkRequest) Encode ¶
func (e *ChannelsExportMessageLinkRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsExportMessageLinkRequest) SetGrouped ¶
func (e *ChannelsExportMessageLinkRequest) SetGrouped(value bool)
SetGrouped sets value of Grouped conditional field.
func (*ChannelsExportMessageLinkRequest) SetThread ¶
func (e *ChannelsExportMessageLinkRequest) SetThread(value bool)
SetThread sets value of Thread conditional field.
func (*ChannelsExportMessageLinkRequest) String ¶ added in v0.12.0
func (e *ChannelsExportMessageLinkRequest) String() string
String implements fmt.Stringer.
type ChannelsGetAdminLogRequest ¶
type ChannelsGetAdminLogRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Channel
Channel InputChannelClass
// Search query, can be empty
Q string
// Event filter
//
// Use SetEventsFilter and GetEventsFilter helpers.
EventsFilter ChannelAdminLogEventsFilter
// Only show events from these admins
//
// Use SetAdmins and GetAdmins helpers.
Admins []InputUserClass
// Maximum ID of message to return (see pagination¹)
//
// Links:
// 1) https://core.telegram.org/api/offsets
MaxID int64
// Minimum ID of message to return (see pagination¹)
//
// Links:
// 1) https://core.telegram.org/api/offsets
MinID int64
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
}
ChannelsGetAdminLogRequest represents TL type `channels.getAdminLog#33ddf480`. Get the admin log of a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.getAdminLog for reference.
func (*ChannelsGetAdminLogRequest) Decode ¶
func (g *ChannelsGetAdminLogRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetAdminLogRequest) Encode ¶
func (g *ChannelsGetAdminLogRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetAdminLogRequest) GetAdmins ¶
func (g *ChannelsGetAdminLogRequest) GetAdmins() (value []InputUserClass, ok bool)
GetAdmins returns value of Admins conditional field and boolean which is true if field was set.
func (*ChannelsGetAdminLogRequest) GetEventsFilter ¶
func (g *ChannelsGetAdminLogRequest) GetEventsFilter() (value ChannelAdminLogEventsFilter, ok bool)
GetEventsFilter returns value of EventsFilter conditional field and boolean which is true if field was set.
func (*ChannelsGetAdminLogRequest) SetAdmins ¶
func (g *ChannelsGetAdminLogRequest) SetAdmins(value []InputUserClass)
SetAdmins sets value of Admins conditional field.
func (*ChannelsGetAdminLogRequest) SetEventsFilter ¶
func (g *ChannelsGetAdminLogRequest) SetEventsFilter(value ChannelAdminLogEventsFilter)
SetEventsFilter sets value of EventsFilter conditional field.
func (*ChannelsGetAdminLogRequest) String ¶ added in v0.12.0
func (g *ChannelsGetAdminLogRequest) String() string
String implements fmt.Stringer.
type ChannelsGetAdminedPublicChannelsRequest ¶
type ChannelsGetAdminedPublicChannelsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Get geogroups
ByLocation bool
// If set and the user has reached the limit of owned public channels/supergroups/geogroups¹, instead of returning the channel list one of the specified errors² will be returned.Useful to check if a new public channel can indeed be created, even before asking the user to enter a channel username to use in channels.checkUsername³/channels.updateUsername⁴.
//
// Links:
// 1) https://core.telegram.org/api/channel
// 2) https://core.telegram.org#possible-errors
// 3) https://core.telegram.org/method/channels.checkUsername
// 4) https://core.telegram.org/method/channels.updateUsername
CheckLimit bool
}
ChannelsGetAdminedPublicChannelsRequest represents TL type `channels.getAdminedPublicChannels#f8b036af`. Get channels/supergroups/geogroups¹ we're admin in. Usually called when the user exceeds the limit² for owned public channels/supergroups/geogroups³, and the user is given the choice to remove one of his channels/supergroups/geogroups.
Links:
- https://core.telegram.org/api/channel
- https://core.telegram.org/constructor/config
- https://core.telegram.org/api/channel
See https://core.telegram.org/method/channels.getAdminedPublicChannels for reference.
func (*ChannelsGetAdminedPublicChannelsRequest) Decode ¶
func (g *ChannelsGetAdminedPublicChannelsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetAdminedPublicChannelsRequest) Encode ¶
func (g *ChannelsGetAdminedPublicChannelsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetAdminedPublicChannelsRequest) SetByLocation ¶
func (g *ChannelsGetAdminedPublicChannelsRequest) SetByLocation(value bool)
SetByLocation sets value of ByLocation conditional field.
func (*ChannelsGetAdminedPublicChannelsRequest) SetCheckLimit ¶
func (g *ChannelsGetAdminedPublicChannelsRequest) SetCheckLimit(value bool)
SetCheckLimit sets value of CheckLimit conditional field.
func (*ChannelsGetAdminedPublicChannelsRequest) String ¶ added in v0.12.0
func (g *ChannelsGetAdminedPublicChannelsRequest) String() string
String implements fmt.Stringer.
type ChannelsGetChannelsRequest ¶
type ChannelsGetChannelsRequest struct {
// IDs of channels/supergroups to get info about
ID []InputChannelClass
}
ChannelsGetChannelsRequest represents TL type `channels.getChannels#a7f6bbb`. Get info about channels/supergroups¹
Links:
See https://core.telegram.org/method/channels.getChannels for reference.
func (*ChannelsGetChannelsRequest) Decode ¶
func (g *ChannelsGetChannelsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetChannelsRequest) Encode ¶
func (g *ChannelsGetChannelsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetChannelsRequest) String ¶ added in v0.12.0
func (g *ChannelsGetChannelsRequest) String() string
String implements fmt.Stringer.
type ChannelsGetFullChannelRequest ¶
type ChannelsGetFullChannelRequest struct {
// The channel to get info about
Channel InputChannelClass
}
ChannelsGetFullChannelRequest represents TL type `channels.getFullChannel#8736a09`. Get full info about a channel
See https://core.telegram.org/method/channels.getFullChannel for reference.
func (*ChannelsGetFullChannelRequest) Decode ¶
func (g *ChannelsGetFullChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetFullChannelRequest) Encode ¶
func (g *ChannelsGetFullChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetFullChannelRequest) String ¶ added in v0.12.0
func (g *ChannelsGetFullChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsGetGroupsForDiscussionRequest ¶
type ChannelsGetGroupsForDiscussionRequest struct {
}
ChannelsGetGroupsForDiscussionRequest represents TL type `channels.getGroupsForDiscussion#f5dad378`. Get all groups that can be used as discussion groups¹. Returned legacy 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 channels.togglePreHistoryHidden³, first.
Links:
- https://core.telegram.org/api/discussion
- https://core.telegram.org/api/channel
- https://core.telegram.org/api/channel
- https://core.telegram.org/method/channels.togglePreHistoryHidden
See https://core.telegram.org/method/channels.getGroupsForDiscussion for reference.
func (*ChannelsGetGroupsForDiscussionRequest) Decode ¶
func (g *ChannelsGetGroupsForDiscussionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetGroupsForDiscussionRequest) Encode ¶
func (g *ChannelsGetGroupsForDiscussionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetGroupsForDiscussionRequest) String ¶ added in v0.12.0
func (g *ChannelsGetGroupsForDiscussionRequest) String() string
String implements fmt.Stringer.
type ChannelsGetInactiveChannelsRequest ¶
type ChannelsGetInactiveChannelsRequest struct {
}
ChannelsGetInactiveChannelsRequest represents TL type `channels.getInactiveChannels#11e831ee`. Get inactive channels and supergroups
See https://core.telegram.org/method/channels.getInactiveChannels for reference.
func (*ChannelsGetInactiveChannelsRequest) Decode ¶
func (g *ChannelsGetInactiveChannelsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetInactiveChannelsRequest) Encode ¶
func (g *ChannelsGetInactiveChannelsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetInactiveChannelsRequest) String ¶ added in v0.12.0
func (g *ChannelsGetInactiveChannelsRequest) String() string
String implements fmt.Stringer.
type ChannelsGetLeftChannelsRequest ¶
type ChannelsGetLeftChannelsRequest struct {
// Offset for pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Offset int
}
ChannelsGetLeftChannelsRequest represents TL type `channels.getLeftChannels#8341ecc0`. Get a list of channels/supergroups¹ we left
Links:
See https://core.telegram.org/method/channels.getLeftChannels for reference.
func (*ChannelsGetLeftChannelsRequest) Decode ¶
func (g *ChannelsGetLeftChannelsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetLeftChannelsRequest) Encode ¶
func (g *ChannelsGetLeftChannelsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetLeftChannelsRequest) String ¶ added in v0.12.0
func (g *ChannelsGetLeftChannelsRequest) String() string
String implements fmt.Stringer.
type ChannelsGetMessagesRequest ¶
type ChannelsGetMessagesRequest struct {
// Channel/supergroup
Channel InputChannelClass
// IDs of messages to get
ID []InputMessageClass
}
ChannelsGetMessagesRequest represents TL type `channels.getMessages#ad8c9a23`. Get channel/supergroup¹ messages
Links:
See https://core.telegram.org/method/channels.getMessages for reference.
func (*ChannelsGetMessagesRequest) Decode ¶
func (g *ChannelsGetMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetMessagesRequest) Encode ¶
func (g *ChannelsGetMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetMessagesRequest) String ¶ added in v0.12.0
func (g *ChannelsGetMessagesRequest) String() string
String implements fmt.Stringer.
type ChannelsGetParticipantRequest ¶
type ChannelsGetParticipantRequest struct {
// Channel/supergroup
Channel InputChannelClass
// ID of participant to get info about
UserID InputUserClass
}
ChannelsGetParticipantRequest represents TL type `channels.getParticipant#546dd7a6`. Get info about a channel/supergroup¹ participant
Links:
See https://core.telegram.org/method/channels.getParticipant for reference.
func (*ChannelsGetParticipantRequest) Decode ¶
func (g *ChannelsGetParticipantRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetParticipantRequest) Encode ¶
func (g *ChannelsGetParticipantRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetParticipantRequest) String ¶ added in v0.12.0
func (g *ChannelsGetParticipantRequest) String() string
String implements fmt.Stringer.
type ChannelsGetParticipantsRequest ¶
type ChannelsGetParticipantsRequest struct {
// Channel
Channel InputChannelClass
// Which participant types to fetch
Filter ChannelParticipantsFilterClass
// Offset¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Offset int
// Limit¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Hash¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Hash int
}
ChannelsGetParticipantsRequest represents TL type `channels.getParticipants#123e05e9`. Get the participants of a supergroup/channel¹
Links:
See https://core.telegram.org/method/channels.getParticipants for reference.
func (*ChannelsGetParticipantsRequest) Decode ¶
func (g *ChannelsGetParticipantsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsGetParticipantsRequest) Encode ¶
func (g *ChannelsGetParticipantsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsGetParticipantsRequest) String ¶ added in v0.12.0
func (g *ChannelsGetParticipantsRequest) String() string
String implements fmt.Stringer.
type ChannelsInviteToChannelRequest ¶
type ChannelsInviteToChannelRequest struct {
// Channel/supergroup
Channel InputChannelClass
// Users to invite
Users []InputUserClass
}
ChannelsInviteToChannelRequest represents TL type `channels.inviteToChannel#199f3a6c`. Invite users to a channel/supergroup
See https://core.telegram.org/method/channels.inviteToChannel for reference.
func (*ChannelsInviteToChannelRequest) Decode ¶
func (i *ChannelsInviteToChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsInviteToChannelRequest) Encode ¶
func (i *ChannelsInviteToChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsInviteToChannelRequest) String ¶ added in v0.12.0
func (i *ChannelsInviteToChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsJoinChannelRequest ¶
type ChannelsJoinChannelRequest struct {
// Channel/supergroup to join
Channel InputChannelClass
}
ChannelsJoinChannelRequest represents TL type `channels.joinChannel#24b524c5`. Join a channel/supergroup
See https://core.telegram.org/method/channels.joinChannel for reference.
func (*ChannelsJoinChannelRequest) Decode ¶
func (j *ChannelsJoinChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsJoinChannelRequest) Encode ¶
func (j *ChannelsJoinChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsJoinChannelRequest) String ¶ added in v0.12.0
func (j *ChannelsJoinChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsLeaveChannelRequest ¶
type ChannelsLeaveChannelRequest struct {
// Channel/supergroup¹ to leave
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
}
ChannelsLeaveChannelRequest represents TL type `channels.leaveChannel#f836aa95`. Leave a channel/supergroup¹
Links:
See https://core.telegram.org/method/channels.leaveChannel for reference.
func (*ChannelsLeaveChannelRequest) Decode ¶
func (l *ChannelsLeaveChannelRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsLeaveChannelRequest) Encode ¶
func (l *ChannelsLeaveChannelRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsLeaveChannelRequest) String ¶ added in v0.12.0
func (l *ChannelsLeaveChannelRequest) String() string
String implements fmt.Stringer.
type ChannelsReadHistoryRequest ¶
type ChannelsReadHistoryRequest struct {
// Channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// ID of message up to which messages should be marked as read
MaxID int
}
ChannelsReadHistoryRequest represents TL type `channels.readHistory#cc104937`. Mark channel/supergroup¹ history as read
Links:
See https://core.telegram.org/method/channels.readHistory for reference.
func (*ChannelsReadHistoryRequest) Decode ¶
func (r *ChannelsReadHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsReadHistoryRequest) Encode ¶
func (r *ChannelsReadHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsReadHistoryRequest) String ¶ added in v0.12.0
func (r *ChannelsReadHistoryRequest) String() string
String implements fmt.Stringer.
type ChannelsReadMessageContentsRequest ¶
type ChannelsReadMessageContentsRequest struct {
// Channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// IDs of messages whose contents should be marked as read
ID []int
}
ChannelsReadMessageContentsRequest represents TL type `channels.readMessageContents#eab5dc38`. Mark channel/supergroup¹ message contents as read
Links:
See https://core.telegram.org/method/channels.readMessageContents for reference.
func (*ChannelsReadMessageContentsRequest) Decode ¶
func (r *ChannelsReadMessageContentsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsReadMessageContentsRequest) Encode ¶
func (r *ChannelsReadMessageContentsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsReadMessageContentsRequest) String ¶ added in v0.12.0
func (r *ChannelsReadMessageContentsRequest) String() string
String implements fmt.Stringer.
type ChannelsReportSpamRequest ¶
type ChannelsReportSpamRequest struct {
// Supergroup
Channel InputChannelClass
// ID of the user that sent the spam messages
UserID InputUserClass
// IDs of spam messages
ID []int
}
ChannelsReportSpamRequest represents TL type `channels.reportSpam#fe087810`. Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup
See https://core.telegram.org/method/channels.reportSpam for reference.
func (*ChannelsReportSpamRequest) Decode ¶
func (r *ChannelsReportSpamRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsReportSpamRequest) Encode ¶
func (r *ChannelsReportSpamRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsReportSpamRequest) String ¶ added in v0.12.0
func (r *ChannelsReportSpamRequest) String() string
String implements fmt.Stringer.
type ChannelsSetDiscussionGroupRequest ¶
type ChannelsSetDiscussionGroupRequest struct {
// Channel
Broadcast InputChannelClass
// Discussion group¹ to associate to the channel
//
// Links:
// 1) https://core.telegram.org/api/discussion
Group InputChannelClass
}
ChannelsSetDiscussionGroupRequest represents TL type `channels.setDiscussionGroup#40582bb2`. Associate a group to a channel as discussion group¹ for that channel
Links:
See https://core.telegram.org/method/channels.setDiscussionGroup for reference.
func (*ChannelsSetDiscussionGroupRequest) Decode ¶
func (s *ChannelsSetDiscussionGroupRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsSetDiscussionGroupRequest) Encode ¶
func (s *ChannelsSetDiscussionGroupRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsSetDiscussionGroupRequest) String ¶ added in v0.12.0
func (s *ChannelsSetDiscussionGroupRequest) String() string
String implements fmt.Stringer.
type ChannelsSetStickersRequest ¶
type ChannelsSetStickersRequest struct {
// Supergroup
Channel InputChannelClass
// The stickerset to associate
Stickerset InputStickerSetClass
}
ChannelsSetStickersRequest represents TL type `channels.setStickers#ea8ca4f9`. Associate a stickerset to the supergroup
See https://core.telegram.org/method/channels.setStickers for reference.
func (*ChannelsSetStickersRequest) Decode ¶
func (s *ChannelsSetStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsSetStickersRequest) Encode ¶
func (s *ChannelsSetStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsSetStickersRequest) String ¶ added in v0.12.0
func (s *ChannelsSetStickersRequest) String() string
String implements fmt.Stringer.
type ChannelsTogglePreHistoryHiddenRequest ¶
type ChannelsTogglePreHistoryHiddenRequest struct {
// Channel/supergroup
Channel InputChannelClass
// Hide/unhide
Enabled bool
}
ChannelsTogglePreHistoryHiddenRequest represents TL type `channels.togglePreHistoryHidden#eabbb94c`. Hide/unhide message history for new channel/supergroup users
See https://core.telegram.org/method/channels.togglePreHistoryHidden for reference.
func (*ChannelsTogglePreHistoryHiddenRequest) Decode ¶
func (t *ChannelsTogglePreHistoryHiddenRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsTogglePreHistoryHiddenRequest) Encode ¶
func (t *ChannelsTogglePreHistoryHiddenRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsTogglePreHistoryHiddenRequest) String ¶ added in v0.12.0
func (t *ChannelsTogglePreHistoryHiddenRequest) String() string
String implements fmt.Stringer.
type ChannelsToggleSignaturesRequest ¶
type ChannelsToggleSignaturesRequest struct {
// Channel
Channel InputChannelClass
// Value
Enabled bool
}
ChannelsToggleSignaturesRequest represents TL type `channels.toggleSignatures#1f69b606`. Enable/disable message signatures in channels
See https://core.telegram.org/method/channels.toggleSignatures for reference.
func (*ChannelsToggleSignaturesRequest) Decode ¶
func (t *ChannelsToggleSignaturesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsToggleSignaturesRequest) Encode ¶
func (t *ChannelsToggleSignaturesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsToggleSignaturesRequest) String ¶ added in v0.12.0
func (t *ChannelsToggleSignaturesRequest) String() string
String implements fmt.Stringer.
type ChannelsToggleSlowModeRequest ¶
type ChannelsToggleSlowModeRequest struct {
// The supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
// Users will only be able to send one message every seconds seconds, 0 to disable the limitation
Seconds int
}
ChannelsToggleSlowModeRequest represents TL type `channels.toggleSlowMode#edd49ef0`. Toggle supergroup slow mode: if enabled, users will only be able to send one message every seconds seconds
See https://core.telegram.org/method/channels.toggleSlowMode for reference.
func (*ChannelsToggleSlowModeRequest) Decode ¶
func (t *ChannelsToggleSlowModeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsToggleSlowModeRequest) Encode ¶
func (t *ChannelsToggleSlowModeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsToggleSlowModeRequest) String ¶ added in v0.12.0
func (t *ChannelsToggleSlowModeRequest) String() string
String implements fmt.Stringer.
type ChannelsUpdateUsernameRequest ¶
type ChannelsUpdateUsernameRequest struct {
// Channel
Channel InputChannelClass
// New username
Username string
}
ChannelsUpdateUsernameRequest represents TL type `channels.updateUsername#3514b3de`. Change the username of a supergroup/channel
See https://core.telegram.org/method/channels.updateUsername for reference.
func (*ChannelsUpdateUsernameRequest) Decode ¶
func (u *ChannelsUpdateUsernameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChannelsUpdateUsernameRequest) Encode ¶
func (u *ChannelsUpdateUsernameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChannelsUpdateUsernameRequest) String ¶ added in v0.12.0
func (u *ChannelsUpdateUsernameRequest) String() string
String implements fmt.Stringer.
type Chat ¶
type Chat struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the current user is the creator of the group
Creator bool
// Whether the current user was kicked from the group
Kicked bool
// Whether the current user has left the group
Left bool
// Whether the group was migrated¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Deactivated bool
// CallActive field of Chat.
CallActive bool
// CallNotEmpty field of Chat.
CallNotEmpty bool
// ID of the group
ID int
// Title
Title string
// Chat photo
Photo ChatPhotoClass
// Participant count
ParticipantsCount int
// Date of creation of the group
Date int
// Used in basic groups to reorder updates and make sure that all of them were received.
Version int
// Means this chat was upgraded¹ to a supergroup
//
// Links:
// 1) https://core.telegram.org/api/channel
//
// Use SetMigratedTo and GetMigratedTo helpers.
MigratedTo InputChannelClass
// Admin rights¹ of the user in the group
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetAdminRights and GetAdminRights helpers.
AdminRights ChatAdminRights
// Default banned rights¹ of all users in the group
//
// Links:
// 1) https://core.telegram.org/api/rights
//
// Use SetDefaultBannedRights and GetDefaultBannedRights helpers.
DefaultBannedRights ChatBannedRights
}
Chat represents TL type `chat#3bda1bde`. Info about a group
See https://core.telegram.org/constructor/chat for reference.
func (*Chat) GetAdminRights ¶
func (c *Chat) GetAdminRights() (value ChatAdminRights, ok bool)
GetAdminRights returns value of AdminRights conditional field and boolean which is true if field was set.
func (*Chat) GetDefaultBannedRights ¶
func (c *Chat) GetDefaultBannedRights() (value ChatBannedRights, ok bool)
GetDefaultBannedRights returns value of DefaultBannedRights conditional field and boolean which is true if field was set.
func (*Chat) GetMigratedTo ¶
func (c *Chat) GetMigratedTo() (value InputChannelClass, ok bool)
GetMigratedTo returns value of MigratedTo conditional field and boolean which is true if field was set.
func (*Chat) SetAdminRights ¶
func (c *Chat) SetAdminRights(value ChatAdminRights)
SetAdminRights sets value of AdminRights conditional field.
func (*Chat) SetCallActive ¶ added in v0.13.0
SetCallActive sets value of CallActive conditional field.
func (*Chat) SetCallNotEmpty ¶ added in v0.13.0
SetCallNotEmpty sets value of CallNotEmpty conditional field.
func (*Chat) SetCreator ¶
SetCreator sets value of Creator conditional field.
func (*Chat) SetDeactivated ¶
SetDeactivated sets value of Deactivated conditional field.
func (*Chat) SetDefaultBannedRights ¶
func (c *Chat) SetDefaultBannedRights(value ChatBannedRights)
SetDefaultBannedRights sets value of DefaultBannedRights conditional field.
func (*Chat) SetMigratedTo ¶
func (c *Chat) SetMigratedTo(value InputChannelClass)
SetMigratedTo sets value of MigratedTo conditional field.
type ChatAdminRights ¶
type ChatAdminRights struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, allows the admin to modify the description of the channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ChangeInfo bool
// If set, allows the admin to post messages in the channel¹
//
// Links:
// 1) https://core.telegram.org/api/channel
PostMessages bool
// If set, allows the admin to also edit messages from other admins in the channel¹
//
// Links:
// 1) https://core.telegram.org/api/channel
EditMessages bool
// If set, allows the admin to also delete messages from other admins in the channel¹
//
// Links:
// 1) https://core.telegram.org/api/channel
DeleteMessages bool
// If set, allows the admin to ban users from the channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
BanUsers bool
// If set, allows the admin to invite users in the channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
InviteUsers bool
// If set, allows the admin to pin messages in the channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
PinMessages bool
// If set, allows the admin to add other admins with the same (or more limited) permissions in the channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
AddAdmins bool
// Whether this admin is anonymous
Anonymous bool
// ManageCall field of ChatAdminRights.
ManageCall bool
}
ChatAdminRights represents TL type `chatAdminRights#5fb224d5`. Represents the rights of an admin in a channel/supergroup¹.
Links:
See https://core.telegram.org/constructor/chatAdminRights for reference.
func (*ChatAdminRights) Decode ¶
func (c *ChatAdminRights) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatAdminRights) Encode ¶
func (c *ChatAdminRights) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatAdminRights) SetAddAdmins ¶
func (c *ChatAdminRights) SetAddAdmins(value bool)
SetAddAdmins sets value of AddAdmins conditional field.
func (*ChatAdminRights) SetAnonymous ¶
func (c *ChatAdminRights) SetAnonymous(value bool)
SetAnonymous sets value of Anonymous conditional field.
func (*ChatAdminRights) SetBanUsers ¶
func (c *ChatAdminRights) SetBanUsers(value bool)
SetBanUsers sets value of BanUsers conditional field.
func (*ChatAdminRights) SetChangeInfo ¶
func (c *ChatAdminRights) SetChangeInfo(value bool)
SetChangeInfo sets value of ChangeInfo conditional field.
func (*ChatAdminRights) SetDeleteMessages ¶
func (c *ChatAdminRights) SetDeleteMessages(value bool)
SetDeleteMessages sets value of DeleteMessages conditional field.
func (*ChatAdminRights) SetEditMessages ¶
func (c *ChatAdminRights) SetEditMessages(value bool)
SetEditMessages sets value of EditMessages conditional field.
func (*ChatAdminRights) SetInviteUsers ¶
func (c *ChatAdminRights) SetInviteUsers(value bool)
SetInviteUsers sets value of InviteUsers conditional field.
func (*ChatAdminRights) SetManageCall ¶
func (c *ChatAdminRights) SetManageCall(value bool)
SetManageCall sets value of ManageCall conditional field.
func (*ChatAdminRights) SetPinMessages ¶
func (c *ChatAdminRights) SetPinMessages(value bool)
SetPinMessages sets value of PinMessages conditional field.
func (*ChatAdminRights) SetPostMessages ¶
func (c *ChatAdminRights) SetPostMessages(value bool)
SetPostMessages sets value of PostMessages conditional field.
func (*ChatAdminRights) String ¶ added in v0.12.0
func (c *ChatAdminRights) String() string
String implements fmt.Stringer.
type ChatBannedRights ¶
type ChatBannedRights struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, does not allow a user to view messages in a supergroup/channel/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ViewMessages bool
// If set, does not allow a user to send messages in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendMessages bool
// If set, does not allow a user to send any media in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendMedia bool
// If set, does not allow a user to send stickers in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendStickers bool
// If set, does not allow a user to send gifs in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendGifs bool
// If set, does not allow a user to send games in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendGames bool
// If set, does not allow a user to use inline bots in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendInline bool
// If set, does not allow a user to embed links in the messages of a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
EmbedLinks bool
// If set, does not allow a user to send stickers in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
SendPolls bool
// If set, does not allow any user to change the description of a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ChangeInfo bool
// If set, does not allow any user to invite users in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
InviteUsers bool
// If set, does not allow any user to pin messages in a supergroup/chat¹
//
// Links:
// 1) https://core.telegram.org/api/channel
PinMessages bool
// Validity of said permissions (it is considered forever any value less then 30 seconds or more then 366 days).
UntilDate int
}
ChatBannedRights represents TL type `chatBannedRights#9f120418`. Represents the rights of a normal user in a supergroup/channel/chat¹. In this case, the flags are inverted: if set, a flag does not allow a user to do X.
Links:
See https://core.telegram.org/constructor/chatBannedRights for reference.
func (*ChatBannedRights) Decode ¶
func (c *ChatBannedRights) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatBannedRights) Encode ¶
func (c *ChatBannedRights) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatBannedRights) SetChangeInfo ¶
func (c *ChatBannedRights) SetChangeInfo(value bool)
SetChangeInfo sets value of ChangeInfo conditional field.
func (*ChatBannedRights) SetEmbedLinks ¶
func (c *ChatBannedRights) SetEmbedLinks(value bool)
SetEmbedLinks sets value of EmbedLinks conditional field.
func (*ChatBannedRights) SetInviteUsers ¶
func (c *ChatBannedRights) SetInviteUsers(value bool)
SetInviteUsers sets value of InviteUsers conditional field.
func (*ChatBannedRights) SetPinMessages ¶
func (c *ChatBannedRights) SetPinMessages(value bool)
SetPinMessages sets value of PinMessages conditional field.
func (*ChatBannedRights) SetSendGames ¶
func (c *ChatBannedRights) SetSendGames(value bool)
SetSendGames sets value of SendGames conditional field.
func (*ChatBannedRights) SetSendGifs ¶
func (c *ChatBannedRights) SetSendGifs(value bool)
SetSendGifs sets value of SendGifs conditional field.
func (*ChatBannedRights) SetSendInline ¶
func (c *ChatBannedRights) SetSendInline(value bool)
SetSendInline sets value of SendInline conditional field.
func (*ChatBannedRights) SetSendMedia ¶
func (c *ChatBannedRights) SetSendMedia(value bool)
SetSendMedia sets value of SendMedia conditional field.
func (*ChatBannedRights) SetSendMessages ¶
func (c *ChatBannedRights) SetSendMessages(value bool)
SetSendMessages sets value of SendMessages conditional field.
func (*ChatBannedRights) SetSendPolls ¶
func (c *ChatBannedRights) SetSendPolls(value bool)
SetSendPolls sets value of SendPolls conditional field.
func (*ChatBannedRights) SetSendStickers ¶
func (c *ChatBannedRights) SetSendStickers(value bool)
SetSendStickers sets value of SendStickers conditional field.
func (*ChatBannedRights) SetViewMessages ¶
func (c *ChatBannedRights) SetViewMessages(value bool)
SetViewMessages sets value of ViewMessages conditional field.
func (*ChatBannedRights) String ¶ added in v0.12.0
func (c *ChatBannedRights) String() string
String implements fmt.Stringer.
type ChatBox ¶
type ChatBox struct {
Chat ChatClass
}
Chat boxes the ChatClass providing a helper.
type ChatClass ¶
type ChatClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatClass represents Chat generic type.
See https://core.telegram.org/type/Chat for reference.
Example:
g, err := DecodeChat(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatEmpty: // chatEmpty#9ba2d800
case *Chat: // chat#3bda1bde
case *ChatForbidden: // chatForbidden#7328bdb
case *Channel: // channel#d31a961e
case *ChannelForbidden: // channelForbidden#289da732
default: panic(v)
}
type ChatDefaultBannedRightsHandler ¶ added in v0.9.0
type ChatDefaultBannedRightsHandler func(ctx UpdateContext, update *UpdateChatDefaultBannedRights) error
ChatDefaultBannedRightsHandler is a ChatDefaultBannedRights event handler.
type ChatEmpty ¶
type ChatEmpty struct {
// Group identifier
ID int
}
ChatEmpty represents TL type `chatEmpty#9ba2d800`. Empty constructor, group doesn't exist
See https://core.telegram.org/constructor/chatEmpty for reference.
type ChatForbidden ¶
ChatForbidden represents TL type `chatForbidden#7328bdb`. A group to which the user has no access. E.g., because the user was kicked from the group.
See https://core.telegram.org/constructor/chatForbidden for reference.
func (*ChatForbidden) Decode ¶
func (c *ChatForbidden) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatForbidden) Encode ¶
func (c *ChatForbidden) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatForbidden) String ¶ added in v0.12.0
func (c *ChatForbidden) String() string
String implements fmt.Stringer.
type ChatFull ¶
type ChatFull struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Can we change the username of this chat
CanSetUsername bool
// Whether scheduled messages¹ are available
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
HasScheduled bool
// ID of the chat
ID int
// About string for this chat
About string
// Participant list
Participants ChatParticipantsClass
// Chat photo
//
// Use SetChatPhoto and GetChatPhoto helpers.
ChatPhoto PhotoClass
// Notification settings
NotifySettings PeerNotifySettings
// Chat invite
ExportedInvite ExportedChatInviteClass
// Info about bots that are in this chat
//
// Use SetBotInfo and GetBotInfo helpers.
BotInfo []BotInfo
// Message ID of the last pinned message¹
//
// Links:
// 1) https://core.telegram.org/api/pin
//
// Use SetPinnedMsgID and GetPinnedMsgID helpers.
PinnedMsgID int
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Call field of ChatFull.
//
// Use SetCall and GetCall helpers.
Call InputGroupCall
}
ChatFull represents TL type `chatFull#dc8c181`. Detailed chat info
See https://core.telegram.org/constructor/chatFull for reference.
func (*ChatFull) GetBotInfo ¶
GetBotInfo returns value of BotInfo conditional field and boolean which is true if field was set.
func (*ChatFull) GetCall ¶ added in v0.13.0
func (c *ChatFull) GetCall() (value InputGroupCall, ok bool)
GetCall returns value of Call conditional field and boolean which is true if field was set.
func (*ChatFull) GetChatPhoto ¶
func (c *ChatFull) GetChatPhoto() (value PhotoClass, ok bool)
GetChatPhoto returns value of ChatPhoto conditional field and boolean which is true if field was set.
func (*ChatFull) GetFolderID ¶
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*ChatFull) GetPinnedMsgID ¶
GetPinnedMsgID returns value of PinnedMsgID conditional field and boolean which is true if field was set.
func (*ChatFull) SetBotInfo ¶
SetBotInfo sets value of BotInfo conditional field.
func (*ChatFull) SetCall ¶ added in v0.13.0
func (c *ChatFull) SetCall(value InputGroupCall)
SetCall sets value of Call conditional field.
func (*ChatFull) SetCanSetUsername ¶
SetCanSetUsername sets value of CanSetUsername conditional field.
func (*ChatFull) SetChatPhoto ¶
func (c *ChatFull) SetChatPhoto(value PhotoClass)
SetChatPhoto sets value of ChatPhoto conditional field.
func (*ChatFull) SetFolderID ¶
SetFolderID sets value of FolderID conditional field.
func (*ChatFull) SetHasScheduled ¶
SetHasScheduled sets value of HasScheduled conditional field.
func (*ChatFull) SetPinnedMsgID ¶
SetPinnedMsgID sets value of PinnedMsgID conditional field.
type ChatFullBox ¶
type ChatFullBox struct {
ChatFull ChatFullClass
}
ChatFull boxes the ChatFullClass providing a helper.
type ChatFullClass ¶
type ChatFullClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatFullClass represents ChatFull generic type.
See https://core.telegram.org/type/ChatFull for reference.
Example:
g, err := DecodeChatFull(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatFull: // chatFull#dc8c181
case *ChannelFull: // channelFull#ef3a6acd
default: panic(v)
}
func DecodeChatFull ¶
func DecodeChatFull(buf *bin.Buffer) (ChatFullClass, error)
DecodeChatFull implements binary de-serialization for ChatFullClass.
type ChatHandler ¶ added in v0.13.0
type ChatHandler func(ctx UpdateContext, update *UpdateChat) error
ChatHandler is a Chat event handler.
type ChatInvite ¶
type ChatInvite struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a channel/supergroup¹ or a normal group²
//
// Links:
// 1) https://core.telegram.org/api/channel
// 2) https://core.telegram.org/api/channel
Channel bool
// Whether this is a channel¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Broadcast bool
// Whether this is a public channel/supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Public bool
// Whether this is a supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Megagroup bool
// Chat/supergroup/channel title
Title string
// Chat/supergroup/channel photo
Photo PhotoClass
// Participant count
ParticipantsCount int
// A few of the participants that are in the group
//
// Use SetParticipants and GetParticipants helpers.
Participants []UserClass
}
ChatInvite represents TL type `chatInvite#dfc2f58e`. Chat invite info
See https://core.telegram.org/constructor/chatInvite for reference.
func (*ChatInvite) Decode ¶
func (c *ChatInvite) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatInvite) Encode ¶
func (c *ChatInvite) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatInvite) GetParticipants ¶
func (c *ChatInvite) GetParticipants() (value []UserClass, ok bool)
GetParticipants returns value of Participants conditional field and boolean which is true if field was set.
func (*ChatInvite) SetBroadcast ¶
func (c *ChatInvite) SetBroadcast(value bool)
SetBroadcast sets value of Broadcast conditional field.
func (*ChatInvite) SetChannel ¶
func (c *ChatInvite) SetChannel(value bool)
SetChannel sets value of Channel conditional field.
func (*ChatInvite) SetMegagroup ¶
func (c *ChatInvite) SetMegagroup(value bool)
SetMegagroup sets value of Megagroup conditional field.
func (*ChatInvite) SetParticipants ¶
func (c *ChatInvite) SetParticipants(value []UserClass)
SetParticipants sets value of Participants conditional field.
func (*ChatInvite) SetPublic ¶
func (c *ChatInvite) SetPublic(value bool)
SetPublic sets value of Public conditional field.
func (*ChatInvite) String ¶ added in v0.12.0
func (c *ChatInvite) String() string
String implements fmt.Stringer.
type ChatInviteAlready ¶
type ChatInviteAlready struct {
// The chat connected to the invite
Chat ChatClass
}
ChatInviteAlready represents TL type `chatInviteAlready#5a686d7c`. The user has already joined this chat
See https://core.telegram.org/constructor/chatInviteAlready for reference.
func (*ChatInviteAlready) Decode ¶
func (c *ChatInviteAlready) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatInviteAlready) Encode ¶
func (c *ChatInviteAlready) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatInviteAlready) String ¶ added in v0.12.0
func (c *ChatInviteAlready) String() string
String implements fmt.Stringer.
type ChatInviteBox ¶
type ChatInviteBox struct {
ChatInvite ChatInviteClass
}
ChatInvite boxes the ChatInviteClass providing a helper.
type ChatInviteClass ¶
type ChatInviteClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatInviteClass represents ChatInvite generic type.
See https://core.telegram.org/type/ChatInvite for reference.
Example:
g, err := DecodeChatInvite(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatInviteAlready: // chatInviteAlready#5a686d7c
case *ChatInvite: // chatInvite#dfc2f58e
case *ChatInvitePeek: // chatInvitePeek#61695cb0
default: panic(v)
}
func DecodeChatInvite ¶
func DecodeChatInvite(buf *bin.Buffer) (ChatInviteClass, error)
DecodeChatInvite implements binary de-serialization for ChatInviteClass.
type ChatInviteEmpty ¶
type ChatInviteEmpty struct {
}
ChatInviteEmpty represents TL type `chatInviteEmpty#69df3769`. No info is associated to the chat invite
See https://core.telegram.org/constructor/chatInviteEmpty for reference.
func (*ChatInviteEmpty) Decode ¶
func (c *ChatInviteEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatInviteEmpty) Encode ¶
func (c *ChatInviteEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatInviteEmpty) String ¶ added in v0.12.0
func (c *ChatInviteEmpty) String() string
String implements fmt.Stringer.
type ChatInviteExported ¶
type ChatInviteExported struct {
// Chat invitation link
Link string
}
ChatInviteExported represents TL type `chatInviteExported#fc2e05bc`. Exported chat invite
See https://core.telegram.org/constructor/chatInviteExported for reference.
func (*ChatInviteExported) Decode ¶
func (c *ChatInviteExported) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatInviteExported) Encode ¶
func (c *ChatInviteExported) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatInviteExported) String ¶ added in v0.12.0
func (c *ChatInviteExported) String() string
String implements fmt.Stringer.
type ChatInvitePeek ¶
type ChatInvitePeek struct {
// Chat information
Chat ChatClass
// Read-only anonymous access to this group will be revoked at this date
Expires int
}
ChatInvitePeek represents TL type `chatInvitePeek#61695cb0`. A chat invitation that also allows peeking into the group to read messages without joining it.
See https://core.telegram.org/constructor/chatInvitePeek for reference.
func (*ChatInvitePeek) Decode ¶
func (c *ChatInvitePeek) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatInvitePeek) Encode ¶
func (c *ChatInvitePeek) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatInvitePeek) String ¶ added in v0.12.0
func (c *ChatInvitePeek) String() string
String implements fmt.Stringer.
type ChatOnlines ¶
type ChatOnlines struct {
// Number of online users
Onlines int
}
ChatOnlines represents TL type `chatOnlines#f041e250`. Number of online users in a chat
See https://core.telegram.org/constructor/chatOnlines for reference.
func (*ChatOnlines) Decode ¶
func (c *ChatOnlines) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatOnlines) Encode ¶
func (c *ChatOnlines) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatOnlines) String ¶ added in v0.12.0
func (c *ChatOnlines) String() string
String implements fmt.Stringer.
type ChatParticipant ¶
type ChatParticipant struct {
// Member user ID
UserID int
// ID of the user that added the member to the group
InviterID int
// Date added to the group
Date int
}
ChatParticipant represents TL type `chatParticipant#c8d7493e`. Group member.
See https://core.telegram.org/constructor/chatParticipant for reference.
func (*ChatParticipant) Decode ¶
func (c *ChatParticipant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatParticipant) Encode ¶
func (c *ChatParticipant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatParticipant) String ¶ added in v0.12.0
func (c *ChatParticipant) String() string
String implements fmt.Stringer.
type ChatParticipantAddHandler ¶ added in v0.9.0
type ChatParticipantAddHandler func(ctx UpdateContext, update *UpdateChatParticipantAdd) error
ChatParticipantAddHandler is a ChatParticipantAdd event handler.
type ChatParticipantAdmin ¶
type ChatParticipantAdmin struct {
// ID of a group member that is admin
UserID int
// ID of the user that added the member to the group
InviterID int
// Date when the user was added
Date int
}
ChatParticipantAdmin represents TL type `chatParticipantAdmin#e2d6e436`. Chat admin
See https://core.telegram.org/constructor/chatParticipantAdmin for reference.
func (*ChatParticipantAdmin) Decode ¶
func (c *ChatParticipantAdmin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatParticipantAdmin) Encode ¶
func (c *ChatParticipantAdmin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatParticipantAdmin) String ¶ added in v0.12.0
func (c *ChatParticipantAdmin) String() string
String implements fmt.Stringer.
type ChatParticipantAdminHandler ¶ added in v0.9.0
type ChatParticipantAdminHandler func(ctx UpdateContext, update *UpdateChatParticipantAdmin) error
ChatParticipantAdminHandler is a ChatParticipantAdmin event handler.
type ChatParticipantBox ¶
type ChatParticipantBox struct {
ChatParticipant ChatParticipantClass
}
ChatParticipant boxes the ChatParticipantClass providing a helper.
type ChatParticipantClass ¶
type ChatParticipantClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatParticipantClass represents ChatParticipant generic type.
See https://core.telegram.org/type/ChatParticipant for reference.
Example:
g, err := DecodeChatParticipant(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatParticipant: // chatParticipant#c8d7493e
case *ChatParticipantCreator: // chatParticipantCreator#da13538a
case *ChatParticipantAdmin: // chatParticipantAdmin#e2d6e436
default: panic(v)
}
func DecodeChatParticipant ¶
func DecodeChatParticipant(buf *bin.Buffer) (ChatParticipantClass, error)
DecodeChatParticipant implements binary de-serialization for ChatParticipantClass.
type ChatParticipantCreator ¶
type ChatParticipantCreator struct {
// ID of the user that created the group
UserID int
}
ChatParticipantCreator represents TL type `chatParticipantCreator#da13538a`. Represents the creator of the group
See https://core.telegram.org/constructor/chatParticipantCreator for reference.
func (*ChatParticipantCreator) Decode ¶
func (c *ChatParticipantCreator) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatParticipantCreator) Encode ¶
func (c *ChatParticipantCreator) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatParticipantCreator) String ¶ added in v0.12.0
func (c *ChatParticipantCreator) String() string
String implements fmt.Stringer.
type ChatParticipantDeleteHandler ¶ added in v0.9.0
type ChatParticipantDeleteHandler func(ctx UpdateContext, update *UpdateChatParticipantDelete) error
ChatParticipantDeleteHandler is a ChatParticipantDelete event handler.
type ChatParticipants ¶
type ChatParticipants struct {
// Group identifier
ChatID int
// List of group members
Participants []ChatParticipantClass
// Group version number
Version int
}
ChatParticipants represents TL type `chatParticipants#3f460fed`. Group members.
See https://core.telegram.org/constructor/chatParticipants for reference.
func (*ChatParticipants) Decode ¶
func (c *ChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatParticipants) Encode ¶
func (c *ChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatParticipants) String ¶ added in v0.12.0
func (c *ChatParticipants) String() string
String implements fmt.Stringer.
type ChatParticipantsBox ¶
type ChatParticipantsBox struct {
ChatParticipants ChatParticipantsClass
}
ChatParticipants boxes the ChatParticipantsClass providing a helper.
type ChatParticipantsClass ¶
type ChatParticipantsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatParticipantsClass represents ChatParticipants generic type.
See https://core.telegram.org/type/ChatParticipants for reference.
Example:
g, err := DecodeChatParticipants(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatParticipantsForbidden: // chatParticipantsForbidden#fc900c2b
case *ChatParticipants: // chatParticipants#3f460fed
default: panic(v)
}
func DecodeChatParticipants ¶
func DecodeChatParticipants(buf *bin.Buffer) (ChatParticipantsClass, error)
DecodeChatParticipants implements binary de-serialization for ChatParticipantsClass.
type ChatParticipantsForbidden ¶
type ChatParticipantsForbidden struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Group ID
ChatID int
// Info about the group membership of the current user
//
// Use SetSelfParticipant and GetSelfParticipant helpers.
SelfParticipant ChatParticipantClass
}
ChatParticipantsForbidden represents TL type `chatParticipantsForbidden#fc900c2b`. Info on members is unavailable
See https://core.telegram.org/constructor/chatParticipantsForbidden for reference.
func (*ChatParticipantsForbidden) Decode ¶
func (c *ChatParticipantsForbidden) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatParticipantsForbidden) Encode ¶
func (c *ChatParticipantsForbidden) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatParticipantsForbidden) GetSelfParticipant ¶
func (c *ChatParticipantsForbidden) GetSelfParticipant() (value ChatParticipantClass, ok bool)
GetSelfParticipant returns value of SelfParticipant conditional field and boolean which is true if field was set.
func (*ChatParticipantsForbidden) SetSelfParticipant ¶
func (c *ChatParticipantsForbidden) SetSelfParticipant(value ChatParticipantClass)
SetSelfParticipant sets value of SelfParticipant conditional field.
func (*ChatParticipantsForbidden) String ¶ added in v0.12.0
func (c *ChatParticipantsForbidden) String() string
String implements fmt.Stringer.
type ChatParticipantsHandler ¶ added in v0.9.0
type ChatParticipantsHandler func(ctx UpdateContext, update *UpdateChatParticipants) error
ChatParticipantsHandler is a ChatParticipants event handler.
type ChatPhoto ¶
type ChatPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user has an animated profile picture
HasVideo bool
// Location of the file corresponding to the small thumbnail for group profile photo
PhotoSmall FileLocationToBeDeprecated
// Location of the file corresponding to the small thumbnail for group profile photo
PhotoBig FileLocationToBeDeprecated
// DC where this photo is stored
DCID int
}
ChatPhoto represents TL type `chatPhoto#d20b9f3c`. Group profile photo.
See https://core.telegram.org/constructor/chatPhoto for reference.
func (*ChatPhoto) SetHasVideo ¶
SetHasVideo sets value of HasVideo conditional field.
type ChatPhotoBox ¶
type ChatPhotoBox struct {
ChatPhoto ChatPhotoClass
}
ChatPhoto boxes the ChatPhotoClass providing a helper.
type ChatPhotoClass ¶
type ChatPhotoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ChatPhotoClass represents ChatPhoto generic type.
See https://core.telegram.org/type/ChatPhoto for reference.
Example:
g, err := DecodeChatPhoto(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatPhotoEmpty: // chatPhotoEmpty#37c1011c
case *ChatPhoto: // chatPhoto#d20b9f3c
default: panic(v)
}
func DecodeChatPhoto ¶
func DecodeChatPhoto(buf *bin.Buffer) (ChatPhotoClass, error)
DecodeChatPhoto implements binary de-serialization for ChatPhotoClass.
type ChatPhotoEmpty ¶
type ChatPhotoEmpty struct {
}
ChatPhotoEmpty represents TL type `chatPhotoEmpty#37c1011c`. Group photo is not set.
See https://core.telegram.org/constructor/chatPhotoEmpty for reference.
func (*ChatPhotoEmpty) Decode ¶
func (c *ChatPhotoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ChatPhotoEmpty) Encode ¶
func (c *ChatPhotoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ChatPhotoEmpty) String ¶ added in v0.12.0
func (c *ChatPhotoEmpty) String() string
String implements fmt.Stringer.
type ChatUserTypingHandler ¶ added in v0.9.0
type ChatUserTypingHandler func(ctx UpdateContext, update *UpdateChatUserTyping) error
ChatUserTypingHandler is a ChatUserTyping event handler.
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client implement methods for calling functions from TL schema via Invoker.
func (*Client) AccountAcceptAuthorization ¶
func (c *Client) AccountAcceptAuthorization(ctx context.Context, request *AccountAcceptAuthorizationRequest) (bool, error)
AccountAcceptAuthorization invokes method account.acceptAuthorization#e7027c94 returning error if any. Sends a Telegram Passport authorization form, effectively sharing data with the service
See https://core.telegram.org/method/account.acceptAuthorization for reference.
func (*Client) AccountCancelPasswordEmail ¶
AccountCancelPasswordEmail invokes method account.cancelPasswordEmail#c1cbd5b6 returning error if any. Cancel the code that was sent to verify an email to use as 2FA recovery method¹.
Links:
See https://core.telegram.org/method/account.cancelPasswordEmail for reference.
func (*Client) AccountChangePhone ¶
func (c *Client) AccountChangePhone(ctx context.Context, request *AccountChangePhoneRequest) (UserClass, error)
AccountChangePhone invokes method account.changePhone#70c32edb returning error if any. Change the phone number of the current account
Possible errors:
400 PHONE_CODE_EMPTY: phone_code is missing 400 PHONE_NUMBER_INVALID: The phone number is invalid
See https://core.telegram.org/method/account.changePhone for reference.
func (*Client) AccountCheckUsername ¶
AccountCheckUsername invokes method account.checkUsername#2714d86c returning error if any. Validates a username and checks availability.
Possible errors:
400 USERNAME_INVALID: Unacceptable username
See https://core.telegram.org/method/account.checkUsername for reference.
func (*Client) AccountConfirmPasswordEmail ¶
AccountConfirmPasswordEmail invokes method account.confirmPasswordEmail#8fdf1920 returning error if any. Verify an email to use as 2FA recovery method¹.
Links:
Possible errors:
400 CODE_INVALID: Code invalid 400 EMAIL_HASH_EXPIRED: Email hash expired
See https://core.telegram.org/method/account.confirmPasswordEmail for reference.
func (*Client) AccountConfirmPhone ¶
func (c *Client) AccountConfirmPhone(ctx context.Context, request *AccountConfirmPhoneRequest) (bool, error)
AccountConfirmPhone invokes method account.confirmPhone#5f2178c3 returning error if any. Confirm a phone number to cancel account deletion, for more info click here »¹
Links:
Possible errors:
400 CODE_HASH_INVALID: Code hash invalid 400 PHONE_CODE_EMPTY: phone_code is missing
See https://core.telegram.org/method/account.confirmPhone for reference.
func (*Client) AccountCreateTheme ¶
func (c *Client) AccountCreateTheme(ctx context.Context, request *AccountCreateThemeRequest) (*Theme, error)
AccountCreateTheme invokes method account.createTheme#8432c21f returning error if any. Create a theme
See https://core.telegram.org/method/account.createTheme for reference.
func (*Client) AccountDeleteAccount ¶
AccountDeleteAccount invokes method account.deleteAccount#418d4e0b returning error if any. Delete the user's account from the telegram servers. Can be used, for example, to delete the account of a user that provided the login code, but forgot the 2FA password and no recovery method is configured¹.
Links:
Possible errors:
420 2FA_CONFIRM_WAIT_X: Since this account is active and protected by a 2FA password, we will delete it in 1 week for security purposes. You can cancel this process at any time, you'll be able to reset your account in X seconds.
See https://core.telegram.org/method/account.deleteAccount for reference.
func (*Client) AccountDeleteSecureValue ¶
func (c *Client) AccountDeleteSecureValue(ctx context.Context, types []SecureValueTypeClass) (bool, error)
AccountDeleteSecureValue invokes method account.deleteSecureValue#b880bc4b returning error if any. Delete stored Telegram Passport¹ documents, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.deleteSecureValue for reference.
func (*Client) AccountFinishTakeoutSession ¶
func (c *Client) AccountFinishTakeoutSession(ctx context.Context, request *AccountFinishTakeoutSessionRequest) (bool, error)
AccountFinishTakeoutSession invokes method account.finishTakeoutSession#1d2652ee returning error if any. Finish account takeout session
Possible errors:
403 TAKEOUT_REQUIRED: A takeout session has to be initialized, first
See https://core.telegram.org/method/account.finishTakeoutSession for reference.
func (*Client) AccountGetAccountTTL ¶
func (c *Client) AccountGetAccountTTL(ctx context.Context) (*AccountDaysTTL, error)
AccountGetAccountTTL invokes method account.getAccountTTL#8fc711d returning error if any. Get days to live of account
See https://core.telegram.org/method/account.getAccountTTL for reference.
func (*Client) AccountGetAllSecureValues ¶ added in v0.8.0
func (c *Client) AccountGetAllSecureValues(ctx context.Context) ([]SecureValue, error)
AccountGetAllSecureValues invokes method account.getAllSecureValues#b288bc7d returning error if any. Get all saved Telegram Passport¹ documents, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.getAllSecureValues for reference.
func (*Client) AccountGetAuthorizationForm ¶
func (c *Client) AccountGetAuthorizationForm(ctx context.Context, request *AccountGetAuthorizationFormRequest) (*AccountAuthorizationForm, error)
AccountGetAuthorizationForm invokes method account.getAuthorizationForm#b86ba8e1 returning error if any. Returns a Telegram Passport authorization form for sharing data with a service
See https://core.telegram.org/method/account.getAuthorizationForm for reference.
func (*Client) AccountGetAuthorizations ¶
func (c *Client) AccountGetAuthorizations(ctx context.Context) (*AccountAuthorizations, error)
AccountGetAuthorizations invokes method account.getAuthorizations#e320c158 returning error if any. Get logged-in sessions
See https://core.telegram.org/method/account.getAuthorizations for reference.
func (*Client) AccountGetAutoDownloadSettings ¶
func (c *Client) AccountGetAutoDownloadSettings(ctx context.Context) (*AccountAutoDownloadSettings, error)
AccountGetAutoDownloadSettings invokes method account.getAutoDownloadSettings#56da0b3f returning error if any. Get media autodownload settings
See https://core.telegram.org/method/account.getAutoDownloadSettings for reference.
func (*Client) AccountGetContactSignUpNotification ¶
AccountGetContactSignUpNotification invokes method account.getContactSignUpNotification#9f07c728 returning error if any. Whether the user will receive notifications when contacts sign up
See https://core.telegram.org/method/account.getContactSignUpNotification for reference.
func (*Client) AccountGetContentSettings ¶
func (c *Client) AccountGetContentSettings(ctx context.Context) (*AccountContentSettings, error)
AccountGetContentSettings invokes method account.getContentSettings#8b9b4dae returning error if any. Get sensitive content settings
See https://core.telegram.org/method/account.getContentSettings for reference.
func (*Client) AccountGetGlobalPrivacySettings ¶
func (c *Client) AccountGetGlobalPrivacySettings(ctx context.Context) (*GlobalPrivacySettings, error)
AccountGetGlobalPrivacySettings invokes method account.getGlobalPrivacySettings#eb2b4cf6 returning error if any. Get global privacy settings
See https://core.telegram.org/method/account.getGlobalPrivacySettings for reference. Can be used by bots.
func (*Client) AccountGetMultiWallPapers ¶ added in v0.8.0
func (c *Client) AccountGetMultiWallPapers(ctx context.Context, wallpapers []InputWallPaperClass) ([]WallPaperClass, error)
AccountGetMultiWallPapers invokes method account.getMultiWallPapers#65ad71dc returning error if any. Get info about multiple wallpapers
See https://core.telegram.org/method/account.getMultiWallPapers for reference.
func (*Client) AccountGetNotifyExceptions ¶
func (c *Client) AccountGetNotifyExceptions(ctx context.Context, request *AccountGetNotifyExceptionsRequest) (UpdatesClass, error)
AccountGetNotifyExceptions invokes method account.getNotifyExceptions#53577479 returning error if any. Returns list of chats with non-default notification settings
See https://core.telegram.org/method/account.getNotifyExceptions for reference.
func (*Client) AccountGetNotifySettings ¶
func (c *Client) AccountGetNotifySettings(ctx context.Context, peer InputNotifyPeerClass) (*PeerNotifySettings, error)
AccountGetNotifySettings invokes method account.getNotifySettings#12b3ad31 returning error if any. Gets current notification settings for a given user/group, from all users/all groups.
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/account.getNotifySettings for reference.
func (*Client) AccountGetPassword ¶
func (c *Client) AccountGetPassword(ctx context.Context) (*AccountPassword, error)
AccountGetPassword invokes method account.getPassword#548a30f5 returning error if any. Obtain configuration for two-factor authorization with password
See https://core.telegram.org/method/account.getPassword for reference.
func (*Client) AccountGetPasswordSettings ¶
func (c *Client) AccountGetPasswordSettings(ctx context.Context, password InputCheckPasswordSRPClass) (*AccountPasswordSettings, error)
AccountGetPasswordSettings invokes method account.getPasswordSettings#9cd4eaf9 returning error if any. Get private info associated to the password info (recovery email, telegram passport¹ info & so on)
Links:
Possible errors:
400 PASSWORD_HASH_INVALID: The provided password hash is invalid
See https://core.telegram.org/method/account.getPasswordSettings for reference.
func (*Client) AccountGetPrivacy ¶
func (c *Client) AccountGetPrivacy(ctx context.Context, key InputPrivacyKeyClass) (*AccountPrivacyRules, error)
AccountGetPrivacy invokes method account.getPrivacy#dadbc950 returning error if any. Get privacy settings of current account
Possible errors:
400 PRIVACY_KEY_INVALID: The privacy key is invalid
See https://core.telegram.org/method/account.getPrivacy for reference.
func (*Client) AccountGetSecureValue ¶ added in v0.8.0
func (c *Client) AccountGetSecureValue(ctx context.Context, types []SecureValueTypeClass) ([]SecureValue, error)
AccountGetSecureValue invokes method account.getSecureValue#73665bc2 returning error if any. Get saved Telegram Passport¹ document, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.getSecureValue for reference.
func (*Client) AccountGetTheme ¶
func (c *Client) AccountGetTheme(ctx context.Context, request *AccountGetThemeRequest) (*Theme, error)
AccountGetTheme invokes method account.getTheme#8d9d742b returning error if any. Get theme information
Possible errors:
400 THEME_FORMAT_INVALID: Invalid theme format provided 400 THEME_INVALID: Invalid theme provided
See https://core.telegram.org/method/account.getTheme for reference.
func (*Client) AccountGetThemes ¶
func (c *Client) AccountGetThemes(ctx context.Context, request *AccountGetThemesRequest) (AccountThemesClass, error)
AccountGetThemes invokes method account.getThemes#285946f8 returning error if any. Get installed themes
See https://core.telegram.org/method/account.getThemes for reference.
func (*Client) AccountGetTmpPassword ¶
func (c *Client) AccountGetTmpPassword(ctx context.Context, request *AccountGetTmpPasswordRequest) (*AccountTmpPassword, error)
AccountGetTmpPassword invokes method account.getTmpPassword#449e0b51 returning error if any. Get temporary payment password
Possible errors:
400 PASSWORD_HASH_INVALID: The provided password hash is invalid 400 TMP_PASSWORD_DISABLED: The temporary password is disabled
See https://core.telegram.org/method/account.getTmpPassword for reference.
func (*Client) AccountGetWallPaper ¶
func (c *Client) AccountGetWallPaper(ctx context.Context, wallpaper InputWallPaperClass) (WallPaperClass, error)
AccountGetWallPaper invokes method account.getWallPaper#fc8ddbea returning error if any. Get info about a certain wallpaper
See https://core.telegram.org/method/account.getWallPaper for reference.
func (*Client) AccountGetWallPapers ¶
func (c *Client) AccountGetWallPapers(ctx context.Context, hash int) (AccountWallPapersClass, error)
AccountGetWallPapers invokes method account.getWallPapers#aabb1763 returning error if any. Returns a list of available wallpapers.
See https://core.telegram.org/method/account.getWallPapers for reference.
func (*Client) AccountGetWebAuthorizations ¶
func (c *Client) AccountGetWebAuthorizations(ctx context.Context) (*AccountWebAuthorizations, error)
AccountGetWebAuthorizations invokes method account.getWebAuthorizations#182e6d6f returning error if any. Get web login widget¹ authorizations
Links:
See https://core.telegram.org/method/account.getWebAuthorizations for reference.
func (*Client) AccountInitTakeoutSession ¶
func (c *Client) AccountInitTakeoutSession(ctx context.Context, request *AccountInitTakeoutSessionRequest) (*AccountTakeout, error)
AccountInitTakeoutSession invokes method account.initTakeoutSession#f05b4804 returning error if any. Intialize account takeout session
Possible errors:
420 TAKEOUT_INIT_DELAY_X: Wait X seconds before initing takeout
See https://core.telegram.org/method/account.initTakeoutSession for reference.
func (*Client) AccountInstallTheme ¶
func (c *Client) AccountInstallTheme(ctx context.Context, request *AccountInstallThemeRequest) (bool, error)
AccountInstallTheme invokes method account.installTheme#7ae43737 returning error if any. Install a theme
See https://core.telegram.org/method/account.installTheme for reference.
func (*Client) AccountInstallWallPaper ¶
func (c *Client) AccountInstallWallPaper(ctx context.Context, request *AccountInstallWallPaperRequest) (bool, error)
AccountInstallWallPaper invokes method account.installWallPaper#feed5769 returning error if any. Install wallpaper
See https://core.telegram.org/method/account.installWallPaper for reference.
func (*Client) AccountRegisterDevice ¶
func (c *Client) AccountRegisterDevice(ctx context.Context, request *AccountRegisterDeviceRequest) (bool, error)
AccountRegisterDevice invokes method account.registerDevice#68976c6f returning error if any. Register device to receive PUSH notifications¹
Links:
Possible errors:
400 TOKEN_INVALID: The provided token is invalid
See https://core.telegram.org/method/account.registerDevice for reference.
func (*Client) AccountReportPeer ¶
func (c *Client) AccountReportPeer(ctx context.Context, request *AccountReportPeerRequest) (bool, error)
AccountReportPeer invokes method account.reportPeer#ae189d5f returning error if any. Report a peer for violation of telegram's Terms of Service
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/account.reportPeer for reference.
func (*Client) AccountResendPasswordEmail ¶
AccountResendPasswordEmail invokes method account.resendPasswordEmail#7a7f2a15 returning error if any. Resend the code to verify an email to use as 2FA recovery method¹.
Links:
See https://core.telegram.org/method/account.resendPasswordEmail for reference.
func (*Client) AccountResetAuthorization ¶
AccountResetAuthorization invokes method account.resetAuthorization#df77f3bc returning error if any. Log out an active authorized session¹ by its hash
Links:
Possible errors:
406 FRESH_RESET_AUTHORISATION_FORBIDDEN: You can't logout other sessions if less than 24 hours have passed since you logged on the current session 400 HASH_INVALID: The provided hash is invalid
See https://core.telegram.org/method/account.resetAuthorization for reference.
func (*Client) AccountResetNotifySettings ¶
AccountResetNotifySettings invokes method account.resetNotifySettings#db7e1747 returning error if any. Resets all notification settings from users and groups.
See https://core.telegram.org/method/account.resetNotifySettings for reference.
func (*Client) AccountResetWallPapers ¶
AccountResetWallPapers invokes method account.resetWallPapers#bb3b9804 returning error if any. Delete installed wallpapers
See https://core.telegram.org/method/account.resetWallPapers for reference.
func (*Client) AccountResetWebAuthorization ¶
AccountResetWebAuthorization invokes method account.resetWebAuthorization#2d01b9ef returning error if any. Log out an active web telegram login¹ session
Links:
See https://core.telegram.org/method/account.resetWebAuthorization for reference.
func (*Client) AccountResetWebAuthorizations ¶
AccountResetWebAuthorizations invokes method account.resetWebAuthorizations#682d2594 returning error if any. Reset all active web telegram login¹ sessions
Links:
See https://core.telegram.org/method/account.resetWebAuthorizations for reference.
func (*Client) AccountSaveAutoDownloadSettings ¶
func (c *Client) AccountSaveAutoDownloadSettings(ctx context.Context, request *AccountSaveAutoDownloadSettingsRequest) (bool, error)
AccountSaveAutoDownloadSettings invokes method account.saveAutoDownloadSettings#76f36233 returning error if any. Change media autodownload settings
See https://core.telegram.org/method/account.saveAutoDownloadSettings for reference.
func (*Client) AccountSaveSecureValue ¶
func (c *Client) AccountSaveSecureValue(ctx context.Context, request *AccountSaveSecureValueRequest) (*SecureValue, error)
AccountSaveSecureValue invokes method account.saveSecureValue#899fe31d returning error if any. Securely save Telegram Passport¹ document, for more info see the passport docs »²
Links:
See https://core.telegram.org/method/account.saveSecureValue for reference.
func (*Client) AccountSaveTheme ¶
func (c *Client) AccountSaveTheme(ctx context.Context, request *AccountSaveThemeRequest) (bool, error)
AccountSaveTheme invokes method account.saveTheme#f257106c returning error if any. Save a theme
See https://core.telegram.org/method/account.saveTheme for reference.
func (*Client) AccountSaveWallPaper ¶
func (c *Client) AccountSaveWallPaper(ctx context.Context, request *AccountSaveWallPaperRequest) (bool, error)
AccountSaveWallPaper invokes method account.saveWallPaper#6c5a5b37 returning error if any. Install/uninstall wallpaper
See https://core.telegram.org/method/account.saveWallPaper for reference.
func (*Client) AccountSendChangePhoneCode ¶
func (c *Client) AccountSendChangePhoneCode(ctx context.Context, request *AccountSendChangePhoneCodeRequest) (*AuthSentCode, error)
AccountSendChangePhoneCode invokes method account.sendChangePhoneCode#82574ae5 returning error if any. Verify a new phone number to associate to the current account
Possible errors:
400 PHONE_NUMBER_INVALID: The phone number is invalid
See https://core.telegram.org/method/account.sendChangePhoneCode for reference.
func (*Client) AccountSendConfirmPhoneCode ¶
func (c *Client) AccountSendConfirmPhoneCode(ctx context.Context, request *AccountSendConfirmPhoneCodeRequest) (*AuthSentCode, error)
AccountSendConfirmPhoneCode invokes method account.sendConfirmPhoneCode#1b3faa88 returning error if any. Send confirmation code to cancel account deletion, for more info click here »¹
Links:
Possible errors:
400 HASH_INVALID: The provided hash is invalid
See https://core.telegram.org/method/account.sendConfirmPhoneCode for reference.
func (*Client) AccountSendVerifyEmailCode ¶
func (c *Client) AccountSendVerifyEmailCode(ctx context.Context, email string) (*AccountSentEmailCode, error)
AccountSendVerifyEmailCode invokes method account.sendVerifyEmailCode#7011509f returning error if any. Send the verification email code for telegram passport¹.
Links:
See https://core.telegram.org/method/account.sendVerifyEmailCode for reference.
func (*Client) AccountSendVerifyPhoneCode ¶
func (c *Client) AccountSendVerifyPhoneCode(ctx context.Context, request *AccountSendVerifyPhoneCodeRequest) (*AuthSentCode, error)
AccountSendVerifyPhoneCode invokes method account.sendVerifyPhoneCode#a5a356f9 returning error if any. Send the verification phone code for telegram passport¹.
Links:
See https://core.telegram.org/method/account.sendVerifyPhoneCode for reference.
func (*Client) AccountSetAccountTTL ¶
AccountSetAccountTTL invokes method account.setAccountTTL#2442485e returning error if any. Set account self-destruction period
Possible errors:
400 TTL_DAYS_INVALID: The provided TTL is invalid
See https://core.telegram.org/method/account.setAccountTTL for reference.
func (*Client) AccountSetContactSignUpNotification ¶
func (c *Client) AccountSetContactSignUpNotification(ctx context.Context, silent bool) (bool, error)
AccountSetContactSignUpNotification invokes method account.setContactSignUpNotification#cff43f61 returning error if any. Toggle contact sign up notifications
See https://core.telegram.org/method/account.setContactSignUpNotification for reference.
func (*Client) AccountSetContentSettings ¶
func (c *Client) AccountSetContentSettings(ctx context.Context, request *AccountSetContentSettingsRequest) (bool, error)
AccountSetContentSettings invokes method account.setContentSettings#b574b16b returning error if any. Set sensitive content settings (for viewing or hiding NSFW content)
See https://core.telegram.org/method/account.setContentSettings for reference.
func (*Client) AccountSetGlobalPrivacySettings ¶
func (c *Client) AccountSetGlobalPrivacySettings(ctx context.Context, settings GlobalPrivacySettings) (*GlobalPrivacySettings, error)
AccountSetGlobalPrivacySettings invokes method account.setGlobalPrivacySettings#1edaaac2 returning error if any. Set global privacy settings
See https://core.telegram.org/method/account.setGlobalPrivacySettings for reference. Can be used by bots.
func (*Client) AccountSetPrivacy ¶
func (c *Client) AccountSetPrivacy(ctx context.Context, request *AccountSetPrivacyRequest) (*AccountPrivacyRules, error)
AccountSetPrivacy invokes method account.setPrivacy#c9f81ce8 returning error if any. Change privacy settings of current account
Possible errors:
400 PRIVACY_KEY_INVALID: The privacy key is invalid 400 PRIVACY_VALUE_INVALID: The specified privacy rule combination is invalid
See https://core.telegram.org/method/account.setPrivacy for reference.
func (*Client) AccountUnregisterDevice ¶
func (c *Client) AccountUnregisterDevice(ctx context.Context, request *AccountUnregisterDeviceRequest) (bool, error)
AccountUnregisterDevice invokes method account.unregisterDevice#3076c4bf returning error if any. Deletes a device by its token, stops sending PUSH-notifications to it.
Possible errors:
400 TOKEN_INVALID: The provided token is invalid
See https://core.telegram.org/method/account.unregisterDevice for reference.
func (*Client) AccountUpdateDeviceLocked ¶
AccountUpdateDeviceLocked invokes method account.updateDeviceLocked#38df3532 returning error if any. When client-side passcode lock feature is enabled, will not show message texts in incoming PUSH notifications¹.
Links:
See https://core.telegram.org/method/account.updateDeviceLocked for reference.
func (*Client) AccountUpdateNotifySettings ¶
func (c *Client) AccountUpdateNotifySettings(ctx context.Context, request *AccountUpdateNotifySettingsRequest) (bool, error)
AccountUpdateNotifySettings invokes method account.updateNotifySettings#84be5b93 returning error if any. Edits notification settings from a given user/group, from all users/all groups.
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 SETTINGS_INVALID: Invalid settings were provided
See https://core.telegram.org/method/account.updateNotifySettings for reference.
func (*Client) AccountUpdatePasswordSettings ¶
func (c *Client) AccountUpdatePasswordSettings(ctx context.Context, request *AccountUpdatePasswordSettingsRequest) (bool, error)
AccountUpdatePasswordSettings invokes method account.updatePasswordSettings#a59b102f returning error if any. Set a new 2FA password
Possible errors:
400 EMAIL_UNCONFIRMED: Email unconfirmed 400 EMAIL_UNCONFIRMED_X: The provided email isn't confirmed, X is the length of the verification code that was just sent to the email: use account.verifyEmail to enter the received verification code and enable the recovery email. 400 NEW_SALT_INVALID: The new salt is invalid 400 NEW_SETTINGS_INVALID: The new password settings are invalid 400 PASSWORD_HASH_INVALID: The old password hash is invalid 400 SRP_ID_INVALID: Invalid SRP ID provided
See https://core.telegram.org/method/account.updatePasswordSettings for reference.
func (*Client) AccountUpdateProfile ¶
func (c *Client) AccountUpdateProfile(ctx context.Context, request *AccountUpdateProfileRequest) (UserClass, error)
AccountUpdateProfile invokes method account.updateProfile#78515775 returning error if any. Updates user profile.
Possible errors:
400 ABOUT_TOO_LONG: About string too long 400 FIRSTNAME_INVALID: The first name is invalid
See https://core.telegram.org/method/account.updateProfile for reference.
func (*Client) AccountUpdateStatus ¶
AccountUpdateStatus invokes method account.updateStatus#6628562c returning error if any. Updates online user status.
See https://core.telegram.org/method/account.updateStatus for reference.
func (*Client) AccountUpdateTheme ¶
func (c *Client) AccountUpdateTheme(ctx context.Context, request *AccountUpdateThemeRequest) (*Theme, error)
AccountUpdateTheme invokes method account.updateTheme#5cb367d5 returning error if any. Update theme
See https://core.telegram.org/method/account.updateTheme for reference.
func (*Client) AccountUpdateUsername ¶
AccountUpdateUsername invokes method account.updateUsername#3e0bdd7c returning error if any. Changes username for the current user.
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 USERNAME_INVALID: Unacceptable username 400 USERNAME_NOT_MODIFIED: Username is not different from the current username 400 USERNAME_OCCUPIED: Username is taken
See https://core.telegram.org/method/account.updateUsername for reference.
func (*Client) AccountUploadTheme ¶
func (c *Client) AccountUploadTheme(ctx context.Context, request *AccountUploadThemeRequest) (DocumentClass, error)
AccountUploadTheme invokes method account.uploadTheme#1c3db333 returning error if any. Upload theme
Possible errors:
400 THEME_FILE_INVALID: Invalid theme file provided
See https://core.telegram.org/method/account.uploadTheme for reference.
func (*Client) AccountUploadWallPaper ¶
func (c *Client) AccountUploadWallPaper(ctx context.Context, request *AccountUploadWallPaperRequest) (WallPaperClass, error)
AccountUploadWallPaper invokes method account.uploadWallPaper#dd853661 returning error if any. Create and upload a new wallpaper
See https://core.telegram.org/method/account.uploadWallPaper for reference.
func (*Client) AccountVerifyEmail ¶
func (c *Client) AccountVerifyEmail(ctx context.Context, request *AccountVerifyEmailRequest) (bool, error)
AccountVerifyEmail invokes method account.verifyEmail#ecba39db returning error if any. Verify an email address for telegram passport¹.
Links:
Possible errors:
400 EMAIL_VERIFY_EXPIRED: The verification email has expired
See https://core.telegram.org/method/account.verifyEmail for reference.
func (*Client) AccountVerifyPhone ¶
func (c *Client) AccountVerifyPhone(ctx context.Context, request *AccountVerifyPhoneRequest) (bool, error)
AccountVerifyPhone invokes method account.verifyPhone#4dd3a7f6 returning error if any. Verify a phone number for telegram passport¹.
Links:
Possible errors:
400 PHONE_CODE_EXPIRED: The phone code you provided has expired, this may happen if it was sent to any chat on telegram (if the code is sent through a telegram chat (not the official account) to avoid it append or prepend to the code some chars)
See https://core.telegram.org/method/account.verifyPhone for reference.
func (*Client) AuthAcceptLoginToken ¶
AuthAcceptLoginToken invokes method auth.acceptLoginToken#e894ad4d returning error if any. Accept QR code login token, logging in the app that generated it. Returns info about the new session. For more info, see login via QR code¹.
Links:
Possible errors:
400 AUTH_TOKEN_INVALIDX: The specified auth token is invalid
See https://core.telegram.org/method/auth.acceptLoginToken for reference.
func (*Client) AuthBindTempAuthKey ¶
func (c *Client) AuthBindTempAuthKey(ctx context.Context, request *AuthBindTempAuthKeyRequest) (bool, error)
AuthBindTempAuthKey invokes method auth.bindTempAuthKey#cdd42a05 returning error if any. Binds a temporary authorization key temp_auth_key_id to the permanent authorization key perm_auth_key_id. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one. For more information, see Perfect Forward Secrecy¹.
Links:
Possible errors:
400 ENCRYPTED_MESSAGE_INVALID: Encrypted message is incorrect 400 INPUT_REQUEST_TOO_LONG: The request is too big 400 TEMP_AUTH_KEY_ALREADY_BOUND: The passed temporary key is already bound to another perm_auth_key_id 400 TEMP_AUTH_KEY_EMPTY: The request was not performed with a temporary authorization key
See https://core.telegram.org/method/auth.bindTempAuthKey for reference. Can be used by bots.
func (*Client) AuthCancelCode ¶
AuthCancelCode invokes method auth.cancelCode#1f040578 returning error if any. Cancel the login verification code
Possible errors:
400 PHONE_CODE_EXPIRED: The phone code you provided has expired, this may happen if it was sent to any chat on telegram (if the code is sent through a telegram chat (not the official account) to avoid it append or prepend to the code some chars) 400 PHONE_NUMBER_INVALID: The phone number is invalid
See https://core.telegram.org/method/auth.cancelCode for reference.
func (*Client) AuthCheckPassword ¶
func (c *Client) AuthCheckPassword(ctx context.Context, password InputCheckPasswordSRPClass) (AuthAuthorizationClass, error)
AuthCheckPassword invokes method auth.checkPassword#d18b4d16 returning error if any. Try logging to an account protected by a 2FA password¹.
Links:
Possible errors:
400 PASSWORD_HASH_INVALID: The provided password isn't valid 400 SRP_ID_INVALID: Invalid SRP ID provided 400 SRP_PASSWORD_CHANGED: Password has changed
See https://core.telegram.org/method/auth.checkPassword for reference.
func (*Client) AuthDropTempAuthKeys ¶
AuthDropTempAuthKeys invokes method auth.dropTempAuthKeys#8e48a188 returning error if any. Delete all temporary authorization keys except for the ones specified
See https://core.telegram.org/method/auth.dropTempAuthKeys for reference. Can be used by bots.
func (*Client) AuthExportAuthorization ¶
func (c *Client) AuthExportAuthorization(ctx context.Context, dcid int) (*AuthExportedAuthorization, error)
AuthExportAuthorization invokes method auth.exportAuthorization#e5bfffcd returning error if any. Returns data for copying authorization to another data-centre.
Possible errors:
400 DC_ID_INVALID: The provided DC ID is invalid
See https://core.telegram.org/method/auth.exportAuthorization for reference. Can be used by bots.
func (*Client) AuthExportLoginToken ¶
func (c *Client) AuthExportLoginToken(ctx context.Context, request *AuthExportLoginTokenRequest) (AuthLoginTokenClass, error)
AuthExportLoginToken invokes method auth.exportLoginToken#b1b41517 returning error if any. Generate a login token, for login via QR code¹. The generated login token should be encoded using base64url, then shown as a tg://login?token=base64encodedtoken URL in the QR code. For more info, see login via QR code¹.
Links:
See https://core.telegram.org/method/auth.exportLoginToken for reference.
func (*Client) AuthImportAuthorization ¶
func (c *Client) AuthImportAuthorization(ctx context.Context, request *AuthImportAuthorizationRequest) (AuthAuthorizationClass, error)
AuthImportAuthorization invokes method auth.importAuthorization#e3ef9613 returning error if any. Logs in a user using a key transmitted from his native data-centre.
Possible errors:
400 AUTH_BYTES_INVALID: The provided authorization is invalid 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/auth.importAuthorization for reference. Can be used by bots.
func (*Client) AuthImportBotAuthorization ¶
func (c *Client) AuthImportBotAuthorization(ctx context.Context, request *AuthImportBotAuthorizationRequest) (AuthAuthorizationClass, error)
AuthImportBotAuthorization invokes method auth.importBotAuthorization#67a3ff2c returning error if any. Login as a bot
Possible errors:
400 ACCESS_TOKEN_EXPIRED: Bot token expired 400 ACCESS_TOKEN_INVALID: The provided token is not valid 400 API_ID_INVALID: The api_id/api_hash combination is invalid 401 AUTH_KEY_INVALID: Auth key invalid
See https://core.telegram.org/method/auth.importBotAuthorization for reference. Can be used by bots.
func (*Client) AuthImportLoginToken ¶
func (c *Client) AuthImportLoginToken(ctx context.Context, token []byte) (AuthLoginTokenClass, error)
AuthImportLoginToken invokes method auth.importLoginToken#95ac5ce4 returning error if any. Login using a redirected login token, generated in case of DC mismatch during QR code login¹. For more info, see login via QR code¹.
Links:
Possible errors:
400 AUTH_TOKEN_EXPIRED: The authorization token has expired
See https://core.telegram.org/method/auth.importLoginToken for reference.
func (*Client) AuthLogOut ¶
AuthLogOut invokes method auth.logOut#5717da40 returning error if any. Logs out the user.
See https://core.telegram.org/method/auth.logOut for reference. Can be used by bots.
func (*Client) AuthRecoverPassword ¶
func (c *Client) AuthRecoverPassword(ctx context.Context, code string) (AuthAuthorizationClass, error)
AuthRecoverPassword invokes method auth.recoverPassword#4ea56e92 returning error if any. Reset the 2FA password¹ using the recovery code sent using auth.requestPasswordRecovery².
Links:
Possible errors:
400 CODE_EMPTY: The provided code is empty
See https://core.telegram.org/method/auth.recoverPassword for reference.
func (*Client) AuthRequestPasswordRecovery ¶
func (c *Client) AuthRequestPasswordRecovery(ctx context.Context) (*AuthPasswordRecovery, error)
AuthRequestPasswordRecovery invokes method auth.requestPasswordRecovery#d897bc66 returning error if any. Request recovery code of a 2FA password¹, only for accounts with a recovery email configured².
Links:
Possible errors:
400 PASSWORD_EMPTY: The provided password is empty
See https://core.telegram.org/method/auth.requestPasswordRecovery for reference.
func (*Client) AuthResendCode ¶
func (c *Client) AuthResendCode(ctx context.Context, request *AuthResendCodeRequest) (*AuthSentCode, error)
AuthResendCode invokes method auth.resendCode#3ef1a9bf returning error if any. Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see login¹ for more info.
Links:
Possible errors:
400 PHONE_CODE_EXPIRED: The phone code you provided has expired, this may happen if it was sent to any chat on telegram (if the code is sent through a telegram chat (not the official account) to avoid it append or prepend to the code some chars) 400 PHONE_CODE_HASH_EMPTY: phone_code_hash is missing 400 PHONE_NUMBER_INVALID: The phone number is invalid
See https://core.telegram.org/method/auth.resendCode for reference.
func (*Client) AuthResetAuthorizations ¶
AuthResetAuthorizations invokes method auth.resetAuthorizations#9fab0d1a returning error if any. Terminates all user's authorized sessions except for the current one. After calling this method it is necessary to reregister the current device using the method account.registerDevice¹
Links:
Possible errors:
406 FRESH_RESET_AUTHORISATION_FORBIDDEN: You can't logout other sessions if less than 24 hours have passed since you logged on the current session
See https://core.telegram.org/method/auth.resetAuthorizations for reference.
func (*Client) AuthSendCode ¶
func (c *Client) AuthSendCode(ctx context.Context, request *AuthSendCodeRequest) (*AuthSentCode, error)
AuthSendCode invokes method auth.sendCode#a677244f returning error if any. Send the verification code for login
Possible errors:
400 API_ID_INVALID: API ID invalid 400 API_ID_PUBLISHED_FLOOD: This API id was published somewhere, you can't use it now 401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 INPUT_REQUEST_TOO_LONG: The request is too big 303 NETWORK_MIGRATE_X: Repeat the query to data-center X 303 PHONE_MIGRATE_X: Repeat the query to data-center X 400 PHONE_NUMBER_APP_SIGNUP_FORBIDDEN: You can't sign up using this app 400 PHONE_NUMBER_BANNED: The provided phone number is banned from telegram 400 PHONE_NUMBER_FLOOD: You asked for the code too many times. 400 PHONE_NUMBER_INVALID: Invalid phone number 406 PHONE_PASSWORD_FLOOD: You have tried logging in too many times 400 PHONE_PASSWORD_PROTECTED: This phone is password protected 400 SMS_CODE_CREATE_FAILED: An error occurred while creating the SMS code
See https://core.telegram.org/method/auth.sendCode for reference.
func (*Client) AuthSignIn ¶
func (c *Client) AuthSignIn(ctx context.Context, request *AuthSignInRequest) (AuthAuthorizationClass, error)
AuthSignIn invokes method auth.signIn#bcd51581 returning error if any. Signs in a user with a validated phone number.
Possible errors:
400 PHONE_CODE_EMPTY: phone_code from the SMS is empty 400 PHONE_CODE_EXPIRED: SMS expired 400 PHONE_CODE_INVALID: Invalid SMS code was sent 400 PHONE_NUMBER_INVALID: Invalid phone number 400 PHONE_NUMBER_UNOCCUPIED: The code is valid but no user with the given number is registered
See https://core.telegram.org/method/auth.signIn for reference.
func (*Client) AuthSignUp ¶
func (c *Client) AuthSignUp(ctx context.Context, request *AuthSignUpRequest) (AuthAuthorizationClass, error)
AuthSignUp invokes method auth.signUp#80eee427 returning error if any. Registers a validated phone number in the system.
Possible errors:
400 FIRSTNAME_INVALID: Invalid first name 400 INPUT_REQUEST_TOO_LONG: The request is too big 400 LASTNAME_INVALID: Invalid last name 400 PHONE_CODE_EMPTY: phone_code from a SMS is empty 400 PHONE_CODE_EXPIRED: SMS expired 400 PHONE_CODE_INVALID: Invalid SMS code was sent 400 PHONE_NUMBER_FLOOD: You asked for the code too many times. 400 PHONE_NUMBER_INVALID: Invalid phone number 400 PHONE_NUMBER_OCCUPIED: The phone number is already in use
See https://core.telegram.org/method/auth.signUp for reference.
func (*Client) BotsAnswerWebhookJSONQuery ¶
func (c *Client) BotsAnswerWebhookJSONQuery(ctx context.Context, request *BotsAnswerWebhookJSONQueryRequest) (bool, error)
BotsAnswerWebhookJSONQuery invokes method bots.answerWebhookJSONQuery#e6213f4d returning error if any. Answers a custom query; for bots only
Possible errors:
400 QUERY_ID_INVALID: The query ID is invalid 400 USER_BOT_INVALID: This method can only be called by a bot
See https://core.telegram.org/method/bots.answerWebhookJSONQuery for reference. Can be used by bots.
func (*Client) BotsSendCustomRequest ¶
func (c *Client) BotsSendCustomRequest(ctx context.Context, request *BotsSendCustomRequestRequest) (*DataJSON, error)
BotsSendCustomRequest invokes method bots.sendCustomRequest#aa2769ed returning error if any. Sends a custom request; for bots only
Possible errors:
400 METHOD_INVALID: The specified method is invalid 400 USER_BOT_INVALID: This method can only be called by a bot
See https://core.telegram.org/method/bots.sendCustomRequest for reference. Can be used by bots.
func (*Client) BotsSetBotCommands ¶
BotsSetBotCommands invokes method bots.setBotCommands#805d46f6 returning error if any. Set bot command list
See https://core.telegram.org/method/bots.setBotCommands for reference. Can be used by bots.
func (*Client) ChannelsCheckUsername ¶
func (c *Client) ChannelsCheckUsername(ctx context.Context, request *ChannelsCheckUsernameRequest) (bool, error)
ChannelsCheckUsername invokes method channels.checkUsername#10e6bd2c returning error if any. Check if a username is free and can be assigned to a channel/supergroup
Possible errors:
400 CHANNELS_ADMIN_PUBLIC_TOO_MUCH: You're admin of too many public channels, make some channels private to change the username of this channel 400 CHANNEL_INVALID: The provided channel is invalid 400 CHAT_ID_INVALID: The provided chat id is invalid 400 USERNAME_INVALID: The provided username is not valid
See https://core.telegram.org/method/channels.checkUsername for reference.
func (*Client) ChannelsCreateChannel ¶
func (c *Client) ChannelsCreateChannel(ctx context.Context, request *ChannelsCreateChannelRequest) (UpdatesClass, error)
ChannelsCreateChannel invokes method channels.createChannel#3d5fb10f returning error if any. Create a supergroup/channel¹.
Links:
Possible errors:
400 CHANNELS_TOO_MUCH: You have joined too many channels/supergroups 400 CHAT_ABOUT_TOO_LONG: Chat about too long 400 CHAT_TITLE_EMPTY: No chat title provided 403 USER_RESTRICTED: You're spamreported, you can't create channels or chats.
See https://core.telegram.org/method/channels.createChannel for reference.
func (*Client) ChannelsDeleteChannel ¶
func (c *Client) ChannelsDeleteChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
ChannelsDeleteChannel invokes method channels.deleteChannel#c0111fe3 returning error if any. Delete a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHANNEL_TOO_LARGE: Channel is too large to be deleted; this error is issued when trying to delete channels with more than 1000 members (subject to change) 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat
See https://core.telegram.org/method/channels.deleteChannel for reference.
func (*Client) ChannelsDeleteHistory ¶
func (c *Client) ChannelsDeleteHistory(ctx context.Context, request *ChannelsDeleteHistoryRequest) (bool, error)
ChannelsDeleteHistory invokes method channels.deleteHistory#af369d42 returning error if any. Delete the history of a supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup
See https://core.telegram.org/method/channels.deleteHistory for reference.
func (*Client) ChannelsDeleteMessages ¶
func (c *Client) ChannelsDeleteMessages(ctx context.Context, request *ChannelsDeleteMessagesRequest) (*MessagesAffectedMessages, error)
ChannelsDeleteMessages invokes method channels.deleteMessages#84c1fd4e returning error if any. Delete messages in a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 403 MESSAGE_DELETE_FORBIDDEN: You can't delete one of the messages you tried to delete, most likely because it is a service message. 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.deleteMessages for reference. Can be used by bots.
func (*Client) ChannelsDeleteUserHistory ¶
func (c *Client) ChannelsDeleteUserHistory(ctx context.Context, request *ChannelsDeleteUserHistoryRequest) (*MessagesAffectedHistory, error)
ChannelsDeleteUserHistory invokes method channels.deleteUserHistory#d10dd71b returning error if any. Delete all messages sent by a certain user in a supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 MSG_ID_INVALID: Invalid message ID provided 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/channels.deleteUserHistory for reference.
func (*Client) ChannelsEditAdmin ¶
func (c *Client) ChannelsEditAdmin(ctx context.Context, request *ChannelsEditAdminRequest) (UpdatesClass, error)
ChannelsEditAdmin invokes method channels.editAdmin#d33c8902 returning error if any. Modify the admin rights of a user in a supergroup/channel¹.
Links:
Possible errors:
400 ADMINS_TOO_MUCH: There are too many admins 400 BOTS_TOO_MUCH: There are too many bots in this chat/channel 400 BOT_CHANNELS_NA: Bots can't edit admin privileges 400 BOT_GROUPS_BLOCKED: This bot can't be added to groups 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 403 CHAT_ADMIN_INVITE_REQUIRED: You do not have the rights to do this 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 406 FRESH_CHANGE_ADMINS_FORBIDDEN: You were just elected admin, you can't add or modify other admins yet 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 PEER_ID_INVALID: The provided peer id is invalid 403 RIGHT_FORBIDDEN: Your admin rights do not allow you to do this 400 USERS_TOO_MUCH: The maximum number of users has been exceeded (to create a chat, for example) 400 USER_BLOCKED: User blocked 403 USER_CHANNELS_TOO_MUCH: One of the users you tried to add is already in too many channels/supergroups 400 USER_CREATOR: You can't leave this channel, because you're its creator 400 USER_ID_INVALID: The provided user ID is invalid 400 USER_NOT_MUTUAL_CONTACT: The provided user is not a mutual contact 403 USER_PRIVACY_RESTRICTED: The user's privacy settings do not allow you to do this 403 USER_RESTRICTED: You're spamreported, you can't create channels or chats.
See https://core.telegram.org/method/channels.editAdmin for reference. Can be used by bots.
func (*Client) ChannelsEditBanned ¶
func (c *Client) ChannelsEditBanned(ctx context.Context, request *ChannelsEditBannedRequest) (UpdatesClass, error)
ChannelsEditBanned invokes method channels.editBanned#72796912 returning error if any. Ban/unban/kick a user in a supergroup/channel¹.
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 MSG_ID_INVALID: Invalid message ID provided 400 PINNED_DIALOGS_TOO_MUCH: Too many pinned dialogs 400 USER_ADMIN_INVALID: You're not an admin 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/channels.editBanned for reference. Can be used by bots.
func (*Client) ChannelsEditCreator ¶
func (c *Client) ChannelsEditCreator(ctx context.Context, request *ChannelsEditCreatorRequest) (UpdatesClass, error)
ChannelsEditCreator invokes method channels.editCreator#8f38cd1f returning error if any. Transfer channel ownership
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 PASSWORD_HASH_INVALID: The provided password hash is invalid 400 PASSWORD_MISSING: You must enable 2FA in order to transfer ownership of a channel 400 PASSWORD_TOO_FRESH_X: The password was modified less than 24 hours ago, try again in X seconds 400 SESSION_TOO_FRESH_X: This session was created less than 24 hours ago, try again in X seconds 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/channels.editCreator for reference.
func (*Client) ChannelsEditLocation ¶
func (c *Client) ChannelsEditLocation(ctx context.Context, request *ChannelsEditLocationRequest) (bool, error)
ChannelsEditLocation invokes method channels.editLocation#58e63f6d returning error if any. Edit location of geogroup
Possible errors:
400 MEGAGROUP_REQUIRED: You can only use this method on a supergroup
See https://core.telegram.org/method/channels.editLocation for reference.
func (*Client) ChannelsEditPhoto ¶
func (c *Client) ChannelsEditPhoto(ctx context.Context, request *ChannelsEditPhotoRequest) (UpdatesClass, error)
ChannelsEditPhoto invokes method channels.editPhoto#f12e57c9 returning error if any. Change the photo of a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 PHOTO_CROP_SIZE_SMALL: Photo is too small 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_INVALID: Photo invalid
See https://core.telegram.org/method/channels.editPhoto for reference. Can be used by bots.
func (*Client) ChannelsEditTitle ¶
func (c *Client) ChannelsEditTitle(ctx context.Context, request *ChannelsEditTitleRequest) (UpdatesClass, error)
ChannelsEditTitle invokes method channels.editTitle#566decd0 returning error if any. Edit the name of a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 400 CHAT_TITLE_EMPTY: No chat title provided 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat
See https://core.telegram.org/method/channels.editTitle for reference. Can be used by bots.
func (*Client) ChannelsExportMessageLink ¶
func (c *Client) ChannelsExportMessageLink(ctx context.Context, request *ChannelsExportMessageLinkRequest) (*ExportedMessageLink, error)
ChannelsExportMessageLink invokes method channels.exportMessageLink#e63fadeb returning error if any. Get link and embed info of a message in a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.exportMessageLink for reference.
func (*Client) ChannelsGetAdminLog ¶
func (c *Client) ChannelsGetAdminLog(ctx context.Context, request *ChannelsGetAdminLogRequest) (*ChannelsAdminLogResults, error)
ChannelsGetAdminLog invokes method channels.getAdminLog#33ddf480 returning error if any. Get the admin log of a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.getAdminLog for reference.
func (*Client) ChannelsGetAdminedPublicChannels ¶
func (c *Client) ChannelsGetAdminedPublicChannels(ctx context.Context, request *ChannelsGetAdminedPublicChannelsRequest) (MessagesChatsClass, error)
ChannelsGetAdminedPublicChannels invokes method channels.getAdminedPublicChannels#f8b036af returning error if any. Get channels/supergroups/geogroups¹ we're admin in. Usually called when the user exceeds the limit² for owned public channels/supergroups/geogroups³, and the user is given the choice to remove one of his channels/supergroups/geogroups.
Links:
- https://core.telegram.org/api/channel
- https://core.telegram.org/constructor/config
- https://core.telegram.org/api/channel
Possible errors:
400 CHANNELS_ADMIN_LOCATED_TOO_MUCH: Returned if both the check_limit and the by_location flags are set and the user has reached the limit of public geogroups 400 CHANNELS_ADMIN_PUBLIC_TOO_MUCH: Returned if the check_limit flag is set and the user has reached the limit of public channels/supergroups
See https://core.telegram.org/method/channels.getAdminedPublicChannels for reference.
func (*Client) ChannelsGetChannels ¶
func (c *Client) ChannelsGetChannels(ctx context.Context, id []InputChannelClass) (MessagesChatsClass, error)
ChannelsGetChannels invokes method channels.getChannels#a7f6bbb returning error if any. Get info about channels/supergroups¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.getChannels for reference. Can be used by bots.
func (*Client) ChannelsGetFullChannel ¶
func (c *Client) ChannelsGetFullChannel(ctx context.Context, channel InputChannelClass) (*MessagesChatFull, error)
ChannelsGetFullChannel invokes method channels.getFullChannel#8736a09 returning error if any. Get full info about a channel
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 403 CHANNEL_PUBLIC_GROUP_NA: channel/supergroup not available 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.getFullChannel for reference. Can be used by bots.
func (*Client) ChannelsGetGroupsForDiscussion ¶
func (c *Client) ChannelsGetGroupsForDiscussion(ctx context.Context) (MessagesChatsClass, error)
ChannelsGetGroupsForDiscussion invokes method channels.getGroupsForDiscussion#f5dad378 returning error if any. Get all groups that can be used as discussion groups¹. Returned legacy 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 channels.togglePreHistoryHidden³, first.
Links:
- https://core.telegram.org/api/discussion
- https://core.telegram.org/api/channel
- https://core.telegram.org/api/channel
- https://core.telegram.org/method/channels.togglePreHistoryHidden
See https://core.telegram.org/method/channels.getGroupsForDiscussion for reference.
func (*Client) ChannelsGetInactiveChannels ¶
func (c *Client) ChannelsGetInactiveChannels(ctx context.Context) (*MessagesInactiveChats, error)
ChannelsGetInactiveChannels invokes method channels.getInactiveChannels#11e831ee returning error if any. Get inactive channels and supergroups
See https://core.telegram.org/method/channels.getInactiveChannels for reference.
func (*Client) ChannelsGetLeftChannels ¶
func (c *Client) ChannelsGetLeftChannels(ctx context.Context, offset int) (MessagesChatsClass, error)
ChannelsGetLeftChannels invokes method channels.getLeftChannels#8341ecc0 returning error if any. Get a list of channels/supergroups¹ we left
Links:
Possible errors:
403 TAKEOUT_REQUIRED: A takeout session has to be initialized, first
See https://core.telegram.org/method/channels.getLeftChannels for reference.
func (*Client) ChannelsGetMessages ¶
func (c *Client) ChannelsGetMessages(ctx context.Context, request *ChannelsGetMessagesRequest) (MessagesMessagesClass, error)
ChannelsGetMessages invokes method channels.getMessages#ad8c9a23 returning error if any. Get channel/supergroup¹ messages
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MESSAGE_IDS_EMPTY: No message ids were provided 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.getMessages for reference. Can be used by bots.
func (*Client) ChannelsGetParticipant ¶
func (c *Client) ChannelsGetParticipant(ctx context.Context, request *ChannelsGetParticipantRequest) (*ChannelsChannelParticipant, error)
ChannelsGetParticipant invokes method channels.getParticipant#546dd7a6 returning error if any. Get info about a channel/supergroup¹ participant
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 MSG_ID_INVALID: Invalid message ID provided 400 USER_ID_INVALID: The provided user ID is invalid 400 USER_NOT_PARTICIPANT: You're not a member of this supergroup/channel
See https://core.telegram.org/method/channels.getParticipant for reference. Can be used by bots.
func (*Client) ChannelsGetParticipants ¶
func (c *Client) ChannelsGetParticipants(ctx context.Context, request *ChannelsGetParticipantsRequest) (ChannelsChannelParticipantsClass, error)
ChannelsGetParticipants invokes method channels.getParticipants#123e05e9 returning error if any. Get the participants of a supergroup/channel¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 INPUT_CONSTRUCTOR_INVALID: The provided constructor is invalid
See https://core.telegram.org/method/channels.getParticipants for reference. Can be used by bots.
func (*Client) ChannelsInviteToChannel ¶
func (c *Client) ChannelsInviteToChannel(ctx context.Context, request *ChannelsInviteToChannelRequest) (UpdatesClass, error)
ChannelsInviteToChannel invokes method channels.inviteToChannel#199f3a6c returning error if any. Invite users to a channel/supergroup
Possible errors:
400 BOTS_TOO_MUCH: There are too many bots in this chat/channel 400 BOT_GROUPS_BLOCKED: This bot can't be added to groups 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_INVALID: Invalid chat 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided 400 USERS_TOO_MUCH: The maximum number of users has been exceeded (to create a chat, for example) 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 USER_BLOCKED: User blocked 400 USER_BOT: Bots can only be admins in channels. 403 USER_CHANNELS_TOO_MUCH: One of the users you tried to add is already in too many channels/supergroups 400 USER_ID_INVALID: The provided user ID is invalid 400 USER_KICKED: This user was kicked from this supergroup/channel 400 USER_NOT_MUTUAL_CONTACT: The provided user is not a mutual contact 403 USER_PRIVACY_RESTRICTED: The user's privacy settings do not allow you to do this
See https://core.telegram.org/method/channels.inviteToChannel for reference.
func (*Client) ChannelsJoinChannel ¶
func (c *Client) ChannelsJoinChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
ChannelsJoinChannel invokes method channels.joinChannel#24b524c5 returning error if any. Join a channel/supergroup
Possible errors:
400 CHANNELS_TOO_MUCH: You have joined too many channels/supergroups 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 INVITE_HASH_EMPTY: The invite hash is empty 400 INVITE_HASH_EXPIRED: The invite link has expired 400 INVITE_HASH_INVALID: The invite hash is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 USERS_TOO_MUCH: The maximum number of users has been exceeded (to create a chat, for example) 400 USER_ALREADY_PARTICIPANT: The user is already in the group 400 USER_CHANNELS_TOO_MUCH: One of the users you tried to add is already in too many channels/supergroups
See https://core.telegram.org/method/channels.joinChannel for reference.
func (*Client) ChannelsLeaveChannel ¶
func (c *Client) ChannelsLeaveChannel(ctx context.Context, channel InputChannelClass) (UpdatesClass, error)
ChannelsLeaveChannel invokes method channels.leaveChannel#f836aa95 returning error if any. Leave a channel/supergroup¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 403 CHANNEL_PUBLIC_GROUP_NA: channel/supergroup not available 400 MSG_ID_INVALID: Invalid message ID provided 400 USER_CREATOR: You can't leave this channel, because you're its creator 400 USER_NOT_PARTICIPANT: You're not a member of this supergroup/channel
See https://core.telegram.org/method/channels.leaveChannel for reference. Can be used by bots.
func (*Client) ChannelsReadHistory ¶
func (c *Client) ChannelsReadHistory(ctx context.Context, request *ChannelsReadHistoryRequest) (bool, error)
ChannelsReadHistory invokes method channels.readHistory#cc104937 returning error if any. Mark channel/supergroup¹ history as read
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.readHistory for reference.
func (*Client) ChannelsReadMessageContents ¶
func (c *Client) ChannelsReadMessageContents(ctx context.Context, request *ChannelsReadMessageContentsRequest) (bool, error)
ChannelsReadMessageContents invokes method channels.readMessageContents#eab5dc38 returning error if any. Mark channel/supergroup¹ message contents as read
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/channels.readMessageContents for reference.
func (*Client) ChannelsReportSpam ¶
func (c *Client) ChannelsReportSpam(ctx context.Context, request *ChannelsReportSpamRequest) (bool, error)
ChannelsReportSpam invokes method channels.reportSpam#fe087810 returning error if any. Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/channels.reportSpam for reference.
func (*Client) ChannelsSetDiscussionGroup ¶
func (c *Client) ChannelsSetDiscussionGroup(ctx context.Context, request *ChannelsSetDiscussionGroupRequest) (bool, error)
ChannelsSetDiscussionGroup invokes method channels.setDiscussionGroup#40582bb2 returning error if any. Associate a group to a channel as discussion group¹ for that channel
Links:
Possible errors:
400 BROADCAST_ID_INVALID: Broadcast ID invalid 400 LINK_NOT_MODIFIED: Discussion link not modified 400 MEGAGROUP_ID_INVALID: Invalid supergroup ID
See https://core.telegram.org/method/channels.setDiscussionGroup for reference.
func (*Client) ChannelsSetStickers ¶
func (c *Client) ChannelsSetStickers(ctx context.Context, request *ChannelsSetStickersRequest) (bool, error)
ChannelsSetStickers invokes method channels.setStickers#ea8ca4f9 returning error if any. Associate a stickerset to the supergroup
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 PARTICIPANTS_TOO_FEW: Not enough participants
See https://core.telegram.org/method/channels.setStickers for reference. Can be used by bots.
func (*Client) ChannelsTogglePreHistoryHidden ¶
func (c *Client) ChannelsTogglePreHistoryHidden(ctx context.Context, request *ChannelsTogglePreHistoryHiddenRequest) (UpdatesClass, error)
ChannelsTogglePreHistoryHidden invokes method channels.togglePreHistoryHidden#eabbb94c returning error if any. Hide/unhide message history for new channel/supergroup users
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 400 CHAT_LINK_EXISTS: The chat is public, you can't hide the history to new users 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified
See https://core.telegram.org/method/channels.togglePreHistoryHidden for reference.
func (*Client) ChannelsToggleSignatures ¶
func (c *Client) ChannelsToggleSignatures(ctx context.Context, request *ChannelsToggleSignaturesRequest) (UpdatesClass, error)
ChannelsToggleSignatures invokes method channels.toggleSignatures#1f69b606 returning error if any. Enable/disable message signatures in channels
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHAT_ID_INVALID: The provided chat id is invalid
See https://core.telegram.org/method/channels.toggleSignatures for reference.
func (*Client) ChannelsToggleSlowMode ¶
func (c *Client) ChannelsToggleSlowMode(ctx context.Context, request *ChannelsToggleSlowModeRequest) (UpdatesClass, error)
ChannelsToggleSlowMode invokes method channels.toggleSlowMode#edd49ef0 returning error if any. Toggle supergroup slow mode: if enabled, users will only be able to send one message every seconds seconds
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 400 INPUT_METHOD_INVALID_1192227_X: Invalid method 400 INPUT_METHOD_INVALID_1604042050_X: Invalid method 400 SECONDS_INVALID: Invalid duration provided
See https://core.telegram.org/method/channels.toggleSlowMode for reference.
func (*Client) ChannelsUpdateUsername ¶
func (c *Client) ChannelsUpdateUsername(ctx context.Context, request *ChannelsUpdateUsernameRequest) (bool, error)
ChannelsUpdateUsername invokes method channels.updateUsername#3514b3de returning error if any. Change the username of a supergroup/channel
Possible errors:
400 CHANNELS_ADMIN_PUBLIC_TOO_MUCH: You're admin of too many public channels, make some channels private to change the username of this channel 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 USERNAME_INVALID: The provided username is not valid 400 USERNAME_NOT_MODIFIED: The username was not modified 400 USERNAME_OCCUPIED: The provided username is already occupied
See https://core.telegram.org/method/channels.updateUsername for reference.
func (*Client) ContactsAcceptContact ¶
func (c *Client) ContactsAcceptContact(ctx context.Context, id InputUserClass) (UpdatesClass, error)
ContactsAcceptContact invokes method contacts.acceptContact#f831a20f returning error if any. If the peer settings¹ of a new user allow us to add him as contact, add that user as contact
Links:
Possible errors:
400 CONTACT_ADD_MISSING: Contact to add is missing 400 CONTACT_ID_INVALID: The provided contact ID is invalid 400 CONTACT_REQ_MISSING: Missing contact request
See https://core.telegram.org/method/contacts.acceptContact for reference.
func (*Client) ContactsAddContact ¶
func (c *Client) ContactsAddContact(ctx context.Context, request *ContactsAddContactRequest) (UpdatesClass, error)
ContactsAddContact invokes method contacts.addContact#e8f463d0 returning error if any. Add an existing telegram user as contact. Use contacts.importContacts¹ to add contacts by phone number, without knowing their Telegram ID.
Links:
Possible errors:
400 CONTACT_ID_INVALID: The provided contact ID is invalid 400 CONTACT_NAME_EMPTY: Contact name empty 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/contacts.addContact for reference.
func (*Client) ContactsBlock ¶
ContactsBlock invokes method contacts.block#68cc1411 returning error if any. Adds the user to the blacklist.
Possible errors:
400 CONTACT_ID_INVALID: The provided contact ID is invalid 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/contacts.block for reference.
func (*Client) ContactsBlockFromReplies ¶
func (c *Client) ContactsBlockFromReplies(ctx context.Context, request *ContactsBlockFromRepliesRequest) (UpdatesClass, error)
ContactsBlockFromReplies invokes method contacts.blockFromReplies#29a8962c returning error if any. Stop getting notifications about thread replies¹ of a certain user in @replies
Links:
See https://core.telegram.org/method/contacts.blockFromReplies for reference. Can be used by bots.
func (*Client) ContactsDeleteByPhones ¶
ContactsDeleteByPhones invokes method contacts.deleteByPhones#1013fd9e returning error if any. Delete contacts by phone number
See https://core.telegram.org/method/contacts.deleteByPhones for reference.
func (*Client) ContactsDeleteContacts ¶
func (c *Client) ContactsDeleteContacts(ctx context.Context, id []InputUserClass) (UpdatesClass, error)
ContactsDeleteContacts invokes method contacts.deleteContacts#96a0e00 returning error if any. Deletes several contacts from the list.
See https://core.telegram.org/method/contacts.deleteContacts for reference.
func (*Client) ContactsGetBlocked ¶
func (c *Client) ContactsGetBlocked(ctx context.Context, request *ContactsGetBlockedRequest) (ContactsBlockedClass, error)
ContactsGetBlocked invokes method contacts.getBlocked#f57c350f returning error if any. Returns the list of blocked users.
See https://core.telegram.org/method/contacts.getBlocked for reference.
func (*Client) ContactsGetContactIDs ¶ added in v0.8.0
ContactsGetContactIDs invokes method contacts.getContactIDs#2caa4a42 returning error if any. Get contact by telegram IDs
See https://core.telegram.org/method/contacts.getContactIDs for reference.
func (*Client) ContactsGetContacts ¶
ContactsGetContacts invokes method contacts.getContacts#c023849f returning error if any. Returns the current user's contact list.
See https://core.telegram.org/method/contacts.getContacts for reference.
func (*Client) ContactsGetLocated ¶
func (c *Client) ContactsGetLocated(ctx context.Context, request *ContactsGetLocatedRequest) (UpdatesClass, error)
ContactsGetLocated invokes method contacts.getLocated#d348bc44 returning error if any. Get contacts near you
Possible errors:
400 GEO_POINT_INVALID: Invalid geoposition provided 406 USERPIC_UPLOAD_REQUIRED: You must have a profile picture to publish your geolocation
See https://core.telegram.org/method/contacts.getLocated for reference.
func (*Client) ContactsGetSaved ¶ added in v0.8.0
func (c *Client) ContactsGetSaved(ctx context.Context) ([]SavedPhoneContact, error)
ContactsGetSaved invokes method contacts.getSaved#82f1e39f returning error if any. Get all contacts
Possible errors:
403 TAKEOUT_REQUIRED: A takeout session has to be initialized, first
See https://core.telegram.org/method/contacts.getSaved for reference.
func (*Client) ContactsGetStatuses ¶ added in v0.8.0
func (c *Client) ContactsGetStatuses(ctx context.Context) ([]ContactStatus, error)
ContactsGetStatuses invokes method contacts.getStatuses#c4a353ee returning error if any. Returns the list of contact statuses.
See https://core.telegram.org/method/contacts.getStatuses for reference.
func (*Client) ContactsGetTopPeers ¶
func (c *Client) ContactsGetTopPeers(ctx context.Context, request *ContactsGetTopPeersRequest) (ContactsTopPeersClass, error)
ContactsGetTopPeers invokes method contacts.getTopPeers#d4982db5 returning error if any. Get most used peers
Possible errors:
400 TYPES_EMPTY: No top peer type was provided
See https://core.telegram.org/method/contacts.getTopPeers for reference.
func (*Client) ContactsImportContacts ¶
func (c *Client) ContactsImportContacts(ctx context.Context, contacts []InputPhoneContact) (*ContactsImportedContacts, error)
ContactsImportContacts invokes method contacts.importContacts#2c800be5 returning error if any. Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info. Use contacts.addContact¹ to add Telegram contacts without actually using their phone number.
Links:
See https://core.telegram.org/method/contacts.importContacts for reference.
func (*Client) ContactsResetSaved ¶
ContactsResetSaved invokes method contacts.resetSaved#879537f1 returning error if any. Delete saved contacts
See https://core.telegram.org/method/contacts.resetSaved for reference.
func (*Client) ContactsResetTopPeerRating ¶
func (c *Client) ContactsResetTopPeerRating(ctx context.Context, request *ContactsResetTopPeerRatingRequest) (bool, error)
ContactsResetTopPeerRating invokes method contacts.resetTopPeerRating#1ae373ac returning error if any. Reset rating¹ of top peer
Links:
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/contacts.resetTopPeerRating for reference.
func (*Client) ContactsResolveUsername ¶
func (c *Client) ContactsResolveUsername(ctx context.Context, username string) (*ContactsResolvedPeer, error)
ContactsResolveUsername invokes method contacts.resolveUsername#f93ccba3 returning error if any. Resolve a @username to get peer info
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 CONNECTION_DEVICE_MODEL_EMPTY: Device model empty 400 CONNECTION_LAYER_INVALID: Layer invalid 400 USERNAME_INVALID: The provided username is not valid 400 USERNAME_NOT_OCCUPIED: The provided username is not occupied
See https://core.telegram.org/method/contacts.resolveUsername for reference. Can be used by bots.
func (*Client) ContactsSearch ¶
func (c *Client) ContactsSearch(ctx context.Context, request *ContactsSearchRequest) (*ContactsFound, error)
ContactsSearch invokes method contacts.search#11f812d8 returning error if any. Returns users found by username substring.
Possible errors:
400 QUERY_TOO_SHORT: The query string is too short 400 SEARCH_QUERY_EMPTY: The search query is empty
See https://core.telegram.org/method/contacts.search for reference.
func (*Client) ContactsToggleTopPeers ¶
ContactsToggleTopPeers invokes method contacts.toggleTopPeers#8514bdda returning error if any. Enable/disable top peers¹
Links:
See https://core.telegram.org/method/contacts.toggleTopPeers for reference.
func (*Client) ContactsUnblock ¶
ContactsUnblock invokes method contacts.unblock#bea65d50 returning error if any. Deletes the user from the blacklist.
Possible errors:
400 CONTACT_ID_INVALID: The provided contact ID is invalid
See https://core.telegram.org/method/contacts.unblock for reference.
func (*Client) FoldersDeleteFolder ¶
FoldersDeleteFolder invokes method folders.deleteFolder#1c295881 returning error if any. Delete a peer folder¹
Links:
See https://core.telegram.org/method/folders.deleteFolder for reference.
func (*Client) FoldersEditPeerFolders ¶
func (c *Client) FoldersEditPeerFolders(ctx context.Context, folderpeers []InputFolderPeer) (UpdatesClass, error)
FoldersEditPeerFolders invokes method folders.editPeerFolders#6847d0ab returning error if any. Edit peers in peer folder¹
Links:
Possible errors:
400 FOLDER_ID_INVALID: Invalid folder ID
See https://core.telegram.org/method/folders.editPeerFolders for reference.
func (*Client) HelpAcceptTermsOfService ¶
HelpAcceptTermsOfService invokes method help.acceptTermsOfService#ee72f79a returning error if any. Accept the new terms of service
See https://core.telegram.org/method/help.acceptTermsOfService for reference.
func (*Client) HelpDismissSuggestion ¶
HelpDismissSuggestion invokes method help.dismissSuggestion#77fa99f returning error if any. Dismiss a suggestion
See https://core.telegram.org/method/help.dismissSuggestion for reference. Can be used by bots.
func (*Client) HelpEditUserInfo ¶
func (c *Client) HelpEditUserInfo(ctx context.Context, request *HelpEditUserInfoRequest) (HelpUserInfoClass, error)
HelpEditUserInfo invokes method help.editUserInfo#66b91b70 returning error if any. Internal use
See https://core.telegram.org/method/help.editUserInfo for reference.
func (*Client) HelpGetAppChangelog ¶
func (c *Client) HelpGetAppChangelog(ctx context.Context, prevappversion string) (UpdatesClass, error)
HelpGetAppChangelog invokes method help.getAppChangelog#9010ef6f returning error if any. Get changelog of current app. Typically, an updates¹ constructor will be returned, containing one or more updateServiceNotification² updates with app-specific changelogs.
Links:
- https://core.telegram.org/constructor/updates
- https://core.telegram.org/constructor/updateServiceNotification
See https://core.telegram.org/method/help.getAppChangelog for reference.
func (*Client) HelpGetAppConfig ¶
func (c *Client) HelpGetAppConfig(ctx context.Context) (JSONValueClass, error)
HelpGetAppConfig invokes method help.getAppConfig#98914110 returning error if any. Get app-specific configuration, see client configuration¹ for more info on the result.
Links:
See https://core.telegram.org/method/help.getAppConfig for reference.
func (*Client) HelpGetAppUpdate ¶
HelpGetAppUpdate invokes method help.getAppUpdate#522d5a7d returning error if any. Returns information on update availability for the current application.
See https://core.telegram.org/method/help.getAppUpdate for reference.
func (*Client) HelpGetCdnConfig ¶
HelpGetCdnConfig invokes method help.getCdnConfig#52029342 returning error if any. Get configuration for CDN¹ file downloads.
Links:
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods.
See https://core.telegram.org/method/help.getCdnConfig for reference. Can be used by bots.
func (*Client) HelpGetConfig ¶
HelpGetConfig invokes method help.getConfig#c4f9186b returning error if any. Returns current configuration, including data center configuration.
Possible errors:
400 CONNECTION_API_ID_INVALID: The provided API id is invalid 400 CONNECTION_APP_VERSION_EMPTY: App version is empty 400 CONNECTION_DEVICE_MODEL_EMPTY: Device model empty 400 CONNECTION_LANG_PACK_INVALID: Language pack invalid 400 CONNECTION_LAYER_INVALID: Layer invalid 400 CONNECTION_NOT_INITED: Connection not initialized 400 CONNECTION_SYSTEM_EMPTY: Connection system empty 400 CONNECTION_SYSTEM_LANG_CODE_EMPTY: The system_lang_code field is empty 400 DATA_INVALID: Encrypted data invalid 400 INPUT_LAYER_INVALID: The provided layer is invalid 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/help.getConfig for reference. Can be used by bots.
func (*Client) HelpGetCountriesList ¶
func (c *Client) HelpGetCountriesList(ctx context.Context, request *HelpGetCountriesListRequest) (HelpCountriesListClass, error)
HelpGetCountriesList invokes method help.getCountriesList#735787a8 returning error if any. Get name, ISO code, localized name and phone codes/patterns of all available countries
See https://core.telegram.org/method/help.getCountriesList for reference. Can be used by bots.
func (*Client) HelpGetDeepLinkInfo ¶
func (c *Client) HelpGetDeepLinkInfo(ctx context.Context, path string) (HelpDeepLinkInfoClass, error)
HelpGetDeepLinkInfo invokes method help.getDeepLinkInfo#3fedc75f returning error if any. Get info about a t.me link
See https://core.telegram.org/method/help.getDeepLinkInfo for reference.
func (*Client) HelpGetInviteText ¶
func (c *Client) HelpGetInviteText(ctx context.Context) (*HelpInviteText, error)
HelpGetInviteText invokes method help.getInviteText#4d392343 returning error if any. Returns localized text of a text message with an invitation.
See https://core.telegram.org/method/help.getInviteText for reference.
func (*Client) HelpGetNearestDc ¶
HelpGetNearestDc invokes method help.getNearestDc#1fb33026 returning error if any. Returns info on data centre nearest to the user.
See https://core.telegram.org/method/help.getNearestDc for reference.
func (*Client) HelpGetPassportConfig ¶
func (c *Client) HelpGetPassportConfig(ctx context.Context, hash int) (HelpPassportConfigClass, error)
HelpGetPassportConfig invokes method help.getPassportConfig#c661ad08 returning error if any. Get passport¹ configuration
Links:
See https://core.telegram.org/method/help.getPassportConfig for reference.
func (*Client) HelpGetPromoData ¶
func (c *Client) HelpGetPromoData(ctx context.Context) (HelpPromoDataClass, error)
HelpGetPromoData invokes method help.getPromoData#c0977421 returning error if any. Get MTProxy/Public Service Announcement information
See https://core.telegram.org/method/help.getPromoData for reference. Can be used by bots.
func (*Client) HelpGetRecentMeUrls ¶
func (c *Client) HelpGetRecentMeUrls(ctx context.Context, referer string) (*HelpRecentMeUrls, error)
HelpGetRecentMeUrls invokes method help.getRecentMeUrls#3dc0f114 returning error if any. Get recently used t.me links
See https://core.telegram.org/method/help.getRecentMeUrls for reference.
func (*Client) HelpGetSupport ¶
func (c *Client) HelpGetSupport(ctx context.Context) (*HelpSupport, error)
HelpGetSupport invokes method help.getSupport#9cdf08cd returning error if any. Returns the support user for the 'ask a question' feature.
See https://core.telegram.org/method/help.getSupport for reference.
func (*Client) HelpGetSupportName ¶
func (c *Client) HelpGetSupportName(ctx context.Context) (*HelpSupportName, error)
HelpGetSupportName invokes method help.getSupportName#d360e72c returning error if any. Get localized name of the telegram support user
Possible errors:
403 USER_INVALID: Invalid user provided
See https://core.telegram.org/method/help.getSupportName for reference.
func (*Client) HelpGetTermsOfServiceUpdate ¶
func (c *Client) HelpGetTermsOfServiceUpdate(ctx context.Context) (HelpTermsOfServiceUpdateClass, error)
HelpGetTermsOfServiceUpdate invokes method help.getTermsOfServiceUpdate#2ca51fd1 returning error if any. Look for updates of telegram's terms of service
See https://core.telegram.org/method/help.getTermsOfServiceUpdate for reference.
func (*Client) HelpGetUserInfo ¶
func (c *Client) HelpGetUserInfo(ctx context.Context, userid InputUserClass) (HelpUserInfoClass, error)
HelpGetUserInfo invokes method help.getUserInfo#38a08d3 returning error if any. Internal use
Possible errors:
403 USER_INVALID: Invalid user provided
See https://core.telegram.org/method/help.getUserInfo for reference.
func (*Client) HelpHidePromoData ¶
HelpHidePromoData invokes method help.hidePromoData#1e251c95 returning error if any. Hide MTProxy/Public Service Announcement information
See https://core.telegram.org/method/help.hidePromoData for reference. Can be used by bots.
func (*Client) HelpSaveAppLog ¶
HelpSaveAppLog invokes method help.saveAppLog#6f02f748 returning error if any. Saves logs of application on the server.
See https://core.telegram.org/method/help.saveAppLog for reference.
func (*Client) HelpSetBotUpdatesStatus ¶
func (c *Client) HelpSetBotUpdatesStatus(ctx context.Context, request *HelpSetBotUpdatesStatusRequest) (bool, error)
HelpSetBotUpdatesStatus invokes method help.setBotUpdatesStatus#ec22cfcd returning error if any. Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only
See https://core.telegram.org/method/help.setBotUpdatesStatus for reference. Can be used by bots.
func (*Client) LangpackGetDifference ¶
func (c *Client) LangpackGetDifference(ctx context.Context, request *LangpackGetDifferenceRequest) (*LangPackDifference, error)
LangpackGetDifference invokes method langpack.getDifference#cd984aa5 returning error if any. Get new strings in languagepack
Possible errors:
400 LANG_PACK_INVALID: The provided language pack is invalid
See https://core.telegram.org/method/langpack.getDifference for reference.
func (*Client) LangpackGetLangPack ¶
func (c *Client) LangpackGetLangPack(ctx context.Context, request *LangpackGetLangPackRequest) (*LangPackDifference, error)
LangpackGetLangPack invokes method langpack.getLangPack#f2f2330a returning error if any. Get localization pack strings
Possible errors:
400 LANG_PACK_INVALID: The provided language pack is invalid
See https://core.telegram.org/method/langpack.getLangPack for reference.
func (*Client) LangpackGetLanguage ¶
func (c *Client) LangpackGetLanguage(ctx context.Context, request *LangpackGetLanguageRequest) (*LangPackLanguage, error)
LangpackGetLanguage invokes method langpack.getLanguage#6a596502 returning error if any. Get information about a language in a localization pack
See https://core.telegram.org/method/langpack.getLanguage for reference.
func (*Client) LangpackGetLanguages ¶ added in v0.8.0
func (c *Client) LangpackGetLanguages(ctx context.Context, langpack string) ([]LangPackLanguage, error)
LangpackGetLanguages invokes method langpack.getLanguages#42c6978f returning error if any. Get information about all languages in a localization pack
Possible errors:
400 LANG_PACK_INVALID: The provided language pack is invalid
See https://core.telegram.org/method/langpack.getLanguages for reference.
func (*Client) LangpackGetStrings ¶ added in v0.8.0
func (c *Client) LangpackGetStrings(ctx context.Context, request *LangpackGetStringsRequest) ([]LangPackStringClass, error)
LangpackGetStrings invokes method langpack.getStrings#efea3803 returning error if any. Get strings from a language pack
Possible errors:
400 LANG_PACK_INVALID: The provided language pack is invalid
See https://core.telegram.org/method/langpack.getStrings for reference.
func (*Client) MessagesAcceptEncryption ¶
func (c *Client) MessagesAcceptEncryption(ctx context.Context, request *MessagesAcceptEncryptionRequest) (EncryptedChatClass, error)
MessagesAcceptEncryption invokes method messages.acceptEncryption#3dbc0415 returning error if any. Confirms creation of a secret chat
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 ENCRYPTION_ALREADY_ACCEPTED: Secret chat already accepted 400 ENCRYPTION_ALREADY_DECLINED: The secret chat was already declined
See https://core.telegram.org/method/messages.acceptEncryption for reference.
func (*Client) MessagesAcceptUrlAuth ¶
func (c *Client) MessagesAcceptUrlAuth(ctx context.Context, request *MessagesAcceptUrlAuthRequest) (UrlAuthResultClass, error)
MessagesAcceptUrlAuth invokes method messages.acceptUrlAuth#f729ea98 returning error if any. Use this to accept a Seamless Telegram Login authorization request, for more info click here »¹
Links:
See https://core.telegram.org/method/messages.acceptUrlAuth for reference.
func (*Client) MessagesAddChatUser ¶
func (c *Client) MessagesAddChatUser(ctx context.Context, request *MessagesAddChatUserRequest) (UpdatesClass, error)
MessagesAddChatUser invokes method messages.addChatUser#f9a0aa09 returning error if any. Adds a user to a chat and sends a service message on it.
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 PEER_ID_INVALID: The provided peer id is invalid 400 USERS_TOO_MUCH: The maximum number of users has been exceeded (to create a chat, for example) 400 USER_ALREADY_PARTICIPANT: The user is already in the group 400 USER_ID_INVALID: The provided user ID is invalid 403 USER_NOT_MUTUAL_CONTACT: The provided user is not a mutual contact 403 USER_PRIVACY_RESTRICTED: The user's privacy settings do not allow you to do this
See https://core.telegram.org/method/messages.addChatUser for reference.
func (*Client) MessagesCheckChatInvite ¶
MessagesCheckChatInvite invokes method messages.checkChatInvite#3eadb1bb returning error if any. Check the validity of a chat invite link and get basic info about it
Possible errors:
400 INVITE_HASH_EMPTY: The invite hash is empty 400 INVITE_HASH_EXPIRED: The invite link has expired 400 INVITE_HASH_INVALID: The invite hash is invalid
See https://core.telegram.org/method/messages.checkChatInvite for reference.
func (*Client) MessagesClearAllDrafts ¶
MessagesClearAllDrafts invokes method messages.clearAllDrafts#7e58ee9c returning error if any. Clear all drafts¹.
Links:
See https://core.telegram.org/method/messages.clearAllDrafts for reference.
func (*Client) MessagesClearRecentStickers ¶
func (c *Client) MessagesClearRecentStickers(ctx context.Context, request *MessagesClearRecentStickersRequest) (bool, error)
MessagesClearRecentStickers invokes method messages.clearRecentStickers#8999602d returning error if any. Clear recent stickers
See https://core.telegram.org/method/messages.clearRecentStickers for reference.
func (*Client) MessagesCreateChat ¶
func (c *Client) MessagesCreateChat(ctx context.Context, request *MessagesCreateChatRequest) (UpdatesClass, error)
MessagesCreateChat invokes method messages.createChat#9cb126e returning error if any. Creates a new chat.
Possible errors:
400 CHAT_INVALID: Invalid chat 400 CHAT_TITLE_EMPTY: No chat title provided 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 USERS_TOO_FEW: Not enough users (to create a chat, for example) 403 USER_RESTRICTED: You're spamreported, you can't create channels or chats.
See https://core.telegram.org/method/messages.createChat for reference.
func (*Client) MessagesDeleteChatUser ¶
func (c *Client) MessagesDeleteChatUser(ctx context.Context, request *MessagesDeleteChatUserRequest) (UpdatesClass, error)
MessagesDeleteChatUser invokes method messages.deleteChatUser#e0611f16 returning error if any. Deletes a user from a chat and sends a service message on it.
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 USER_ID_INVALID: The provided user ID is invalid 400 USER_NOT_PARTICIPANT: You're not a member of this supergroup/channel
See https://core.telegram.org/method/messages.deleteChatUser for reference. Can be used by bots.
func (*Client) MessagesDeleteHistory ¶
func (c *Client) MessagesDeleteHistory(ctx context.Context, request *MessagesDeleteHistoryRequest) (*MessagesAffectedHistory, error)
MessagesDeleteHistory invokes method messages.deleteHistory#1c015b09 returning error if any. Deletes communication history.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.deleteHistory for reference.
func (*Client) MessagesDeleteMessages ¶
func (c *Client) MessagesDeleteMessages(ctx context.Context, request *MessagesDeleteMessagesRequest) (*MessagesAffectedMessages, error)
MessagesDeleteMessages invokes method messages.deleteMessages#e58e95d2 returning error if any. Deletes messages by their identifiers.
Possible errors:
403 MESSAGE_DELETE_FORBIDDEN: You can't delete one of the messages you tried to delete, most likely because it is a service message.
See https://core.telegram.org/method/messages.deleteMessages for reference. Can be used by bots.
func (*Client) MessagesDeleteScheduledMessages ¶
func (c *Client) MessagesDeleteScheduledMessages(ctx context.Context, request *MessagesDeleteScheduledMessagesRequest) (UpdatesClass, error)
MessagesDeleteScheduledMessages invokes method messages.deleteScheduledMessages#59ae2b16 returning error if any. Delete scheduled messages
See https://core.telegram.org/method/messages.deleteScheduledMessages for reference.
func (*Client) MessagesDiscardEncryption ¶
MessagesDiscardEncryption invokes method messages.discardEncryption#edd923c5 returning error if any. Cancels a request for creation and/or delete info on secret chat.
Possible errors:
400 CHAT_ID_EMPTY: The provided chat ID is empty 400 ENCRYPTION_ALREADY_DECLINED: The secret chat was already declined 400 ENCRYPTION_ID_INVALID: The provided secret chat ID is invalid
See https://core.telegram.org/method/messages.discardEncryption for reference.
func (*Client) MessagesEditChatAbout ¶
func (c *Client) MessagesEditChatAbout(ctx context.Context, request *MessagesEditChatAboutRequest) (bool, error)
MessagesEditChatAbout invokes method messages.editChatAbout#def60797 returning error if any. Edit the description of a group/supergroup/channel¹.
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ABOUT_NOT_MODIFIED: About text has not changed 400 CHAT_ABOUT_TOO_LONG: Chat about too long 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.editChatAbout for reference. Can be used by bots.
func (*Client) MessagesEditChatAdmin ¶
func (c *Client) MessagesEditChatAdmin(ctx context.Context, request *MessagesEditChatAdminRequest) (bool, error)
MessagesEditChatAdmin invokes method messages.editChatAdmin#a9e69f2e returning error if any. Make a user admin in a legacy group¹.
Links:
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 USER_ID_INVALID: The provided user ID is invalid 400 USER_NOT_PARTICIPANT: You're not a member of this supergroup/channel
See https://core.telegram.org/method/messages.editChatAdmin for reference.
func (*Client) MessagesEditChatDefaultBannedRights ¶
func (c *Client) MessagesEditChatDefaultBannedRights(ctx context.Context, request *MessagesEditChatDefaultBannedRightsRequest) (UpdatesClass, error)
MessagesEditChatDefaultBannedRights invokes method messages.editChatDefaultBannedRights#a5866b41 returning error if any. Edit the default banned rights of a channel/supergroup/group¹.
Links:
Possible errors:
400 BANNED_RIGHTS_INVALID: You provided some invalid flags in the banned rights 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 400 PEER_ID_INVALID: The provided peer id is invalid 400 UNTIL_DATE_INVALID: Invalid until date provided
See https://core.telegram.org/method/messages.editChatDefaultBannedRights for reference. Can be used by bots.
func (*Client) MessagesEditChatPhoto ¶
func (c *Client) MessagesEditChatPhoto(ctx context.Context, request *MessagesEditChatPhotoRequest) (UpdatesClass, error)
MessagesEditChatPhoto invokes method messages.editChatPhoto#ca4c79d8 returning error if any. Changes chat photo and sends a service message on it
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 400 INPUT_CONSTRUCTOR_INVALID: The provided constructor is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 PHOTO_CROP_SIZE_SMALL: Photo is too small 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_INVALID: Photo invalid
See https://core.telegram.org/method/messages.editChatPhoto for reference. Can be used by bots.
func (*Client) MessagesEditChatTitle ¶
func (c *Client) MessagesEditChatTitle(ctx context.Context, request *MessagesEditChatTitleRequest) (UpdatesClass, error)
MessagesEditChatTitle invokes method messages.editChatTitle#dc452855 returning error if any. Chanages chat name and sends a service message on it.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 400 CHAT_TITLE_EMPTY: No chat title provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.editChatTitle for reference. Can be used by bots.
func (*Client) MessagesEditInlineBotMessage ¶
func (c *Client) MessagesEditInlineBotMessage(ctx context.Context, request *MessagesEditInlineBotMessageRequest) (bool, error)
MessagesEditInlineBotMessage invokes method messages.editInlineBotMessage#83557dba returning error if any. Edit an inline bot message
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MESSAGE_NOT_MODIFIED: The message text has not changed
See https://core.telegram.org/method/messages.editInlineBotMessage for reference. Can be used by bots.
func (*Client) MessagesEditMessage ¶
func (c *Client) MessagesEditMessage(ctx context.Context, request *MessagesEditMessageRequest) (UpdatesClass, error)
MessagesEditMessage invokes method messages.editMessage#48f71778 returning error if any. Edit message
Possible errors:
400 BUTTON_DATA_INVALID: The data of one or more of the buttons you provided is invalid 400 BUTTON_TYPE_INVALID: The type of one or more of the buttons you provided is invalid 400 BUTTON_URL_INVALID: Button URL invalid 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 403 INLINE_BOT_REQUIRED: Only the inline bot can edit message 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MEDIA_CAPTION_TOO_LONG: The caption is too long 400 MEDIA_PREV_INVALID: Previous media invalid 403 MESSAGE_AUTHOR_REQUIRED: Message author required 400 MESSAGE_EDIT_TIME_EXPIRED: You can't edit this message anymore, too much time has passed since its creation. 400 MESSAGE_EMPTY: The provided message is empty 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MESSAGE_NOT_MODIFIED: The message text has not changed 400 MESSAGE_TOO_LONG: The provided message is too long 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 REPLY_MARKUP_INVALID: The provided reply markup is invalid 400 SCHEDULE_DATE_INVALID: Invalid schedule date provided 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels
See https://core.telegram.org/method/messages.editMessage for reference. Can be used by bots.
func (*Client) MessagesExportChatInvite ¶
func (c *Client) MessagesExportChatInvite(ctx context.Context, peer InputPeerClass) (ExportedChatInviteClass, error)
MessagesExportChatInvite invokes method messages.exportChatInvite#df7534c returning error if any. Export an invite link for a chat
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.exportChatInvite for reference. Can be used by bots.
func (*Client) MessagesFaveSticker ¶
func (c *Client) MessagesFaveSticker(ctx context.Context, request *MessagesFaveStickerRequest) (bool, error)
MessagesFaveSticker invokes method messages.faveSticker#b9ffc55b returning error if any. Mark a sticker as favorite
Possible errors:
400 STICKER_ID_INVALID: The provided sticker ID is invalid
See https://core.telegram.org/method/messages.faveSticker for reference.
func (*Client) MessagesForwardMessages ¶
func (c *Client) MessagesForwardMessages(ctx context.Context, request *MessagesForwardMessagesRequest) (UpdatesClass, error)
MessagesForwardMessages invokes method messages.forwardMessages#d9fee60e returning error if any. Forwards messages by their IDs.
Possible errors:
400 BROADCAST_PUBLIC_VOTERS_FORBIDDEN: You can't forward polls with public voters 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 400 CHAT_RESTRICTED: You can't send messages in this chat, you were restricted 403 CHAT_SEND_GIFS_FORBIDDEN: You can't send gifs in this chat 403 CHAT_SEND_MEDIA_FORBIDDEN: You can't send media in this chat 403 CHAT_SEND_POLL_FORBIDDEN: You can't send polls in this chat 403 CHAT_SEND_STICKERS_FORBIDDEN: You can't send stickers in this chat. 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 GROUPED_MEDIA_INVALID: Invalid grouped media 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MEDIA_EMPTY: The provided media object is invalid 400 MESSAGE_IDS_EMPTY: No message ids were provided 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MSG_ID_INVALID: Invalid message ID provided 420 P0NY_FLOODWAIT: 400 PEER_ID_INVALID: The provided peer id is invalid 400 RANDOM_ID_INVALID: A provided random ID is invalid 400 SCHEDULE_TOO_MUCH: There are too many scheduled messages 400 SLOWMODE_MULTI_MSGS_DISABLED: Slowmode is enabled, you cannot forward multiple messages to this group. 420 SLOWMODE_WAIT_X: Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat. 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 USER_IS_BLOCKED: You were blocked by this user 400 USER_IS_BOT: Bots can't send messages to other bots 400 YOU_BLOCKED_USER: You blocked this user
See https://core.telegram.org/method/messages.forwardMessages for reference. Can be used by bots.
func (*Client) MessagesGetAllChats ¶
func (c *Client) MessagesGetAllChats(ctx context.Context, exceptids []int) (MessagesChatsClass, error)
MessagesGetAllChats invokes method messages.getAllChats#eba80ff0 returning error if any. Get all chats, channels and supergroups
See https://core.telegram.org/method/messages.getAllChats for reference.
func (*Client) MessagesGetAllDrafts ¶
func (c *Client) MessagesGetAllDrafts(ctx context.Context) (UpdatesClass, error)
MessagesGetAllDrafts invokes method messages.getAllDrafts#6a3f8d65 returning error if any. Save get all message drafts¹.
Links:
See https://core.telegram.org/method/messages.getAllDrafts for reference.
func (*Client) MessagesGetAllStickers ¶
func (c *Client) MessagesGetAllStickers(ctx context.Context, hash int) (MessagesAllStickersClass, error)
MessagesGetAllStickers invokes method messages.getAllStickers#1c9618b1 returning error if any. Get all installed stickers
See https://core.telegram.org/method/messages.getAllStickers for reference.
func (*Client) MessagesGetArchivedStickers ¶
func (c *Client) MessagesGetArchivedStickers(ctx context.Context, request *MessagesGetArchivedStickersRequest) (*MessagesArchivedStickers, error)
MessagesGetArchivedStickers invokes method messages.getArchivedStickers#57f17692 returning error if any. Get all archived stickers
See https://core.telegram.org/method/messages.getArchivedStickers for reference.
func (*Client) MessagesGetAttachedStickers ¶ added in v0.8.0
func (c *Client) MessagesGetAttachedStickers(ctx context.Context, media InputStickeredMediaClass) ([]StickerSetCoveredClass, error)
MessagesGetAttachedStickers invokes method messages.getAttachedStickers#cc5b67cc returning error if any. Get stickers attached to a photo or video
See https://core.telegram.org/method/messages.getAttachedStickers for reference.
func (*Client) MessagesGetBotCallbackAnswer ¶
func (c *Client) MessagesGetBotCallbackAnswer(ctx context.Context, request *MessagesGetBotCallbackAnswerRequest) (*MessagesBotCallbackAnswer, error)
MessagesGetBotCallbackAnswer invokes method messages.getBotCallbackAnswer#9342ca07 returning error if any. Press an inline callback button and get a callback answer from the bot
Possible errors:
400 BOT_RESPONSE_TIMEOUT: A timeout occurred while fetching data from the bot 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 DATA_INVALID: Encrypted data invalid 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid -503 Timeout: Timeout while fetching data
See https://core.telegram.org/method/messages.getBotCallbackAnswer for reference.
func (*Client) MessagesGetChats ¶
MessagesGetChats invokes method messages.getChats#3c6aa187 returning error if any. Returns chat basic info on their IDs.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getChats for reference. Can be used by bots.
func (*Client) MessagesGetCommonChats ¶
func (c *Client) MessagesGetCommonChats(ctx context.Context, request *MessagesGetCommonChatsRequest) (MessagesChatsClass, error)
MessagesGetCommonChats invokes method messages.getCommonChats#d0a48c4 returning error if any. Get chats in common with a user
Possible errors:
400 MSG_ID_INVALID: Invalid message ID provided 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/messages.getCommonChats for reference.
func (*Client) MessagesGetDhConfig ¶
func (c *Client) MessagesGetDhConfig(ctx context.Context, request *MessagesGetDhConfigRequest) (MessagesDhConfigClass, error)
MessagesGetDhConfig invokes method messages.getDhConfig#26cf8950 returning error if any. Returns configuration parameters for Diffie-Hellman key generation. Can also return a random sequence of bytes of required length.
Possible errors:
400 RANDOM_LENGTH_INVALID: Random length invalid
See https://core.telegram.org/method/messages.getDhConfig for reference.
func (*Client) MessagesGetDialogFilters ¶ added in v0.8.0
func (c *Client) MessagesGetDialogFilters(ctx context.Context) ([]DialogFilter, error)
MessagesGetDialogFilters invokes method messages.getDialogFilters#f19ed96d returning error if any. Get folders¹
Links:
See https://core.telegram.org/method/messages.getDialogFilters for reference.
func (*Client) MessagesGetDialogUnreadMarks ¶ added in v0.8.0
func (c *Client) MessagesGetDialogUnreadMarks(ctx context.Context) ([]DialogPeerClass, error)
MessagesGetDialogUnreadMarks invokes method messages.getDialogUnreadMarks#22e24e22 returning error if any. Get dialogs manually marked as unread
See https://core.telegram.org/method/messages.getDialogUnreadMarks for reference.
func (*Client) MessagesGetDialogs ¶
func (c *Client) MessagesGetDialogs(ctx context.Context, request *MessagesGetDialogsRequest) (MessagesDialogsClass, error)
MessagesGetDialogs invokes method messages.getDialogs#a0ee3b73 returning error if any. Returns the current user dialog list.
Possible errors:
400 FOLDER_ID_INVALID: Invalid folder ID 400 INPUT_CONSTRUCTOR_INVALID: The provided constructor is invalid 400 OFFSET_PEER_ID_INVALID: The provided offset peer is invalid
See https://core.telegram.org/method/messages.getDialogs for reference.
func (*Client) MessagesGetDiscussionMessage ¶
func (c *Client) MessagesGetDiscussionMessage(ctx context.Context, request *MessagesGetDiscussionMessageRequest) (*MessagesDiscussionMessage, error)
MessagesGetDiscussionMessage invokes method messages.getDiscussionMessage#446972fd returning error if any. Get discussion message¹ from the associated discussion group² of a channel to show it on top of the comment section, without actually joining the group
Links:
See https://core.telegram.org/method/messages.getDiscussionMessage for reference. Can be used by bots.
func (*Client) MessagesGetDocumentByHash ¶
func (c *Client) MessagesGetDocumentByHash(ctx context.Context, request *MessagesGetDocumentByHashRequest) (DocumentClass, error)
MessagesGetDocumentByHash invokes method messages.getDocumentByHash#338e2464 returning error if any. Get a document by its SHA256 hash, mainly used for gifs
Possible errors:
400 SHA256_HASH_INVALID: The provided SHA256 hash is invalid
See https://core.telegram.org/method/messages.getDocumentByHash for reference. Can be used by bots.
func (*Client) MessagesGetEmojiKeywords ¶
func (c *Client) MessagesGetEmojiKeywords(ctx context.Context, langcode string) (*EmojiKeywordsDifference, error)
MessagesGetEmojiKeywords invokes method messages.getEmojiKeywords#35a0e062 returning error if any. Get localized emoji keywords
See https://core.telegram.org/method/messages.getEmojiKeywords for reference.
func (*Client) MessagesGetEmojiKeywordsDifference ¶
func (c *Client) MessagesGetEmojiKeywordsDifference(ctx context.Context, request *MessagesGetEmojiKeywordsDifferenceRequest) (*EmojiKeywordsDifference, error)
MessagesGetEmojiKeywordsDifference invokes method messages.getEmojiKeywordsDifference#1508b6af returning error if any. Get changed emoji keywords
See https://core.telegram.org/method/messages.getEmojiKeywordsDifference for reference.
func (*Client) MessagesGetEmojiKeywordsLanguages ¶ added in v0.8.0
func (c *Client) MessagesGetEmojiKeywordsLanguages(ctx context.Context, langcodes []string) ([]EmojiLanguage, error)
MessagesGetEmojiKeywordsLanguages invokes method messages.getEmojiKeywordsLanguages#4e9963b2 returning error if any. Get info about an emoji keyword localization
See https://core.telegram.org/method/messages.getEmojiKeywordsLanguages for reference.
func (*Client) MessagesGetEmojiURL ¶
MessagesGetEmojiURL invokes method messages.getEmojiURL#d5b10c26 returning error if any. Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation
See https://core.telegram.org/method/messages.getEmojiURL for reference.
func (*Client) MessagesGetFavedStickers ¶
func (c *Client) MessagesGetFavedStickers(ctx context.Context, hash int) (MessagesFavedStickersClass, error)
MessagesGetFavedStickers invokes method messages.getFavedStickers#21ce0b0e returning error if any. Get faved stickers
See https://core.telegram.org/method/messages.getFavedStickers for reference.
func (*Client) MessagesGetFeaturedStickers ¶
func (c *Client) MessagesGetFeaturedStickers(ctx context.Context, hash int) (MessagesFeaturedStickersClass, error)
MessagesGetFeaturedStickers invokes method messages.getFeaturedStickers#2dacca4f returning error if any. Get featured stickers
See https://core.telegram.org/method/messages.getFeaturedStickers for reference.
func (*Client) MessagesGetFullChat ¶
MessagesGetFullChat invokes method messages.getFullChat#3b831c66 returning error if any. Returns full chat info according to its ID.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getFullChat for reference. Can be used by bots.
func (*Client) MessagesGetGameHighScores ¶
func (c *Client) MessagesGetGameHighScores(ctx context.Context, request *MessagesGetGameHighScoresRequest) (*MessagesHighScores, error)
MessagesGetGameHighScores invokes method messages.getGameHighScores#e822649d returning error if any. Get highscores of a game
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 USER_BOT_REQUIRED: This method can only be called by a bot
See https://core.telegram.org/method/messages.getGameHighScores for reference. Can be used by bots.
func (*Client) MessagesGetHistory ¶
func (c *Client) MessagesGetHistory(ctx context.Context, request *MessagesGetHistoryRequest) (MessagesMessagesClass, error)
MessagesGetHistory invokes method messages.getHistory#dcbb8260 returning error if any. Gets back the conversation history with one interlocutor / within a chat
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ID_INVALID: The provided chat id is invalid 400 CONNECTION_DEVICE_MODEL_EMPTY: Device model empty 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getHistory for reference.
func (*Client) MessagesGetInlineBotResults ¶
func (c *Client) MessagesGetInlineBotResults(ctx context.Context, request *MessagesGetInlineBotResultsRequest) (*MessagesBotResults, error)
MessagesGetInlineBotResults invokes method messages.getInlineBotResults#514e999d returning error if any. Query an inline bot
Possible errors:
400 BOT_INLINE_DISABLED: This bot can't be used in inline mode 400 BOT_INVALID: This is not a valid bot 400 BOT_RESPONSE_TIMEOUT: A timeout occurred while fetching data from the bot 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided -503 Timeout: Timeout while fetching data
See https://core.telegram.org/method/messages.getInlineBotResults for reference.
func (*Client) MessagesGetInlineGameHighScores ¶
func (c *Client) MessagesGetInlineGameHighScores(ctx context.Context, request *MessagesGetInlineGameHighScoresRequest) (*MessagesHighScores, error)
MessagesGetInlineGameHighScores invokes method messages.getInlineGameHighScores#f635e1b returning error if any. Get highscores of a game sent using an inline bot
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 USER_BOT_REQUIRED: This method can only be called by a bot
See https://core.telegram.org/method/messages.getInlineGameHighScores for reference. Can be used by bots.
func (*Client) MessagesGetMaskStickers ¶
func (c *Client) MessagesGetMaskStickers(ctx context.Context, hash int) (MessagesAllStickersClass, error)
MessagesGetMaskStickers invokes method messages.getMaskStickers#65b8c79f returning error if any. Get installed mask stickers
See https://core.telegram.org/method/messages.getMaskStickers for reference.
func (*Client) MessagesGetMessageEditData ¶
func (c *Client) MessagesGetMessageEditData(ctx context.Context, request *MessagesGetMessageEditDataRequest) (*MessagesMessageEditData, error)
MessagesGetMessageEditData invokes method messages.getMessageEditData#fda68d36 returning error if any. Find out if a media message's caption can be edited
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 MESSAGE_AUTHOR_REQUIRED: Message author required 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getMessageEditData for reference.
func (*Client) MessagesGetMessages ¶
func (c *Client) MessagesGetMessages(ctx context.Context, id []InputMessageClass) (MessagesMessagesClass, error)
MessagesGetMessages invokes method messages.getMessages#63c66506 returning error if any. Returns the list of messages by their IDs.
See https://core.telegram.org/method/messages.getMessages for reference. Can be used by bots.
func (*Client) MessagesGetMessagesViews ¶
func (c *Client) MessagesGetMessagesViews(ctx context.Context, request *MessagesGetMessagesViewsRequest) (*MessagesMessageViews, error)
MessagesGetMessagesViews invokes method messages.getMessagesViews#5784d3e1 returning error if any. Get and increase the view counter of a message sent or forwarded from a channel¹
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ID_INVALID: The provided chat id is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getMessagesViews for reference.
func (*Client) MessagesGetOldFeaturedStickers ¶
func (c *Client) MessagesGetOldFeaturedStickers(ctx context.Context, request *MessagesGetOldFeaturedStickersRequest) (MessagesFeaturedStickersClass, error)
MessagesGetOldFeaturedStickers invokes method messages.getOldFeaturedStickers#5fe7025b returning error if any. Method for fetching previously featured stickers
See https://core.telegram.org/method/messages.getOldFeaturedStickers for reference.
func (*Client) MessagesGetOnlines ¶
func (c *Client) MessagesGetOnlines(ctx context.Context, peer InputPeerClass) (*ChatOnlines, error)
MessagesGetOnlines invokes method messages.getOnlines#6e2be050 returning error if any. Get count of online users in a chat
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getOnlines for reference.
func (*Client) MessagesGetPeerDialogs ¶
func (c *Client) MessagesGetPeerDialogs(ctx context.Context, peers []InputDialogPeerClass) (*MessagesPeerDialogs, error)
MessagesGetPeerDialogs invokes method messages.getPeerDialogs#e470bcfd returning error if any. Get dialog info of specified peers
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CONNECTION_DEVICE_MODEL_EMPTY: Device model empty 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getPeerDialogs for reference.
func (*Client) MessagesGetPeerSettings ¶
func (c *Client) MessagesGetPeerSettings(ctx context.Context, peer InputPeerClass) (*PeerSettings, error)
MessagesGetPeerSettings invokes method messages.getPeerSettings#3672e09c returning error if any. Get peer settings
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getPeerSettings for reference.
func (*Client) MessagesGetPinnedDialogs ¶
func (c *Client) MessagesGetPinnedDialogs(ctx context.Context, folderid int) (*MessagesPeerDialogs, error)
MessagesGetPinnedDialogs invokes method messages.getPinnedDialogs#d6b94df2 returning error if any. Get pinned dialogs
Possible errors:
400 FOLDER_ID_INVALID: Invalid folder ID
See https://core.telegram.org/method/messages.getPinnedDialogs for reference.
func (*Client) MessagesGetPollResults ¶
func (c *Client) MessagesGetPollResults(ctx context.Context, request *MessagesGetPollResultsRequest) (UpdatesClass, error)
MessagesGetPollResults invokes method messages.getPollResults#73bb643b returning error if any. Get poll results
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/messages.getPollResults for reference.
func (*Client) MessagesGetPollVotes ¶
func (c *Client) MessagesGetPollVotes(ctx context.Context, request *MessagesGetPollVotesRequest) (*MessagesVotesList, error)
MessagesGetPollVotes invokes method messages.getPollVotes#b86e380e returning error if any. Get poll results for non-anonymous polls
Possible errors:
403 BROADCAST_FORBIDDEN: 400 MSG_ID_INVALID: Invalid message ID provided 403 POLL_VOTE_REQUIRED: Cast a vote in the poll before calling this method
See https://core.telegram.org/method/messages.getPollVotes for reference.
func (*Client) MessagesGetRecentLocations ¶
func (c *Client) MessagesGetRecentLocations(ctx context.Context, request *MessagesGetRecentLocationsRequest) (MessagesMessagesClass, error)
MessagesGetRecentLocations invokes method messages.getRecentLocations#bbc45b09 returning error if any. Get live location history of a certain user
See https://core.telegram.org/method/messages.getRecentLocations for reference.
func (*Client) MessagesGetRecentStickers ¶
func (c *Client) MessagesGetRecentStickers(ctx context.Context, request *MessagesGetRecentStickersRequest) (MessagesRecentStickersClass, error)
MessagesGetRecentStickers invokes method messages.getRecentStickers#5ea192c9 returning error if any. Get recent stickers
See https://core.telegram.org/method/messages.getRecentStickers for reference.
func (*Client) MessagesGetReplies ¶
func (c *Client) MessagesGetReplies(ctx context.Context, request *MessagesGetRepliesRequest) (MessagesMessagesClass, error)
MessagesGetReplies invokes method messages.getReplies#24b581ba returning error if any. Get messages in a reply thread
See https://core.telegram.org/method/messages.getReplies for reference. Can be used by bots.
func (*Client) MessagesGetSavedGifs ¶
func (c *Client) MessagesGetSavedGifs(ctx context.Context, hash int) (MessagesSavedGifsClass, error)
MessagesGetSavedGifs invokes method messages.getSavedGifs#83bf3d52 returning error if any. Get saved GIFs
See https://core.telegram.org/method/messages.getSavedGifs for reference.
func (*Client) MessagesGetScheduledHistory ¶
func (c *Client) MessagesGetScheduledHistory(ctx context.Context, request *MessagesGetScheduledHistoryRequest) (MessagesMessagesClass, error)
MessagesGetScheduledHistory invokes method messages.getScheduledHistory#e2c2685b returning error if any. Get scheduled messages
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getScheduledHistory for reference.
func (*Client) MessagesGetScheduledMessages ¶
func (c *Client) MessagesGetScheduledMessages(ctx context.Context, request *MessagesGetScheduledMessagesRequest) (MessagesMessagesClass, error)
MessagesGetScheduledMessages invokes method messages.getScheduledMessages#bdbb0464 returning error if any. Get scheduled messages
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getScheduledMessages for reference.
func (*Client) MessagesGetSearchCounters ¶ added in v0.8.0
func (c *Client) MessagesGetSearchCounters(ctx context.Context, request *MessagesGetSearchCountersRequest) ([]MessagesSearchCounter, error)
MessagesGetSearchCounters invokes method messages.getSearchCounters#732eef00 returning error if any. Get the number of results that would be found by a messages.search¹ call with the same parameters
Links:
See https://core.telegram.org/method/messages.getSearchCounters for reference.
func (*Client) MessagesGetSplitRanges ¶ added in v0.8.0
func (c *Client) MessagesGetSplitRanges(ctx context.Context) ([]MessageRange, error)
MessagesGetSplitRanges invokes method messages.getSplitRanges#1cff7e08 returning error if any. Get message ranges for saving the user's chat history
See https://core.telegram.org/method/messages.getSplitRanges for reference.
func (*Client) MessagesGetStatsURL ¶
func (c *Client) MessagesGetStatsURL(ctx context.Context, request *MessagesGetStatsURLRequest) (*StatsURL, error)
MessagesGetStatsURL invokes method messages.getStatsURL#812c2ae6 returning error if any. Returns URL with the chat statistics. Currently this method can be used only for channels
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getStatsURL for reference.
func (*Client) MessagesGetStickerSet ¶
func (c *Client) MessagesGetStickerSet(ctx context.Context, stickerset InputStickerSetClass) (*MessagesStickerSet, error)
MessagesGetStickerSet invokes method messages.getStickerSet#2619a90e returning error if any. Get info about a stickerset
Possible errors:
400 STICKERSET_INVALID: The provided sticker set is invalid
See https://core.telegram.org/method/messages.getStickerSet for reference. Can be used by bots.
func (*Client) MessagesGetStickers ¶
func (c *Client) MessagesGetStickers(ctx context.Context, request *MessagesGetStickersRequest) (MessagesStickersClass, error)
MessagesGetStickers invokes method messages.getStickers#43d4f2c returning error if any. Get stickers by emoji
See https://core.telegram.org/method/messages.getStickers for reference.
func (*Client) MessagesGetSuggestedDialogFilters ¶ added in v0.8.0
func (c *Client) MessagesGetSuggestedDialogFilters(ctx context.Context) ([]DialogFilterSuggested, error)
MessagesGetSuggestedDialogFilters invokes method messages.getSuggestedDialogFilters#a29cd42c returning error if any. Get suggested folders¹
Links:
See https://core.telegram.org/method/messages.getSuggestedDialogFilters for reference.
func (*Client) MessagesGetUnreadMentions ¶
func (c *Client) MessagesGetUnreadMentions(ctx context.Context, request *MessagesGetUnreadMentionsRequest) (MessagesMessagesClass, error)
MessagesGetUnreadMentions invokes method messages.getUnreadMentions#46578472 returning error if any. Get unread messages where we were mentioned
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.getUnreadMentions for reference.
func (*Client) MessagesGetWebPage ¶
func (c *Client) MessagesGetWebPage(ctx context.Context, request *MessagesGetWebPageRequest) (WebPageClass, error)
MessagesGetWebPage invokes method messages.getWebPage#32ca8f91 returning error if any. Get instant view¹ page
Links:
Possible errors:
400 WC_CONVERT_URL_INVALID: WC convert URL invalid
See https://core.telegram.org/method/messages.getWebPage for reference.
func (*Client) MessagesGetWebPagePreview ¶
func (c *Client) MessagesGetWebPagePreview(ctx context.Context, request *MessagesGetWebPagePreviewRequest) (MessageMediaClass, error)
MessagesGetWebPagePreview invokes method messages.getWebPagePreview#8b68b0cc returning error if any. Get preview of webpage
Possible errors:
400 MESSAGE_EMPTY: The provided message is empty
See https://core.telegram.org/method/messages.getWebPagePreview for reference.
func (*Client) MessagesHidePeerSettingsBar ¶
func (c *Client) MessagesHidePeerSettingsBar(ctx context.Context, peer InputPeerClass) (bool, error)
MessagesHidePeerSettingsBar invokes method messages.hidePeerSettingsBar#4facb138 returning error if any. Should be called after the user hides the report spam/add as contact bar of a new chat, effectively prevents the user from executing the actions specified in the peer's settings¹.
Links:
See https://core.telegram.org/method/messages.hidePeerSettingsBar for reference.
func (*Client) MessagesImportChatInvite ¶
MessagesImportChatInvite invokes method messages.importChatInvite#6c50051c returning error if any. Import a chat invite and join a private chat/supergroup/channel
Possible errors:
400 CHANNELS_TOO_MUCH: You have joined too many channels/supergroups 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 INVITE_HASH_EMPTY: The invite hash is empty 400 INVITE_HASH_EXPIRED: The invite link has expired 400 INVITE_HASH_INVALID: The invite hash is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 USERS_TOO_MUCH: The maximum number of users has been exceeded (to create a chat, for example) 400 USER_ALREADY_PARTICIPANT: The user is already in the group 400 USER_CHANNELS_TOO_MUCH: One of the users you tried to add is already in too many channels/supergroups
See https://core.telegram.org/method/messages.importChatInvite for reference.
func (*Client) MessagesInstallStickerSet ¶
func (c *Client) MessagesInstallStickerSet(ctx context.Context, request *MessagesInstallStickerSetRequest) (MessagesStickerSetInstallResultClass, error)
MessagesInstallStickerSet invokes method messages.installStickerSet#c78fe460 returning error if any. Install a stickerset
Possible errors:
400 STICKERSET_INVALID: The provided sticker set is invalid
See https://core.telegram.org/method/messages.installStickerSet for reference.
func (*Client) MessagesMarkDialogUnread ¶
func (c *Client) MessagesMarkDialogUnread(ctx context.Context, request *MessagesMarkDialogUnreadRequest) (bool, error)
MessagesMarkDialogUnread invokes method messages.markDialogUnread#c286d98f returning error if any. Manually mark dialog as unread
See https://core.telegram.org/method/messages.markDialogUnread for reference.
func (*Client) MessagesMigrateChat ¶
MessagesMigrateChat invokes method messages.migrateChat#15a3b8e3 returning error if any. Turn a legacy group into a supergroup¹
Links:
Possible errors:
403 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.migrateChat for reference.
func (*Client) MessagesReadDiscussion ¶
func (c *Client) MessagesReadDiscussion(ctx context.Context, request *MessagesReadDiscussionRequest) (bool, error)
MessagesReadDiscussion invokes method messages.readDiscussion#f731a9f4 returning error if any. Mark a thread¹ as read
Links:
See https://core.telegram.org/method/messages.readDiscussion for reference. Can be used by bots.
func (*Client) MessagesReadEncryptedHistory ¶
func (c *Client) MessagesReadEncryptedHistory(ctx context.Context, request *MessagesReadEncryptedHistoryRequest) (bool, error)
MessagesReadEncryptedHistory invokes method messages.readEncryptedHistory#7f4b690a returning error if any. Marks message history within a secret chat as read.
Possible errors:
400 MSG_WAIT_FAILED: A waiting call returned an error
See https://core.telegram.org/method/messages.readEncryptedHistory for reference.
func (*Client) MessagesReadFeaturedStickers ¶
MessagesReadFeaturedStickers invokes method messages.readFeaturedStickers#5b118126 returning error if any. Mark new featured stickers as read
See https://core.telegram.org/method/messages.readFeaturedStickers for reference.
func (*Client) MessagesReadHistory ¶
func (c *Client) MessagesReadHistory(ctx context.Context, request *MessagesReadHistoryRequest) (*MessagesAffectedMessages, error)
MessagesReadHistory invokes method messages.readHistory#e306d3a returning error if any. Marks message history as read.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.readHistory for reference.
func (*Client) MessagesReadMentions ¶
func (c *Client) MessagesReadMentions(ctx context.Context, peer InputPeerClass) (*MessagesAffectedHistory, error)
MessagesReadMentions invokes method messages.readMentions#f0189d3 returning error if any. Mark mentions as read
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.readMentions for reference.
func (*Client) MessagesReadMessageContents ¶
func (c *Client) MessagesReadMessageContents(ctx context.Context, id []int) (*MessagesAffectedMessages, error)
MessagesReadMessageContents invokes method messages.readMessageContents#36a73f77 returning error if any. Notifies the sender about the recipient having listened a voice message or watched a video.
See https://core.telegram.org/method/messages.readMessageContents for reference.
func (*Client) MessagesReceivedMessages ¶ added in v0.8.0
func (c *Client) MessagesReceivedMessages(ctx context.Context, maxid int) ([]ReceivedNotifyMessage, error)
MessagesReceivedMessages invokes method messages.receivedMessages#5a954c0 returning error if any. Confirms receipt of messages by a client, cancels PUSH-notification sending.
See https://core.telegram.org/method/messages.receivedMessages for reference.
func (*Client) MessagesReceivedQueue ¶ added in v0.8.0
MessagesReceivedQueue invokes method messages.receivedQueue#55a5bb66 returning error if any. Confirms receipt of messages in a secret chat by client, cancels push notifications.
Possible errors:
400 MSG_WAIT_FAILED: A waiting call returned an error
See https://core.telegram.org/method/messages.receivedQueue for reference.
func (*Client) MessagesReorderPinnedDialogs ¶
func (c *Client) MessagesReorderPinnedDialogs(ctx context.Context, request *MessagesReorderPinnedDialogsRequest) (bool, error)
MessagesReorderPinnedDialogs invokes method messages.reorderPinnedDialogs#3b1adf37 returning error if any. Reorder pinned dialogs
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.reorderPinnedDialogs for reference.
func (*Client) MessagesReorderStickerSets ¶
func (c *Client) MessagesReorderStickerSets(ctx context.Context, request *MessagesReorderStickerSetsRequest) (bool, error)
MessagesReorderStickerSets invokes method messages.reorderStickerSets#78337739 returning error if any. Reorder installed stickersets
See https://core.telegram.org/method/messages.reorderStickerSets for reference.
func (*Client) MessagesReport ¶
MessagesReport invokes method messages.report#bd82b658 returning error if any. Report a message in a chat for violation of telegram's Terms of Service
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.report for reference.
func (*Client) MessagesReportEncryptedSpam ¶
func (c *Client) MessagesReportEncryptedSpam(ctx context.Context, peer InputEncryptedChat) (bool, error)
MessagesReportEncryptedSpam invokes method messages.reportEncryptedSpam#4b0c8c0f returning error if any. Report a secret chat for spam
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid
See https://core.telegram.org/method/messages.reportEncryptedSpam for reference.
func (*Client) MessagesReportSpam ¶
MessagesReportSpam invokes method messages.reportSpam#cf1592db returning error if any. Report a new incoming chat for spam, if the peer settings¹ of the chat allow us to do that
Links:
Possible errors:
400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.reportSpam for reference.
func (*Client) MessagesRequestEncryption ¶
func (c *Client) MessagesRequestEncryption(ctx context.Context, request *MessagesRequestEncryptionRequest) (EncryptedChatClass, error)
MessagesRequestEncryption invokes method messages.requestEncryption#f64daf43 returning error if any. Sends a request to start a secret chat to the user.
Possible errors:
400 DH_G_A_INVALID: g_a invalid 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/messages.requestEncryption for reference.
func (*Client) MessagesRequestUrlAuth ¶
func (c *Client) MessagesRequestUrlAuth(ctx context.Context, request *MessagesRequestUrlAuthRequest) (UrlAuthResultClass, error)
MessagesRequestUrlAuth invokes method messages.requestUrlAuth#e33f5613 returning error if any. Get more info about a Seamless Telegram Login authorization request, for more info click here »¹
Links:
See https://core.telegram.org/method/messages.requestUrlAuth for reference.
func (*Client) MessagesSaveDraft ¶
func (c *Client) MessagesSaveDraft(ctx context.Context, request *MessagesSaveDraftRequest) (bool, error)
MessagesSaveDraft invokes method messages.saveDraft#bc39e14b returning error if any. Save a message draft¹ associated to a chat.
Links:
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.saveDraft for reference.
func (*Client) MessagesSaveGif ¶
func (c *Client) MessagesSaveGif(ctx context.Context, request *MessagesSaveGifRequest) (bool, error)
MessagesSaveGif invokes method messages.saveGif#327a30cb returning error if any. Add GIF to saved gifs list
Possible errors:
400 GIF_ID_INVALID: The provided GIF ID is invalid
See https://core.telegram.org/method/messages.saveGif for reference.
func (*Client) MessagesSaveRecentSticker ¶
func (c *Client) MessagesSaveRecentSticker(ctx context.Context, request *MessagesSaveRecentStickerRequest) (bool, error)
MessagesSaveRecentSticker invokes method messages.saveRecentSticker#392718f8 returning error if any. Add/remove sticker from recent stickers list
Possible errors:
400 STICKER_ID_INVALID: The provided sticker ID is invalid
See https://core.telegram.org/method/messages.saveRecentSticker for reference.
func (*Client) MessagesSearch ¶
func (c *Client) MessagesSearch(ctx context.Context, request *MessagesSearchRequest) (MessagesMessagesClass, error)
MessagesSearch invokes method messages.search#c352eec returning error if any. Gets back found messages
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 INPUT_CONSTRUCTOR_INVALID: The provided constructor is invalid 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 PEER_ID_NOT_SUPPORTED: The provided peer ID is not supported 400 SEARCH_QUERY_EMPTY: The search query is empty 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/messages.search for reference.
func (*Client) MessagesSearchGlobal ¶
func (c *Client) MessagesSearchGlobal(ctx context.Context, request *MessagesSearchGlobalRequest) (MessagesMessagesClass, error)
MessagesSearchGlobal invokes method messages.searchGlobal#4bc6589a returning error if any. Search for messages and peers globally
Possible errors:
400 FOLDER_ID_INVALID: Invalid folder ID 400 SEARCH_QUERY_EMPTY: The search query is empty
See https://core.telegram.org/method/messages.searchGlobal for reference.
func (*Client) MessagesSearchStickerSets ¶
func (c *Client) MessagesSearchStickerSets(ctx context.Context, request *MessagesSearchStickerSetsRequest) (MessagesFoundStickerSetsClass, error)
MessagesSearchStickerSets invokes method messages.searchStickerSets#c2b7d08b returning error if any. Search for stickersets
See https://core.telegram.org/method/messages.searchStickerSets for reference.
func (*Client) MessagesSendEncrypted ¶
func (c *Client) MessagesSendEncrypted(ctx context.Context, request *MessagesSendEncryptedRequest) (MessagesSentEncryptedMessageClass, error)
MessagesSendEncrypted invokes method messages.sendEncrypted#44fa7a15 returning error if any. Sends a text message to a secret chat.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid 400 DATA_INVALID: Encrypted data invalid 400 ENCRYPTION_DECLINED: The secret chat was declined 400 MSG_WAIT_FAILED: A waiting call returned an error
See https://core.telegram.org/method/messages.sendEncrypted for reference.
func (*Client) MessagesSendEncryptedFile ¶
func (c *Client) MessagesSendEncryptedFile(ctx context.Context, request *MessagesSendEncryptedFileRequest) (MessagesSentEncryptedMessageClass, error)
MessagesSendEncryptedFile invokes method messages.sendEncryptedFile#5559481d returning error if any. Sends a message with a file attachment to a secret chat
Possible errors:
400 DATA_TOO_LONG: Data too long 400 ENCRYPTION_DECLINED: The secret chat was declined 400 MD5_CHECKSUM_INVALID: The MD5 checksums do not match 400 MSG_WAIT_FAILED: A waiting call returned an error
See https://core.telegram.org/method/messages.sendEncryptedFile for reference.
func (*Client) MessagesSendEncryptedService ¶
func (c *Client) MessagesSendEncryptedService(ctx context.Context, request *MessagesSendEncryptedServiceRequest) (MessagesSentEncryptedMessageClass, error)
MessagesSendEncryptedService invokes method messages.sendEncryptedService#32d439a4 returning error if any. Sends a service message to a secret chat.
Possible errors:
400 DATA_INVALID: Encrypted data invalid 400 ENCRYPTION_DECLINED: The secret chat was declined 400 ENCRYPTION_ID_INVALID: The provided secret chat ID is invalid 400 MSG_WAIT_FAILED: A waiting call returned an error 403 USER_IS_BLOCKED: You were blocked by this user
See https://core.telegram.org/method/messages.sendEncryptedService for reference.
func (*Client) MessagesSendInlineBotResult ¶
func (c *Client) MessagesSendInlineBotResult(ctx context.Context, request *MessagesSendInlineBotResultRequest) (UpdatesClass, error)
MessagesSendInlineBotResult invokes method messages.sendInlineBotResult#220815b0 returning error if any. Send a result obtained using messages.getInlineBotResults¹.
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_RESTRICTED: You can't send messages in this chat, you were restricted 403 CHAT_SEND_GIFS_FORBIDDEN: You can't send gifs in this chat 403 CHAT_SEND_INLINE_FORBIDDEN: You can't send inline messages in this group 403 CHAT_SEND_MEDIA_FORBIDDEN: You can't send media in this chat 403 CHAT_SEND_STICKERS_FORBIDDEN: You can't send stickers in this chat. 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 INLINE_RESULT_EXPIRED: The inline query expired 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MEDIA_EMPTY: The provided media object is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 QUERY_ID_EMPTY: The query ID is empty 400 RESULT_ID_EMPTY: Result ID empty 420 SLOWMODE_WAIT_X: Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat. 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 WEBPAGE_CURL_FAILED: Failure while fetching the webpage with cURL 400 WEBPAGE_MEDIA_EMPTY: Webpage media empty 400 YOU_BLOCKED_USER: You blocked this user
See https://core.telegram.org/method/messages.sendInlineBotResult for reference.
func (*Client) MessagesSendMedia ¶
func (c *Client) MessagesSendMedia(ctx context.Context, request *MessagesSendMediaRequest) (UpdatesClass, error)
MessagesSendMedia invokes method messages.sendMedia#3491eba9 returning error if any. Send a media
Possible errors:
400 BROADCAST_PUBLIC_VOTERS_FORBIDDEN: You can't forward polls with public voters 400 BUTTON_DATA_INVALID: The data of one or more of the buttons you provided is invalid 400 BUTTON_TYPE_INVALID: The type of one or more of the buttons you provided is invalid 400 BUTTON_URL_INVALID: Button URL invalid 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_RESTRICTED: You can't send messages in this chat, you were restricted 403 CHAT_SEND_GIFS_FORBIDDEN: You can't send gifs in this chat 403 CHAT_SEND_MEDIA_FORBIDDEN: You can't send media in this chat 403 CHAT_SEND_STICKERS_FORBIDDEN: You can't send stickers in this chat. 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 EXTERNAL_URL_INVALID: External URL invalid 400 FILE_PARTS_INVALID: The number of file parts is invalid 400 FILE_PART_LENGTH_INVALID: The length of a file part is invalid 400 IMAGE_PROCESS_FAILED: Failure while processing image 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MD5_CHECKSUM_INVALID: The MD5 checksums do not match 400 MEDIA_CAPTION_TOO_LONG: The caption is too long 400 MEDIA_EMPTY: The provided media object is invalid 400 MEDIA_INVALID: Media invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_INVALID_DIMENSIONS: The photo dimensions are invalid 400 PHOTO_SAVE_FILE_INVALID: Internal issues, try again later 400 POLL_ANSWERS_INVALID: Invalid poll answers were provided 400 POLL_OPTION_DUPLICATE: Duplicate poll options provided 400 POLL_OPTION_INVALID: Invalid poll option provided 400 QUIZ_CORRECT_ANSWERS_EMPTY: No correct quiz answer was specified 400 QUIZ_CORRECT_ANSWER_INVALID: An invalid value was provided to the correct_answers field 400 REPLY_MARKUP_BUY_EMPTY: Reply markup for buy button empty 400 REPLY_MARKUP_INVALID: The provided reply markup is invalid 400 SCHEDULE_TOO_MUCH: There are too many scheduled messages 420 SLOWMODE_WAIT_X: Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat. 400 TTL_MEDIA_INVALID: Invalid media Time To Live was provided 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 USER_IS_BLOCKED: You were blocked by this user 400 USER_IS_BOT: Bots can't send messages to other bots 400 WEBPAGE_CURL_FAILED: Failure while fetching the webpage with cURL 400 WEBPAGE_MEDIA_EMPTY: Webpage media empty 400 YOU_BLOCKED_USER: You blocked this user
See https://core.telegram.org/method/messages.sendMedia for reference. Can be used by bots.
func (*Client) MessagesSendMessage ¶
func (c *Client) MessagesSendMessage(ctx context.Context, request *MessagesSendMessageRequest) (UpdatesClass, error)
MessagesSendMessage invokes method messages.sendMessage#520c3870 returning error if any. Sends a message to a chat
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 BOT_DOMAIN_INVALID: Bot domain invalid 400 BOT_INVALID: This is not a valid bot 400 BUTTON_DATA_INVALID: The data of one or more of the buttons you provided is invalid 400 BUTTON_TYPE_INVALID: The type of one or more of the buttons you provided is invalid 400 BUTTON_URL_INVALID: Button URL invalid 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 400 CHAT_RESTRICTED: You can't send messages in this chat, you were restricted 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 ENCRYPTION_DECLINED: The secret chat was declined 400 ENTITY_MENTION_USER_INVALID: You mentioned an invalid user 400 FROM_MESSAGE_BOT_DISABLED: Bots can't use fromMessage min constructors 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MESSAGE_EMPTY: The provided message is empty 400 MESSAGE_TOO_LONG: The provided message is too long 400 MSG_ID_INVALID: Provided reply_to_msg_id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 PINNED_DIALOGS_TOO_MUCH: Too many pinned dialogs 400 REPLY_MARKUP_INVALID: The provided reply markup is invalid 400 SCHEDULE_BOT_NOT_ALLOWED: Bots cannot schedule messages 400 SCHEDULE_DATE_TOO_LATE: You can't schedule a message this far in the future 400 SCHEDULE_TOO_MUCH: There are too many scheduled messages 420 SLOWMODE_WAIT_X: Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat. 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 USER_IS_BLOCKED: You were blocked by this user 400 USER_IS_BOT: Bots can't send messages to other bots 400 YOU_BLOCKED_USER: You blocked this user
See https://core.telegram.org/method/messages.sendMessage for reference. Can be used by bots.
func (*Client) MessagesSendMultiMedia ¶
func (c *Client) MessagesSendMultiMedia(ctx context.Context, request *MessagesSendMultiMediaRequest) (UpdatesClass, error)
MessagesSendMultiMedia invokes method messages.sendMultiMedia#cc0110cb returning error if any. Send an album or grouped media¹
Links:
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 MEDIA_EMPTY: The provided media object is invalid 400 MEDIA_INVALID: Media invalid 400 MULTI_MEDIA_TOO_LONG: Too many media files for album 400 PEER_ID_INVALID: The provided peer id is invalid 400 RANDOM_ID_EMPTY: Random ID empty
See https://core.telegram.org/method/messages.sendMultiMedia for reference. Can be used by bots.
func (*Client) MessagesSendScheduledMessages ¶
func (c *Client) MessagesSendScheduledMessages(ctx context.Context, request *MessagesSendScheduledMessagesRequest) (UpdatesClass, error)
MessagesSendScheduledMessages invokes method messages.sendScheduledMessages#bd38850a returning error if any. Send scheduled messages right away
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/messages.sendScheduledMessages for reference.
func (*Client) MessagesSendScreenshotNotification ¶
func (c *Client) MessagesSendScreenshotNotification(ctx context.Context, request *MessagesSendScreenshotNotificationRequest) (UpdatesClass, error)
MessagesSendScreenshotNotification invokes method messages.sendScreenshotNotification#c97df020 returning error if any. Notify the other user in a private chat that a screenshot of the chat was taken
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.sendScreenshotNotification for reference.
func (*Client) MessagesSendVote ¶
func (c *Client) MessagesSendVote(ctx context.Context, request *MessagesSendVoteRequest) (UpdatesClass, error)
MessagesSendVote invokes method messages.sendVote#10ea6184 returning error if any. Vote in a poll¹
Links:
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 MESSAGE_POLL_CLOSED: Poll closed 400 OPTIONS_TOO_MUCH: Too many options provided 400 OPTION_INVALID: Invalid option selected 400 REVOTE_NOT_ALLOWED: You cannot change your vote
See https://core.telegram.org/method/messages.sendVote for reference.
func (*Client) MessagesSetBotCallbackAnswer ¶
func (c *Client) MessagesSetBotCallbackAnswer(ctx context.Context, request *MessagesSetBotCallbackAnswerRequest) (bool, error)
MessagesSetBotCallbackAnswer invokes method messages.setBotCallbackAnswer#d58f130a returning error if any. Set the callback answer to a user button press (bots only)
Possible errors:
400 QUERY_ID_INVALID: The query ID is invalid 400 URL_INVALID: Invalid URL provided
See https://core.telegram.org/method/messages.setBotCallbackAnswer for reference. Can be used by bots.
func (*Client) MessagesSetBotPrecheckoutResults ¶
func (c *Client) MessagesSetBotPrecheckoutResults(ctx context.Context, request *MessagesSetBotPrecheckoutResultsRequest) (bool, error)
MessagesSetBotPrecheckoutResults invokes method messages.setBotPrecheckoutResults#9c2dd95 returning error if any. Once the user has confirmed their payment and shipping details, the bot receives an updateBotPrecheckoutQuery¹ update. Use this method to respond to such pre-checkout queries. Note: Telegram must receive an answer within 10 seconds after the pre-checkout query was sent.
Links:
Possible errors:
400 ERROR_TEXT_EMPTY: The provided error message is empty
See https://core.telegram.org/method/messages.setBotPrecheckoutResults for reference. Can be used by bots.
func (*Client) MessagesSetBotShippingResults ¶
func (c *Client) MessagesSetBotShippingResults(ctx context.Context, request *MessagesSetBotShippingResultsRequest) (bool, error)
MessagesSetBotShippingResults invokes method messages.setBotShippingResults#e5f672fa returning error if any. If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the bot will receive an updateBotShippingQuery¹ update. Use this method to reply to shipping queries.
Links:
Possible errors:
400 QUERY_ID_INVALID: The query ID is invalid
See https://core.telegram.org/method/messages.setBotShippingResults for reference. Can be used by bots.
func (*Client) MessagesSetEncryptedTyping ¶
func (c *Client) MessagesSetEncryptedTyping(ctx context.Context, request *MessagesSetEncryptedTypingRequest) (bool, error)
MessagesSetEncryptedTyping invokes method messages.setEncryptedTyping#791451ed returning error if any. Send typing event by the current user to a secret chat.
Possible errors:
400 CHAT_ID_INVALID: The provided chat id is invalid
See https://core.telegram.org/method/messages.setEncryptedTyping for reference.
func (*Client) MessagesSetGameScore ¶
func (c *Client) MessagesSetGameScore(ctx context.Context, request *MessagesSetGameScoreRequest) (UpdatesClass, error)
MessagesSetGameScore invokes method messages.setGameScore#8ef8ecc0 returning error if any. Use this method to set the score of the specified user in a game sent as a normal message (bots only).
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 USER_BOT_REQUIRED: This method can only be called by a bot
See https://core.telegram.org/method/messages.setGameScore for reference. Can be used by bots.
func (*Client) MessagesSetInlineBotResults ¶
func (c *Client) MessagesSetInlineBotResults(ctx context.Context, request *MessagesSetInlineBotResultsRequest) (bool, error)
MessagesSetInlineBotResults invokes method messages.setInlineBotResults#eb5ea206 returning error if any. Answer an inline query, for bots only
Possible errors:
400 ARTICLE_TITLE_EMPTY: The title of the article is empty 400 BUTTON_DATA_INVALID: The data of one or more of the buttons you provided is invalid 400 BUTTON_TYPE_INVALID: The type of one or more of the buttons you provided is invalid 400 BUTTON_URL_INVALID: Button URL invalid 400 GIF_CONTENT_TYPE_INVALID: GIF content-type invalid 400 MESSAGE_EMPTY: The provided message is empty 400 MESSAGE_TOO_LONG: The provided message is too long 400 PHOTO_CONTENT_TYPE_INVALID: Photo mime-type invalid 400 PHOTO_CONTENT_URL_EMPTY: Photo URL invalid 400 PHOTO_INVALID: Photo invalid 400 PHOTO_THUMB_URL_EMPTY: Photo thumbnail URL is empty 400 QUERY_ID_INVALID: The query ID is invalid 400 REPLY_MARKUP_INVALID: The provided reply markup is invalid 400 RESULTS_TOO_MUCH: Too many results were provided 400 RESULT_ID_DUPLICATE: You provided a duplicate result ID 400 RESULT_TYPE_INVALID: Result type invalid 400 SEND_MESSAGE_MEDIA_INVALID: Invalid media provided 400 SEND_MESSAGE_TYPE_INVALID: The message type is invalid 400 START_PARAM_INVALID: Start parameter invalid 403 USER_BOT_INVALID: This method can only be called by a bot 400 WEBDOCUMENT_INVALID: Invalid webdocument URL provided 400 WEBDOCUMENT_MIME_INVALID: Invalid webdocument mime type provided 400 WEBDOCUMENT_SIZE_TOO_BIG: Webdocument is too big!
See https://core.telegram.org/method/messages.setInlineBotResults for reference. Can be used by bots.
func (*Client) MessagesSetInlineGameScore ¶
func (c *Client) MessagesSetInlineGameScore(ctx context.Context, request *MessagesSetInlineGameScoreRequest) (bool, error)
MessagesSetInlineGameScore invokes method messages.setInlineGameScore#15ad9f64 returning error if any. Use this method to set the score of the specified user in a game sent as an inline message (bots only).
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid 400 USER_BOT_REQUIRED: This method can only be called by a bot
See https://core.telegram.org/method/messages.setInlineGameScore for reference. Can be used by bots.
func (*Client) MessagesSetTyping ¶
func (c *Client) MessagesSetTyping(ctx context.Context, request *MessagesSetTypingRequest) (bool, error)
MessagesSetTyping invokes method messages.setTyping#58943ee2 returning error if any. Sends a current user typing event (see SendMessageAction¹ for all event types) to a conversation partner or group.
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_ID_INVALID: The provided chat id is invalid 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 USER_IS_BLOCKED: You were blocked by this user 400 USER_IS_BOT: Bots can't send messages to other bots
See https://core.telegram.org/method/messages.setTyping for reference. Can be used by bots.
func (*Client) MessagesStartBot ¶
func (c *Client) MessagesStartBot(ctx context.Context, request *MessagesStartBotRequest) (UpdatesClass, error)
MessagesStartBot invokes method messages.startBot#e6df7378 returning error if any. Start a conversation with a bot using a deep linking parameter¹
Links:
Possible errors:
400 BOT_INVALID: This is not a valid bot 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 START_PARAM_EMPTY: The start parameter is empty 400 START_PARAM_INVALID: Start parameter invalid 400 START_PARAM_TOO_LONG: Start parameter is too long
See https://core.telegram.org/method/messages.startBot for reference.
func (*Client) MessagesToggleDialogPin ¶
func (c *Client) MessagesToggleDialogPin(ctx context.Context, request *MessagesToggleDialogPinRequest) (bool, error)
MessagesToggleDialogPin invokes method messages.toggleDialogPin#a731e257 returning error if any. Pin/unpin a dialog
Possible errors:
400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/messages.toggleDialogPin for reference.
func (*Client) MessagesToggleStickerSets ¶
func (c *Client) MessagesToggleStickerSets(ctx context.Context, request *MessagesToggleStickerSetsRequest) (bool, error)
MessagesToggleStickerSets invokes method messages.toggleStickerSets#b5052fea returning error if any. Apply changes to multiple stickersets
See https://core.telegram.org/method/messages.toggleStickerSets for reference.
func (*Client) MessagesUninstallStickerSet ¶
func (c *Client) MessagesUninstallStickerSet(ctx context.Context, stickerset InputStickerSetClass) (bool, error)
MessagesUninstallStickerSet invokes method messages.uninstallStickerSet#f96e55de returning error if any. Uninstall a stickerset
Possible errors:
400 STICKERSET_INVALID: The provided sticker set is invalid
See https://core.telegram.org/method/messages.uninstallStickerSet for reference.
func (*Client) MessagesUnpinAllMessages ¶
func (c *Client) MessagesUnpinAllMessages(ctx context.Context, peer InputPeerClass) (*MessagesAffectedHistory, error)
MessagesUnpinAllMessages invokes method messages.unpinAllMessages#f025bc8b returning error if any. Unpin¹ all pinned messages
Links:
See https://core.telegram.org/method/messages.unpinAllMessages for reference. Can be used by bots.
func (*Client) MessagesUpdateDialogFilter ¶
func (c *Client) MessagesUpdateDialogFilter(ctx context.Context, request *MessagesUpdateDialogFilterRequest) (bool, error)
MessagesUpdateDialogFilter invokes method messages.updateDialogFilter#1ad4a04a returning error if any. Update folder¹
Links:
Possible errors:
400 FILTER_ID_INVALID: The specified filter ID is invalid
See https://core.telegram.org/method/messages.updateDialogFilter for reference.
func (*Client) MessagesUpdateDialogFiltersOrder ¶
MessagesUpdateDialogFiltersOrder invokes method messages.updateDialogFiltersOrder#c563c1e4 returning error if any. Reorder folders¹
Links:
See https://core.telegram.org/method/messages.updateDialogFiltersOrder for reference.
func (*Client) MessagesUpdatePinnedMessage ¶
func (c *Client) MessagesUpdatePinnedMessage(ctx context.Context, request *MessagesUpdatePinnedMessageRequest) (UpdatesClass, error)
MessagesUpdatePinnedMessage invokes method messages.updatePinnedMessage#d2aaf7ec returning error if any. Pin a message
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 400 CHAT_NOT_MODIFIED: The pinned message wasn't modified 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 MESSAGE_ID_INVALID: The provided message id is invalid 400 PIN_RESTRICTED: You can't pin messages
See https://core.telegram.org/method/messages.updatePinnedMessage for reference. Can be used by bots.
func (*Client) MessagesUploadEncryptedFile ¶
func (c *Client) MessagesUploadEncryptedFile(ctx context.Context, request *MessagesUploadEncryptedFileRequest) (EncryptedFileClass, error)
MessagesUploadEncryptedFile invokes method messages.uploadEncryptedFile#5057c497 returning error if any. Upload encrypted file and associate it to a secret chat
See https://core.telegram.org/method/messages.uploadEncryptedFile for reference.
func (*Client) MessagesUploadMedia ¶
func (c *Client) MessagesUploadMedia(ctx context.Context, request *MessagesUploadMediaRequest) (MessageMediaClass, error)
MessagesUploadMedia invokes method messages.uploadMedia#519bc2b1 returning error if any. Upload a file and associate it to a chat (without actually sending it to the chat)
Possible errors:
400 BOT_MISSING: This method can only be run by a bot 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this 403 CHAT_WRITE_FORBIDDEN: You can't write in this chat 400 FILE_PARTS_INVALID: The number of file parts is invalid 400 IMAGE_PROCESS_FAILED: Failure while processing image 400 INPUT_USER_DEACTIVATED: The specified user was deleted 400 MEDIA_INVALID: Media invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 PEER_ID_INVALID: The provided peer id is invalid 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_SAVE_FILE_INVALID: Internal issues, try again later 400 USER_BANNED_IN_CHANNEL: You're banned from sending messages in supergroups/channels 400 WEBPAGE_CURL_FAILED: Failure while fetching the webpage with cURL
See https://core.telegram.org/method/messages.uploadMedia for reference. Can be used by bots.
func (*Client) PaymentsClearSavedInfo ¶
func (c *Client) PaymentsClearSavedInfo(ctx context.Context, request *PaymentsClearSavedInfoRequest) (bool, error)
PaymentsClearSavedInfo invokes method payments.clearSavedInfo#d83d70c1 returning error if any. Clear saved payment information
See https://core.telegram.org/method/payments.clearSavedInfo for reference.
func (*Client) PaymentsGetBankCardData ¶
func (c *Client) PaymentsGetBankCardData(ctx context.Context, number string) (*PaymentsBankCardData, error)
PaymentsGetBankCardData invokes method payments.getBankCardData#2e79d779 returning error if any. Get info about a credit card
See https://core.telegram.org/method/payments.getBankCardData for reference.
func (*Client) PaymentsGetPaymentForm ¶
func (c *Client) PaymentsGetPaymentForm(ctx context.Context, msgid int) (*PaymentsPaymentForm, error)
PaymentsGetPaymentForm invokes method payments.getPaymentForm#99f09745 returning error if any. Get a payment form
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/payments.getPaymentForm for reference.
func (*Client) PaymentsGetPaymentReceipt ¶
func (c *Client) PaymentsGetPaymentReceipt(ctx context.Context, msgid int) (*PaymentsPaymentReceipt, error)
PaymentsGetPaymentReceipt invokes method payments.getPaymentReceipt#a092a980 returning error if any. Get payment receipt
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/payments.getPaymentReceipt for reference.
func (*Client) PaymentsGetSavedInfo ¶
func (c *Client) PaymentsGetSavedInfo(ctx context.Context) (*PaymentsSavedInfo, error)
PaymentsGetSavedInfo invokes method payments.getSavedInfo#227d824b returning error if any. Get saved payment information
See https://core.telegram.org/method/payments.getSavedInfo for reference.
func (*Client) PaymentsSendPaymentForm ¶
func (c *Client) PaymentsSendPaymentForm(ctx context.Context, request *PaymentsSendPaymentFormRequest) (PaymentsPaymentResultClass, error)
PaymentsSendPaymentForm invokes method payments.sendPaymentForm#2b8879b3 returning error if any. Send compiled payment form
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/payments.sendPaymentForm for reference.
func (*Client) PaymentsValidateRequestedInfo ¶
func (c *Client) PaymentsValidateRequestedInfo(ctx context.Context, request *PaymentsValidateRequestedInfoRequest) (*PaymentsValidatedRequestedInfo, error)
PaymentsValidateRequestedInfo invokes method payments.validateRequestedInfo#770a8e74 returning error if any. Submit requested order information for validation
Possible errors:
400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/payments.validateRequestedInfo for reference.
func (*Client) PhoneAcceptCall ¶
func (c *Client) PhoneAcceptCall(ctx context.Context, request *PhoneAcceptCallRequest) (*PhonePhoneCall, error)
PhoneAcceptCall invokes method phone.acceptCall#3bd2b4a0 returning error if any. Accept incoming call
Possible errors:
400 CALL_ALREADY_ACCEPTED: The call was already accepted 400 CALL_ALREADY_DECLINED: The call was already declined 400 CALL_PEER_INVALID: The provided call peer object is invalid 400 CALL_PROTOCOL_FLAGS_INVALID: Call protocol flags invalid
See https://core.telegram.org/method/phone.acceptCall for reference.
func (*Client) PhoneCheckGroupCall ¶ added in v0.13.0
func (c *Client) PhoneCheckGroupCall(ctx context.Context, request *PhoneCheckGroupCallRequest) (bool, error)
PhoneCheckGroupCall invokes method phone.checkGroupCall#b74a7bea returning error if any.
See https://core.telegram.org/method/phone.checkGroupCall for reference.
func (*Client) PhoneConfirmCall ¶
func (c *Client) PhoneConfirmCall(ctx context.Context, request *PhoneConfirmCallRequest) (*PhonePhoneCall, error)
PhoneConfirmCall invokes method phone.confirmCall#2efe1722 returning error if any. Complete phone call E2E encryption key exchange »¹
Links:
Possible errors:
400 CALL_ALREADY_DECLINED: The call was already declined 400 CALL_PEER_INVALID: The provided call peer object is invalid
See https://core.telegram.org/method/phone.confirmCall for reference.
func (*Client) PhoneCreateGroupCall ¶ added in v0.13.0
func (c *Client) PhoneCreateGroupCall(ctx context.Context, request *PhoneCreateGroupCallRequest) (UpdatesClass, error)
PhoneCreateGroupCall invokes method phone.createGroupCall#bd3dabe0 returning error if any.
See https://core.telegram.org/method/phone.createGroupCall for reference.
func (*Client) PhoneDiscardCall ¶
func (c *Client) PhoneDiscardCall(ctx context.Context, request *PhoneDiscardCallRequest) (UpdatesClass, error)
PhoneDiscardCall invokes method phone.discardCall#b2cbc1c0 returning error if any. Refuse or end running call
Possible errors:
400 CALL_ALREADY_ACCEPTED: The call was already accepted 400 CALL_PEER_INVALID: The provided call peer object is invalid
See https://core.telegram.org/method/phone.discardCall for reference.
func (*Client) PhoneDiscardGroupCall ¶ added in v0.13.0
func (c *Client) PhoneDiscardGroupCall(ctx context.Context, call InputGroupCall) (UpdatesClass, error)
PhoneDiscardGroupCall invokes method phone.discardGroupCall#7a777135 returning error if any.
See https://core.telegram.org/method/phone.discardGroupCall for reference.
func (*Client) PhoneEditGroupCallMember ¶ added in v0.13.0
func (c *Client) PhoneEditGroupCallMember(ctx context.Context, request *PhoneEditGroupCallMemberRequest) (UpdatesClass, error)
PhoneEditGroupCallMember invokes method phone.editGroupCallMember#63146ae4 returning error if any.
See https://core.telegram.org/method/phone.editGroupCallMember for reference.
func (*Client) PhoneGetCallConfig ¶
PhoneGetCallConfig invokes method phone.getCallConfig#55451fa9 returning error if any. Get phone call configuration to be passed to libtgvoip's shared config
See https://core.telegram.org/method/phone.getCallConfig for reference.
func (*Client) PhoneGetGroupCall ¶ added in v0.13.0
func (c *Client) PhoneGetGroupCall(ctx context.Context, call InputGroupCall) (*PhoneGroupCall, error)
PhoneGetGroupCall invokes method phone.getGroupCall#c7cb017 returning error if any.
See https://core.telegram.org/method/phone.getGroupCall for reference.
func (*Client) PhoneGetGroupParticipants ¶ added in v0.13.0
func (c *Client) PhoneGetGroupParticipants(ctx context.Context, request *PhoneGetGroupParticipantsRequest) (*PhoneGroupParticipants, error)
PhoneGetGroupParticipants invokes method phone.getGroupParticipants#c9f1d285 returning error if any.
See https://core.telegram.org/method/phone.getGroupParticipants for reference.
func (*Client) PhoneInviteToGroupCall ¶ added in v0.13.0
func (c *Client) PhoneInviteToGroupCall(ctx context.Context, request *PhoneInviteToGroupCallRequest) (UpdatesClass, error)
PhoneInviteToGroupCall invokes method phone.inviteToGroupCall#7b393160 returning error if any.
See https://core.telegram.org/method/phone.inviteToGroupCall for reference.
func (*Client) PhoneJoinGroupCall ¶ added in v0.13.0
func (c *Client) PhoneJoinGroupCall(ctx context.Context, request *PhoneJoinGroupCallRequest) (UpdatesClass, error)
PhoneJoinGroupCall invokes method phone.joinGroupCall#5f9c8e62 returning error if any.
See https://core.telegram.org/method/phone.joinGroupCall for reference.
func (*Client) PhoneLeaveGroupCall ¶ added in v0.13.0
func (c *Client) PhoneLeaveGroupCall(ctx context.Context, request *PhoneLeaveGroupCallRequest) (UpdatesClass, error)
PhoneLeaveGroupCall invokes method phone.leaveGroupCall#500377f9 returning error if any.
See https://core.telegram.org/method/phone.leaveGroupCall for reference.
func (*Client) PhoneReceivedCall ¶
PhoneReceivedCall invokes method phone.receivedCall#17d54f61 returning error if any. Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended.
Possible errors:
400 CALL_ALREADY_DECLINED: The call was already declined 400 CALL_PEER_INVALID: The provided call peer object is invalid
See https://core.telegram.org/method/phone.receivedCall for reference.
func (*Client) PhoneRequestCall ¶
func (c *Client) PhoneRequestCall(ctx context.Context, request *PhoneRequestCallRequest) (*PhonePhoneCall, error)
PhoneRequestCall invokes method phone.requestCall#42ff96ed returning error if any. Start a telegram phone call
Possible errors:
400 CALL_PROTOCOL_FLAGS_INVALID: Call protocol flags invalid 400 PARTICIPANT_VERSION_OUTDATED: The other participant does not use an up to date telegram client with support for calls 400 USER_ID_INVALID: The provided user ID is invalid 403 USER_IS_BLOCKED: You were blocked by this user 403 USER_PRIVACY_RESTRICTED: The user's privacy settings do not allow you to do this
See https://core.telegram.org/method/phone.requestCall for reference.
func (*Client) PhoneSaveCallDebug ¶
func (c *Client) PhoneSaveCallDebug(ctx context.Context, request *PhoneSaveCallDebugRequest) (bool, error)
PhoneSaveCallDebug invokes method phone.saveCallDebug#277add7e returning error if any. Send phone call debug data to server
Possible errors:
400 CALL_PEER_INVALID: The provided call peer object is invalid 400 DATA_JSON_INVALID: The provided JSON data is invalid
See https://core.telegram.org/method/phone.saveCallDebug for reference.
func (*Client) PhoneSendSignalingData ¶
func (c *Client) PhoneSendSignalingData(ctx context.Context, request *PhoneSendSignalingDataRequest) (bool, error)
PhoneSendSignalingData invokes method phone.sendSignalingData#ff7a9383 returning error if any. Send VoIP signaling data
See https://core.telegram.org/method/phone.sendSignalingData for reference. Can be used by bots.
func (*Client) PhoneSetCallRating ¶
func (c *Client) PhoneSetCallRating(ctx context.Context, request *PhoneSetCallRatingRequest) (UpdatesClass, error)
PhoneSetCallRating invokes method phone.setCallRating#59ead627 returning error if any. Rate a call
Possible errors:
400 CALL_PEER_INVALID: The provided call peer object is invalid
See https://core.telegram.org/method/phone.setCallRating for reference.
func (*Client) PhoneToggleGroupCallSettings ¶ added in v0.13.0
func (c *Client) PhoneToggleGroupCallSettings(ctx context.Context, request *PhoneToggleGroupCallSettingsRequest) (UpdatesClass, error)
PhoneToggleGroupCallSettings invokes method phone.toggleGroupCallSettings#74bbb43d returning error if any.
See https://core.telegram.org/method/phone.toggleGroupCallSettings for reference.
func (*Client) PhotosDeletePhotos ¶ added in v0.8.0
PhotosDeletePhotos invokes method photos.deletePhotos#87cf7f2f returning error if any. Deletes profile photos.
See https://core.telegram.org/method/photos.deletePhotos for reference.
func (*Client) PhotosGetUserPhotos ¶
func (c *Client) PhotosGetUserPhotos(ctx context.Context, request *PhotosGetUserPhotosRequest) (PhotosPhotosClass, error)
PhotosGetUserPhotos invokes method photos.getUserPhotos#91cd32a8 returning error if any. Returns the list of user photos.
Possible errors:
400 MAX_ID_INVALID: The provided max ID is invalid 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/photos.getUserPhotos for reference. Can be used by bots.
func (*Client) PhotosUpdateProfilePhoto ¶
func (c *Client) PhotosUpdateProfilePhoto(ctx context.Context, id InputPhotoClass) (*PhotosPhoto, error)
PhotosUpdateProfilePhoto invokes method photos.updateProfilePhoto#72d4742c returning error if any. Installs a previously uploaded photo as a profile photo.
Possible errors:
400 FILE_PARTS_INVALID: The number of file parts is invalid 400 IMAGE_PROCESS_FAILED: Failure while processing image 400 LOCATION_INVALID: The provided location is invalid 400 PHOTO_CROP_SIZE_SMALL: Photo is too small 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_ID_INVALID: Photo ID invalid
See https://core.telegram.org/method/photos.updateProfilePhoto for reference.
func (*Client) PhotosUploadProfilePhoto ¶
func (c *Client) PhotosUploadProfilePhoto(ctx context.Context, request *PhotosUploadProfilePhotoRequest) (*PhotosPhoto, error)
PhotosUploadProfilePhoto invokes method photos.uploadProfilePhoto#89f30f69 returning error if any. Updates current user profile photo.
Possible errors:
400 FILE_PARTS_INVALID: The number of file parts is invalid 400 IMAGE_PROCESS_FAILED: Failure while processing image 400 PHOTO_CROP_FILE_MISSING: Photo crop file missing 400 PHOTO_CROP_SIZE_SMALL: Photo is too small 400 PHOTO_EXT_INVALID: The extension of the photo is invalid 400 PHOTO_FILE_MISSING: Profile photo file missing 400 VIDEO_FILE_INVALID: The specified video file is invalid
See https://core.telegram.org/method/photos.uploadProfilePhoto for reference.
func (*Client) StatsGetBroadcastStats ¶
func (c *Client) StatsGetBroadcastStats(ctx context.Context, request *StatsGetBroadcastStatsRequest) (*StatsBroadcastStats, error)
StatsGetBroadcastStats invokes method stats.getBroadcastStats#ab42441a returning error if any. Get channel statistics¹
Links:
Possible errors:
400 BROADCAST_REQUIRED: This method can only be called on a channel, please use stats.getMegagroupStats for supergroups 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this
See https://core.telegram.org/method/stats.getBroadcastStats for reference.
func (*Client) StatsGetMegagroupStats ¶
func (c *Client) StatsGetMegagroupStats(ctx context.Context, request *StatsGetMegagroupStatsRequest) (*StatsMegagroupStats, error)
StatsGetMegagroupStats invokes method stats.getMegagroupStats#dcdf8607 returning error if any. Get supergroup statistics¹
Links:
See https://core.telegram.org/method/stats.getMegagroupStats for reference. Can be used by bots.
func (*Client) StatsGetMessagePublicForwards ¶
func (c *Client) StatsGetMessagePublicForwards(ctx context.Context, request *StatsGetMessagePublicForwardsRequest) (MessagesMessagesClass, error)
StatsGetMessagePublicForwards invokes method stats.getMessagePublicForwards#5630281b returning error if any. Obtains a list of messages, indicating to which other public channels was a channel message forwarded. Will return a list of messages¹ with peer_id equal to the public channel to which this message was forwarded.
Links:
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 MESSAGE_ID_INVALID: The provided message id is invalid
See https://core.telegram.org/method/stats.getMessagePublicForwards for reference. Can be used by bots.
func (*Client) StatsGetMessageStats ¶
func (c *Client) StatsGetMessageStats(ctx context.Context, request *StatsGetMessageStatsRequest) (*StatsMessageStats, error)
StatsGetMessageStats invokes method stats.getMessageStats#b6e0a3f5 returning error if any. Get message statistics¹
Links:
Possible errors:
400 CHAT_ADMIN_REQUIRED: You must be an admin in this chat to do this
See https://core.telegram.org/method/stats.getMessageStats for reference. Can be used by bots.
func (*Client) StatsLoadAsyncGraph ¶
func (c *Client) StatsLoadAsyncGraph(ctx context.Context, request *StatsLoadAsyncGraphRequest) (StatsGraphClass, error)
StatsLoadAsyncGraph invokes method stats.loadAsyncGraph#621d5fa0 returning error if any. Load channel statistics graph¹ asynchronously
Links:
Possible errors:
400 GRAPH_INVALID_RELOAD: Invalid graph token provided, please reload the stats and provide the updated token 400 GRAPH_OUTDATED_RELOAD: The graph is outdated, please get a new async token using stats.getBroadcastStats
See https://core.telegram.org/method/stats.loadAsyncGraph for reference.
func (*Client) StickersAddStickerToSet ¶
func (c *Client) StickersAddStickerToSet(ctx context.Context, request *StickersAddStickerToSetRequest) (*MessagesStickerSet, error)
StickersAddStickerToSet invokes method stickers.addStickerToSet#8653febe returning error if any. Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot.
Possible errors:
400 BOT_MISSING: This method can only be run by a bot 400 STICKERSET_INVALID: The provided sticker set is invalid
See https://core.telegram.org/method/stickers.addStickerToSet for reference. Can be used by bots.
func (*Client) StickersChangeStickerPosition ¶
func (c *Client) StickersChangeStickerPosition(ctx context.Context, request *StickersChangeStickerPositionRequest) (*MessagesStickerSet, error)
StickersChangeStickerPosition invokes method stickers.changeStickerPosition#ffb6d4ca returning error if any. Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot
Possible errors:
400 BOT_MISSING: This method can only be run by a bot 400 STICKER_INVALID: The provided sticker is invalid
See https://core.telegram.org/method/stickers.changeStickerPosition for reference. Can be used by bots.
func (*Client) StickersCreateStickerSet ¶
func (c *Client) StickersCreateStickerSet(ctx context.Context, request *StickersCreateStickerSetRequest) (*MessagesStickerSet, error)
StickersCreateStickerSet invokes method stickers.createStickerSet#f1036780 returning error if any. Create a stickerset, bots only.
Possible errors:
400 BOT_MISSING: This method can only be run by a bot 400 PACK_SHORT_NAME_INVALID: Short pack name invalid 400 PACK_SHORT_NAME_OCCUPIED: A stickerpack with this name already exists 400 PACK_TITLE_INVALID: The stickerpack title is invalid 400 PEER_ID_INVALID: The provided peer id is invalid 400 SHORTNAME_OCCUPY_FAILED: An internal error occurred 400 STICKERS_EMPTY: No sticker provided 400 STICKER_EMOJI_INVALID: Sticker emoji invalid 400 STICKER_FILE_INVALID: Sticker file invalid 400 STICKER_PNG_DIMENSIONS: Sticker png dimensions invalid 400 STICKER_PNG_NOPNG: One of the specified stickers is not a valid PNG file 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/stickers.createStickerSet for reference. Can be used by bots.
func (*Client) StickersRemoveStickerFromSet ¶
func (c *Client) StickersRemoveStickerFromSet(ctx context.Context, sticker InputDocumentClass) (*MessagesStickerSet, error)
StickersRemoveStickerFromSet invokes method stickers.removeStickerFromSet#f7760f51 returning error if any. Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot.
Possible errors:
400 BOT_MISSING: This method can only be run by a bot 400 STICKER_INVALID: The provided sticker is invalid
See https://core.telegram.org/method/stickers.removeStickerFromSet for reference. Can be used by bots.
func (*Client) StickersSetStickerSetThumb ¶
func (c *Client) StickersSetStickerSetThumb(ctx context.Context, request *StickersSetStickerSetThumbRequest) (*MessagesStickerSet, error)
StickersSetStickerSetThumb invokes method stickers.setStickerSetThumb#9a364e30 returning error if any. Set stickerset thumbnail
Possible errors:
400 STICKERSET_INVALID: The provided sticker set is invalid
See https://core.telegram.org/method/stickers.setStickerSetThumb for reference. Can be used by bots.
func (*Client) UpdatesGetChannelDifference ¶
func (c *Client) UpdatesGetChannelDifference(ctx context.Context, request *UpdatesGetChannelDifferenceRequest) (UpdatesChannelDifferenceClass, error)
UpdatesGetChannelDifference invokes method updates.getChannelDifference#3173d78 returning error if any. Returns the difference between the current state of updates of a certain channel and transmitted.
Possible errors:
400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 403 CHANNEL_PUBLIC_GROUP_NA: channel/supergroup not available 400 FROM_MESSAGE_BOT_DISABLED: Bots can't use fromMessage min constructors 400 MSG_ID_INVALID: Invalid message ID provided 400 PERSISTENT_TIMESTAMP_EMPTY: Persistent timestamp empty 400 PERSISTENT_TIMESTAMP_INVALID: Persistent timestamp invalid 400 PINNED_DIALOGS_TOO_MUCH: Too many pinned dialogs 400 RANGES_INVALID: Invalid range provided
See https://core.telegram.org/method/updates.getChannelDifference for reference. Can be used by bots.
func (*Client) UpdatesGetDifference ¶
func (c *Client) UpdatesGetDifference(ctx context.Context, request *UpdatesGetDifferenceRequest) (UpdatesDifferenceClass, error)
UpdatesGetDifference invokes method updates.getDifference#25939651 returning error if any. Get new updates¹.
Links:
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 CDN_METHOD_INVALID: You can't call this method in a CDN DC 400 DATE_EMPTY: Date empty 400 PERSISTENT_TIMESTAMP_EMPTY: Persistent timestamp empty 400 PERSISTENT_TIMESTAMP_INVALID: Persistent timestamp invalid
See https://core.telegram.org/method/updates.getDifference for reference. Can be used by bots.
func (*Client) UpdatesGetState ¶
func (c *Client) UpdatesGetState(ctx context.Context) (*UpdatesState, error)
UpdatesGetState invokes method updates.getState#edd4882a returning error if any. Returns a current state of updates.
See https://core.telegram.org/method/updates.getState for reference. Can be used by bots.
func (*Client) UploadGetCdnFile ¶
func (c *Client) UploadGetCdnFile(ctx context.Context, request *UploadGetCdnFileRequest) (UploadCdnFileClass, error)
UploadGetCdnFile invokes method upload.getCdnFile#2000bcc3 returning error if any. Download a CDN¹ file.
Links:
See https://core.telegram.org/method/upload.getCdnFile for reference.
func (*Client) UploadGetCdnFileHashes ¶ added in v0.8.0
func (c *Client) UploadGetCdnFileHashes(ctx context.Context, request *UploadGetCdnFileHashesRequest) ([]FileHash, error)
UploadGetCdnFileHashes invokes method upload.getCdnFileHashes#4da54231 returning error if any. Get SHA256 hashes for verifying downloaded CDN¹ files
Links:
Possible errors:
400 CDN_METHOD_INVALID: You can't call this method in a CDN DC 400 RSA_DECRYPT_FAILED: Internal RSA decryption failed
See https://core.telegram.org/method/upload.getCdnFileHashes for reference. Can be used by bots.
func (*Client) UploadGetFile ¶
func (c *Client) UploadGetFile(ctx context.Context, request *UploadGetFileRequest) (UploadFileClass, error)
UploadGetFile invokes method upload.getFile#b15a9afc returning error if any. Returns content of a whole file or its part.
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 CHANNEL_INVALID: The provided channel is invalid 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 406 FILEREF_UPGRADE_NEEDED: The client has to be updated in order to support file references 400 FILE_ID_INVALID: The provided file id is invalid 400 FILE_REFERENCE_*: The file reference expired, it must be refreshed 400 FILE_REFERENCE_EXPIRED: File reference expired, it must be refetched as described in https://core.telegram.org/api/file_reference 400 LIMIT_INVALID: The provided limit is invalid 400 LOCATION_INVALID: The provided location is invalid 400 MSG_ID_INVALID: Invalid message ID provided 400 OFFSET_INVALID: The provided offset is invalid 400 PEER_ID_INVALID: The provided peer id is invalid
See https://core.telegram.org/method/upload.getFile for reference. Can be used by bots.
func (*Client) UploadGetFileHashes ¶ added in v0.8.0
func (c *Client) UploadGetFileHashes(ctx context.Context, request *UploadGetFileHashesRequest) ([]FileHash, error)
UploadGetFileHashes invokes method upload.getFileHashes#c7025931 returning error if any. Get SHA256 hashes for verifying downloaded files
Possible errors:
400 LOCATION_INVALID: The provided location is invalid
See https://core.telegram.org/method/upload.getFileHashes for reference. Can be used by bots.
func (*Client) UploadGetWebFile ¶
func (c *Client) UploadGetWebFile(ctx context.Context, request *UploadGetWebFileRequest) (*UploadWebFile, error)
UploadGetWebFile invokes method upload.getWebFile#24e6818d returning error if any.
See https://core.telegram.org/method/upload.getWebFile for reference.
func (*Client) UploadReuploadCdnFile ¶ added in v0.8.0
func (c *Client) UploadReuploadCdnFile(ctx context.Context, request *UploadReuploadCdnFileRequest) ([]FileHash, error)
UploadReuploadCdnFile invokes method upload.reuploadCdnFile#9b2754a8 returning error if any. Request a reupload of a certain file to a CDN DC¹.
Links:
Possible errors:
400 RSA_DECRYPT_FAILED: Internal RSA decryption failed
See https://core.telegram.org/method/upload.reuploadCdnFile for reference. Can be used by bots.
func (*Client) UploadSaveBigFilePart ¶
func (c *Client) UploadSaveBigFilePart(ctx context.Context, request *UploadSaveBigFilePartRequest) (bool, error)
UploadSaveBigFilePart invokes method upload.saveBigFilePart#de7b673d returning error if any. Saves a part of a large file (over 10Mb in size) to be later passed to one of the methods.
Possible errors:
400 FILE_PARTS_INVALID: The number of file parts is invalid 400 FILE_PART_EMPTY: The provided file part is empty 400 FILE_PART_INVALID: The file part number is invalid 400 FILE_PART_SIZE_CHANGED: Provided file part size has changed 400 FILE_PART_SIZE_INVALID: The provided file part size is invalid 400 FILE_PART_TOO_BIG: The uploaded file part is too big
See https://core.telegram.org/method/upload.saveBigFilePart for reference. Can be used by bots.
func (*Client) UploadSaveFilePart ¶
func (c *Client) UploadSaveFilePart(ctx context.Context, request *UploadSaveFilePartRequest) (bool, error)
UploadSaveFilePart invokes method upload.saveFilePart#b304a621 returning error if any. Saves a part of file for futher sending to one of the methods.
Possible errors:
400 FILE_PART_EMPTY: The provided file part is empty 400 FILE_PART_INVALID: The file part number is invalid
See https://core.telegram.org/method/upload.saveFilePart for reference. Can be used by bots.
func (*Client) UsersGetFullUser ¶
UsersGetFullUser invokes method users.getFullUser#ca30a5b1 returning error if any. Returns extended user info by ID.
Possible errors:
400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 MSG_ID_INVALID: Invalid message ID provided 400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/users.getFullUser for reference. Can be used by bots.
func (*Client) UsersGetUsers ¶ added in v0.8.0
UsersGetUsers invokes method users.getUsers#d91a548 returning error if any. Returns basic user info according to their identifiers.
Possible errors:
401 AUTH_KEY_PERM_EMPTY: The temporary auth key must be binded to the permanent auth key to use these methods. 400 CHANNEL_PRIVATE: You haven't joined this channel/supergroup 400 CONNECTION_NOT_INITED: Connection not initialized 400 INPUT_LAYER_INVALID: The provided layer is invalid 400 MSG_ID_INVALID: Invalid message ID provided
See https://core.telegram.org/method/users.getUsers for reference. Can be used by bots.
func (*Client) UsersSetSecureValueErrors ¶
func (c *Client) UsersSetSecureValueErrors(ctx context.Context, request *UsersSetSecureValueErrorsRequest) (bool, error)
UsersSetSecureValueErrors invokes method users.setSecureValueErrors#90c894b5 returning error if any. Notify the user that the sent passport¹ data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change). Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues.
Links:
Possible errors:
400 USER_ID_INVALID: The provided user ID is invalid
See https://core.telegram.org/method/users.setSecureValueErrors for reference. Can be used by bots.
type CodeSettings ¶
type CodeSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to allow phone verification via phone calls¹.
//
// Links:
// 1) https://core.telegram.org/api/auth
AllowFlashcall bool
// Pass true if the phone number is used on the current device. Ignored if allow_flashcall is not set.
CurrentNumber bool
// If a token that will be included in eventually sent SMSs is required: required in newer versions of android, to use the android SMS receiver APIs¹
//
// Links:
// 1) https://developers.google.com/identity/sms-retriever/overview
AllowAppHash bool
}
CodeSettings represents TL type `codeSettings#debebe83`. Settings used by telegram servers for sending the confirm code. Example implementations: telegram for android¹, tdlib².
Links:
- https://github.com/DrKLO/Telegram/blob/master/TMessagesProj/src/main/java/org/telegram/ui/LoginActivity.java
- https://github.com/tdlib/td/tree/master/td/telegram/SendCodeHelper.cpp
See https://core.telegram.org/constructor/codeSettings for reference.
func (*CodeSettings) Decode ¶
func (c *CodeSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*CodeSettings) Encode ¶
func (c *CodeSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*CodeSettings) SetAllowAppHash ¶
func (c *CodeSettings) SetAllowAppHash(value bool)
SetAllowAppHash sets value of AllowAppHash conditional field.
func (*CodeSettings) SetAllowFlashcall ¶
func (c *CodeSettings) SetAllowFlashcall(value bool)
SetAllowFlashcall sets value of AllowFlashcall conditional field.
func (*CodeSettings) SetCurrentNumber ¶
func (c *CodeSettings) SetCurrentNumber(value bool)
SetCurrentNumber sets value of CurrentNumber conditional field.
func (*CodeSettings) String ¶ added in v0.12.0
func (c *CodeSettings) String() string
String implements fmt.Stringer.
type Config ¶
type Config struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether phone calls can be used
PhonecallsEnabled bool
// Whether the client should use P2P by default for phone calls with contacts
DefaultP2PContacts bool
// Whether the client should preload featured stickers
PreloadFeaturedStickers bool
// Whether the client should ignore phone entities¹
//
// Links:
// 1) https://core.telegram.org/api/entities
IgnorePhoneEntities bool
// Whether incoming private messages can be deleted for both participants
RevokePmInbox bool
// Indicates that telegram is probably censored by governments/ISPs in the current region
BlockedMode bool
// Whether pfs¹ was used
//
// Links:
// 1) https://core.telegram.org/api/pfs
PFSEnabled bool
// Current date at the server
Date int
// Expiration date of this config: when it expires it'll have to be refetched using help.getConfig¹
//
// Links:
// 1) https://core.telegram.org/method/help.getConfig
Expires int
// Whether we're connected to the test DCs
TestMode bool
// ID of the DC that returned the reply
ThisDC int
// DC IP list
DCOptions []DcOption
// Domain name for fetching encrypted DC list from DNS TXT record
DCTxtDomainName string
// Maximum member count for normal groups¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ChatSizeMax int
// Maximum member count for supergroups¹
//
// Links:
// 1) https://core.telegram.org/api/channel
MegagroupSizeMax int
// Maximum number of messages that can be forwarded at once using messages.forwardMessages¹.
//
// Links:
// 1) https://core.telegram.org/method/messages.forwardMessages
ForwardedCountMax int
// The client should update its online status¹ every N milliseconds
//
// Links:
// 1) https://core.telegram.org/method/account.updateStatus
OnlineUpdatePeriodMs int
// Delay before offline status needs to be sent to the server
OfflineBlurTimeoutMs int
// Time without any user activity after which it should be treated offline
OfflineIdleTimeoutMs int
// If we are offline, but were online from some other client in last online_cloud_timeout_ms milliseconds after we had gone offline, then delay offline notification for notify_cloud_delay_ms milliseconds.
OnlineCloudTimeoutMs int
// If we are offline, but online from some other client then delay sending the offline notification for notify_cloud_delay_ms milliseconds.
NotifyCloudDelayMs int
// If some other client is online, then delay notification for notification_default_delay_ms milliseconds
NotifyDefaultDelayMs int
// Not for client use
PushChatPeriodMs int
// Not for client use
PushChatLimit int
// Maximum count of saved gifs
SavedGifsLimit int
// Only messages with age smaller than the one specified can be edited
EditTimeLimit int
// Only channel/supergroup messages with age smaller than the specified can be deleted
RevokeTimeLimit int
// Only private messages with age smaller than the specified can be deleted
RevokePmTimeLimit int
// Exponential decay rate for computing top peer rating¹
//
// Links:
// 1) https://core.telegram.org/api/top-rating
RatingEDecay int
// Maximum number of recent stickers
StickersRecentLimit int
// Maximum number of faved stickers
StickersFavedLimit int
// Indicates that round videos (video notes) and voice messages sent in channels and older than the specified period must be marked as read
ChannelsReadMediaPeriod int
// Temporary passport¹ sessions
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetTmpSessions and GetTmpSessions helpers.
TmpSessions int
// Maximum count of pinned dialogs
PinnedDialogsCountMax int
// Maximum count of dialogs per folder
PinnedInfolderCountMax int
// Maximum allowed outgoing ring time in VoIP calls: if the user we're calling doesn't reply within the specified time (in milliseconds), we should hang up the call
CallReceiveTimeoutMs int
// Maximum allowed incoming ring time in VoIP calls: if the current user doesn't reply within the specified time (in milliseconds), the call will be automatically refused
CallRingTimeoutMs int
// VoIP connection timeout: if the instance of libtgvoip on the other side of the call doesn't connect to our instance of libtgvoip within the specified time (in milliseconds), the call must be aborted
CallConnectTimeoutMs int
// If during a VoIP call a packet isn't received for the specified period of time, the call must be aborted
CallPacketTimeoutMs int
// The domain to use to parse in-app links.For example t.me indicates that t.me/username links should parsed to @username, t.me/addsticker/name should be parsed to the appropriate stickerset and so on...
MeURLPrefix string
// URL to use to auto-update the current app
//
// Use SetAutoupdateURLPrefix and GetAutoupdateURLPrefix helpers.
AutoupdateURLPrefix string
// Username of the bot to use to search for GIFs
//
// Use SetGifSearchUsername and GetGifSearchUsername helpers.
GifSearchUsername string
// Username of the bot to use to search for venues
//
// Use SetVenueSearchUsername and GetVenueSearchUsername helpers.
VenueSearchUsername string
// Username of the bot to use for image search
//
// Use SetImgSearchUsername and GetImgSearchUsername helpers.
ImgSearchUsername string
// ID of the map provider to use for venues
//
// Use SetStaticMapsProvider and GetStaticMapsProvider helpers.
StaticMapsProvider string
// Maximum length of caption (length in utf8 codepoints)
CaptionLengthMax int
// Maximum length of messages (length in utf8 codepoints)
MessageLengthMax int
// DC ID to use to download webfiles¹
//
// Links:
// 1) https://core.telegram.org/api/files
WebfileDCID int
// Suggested language code
//
// Use SetSuggestedLangCode and GetSuggestedLangCode helpers.
SuggestedLangCode string
// Language pack version
//
// Use SetLangPackVersion and GetLangPackVersion helpers.
LangPackVersion int
// Basic language pack version
//
// Use SetBaseLangPackVersion and GetBaseLangPackVersion helpers.
BaseLangPackVersion int
}
Config represents TL type `config#330b4067`. Current configuration
See https://core.telegram.org/constructor/config for reference.
func (*Config) GetAutoupdateURLPrefix ¶
GetAutoupdateURLPrefix returns value of AutoupdateURLPrefix conditional field and boolean which is true if field was set.
func (*Config) GetBaseLangPackVersion ¶
GetBaseLangPackVersion returns value of BaseLangPackVersion conditional field and boolean which is true if field was set.
func (*Config) GetGifSearchUsername ¶
GetGifSearchUsername returns value of GifSearchUsername conditional field and boolean which is true if field was set.
func (*Config) GetImgSearchUsername ¶
GetImgSearchUsername returns value of ImgSearchUsername conditional field and boolean which is true if field was set.
func (*Config) GetLangPackVersion ¶
GetLangPackVersion returns value of LangPackVersion conditional field and boolean which is true if field was set.
func (*Config) GetStaticMapsProvider ¶
GetStaticMapsProvider returns value of StaticMapsProvider conditional field and boolean which is true if field was set.
func (*Config) GetSuggestedLangCode ¶
GetSuggestedLangCode returns value of SuggestedLangCode conditional field and boolean which is true if field was set.
func (*Config) GetTmpSessions ¶
GetTmpSessions returns value of TmpSessions conditional field and boolean which is true if field was set.
func (*Config) GetVenueSearchUsername ¶
GetVenueSearchUsername returns value of VenueSearchUsername conditional field and boolean which is true if field was set.
func (*Config) SetAutoupdateURLPrefix ¶
SetAutoupdateURLPrefix sets value of AutoupdateURLPrefix conditional field.
func (*Config) SetBaseLangPackVersion ¶
SetBaseLangPackVersion sets value of BaseLangPackVersion conditional field.
func (*Config) SetBlockedMode ¶
SetBlockedMode sets value of BlockedMode conditional field.
func (*Config) SetDefaultP2PContacts ¶
SetDefaultP2PContacts sets value of DefaultP2PContacts conditional field.
func (*Config) SetGifSearchUsername ¶
SetGifSearchUsername sets value of GifSearchUsername conditional field.
func (*Config) SetIgnorePhoneEntities ¶
SetIgnorePhoneEntities sets value of IgnorePhoneEntities conditional field.
func (*Config) SetImgSearchUsername ¶
SetImgSearchUsername sets value of ImgSearchUsername conditional field.
func (*Config) SetLangPackVersion ¶
SetLangPackVersion sets value of LangPackVersion conditional field.
func (*Config) SetPFSEnabled ¶
SetPFSEnabled sets value of PFSEnabled conditional field.
func (*Config) SetPhonecallsEnabled ¶
SetPhonecallsEnabled sets value of PhonecallsEnabled conditional field.
func (*Config) SetPreloadFeaturedStickers ¶
SetPreloadFeaturedStickers sets value of PreloadFeaturedStickers conditional field.
func (*Config) SetRevokePmInbox ¶
SetRevokePmInbox sets value of RevokePmInbox conditional field.
func (*Config) SetStaticMapsProvider ¶
SetStaticMapsProvider sets value of StaticMapsProvider conditional field.
func (*Config) SetSuggestedLangCode ¶
SetSuggestedLangCode sets value of SuggestedLangCode conditional field.
func (*Config) SetTmpSessions ¶
SetTmpSessions sets value of TmpSessions conditional field.
func (*Config) SetVenueSearchUsername ¶
SetVenueSearchUsername sets value of VenueSearchUsername conditional field.
type ConfigHandler ¶ added in v0.9.0
type ConfigHandler func(ctx UpdateContext, update *UpdateConfig) error
ConfigHandler is a Config event handler.
type Contact ¶
type Contact struct {
// User identifier
UserID int
// Current user is in the user's contact list
Mutual bool
}
Contact represents TL type `contact#f911c994`. A contact of the current user that is registered in the system.
See https://core.telegram.org/constructor/contact for reference.
type ContactStatus ¶
type ContactStatus struct {
// User identifier
UserID int
// Online status
Status UserStatusClass
}
ContactStatus represents TL type `contactStatus#d3680c61`. Contact status: online / offline.
See https://core.telegram.org/constructor/contactStatus for reference.
func (*ContactStatus) Decode ¶
func (c *ContactStatus) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactStatus) Encode ¶
func (c *ContactStatus) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactStatus) String ¶ added in v0.12.0
func (c *ContactStatus) String() string
String implements fmt.Stringer.
type ContactStatusVector ¶ added in v0.8.0
type ContactStatusVector struct {
// Elements of Vector<ContactStatus>
Elems []ContactStatus
}
ContactStatusVector is a box for Vector<ContactStatus>
func (*ContactStatusVector) Decode ¶ added in v0.8.0
func (vec *ContactStatusVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactStatusVector) Encode ¶ added in v0.8.0
func (vec *ContactStatusVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactStatusVector) String ¶ added in v0.12.0
func (vec *ContactStatusVector) String() string
String implements fmt.Stringer.
type ContactsAcceptContactRequest ¶
type ContactsAcceptContactRequest struct {
// The user to add as contact
ID InputUserClass
}
ContactsAcceptContactRequest represents TL type `contacts.acceptContact#f831a20f`. If the peer settings¹ of a new user allow us to add him as contact, add that user as contact
Links:
See https://core.telegram.org/method/contacts.acceptContact for reference.
func (*ContactsAcceptContactRequest) Decode ¶
func (a *ContactsAcceptContactRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsAcceptContactRequest) Encode ¶
func (a *ContactsAcceptContactRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsAcceptContactRequest) String ¶ added in v0.12.0
func (a *ContactsAcceptContactRequest) String() string
String implements fmt.Stringer.
type ContactsAddContactRequest ¶
type ContactsAddContactRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Allow the other user to see our phone number?
AddPhonePrivacyException bool
// Telegram ID of the other user
ID InputUserClass
// First name
FirstName string
// Last name
LastName string
// User's phone number
Phone string
}
ContactsAddContactRequest represents TL type `contacts.addContact#e8f463d0`. Add an existing telegram user as contact. Use contacts.importContacts¹ to add contacts by phone number, without knowing their Telegram ID.
Links:
See https://core.telegram.org/method/contacts.addContact for reference.
func (*ContactsAddContactRequest) Decode ¶
func (a *ContactsAddContactRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsAddContactRequest) Encode ¶
func (a *ContactsAddContactRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsAddContactRequest) SetAddPhonePrivacyException ¶
func (a *ContactsAddContactRequest) SetAddPhonePrivacyException(value bool)
SetAddPhonePrivacyException sets value of AddPhonePrivacyException conditional field.
func (*ContactsAddContactRequest) String ¶ added in v0.12.0
func (a *ContactsAddContactRequest) String() string
String implements fmt.Stringer.
type ContactsBlockFromRepliesRequest ¶
type ContactsBlockFromRepliesRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to delete the specified message as well
DeleteMessage bool
// Whether to delete all @replies messages from this user as well
DeleteHistory bool
// Whether to also report this user for spam
ReportSpam bool
// ID of the message in the @replies¹ chat
//
// Links:
// 1) https://core.telegram.org/api/threads#replies
MsgID int
}
ContactsBlockFromRepliesRequest represents TL type `contacts.blockFromReplies#29a8962c`. Stop getting notifications about thread replies¹ of a certain user in @replies
Links:
See https://core.telegram.org/method/contacts.blockFromReplies for reference.
func (*ContactsBlockFromRepliesRequest) Decode ¶
func (b *ContactsBlockFromRepliesRequest) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsBlockFromRepliesRequest) Encode ¶
func (b *ContactsBlockFromRepliesRequest) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsBlockFromRepliesRequest) SetDeleteHistory ¶
func (b *ContactsBlockFromRepliesRequest) SetDeleteHistory(value bool)
SetDeleteHistory sets value of DeleteHistory conditional field.
func (*ContactsBlockFromRepliesRequest) SetDeleteMessage ¶
func (b *ContactsBlockFromRepliesRequest) SetDeleteMessage(value bool)
SetDeleteMessage sets value of DeleteMessage conditional field.
func (*ContactsBlockFromRepliesRequest) SetReportSpam ¶
func (b *ContactsBlockFromRepliesRequest) SetReportSpam(value bool)
SetReportSpam sets value of ReportSpam conditional field.
func (*ContactsBlockFromRepliesRequest) String ¶ added in v0.12.0
func (b *ContactsBlockFromRepliesRequest) String() string
String implements fmt.Stringer.
type ContactsBlockRequest ¶
type ContactsBlockRequest struct {
// User ID
ID InputPeerClass
}
ContactsBlockRequest represents TL type `contacts.block#68cc1411`. Adds the user to the blacklist.
See https://core.telegram.org/method/contacts.block for reference.
func (*ContactsBlockRequest) Decode ¶
func (b *ContactsBlockRequest) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsBlockRequest) Encode ¶
func (b *ContactsBlockRequest) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsBlockRequest) String ¶ added in v0.12.0
func (b *ContactsBlockRequest) String() string
String implements fmt.Stringer.
type ContactsBlocked ¶
type ContactsBlocked struct {
// List of blocked users
Blocked []PeerBlocked
// Blocked chats
Chats []ChatClass
// List of users
Users []UserClass
}
ContactsBlocked represents TL type `contacts.blocked#ade1591`. Full list of blocked users.
See https://core.telegram.org/constructor/contacts.blocked for reference.
func (*ContactsBlocked) Decode ¶
func (b *ContactsBlocked) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsBlocked) Encode ¶
func (b *ContactsBlocked) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsBlocked) String ¶ added in v0.12.0
func (b *ContactsBlocked) String() string
String implements fmt.Stringer.
type ContactsBlockedBox ¶
type ContactsBlockedBox struct {
Blocked ContactsBlockedClass
}
ContactsBlocked boxes the ContactsBlockedClass providing a helper.
type ContactsBlockedClass ¶
type ContactsBlockedClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ContactsBlockedClass represents contacts.Blocked generic type.
See https://core.telegram.org/type/contacts.Blocked for reference.
Example:
g, err := DecodeContactsBlocked(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ContactsBlocked: // contacts.blocked#ade1591
case *ContactsBlockedSlice: // contacts.blockedSlice#e1664194
default: panic(v)
}
func DecodeContactsBlocked ¶
func DecodeContactsBlocked(buf *bin.Buffer) (ContactsBlockedClass, error)
DecodeContactsBlocked implements binary de-serialization for ContactsBlockedClass.
type ContactsBlockedSlice ¶
type ContactsBlockedSlice struct {
// Total number of elements in the list
Count int
// List of blocked users
Blocked []PeerBlocked
// Blocked chats
Chats []ChatClass
// List of users
Users []UserClass
}
ContactsBlockedSlice represents TL type `contacts.blockedSlice#e1664194`. Incomplete list of blocked users.
See https://core.telegram.org/constructor/contacts.blockedSlice for reference.
func (*ContactsBlockedSlice) Decode ¶
func (b *ContactsBlockedSlice) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsBlockedSlice) Encode ¶
func (b *ContactsBlockedSlice) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsBlockedSlice) String ¶ added in v0.12.0
func (b *ContactsBlockedSlice) String() string
String implements fmt.Stringer.
type ContactsContacts ¶
type ContactsContacts struct {
// Contact list
Contacts []Contact
// Number of contacts that were saved successfully
SavedCount int
// User list
Users []UserClass
}
ContactsContacts represents TL type `contacts.contacts#eae87e42`. The current user's contact list and info on users.
See https://core.telegram.org/constructor/contacts.contacts for reference.
func (*ContactsContacts) Decode ¶
func (c *ContactsContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsContacts) Encode ¶
func (c *ContactsContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsContacts) String ¶ added in v0.12.0
func (c *ContactsContacts) String() string
String implements fmt.Stringer.
type ContactsContactsBox ¶
type ContactsContactsBox struct {
Contacts ContactsContactsClass
}
ContactsContacts boxes the ContactsContactsClass providing a helper.
type ContactsContactsClass ¶
type ContactsContactsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ContactsContactsClass represents contacts.Contacts generic type.
See https://core.telegram.org/type/contacts.Contacts for reference.
Example:
g, err := DecodeContactsContacts(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ContactsContactsNotModified: // contacts.contactsNotModified#b74ba9d2
case *ContactsContacts: // contacts.contacts#eae87e42
default: panic(v)
}
func DecodeContactsContacts ¶
func DecodeContactsContacts(buf *bin.Buffer) (ContactsContactsClass, error)
DecodeContactsContacts implements binary de-serialization for ContactsContactsClass.
type ContactsContactsNotModified ¶
type ContactsContactsNotModified struct {
}
ContactsContactsNotModified represents TL type `contacts.contactsNotModified#b74ba9d2`. Contact list on the server is the same as the list on the client.
See https://core.telegram.org/constructor/contacts.contactsNotModified for reference.
func (*ContactsContactsNotModified) Decode ¶
func (c *ContactsContactsNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsContactsNotModified) Encode ¶
func (c *ContactsContactsNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsContactsNotModified) String ¶ added in v0.12.0
func (c *ContactsContactsNotModified) String() string
String implements fmt.Stringer.
type ContactsDeleteByPhonesRequest ¶
type ContactsDeleteByPhonesRequest struct {
// Phone numbers
Phones []string
}
ContactsDeleteByPhonesRequest represents TL type `contacts.deleteByPhones#1013fd9e`. Delete contacts by phone number
See https://core.telegram.org/method/contacts.deleteByPhones for reference.
func (*ContactsDeleteByPhonesRequest) Decode ¶
func (d *ContactsDeleteByPhonesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsDeleteByPhonesRequest) Encode ¶
func (d *ContactsDeleteByPhonesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsDeleteByPhonesRequest) String ¶ added in v0.12.0
func (d *ContactsDeleteByPhonesRequest) String() string
String implements fmt.Stringer.
type ContactsDeleteContactsRequest ¶
type ContactsDeleteContactsRequest struct {
// User ID list
ID []InputUserClass
}
ContactsDeleteContactsRequest represents TL type `contacts.deleteContacts#96a0e00`. Deletes several contacts from the list.
See https://core.telegram.org/method/contacts.deleteContacts for reference.
func (*ContactsDeleteContactsRequest) Decode ¶
func (d *ContactsDeleteContactsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsDeleteContactsRequest) Encode ¶
func (d *ContactsDeleteContactsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsDeleteContactsRequest) String ¶ added in v0.12.0
func (d *ContactsDeleteContactsRequest) String() string
String implements fmt.Stringer.
type ContactsFound ¶
type ContactsFound struct {
// Personalized results
MyResults []PeerClass
// List of found user identifiers
Results []PeerClass
// Found chats
Chats []ChatClass
// List of users
Users []UserClass
}
ContactsFound represents TL type `contacts.found#b3134d9d`. Users found by name substring and auxiliary data.
See https://core.telegram.org/constructor/contacts.found for reference.
func (*ContactsFound) Decode ¶
func (f *ContactsFound) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsFound) Encode ¶
func (f *ContactsFound) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsFound) String ¶ added in v0.12.0
func (f *ContactsFound) String() string
String implements fmt.Stringer.
type ContactsGetBlockedRequest ¶
type ContactsGetBlockedRequest struct {
// The number of list elements to be skipped
Offset int
// The number of list elements to be returned
Limit int
}
ContactsGetBlockedRequest represents TL type `contacts.getBlocked#f57c350f`. Returns the list of blocked users.
See https://core.telegram.org/method/contacts.getBlocked for reference.
func (*ContactsGetBlockedRequest) Decode ¶
func (g *ContactsGetBlockedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetBlockedRequest) Encode ¶
func (g *ContactsGetBlockedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetBlockedRequest) String ¶ added in v0.12.0
func (g *ContactsGetBlockedRequest) String() string
String implements fmt.Stringer.
type ContactsGetContactIDsRequest ¶
type ContactsGetContactIDsRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
ContactsGetContactIDsRequest represents TL type `contacts.getContactIDs#2caa4a42`. Get contact by telegram IDs
See https://core.telegram.org/method/contacts.getContactIDs for reference.
func (*ContactsGetContactIDsRequest) Decode ¶
func (g *ContactsGetContactIDsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetContactIDsRequest) Encode ¶
func (g *ContactsGetContactIDsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetContactIDsRequest) String ¶ added in v0.12.0
func (g *ContactsGetContactIDsRequest) String() string
String implements fmt.Stringer.
type ContactsGetContactsRequest ¶
type ContactsGetContactsRequest struct {
// If there already is a full contact list on the client, a hash¹ of a the list of contact IDs in ascending order may be passed in this parameter. If the contact set was not changed, (contacts.contactsNotModified)² will be returned.
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
// 2) https://core.telegram.org/constructor/contacts.contactsNotModified
Hash int
}
ContactsGetContactsRequest represents TL type `contacts.getContacts#c023849f`. Returns the current user's contact list.
See https://core.telegram.org/method/contacts.getContacts for reference.
func (*ContactsGetContactsRequest) Decode ¶
func (g *ContactsGetContactsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetContactsRequest) Encode ¶
func (g *ContactsGetContactsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetContactsRequest) String ¶ added in v0.12.0
func (g *ContactsGetContactsRequest) String() string
String implements fmt.Stringer.
type ContactsGetLocatedRequest ¶
type ContactsGetLocatedRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// While the geolocation of the current user is public, clients should update it in the background every half-an-hour or so, while setting this flag. Do this only if the new location is more than 1 KM away from the previous one, or if the previous location is unknown.
Background bool
// Geolocation
GeoPoint InputGeoPointClass
// If set, the geolocation of the current user will be public for the specified number of seconds; pass 0x7fffffff to disable expiry, 0 to make the current geolocation private; if the flag isn't set, no changes will be applied.
//
// Use SetSelfExpires and GetSelfExpires helpers.
SelfExpires int
}
ContactsGetLocatedRequest represents TL type `contacts.getLocated#d348bc44`. Get contacts near you
See https://core.telegram.org/method/contacts.getLocated for reference.
func (*ContactsGetLocatedRequest) Decode ¶
func (g *ContactsGetLocatedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetLocatedRequest) Encode ¶
func (g *ContactsGetLocatedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetLocatedRequest) GetSelfExpires ¶
func (g *ContactsGetLocatedRequest) GetSelfExpires() (value int, ok bool)
GetSelfExpires returns value of SelfExpires conditional field and boolean which is true if field was set.
func (*ContactsGetLocatedRequest) SetBackground ¶
func (g *ContactsGetLocatedRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*ContactsGetLocatedRequest) SetSelfExpires ¶
func (g *ContactsGetLocatedRequest) SetSelfExpires(value int)
SetSelfExpires sets value of SelfExpires conditional field.
func (*ContactsGetLocatedRequest) String ¶ added in v0.12.0
func (g *ContactsGetLocatedRequest) String() string
String implements fmt.Stringer.
type ContactsGetSavedRequest ¶
type ContactsGetSavedRequest struct {
}
ContactsGetSavedRequest represents TL type `contacts.getSaved#82f1e39f`. Get all contacts
See https://core.telegram.org/method/contacts.getSaved for reference.
func (*ContactsGetSavedRequest) Decode ¶
func (g *ContactsGetSavedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetSavedRequest) Encode ¶
func (g *ContactsGetSavedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetSavedRequest) String ¶ added in v0.12.0
func (g *ContactsGetSavedRequest) String() string
String implements fmt.Stringer.
type ContactsGetStatusesRequest ¶
type ContactsGetStatusesRequest struct {
}
ContactsGetStatusesRequest represents TL type `contacts.getStatuses#c4a353ee`. Returns the list of contact statuses.
See https://core.telegram.org/method/contacts.getStatuses for reference.
func (*ContactsGetStatusesRequest) Decode ¶
func (g *ContactsGetStatusesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetStatusesRequest) Encode ¶
func (g *ContactsGetStatusesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetStatusesRequest) String ¶ added in v0.12.0
func (g *ContactsGetStatusesRequest) String() string
String implements fmt.Stringer.
type ContactsGetTopPeersRequest ¶
type ContactsGetTopPeersRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Users we've chatted most frequently with
Correspondents bool
// Most used bots
BotsPm bool
// Most used inline bots
BotsInline bool
// Most frequently called users
PhoneCalls bool
// Users to which the users often forwards messages to
ForwardUsers bool
// Chats to which the users often forwards messages to
ForwardChats bool
// Often-opened groups and supergroups
Groups bool
// Most frequently visited channels
Channels bool
// Offset for pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Offset int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
ContactsGetTopPeersRequest represents TL type `contacts.getTopPeers#d4982db5`. Get most used peers
See https://core.telegram.org/method/contacts.getTopPeers for reference.
func (*ContactsGetTopPeersRequest) Decode ¶
func (g *ContactsGetTopPeersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsGetTopPeersRequest) Encode ¶
func (g *ContactsGetTopPeersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsGetTopPeersRequest) SetBotsInline ¶
func (g *ContactsGetTopPeersRequest) SetBotsInline(value bool)
SetBotsInline sets value of BotsInline conditional field.
func (*ContactsGetTopPeersRequest) SetBotsPm ¶
func (g *ContactsGetTopPeersRequest) SetBotsPm(value bool)
SetBotsPm sets value of BotsPm conditional field.
func (*ContactsGetTopPeersRequest) SetChannels ¶
func (g *ContactsGetTopPeersRequest) SetChannels(value bool)
SetChannels sets value of Channels conditional field.
func (*ContactsGetTopPeersRequest) SetCorrespondents ¶
func (g *ContactsGetTopPeersRequest) SetCorrespondents(value bool)
SetCorrespondents sets value of Correspondents conditional field.
func (*ContactsGetTopPeersRequest) SetForwardChats ¶
func (g *ContactsGetTopPeersRequest) SetForwardChats(value bool)
SetForwardChats sets value of ForwardChats conditional field.
func (*ContactsGetTopPeersRequest) SetForwardUsers ¶
func (g *ContactsGetTopPeersRequest) SetForwardUsers(value bool)
SetForwardUsers sets value of ForwardUsers conditional field.
func (*ContactsGetTopPeersRequest) SetGroups ¶
func (g *ContactsGetTopPeersRequest) SetGroups(value bool)
SetGroups sets value of Groups conditional field.
func (*ContactsGetTopPeersRequest) SetPhoneCalls ¶
func (g *ContactsGetTopPeersRequest) SetPhoneCalls(value bool)
SetPhoneCalls sets value of PhoneCalls conditional field.
func (*ContactsGetTopPeersRequest) String ¶ added in v0.12.0
func (g *ContactsGetTopPeersRequest) String() string
String implements fmt.Stringer.
type ContactsImportContactsRequest ¶
type ContactsImportContactsRequest struct {
// List of contacts to import
Contacts []InputPhoneContact
}
ContactsImportContactsRequest represents TL type `contacts.importContacts#2c800be5`. Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info. Use contacts.addContact¹ to add Telegram contacts without actually using their phone number.
Links:
See https://core.telegram.org/method/contacts.importContacts for reference.
func (*ContactsImportContactsRequest) Decode ¶
func (i *ContactsImportContactsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsImportContactsRequest) Encode ¶
func (i *ContactsImportContactsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsImportContactsRequest) String ¶ added in v0.12.0
func (i *ContactsImportContactsRequest) String() string
String implements fmt.Stringer.
type ContactsImportedContacts ¶
type ContactsImportedContacts struct {
// List of succesfully imported contacts
Imported []ImportedContact
// Popular contacts
PopularInvites []PopularContact
// List of contact ids that could not be imported due to system limitation and will need to be imported at a later date.Parameter added in Layer 13¹
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-13
RetryContacts []int64
// List of users
Users []UserClass
}
ContactsImportedContacts represents TL type `contacts.importedContacts#77d01c3b`. Info on succesfully imported contacts.
See https://core.telegram.org/constructor/contacts.importedContacts for reference.
func (*ContactsImportedContacts) Decode ¶
func (i *ContactsImportedContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsImportedContacts) Encode ¶
func (i *ContactsImportedContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsImportedContacts) String ¶ added in v0.12.0
func (i *ContactsImportedContacts) String() string
String implements fmt.Stringer.
type ContactsResetHandler ¶ added in v0.9.0
type ContactsResetHandler func(ctx UpdateContext, update *UpdateContactsReset) error
ContactsResetHandler is a ContactsReset event handler.
type ContactsResetSavedRequest ¶
type ContactsResetSavedRequest struct {
}
ContactsResetSavedRequest represents TL type `contacts.resetSaved#879537f1`. Delete saved contacts
See https://core.telegram.org/method/contacts.resetSaved for reference.
func (*ContactsResetSavedRequest) Decode ¶
func (r *ContactsResetSavedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsResetSavedRequest) Encode ¶
func (r *ContactsResetSavedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsResetSavedRequest) String ¶ added in v0.12.0
func (r *ContactsResetSavedRequest) String() string
String implements fmt.Stringer.
type ContactsResetTopPeerRatingRequest ¶
type ContactsResetTopPeerRatingRequest struct {
// Top peer category
Category TopPeerCategoryClass
// Peer whose rating should be reset
Peer InputPeerClass
}
ContactsResetTopPeerRatingRequest represents TL type `contacts.resetTopPeerRating#1ae373ac`. Reset rating¹ of top peer
Links:
See https://core.telegram.org/method/contacts.resetTopPeerRating for reference.
func (*ContactsResetTopPeerRatingRequest) Decode ¶
func (r *ContactsResetTopPeerRatingRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsResetTopPeerRatingRequest) Encode ¶
func (r *ContactsResetTopPeerRatingRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsResetTopPeerRatingRequest) String ¶ added in v0.12.0
func (r *ContactsResetTopPeerRatingRequest) String() string
String implements fmt.Stringer.
type ContactsResolveUsernameRequest ¶
type ContactsResolveUsernameRequest struct {
// @username to resolve
Username string
}
ContactsResolveUsernameRequest represents TL type `contacts.resolveUsername#f93ccba3`. Resolve a @username to get peer info
See https://core.telegram.org/method/contacts.resolveUsername for reference.
func (*ContactsResolveUsernameRequest) Decode ¶
func (r *ContactsResolveUsernameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsResolveUsernameRequest) Encode ¶
func (r *ContactsResolveUsernameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsResolveUsernameRequest) String ¶ added in v0.12.0
func (r *ContactsResolveUsernameRequest) String() string
String implements fmt.Stringer.
type ContactsResolvedPeer ¶
type ContactsResolvedPeer struct {
// The peer
Peer PeerClass
// Chats
Chats []ChatClass
// Users
Users []UserClass
}
ContactsResolvedPeer represents TL type `contacts.resolvedPeer#7f077ad9`. Resolved peer
See https://core.telegram.org/constructor/contacts.resolvedPeer for reference.
func (*ContactsResolvedPeer) Decode ¶
func (r *ContactsResolvedPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsResolvedPeer) Encode ¶
func (r *ContactsResolvedPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsResolvedPeer) String ¶ added in v0.12.0
func (r *ContactsResolvedPeer) String() string
String implements fmt.Stringer.
type ContactsSearchRequest ¶
type ContactsSearchRequest struct {
// Target substring
Q string
// Maximum number of users to be returned
Limit int
}
ContactsSearchRequest represents TL type `contacts.search#11f812d8`. Returns users found by username substring.
See https://core.telegram.org/method/contacts.search for reference.
func (*ContactsSearchRequest) Decode ¶
func (s *ContactsSearchRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsSearchRequest) Encode ¶
func (s *ContactsSearchRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsSearchRequest) String ¶ added in v0.12.0
func (s *ContactsSearchRequest) String() string
String implements fmt.Stringer.
type ContactsToggleTopPeersRequest ¶
type ContactsToggleTopPeersRequest struct {
// Enable/disable
Enabled bool
}
ContactsToggleTopPeersRequest represents TL type `contacts.toggleTopPeers#8514bdda`. Enable/disable top peers¹
Links:
See https://core.telegram.org/method/contacts.toggleTopPeers for reference.
func (*ContactsToggleTopPeersRequest) Decode ¶
func (t *ContactsToggleTopPeersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsToggleTopPeersRequest) Encode ¶
func (t *ContactsToggleTopPeersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsToggleTopPeersRequest) String ¶ added in v0.12.0
func (t *ContactsToggleTopPeersRequest) String() string
String implements fmt.Stringer.
type ContactsTopPeers ¶
type ContactsTopPeers struct {
// Top peers by top peer category
Categories []TopPeerCategoryPeers
// Chats
Chats []ChatClass
// Users
Users []UserClass
}
ContactsTopPeers represents TL type `contacts.topPeers#70b772a8`. Top peers
See https://core.telegram.org/constructor/contacts.topPeers for reference.
func (*ContactsTopPeers) Decode ¶
func (t *ContactsTopPeers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsTopPeers) Encode ¶
func (t *ContactsTopPeers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsTopPeers) String ¶ added in v0.12.0
func (t *ContactsTopPeers) String() string
String implements fmt.Stringer.
type ContactsTopPeersBox ¶
type ContactsTopPeersBox struct {
TopPeers ContactsTopPeersClass
}
ContactsTopPeers boxes the ContactsTopPeersClass providing a helper.
type ContactsTopPeersClass ¶
type ContactsTopPeersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ContactsTopPeersClass represents contacts.TopPeers generic type.
See https://core.telegram.org/type/contacts.TopPeers for reference.
Example:
g, err := DecodeContactsTopPeers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ContactsTopPeersNotModified: // contacts.topPeersNotModified#de266ef5
case *ContactsTopPeers: // contacts.topPeers#70b772a8
case *ContactsTopPeersDisabled: // contacts.topPeersDisabled#b52c939d
default: panic(v)
}
func DecodeContactsTopPeers ¶
func DecodeContactsTopPeers(buf *bin.Buffer) (ContactsTopPeersClass, error)
DecodeContactsTopPeers implements binary de-serialization for ContactsTopPeersClass.
type ContactsTopPeersDisabled ¶
type ContactsTopPeersDisabled struct {
}
ContactsTopPeersDisabled represents TL type `contacts.topPeersDisabled#b52c939d`. Top peers disabled
See https://core.telegram.org/constructor/contacts.topPeersDisabled for reference.
func (*ContactsTopPeersDisabled) Decode ¶
func (t *ContactsTopPeersDisabled) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsTopPeersDisabled) Encode ¶
func (t *ContactsTopPeersDisabled) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsTopPeersDisabled) String ¶ added in v0.12.0
func (t *ContactsTopPeersDisabled) String() string
String implements fmt.Stringer.
type ContactsTopPeersNotModified ¶
type ContactsTopPeersNotModified struct {
}
ContactsTopPeersNotModified represents TL type `contacts.topPeersNotModified#de266ef5`. Top peer info hasn't changed
See https://core.telegram.org/constructor/contacts.topPeersNotModified for reference.
func (*ContactsTopPeersNotModified) Decode ¶
func (t *ContactsTopPeersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsTopPeersNotModified) Encode ¶
func (t *ContactsTopPeersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsTopPeersNotModified) String ¶ added in v0.12.0
func (t *ContactsTopPeersNotModified) String() string
String implements fmt.Stringer.
type ContactsUnblockRequest ¶
type ContactsUnblockRequest struct {
// User ID
ID InputPeerClass
}
ContactsUnblockRequest represents TL type `contacts.unblock#bea65d50`. Deletes the user from the blacklist.
See https://core.telegram.org/method/contacts.unblock for reference.
func (*ContactsUnblockRequest) Decode ¶
func (u *ContactsUnblockRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ContactsUnblockRequest) Encode ¶
func (u *ContactsUnblockRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ContactsUnblockRequest) String ¶ added in v0.12.0
func (u *ContactsUnblockRequest) String() string
String implements fmt.Stringer.
type DataJSON ¶
type DataJSON struct {
// JSON-encoded object
Data string
}
DataJSON represents TL type `dataJSON#7d748d04`. Represents a json-encoded object
See https://core.telegram.org/constructor/dataJSON for reference.
type DcOption ¶
type DcOption struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the specified IP is an IPv6 address
Ipv6 bool
// Whether this DC should only be used to download or upload files¹
//
// Links:
// 1) https://core.telegram.org/api/files
MediaOnly bool
// Whether this DC only supports connection with transport obfuscation¹
//
// Links:
// 1) https://core.telegram.org/mtproto/mtproto-transports#transport-obfuscation
TcpoOnly bool
// Whether this is a CDN DC¹.
//
// Links:
// 1) https://core.telegram.org/cdn
CDN bool
// If set, this IP should be used when connecting through a proxy
Static bool
// DC ID
ID int
// IP address of DC
IPAddress string
// Port
Port int
// If the tcpo_only flag is set, specifies the secret to use when connecting using transport obfuscation¹
//
// Links:
// 1) https://core.telegram.org/mtproto/mtproto-transports#transport-obfuscation
//
// Use SetSecret and GetSecret helpers.
Secret []byte
}
DcOption represents TL type `dcOption#18b7a10d`. Data centre
See https://core.telegram.org/constructor/dcOption for reference.
func (*DcOption) GetSecret ¶
GetSecret returns value of Secret conditional field and boolean which is true if field was set.
func (*DcOption) SetMediaOnly ¶
SetMediaOnly sets value of MediaOnly conditional field.
func (*DcOption) SetTcpoOnly ¶
SetTcpoOnly sets value of TcpoOnly conditional field.
type DcOptionsHandler ¶ added in v0.9.0
type DcOptionsHandler func(ctx UpdateContext, update *UpdateDcOptions) error
DcOptionsHandler is a DcOptions event handler.
type DeleteChannelMessagesHandler ¶ added in v0.9.0
type DeleteChannelMessagesHandler func(ctx UpdateContext, update *UpdateDeleteChannelMessages) error
DeleteChannelMessagesHandler is a DeleteChannelMessages event handler.
type DeleteMessagesHandler ¶ added in v0.9.0
type DeleteMessagesHandler func(ctx UpdateContext, update *UpdateDeleteMessages) error
DeleteMessagesHandler is a DeleteMessages event handler.
type DeleteScheduledMessagesHandler ¶ added in v0.9.0
type DeleteScheduledMessagesHandler func(ctx UpdateContext, update *UpdateDeleteScheduledMessages) error
DeleteScheduledMessagesHandler is a DeleteScheduledMessages event handler.
type Dialog ¶
type Dialog struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is the dialog pinned
Pinned bool
// Whether the chat was manually marked as unread
UnreadMark bool
// The chat
Peer PeerClass
// The latest message ID
TopMessage int
// Position up to which all incoming messages are read.
ReadInboxMaxID int
// Position up to which all outgoing messages are read.
ReadOutboxMaxID int
// Number of unread messages
UnreadCount int
// Number of unread mentions¹
//
// Links:
// 1) https://core.telegram.org/api/mentions
UnreadMentionsCount int
// Notification settings
NotifySettings PeerNotifySettings
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
//
// Use SetPts and GetPts helpers.
Pts int
// Message draft
//
// Use SetDraft and GetDraft helpers.
Draft DraftMessageClass
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
}
Dialog represents TL type `dialog#2c171f72`. Chat
See https://core.telegram.org/constructor/dialog for reference.
func (*Dialog) GetDraft ¶
func (d *Dialog) GetDraft() (value DraftMessageClass, ok bool)
GetDraft returns value of Draft conditional field and boolean which is true if field was set.
func (*Dialog) GetFolderID ¶
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*Dialog) GetPts ¶
GetPts returns value of Pts conditional field and boolean which is true if field was set.
func (*Dialog) SetDraft ¶
func (d *Dialog) SetDraft(value DraftMessageClass)
SetDraft sets value of Draft conditional field.
func (*Dialog) SetFolderID ¶
SetFolderID sets value of FolderID conditional field.
func (*Dialog) SetUnreadMark ¶
SetUnreadMark sets value of UnreadMark conditional field.
type DialogBox ¶
type DialogBox struct {
Dialog DialogClass
}
Dialog boxes the DialogClass providing a helper.
type DialogClass ¶
type DialogClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
DialogClass represents Dialog generic type.
See https://core.telegram.org/type/Dialog for reference.
Example:
g, err := DecodeDialog(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *Dialog: // dialog#2c171f72
case *DialogFolder: // dialogFolder#71bd134c
default: panic(v)
}
func DecodeDialog ¶
func DecodeDialog(buf *bin.Buffer) (DialogClass, error)
DecodeDialog implements binary de-serialization for DialogClass.
type DialogFilter ¶
type DialogFilter struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to include all contacts in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Contacts bool
// Whether to include all non-contacts in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
NonContacts bool
// Whether to include all groups in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Groups bool
// Whether to include all channels in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Broadcasts bool
// Whether to include all bots in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Bots bool
// Whether to exclude muted chats from this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
ExcludeMuted bool
// Whether to exclude read chats from this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
ExcludeRead bool
// Whether to exclude archived chats from this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
ExcludeArchived bool
// Folder¹ ID
//
// Links:
// 1) https://core.telegram.org/api/folders
ID int
// Folder¹ name
//
// Links:
// 1) https://core.telegram.org/api/folders
Title string
// Folder¹ emoticon
//
// Links:
// 1) https://core.telegram.org/api/folders
//
// Use SetEmoticon and GetEmoticon helpers.
Emoticon string
// Pinned chats, folders¹ can have unlimited pinned chats
//
// Links:
// 1) https://core.telegram.org/api/folders
PinnedPeers []InputPeerClass
// Include the following chats in this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
IncludePeers []InputPeerClass
// Exclude the following chats from this folder¹
//
// Links:
// 1) https://core.telegram.org/api/folders
ExcludePeers []InputPeerClass
}
DialogFilter represents TL type `dialogFilter#7438f7e8`. Dialog filter AKA folder¹
Links:
See https://core.telegram.org/constructor/dialogFilter for reference.
func (*DialogFilter) Decode ¶
func (d *DialogFilter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogFilter) Encode ¶
func (d *DialogFilter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogFilter) GetEmoticon ¶
func (d *DialogFilter) GetEmoticon() (value string, ok bool)
GetEmoticon returns value of Emoticon conditional field and boolean which is true if field was set.
func (*DialogFilter) SetBots ¶
func (d *DialogFilter) SetBots(value bool)
SetBots sets value of Bots conditional field.
func (*DialogFilter) SetBroadcasts ¶
func (d *DialogFilter) SetBroadcasts(value bool)
SetBroadcasts sets value of Broadcasts conditional field.
func (*DialogFilter) SetContacts ¶
func (d *DialogFilter) SetContacts(value bool)
SetContacts sets value of Contacts conditional field.
func (*DialogFilter) SetEmoticon ¶
func (d *DialogFilter) SetEmoticon(value string)
SetEmoticon sets value of Emoticon conditional field.
func (*DialogFilter) SetExcludeArchived ¶
func (d *DialogFilter) SetExcludeArchived(value bool)
SetExcludeArchived sets value of ExcludeArchived conditional field.
func (*DialogFilter) SetExcludeMuted ¶
func (d *DialogFilter) SetExcludeMuted(value bool)
SetExcludeMuted sets value of ExcludeMuted conditional field.
func (*DialogFilter) SetExcludeRead ¶
func (d *DialogFilter) SetExcludeRead(value bool)
SetExcludeRead sets value of ExcludeRead conditional field.
func (*DialogFilter) SetGroups ¶
func (d *DialogFilter) SetGroups(value bool)
SetGroups sets value of Groups conditional field.
func (*DialogFilter) SetNonContacts ¶
func (d *DialogFilter) SetNonContacts(value bool)
SetNonContacts sets value of NonContacts conditional field.
func (*DialogFilter) String ¶ added in v0.12.0
func (d *DialogFilter) String() string
String implements fmt.Stringer.
type DialogFilterHandler ¶ added in v0.9.0
type DialogFilterHandler func(ctx UpdateContext, update *UpdateDialogFilter) error
DialogFilterHandler is a DialogFilter event handler.
type DialogFilterOrderHandler ¶ added in v0.9.0
type DialogFilterOrderHandler func(ctx UpdateContext, update *UpdateDialogFilterOrder) error
DialogFilterOrderHandler is a DialogFilterOrder event handler.
type DialogFilterSuggested ¶
type DialogFilterSuggested struct {
// Folder info¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Filter DialogFilter
// Folder¹ description
//
// Links:
// 1) https://core.telegram.org/api/folders
Description string
}
DialogFilterSuggested represents TL type `dialogFilterSuggested#77744d4a`. Suggested folders¹
Links:
See https://core.telegram.org/constructor/dialogFilterSuggested for reference.
func (*DialogFilterSuggested) Decode ¶
func (d *DialogFilterSuggested) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogFilterSuggested) Encode ¶
func (d *DialogFilterSuggested) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogFilterSuggested) String ¶ added in v0.12.0
func (d *DialogFilterSuggested) String() string
String implements fmt.Stringer.
type DialogFilterSuggestedVector ¶ added in v0.8.0
type DialogFilterSuggestedVector struct {
// Elements of Vector<DialogFilterSuggested>
Elems []DialogFilterSuggested
}
DialogFilterSuggestedVector is a box for Vector<DialogFilterSuggested>
func (*DialogFilterSuggestedVector) Decode ¶ added in v0.8.0
func (vec *DialogFilterSuggestedVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogFilterSuggestedVector) Encode ¶ added in v0.8.0
func (vec *DialogFilterSuggestedVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogFilterSuggestedVector) String ¶ added in v0.12.0
func (vec *DialogFilterSuggestedVector) String() string
String implements fmt.Stringer.
type DialogFilterVector ¶ added in v0.8.0
type DialogFilterVector struct {
// Elements of Vector<DialogFilter>
Elems []DialogFilter
}
DialogFilterVector is a box for Vector<DialogFilter>
func (*DialogFilterVector) Decode ¶ added in v0.8.0
func (vec *DialogFilterVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogFilterVector) Encode ¶ added in v0.8.0
func (vec *DialogFilterVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogFilterVector) String ¶ added in v0.12.0
func (vec *DialogFilterVector) String() string
String implements fmt.Stringer.
type DialogFiltersHandler ¶ added in v0.9.0
type DialogFiltersHandler func(ctx UpdateContext, update *UpdateDialogFilters) error
DialogFiltersHandler is a DialogFilters event handler.
type DialogFolder ¶
type DialogFolder struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this folder pinned
Pinned bool
// The folder
Folder Folder
// Peer in folder
Peer PeerClass
// Latest message ID of dialog
TopMessage int
// Number of unread muted peers in folder
UnreadMutedPeersCount int
// Number of unread unmuted peers in folder
UnreadUnmutedPeersCount int
// Number of unread messages from muted peers in folder
UnreadMutedMessagesCount int
// Number of unread messages from unmuted peers in folder
UnreadUnmutedMessagesCount int
}
DialogFolder represents TL type `dialogFolder#71bd134c`. Dialog in folder
See https://core.telegram.org/constructor/dialogFolder for reference.
func (*DialogFolder) Decode ¶
func (d *DialogFolder) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogFolder) Encode ¶
func (d *DialogFolder) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogFolder) SetPinned ¶
func (d *DialogFolder) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*DialogFolder) String ¶ added in v0.12.0
func (d *DialogFolder) String() string
String implements fmt.Stringer.
type DialogPeer ¶
type DialogPeer struct {
// Peer
Peer PeerClass
}
DialogPeer represents TL type `dialogPeer#e56dbf05`. Peer
See https://core.telegram.org/constructor/dialogPeer for reference.
func (*DialogPeer) Decode ¶
func (d *DialogPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogPeer) Encode ¶
func (d *DialogPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogPeer) String ¶ added in v0.12.0
func (d *DialogPeer) String() string
String implements fmt.Stringer.
type DialogPeerBox ¶
type DialogPeerBox struct {
DialogPeer DialogPeerClass
}
DialogPeer boxes the DialogPeerClass providing a helper.
type DialogPeerClass ¶
type DialogPeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
DialogPeerClass represents DialogPeer generic type.
See https://core.telegram.org/type/DialogPeer for reference.
Example:
g, err := DecodeDialogPeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *DialogPeer: // dialogPeer#e56dbf05
case *DialogPeerFolder: // dialogPeerFolder#514519e2
default: panic(v)
}
func DecodeDialogPeer ¶
func DecodeDialogPeer(buf *bin.Buffer) (DialogPeerClass, error)
DecodeDialogPeer implements binary de-serialization for DialogPeerClass.
type DialogPeerClassVector ¶ added in v0.8.0
type DialogPeerClassVector struct {
// Elements of Vector<DialogPeer>
Elems []DialogPeerClass
}
DialogPeerClassVector is a box for Vector<DialogPeer>
func (*DialogPeerClassVector) Decode ¶ added in v0.8.0
func (vec *DialogPeerClassVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogPeerClassVector) Encode ¶ added in v0.8.0
func (vec *DialogPeerClassVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogPeerClassVector) String ¶ added in v0.12.0
func (vec *DialogPeerClassVector) String() string
String implements fmt.Stringer.
type DialogPeerFolder ¶
type DialogPeerFolder struct {
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
DialogPeerFolder represents TL type `dialogPeerFolder#514519e2`. Peer folder¹
Links:
See https://core.telegram.org/constructor/dialogPeerFolder for reference.
func (*DialogPeerFolder) Decode ¶
func (d *DialogPeerFolder) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DialogPeerFolder) Encode ¶
func (d *DialogPeerFolder) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DialogPeerFolder) String ¶ added in v0.12.0
func (d *DialogPeerFolder) String() string
String implements fmt.Stringer.
type DialogPinnedHandler ¶ added in v0.9.0
type DialogPinnedHandler func(ctx UpdateContext, update *UpdateDialogPinned) error
DialogPinnedHandler is a DialogPinned event handler.
type DialogUnreadMarkHandler ¶ added in v0.9.0
type DialogUnreadMarkHandler func(ctx UpdateContext, update *UpdateDialogUnreadMark) error
DialogUnreadMarkHandler is a DialogUnreadMark event handler.
type Document ¶
type Document struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Document ID
ID int64
// Check sum, dependant on document ID
AccessHash int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
// Creation date
Date int
// MIME type
MimeType string
// Size
Size int
// Thumbnails
//
// Use SetThumbs and GetThumbs helpers.
Thumbs []PhotoSizeClass
// Video thumbnails
//
// Use SetVideoThumbs and GetVideoThumbs helpers.
VideoThumbs []VideoSize
// DC ID
DCID int
// Attributes
Attributes []DocumentAttributeClass
}
Document represents TL type `document#1e87342b`. Document
See https://core.telegram.org/constructor/document for reference.
func (*Document) GetThumbs ¶
func (d *Document) GetThumbs() (value []PhotoSizeClass, ok bool)
GetThumbs returns value of Thumbs conditional field and boolean which is true if field was set.
func (*Document) GetVideoThumbs ¶
GetVideoThumbs returns value of VideoThumbs conditional field and boolean which is true if field was set.
func (*Document) SetThumbs ¶
func (d *Document) SetThumbs(value []PhotoSizeClass)
SetThumbs sets value of Thumbs conditional field.
func (*Document) SetVideoThumbs ¶
SetVideoThumbs sets value of VideoThumbs conditional field.
type DocumentAttributeAnimated ¶
type DocumentAttributeAnimated struct {
}
DocumentAttributeAnimated represents TL type `documentAttributeAnimated#11b58939`. Defines an animated GIF
See https://core.telegram.org/constructor/documentAttributeAnimated for reference.
func (*DocumentAttributeAnimated) Decode ¶
func (d *DocumentAttributeAnimated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeAnimated) Encode ¶
func (d *DocumentAttributeAnimated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeAnimated) String ¶ added in v0.12.0
func (d *DocumentAttributeAnimated) String() string
String implements fmt.Stringer.
type DocumentAttributeAudio ¶
type DocumentAttributeAudio struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a voice message
Voice bool
// Duration in seconds
Duration int
// Name of song
//
// Use SetTitle and GetTitle helpers.
Title string
// Performer
//
// Use SetPerformer and GetPerformer helpers.
Performer string
// Waveform
//
// Use SetWaveform and GetWaveform helpers.
Waveform []byte
}
DocumentAttributeAudio represents TL type `documentAttributeAudio#9852f9c6`. Represents an audio file
See https://core.telegram.org/constructor/documentAttributeAudio for reference.
func (*DocumentAttributeAudio) Decode ¶
func (d *DocumentAttributeAudio) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeAudio) Encode ¶
func (d *DocumentAttributeAudio) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeAudio) GetPerformer ¶
func (d *DocumentAttributeAudio) GetPerformer() (value string, ok bool)
GetPerformer returns value of Performer conditional field and boolean which is true if field was set.
func (*DocumentAttributeAudio) GetTitle ¶
func (d *DocumentAttributeAudio) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*DocumentAttributeAudio) GetWaveform ¶
func (d *DocumentAttributeAudio) GetWaveform() (value []byte, ok bool)
GetWaveform returns value of Waveform conditional field and boolean which is true if field was set.
func (*DocumentAttributeAudio) SetPerformer ¶
func (d *DocumentAttributeAudio) SetPerformer(value string)
SetPerformer sets value of Performer conditional field.
func (*DocumentAttributeAudio) SetTitle ¶
func (d *DocumentAttributeAudio) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*DocumentAttributeAudio) SetVoice ¶
func (d *DocumentAttributeAudio) SetVoice(value bool)
SetVoice sets value of Voice conditional field.
func (*DocumentAttributeAudio) SetWaveform ¶
func (d *DocumentAttributeAudio) SetWaveform(value []byte)
SetWaveform sets value of Waveform conditional field.
func (*DocumentAttributeAudio) String ¶ added in v0.12.0
func (d *DocumentAttributeAudio) String() string
String implements fmt.Stringer.
type DocumentAttributeBox ¶
type DocumentAttributeBox struct {
DocumentAttribute DocumentAttributeClass
}
DocumentAttribute boxes the DocumentAttributeClass providing a helper.
type DocumentAttributeClass ¶
type DocumentAttributeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
DocumentAttributeClass represents DocumentAttribute generic type.
See https://core.telegram.org/type/DocumentAttribute for reference.
Example:
g, err := DecodeDocumentAttribute(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *DocumentAttributeImageSize: // documentAttributeImageSize#6c37c15c
case *DocumentAttributeAnimated: // documentAttributeAnimated#11b58939
case *DocumentAttributeSticker: // documentAttributeSticker#6319d612
case *DocumentAttributeVideo: // documentAttributeVideo#ef02ce6
case *DocumentAttributeAudio: // documentAttributeAudio#9852f9c6
case *DocumentAttributeFilename: // documentAttributeFilename#15590068
case *DocumentAttributeHasStickers: // documentAttributeHasStickers#9801d2f7
default: panic(v)
}
func DecodeDocumentAttribute ¶
func DecodeDocumentAttribute(buf *bin.Buffer) (DocumentAttributeClass, error)
DecodeDocumentAttribute implements binary de-serialization for DocumentAttributeClass.
type DocumentAttributeFilename ¶
type DocumentAttributeFilename struct {
// The file name
FileName string
}
DocumentAttributeFilename represents TL type `documentAttributeFilename#15590068`. A simple document with a file name
See https://core.telegram.org/constructor/documentAttributeFilename for reference.
func (*DocumentAttributeFilename) Decode ¶
func (d *DocumentAttributeFilename) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeFilename) Encode ¶
func (d *DocumentAttributeFilename) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeFilename) String ¶ added in v0.12.0
func (d *DocumentAttributeFilename) String() string
String implements fmt.Stringer.
type DocumentAttributeHasStickers ¶
type DocumentAttributeHasStickers struct {
}
DocumentAttributeHasStickers represents TL type `documentAttributeHasStickers#9801d2f7`. Whether the current document has stickers attached
See https://core.telegram.org/constructor/documentAttributeHasStickers for reference.
func (*DocumentAttributeHasStickers) Decode ¶
func (d *DocumentAttributeHasStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeHasStickers) Encode ¶
func (d *DocumentAttributeHasStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeHasStickers) String ¶ added in v0.12.0
func (d *DocumentAttributeHasStickers) String() string
String implements fmt.Stringer.
type DocumentAttributeImageSize ¶
DocumentAttributeImageSize represents TL type `documentAttributeImageSize#6c37c15c`. Defines the width and height of an image uploaded as document
See https://core.telegram.org/constructor/documentAttributeImageSize for reference.
func (*DocumentAttributeImageSize) Decode ¶
func (d *DocumentAttributeImageSize) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeImageSize) Encode ¶
func (d *DocumentAttributeImageSize) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeImageSize) String ¶ added in v0.12.0
func (d *DocumentAttributeImageSize) String() string
String implements fmt.Stringer.
type DocumentAttributeSticker ¶
type DocumentAttributeSticker struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a mask sticker
Mask bool
// Alternative emoji representation of sticker
Alt string
// Associated stickerset
Stickerset InputStickerSetClass
// Mask coordinates (if this is a mask sticker, attached to a photo)
//
// Use SetMaskCoords and GetMaskCoords helpers.
MaskCoords MaskCoords
}
DocumentAttributeSticker represents TL type `documentAttributeSticker#6319d612`. Defines a sticker
See https://core.telegram.org/constructor/documentAttributeSticker for reference.
func (*DocumentAttributeSticker) Decode ¶
func (d *DocumentAttributeSticker) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeSticker) Encode ¶
func (d *DocumentAttributeSticker) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeSticker) GetMaskCoords ¶
func (d *DocumentAttributeSticker) GetMaskCoords() (value MaskCoords, ok bool)
GetMaskCoords returns value of MaskCoords conditional field and boolean which is true if field was set.
func (*DocumentAttributeSticker) SetMask ¶
func (d *DocumentAttributeSticker) SetMask(value bool)
SetMask sets value of Mask conditional field.
func (*DocumentAttributeSticker) SetMaskCoords ¶
func (d *DocumentAttributeSticker) SetMaskCoords(value MaskCoords)
SetMaskCoords sets value of MaskCoords conditional field.
func (*DocumentAttributeSticker) String ¶ added in v0.12.0
func (d *DocumentAttributeSticker) String() string
String implements fmt.Stringer.
type DocumentAttributeVideo ¶
type DocumentAttributeVideo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a round video
RoundMessage bool
// Whether the video supports streaming
SupportsStreaming bool
// Duration in seconds
Duration int
// Video width
W int
// Video height
H int
}
DocumentAttributeVideo represents TL type `documentAttributeVideo#ef02ce6`. Defines a video
See https://core.telegram.org/constructor/documentAttributeVideo for reference.
func (*DocumentAttributeVideo) Decode ¶
func (d *DocumentAttributeVideo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentAttributeVideo) Encode ¶
func (d *DocumentAttributeVideo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentAttributeVideo) SetRoundMessage ¶
func (d *DocumentAttributeVideo) SetRoundMessage(value bool)
SetRoundMessage sets value of RoundMessage conditional field.
func (*DocumentAttributeVideo) SetSupportsStreaming ¶
func (d *DocumentAttributeVideo) SetSupportsStreaming(value bool)
SetSupportsStreaming sets value of SupportsStreaming conditional field.
func (*DocumentAttributeVideo) String ¶ added in v0.12.0
func (d *DocumentAttributeVideo) String() string
String implements fmt.Stringer.
type DocumentBox ¶
type DocumentBox struct {
Document DocumentClass
}
Document boxes the DocumentClass providing a helper.
type DocumentClass ¶
type DocumentClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
DocumentClass represents Document generic type.
See https://core.telegram.org/type/Document for reference.
Example:
g, err := DecodeDocument(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *DocumentEmpty: // documentEmpty#36f8c871
case *Document: // document#1e87342b
default: panic(v)
}
func DecodeDocument ¶
func DecodeDocument(buf *bin.Buffer) (DocumentClass, error)
DecodeDocument implements binary de-serialization for DocumentClass.
type DocumentEmpty ¶
type DocumentEmpty struct {
// Document ID or 0
ID int64
}
DocumentEmpty represents TL type `documentEmpty#36f8c871`. Empty constructor, document doesn't exist.
See https://core.telegram.org/constructor/documentEmpty for reference.
func (*DocumentEmpty) Decode ¶
func (d *DocumentEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DocumentEmpty) Encode ¶
func (d *DocumentEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DocumentEmpty) String ¶ added in v0.12.0
func (d *DocumentEmpty) String() string
String implements fmt.Stringer.
type DraftMessage ¶
type DraftMessage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether no webpage preview will be generated
NoWebpage bool
// The message this message will reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// The draft
Message string
// Message entities¹ for styled text.
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Date of last update of the draft.
Date int
}
DraftMessage represents TL type `draftMessage#fd8e711f`. Represents a message draft¹.
Links:
See https://core.telegram.org/constructor/draftMessage for reference.
func (*DraftMessage) Decode ¶
func (d *DraftMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DraftMessage) Encode ¶
func (d *DraftMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DraftMessage) GetEntities ¶
func (d *DraftMessage) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*DraftMessage) GetReplyToMsgID ¶
func (d *DraftMessage) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*DraftMessage) SetEntities ¶
func (d *DraftMessage) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*DraftMessage) SetNoWebpage ¶
func (d *DraftMessage) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*DraftMessage) SetReplyToMsgID ¶
func (d *DraftMessage) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*DraftMessage) String ¶ added in v0.12.0
func (d *DraftMessage) String() string
String implements fmt.Stringer.
type DraftMessageBox ¶
type DraftMessageBox struct {
DraftMessage DraftMessageClass
}
DraftMessage boxes the DraftMessageClass providing a helper.
type DraftMessageClass ¶
type DraftMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
DraftMessageClass represents DraftMessage generic type.
See https://core.telegram.org/type/DraftMessage for reference.
Example:
g, err := DecodeDraftMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *DraftMessageEmpty: // draftMessageEmpty#1b0c841a
case *DraftMessage: // draftMessage#fd8e711f
default: panic(v)
}
func DecodeDraftMessage ¶
func DecodeDraftMessage(buf *bin.Buffer) (DraftMessageClass, error)
DecodeDraftMessage implements binary de-serialization for DraftMessageClass.
type DraftMessageEmpty ¶
type DraftMessageEmpty struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// When was the draft last updated
//
// Use SetDate and GetDate helpers.
Date int
}
DraftMessageEmpty represents TL type `draftMessageEmpty#1b0c841a`. Empty draft
See https://core.telegram.org/constructor/draftMessageEmpty for reference.
func (*DraftMessageEmpty) Decode ¶
func (d *DraftMessageEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DraftMessageEmpty) Encode ¶
func (d *DraftMessageEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DraftMessageEmpty) GetDate ¶
func (d *DraftMessageEmpty) GetDate() (value int, ok bool)
GetDate returns value of Date conditional field and boolean which is true if field was set.
func (*DraftMessageEmpty) SetDate ¶
func (d *DraftMessageEmpty) SetDate(value int)
SetDate sets value of Date conditional field.
func (*DraftMessageEmpty) String ¶ added in v0.12.0
func (d *DraftMessageEmpty) String() string
String implements fmt.Stringer.
type DraftMessageHandler ¶ added in v0.9.0
type DraftMessageHandler func(ctx UpdateContext, update *UpdateDraftMessage) error
DraftMessageHandler is a DraftMessage event handler.
type EditChannelMessageHandler ¶ added in v0.9.0
type EditChannelMessageHandler func(ctx UpdateContext, update *UpdateEditChannelMessage) error
EditChannelMessageHandler is a EditChannelMessage event handler.
type EditMessageHandler ¶ added in v0.9.0
type EditMessageHandler func(ctx UpdateContext, update *UpdateEditMessage) error
EditMessageHandler is a EditMessage event handler.
type EmojiKeyword ¶
type EmojiKeyword struct {
// Keyword
Keyword string
// Emojis associated to keyword
Emoticons []string
}
EmojiKeyword represents TL type `emojiKeyword#d5b3b9f9`. Emoji keyword
See https://core.telegram.org/constructor/emojiKeyword for reference.
func (*EmojiKeyword) Decode ¶
func (e *EmojiKeyword) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EmojiKeyword) Encode ¶
func (e *EmojiKeyword) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EmojiKeyword) String ¶ added in v0.12.0
func (e *EmojiKeyword) String() string
String implements fmt.Stringer.
type EmojiKeywordBox ¶
type EmojiKeywordBox struct {
EmojiKeyword EmojiKeywordClass
}
EmojiKeyword boxes the EmojiKeywordClass providing a helper.
type EmojiKeywordClass ¶
type EmojiKeywordClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
EmojiKeywordClass represents EmojiKeyword generic type.
See https://core.telegram.org/type/EmojiKeyword for reference.
Example:
g, err := DecodeEmojiKeyword(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *EmojiKeyword: // emojiKeyword#d5b3b9f9
case *EmojiKeywordDeleted: // emojiKeywordDeleted#236df622
default: panic(v)
}
func DecodeEmojiKeyword ¶
func DecodeEmojiKeyword(buf *bin.Buffer) (EmojiKeywordClass, error)
DecodeEmojiKeyword implements binary de-serialization for EmojiKeywordClass.
type EmojiKeywordDeleted ¶
type EmojiKeywordDeleted struct {
// Keyword
Keyword string
// Emojis that were associated to keyword
Emoticons []string
}
EmojiKeywordDeleted represents TL type `emojiKeywordDeleted#236df622`. Deleted emoji keyword
See https://core.telegram.org/constructor/emojiKeywordDeleted for reference.
func (*EmojiKeywordDeleted) Decode ¶
func (e *EmojiKeywordDeleted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EmojiKeywordDeleted) Encode ¶
func (e *EmojiKeywordDeleted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EmojiKeywordDeleted) String ¶ added in v0.12.0
func (e *EmojiKeywordDeleted) String() string
String implements fmt.Stringer.
type EmojiKeywordsDifference ¶
type EmojiKeywordsDifference struct {
// Language code for keywords
LangCode string
// Previous emoji keyword list version
FromVersion int
// Current version of emoji keyword list
Version int
// Emojis associated to keywords
Keywords []EmojiKeywordClass
}
EmojiKeywordsDifference represents TL type `emojiKeywordsDifference#5cc761bd`. Changes to emoji keywords
See https://core.telegram.org/constructor/emojiKeywordsDifference for reference.
func (*EmojiKeywordsDifference) Decode ¶
func (e *EmojiKeywordsDifference) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EmojiKeywordsDifference) Encode ¶
func (e *EmojiKeywordsDifference) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EmojiKeywordsDifference) String ¶ added in v0.12.0
func (e *EmojiKeywordsDifference) String() string
String implements fmt.Stringer.
type EmojiLanguage ¶
type EmojiLanguage struct {
// Language code
LangCode string
}
EmojiLanguage represents TL type `emojiLanguage#b3fb5361`. Emoji language
See https://core.telegram.org/constructor/emojiLanguage for reference.
func (*EmojiLanguage) Decode ¶
func (e *EmojiLanguage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EmojiLanguage) Encode ¶
func (e *EmojiLanguage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EmojiLanguage) String ¶ added in v0.12.0
func (e *EmojiLanguage) String() string
String implements fmt.Stringer.
type EmojiLanguageVector ¶ added in v0.8.0
type EmojiLanguageVector struct {
// Elements of Vector<EmojiLanguage>
Elems []EmojiLanguage
}
EmojiLanguageVector is a box for Vector<EmojiLanguage>
func (*EmojiLanguageVector) Decode ¶ added in v0.8.0
func (vec *EmojiLanguageVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EmojiLanguageVector) Encode ¶ added in v0.8.0
func (vec *EmojiLanguageVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EmojiLanguageVector) String ¶ added in v0.12.0
func (vec *EmojiLanguageVector) String() string
String implements fmt.Stringer.
type EmojiURL ¶
type EmojiURL struct {
// An HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation
URL string
}
EmojiURL represents TL type `emojiURL#a575739d`. An HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation
See https://core.telegram.org/constructor/emojiURL for reference.
type EncryptedChat ¶
type EncryptedChat struct {
// Chat ID
ID int
// Check sum dependant on the user ID
AccessHash int64
// Date chat was created
Date int
// Chat creator ID
AdminID int
// ID of the second chat participant
ParticipantID int
// B = g ^ b mod p, if the currently authorized user is the chat's creator,or A = g ^ a mod p otherwiseSee Wikipedia¹ for more info
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
GAOrB []byte
// 64-bit fingerprint of received key
KeyFingerprint int64
}
EncryptedChat represents TL type `encryptedChat#fa56ce36`. Encrypted chat
See https://core.telegram.org/constructor/encryptedChat for reference.
func (*EncryptedChat) Decode ¶
func (e *EncryptedChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedChat) Encode ¶
func (e *EncryptedChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedChat) String ¶ added in v0.12.0
func (e *EncryptedChat) String() string
String implements fmt.Stringer.
type EncryptedChatBox ¶
type EncryptedChatBox struct {
EncryptedChat EncryptedChatClass
}
EncryptedChat boxes the EncryptedChatClass providing a helper.
type EncryptedChatClass ¶
type EncryptedChatClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
EncryptedChatClass represents EncryptedChat generic type.
See https://core.telegram.org/type/EncryptedChat for reference.
Example:
g, err := DecodeEncryptedChat(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *EncryptedChatEmpty: // encryptedChatEmpty#ab7ec0a0
case *EncryptedChatWaiting: // encryptedChatWaiting#3bf703dc
case *EncryptedChatRequested: // encryptedChatRequested#62718a82
case *EncryptedChat: // encryptedChat#fa56ce36
case *EncryptedChatDiscarded: // encryptedChatDiscarded#13d6dd27
default: panic(v)
}
func DecodeEncryptedChat ¶
func DecodeEncryptedChat(buf *bin.Buffer) (EncryptedChatClass, error)
DecodeEncryptedChat implements binary de-serialization for EncryptedChatClass.
type EncryptedChatDiscarded ¶
type EncryptedChatDiscarded struct {
// Chat ID
ID int
}
EncryptedChatDiscarded represents TL type `encryptedChatDiscarded#13d6dd27`. Discarded or deleted chat.
See https://core.telegram.org/constructor/encryptedChatDiscarded for reference.
func (*EncryptedChatDiscarded) Decode ¶
func (e *EncryptedChatDiscarded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedChatDiscarded) Encode ¶
func (e *EncryptedChatDiscarded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedChatDiscarded) String ¶ added in v0.12.0
func (e *EncryptedChatDiscarded) String() string
String implements fmt.Stringer.
type EncryptedChatEmpty ¶
type EncryptedChatEmpty struct {
// Chat ID
ID int
}
EncryptedChatEmpty represents TL type `encryptedChatEmpty#ab7ec0a0`. Empty constructor.
See https://core.telegram.org/constructor/encryptedChatEmpty for reference.
func (*EncryptedChatEmpty) Decode ¶
func (e *EncryptedChatEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedChatEmpty) Encode ¶
func (e *EncryptedChatEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedChatEmpty) String ¶ added in v0.12.0
func (e *EncryptedChatEmpty) String() string
String implements fmt.Stringer.
type EncryptedChatRequested ¶
type EncryptedChatRequested struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Chat ID
ID int
// Check sum depending on user ID
AccessHash int64
// Chat creation date
Date int
// Chat creator ID
AdminID int
// ID of second chat participant
ParticipantID int
// A = g ^ a mod p, see Wikipedia¹
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
GA []byte
}
EncryptedChatRequested represents TL type `encryptedChatRequested#62718a82`. Request to create an encrypted chat.
See https://core.telegram.org/constructor/encryptedChatRequested for reference.
func (*EncryptedChatRequested) Decode ¶
func (e *EncryptedChatRequested) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedChatRequested) Encode ¶
func (e *EncryptedChatRequested) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedChatRequested) GetFolderID ¶
func (e *EncryptedChatRequested) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*EncryptedChatRequested) SetFolderID ¶
func (e *EncryptedChatRequested) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*EncryptedChatRequested) String ¶ added in v0.12.0
func (e *EncryptedChatRequested) String() string
String implements fmt.Stringer.
type EncryptedChatTypingHandler ¶ added in v0.9.0
type EncryptedChatTypingHandler func(ctx UpdateContext, update *UpdateEncryptedChatTyping) error
EncryptedChatTypingHandler is a EncryptedChatTyping event handler.
type EncryptedChatWaiting ¶
type EncryptedChatWaiting struct {
// Chat ID
ID int
// Checking sum depending on user ID
AccessHash int64
// Date of chat creation
Date int
// Chat creator ID
AdminID int
// ID of second chat participant
ParticipantID int
}
EncryptedChatWaiting represents TL type `encryptedChatWaiting#3bf703dc`. Chat waiting for approval of second participant.
See https://core.telegram.org/constructor/encryptedChatWaiting for reference.
func (*EncryptedChatWaiting) Decode ¶
func (e *EncryptedChatWaiting) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedChatWaiting) Encode ¶
func (e *EncryptedChatWaiting) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedChatWaiting) String ¶ added in v0.12.0
func (e *EncryptedChatWaiting) String() string
String implements fmt.Stringer.
type EncryptedFile ¶
type EncryptedFile struct {
// File ID
ID int64
// Checking sum depending on user ID
AccessHash int64
// File size in bytes
Size int
// Number of data centre
DCID int
// 32-bit fingerprint of key used for file encryption
KeyFingerprint int
}
EncryptedFile represents TL type `encryptedFile#4a70994c`. Encrypted file.
See https://core.telegram.org/constructor/encryptedFile for reference.
func (*EncryptedFile) Decode ¶
func (e *EncryptedFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedFile) Encode ¶
func (e *EncryptedFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedFile) String ¶ added in v0.12.0
func (e *EncryptedFile) String() string
String implements fmt.Stringer.
type EncryptedFileBox ¶
type EncryptedFileBox struct {
EncryptedFile EncryptedFileClass
}
EncryptedFile boxes the EncryptedFileClass providing a helper.
type EncryptedFileClass ¶
type EncryptedFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
EncryptedFileClass represents EncryptedFile generic type.
See https://core.telegram.org/type/EncryptedFile for reference.
Example:
g, err := DecodeEncryptedFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *EncryptedFileEmpty: // encryptedFileEmpty#c21f497e
case *EncryptedFile: // encryptedFile#4a70994c
default: panic(v)
}
func DecodeEncryptedFile ¶
func DecodeEncryptedFile(buf *bin.Buffer) (EncryptedFileClass, error)
DecodeEncryptedFile implements binary de-serialization for EncryptedFileClass.
type EncryptedFileEmpty ¶
type EncryptedFileEmpty struct {
}
EncryptedFileEmpty represents TL type `encryptedFileEmpty#c21f497e`. Empty constructor, unexisitng file.
See https://core.telegram.org/constructor/encryptedFileEmpty for reference.
func (*EncryptedFileEmpty) Decode ¶
func (e *EncryptedFileEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedFileEmpty) Encode ¶
func (e *EncryptedFileEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedFileEmpty) String ¶ added in v0.12.0
func (e *EncryptedFileEmpty) String() string
String implements fmt.Stringer.
type EncryptedMessage ¶
type EncryptedMessage struct {
// Random message ID, assigned by the author of message
RandomID int64
// ID of encrypted chat
ChatID int
// Date of sending
Date int
// TL-serialising of DecryptedMessage¹ type, encrypted with the key creatied at stage of chat initialization
//
// Links:
// 1) https://core.telegram.org/type/DecryptedMessage
Bytes []byte
// Attached encrypted file
File EncryptedFileClass
}
EncryptedMessage represents TL type `encryptedMessage#ed18c118`. Encrypted message.
See https://core.telegram.org/constructor/encryptedMessage for reference.
func (*EncryptedMessage) Decode ¶
func (e *EncryptedMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedMessage) Encode ¶
func (e *EncryptedMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedMessage) String ¶ added in v0.12.0
func (e *EncryptedMessage) String() string
String implements fmt.Stringer.
type EncryptedMessageBox ¶
type EncryptedMessageBox struct {
EncryptedMessage EncryptedMessageClass
}
EncryptedMessage boxes the EncryptedMessageClass providing a helper.
type EncryptedMessageClass ¶
type EncryptedMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
EncryptedMessageClass represents EncryptedMessage generic type.
See https://core.telegram.org/type/EncryptedMessage for reference.
Example:
g, err := DecodeEncryptedMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *EncryptedMessage: // encryptedMessage#ed18c118
case *EncryptedMessageService: // encryptedMessageService#23734b06
default: panic(v)
}
func DecodeEncryptedMessage ¶
func DecodeEncryptedMessage(buf *bin.Buffer) (EncryptedMessageClass, error)
DecodeEncryptedMessage implements binary de-serialization for EncryptedMessageClass.
type EncryptedMessageService ¶
type EncryptedMessageService struct {
// Random message ID, assigned by the author of message
RandomID int64
// ID of encrypted chat
ChatID int
// Date of sending
Date int
// TL-serialising of DecryptedMessage¹ type, encrypted with the key creatied at stage of chat initialization
//
// Links:
// 1) https://core.telegram.org/type/DecryptedMessage
Bytes []byte
}
EncryptedMessageService represents TL type `encryptedMessageService#23734b06`. Encrypted service message
See https://core.telegram.org/constructor/encryptedMessageService for reference.
func (*EncryptedMessageService) Decode ¶
func (e *EncryptedMessageService) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*EncryptedMessageService) Encode ¶
func (e *EncryptedMessageService) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*EncryptedMessageService) String ¶ added in v0.12.0
func (e *EncryptedMessageService) String() string
String implements fmt.Stringer.
type EncryptedMessagesReadHandler ¶ added in v0.9.0
type EncryptedMessagesReadHandler func(ctx UpdateContext, update *UpdateEncryptedMessagesRead) error
EncryptedMessagesReadHandler is a EncryptedMessagesRead event handler.
type EncryptionHandler ¶ added in v0.9.0
type EncryptionHandler func(ctx UpdateContext, update *UpdateEncryption) error
EncryptionHandler is a Encryption event handler.
type Error ¶
Error represents TL type `error#c4b9f9bb`. Error.
See https://core.telegram.org/constructor/error for reference.
type ExportedChatInviteBox ¶
type ExportedChatInviteBox struct {
ExportedChatInvite ExportedChatInviteClass
}
ExportedChatInvite boxes the ExportedChatInviteClass providing a helper.
type ExportedChatInviteClass ¶
type ExportedChatInviteClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ExportedChatInviteClass represents ExportedChatInvite generic type.
See https://core.telegram.org/type/ExportedChatInvite for reference.
Example:
g, err := DecodeExportedChatInvite(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ChatInviteEmpty: // chatInviteEmpty#69df3769
case *ChatInviteExported: // chatInviteExported#fc2e05bc
default: panic(v)
}
func DecodeExportedChatInvite ¶
func DecodeExportedChatInvite(buf *bin.Buffer) (ExportedChatInviteClass, error)
DecodeExportedChatInvite implements binary de-serialization for ExportedChatInviteClass.
type ExportedMessageLink ¶
ExportedMessageLink represents TL type `exportedMessageLink#5dab1af4`. Link to a message in a supergroup/channel
See https://core.telegram.org/constructor/exportedMessageLink for reference.
func (*ExportedMessageLink) Decode ¶
func (e *ExportedMessageLink) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ExportedMessageLink) Encode ¶
func (e *ExportedMessageLink) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ExportedMessageLink) String ¶ added in v0.12.0
func (e *ExportedMessageLink) String() string
String implements fmt.Stringer.
type FavedStickersHandler ¶ added in v0.9.0
type FavedStickersHandler func(ctx UpdateContext, update *UpdateFavedStickers) error
FavedStickersHandler is a FavedStickers event handler.
type FileHash ¶
type FileHash struct {
// Offset field of FileHash.
Offset int
// Limit field of FileHash.
Limit int
// Hash field of FileHash.
Hash []byte
}
FileHash represents TL type `fileHash#6242c773`.
See https://core.telegram.org/constructor/fileHash for reference.
type FileHashVector ¶ added in v0.8.0
type FileHashVector struct {
// Elements of Vector<FileHash>
Elems []FileHash
}
FileHashVector is a box for Vector<FileHash>
func (*FileHashVector) Decode ¶ added in v0.8.0
func (vec *FileHashVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FileHashVector) Encode ¶ added in v0.8.0
func (vec *FileHashVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FileHashVector) String ¶ added in v0.12.0
func (vec *FileHashVector) String() string
String implements fmt.Stringer.
type FileLocationToBeDeprecated ¶
FileLocationToBeDeprecated represents TL type `fileLocationToBeDeprecated#bc7fc6cd`. Indicates the location of a photo, will be deprecated soon
See https://core.telegram.org/constructor/fileLocationToBeDeprecated for reference.
func (*FileLocationToBeDeprecated) Decode ¶
func (f *FileLocationToBeDeprecated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FileLocationToBeDeprecated) Encode ¶
func (f *FileLocationToBeDeprecated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FileLocationToBeDeprecated) String ¶ added in v0.12.0
func (f *FileLocationToBeDeprecated) String() string
String implements fmt.Stringer.
type Folder ¶
type Folder struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Automatically add new channels to this folder
AutofillNewBroadcasts bool
// Automatically add joined new public supergroups to this folder
AutofillPublicGroups bool
// Automatically add new private chats to this folder
AutofillNewCorrespondents bool
// Folder ID
ID int
// Folder title
Title string
// Folder picture
//
// Use SetPhoto and GetPhoto helpers.
Photo ChatPhotoClass
}
Folder represents TL type `folder#ff544e65`. Folder
See https://core.telegram.org/constructor/folder for reference.
func (*Folder) GetPhoto ¶
func (f *Folder) GetPhoto() (value ChatPhotoClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*Folder) SetAutofillNewBroadcasts ¶
SetAutofillNewBroadcasts sets value of AutofillNewBroadcasts conditional field.
func (*Folder) SetAutofillNewCorrespondents ¶
SetAutofillNewCorrespondents sets value of AutofillNewCorrespondents conditional field.
func (*Folder) SetAutofillPublicGroups ¶
SetAutofillPublicGroups sets value of AutofillPublicGroups conditional field.
func (*Folder) SetPhoto ¶
func (f *Folder) SetPhoto(value ChatPhotoClass)
SetPhoto sets value of Photo conditional field.
type FolderPeer ¶
type FolderPeer struct {
// Folder peer info
Peer PeerClass
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
FolderPeer represents TL type `folderPeer#e9baa668`. Peer in a folder
See https://core.telegram.org/constructor/folderPeer for reference.
func (*FolderPeer) Decode ¶
func (f *FolderPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FolderPeer) Encode ¶
func (f *FolderPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FolderPeer) String ¶ added in v0.12.0
func (f *FolderPeer) String() string
String implements fmt.Stringer.
type FolderPeersHandler ¶ added in v0.9.0
type FolderPeersHandler func(ctx UpdateContext, update *UpdateFolderPeers) error
FolderPeersHandler is a FolderPeers event handler.
type FoldersDeleteFolderRequest ¶
type FoldersDeleteFolderRequest struct {
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
FoldersDeleteFolderRequest represents TL type `folders.deleteFolder#1c295881`. Delete a peer folder¹
Links:
See https://core.telegram.org/method/folders.deleteFolder for reference.
func (*FoldersDeleteFolderRequest) Decode ¶
func (d *FoldersDeleteFolderRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FoldersDeleteFolderRequest) Encode ¶
func (d *FoldersDeleteFolderRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FoldersDeleteFolderRequest) String ¶ added in v0.12.0
func (d *FoldersDeleteFolderRequest) String() string
String implements fmt.Stringer.
type FoldersEditPeerFoldersRequest ¶
type FoldersEditPeerFoldersRequest struct {
// New peer list
FolderPeers []InputFolderPeer
}
FoldersEditPeerFoldersRequest represents TL type `folders.editPeerFolders#6847d0ab`. Edit peers in peer folder¹
Links:
See https://core.telegram.org/method/folders.editPeerFolders for reference.
func (*FoldersEditPeerFoldersRequest) Decode ¶
func (e *FoldersEditPeerFoldersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FoldersEditPeerFoldersRequest) Encode ¶
func (e *FoldersEditPeerFoldersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FoldersEditPeerFoldersRequest) String ¶ added in v0.12.0
func (e *FoldersEditPeerFoldersRequest) String() string
String implements fmt.Stringer.
type Game ¶
type Game struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// ID of the game
ID int64
// Access hash of the game
AccessHash int64
// Short name for the game
ShortName string
// Title of the game
Title string
// Game description
Description string
// Game preview
Photo PhotoClass
// Optional attached document
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
}
Game represents TL type `game#bdf9653b`. Indicates an already sent game
See https://core.telegram.org/constructor/game for reference.
func (*Game) GetDocument ¶
func (g *Game) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*Game) SetDocument ¶
func (g *Game) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
type GeoLiveViewedHandler ¶ added in v0.9.0
type GeoLiveViewedHandler func(ctx UpdateContext, update *UpdateGeoLiveViewed) error
GeoLiveViewedHandler is a GeoLiveViewed event handler.
type GeoPoint ¶
type GeoPoint struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Longtitude
Long float64
// Latitude
Lat float64
// Access hash
AccessHash int64
// The estimated horizontal accuracy of the location, in meters; as defined by the sender.
//
// Use SetAccuracyRadius and GetAccuracyRadius helpers.
AccuracyRadius int
}
GeoPoint represents TL type `geoPoint#b2a2f663`. GeoPoint.
See https://core.telegram.org/constructor/geoPoint for reference.
func (*GeoPoint) GetAccuracyRadius ¶
GetAccuracyRadius returns value of AccuracyRadius conditional field and boolean which is true if field was set.
func (*GeoPoint) SetAccuracyRadius ¶
SetAccuracyRadius sets value of AccuracyRadius conditional field.
type GeoPointBox ¶
type GeoPointBox struct {
GeoPoint GeoPointClass
}
GeoPoint boxes the GeoPointClass providing a helper.
type GeoPointClass ¶
type GeoPointClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
GeoPointClass represents GeoPoint generic type.
See https://core.telegram.org/type/GeoPoint for reference.
Example:
g, err := DecodeGeoPoint(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *GeoPointEmpty: // geoPointEmpty#1117dd5f
case *GeoPoint: // geoPoint#b2a2f663
default: panic(v)
}
func DecodeGeoPoint ¶
func DecodeGeoPoint(buf *bin.Buffer) (GeoPointClass, error)
DecodeGeoPoint implements binary de-serialization for GeoPointClass.
type GeoPointEmpty ¶
type GeoPointEmpty struct {
}
GeoPointEmpty represents TL type `geoPointEmpty#1117dd5f`. Empty constructor.
See https://core.telegram.org/constructor/geoPointEmpty for reference.
func (*GeoPointEmpty) Decode ¶
func (g *GeoPointEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GeoPointEmpty) Encode ¶
func (g *GeoPointEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GeoPointEmpty) String ¶ added in v0.12.0
func (g *GeoPointEmpty) String() string
String implements fmt.Stringer.
type GlobalPrivacySettings ¶
type GlobalPrivacySettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to archive and mute new chats from non-contacts
//
// Use SetArchiveAndMuteNewNoncontactPeers and GetArchiveAndMuteNewNoncontactPeers helpers.
ArchiveAndMuteNewNoncontactPeers bool
}
GlobalPrivacySettings represents TL type `globalPrivacySettings#bea2f424`. Global privacy settings
See https://core.telegram.org/constructor/globalPrivacySettings for reference.
func (*GlobalPrivacySettings) Decode ¶
func (g *GlobalPrivacySettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GlobalPrivacySettings) Encode ¶
func (g *GlobalPrivacySettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GlobalPrivacySettings) GetArchiveAndMuteNewNoncontactPeers ¶ added in v0.17.0
func (g *GlobalPrivacySettings) GetArchiveAndMuteNewNoncontactPeers() (value bool, ok bool)
GetArchiveAndMuteNewNoncontactPeers returns value of ArchiveAndMuteNewNoncontactPeers conditional field and boolean which is true if field was set.
func (*GlobalPrivacySettings) SetArchiveAndMuteNewNoncontactPeers ¶
func (g *GlobalPrivacySettings) SetArchiveAndMuteNewNoncontactPeers(value bool)
SetArchiveAndMuteNewNoncontactPeers sets value of ArchiveAndMuteNewNoncontactPeers conditional field.
func (*GlobalPrivacySettings) String ¶ added in v0.12.0
func (g *GlobalPrivacySettings) String() string
String implements fmt.Stringer.
type GroupCall ¶ added in v0.13.0
type GroupCall struct {
// Flags field of GroupCall.
Flags bin.Fields
// JoinMuted field of GroupCall.
JoinMuted bool
// CanChangeJoinMuted field of GroupCall.
CanChangeJoinMuted bool
// ID field of GroupCall.
ID int64
// AccessHash field of GroupCall.
AccessHash int64
// ParticipantsCount field of GroupCall.
ParticipantsCount int
// Params field of GroupCall.
//
// Use SetParams and GetParams helpers.
Params DataJSON
// Version field of GroupCall.
Version int
}
GroupCall represents TL type `groupCall#55903081`.
See https://core.telegram.org/constructor/groupCall for reference.
func (*GroupCall) GetParams ¶ added in v0.13.0
GetParams returns value of Params conditional field and boolean which is true if field was set.
func (*GroupCall) SetCanChangeJoinMuted ¶ added in v0.13.0
SetCanChangeJoinMuted sets value of CanChangeJoinMuted conditional field.
func (*GroupCall) SetJoinMuted ¶ added in v0.13.0
SetJoinMuted sets value of JoinMuted conditional field.
type GroupCallBox ¶ added in v0.13.0
type GroupCallBox struct {
GroupCall GroupCallClass
}
GroupCall boxes the GroupCallClass providing a helper.
type GroupCallClass ¶ added in v0.13.0
type GroupCallClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
GroupCallClass represents GroupCall generic type.
See https://core.telegram.org/type/GroupCall for reference.
Example:
g, err := DecodeGroupCall(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *GroupCallDiscarded: // groupCallDiscarded#7780bcb4
case *GroupCall: // groupCall#55903081
default: panic(v)
}
func DecodeGroupCall ¶ added in v0.13.0
func DecodeGroupCall(buf *bin.Buffer) (GroupCallClass, error)
DecodeGroupCall implements binary de-serialization for GroupCallClass.
type GroupCallDiscarded ¶ added in v0.13.0
type GroupCallDiscarded struct {
// ID field of GroupCallDiscarded.
ID int64
// AccessHash field of GroupCallDiscarded.
AccessHash int64
// Duration field of GroupCallDiscarded.
Duration int
}
GroupCallDiscarded represents TL type `groupCallDiscarded#7780bcb4`.
See https://core.telegram.org/constructor/groupCallDiscarded for reference.
func (*GroupCallDiscarded) Decode ¶ added in v0.13.0
func (g *GroupCallDiscarded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GroupCallDiscarded) Encode ¶ added in v0.13.0
func (g *GroupCallDiscarded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GroupCallDiscarded) String ¶ added in v0.13.0
func (g *GroupCallDiscarded) String() string
String implements fmt.Stringer.
type GroupCallHandler ¶ added in v0.13.0
type GroupCallHandler func(ctx UpdateContext, update *UpdateGroupCall) error
GroupCallHandler is a GroupCall event handler.
type GroupCallParticipant ¶ added in v0.13.0
type GroupCallParticipant struct {
// Flags field of GroupCallParticipant.
Flags bin.Fields
// Muted field of GroupCallParticipant.
Muted bool
// Left field of GroupCallParticipant.
Left bool
// CanSelfUnmute field of GroupCallParticipant.
CanSelfUnmute bool
// JustJoined field of GroupCallParticipant.
JustJoined bool
// Versioned field of GroupCallParticipant.
Versioned bool
// UserID field of GroupCallParticipant.
UserID int
// Date field of GroupCallParticipant.
Date int
// ActiveDate field of GroupCallParticipant.
//
// Use SetActiveDate and GetActiveDate helpers.
ActiveDate int
// Source field of GroupCallParticipant.
Source int
}
GroupCallParticipant represents TL type `groupCallParticipant#56b087c9`.
See https://core.telegram.org/constructor/groupCallParticipant for reference.
func (*GroupCallParticipant) Decode ¶ added in v0.13.0
func (g *GroupCallParticipant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GroupCallParticipant) Encode ¶ added in v0.13.0
func (g *GroupCallParticipant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GroupCallParticipant) GetActiveDate ¶ added in v0.13.0
func (g *GroupCallParticipant) GetActiveDate() (value int, ok bool)
GetActiveDate returns value of ActiveDate conditional field and boolean which is true if field was set.
func (*GroupCallParticipant) SetActiveDate ¶ added in v0.13.0
func (g *GroupCallParticipant) SetActiveDate(value int)
SetActiveDate sets value of ActiveDate conditional field.
func (*GroupCallParticipant) SetCanSelfUnmute ¶ added in v0.13.0
func (g *GroupCallParticipant) SetCanSelfUnmute(value bool)
SetCanSelfUnmute sets value of CanSelfUnmute conditional field.
func (*GroupCallParticipant) SetJustJoined ¶ added in v0.13.0
func (g *GroupCallParticipant) SetJustJoined(value bool)
SetJustJoined sets value of JustJoined conditional field.
func (*GroupCallParticipant) SetLeft ¶ added in v0.13.0
func (g *GroupCallParticipant) SetLeft(value bool)
SetLeft sets value of Left conditional field.
func (*GroupCallParticipant) SetMuted ¶ added in v0.13.0
func (g *GroupCallParticipant) SetMuted(value bool)
SetMuted sets value of Muted conditional field.
func (*GroupCallParticipant) SetVersioned ¶ added in v0.13.0
func (g *GroupCallParticipant) SetVersioned(value bool)
SetVersioned sets value of Versioned conditional field.
func (*GroupCallParticipant) String ¶ added in v0.13.0
func (g *GroupCallParticipant) String() string
String implements fmt.Stringer.
type GroupCallParticipantsHandler ¶ added in v0.13.0
type GroupCallParticipantsHandler func(ctx UpdateContext, update *UpdateGroupCallParticipants) error
GroupCallParticipantsHandler is a GroupCallParticipants event handler.
type HelpAcceptTermsOfServiceRequest ¶
type HelpAcceptTermsOfServiceRequest struct {
// ID of terms of service
ID DataJSON
}
HelpAcceptTermsOfServiceRequest represents TL type `help.acceptTermsOfService#ee72f79a`. Accept the new terms of service
See https://core.telegram.org/method/help.acceptTermsOfService for reference.
func (*HelpAcceptTermsOfServiceRequest) Decode ¶
func (a *HelpAcceptTermsOfServiceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpAcceptTermsOfServiceRequest) Encode ¶
func (a *HelpAcceptTermsOfServiceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpAcceptTermsOfServiceRequest) String ¶ added in v0.12.0
func (a *HelpAcceptTermsOfServiceRequest) String() string
String implements fmt.Stringer.
type HelpAppUpdate ¶
type HelpAppUpdate struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Unskippable, the new info must be shown to the user (with a popup or something else)
CanNotSkip bool
// Update ID
ID int
// New version name
Version string
// Text description of the update
Text string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
Entities []MessageEntityClass
// Application binary
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
// Application download URL
//
// Use SetURL and GetURL helpers.
URL string
}
HelpAppUpdate represents TL type `help.appUpdate#1da7158f`. An update is available for the application.
See https://core.telegram.org/constructor/help.appUpdate for reference.
func (*HelpAppUpdate) Decode ¶
func (a *HelpAppUpdate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpAppUpdate) Encode ¶
func (a *HelpAppUpdate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpAppUpdate) GetDocument ¶
func (a *HelpAppUpdate) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*HelpAppUpdate) GetURL ¶
func (a *HelpAppUpdate) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*HelpAppUpdate) SetCanNotSkip ¶
func (a *HelpAppUpdate) SetCanNotSkip(value bool)
SetCanNotSkip sets value of CanNotSkip conditional field.
func (*HelpAppUpdate) SetDocument ¶
func (a *HelpAppUpdate) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
func (*HelpAppUpdate) SetURL ¶
func (a *HelpAppUpdate) SetURL(value string)
SetURL sets value of URL conditional field.
func (*HelpAppUpdate) String ¶ added in v0.12.0
func (a *HelpAppUpdate) String() string
String implements fmt.Stringer.
type HelpAppUpdateBox ¶
type HelpAppUpdateBox struct {
AppUpdate HelpAppUpdateClass
}
HelpAppUpdate boxes the HelpAppUpdateClass providing a helper.
type HelpAppUpdateClass ¶
type HelpAppUpdateClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpAppUpdateClass represents help.AppUpdate generic type.
See https://core.telegram.org/type/help.AppUpdate for reference.
Example:
g, err := DecodeHelpAppUpdate(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpAppUpdate: // help.appUpdate#1da7158f
case *HelpNoAppUpdate: // help.noAppUpdate#c45a6536
default: panic(v)
}
func DecodeHelpAppUpdate ¶
func DecodeHelpAppUpdate(buf *bin.Buffer) (HelpAppUpdateClass, error)
DecodeHelpAppUpdate implements binary de-serialization for HelpAppUpdateClass.
type HelpCountriesList ¶
type HelpCountriesList struct {
// Name, ISO code, localized name and phone codes/patterns of all available countries
Countries []HelpCountry
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
HelpCountriesList represents TL type `help.countriesList#87d0759e`. Name, ISO code, localized name and phone codes/patterns of all available countries
See https://core.telegram.org/constructor/help.countriesList for reference.
func (*HelpCountriesList) Decode ¶
func (c *HelpCountriesList) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpCountriesList) Encode ¶
func (c *HelpCountriesList) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpCountriesList) String ¶ added in v0.12.0
func (c *HelpCountriesList) String() string
String implements fmt.Stringer.
type HelpCountriesListBox ¶
type HelpCountriesListBox struct {
CountriesList HelpCountriesListClass
}
HelpCountriesList boxes the HelpCountriesListClass providing a helper.
type HelpCountriesListClass ¶
type HelpCountriesListClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpCountriesListClass represents help.CountriesList generic type.
See https://core.telegram.org/type/help.CountriesList for reference.
Example:
g, err := DecodeHelpCountriesList(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpCountriesListNotModified: // help.countriesListNotModified#93cc1f32
case *HelpCountriesList: // help.countriesList#87d0759e
default: panic(v)
}
func DecodeHelpCountriesList ¶
func DecodeHelpCountriesList(buf *bin.Buffer) (HelpCountriesListClass, error)
DecodeHelpCountriesList implements binary de-serialization for HelpCountriesListClass.
type HelpCountriesListNotModified ¶
type HelpCountriesListNotModified struct {
}
HelpCountriesListNotModified represents TL type `help.countriesListNotModified#93cc1f32`. The country list has not changed
See https://core.telegram.org/constructor/help.countriesListNotModified for reference.
func (*HelpCountriesListNotModified) Decode ¶
func (c *HelpCountriesListNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpCountriesListNotModified) Encode ¶
func (c *HelpCountriesListNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpCountriesListNotModified) String ¶ added in v0.12.0
func (c *HelpCountriesListNotModified) String() string
String implements fmt.Stringer.
type HelpCountry ¶
type HelpCountry struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this country should not be shown in the list
Hidden bool
// ISO code of country
Iso2 string
// Name of the country in the country's language
DefaultName string
// Name of the country in the user's language, if different from the original name
//
// Use SetName and GetName helpers.
Name string
// Phone codes/patterns
CountryCodes []HelpCountryCode
}
HelpCountry represents TL type `help.country#c3878e23`. Name, ISO code, localized name and phone codes/patterns of a specific country
See https://core.telegram.org/constructor/help.country for reference.
func (*HelpCountry) Decode ¶
func (c *HelpCountry) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpCountry) Encode ¶
func (c *HelpCountry) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpCountry) GetName ¶
func (c *HelpCountry) GetName() (value string, ok bool)
GetName returns value of Name conditional field and boolean which is true if field was set.
func (*HelpCountry) SetHidden ¶
func (c *HelpCountry) SetHidden(value bool)
SetHidden sets value of Hidden conditional field.
func (*HelpCountry) SetName ¶
func (c *HelpCountry) SetName(value string)
SetName sets value of Name conditional field.
func (*HelpCountry) String ¶ added in v0.12.0
func (c *HelpCountry) String() string
String implements fmt.Stringer.
type HelpCountryCode ¶
type HelpCountryCode struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// ISO country code
CountryCode string
// Possible phone prefixes
//
// Use SetPrefixes and GetPrefixes helpers.
Prefixes []string
// Phone patterns: for example, XXX XXX XXX
//
// Use SetPatterns and GetPatterns helpers.
Patterns []string
}
HelpCountryCode represents TL type `help.countryCode#4203c5ef`. Country code and phone number pattern of a specific country
See https://core.telegram.org/constructor/help.countryCode for reference.
func (*HelpCountryCode) Decode ¶
func (c *HelpCountryCode) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpCountryCode) Encode ¶
func (c *HelpCountryCode) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpCountryCode) GetPatterns ¶
func (c *HelpCountryCode) GetPatterns() (value []string, ok bool)
GetPatterns returns value of Patterns conditional field and boolean which is true if field was set.
func (*HelpCountryCode) GetPrefixes ¶
func (c *HelpCountryCode) GetPrefixes() (value []string, ok bool)
GetPrefixes returns value of Prefixes conditional field and boolean which is true if field was set.
func (*HelpCountryCode) SetPatterns ¶
func (c *HelpCountryCode) SetPatterns(value []string)
SetPatterns sets value of Patterns conditional field.
func (*HelpCountryCode) SetPrefixes ¶
func (c *HelpCountryCode) SetPrefixes(value []string)
SetPrefixes sets value of Prefixes conditional field.
func (*HelpCountryCode) String ¶ added in v0.12.0
func (c *HelpCountryCode) String() string
String implements fmt.Stringer.
type HelpDeepLinkInfo ¶
type HelpDeepLinkInfo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// An update of the app is required to parse this link
UpdateApp bool
// Message to show to the user
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
HelpDeepLinkInfo represents TL type `help.deepLinkInfo#6a4ee832`. Deep linking info
See https://core.telegram.org/constructor/help.deepLinkInfo for reference.
func (*HelpDeepLinkInfo) Decode ¶
func (d *HelpDeepLinkInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpDeepLinkInfo) Encode ¶
func (d *HelpDeepLinkInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpDeepLinkInfo) GetEntities ¶
func (d *HelpDeepLinkInfo) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*HelpDeepLinkInfo) SetEntities ¶
func (d *HelpDeepLinkInfo) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*HelpDeepLinkInfo) SetUpdateApp ¶
func (d *HelpDeepLinkInfo) SetUpdateApp(value bool)
SetUpdateApp sets value of UpdateApp conditional field.
func (*HelpDeepLinkInfo) String ¶ added in v0.12.0
func (d *HelpDeepLinkInfo) String() string
String implements fmt.Stringer.
type HelpDeepLinkInfoBox ¶
type HelpDeepLinkInfoBox struct {
DeepLinkInfo HelpDeepLinkInfoClass
}
HelpDeepLinkInfo boxes the HelpDeepLinkInfoClass providing a helper.
type HelpDeepLinkInfoClass ¶
type HelpDeepLinkInfoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpDeepLinkInfoClass represents help.DeepLinkInfo generic type.
See https://core.telegram.org/type/help.DeepLinkInfo for reference.
Example:
g, err := DecodeHelpDeepLinkInfo(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpDeepLinkInfoEmpty: // help.deepLinkInfoEmpty#66afa166
case *HelpDeepLinkInfo: // help.deepLinkInfo#6a4ee832
default: panic(v)
}
func DecodeHelpDeepLinkInfo ¶
func DecodeHelpDeepLinkInfo(buf *bin.Buffer) (HelpDeepLinkInfoClass, error)
DecodeHelpDeepLinkInfo implements binary de-serialization for HelpDeepLinkInfoClass.
type HelpDeepLinkInfoEmpty ¶
type HelpDeepLinkInfoEmpty struct {
}
HelpDeepLinkInfoEmpty represents TL type `help.deepLinkInfoEmpty#66afa166`. Deep link info empty
See https://core.telegram.org/constructor/help.deepLinkInfoEmpty for reference.
func (*HelpDeepLinkInfoEmpty) Decode ¶
func (d *HelpDeepLinkInfoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpDeepLinkInfoEmpty) Encode ¶
func (d *HelpDeepLinkInfoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpDeepLinkInfoEmpty) String ¶ added in v0.12.0
func (d *HelpDeepLinkInfoEmpty) String() string
String implements fmt.Stringer.
type HelpDismissSuggestionRequest ¶
type HelpDismissSuggestionRequest struct {
// Suggestion
Suggestion string
}
HelpDismissSuggestionRequest represents TL type `help.dismissSuggestion#77fa99f`. Dismiss a suggestion
See https://core.telegram.org/method/help.dismissSuggestion for reference.
func (*HelpDismissSuggestionRequest) Decode ¶
func (d *HelpDismissSuggestionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpDismissSuggestionRequest) Encode ¶
func (d *HelpDismissSuggestionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpDismissSuggestionRequest) String ¶ added in v0.12.0
func (d *HelpDismissSuggestionRequest) String() string
String implements fmt.Stringer.
type HelpEditUserInfoRequest ¶
type HelpEditUserInfoRequest struct {
// User
UserID InputUserClass
// Message
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
Entities []MessageEntityClass
}
HelpEditUserInfoRequest represents TL type `help.editUserInfo#66b91b70`. Internal use
See https://core.telegram.org/method/help.editUserInfo for reference.
func (*HelpEditUserInfoRequest) Decode ¶
func (e *HelpEditUserInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpEditUserInfoRequest) Encode ¶
func (e *HelpEditUserInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpEditUserInfoRequest) String ¶ added in v0.12.0
func (e *HelpEditUserInfoRequest) String() string
String implements fmt.Stringer.
type HelpGetAppChangelogRequest ¶
type HelpGetAppChangelogRequest struct {
// Previous app version
PrevAppVersion string
}
HelpGetAppChangelogRequest represents TL type `help.getAppChangelog#9010ef6f`. Get changelog of current app. Typically, an updates¹ constructor will be returned, containing one or more updateServiceNotification² updates with app-specific changelogs.
Links:
- https://core.telegram.org/constructor/updates
- https://core.telegram.org/constructor/updateServiceNotification
See https://core.telegram.org/method/help.getAppChangelog for reference.
func (*HelpGetAppChangelogRequest) Decode ¶
func (g *HelpGetAppChangelogRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetAppChangelogRequest) Encode ¶
func (g *HelpGetAppChangelogRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetAppChangelogRequest) String ¶ added in v0.12.0
func (g *HelpGetAppChangelogRequest) String() string
String implements fmt.Stringer.
type HelpGetAppConfigRequest ¶
type HelpGetAppConfigRequest struct {
}
HelpGetAppConfigRequest represents TL type `help.getAppConfig#98914110`. Get app-specific configuration, see client configuration¹ for more info on the result.
Links:
See https://core.telegram.org/method/help.getAppConfig for reference.
func (*HelpGetAppConfigRequest) Decode ¶
func (g *HelpGetAppConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetAppConfigRequest) Encode ¶
func (g *HelpGetAppConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetAppConfigRequest) String ¶ added in v0.12.0
func (g *HelpGetAppConfigRequest) String() string
String implements fmt.Stringer.
type HelpGetAppUpdateRequest ¶
type HelpGetAppUpdateRequest struct {
// Source
Source string
}
HelpGetAppUpdateRequest represents TL type `help.getAppUpdate#522d5a7d`. Returns information on update availability for the current application.
See https://core.telegram.org/method/help.getAppUpdate for reference.
func (*HelpGetAppUpdateRequest) Decode ¶
func (g *HelpGetAppUpdateRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetAppUpdateRequest) Encode ¶
func (g *HelpGetAppUpdateRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetAppUpdateRequest) String ¶ added in v0.12.0
func (g *HelpGetAppUpdateRequest) String() string
String implements fmt.Stringer.
type HelpGetCdnConfigRequest ¶
type HelpGetCdnConfigRequest struct {
}
HelpGetCdnConfigRequest represents TL type `help.getCdnConfig#52029342`. Get configuration for CDN¹ file downloads.
Links:
See https://core.telegram.org/method/help.getCdnConfig for reference.
func (*HelpGetCdnConfigRequest) Decode ¶
func (g *HelpGetCdnConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetCdnConfigRequest) Encode ¶
func (g *HelpGetCdnConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetCdnConfigRequest) String ¶ added in v0.12.0
func (g *HelpGetCdnConfigRequest) String() string
String implements fmt.Stringer.
type HelpGetConfigRequest ¶
type HelpGetConfigRequest struct {
}
HelpGetConfigRequest represents TL type `help.getConfig#c4f9186b`. Returns current configuration, including data center configuration.
See https://core.telegram.org/method/help.getConfig for reference.
func (*HelpGetConfigRequest) Decode ¶
func (g *HelpGetConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetConfigRequest) Encode ¶
func (g *HelpGetConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetConfigRequest) String ¶ added in v0.12.0
func (g *HelpGetConfigRequest) String() string
String implements fmt.Stringer.
type HelpGetCountriesListRequest ¶
type HelpGetCountriesListRequest struct {
// Language code of the current user
LangCode string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
HelpGetCountriesListRequest represents TL type `help.getCountriesList#735787a8`. Get name, ISO code, localized name and phone codes/patterns of all available countries
See https://core.telegram.org/method/help.getCountriesList for reference.
func (*HelpGetCountriesListRequest) Decode ¶
func (g *HelpGetCountriesListRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetCountriesListRequest) Encode ¶
func (g *HelpGetCountriesListRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetCountriesListRequest) String ¶ added in v0.12.0
func (g *HelpGetCountriesListRequest) String() string
String implements fmt.Stringer.
type HelpGetDeepLinkInfoRequest ¶
type HelpGetDeepLinkInfoRequest struct {
// Path in t.me/path
Path string
}
HelpGetDeepLinkInfoRequest represents TL type `help.getDeepLinkInfo#3fedc75f`. Get info about a t.me link
See https://core.telegram.org/method/help.getDeepLinkInfo for reference.
func (*HelpGetDeepLinkInfoRequest) Decode ¶
func (g *HelpGetDeepLinkInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetDeepLinkInfoRequest) Encode ¶
func (g *HelpGetDeepLinkInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetDeepLinkInfoRequest) String ¶ added in v0.12.0
func (g *HelpGetDeepLinkInfoRequest) String() string
String implements fmt.Stringer.
type HelpGetInviteTextRequest ¶
type HelpGetInviteTextRequest struct {
}
HelpGetInviteTextRequest represents TL type `help.getInviteText#4d392343`. Returns localized text of a text message with an invitation.
See https://core.telegram.org/method/help.getInviteText for reference.
func (*HelpGetInviteTextRequest) Decode ¶
func (g *HelpGetInviteTextRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetInviteTextRequest) Encode ¶
func (g *HelpGetInviteTextRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetInviteTextRequest) String ¶ added in v0.12.0
func (g *HelpGetInviteTextRequest) String() string
String implements fmt.Stringer.
type HelpGetNearestDcRequest ¶
type HelpGetNearestDcRequest struct {
}
HelpGetNearestDcRequest represents TL type `help.getNearestDc#1fb33026`. Returns info on data centre nearest to the user.
See https://core.telegram.org/method/help.getNearestDc for reference.
func (*HelpGetNearestDcRequest) Decode ¶
func (g *HelpGetNearestDcRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetNearestDcRequest) Encode ¶
func (g *HelpGetNearestDcRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetNearestDcRequest) String ¶ added in v0.12.0
func (g *HelpGetNearestDcRequest) String() string
String implements fmt.Stringer.
type HelpGetPassportConfigRequest ¶
type HelpGetPassportConfigRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
HelpGetPassportConfigRequest represents TL type `help.getPassportConfig#c661ad08`. Get passport¹ configuration
Links:
See https://core.telegram.org/method/help.getPassportConfig for reference.
func (*HelpGetPassportConfigRequest) Decode ¶
func (g *HelpGetPassportConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetPassportConfigRequest) Encode ¶
func (g *HelpGetPassportConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetPassportConfigRequest) String ¶ added in v0.12.0
func (g *HelpGetPassportConfigRequest) String() string
String implements fmt.Stringer.
type HelpGetPromoDataRequest ¶
type HelpGetPromoDataRequest struct {
}
HelpGetPromoDataRequest represents TL type `help.getPromoData#c0977421`. Get MTProxy/Public Service Announcement information
See https://core.telegram.org/method/help.getPromoData for reference.
func (*HelpGetPromoDataRequest) Decode ¶
func (g *HelpGetPromoDataRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetPromoDataRequest) Encode ¶
func (g *HelpGetPromoDataRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetPromoDataRequest) String ¶ added in v0.12.0
func (g *HelpGetPromoDataRequest) String() string
String implements fmt.Stringer.
type HelpGetRecentMeUrlsRequest ¶
type HelpGetRecentMeUrlsRequest struct {
// Referer
Referer string
}
HelpGetRecentMeUrlsRequest represents TL type `help.getRecentMeUrls#3dc0f114`. Get recently used t.me links
See https://core.telegram.org/method/help.getRecentMeUrls for reference.
func (*HelpGetRecentMeUrlsRequest) Decode ¶
func (g *HelpGetRecentMeUrlsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetRecentMeUrlsRequest) Encode ¶
func (g *HelpGetRecentMeUrlsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetRecentMeUrlsRequest) String ¶ added in v0.12.0
func (g *HelpGetRecentMeUrlsRequest) String() string
String implements fmt.Stringer.
type HelpGetSupportNameRequest ¶
type HelpGetSupportNameRequest struct {
}
HelpGetSupportNameRequest represents TL type `help.getSupportName#d360e72c`. Get localized name of the telegram support user
See https://core.telegram.org/method/help.getSupportName for reference.
func (*HelpGetSupportNameRequest) Decode ¶
func (g *HelpGetSupportNameRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetSupportNameRequest) Encode ¶
func (g *HelpGetSupportNameRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetSupportNameRequest) String ¶ added in v0.12.0
func (g *HelpGetSupportNameRequest) String() string
String implements fmt.Stringer.
type HelpGetSupportRequest ¶
type HelpGetSupportRequest struct {
}
HelpGetSupportRequest represents TL type `help.getSupport#9cdf08cd`. Returns the support user for the 'ask a question' feature.
See https://core.telegram.org/method/help.getSupport for reference.
func (*HelpGetSupportRequest) Decode ¶
func (g *HelpGetSupportRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetSupportRequest) Encode ¶
func (g *HelpGetSupportRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetSupportRequest) String ¶ added in v0.12.0
func (g *HelpGetSupportRequest) String() string
String implements fmt.Stringer.
type HelpGetTermsOfServiceUpdateRequest ¶
type HelpGetTermsOfServiceUpdateRequest struct {
}
HelpGetTermsOfServiceUpdateRequest represents TL type `help.getTermsOfServiceUpdate#2ca51fd1`. Look for updates of telegram's terms of service
See https://core.telegram.org/method/help.getTermsOfServiceUpdate for reference.
func (*HelpGetTermsOfServiceUpdateRequest) Decode ¶
func (g *HelpGetTermsOfServiceUpdateRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetTermsOfServiceUpdateRequest) Encode ¶
func (g *HelpGetTermsOfServiceUpdateRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetTermsOfServiceUpdateRequest) String ¶ added in v0.12.0
func (g *HelpGetTermsOfServiceUpdateRequest) String() string
String implements fmt.Stringer.
type HelpGetUserInfoRequest ¶
type HelpGetUserInfoRequest struct {
// User ID
UserID InputUserClass
}
HelpGetUserInfoRequest represents TL type `help.getUserInfo#38a08d3`. Internal use
See https://core.telegram.org/method/help.getUserInfo for reference.
func (*HelpGetUserInfoRequest) Decode ¶
func (g *HelpGetUserInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpGetUserInfoRequest) Encode ¶
func (g *HelpGetUserInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpGetUserInfoRequest) String ¶ added in v0.12.0
func (g *HelpGetUserInfoRequest) String() string
String implements fmt.Stringer.
type HelpHidePromoDataRequest ¶
type HelpHidePromoDataRequest struct {
// Peer to hide
Peer InputPeerClass
}
HelpHidePromoDataRequest represents TL type `help.hidePromoData#1e251c95`. Hide MTProxy/Public Service Announcement information
See https://core.telegram.org/method/help.hidePromoData for reference.
func (*HelpHidePromoDataRequest) Decode ¶
func (h *HelpHidePromoDataRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpHidePromoDataRequest) Encode ¶
func (h *HelpHidePromoDataRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpHidePromoDataRequest) String ¶ added in v0.12.0
func (h *HelpHidePromoDataRequest) String() string
String implements fmt.Stringer.
type HelpInviteText ¶
type HelpInviteText struct {
// Text of the message
Message string
}
HelpInviteText represents TL type `help.inviteText#18cb9f78`. Text of a text message with an invitation to install Telegram.
See https://core.telegram.org/constructor/help.inviteText for reference.
func (*HelpInviteText) Decode ¶
func (i *HelpInviteText) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpInviteText) Encode ¶
func (i *HelpInviteText) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpInviteText) String ¶ added in v0.12.0
func (i *HelpInviteText) String() string
String implements fmt.Stringer.
type HelpNoAppUpdate ¶
type HelpNoAppUpdate struct {
}
HelpNoAppUpdate represents TL type `help.noAppUpdate#c45a6536`. No updates are available for the application.
See https://core.telegram.org/constructor/help.noAppUpdate for reference.
func (*HelpNoAppUpdate) Decode ¶
func (n *HelpNoAppUpdate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpNoAppUpdate) Encode ¶
func (n *HelpNoAppUpdate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpNoAppUpdate) String ¶ added in v0.12.0
func (n *HelpNoAppUpdate) String() string
String implements fmt.Stringer.
type HelpPassportConfig ¶
type HelpPassportConfig struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Localization
CountriesLangs DataJSON
}
HelpPassportConfig represents TL type `help.passportConfig#a098d6af`. Telegram passport¹ configuration
Links:
See https://core.telegram.org/constructor/help.passportConfig for reference.
func (*HelpPassportConfig) Decode ¶
func (p *HelpPassportConfig) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpPassportConfig) Encode ¶
func (p *HelpPassportConfig) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpPassportConfig) String ¶ added in v0.12.0
func (p *HelpPassportConfig) String() string
String implements fmt.Stringer.
type HelpPassportConfigBox ¶
type HelpPassportConfigBox struct {
PassportConfig HelpPassportConfigClass
}
HelpPassportConfig boxes the HelpPassportConfigClass providing a helper.
type HelpPassportConfigClass ¶
type HelpPassportConfigClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpPassportConfigClass represents help.PassportConfig generic type.
See https://core.telegram.org/type/help.PassportConfig for reference.
Example:
g, err := DecodeHelpPassportConfig(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpPassportConfigNotModified: // help.passportConfigNotModified#bfb9f457
case *HelpPassportConfig: // help.passportConfig#a098d6af
default: panic(v)
}
func DecodeHelpPassportConfig ¶
func DecodeHelpPassportConfig(buf *bin.Buffer) (HelpPassportConfigClass, error)
DecodeHelpPassportConfig implements binary de-serialization for HelpPassportConfigClass.
type HelpPassportConfigNotModified ¶
type HelpPassportConfigNotModified struct {
}
HelpPassportConfigNotModified represents TL type `help.passportConfigNotModified#bfb9f457`. Password configuration not modified
See https://core.telegram.org/constructor/help.passportConfigNotModified for reference.
func (*HelpPassportConfigNotModified) Decode ¶
func (p *HelpPassportConfigNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpPassportConfigNotModified) Encode ¶
func (p *HelpPassportConfigNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpPassportConfigNotModified) String ¶ added in v0.12.0
func (p *HelpPassportConfigNotModified) String() string
String implements fmt.Stringer.
type HelpPromoData ¶
type HelpPromoData struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// MTProxy-related channel
Proxy bool
// Expiry of PSA/MTProxy info
Expires int
// MTProxy/PSA peer
Peer PeerClass
// Chat info
Chats []ChatClass
// User info
Users []UserClass
// PSA type
//
// Use SetPsaType and GetPsaType helpers.
PsaType string
// PSA message
//
// Use SetPsaMessage and GetPsaMessage helpers.
PsaMessage string
}
HelpPromoData represents TL type `help.promoData#8c39793f`. MTProxy/Public Service Announcement information
See https://core.telegram.org/constructor/help.promoData for reference.
func (*HelpPromoData) Decode ¶
func (p *HelpPromoData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpPromoData) Encode ¶
func (p *HelpPromoData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpPromoData) GetPsaMessage ¶
func (p *HelpPromoData) GetPsaMessage() (value string, ok bool)
GetPsaMessage returns value of PsaMessage conditional field and boolean which is true if field was set.
func (*HelpPromoData) GetPsaType ¶
func (p *HelpPromoData) GetPsaType() (value string, ok bool)
GetPsaType returns value of PsaType conditional field and boolean which is true if field was set.
func (*HelpPromoData) SetProxy ¶
func (p *HelpPromoData) SetProxy(value bool)
SetProxy sets value of Proxy conditional field.
func (*HelpPromoData) SetPsaMessage ¶
func (p *HelpPromoData) SetPsaMessage(value string)
SetPsaMessage sets value of PsaMessage conditional field.
func (*HelpPromoData) SetPsaType ¶
func (p *HelpPromoData) SetPsaType(value string)
SetPsaType sets value of PsaType conditional field.
func (*HelpPromoData) String ¶ added in v0.12.0
func (p *HelpPromoData) String() string
String implements fmt.Stringer.
type HelpPromoDataBox ¶
type HelpPromoDataBox struct {
PromoData HelpPromoDataClass
}
HelpPromoData boxes the HelpPromoDataClass providing a helper.
type HelpPromoDataClass ¶
type HelpPromoDataClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpPromoDataClass represents help.PromoData generic type.
See https://core.telegram.org/type/help.PromoData for reference.
Example:
g, err := DecodeHelpPromoData(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpPromoDataEmpty: // help.promoDataEmpty#98f6ac75
case *HelpPromoData: // help.promoData#8c39793f
default: panic(v)
}
func DecodeHelpPromoData ¶
func DecodeHelpPromoData(buf *bin.Buffer) (HelpPromoDataClass, error)
DecodeHelpPromoData implements binary de-serialization for HelpPromoDataClass.
type HelpPromoDataEmpty ¶
type HelpPromoDataEmpty struct {
// Re-fetch PSA/MTProxy info after the specified number of seconds
Expires int
}
HelpPromoDataEmpty represents TL type `help.promoDataEmpty#98f6ac75`. No PSA/MTProxy info is available
See https://core.telegram.org/constructor/help.promoDataEmpty for reference.
func (*HelpPromoDataEmpty) Decode ¶
func (p *HelpPromoDataEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpPromoDataEmpty) Encode ¶
func (p *HelpPromoDataEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpPromoDataEmpty) String ¶ added in v0.12.0
func (p *HelpPromoDataEmpty) String() string
String implements fmt.Stringer.
type HelpRecentMeUrls ¶
type HelpRecentMeUrls struct {
// URLs
Urls []RecentMeUrlClass
// Chats
Chats []ChatClass
// Users
Users []UserClass
}
HelpRecentMeUrls represents TL type `help.recentMeUrls#e0310d7`. Recent t.me URLs
See https://core.telegram.org/constructor/help.recentMeUrls for reference.
func (*HelpRecentMeUrls) Decode ¶
func (r *HelpRecentMeUrls) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpRecentMeUrls) Encode ¶
func (r *HelpRecentMeUrls) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpRecentMeUrls) String ¶ added in v0.12.0
func (r *HelpRecentMeUrls) String() string
String implements fmt.Stringer.
type HelpSaveAppLogRequest ¶
type HelpSaveAppLogRequest struct {
// List of input events
Events []InputAppEvent
}
HelpSaveAppLogRequest represents TL type `help.saveAppLog#6f02f748`. Saves logs of application on the server.
See https://core.telegram.org/method/help.saveAppLog for reference.
func (*HelpSaveAppLogRequest) Decode ¶
func (s *HelpSaveAppLogRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpSaveAppLogRequest) Encode ¶
func (s *HelpSaveAppLogRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpSaveAppLogRequest) String ¶ added in v0.12.0
func (s *HelpSaveAppLogRequest) String() string
String implements fmt.Stringer.
type HelpSetBotUpdatesStatusRequest ¶
type HelpSetBotUpdatesStatusRequest struct {
// Number of pending updates
PendingUpdatesCount int
// Error message, if present
Message string
}
HelpSetBotUpdatesStatusRequest represents TL type `help.setBotUpdatesStatus#ec22cfcd`. Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only
See https://core.telegram.org/method/help.setBotUpdatesStatus for reference.
func (*HelpSetBotUpdatesStatusRequest) Decode ¶
func (s *HelpSetBotUpdatesStatusRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpSetBotUpdatesStatusRequest) Encode ¶
func (s *HelpSetBotUpdatesStatusRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpSetBotUpdatesStatusRequest) String ¶ added in v0.12.0
func (s *HelpSetBotUpdatesStatusRequest) String() string
String implements fmt.Stringer.
type HelpSupport ¶
HelpSupport represents TL type `help.support#17c6b5f6`. Info on support user.
See https://core.telegram.org/constructor/help.support for reference.
func (*HelpSupport) Decode ¶
func (s *HelpSupport) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpSupport) Encode ¶
func (s *HelpSupport) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpSupport) String ¶ added in v0.12.0
func (s *HelpSupport) String() string
String implements fmt.Stringer.
type HelpSupportName ¶
type HelpSupportName struct {
// Localized name
Name string
}
HelpSupportName represents TL type `help.supportName#8c05f1c9`. Localized name for telegram support
See https://core.telegram.org/constructor/help.supportName for reference.
func (*HelpSupportName) Decode ¶
func (s *HelpSupportName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpSupportName) Encode ¶
func (s *HelpSupportName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpSupportName) String ¶ added in v0.12.0
func (s *HelpSupportName) String() string
String implements fmt.Stringer.
type HelpTermsOfService ¶
type HelpTermsOfService struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether a prompt must be showed to the user, in order to accept the new terms.
Popup bool
// ID of the new terms
ID DataJSON
// Text of the new terms
Text string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
Entities []MessageEntityClass
// Minimum age required to sign up to telegram, the user must confirm that they is older than the minimum age.
//
// Use SetMinAgeConfirm and GetMinAgeConfirm helpers.
MinAgeConfirm int
}
HelpTermsOfService represents TL type `help.termsOfService#780a0310`. Info about the latest telegram Terms Of Service
See https://core.telegram.org/constructor/help.termsOfService for reference.
func (*HelpTermsOfService) Decode ¶
func (t *HelpTermsOfService) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpTermsOfService) Encode ¶
func (t *HelpTermsOfService) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpTermsOfService) GetMinAgeConfirm ¶
func (t *HelpTermsOfService) GetMinAgeConfirm() (value int, ok bool)
GetMinAgeConfirm returns value of MinAgeConfirm conditional field and boolean which is true if field was set.
func (*HelpTermsOfService) SetMinAgeConfirm ¶
func (t *HelpTermsOfService) SetMinAgeConfirm(value int)
SetMinAgeConfirm sets value of MinAgeConfirm conditional field.
func (*HelpTermsOfService) SetPopup ¶
func (t *HelpTermsOfService) SetPopup(value bool)
SetPopup sets value of Popup conditional field.
func (*HelpTermsOfService) String ¶ added in v0.12.0
func (t *HelpTermsOfService) String() string
String implements fmt.Stringer.
type HelpTermsOfServiceUpdate ¶
type HelpTermsOfServiceUpdate struct {
// New TOS updates will have to be queried using help.getTermsOfServiceUpdate¹ in expires seconds
//
// Links:
// 1) https://core.telegram.org/method/help.getTermsOfServiceUpdate
Expires int
// New terms of service
TermsOfService HelpTermsOfService
}
HelpTermsOfServiceUpdate represents TL type `help.termsOfServiceUpdate#28ecf961`. Info about an update of telegram's terms of service. If the terms of service are declined, then the account.deleteAccount¹ method should be called with the reason "Decline ToS update"
Links:
See https://core.telegram.org/constructor/help.termsOfServiceUpdate for reference.
func (*HelpTermsOfServiceUpdate) Decode ¶
func (t *HelpTermsOfServiceUpdate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpTermsOfServiceUpdate) Encode ¶
func (t *HelpTermsOfServiceUpdate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpTermsOfServiceUpdate) String ¶ added in v0.12.0
func (t *HelpTermsOfServiceUpdate) String() string
String implements fmt.Stringer.
type HelpTermsOfServiceUpdateBox ¶
type HelpTermsOfServiceUpdateBox struct {
TermsOfServiceUpdate HelpTermsOfServiceUpdateClass
}
HelpTermsOfServiceUpdate boxes the HelpTermsOfServiceUpdateClass providing a helper.
type HelpTermsOfServiceUpdateClass ¶
type HelpTermsOfServiceUpdateClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpTermsOfServiceUpdateClass represents help.TermsOfServiceUpdate generic type.
See https://core.telegram.org/type/help.TermsOfServiceUpdate for reference.
Example:
g, err := DecodeHelpTermsOfServiceUpdate(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpTermsOfServiceUpdateEmpty: // help.termsOfServiceUpdateEmpty#e3309f7f
case *HelpTermsOfServiceUpdate: // help.termsOfServiceUpdate#28ecf961
default: panic(v)
}
func DecodeHelpTermsOfServiceUpdate ¶
func DecodeHelpTermsOfServiceUpdate(buf *bin.Buffer) (HelpTermsOfServiceUpdateClass, error)
DecodeHelpTermsOfServiceUpdate implements binary de-serialization for HelpTermsOfServiceUpdateClass.
type HelpTermsOfServiceUpdateEmpty ¶
type HelpTermsOfServiceUpdateEmpty struct {
// New TOS updates will have to be queried using help.getTermsOfServiceUpdate¹ in expires seconds
//
// Links:
// 1) https://core.telegram.org/method/help.getTermsOfServiceUpdate
Expires int
}
HelpTermsOfServiceUpdateEmpty represents TL type `help.termsOfServiceUpdateEmpty#e3309f7f`. No changes were made to telegram's terms of service
See https://core.telegram.org/constructor/help.termsOfServiceUpdateEmpty for reference.
func (*HelpTermsOfServiceUpdateEmpty) Decode ¶
func (t *HelpTermsOfServiceUpdateEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpTermsOfServiceUpdateEmpty) Encode ¶
func (t *HelpTermsOfServiceUpdateEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpTermsOfServiceUpdateEmpty) String ¶ added in v0.12.0
func (t *HelpTermsOfServiceUpdateEmpty) String() string
String implements fmt.Stringer.
type HelpUserInfo ¶
type HelpUserInfo struct {
// Info
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
Entities []MessageEntityClass
// Author
Author string
// Date
Date int
}
HelpUserInfo represents TL type `help.userInfo#1eb3758`. Internal use
See https://core.telegram.org/constructor/help.userInfo for reference.
func (*HelpUserInfo) Decode ¶
func (u *HelpUserInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpUserInfo) Encode ¶
func (u *HelpUserInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpUserInfo) String ¶ added in v0.12.0
func (u *HelpUserInfo) String() string
String implements fmt.Stringer.
type HelpUserInfoBox ¶
type HelpUserInfoBox struct {
UserInfo HelpUserInfoClass
}
HelpUserInfo boxes the HelpUserInfoClass providing a helper.
type HelpUserInfoClass ¶
type HelpUserInfoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
HelpUserInfoClass represents help.UserInfo generic type.
See https://core.telegram.org/type/help.UserInfo for reference.
Example:
g, err := DecodeHelpUserInfo(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *HelpUserInfoEmpty: // help.userInfoEmpty#f3ae2eed
case *HelpUserInfo: // help.userInfo#1eb3758
default: panic(v)
}
func DecodeHelpUserInfo ¶
func DecodeHelpUserInfo(buf *bin.Buffer) (HelpUserInfoClass, error)
DecodeHelpUserInfo implements binary de-serialization for HelpUserInfoClass.
type HelpUserInfoEmpty ¶
type HelpUserInfoEmpty struct {
}
HelpUserInfoEmpty represents TL type `help.userInfoEmpty#f3ae2eed`. Internal use
See https://core.telegram.org/constructor/help.userInfoEmpty for reference.
func (*HelpUserInfoEmpty) Decode ¶
func (u *HelpUserInfoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HelpUserInfoEmpty) Encode ¶
func (u *HelpUserInfoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HelpUserInfoEmpty) String ¶ added in v0.12.0
func (u *HelpUserInfoEmpty) String() string
String implements fmt.Stringer.
type HighScore ¶
type HighScore struct {
// Position in highscore list
Pos int
// User ID
UserID int
// Score
Score int
}
HighScore represents TL type `highScore#58fffcd0`. Game highscore
See https://core.telegram.org/constructor/highScore for reference.
type ImportedContact ¶
type ImportedContact struct {
// User identifier
UserID int
// The contact's client identifier (passed to one of the InputContact¹ constructors)
//
// Links:
// 1) https://core.telegram.org/type/InputContact
ClientID int64
}
ImportedContact represents TL type `importedContact#d0028438`. Successfully imported contact.
See https://core.telegram.org/constructor/importedContact for reference.
func (*ImportedContact) Decode ¶
func (i *ImportedContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ImportedContact) Encode ¶
func (i *ImportedContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ImportedContact) String ¶ added in v0.12.0
func (i *ImportedContact) String() string
String implements fmt.Stringer.
type InitConnectionRequest ¶ added in v0.18.0
type InitConnectionRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Application identifier (see. App configuration¹)
//
// Links:
// 1) https://core.telegram.org/myapp
APIID int
// Device model
DeviceModel string
// Operation system version
SystemVersion string
// Application version
AppVersion string
// Code for the language used on the device's OS, ISO 639-1 standard
SystemLangCode string
// Language pack to use
LangPack string
// Code for the language used on the client, ISO 639-1 standard
LangCode string
// Info about an MTProto proxy
//
// Use SetProxy and GetProxy helpers.
Proxy InputClientProxy
// Additional initConnection parameters. For now, only the tz_offset field is supported, for specifying timezone offset in seconds.
//
// Use SetParams and GetParams helpers.
Params JSONValueClass
// The query itself
Query bin.Object
}
InitConnectionRequest represents TL type `initConnection#c1cd5ea9`. Initialize connection
See https://core.telegram.org/constructor/initConnection for reference.
func (*InitConnectionRequest) Decode ¶ added in v0.18.0
func (i *InitConnectionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InitConnectionRequest) Encode ¶ added in v0.18.0
func (i *InitConnectionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InitConnectionRequest) GetParams ¶ added in v0.18.0
func (i *InitConnectionRequest) GetParams() (value JSONValueClass, ok bool)
GetParams returns value of Params conditional field and boolean which is true if field was set.
func (*InitConnectionRequest) GetProxy ¶ added in v0.18.0
func (i *InitConnectionRequest) GetProxy() (value InputClientProxy, ok bool)
GetProxy returns value of Proxy conditional field and boolean which is true if field was set.
func (*InitConnectionRequest) SetParams ¶ added in v0.18.0
func (i *InitConnectionRequest) SetParams(value JSONValueClass)
SetParams sets value of Params conditional field.
func (*InitConnectionRequest) SetProxy ¶ added in v0.18.0
func (i *InitConnectionRequest) SetProxy(value InputClientProxy)
SetProxy sets value of Proxy conditional field.
func (*InitConnectionRequest) String ¶ added in v0.18.0
func (i *InitConnectionRequest) String() string
String implements fmt.Stringer.
type InlineBotCallbackQueryHandler ¶ added in v0.9.0
type InlineBotCallbackQueryHandler func(ctx UpdateContext, update *UpdateInlineBotCallbackQuery) error
InlineBotCallbackQueryHandler is a InlineBotCallbackQuery event handler.
type InlineBotSwitchPM ¶
type InlineBotSwitchPM struct {
// Text for the button that switches the user to a private chat with the bot and sends the bot a start message with the parameter start_parameter (can be empty)
Text string
// The parameter for the /start parameter
StartParam string
}
InlineBotSwitchPM represents TL type `inlineBotSwitchPM#3c20629f`. The bot requested the user to message him in private
See https://core.telegram.org/constructor/inlineBotSwitchPM for reference.
func (*InlineBotSwitchPM) Decode ¶
func (i *InlineBotSwitchPM) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineBotSwitchPM) Encode ¶
func (i *InlineBotSwitchPM) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineBotSwitchPM) String ¶ added in v0.12.0
func (i *InlineBotSwitchPM) String() string
String implements fmt.Stringer.
type InlineQueryPeerTypeBox ¶ added in v0.13.0
type InlineQueryPeerTypeBox struct {
InlineQueryPeerType InlineQueryPeerTypeClass
}
InlineQueryPeerType boxes the InlineQueryPeerTypeClass providing a helper.
type InlineQueryPeerTypeBroadcast ¶ added in v0.13.0
type InlineQueryPeerTypeBroadcast struct {
}
InlineQueryPeerTypeBroadcast represents TL type `inlineQueryPeerTypeBroadcast#6334ee9a`.
See https://core.telegram.org/constructor/inlineQueryPeerTypeBroadcast for reference.
func (*InlineQueryPeerTypeBroadcast) Decode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeBroadcast) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineQueryPeerTypeBroadcast) Encode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeBroadcast) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineQueryPeerTypeBroadcast) String ¶ added in v0.13.0
func (i *InlineQueryPeerTypeBroadcast) String() string
String implements fmt.Stringer.
type InlineQueryPeerTypeChat ¶ added in v0.13.0
type InlineQueryPeerTypeChat struct {
}
InlineQueryPeerTypeChat represents TL type `inlineQueryPeerTypeChat#d766c50a`.
See https://core.telegram.org/constructor/inlineQueryPeerTypeChat for reference.
func (*InlineQueryPeerTypeChat) Decode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineQueryPeerTypeChat) Encode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineQueryPeerTypeChat) String ¶ added in v0.13.0
func (i *InlineQueryPeerTypeChat) String() string
String implements fmt.Stringer.
type InlineQueryPeerTypeClass ¶ added in v0.13.0
type InlineQueryPeerTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InlineQueryPeerTypeClass represents InlineQueryPeerType generic type.
See https://core.telegram.org/type/InlineQueryPeerType for reference.
Example:
g, err := DecodeInlineQueryPeerType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InlineQueryPeerTypeSameBotPM: // inlineQueryPeerTypeSameBotPM#3081ed9d
case *InlineQueryPeerTypePM: // inlineQueryPeerTypePM#833c0fac
case *InlineQueryPeerTypeChat: // inlineQueryPeerTypeChat#d766c50a
case *InlineQueryPeerTypeMegagroup: // inlineQueryPeerTypeMegagroup#5ec4be43
case *InlineQueryPeerTypeBroadcast: // inlineQueryPeerTypeBroadcast#6334ee9a
default: panic(v)
}
func DecodeInlineQueryPeerType ¶ added in v0.13.0
func DecodeInlineQueryPeerType(buf *bin.Buffer) (InlineQueryPeerTypeClass, error)
DecodeInlineQueryPeerType implements binary de-serialization for InlineQueryPeerTypeClass.
type InlineQueryPeerTypeMegagroup ¶ added in v0.13.0
type InlineQueryPeerTypeMegagroup struct {
}
InlineQueryPeerTypeMegagroup represents TL type `inlineQueryPeerTypeMegagroup#5ec4be43`.
See https://core.telegram.org/constructor/inlineQueryPeerTypeMegagroup for reference.
func (*InlineQueryPeerTypeMegagroup) Decode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeMegagroup) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineQueryPeerTypeMegagroup) Encode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeMegagroup) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineQueryPeerTypeMegagroup) String ¶ added in v0.13.0
func (i *InlineQueryPeerTypeMegagroup) String() string
String implements fmt.Stringer.
type InlineQueryPeerTypePM ¶ added in v0.13.0
type InlineQueryPeerTypePM struct {
}
InlineQueryPeerTypePM represents TL type `inlineQueryPeerTypePM#833c0fac`.
See https://core.telegram.org/constructor/inlineQueryPeerTypePM for reference.
func (*InlineQueryPeerTypePM) Decode ¶ added in v0.13.0
func (i *InlineQueryPeerTypePM) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineQueryPeerTypePM) Encode ¶ added in v0.13.0
func (i *InlineQueryPeerTypePM) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineQueryPeerTypePM) String ¶ added in v0.13.0
func (i *InlineQueryPeerTypePM) String() string
String implements fmt.Stringer.
type InlineQueryPeerTypeSameBotPM ¶ added in v0.13.0
type InlineQueryPeerTypeSameBotPM struct {
}
InlineQueryPeerTypeSameBotPM represents TL type `inlineQueryPeerTypeSameBotPM#3081ed9d`.
See https://core.telegram.org/constructor/inlineQueryPeerTypeSameBotPM for reference.
func (*InlineQueryPeerTypeSameBotPM) Decode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeSameBotPM) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InlineQueryPeerTypeSameBotPM) Encode ¶ added in v0.13.0
func (i *InlineQueryPeerTypeSameBotPM) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InlineQueryPeerTypeSameBotPM) String ¶ added in v0.13.0
func (i *InlineQueryPeerTypeSameBotPM) String() string
String implements fmt.Stringer.
type InputAppEvent ¶
type InputAppEvent struct {
// Client's exact timestamp for the event
Time float64
// Type of event
Type string
// Arbitrary numeric value for more convenient selection of certain event types, or events referring to a certain object
Peer int64
// Details of the event
Data JSONValueClass
}
InputAppEvent represents TL type `inputAppEvent#1d1b1245`. Event that occured in the application.
See https://core.telegram.org/constructor/inputAppEvent for reference.
func (*InputAppEvent) Decode ¶
func (i *InputAppEvent) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputAppEvent) Encode ¶
func (i *InputAppEvent) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputAppEvent) String ¶ added in v0.12.0
func (i *InputAppEvent) String() string
String implements fmt.Stringer.
type InputBotInlineMessageBox ¶
type InputBotInlineMessageBox struct {
InputBotInlineMessage InputBotInlineMessageClass
}
InputBotInlineMessage boxes the InputBotInlineMessageClass providing a helper.
type InputBotInlineMessageClass ¶
type InputBotInlineMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputBotInlineMessageClass represents InputBotInlineMessage generic type.
See https://core.telegram.org/type/InputBotInlineMessage for reference.
Example:
g, err := DecodeInputBotInlineMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputBotInlineMessageMediaAuto: // inputBotInlineMessageMediaAuto#3380c786
case *InputBotInlineMessageText: // inputBotInlineMessageText#3dcd7a87
case *InputBotInlineMessageMediaGeo: // inputBotInlineMessageMediaGeo#96929a85
case *InputBotInlineMessageMediaVenue: // inputBotInlineMessageMediaVenue#417bbf11
case *InputBotInlineMessageMediaContact: // inputBotInlineMessageMediaContact#a6edbffd
case *InputBotInlineMessageGame: // inputBotInlineMessageGame#4b425864
default: panic(v)
}
func DecodeInputBotInlineMessage ¶
func DecodeInputBotInlineMessage(buf *bin.Buffer) (InputBotInlineMessageClass, error)
DecodeInputBotInlineMessage implements binary de-serialization for InputBotInlineMessageClass.
type InputBotInlineMessageGame ¶
type InputBotInlineMessageGame struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageGame represents TL type `inputBotInlineMessageGame#4b425864`. A game
See https://core.telegram.org/constructor/inputBotInlineMessageGame for reference.
func (*InputBotInlineMessageGame) Decode ¶
func (i *InputBotInlineMessageGame) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageGame) Encode ¶
func (i *InputBotInlineMessageGame) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageGame) GetReplyMarkup ¶
func (i *InputBotInlineMessageGame) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageGame) SetReplyMarkup ¶
func (i *InputBotInlineMessageGame) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageGame) String ¶ added in v0.12.0
func (i *InputBotInlineMessageGame) String() string
String implements fmt.Stringer.
type InputBotInlineMessageID ¶
type InputBotInlineMessageID struct {
// DC ID to use when working with this inline message
DCID int
// ID of message
ID int64
// Access hash of message
AccessHash int64
}
InputBotInlineMessageID represents TL type `inputBotInlineMessageID#890c3d89`. Represents a sent inline message from the perspective of a bot
See https://core.telegram.org/constructor/inputBotInlineMessageID for reference.
func (*InputBotInlineMessageID) Decode ¶
func (i *InputBotInlineMessageID) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageID) Encode ¶
func (i *InputBotInlineMessageID) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageID) String ¶ added in v0.12.0
func (i *InputBotInlineMessageID) String() string
String implements fmt.Stringer.
type InputBotInlineMessageMediaAuto ¶
type InputBotInlineMessageMediaAuto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Caption
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageMediaAuto represents TL type `inputBotInlineMessageMediaAuto#3380c786`. A media
See https://core.telegram.org/constructor/inputBotInlineMessageMediaAuto for reference.
func (*InputBotInlineMessageMediaAuto) Decode ¶
func (i *InputBotInlineMessageMediaAuto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageMediaAuto) Encode ¶
func (i *InputBotInlineMessageMediaAuto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageMediaAuto) GetEntities ¶
func (i *InputBotInlineMessageMediaAuto) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaAuto) GetReplyMarkup ¶
func (i *InputBotInlineMessageMediaAuto) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaAuto) SetEntities ¶
func (i *InputBotInlineMessageMediaAuto) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*InputBotInlineMessageMediaAuto) SetReplyMarkup ¶
func (i *InputBotInlineMessageMediaAuto) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageMediaAuto) String ¶ added in v0.12.0
func (i *InputBotInlineMessageMediaAuto) String() string
String implements fmt.Stringer.
type InputBotInlineMessageMediaContact ¶
type InputBotInlineMessageMediaContact struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Phone number
PhoneNumber string
// First name
FirstName string
// Last name
LastName string
// VCard info
Vcard string
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageMediaContact represents TL type `inputBotInlineMessageMediaContact#a6edbffd`. A contact
See https://core.telegram.org/constructor/inputBotInlineMessageMediaContact for reference.
func (*InputBotInlineMessageMediaContact) Decode ¶
func (i *InputBotInlineMessageMediaContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageMediaContact) Encode ¶
func (i *InputBotInlineMessageMediaContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageMediaContact) GetReplyMarkup ¶
func (i *InputBotInlineMessageMediaContact) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaContact) SetReplyMarkup ¶
func (i *InputBotInlineMessageMediaContact) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageMediaContact) String ¶ added in v0.12.0
func (i *InputBotInlineMessageMediaContact) String() string
String implements fmt.Stringer.
type InputBotInlineMessageMediaGeo ¶
type InputBotInlineMessageMediaGeo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Geolocation
GeoPoint InputGeoPointClass
// For live locations¹, a direction in which the location moves, in degrees; 1-360
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetHeading and GetHeading helpers.
Heading int
// Validity period
//
// Use SetPeriod and GetPeriod helpers.
Period int
// For live locations¹, a maximum distance to another chat member for proximity alerts, in meters (0-100000)
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetProximityNotificationRadius and GetProximityNotificationRadius helpers.
ProximityNotificationRadius int
// Reply markup for bot/inline keyboards
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageMediaGeo represents TL type `inputBotInlineMessageMediaGeo#96929a85`. Geolocation
See https://core.telegram.org/constructor/inputBotInlineMessageMediaGeo for reference.
func (*InputBotInlineMessageMediaGeo) Decode ¶
func (i *InputBotInlineMessageMediaGeo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageMediaGeo) Encode ¶
func (i *InputBotInlineMessageMediaGeo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageMediaGeo) GetHeading ¶
func (i *InputBotInlineMessageMediaGeo) GetHeading() (value int, ok bool)
GetHeading returns value of Heading conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaGeo) GetPeriod ¶
func (i *InputBotInlineMessageMediaGeo) GetPeriod() (value int, ok bool)
GetPeriod returns value of Period conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaGeo) GetProximityNotificationRadius ¶
func (i *InputBotInlineMessageMediaGeo) GetProximityNotificationRadius() (value int, ok bool)
GetProximityNotificationRadius returns value of ProximityNotificationRadius conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaGeo) GetReplyMarkup ¶
func (i *InputBotInlineMessageMediaGeo) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaGeo) SetHeading ¶
func (i *InputBotInlineMessageMediaGeo) SetHeading(value int)
SetHeading sets value of Heading conditional field.
func (*InputBotInlineMessageMediaGeo) SetPeriod ¶
func (i *InputBotInlineMessageMediaGeo) SetPeriod(value int)
SetPeriod sets value of Period conditional field.
func (*InputBotInlineMessageMediaGeo) SetProximityNotificationRadius ¶
func (i *InputBotInlineMessageMediaGeo) SetProximityNotificationRadius(value int)
SetProximityNotificationRadius sets value of ProximityNotificationRadius conditional field.
func (*InputBotInlineMessageMediaGeo) SetReplyMarkup ¶
func (i *InputBotInlineMessageMediaGeo) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageMediaGeo) String ¶ added in v0.12.0
func (i *InputBotInlineMessageMediaGeo) String() string
String implements fmt.Stringer.
type InputBotInlineMessageMediaVenue ¶
type InputBotInlineMessageMediaVenue struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Geolocation
GeoPoint InputGeoPointClass
// Venue name
Title string
// Address
Address string
// Venue provider: currently only "foursquare" needs to be supported
Provider string
// Venue ID in the provider's database
VenueID string
// Venue type in the provider's database
VenueType string
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageMediaVenue represents TL type `inputBotInlineMessageMediaVenue#417bbf11`. Venue
See https://core.telegram.org/constructor/inputBotInlineMessageMediaVenue for reference.
func (*InputBotInlineMessageMediaVenue) Decode ¶
func (i *InputBotInlineMessageMediaVenue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageMediaVenue) Encode ¶
func (i *InputBotInlineMessageMediaVenue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageMediaVenue) GetReplyMarkup ¶
func (i *InputBotInlineMessageMediaVenue) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageMediaVenue) SetReplyMarkup ¶
func (i *InputBotInlineMessageMediaVenue) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageMediaVenue) String ¶ added in v0.12.0
func (i *InputBotInlineMessageMediaVenue) String() string
String implements fmt.Stringer.
type InputBotInlineMessageText ¶
type InputBotInlineMessageText struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable webpage preview
NoWebpage bool
// Message
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Inline keyboard
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
}
InputBotInlineMessageText represents TL type `inputBotInlineMessageText#3dcd7a87`. Simple text message
See https://core.telegram.org/constructor/inputBotInlineMessageText for reference.
func (*InputBotInlineMessageText) Decode ¶
func (i *InputBotInlineMessageText) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineMessageText) Encode ¶
func (i *InputBotInlineMessageText) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineMessageText) GetEntities ¶
func (i *InputBotInlineMessageText) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageText) GetReplyMarkup ¶
func (i *InputBotInlineMessageText) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*InputBotInlineMessageText) SetEntities ¶
func (i *InputBotInlineMessageText) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*InputBotInlineMessageText) SetNoWebpage ¶
func (i *InputBotInlineMessageText) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*InputBotInlineMessageText) SetReplyMarkup ¶
func (i *InputBotInlineMessageText) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*InputBotInlineMessageText) String ¶ added in v0.12.0
func (i *InputBotInlineMessageText) String() string
String implements fmt.Stringer.
type InputBotInlineResult ¶
type InputBotInlineResult struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// ID of result
ID string
// Result type (see bot API docs¹)
//
// Links:
// 1) https://core.telegram.org/bots/api#inlinequeryresult
Type string
// Result title
//
// Use SetTitle and GetTitle helpers.
Title string
// Result description
//
// Use SetDescription and GetDescription helpers.
Description string
// URL of result
//
// Use SetURL and GetURL helpers.
URL string
// Thumbnail for result
//
// Use SetThumb and GetThumb helpers.
Thumb InputWebDocument
// Result contents
//
// Use SetContent and GetContent helpers.
Content InputWebDocument
// Message to send when the result is selected
SendMessage InputBotInlineMessageClass
}
InputBotInlineResult represents TL type `inputBotInlineResult#88bf9319`. An inline bot result
See https://core.telegram.org/constructor/inputBotInlineResult for reference.
func (*InputBotInlineResult) Decode ¶
func (i *InputBotInlineResult) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineResult) Encode ¶
func (i *InputBotInlineResult) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineResult) GetContent ¶
func (i *InputBotInlineResult) GetContent() (value InputWebDocument, ok bool)
GetContent returns value of Content conditional field and boolean which is true if field was set.
func (*InputBotInlineResult) GetDescription ¶
func (i *InputBotInlineResult) GetDescription() (value string, ok bool)
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*InputBotInlineResult) GetThumb ¶
func (i *InputBotInlineResult) GetThumb() (value InputWebDocument, ok bool)
GetThumb returns value of Thumb conditional field and boolean which is true if field was set.
func (*InputBotInlineResult) GetTitle ¶
func (i *InputBotInlineResult) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*InputBotInlineResult) GetURL ¶
func (i *InputBotInlineResult) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*InputBotInlineResult) SetContent ¶
func (i *InputBotInlineResult) SetContent(value InputWebDocument)
SetContent sets value of Content conditional field.
func (*InputBotInlineResult) SetDescription ¶
func (i *InputBotInlineResult) SetDescription(value string)
SetDescription sets value of Description conditional field.
func (*InputBotInlineResult) SetThumb ¶
func (i *InputBotInlineResult) SetThumb(value InputWebDocument)
SetThumb sets value of Thumb conditional field.
func (*InputBotInlineResult) SetTitle ¶
func (i *InputBotInlineResult) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*InputBotInlineResult) SetURL ¶
func (i *InputBotInlineResult) SetURL(value string)
SetURL sets value of URL conditional field.
func (*InputBotInlineResult) String ¶ added in v0.12.0
func (i *InputBotInlineResult) String() string
String implements fmt.Stringer.
type InputBotInlineResultBox ¶
type InputBotInlineResultBox struct {
InputBotInlineResult InputBotInlineResultClass
}
InputBotInlineResult boxes the InputBotInlineResultClass providing a helper.
type InputBotInlineResultClass ¶
type InputBotInlineResultClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputBotInlineResultClass represents InputBotInlineResult generic type.
See https://core.telegram.org/type/InputBotInlineResult for reference.
Example:
g, err := DecodeInputBotInlineResult(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputBotInlineResult: // inputBotInlineResult#88bf9319
case *InputBotInlineResultPhoto: // inputBotInlineResultPhoto#a8d864a7
case *InputBotInlineResultDocument: // inputBotInlineResultDocument#fff8fdc4
case *InputBotInlineResultGame: // inputBotInlineResultGame#4fa417f2
default: panic(v)
}
func DecodeInputBotInlineResult ¶
func DecodeInputBotInlineResult(buf *bin.Buffer) (InputBotInlineResultClass, error)
DecodeInputBotInlineResult implements binary de-serialization for InputBotInlineResultClass.
type InputBotInlineResultDocument ¶
type InputBotInlineResultDocument struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Result ID
ID string
// Result type (see bot API docs¹)
//
// Links:
// 1) https://core.telegram.org/bots/api#inlinequeryresult
Type string
// Result title
//
// Use SetTitle and GetTitle helpers.
Title string
// Result description
//
// Use SetDescription and GetDescription helpers.
Description string
// Document to send
Document InputDocumentClass
// Message to send when the result is selected
SendMessage InputBotInlineMessageClass
}
InputBotInlineResultDocument represents TL type `inputBotInlineResultDocument#fff8fdc4`. Document (media of any type except for photos)
See https://core.telegram.org/constructor/inputBotInlineResultDocument for reference.
func (*InputBotInlineResultDocument) Decode ¶
func (i *InputBotInlineResultDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineResultDocument) Encode ¶
func (i *InputBotInlineResultDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineResultDocument) GetDescription ¶
func (i *InputBotInlineResultDocument) GetDescription() (value string, ok bool)
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*InputBotInlineResultDocument) GetTitle ¶
func (i *InputBotInlineResultDocument) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*InputBotInlineResultDocument) SetDescription ¶
func (i *InputBotInlineResultDocument) SetDescription(value string)
SetDescription sets value of Description conditional field.
func (*InputBotInlineResultDocument) SetTitle ¶
func (i *InputBotInlineResultDocument) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*InputBotInlineResultDocument) String ¶ added in v0.12.0
func (i *InputBotInlineResultDocument) String() string
String implements fmt.Stringer.
type InputBotInlineResultGame ¶
type InputBotInlineResultGame struct {
// Result ID
ID string
// Game short name
ShortName string
// Message to send when the result is selected
SendMessage InputBotInlineMessageClass
}
InputBotInlineResultGame represents TL type `inputBotInlineResultGame#4fa417f2`. Game
See https://core.telegram.org/constructor/inputBotInlineResultGame for reference.
func (*InputBotInlineResultGame) Decode ¶
func (i *InputBotInlineResultGame) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineResultGame) Encode ¶
func (i *InputBotInlineResultGame) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineResultGame) String ¶ added in v0.12.0
func (i *InputBotInlineResultGame) String() string
String implements fmt.Stringer.
type InputBotInlineResultPhoto ¶
type InputBotInlineResultPhoto struct {
// Result ID
ID string
// Result type (see bot API docs¹)
//
// Links:
// 1) https://core.telegram.org/bots/api#inlinequeryresult
Type string
// Photo to send
Photo InputPhotoClass
// Message to send when the result is selected
SendMessage InputBotInlineMessageClass
}
InputBotInlineResultPhoto represents TL type `inputBotInlineResultPhoto#a8d864a7`. Photo
See https://core.telegram.org/constructor/inputBotInlineResultPhoto for reference.
func (*InputBotInlineResultPhoto) Decode ¶
func (i *InputBotInlineResultPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputBotInlineResultPhoto) Encode ¶
func (i *InputBotInlineResultPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputBotInlineResultPhoto) String ¶ added in v0.12.0
func (i *InputBotInlineResultPhoto) String() string
String implements fmt.Stringer.
type InputChannel ¶
type InputChannel struct {
// Channel ID
ChannelID int
// Access hash taken from the channel¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/channel
AccessHash int64
}
InputChannel represents TL type `inputChannel#afeb712e`. Represents a channel
See https://core.telegram.org/constructor/inputChannel for reference.
func (*InputChannel) Decode ¶
func (i *InputChannel) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChannel) Encode ¶
func (i *InputChannel) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChannel) String ¶ added in v0.12.0
func (i *InputChannel) String() string
String implements fmt.Stringer.
type InputChannelBox ¶
type InputChannelBox struct {
InputChannel InputChannelClass
}
InputChannel boxes the InputChannelClass providing a helper.
type InputChannelClass ¶
type InputChannelClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputChannelClass represents InputChannel generic type.
See https://core.telegram.org/type/InputChannel for reference.
Example:
g, err := DecodeInputChannel(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputChannelEmpty: // inputChannelEmpty#ee8c1e86
case *InputChannel: // inputChannel#afeb712e
case *InputChannelFromMessage: // inputChannelFromMessage#2a286531
default: panic(v)
}
func DecodeInputChannel ¶
func DecodeInputChannel(buf *bin.Buffer) (InputChannelClass, error)
DecodeInputChannel implements binary de-serialization for InputChannelClass.
type InputChannelEmpty ¶
type InputChannelEmpty struct {
}
InputChannelEmpty represents TL type `inputChannelEmpty#ee8c1e86`. Represents the absence of a channel
See https://core.telegram.org/constructor/inputChannelEmpty for reference.
func (*InputChannelEmpty) Decode ¶
func (i *InputChannelEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChannelEmpty) Encode ¶
func (i *InputChannelEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChannelEmpty) String ¶ added in v0.12.0
func (i *InputChannelEmpty) String() string
String implements fmt.Stringer.
type InputChannelFromMessage ¶
type InputChannelFromMessage struct {
// The chat where the channel was seen
Peer InputPeerClass
// The message ID in the chat where the channel was seen
MsgID int
// The channel ID
ChannelID int
}
InputChannelFromMessage represents TL type `inputChannelFromMessage#2a286531`. Defines a min¹ channel that was seen in a certain message of a certain chat.
Links:
See https://core.telegram.org/constructor/inputChannelFromMessage for reference.
func (*InputChannelFromMessage) Decode ¶
func (i *InputChannelFromMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChannelFromMessage) Encode ¶
func (i *InputChannelFromMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChannelFromMessage) String ¶ added in v0.12.0
func (i *InputChannelFromMessage) String() string
String implements fmt.Stringer.
type InputChatPhoto ¶
type InputChatPhoto struct {
// Existing photo
ID InputPhotoClass
}
InputChatPhoto represents TL type `inputChatPhoto#8953ad37`. Existing photo to be set as a chat profile photo.
See https://core.telegram.org/constructor/inputChatPhoto for reference.
func (*InputChatPhoto) Decode ¶
func (i *InputChatPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChatPhoto) Encode ¶
func (i *InputChatPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChatPhoto) String ¶ added in v0.12.0
func (i *InputChatPhoto) String() string
String implements fmt.Stringer.
type InputChatPhotoBox ¶
type InputChatPhotoBox struct {
InputChatPhoto InputChatPhotoClass
}
InputChatPhoto boxes the InputChatPhotoClass providing a helper.
type InputChatPhotoClass ¶
type InputChatPhotoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputChatPhotoClass represents InputChatPhoto generic type.
See https://core.telegram.org/type/InputChatPhoto for reference.
Example:
g, err := DecodeInputChatPhoto(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputChatPhotoEmpty: // inputChatPhotoEmpty#1ca48f57
case *InputChatUploadedPhoto: // inputChatUploadedPhoto#c642724e
case *InputChatPhoto: // inputChatPhoto#8953ad37
default: panic(v)
}
func DecodeInputChatPhoto ¶
func DecodeInputChatPhoto(buf *bin.Buffer) (InputChatPhotoClass, error)
DecodeInputChatPhoto implements binary de-serialization for InputChatPhotoClass.
type InputChatPhotoEmpty ¶
type InputChatPhotoEmpty struct {
}
InputChatPhotoEmpty represents TL type `inputChatPhotoEmpty#1ca48f57`. Empty constructor, remove group photo.
See https://core.telegram.org/constructor/inputChatPhotoEmpty for reference.
func (*InputChatPhotoEmpty) Decode ¶
func (i *InputChatPhotoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChatPhotoEmpty) Encode ¶
func (i *InputChatPhotoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChatPhotoEmpty) String ¶ added in v0.12.0
func (i *InputChatPhotoEmpty) String() string
String implements fmt.Stringer.
type InputChatUploadedPhoto ¶
type InputChatUploadedPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// File saved in parts using the method upload.saveFilePart¹
//
// Links:
// 1) https://core.telegram.org/method/upload.saveFilePart
//
// Use SetFile and GetFile helpers.
File InputFileClass
// Square video for animated profile picture
//
// Use SetVideo and GetVideo helpers.
Video InputFileClass
// Timestamp that should be shown as static preview to the user (seconds)
//
// Use SetVideoStartTs and GetVideoStartTs helpers.
VideoStartTs float64
}
InputChatUploadedPhoto represents TL type `inputChatUploadedPhoto#c642724e`. New photo to be set as group profile photo.
See https://core.telegram.org/constructor/inputChatUploadedPhoto for reference.
func (*InputChatUploadedPhoto) Decode ¶
func (i *InputChatUploadedPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputChatUploadedPhoto) Encode ¶
func (i *InputChatUploadedPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputChatUploadedPhoto) GetFile ¶
func (i *InputChatUploadedPhoto) GetFile() (value InputFileClass, ok bool)
GetFile returns value of File conditional field and boolean which is true if field was set.
func (*InputChatUploadedPhoto) GetVideo ¶
func (i *InputChatUploadedPhoto) GetVideo() (value InputFileClass, ok bool)
GetVideo returns value of Video conditional field and boolean which is true if field was set.
func (*InputChatUploadedPhoto) GetVideoStartTs ¶
func (i *InputChatUploadedPhoto) GetVideoStartTs() (value float64, ok bool)
GetVideoStartTs returns value of VideoStartTs conditional field and boolean which is true if field was set.
func (*InputChatUploadedPhoto) SetFile ¶
func (i *InputChatUploadedPhoto) SetFile(value InputFileClass)
SetFile sets value of File conditional field.
func (*InputChatUploadedPhoto) SetVideo ¶
func (i *InputChatUploadedPhoto) SetVideo(value InputFileClass)
SetVideo sets value of Video conditional field.
func (*InputChatUploadedPhoto) SetVideoStartTs ¶
func (i *InputChatUploadedPhoto) SetVideoStartTs(value float64)
SetVideoStartTs sets value of VideoStartTs conditional field.
func (*InputChatUploadedPhoto) String ¶ added in v0.12.0
func (i *InputChatUploadedPhoto) String() string
String implements fmt.Stringer.
type InputCheckPasswordEmpty ¶
type InputCheckPasswordEmpty struct {
}
InputCheckPasswordEmpty represents TL type `inputCheckPasswordEmpty#9880f658`. There is no password
See https://core.telegram.org/constructor/inputCheckPasswordEmpty for reference.
func (*InputCheckPasswordEmpty) Decode ¶
func (i *InputCheckPasswordEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputCheckPasswordEmpty) Encode ¶
func (i *InputCheckPasswordEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputCheckPasswordEmpty) String ¶ added in v0.12.0
func (i *InputCheckPasswordEmpty) String() string
String implements fmt.Stringer.
type InputCheckPasswordSRP ¶
type InputCheckPasswordSRP struct {
// SRP ID¹
//
// Links:
// 1) https://core.telegram.org/api/srp
SrpID int64
// A parameter (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
A []byte
// M1 parameter (see SRP¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
M1 []byte
}
InputCheckPasswordSRP represents TL type `inputCheckPasswordSRP#d27ff082`. Constructor for checking the validity of a 2FA SRP password (see SRP¹)
Links:
See https://core.telegram.org/constructor/inputCheckPasswordSRP for reference.
func (*InputCheckPasswordSRP) Decode ¶
func (i *InputCheckPasswordSRP) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputCheckPasswordSRP) Encode ¶
func (i *InputCheckPasswordSRP) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputCheckPasswordSRP) String ¶ added in v0.12.0
func (i *InputCheckPasswordSRP) String() string
String implements fmt.Stringer.
type InputCheckPasswordSRPBox ¶
type InputCheckPasswordSRPBox struct {
InputCheckPasswordSRP InputCheckPasswordSRPClass
}
InputCheckPasswordSRP boxes the InputCheckPasswordSRPClass providing a helper.
type InputCheckPasswordSRPClass ¶
type InputCheckPasswordSRPClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputCheckPasswordSRPClass represents InputCheckPasswordSRP generic type.
See https://core.telegram.org/type/InputCheckPasswordSRP for reference.
Example:
g, err := DecodeInputCheckPasswordSRP(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputCheckPasswordEmpty: // inputCheckPasswordEmpty#9880f658
case *InputCheckPasswordSRP: // inputCheckPasswordSRP#d27ff082
default: panic(v)
}
func DecodeInputCheckPasswordSRP ¶
func DecodeInputCheckPasswordSRP(buf *bin.Buffer) (InputCheckPasswordSRPClass, error)
DecodeInputCheckPasswordSRP implements binary de-serialization for InputCheckPasswordSRPClass.
type InputClientProxy ¶
InputClientProxy represents TL type `inputClientProxy#75588b3f`. Info about an MTProxy¹ used to connect.
Links:
See https://core.telegram.org/constructor/inputClientProxy for reference.
func (*InputClientProxy) Decode ¶
func (i *InputClientProxy) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputClientProxy) Encode ¶
func (i *InputClientProxy) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputClientProxy) String ¶ added in v0.12.0
func (i *InputClientProxy) String() string
String implements fmt.Stringer.
type InputDialogPeer ¶
type InputDialogPeer struct {
// Peer
Peer InputPeerClass
}
InputDialogPeer represents TL type `inputDialogPeer#fcaafeb7`. A peer
See https://core.telegram.org/constructor/inputDialogPeer for reference.
func (*InputDialogPeer) Decode ¶
func (i *InputDialogPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputDialogPeer) Encode ¶
func (i *InputDialogPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputDialogPeer) String ¶ added in v0.12.0
func (i *InputDialogPeer) String() string
String implements fmt.Stringer.
type InputDialogPeerBox ¶
type InputDialogPeerBox struct {
InputDialogPeer InputDialogPeerClass
}
InputDialogPeer boxes the InputDialogPeerClass providing a helper.
type InputDialogPeerClass ¶
type InputDialogPeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputDialogPeerClass represents InputDialogPeer generic type.
See https://core.telegram.org/type/InputDialogPeer for reference.
Example:
g, err := DecodeInputDialogPeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputDialogPeer: // inputDialogPeer#fcaafeb7
case *InputDialogPeerFolder: // inputDialogPeerFolder#64600527
default: panic(v)
}
func DecodeInputDialogPeer ¶
func DecodeInputDialogPeer(buf *bin.Buffer) (InputDialogPeerClass, error)
DecodeInputDialogPeer implements binary de-serialization for InputDialogPeerClass.
type InputDialogPeerFolder ¶
type InputDialogPeerFolder struct {
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
InputDialogPeerFolder represents TL type `inputDialogPeerFolder#64600527`. All peers in a peer folder¹
Links:
See https://core.telegram.org/constructor/inputDialogPeerFolder for reference.
func (*InputDialogPeerFolder) Decode ¶
func (i *InputDialogPeerFolder) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputDialogPeerFolder) Encode ¶
func (i *InputDialogPeerFolder) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputDialogPeerFolder) String ¶ added in v0.12.0
func (i *InputDialogPeerFolder) String() string
String implements fmt.Stringer.
type InputDocument ¶
type InputDocument struct {
// Document ID
ID int64
// access_hash parameter from the document¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/document
AccessHash int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
}
InputDocument represents TL type `inputDocument#1abfb575`. Defines a video for subsequent interaction.
See https://core.telegram.org/constructor/inputDocument for reference.
func (*InputDocument) Decode ¶
func (i *InputDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputDocument) Encode ¶
func (i *InputDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputDocument) String ¶ added in v0.12.0
func (i *InputDocument) String() string
String implements fmt.Stringer.
type InputDocumentBox ¶
type InputDocumentBox struct {
InputDocument InputDocumentClass
}
InputDocument boxes the InputDocumentClass providing a helper.
type InputDocumentClass ¶
type InputDocumentClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputDocumentClass represents InputDocument generic type.
See https://core.telegram.org/type/InputDocument for reference.
Example:
g, err := DecodeInputDocument(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputDocumentEmpty: // inputDocumentEmpty#72f0eaae
case *InputDocument: // inputDocument#1abfb575
default: panic(v)
}
func DecodeInputDocument ¶
func DecodeInputDocument(buf *bin.Buffer) (InputDocumentClass, error)
DecodeInputDocument implements binary de-serialization for InputDocumentClass.
type InputDocumentEmpty ¶
type InputDocumentEmpty struct {
}
InputDocumentEmpty represents TL type `inputDocumentEmpty#72f0eaae`. Empty constructor.
See https://core.telegram.org/constructor/inputDocumentEmpty for reference.
func (*InputDocumentEmpty) Decode ¶
func (i *InputDocumentEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputDocumentEmpty) Encode ¶
func (i *InputDocumentEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputDocumentEmpty) String ¶ added in v0.12.0
func (i *InputDocumentEmpty) String() string
String implements fmt.Stringer.
type InputDocumentFileLocation ¶
type InputDocumentFileLocation struct {
// Document ID
ID int64
// access_hash parameter from the document¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/document
AccessHash int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
// Thumbnail size to download the thumbnail
ThumbSize string
}
InputDocumentFileLocation represents TL type `inputDocumentFileLocation#bad07584`. Document location (video, voice, audio, basically every type except photo)
See https://core.telegram.org/constructor/inputDocumentFileLocation for reference.
func (*InputDocumentFileLocation) Decode ¶
func (i *InputDocumentFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputDocumentFileLocation) Encode ¶
func (i *InputDocumentFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputDocumentFileLocation) String ¶ added in v0.12.0
func (i *InputDocumentFileLocation) String() string
String implements fmt.Stringer.
type InputEncryptedChat ¶
type InputEncryptedChat struct {
// Chat ID
ChatID int
// Checking sum from constructor encryptedChat¹, encryptedChatWaiting² or encryptedChatRequested³
//
// Links:
// 1) https://core.telegram.org/constructor/encryptedChat
// 2) https://core.telegram.org/constructor/encryptedChatWaiting
// 3) https://core.telegram.org/constructor/encryptedChatRequested
AccessHash int64
}
InputEncryptedChat represents TL type `inputEncryptedChat#f141b5e1`. Creates an encrypted chat.
See https://core.telegram.org/constructor/inputEncryptedChat for reference.
func (*InputEncryptedChat) Decode ¶
func (i *InputEncryptedChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedChat) Encode ¶
func (i *InputEncryptedChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedChat) String ¶ added in v0.12.0
func (i *InputEncryptedChat) String() string
String implements fmt.Stringer.
type InputEncryptedFile ¶
type InputEncryptedFile struct {
// File ID, value of id parameter from encryptedFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/encryptedFile
ID int64
// Checking sum, value of access_hash parameter from encryptedFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/encryptedFile
AccessHash int64
}
InputEncryptedFile represents TL type `inputEncryptedFile#5a17b5e5`. Sets forwarded encrypted file for attachment.
See https://core.telegram.org/constructor/inputEncryptedFile for reference.
func (*InputEncryptedFile) Decode ¶
func (i *InputEncryptedFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedFile) Encode ¶
func (i *InputEncryptedFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedFile) String ¶ added in v0.12.0
func (i *InputEncryptedFile) String() string
String implements fmt.Stringer.
type InputEncryptedFileBigUploaded ¶
type InputEncryptedFileBigUploaded struct {
// Random file id, created by the client
ID int64
// Number of saved parts
Parts int
// 32-bit imprint of the key used to encrypt the file
KeyFingerprint int
}
InputEncryptedFileBigUploaded represents TL type `inputEncryptedFileBigUploaded#2dc173c8`. Assigns a new big encrypted file (over 10Mb in size), saved in parts using the method upload.saveBigFilePart¹.
Links:
See https://core.telegram.org/constructor/inputEncryptedFileBigUploaded for reference.
func (*InputEncryptedFileBigUploaded) Decode ¶
func (i *InputEncryptedFileBigUploaded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedFileBigUploaded) Encode ¶
func (i *InputEncryptedFileBigUploaded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedFileBigUploaded) String ¶ added in v0.12.0
func (i *InputEncryptedFileBigUploaded) String() string
String implements fmt.Stringer.
type InputEncryptedFileBox ¶
type InputEncryptedFileBox struct {
InputEncryptedFile InputEncryptedFileClass
}
InputEncryptedFile boxes the InputEncryptedFileClass providing a helper.
type InputEncryptedFileClass ¶
type InputEncryptedFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputEncryptedFileClass represents InputEncryptedFile generic type.
See https://core.telegram.org/type/InputEncryptedFile for reference.
Example:
g, err := DecodeInputEncryptedFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputEncryptedFileEmpty: // inputEncryptedFileEmpty#1837c364
case *InputEncryptedFileUploaded: // inputEncryptedFileUploaded#64bd0306
case *InputEncryptedFile: // inputEncryptedFile#5a17b5e5
case *InputEncryptedFileBigUploaded: // inputEncryptedFileBigUploaded#2dc173c8
default: panic(v)
}
func DecodeInputEncryptedFile ¶
func DecodeInputEncryptedFile(buf *bin.Buffer) (InputEncryptedFileClass, error)
DecodeInputEncryptedFile implements binary de-serialization for InputEncryptedFileClass.
type InputEncryptedFileEmpty ¶
type InputEncryptedFileEmpty struct {
}
InputEncryptedFileEmpty represents TL type `inputEncryptedFileEmpty#1837c364`. Empty constructor.
See https://core.telegram.org/constructor/inputEncryptedFileEmpty for reference.
func (*InputEncryptedFileEmpty) Decode ¶
func (i *InputEncryptedFileEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedFileEmpty) Encode ¶
func (i *InputEncryptedFileEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedFileEmpty) String ¶ added in v0.12.0
func (i *InputEncryptedFileEmpty) String() string
String implements fmt.Stringer.
type InputEncryptedFileLocation ¶
type InputEncryptedFileLocation struct {
// File ID, id parameter value from encryptedFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/encryptedFile
ID int64
// Checksum, access_hash parameter value from encryptedFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/encryptedFile
AccessHash int64
}
InputEncryptedFileLocation represents TL type `inputEncryptedFileLocation#f5235d55`. Location of encrypted secret chat file.
See https://core.telegram.org/constructor/inputEncryptedFileLocation for reference.
func (*InputEncryptedFileLocation) Decode ¶
func (i *InputEncryptedFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedFileLocation) Encode ¶
func (i *InputEncryptedFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedFileLocation) String ¶ added in v0.12.0
func (i *InputEncryptedFileLocation) String() string
String implements fmt.Stringer.
type InputEncryptedFileUploaded ¶
type InputEncryptedFileUploaded struct {
// Random file ID created by clien
ID int64
// Number of saved parts
Parts int
// In case md5-HASH¹ of the (already encrypted) file was transmitted, file content will be checked prior to use
//
// Links:
// 1) https://en.wikipedia.org/wiki/MD5
Md5Checksum string
// 32-bit fingerprint of the key used to encrypt a file
KeyFingerprint int
}
InputEncryptedFileUploaded represents TL type `inputEncryptedFileUploaded#64bd0306`. Sets new encrypted file saved by parts using upload.saveFilePart method.
See https://core.telegram.org/constructor/inputEncryptedFileUploaded for reference.
func (*InputEncryptedFileUploaded) Decode ¶
func (i *InputEncryptedFileUploaded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputEncryptedFileUploaded) Encode ¶
func (i *InputEncryptedFileUploaded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputEncryptedFileUploaded) String ¶ added in v0.12.0
func (i *InputEncryptedFileUploaded) String() string
String implements fmt.Stringer.
type InputFile ¶
type InputFile struct {
// Random file identifier created by the client
ID int64
// Number of parts saved
Parts int
// Full name of the file
Name string
// In case the file's md5-hash¹ was passed, contents of the file will be checked prior to use
//
// Links:
// 1) https://en.wikipedia.org/wiki/MD5#MD5_hashes
Md5Checksum string
}
InputFile represents TL type `inputFile#f52ff27f`. Defines a file saved in parts using the method upload.saveFilePart¹.
Links:
See https://core.telegram.org/constructor/inputFile for reference.
type InputFileBig ¶
type InputFileBig struct {
// Random file id, created by the client
ID int64
// Number of parts saved
Parts int
// Full file name
Name string
}
InputFileBig represents TL type `inputFileBig#fa4f0bb5`. Assigns a big file (over 10Mb in size), saved in part using the method upload.saveBigFilePart¹.
Links:
See https://core.telegram.org/constructor/inputFileBig for reference.
func (*InputFileBig) Decode ¶
func (i *InputFileBig) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputFileBig) Encode ¶
func (i *InputFileBig) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputFileBig) String ¶ added in v0.12.0
func (i *InputFileBig) String() string
String implements fmt.Stringer.
type InputFileBox ¶
type InputFileBox struct {
InputFile InputFileClass
}
InputFile boxes the InputFileClass providing a helper.
type InputFileClass ¶
type InputFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputFileClass represents InputFile generic type.
See https://core.telegram.org/type/InputFile for reference.
Example:
g, err := DecodeInputFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputFile: // inputFile#f52ff27f
case *InputFileBig: // inputFileBig#fa4f0bb5
default: panic(v)
}
func DecodeInputFile ¶
func DecodeInputFile(buf *bin.Buffer) (InputFileClass, error)
DecodeInputFile implements binary de-serialization for InputFileClass.
type InputFileLocation ¶
type InputFileLocation struct {
// Server volume
VolumeID int64
// File identifier
LocalID int
// Check sum to access the file
Secret int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
}
InputFileLocation represents TL type `inputFileLocation#dfdaabe1`. DEPRECATED location of a photo
See https://core.telegram.org/constructor/inputFileLocation for reference.
func (*InputFileLocation) Decode ¶
func (i *InputFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputFileLocation) Encode ¶
func (i *InputFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputFileLocation) String ¶ added in v0.12.0
func (i *InputFileLocation) String() string
String implements fmt.Stringer.
type InputFileLocationBox ¶
type InputFileLocationBox struct {
InputFileLocation InputFileLocationClass
}
InputFileLocation boxes the InputFileLocationClass providing a helper.
type InputFileLocationClass ¶
type InputFileLocationClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputFileLocationClass represents InputFileLocation generic type.
See https://core.telegram.org/type/InputFileLocation for reference.
Example:
g, err := DecodeInputFileLocation(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputFileLocation: // inputFileLocation#dfdaabe1
case *InputEncryptedFileLocation: // inputEncryptedFileLocation#f5235d55
case *InputDocumentFileLocation: // inputDocumentFileLocation#bad07584
case *InputSecureFileLocation: // inputSecureFileLocation#cbc7ee28
case *InputTakeoutFileLocation: // inputTakeoutFileLocation#29be5899
case *InputPhotoFileLocation: // inputPhotoFileLocation#40181ffe
case *InputPhotoLegacyFileLocation: // inputPhotoLegacyFileLocation#d83466f3
case *InputPeerPhotoFileLocation: // inputPeerPhotoFileLocation#27d69997
case *InputStickerSetThumb: // inputStickerSetThumb#dbaeae9
default: panic(v)
}
func DecodeInputFileLocation ¶
func DecodeInputFileLocation(buf *bin.Buffer) (InputFileLocationClass, error)
DecodeInputFileLocation implements binary de-serialization for InputFileLocationClass.
type InputFolderPeer ¶
type InputFolderPeer struct {
// Peer
Peer InputPeerClass
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
InputFolderPeer represents TL type `inputFolderPeer#fbd2c296`. Peer in a folder
See https://core.telegram.org/constructor/inputFolderPeer for reference.
func (*InputFolderPeer) Decode ¶
func (i *InputFolderPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputFolderPeer) Encode ¶
func (i *InputFolderPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputFolderPeer) String ¶ added in v0.12.0
func (i *InputFolderPeer) String() string
String implements fmt.Stringer.
type InputGameBox ¶
type InputGameBox struct {
InputGame InputGameClass
}
InputGame boxes the InputGameClass providing a helper.
type InputGameClass ¶
type InputGameClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputGameClass represents InputGame generic type.
See https://core.telegram.org/type/InputGame for reference.
Example:
g, err := DecodeInputGame(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputGameID: // inputGameID#32c3e77
case *InputGameShortName: // inputGameShortName#c331e80a
default: panic(v)
}
func DecodeInputGame ¶
func DecodeInputGame(buf *bin.Buffer) (InputGameClass, error)
DecodeInputGame implements binary de-serialization for InputGameClass.
type InputGameID ¶
type InputGameID struct {
// game ID from Game¹ constructor
//
// Links:
// 1) https://core.telegram.org/type/Game
ID int64
// access hash from Game¹ constructor
//
// Links:
// 1) https://core.telegram.org/type/Game
AccessHash int64
}
InputGameID represents TL type `inputGameID#32c3e77`. Indicates an already sent game
See https://core.telegram.org/constructor/inputGameID for reference.
func (*InputGameID) Decode ¶
func (i *InputGameID) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputGameID) Encode ¶
func (i *InputGameID) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputGameID) String ¶ added in v0.12.0
func (i *InputGameID) String() string
String implements fmt.Stringer.
type InputGameShortName ¶
type InputGameShortName struct {
// The bot that provides the game
BotID InputUserClass
// The game's short name
ShortName string
}
InputGameShortName represents TL type `inputGameShortName#c331e80a`. Game by short name
See https://core.telegram.org/constructor/inputGameShortName for reference.
func (*InputGameShortName) Decode ¶
func (i *InputGameShortName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputGameShortName) Encode ¶
func (i *InputGameShortName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputGameShortName) String ¶ added in v0.12.0
func (i *InputGameShortName) String() string
String implements fmt.Stringer.
type InputGeoPoint ¶
type InputGeoPoint struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Latitide
Lat float64
// Longtitude
Long float64
// The estimated horizontal accuracy of the location, in meters; as defined by the sender.
//
// Use SetAccuracyRadius and GetAccuracyRadius helpers.
AccuracyRadius int
}
InputGeoPoint represents TL type `inputGeoPoint#48222faf`. Defines a GeoPoint by its coordinates.
See https://core.telegram.org/constructor/inputGeoPoint for reference.
func (*InputGeoPoint) Decode ¶
func (i *InputGeoPoint) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputGeoPoint) Encode ¶
func (i *InputGeoPoint) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputGeoPoint) GetAccuracyRadius ¶
func (i *InputGeoPoint) GetAccuracyRadius() (value int, ok bool)
GetAccuracyRadius returns value of AccuracyRadius conditional field and boolean which is true if field was set.
func (*InputGeoPoint) SetAccuracyRadius ¶
func (i *InputGeoPoint) SetAccuracyRadius(value int)
SetAccuracyRadius sets value of AccuracyRadius conditional field.
func (*InputGeoPoint) String ¶ added in v0.12.0
func (i *InputGeoPoint) String() string
String implements fmt.Stringer.
type InputGeoPointBox ¶
type InputGeoPointBox struct {
InputGeoPoint InputGeoPointClass
}
InputGeoPoint boxes the InputGeoPointClass providing a helper.
type InputGeoPointClass ¶
type InputGeoPointClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputGeoPointClass represents InputGeoPoint generic type.
See https://core.telegram.org/type/InputGeoPoint for reference.
Example:
g, err := DecodeInputGeoPoint(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputGeoPointEmpty: // inputGeoPointEmpty#e4c123d6
case *InputGeoPoint: // inputGeoPoint#48222faf
default: panic(v)
}
func DecodeInputGeoPoint ¶
func DecodeInputGeoPoint(buf *bin.Buffer) (InputGeoPointClass, error)
DecodeInputGeoPoint implements binary de-serialization for InputGeoPointClass.
type InputGeoPointEmpty ¶
type InputGeoPointEmpty struct {
}
InputGeoPointEmpty represents TL type `inputGeoPointEmpty#e4c123d6`. Empty GeoPoint constructor.
See https://core.telegram.org/constructor/inputGeoPointEmpty for reference.
func (*InputGeoPointEmpty) Decode ¶
func (i *InputGeoPointEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputGeoPointEmpty) Encode ¶
func (i *InputGeoPointEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputGeoPointEmpty) String ¶ added in v0.12.0
func (i *InputGeoPointEmpty) String() string
String implements fmt.Stringer.
type InputGroupCall ¶ added in v0.13.0
type InputGroupCall struct {
// ID field of InputGroupCall.
ID int64
// AccessHash field of InputGroupCall.
AccessHash int64
}
InputGroupCall represents TL type `inputGroupCall#d8aa840f`.
See https://core.telegram.org/constructor/inputGroupCall for reference.
func (*InputGroupCall) Decode ¶ added in v0.13.0
func (i *InputGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputGroupCall) Encode ¶ added in v0.13.0
func (i *InputGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputGroupCall) String ¶ added in v0.13.0
func (i *InputGroupCall) String() string
String implements fmt.Stringer.
type InputKeyboardButtonUrlAuth ¶
type InputKeyboardButtonUrlAuth struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag to request the permission for your bot to send messages to the user.
RequestWriteAccess bool
// Button text
Text string
// New text of the button in forwarded messages.
//
// Use SetFwdText and GetFwdText helpers.
FwdText string
// An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in Receiving authorization data¹.NOTE: You must always check the hash of the received data to verify the authentication and the integrity of the data as described in Checking authorization².
//
// Links:
// 1) https://core.telegram.org/widgets/login#receiving-authorization-data
// 2) https://core.telegram.org/widgets/login#checking-authorization
URL string
// Username of a bot, which will be used for user authorization. See Setting up a bot¹ for more details. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See Linking your domain to the bot² for more details.
//
// Links:
// 1) https://core.telegram.org/widgets/login#setting-up-a-bot
// 2) https://core.telegram.org/widgets/login#linking-your-domain-to-the-bot
Bot InputUserClass
}
InputKeyboardButtonUrlAuth represents TL type `inputKeyboardButtonUrlAuth#d02e7fd4`. Button to request a user to authorize¹ via URL using Seamless Telegram Login².
Links:
- https://core.telegram.org/method/messages.acceptUrlAuth
- https://telegram.org/blog/privacy-discussions-web-bots#meet-seamless-web-bots
See https://core.telegram.org/constructor/inputKeyboardButtonUrlAuth for reference.
func (*InputKeyboardButtonUrlAuth) Decode ¶
func (i *InputKeyboardButtonUrlAuth) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputKeyboardButtonUrlAuth) Encode ¶
func (i *InputKeyboardButtonUrlAuth) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputKeyboardButtonUrlAuth) GetFwdText ¶
func (i *InputKeyboardButtonUrlAuth) GetFwdText() (value string, ok bool)
GetFwdText returns value of FwdText conditional field and boolean which is true if field was set.
func (*InputKeyboardButtonUrlAuth) SetFwdText ¶
func (i *InputKeyboardButtonUrlAuth) SetFwdText(value string)
SetFwdText sets value of FwdText conditional field.
func (*InputKeyboardButtonUrlAuth) SetRequestWriteAccess ¶
func (i *InputKeyboardButtonUrlAuth) SetRequestWriteAccess(value bool)
SetRequestWriteAccess sets value of RequestWriteAccess conditional field.
func (*InputKeyboardButtonUrlAuth) String ¶ added in v0.12.0
func (i *InputKeyboardButtonUrlAuth) String() string
String implements fmt.Stringer.
type InputMediaBox ¶
type InputMediaBox struct {
InputMedia InputMediaClass
}
InputMedia boxes the InputMediaClass providing a helper.
type InputMediaClass ¶
type InputMediaClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputMediaClass represents InputMedia generic type.
See https://core.telegram.org/type/InputMedia for reference.
Example:
g, err := DecodeInputMedia(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputMediaEmpty: // inputMediaEmpty#9664f57f
case *InputMediaUploadedPhoto: // inputMediaUploadedPhoto#1e287d04
case *InputMediaPhoto: // inputMediaPhoto#b3ba0635
case *InputMediaGeoPoint: // inputMediaGeoPoint#f9c44144
case *InputMediaContact: // inputMediaContact#f8ab7dfb
case *InputMediaUploadedDocument: // inputMediaUploadedDocument#5b38c6c1
case *InputMediaDocument: // inputMediaDocument#33473058
case *InputMediaVenue: // inputMediaVenue#c13d1c11
case *InputMediaPhotoExternal: // inputMediaPhotoExternal#e5bbfe1a
case *InputMediaDocumentExternal: // inputMediaDocumentExternal#fb52dc99
case *InputMediaGame: // inputMediaGame#d33f43f3
case *InputMediaInvoice: // inputMediaInvoice#f4e096c3
case *InputMediaGeoLive: // inputMediaGeoLive#971fa843
case *InputMediaPoll: // inputMediaPoll#f94e5f1
case *InputMediaDice: // inputMediaDice#e66fbf7b
default: panic(v)
}
func DecodeInputMedia ¶
func DecodeInputMedia(buf *bin.Buffer) (InputMediaClass, error)
DecodeInputMedia implements binary de-serialization for InputMediaClass.
type InputMediaContact ¶
type InputMediaContact struct {
// Phone number
PhoneNumber string
// Contact's first name
FirstName string
// Contact's last name
LastName string
// Contact vcard
Vcard string
}
InputMediaContact represents TL type `inputMediaContact#f8ab7dfb`. Phonebook contact
See https://core.telegram.org/constructor/inputMediaContact for reference.
func (*InputMediaContact) Decode ¶
func (i *InputMediaContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaContact) Encode ¶
func (i *InputMediaContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaContact) String ¶ added in v0.12.0
func (i *InputMediaContact) String() string
String implements fmt.Stringer.
type InputMediaDice ¶
type InputMediaDice struct {
// The emoji, for now , and are supported
Emoticon string
}
InputMediaDice represents TL type `inputMediaDice#e66fbf7b`. Send a dice-based animated sticker¹
Links:
See https://core.telegram.org/constructor/inputMediaDice for reference.
func (*InputMediaDice) Decode ¶
func (i *InputMediaDice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaDice) Encode ¶
func (i *InputMediaDice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaDice) String ¶ added in v0.12.0
func (i *InputMediaDice) String() string
String implements fmt.Stringer.
type InputMediaDocument ¶
type InputMediaDocument struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The document to be forwarded.
ID InputDocumentClass
// Time to live of self-destructing document
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
// Query field of InputMediaDocument.
//
// Use SetQuery and GetQuery helpers.
Query string
}
InputMediaDocument represents TL type `inputMediaDocument#33473058`. Forwarded document
See https://core.telegram.org/constructor/inputMediaDocument for reference.
func (*InputMediaDocument) Decode ¶
func (i *InputMediaDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaDocument) Encode ¶
func (i *InputMediaDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaDocument) GetQuery ¶ added in v0.13.0
func (i *InputMediaDocument) GetQuery() (value string, ok bool)
GetQuery returns value of Query conditional field and boolean which is true if field was set.
func (*InputMediaDocument) GetTTLSeconds ¶
func (i *InputMediaDocument) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaDocument) SetQuery ¶ added in v0.13.0
func (i *InputMediaDocument) SetQuery(value string)
SetQuery sets value of Query conditional field.
func (*InputMediaDocument) SetTTLSeconds ¶
func (i *InputMediaDocument) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaDocument) String ¶ added in v0.12.0
func (i *InputMediaDocument) String() string
String implements fmt.Stringer.
type InputMediaDocumentExternal ¶
type InputMediaDocumentExternal struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// URL of the document
URL string
// Self-destruct time to live of document
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
InputMediaDocumentExternal represents TL type `inputMediaDocumentExternal#fb52dc99`. Document that will be downloaded by the telegram servers
See https://core.telegram.org/constructor/inputMediaDocumentExternal for reference.
func (*InputMediaDocumentExternal) Decode ¶
func (i *InputMediaDocumentExternal) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaDocumentExternal) Encode ¶
func (i *InputMediaDocumentExternal) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaDocumentExternal) GetTTLSeconds ¶
func (i *InputMediaDocumentExternal) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaDocumentExternal) SetTTLSeconds ¶
func (i *InputMediaDocumentExternal) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaDocumentExternal) String ¶ added in v0.12.0
func (i *InputMediaDocumentExternal) String() string
String implements fmt.Stringer.
type InputMediaEmpty ¶
type InputMediaEmpty struct {
}
InputMediaEmpty represents TL type `inputMediaEmpty#9664f57f`. Empty media content of a message.
See https://core.telegram.org/constructor/inputMediaEmpty for reference.
func (*InputMediaEmpty) Decode ¶
func (i *InputMediaEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaEmpty) Encode ¶
func (i *InputMediaEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaEmpty) String ¶ added in v0.12.0
func (i *InputMediaEmpty) String() string
String implements fmt.Stringer.
type InputMediaGame ¶
type InputMediaGame struct {
// The game to forward
ID InputGameClass
}
InputMediaGame represents TL type `inputMediaGame#d33f43f3`. A game
See https://core.telegram.org/constructor/inputMediaGame for reference.
func (*InputMediaGame) Decode ¶
func (i *InputMediaGame) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaGame) Encode ¶
func (i *InputMediaGame) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaGame) String ¶ added in v0.12.0
func (i *InputMediaGame) String() string
String implements fmt.Stringer.
type InputMediaGeoLive ¶
type InputMediaGeoLive struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether sending of the geolocation was stopped
Stopped bool
// Current geolocation
GeoPoint InputGeoPointClass
// For live locations¹, a direction in which the location moves, in degrees; 1-360.
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetHeading and GetHeading helpers.
Heading int
// Validity period of the current location
//
// Use SetPeriod and GetPeriod helpers.
Period int
// For live locations¹, a maximum distance to another chat member for proximity alerts, in meters (0-100000)
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetProximityNotificationRadius and GetProximityNotificationRadius helpers.
ProximityNotificationRadius int
}
InputMediaGeoLive represents TL type `inputMediaGeoLive#971fa843`. Live geolocation¹
Links:
See https://core.telegram.org/constructor/inputMediaGeoLive for reference.
func (*InputMediaGeoLive) Decode ¶
func (i *InputMediaGeoLive) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaGeoLive) Encode ¶
func (i *InputMediaGeoLive) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaGeoLive) GetHeading ¶
func (i *InputMediaGeoLive) GetHeading() (value int, ok bool)
GetHeading returns value of Heading conditional field and boolean which is true if field was set.
func (*InputMediaGeoLive) GetPeriod ¶
func (i *InputMediaGeoLive) GetPeriod() (value int, ok bool)
GetPeriod returns value of Period conditional field and boolean which is true if field was set.
func (*InputMediaGeoLive) GetProximityNotificationRadius ¶
func (i *InputMediaGeoLive) GetProximityNotificationRadius() (value int, ok bool)
GetProximityNotificationRadius returns value of ProximityNotificationRadius conditional field and boolean which is true if field was set.
func (*InputMediaGeoLive) SetHeading ¶
func (i *InputMediaGeoLive) SetHeading(value int)
SetHeading sets value of Heading conditional field.
func (*InputMediaGeoLive) SetPeriod ¶
func (i *InputMediaGeoLive) SetPeriod(value int)
SetPeriod sets value of Period conditional field.
func (*InputMediaGeoLive) SetProximityNotificationRadius ¶
func (i *InputMediaGeoLive) SetProximityNotificationRadius(value int)
SetProximityNotificationRadius sets value of ProximityNotificationRadius conditional field.
func (*InputMediaGeoLive) SetStopped ¶
func (i *InputMediaGeoLive) SetStopped(value bool)
SetStopped sets value of Stopped conditional field.
func (*InputMediaGeoLive) String ¶ added in v0.12.0
func (i *InputMediaGeoLive) String() string
String implements fmt.Stringer.
type InputMediaGeoPoint ¶
type InputMediaGeoPoint struct {
// GeoPoint
GeoPoint InputGeoPointClass
}
InputMediaGeoPoint represents TL type `inputMediaGeoPoint#f9c44144`. Map.
See https://core.telegram.org/constructor/inputMediaGeoPoint for reference.
func (*InputMediaGeoPoint) Decode ¶
func (i *InputMediaGeoPoint) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaGeoPoint) Encode ¶
func (i *InputMediaGeoPoint) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaGeoPoint) String ¶ added in v0.12.0
func (i *InputMediaGeoPoint) String() string
String implements fmt.Stringer.
type InputMediaInvoice ¶
type InputMediaInvoice struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Product name, 1-32 characters
Title string
// Product description, 1-255 characters
Description string
// URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for.
//
// Use SetPhoto and GetPhoto helpers.
Photo InputWebDocument
// The actual invoice
Invoice Invoice
// Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes.
Payload []byte
// Payments provider token, obtained via Botfather¹
//
// Links:
// 1) https://t.me/botfather
Provider string
// JSON-encoded data about the invoice, which will be shared with the payment provider. A detailed description of required fields should be provided by the payment provider.
ProviderData DataJSON
// Start parameter
StartParam string
}
InputMediaInvoice represents TL type `inputMediaInvoice#f4e096c3`. Generated invoice of a bot payment¹
Links:
See https://core.telegram.org/constructor/inputMediaInvoice for reference.
func (*InputMediaInvoice) Decode ¶
func (i *InputMediaInvoice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaInvoice) Encode ¶
func (i *InputMediaInvoice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaInvoice) GetPhoto ¶
func (i *InputMediaInvoice) GetPhoto() (value InputWebDocument, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*InputMediaInvoice) SetPhoto ¶
func (i *InputMediaInvoice) SetPhoto(value InputWebDocument)
SetPhoto sets value of Photo conditional field.
func (*InputMediaInvoice) String ¶ added in v0.12.0
func (i *InputMediaInvoice) String() string
String implements fmt.Stringer.
type InputMediaPhoto ¶
type InputMediaPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Photo to be forwarded
ID InputPhotoClass
// Time to live in seconds of self-destructing photo
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
InputMediaPhoto represents TL type `inputMediaPhoto#b3ba0635`. Forwarded photo
See https://core.telegram.org/constructor/inputMediaPhoto for reference.
func (*InputMediaPhoto) Decode ¶
func (i *InputMediaPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaPhoto) Encode ¶
func (i *InputMediaPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaPhoto) GetTTLSeconds ¶
func (i *InputMediaPhoto) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaPhoto) SetTTLSeconds ¶
func (i *InputMediaPhoto) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaPhoto) String ¶ added in v0.12.0
func (i *InputMediaPhoto) String() string
String implements fmt.Stringer.
type InputMediaPhotoExternal ¶
type InputMediaPhotoExternal struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// URL of the photo
URL string
// Self-destruct time to live of photo
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
InputMediaPhotoExternal represents TL type `inputMediaPhotoExternal#e5bbfe1a`. New photo that will be uploaded by the server using the specified URL
See https://core.telegram.org/constructor/inputMediaPhotoExternal for reference.
func (*InputMediaPhotoExternal) Decode ¶
func (i *InputMediaPhotoExternal) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaPhotoExternal) Encode ¶
func (i *InputMediaPhotoExternal) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaPhotoExternal) GetTTLSeconds ¶
func (i *InputMediaPhotoExternal) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaPhotoExternal) SetTTLSeconds ¶
func (i *InputMediaPhotoExternal) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaPhotoExternal) String ¶ added in v0.12.0
func (i *InputMediaPhotoExternal) String() string
String implements fmt.Stringer.
type InputMediaPoll ¶
type InputMediaPoll struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The poll to send
Poll Poll
// Correct answer IDs (for quiz polls)
//
// Use SetCorrectAnswers and GetCorrectAnswers helpers.
CorrectAnswers [][]byte
// Explanation of quiz solution
//
// Use SetSolution and GetSolution helpers.
Solution string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetSolutionEntities and GetSolutionEntities helpers.
SolutionEntities []MessageEntityClass
}
InputMediaPoll represents TL type `inputMediaPoll#f94e5f1`. A poll
See https://core.telegram.org/constructor/inputMediaPoll for reference.
func (*InputMediaPoll) Decode ¶
func (i *InputMediaPoll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaPoll) Encode ¶
func (i *InputMediaPoll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaPoll) GetCorrectAnswers ¶
func (i *InputMediaPoll) GetCorrectAnswers() (value [][]byte, ok bool)
GetCorrectAnswers returns value of CorrectAnswers conditional field and boolean which is true if field was set.
func (*InputMediaPoll) GetSolution ¶
func (i *InputMediaPoll) GetSolution() (value string, ok bool)
GetSolution returns value of Solution conditional field and boolean which is true if field was set.
func (*InputMediaPoll) GetSolutionEntities ¶
func (i *InputMediaPoll) GetSolutionEntities() (value []MessageEntityClass, ok bool)
GetSolutionEntities returns value of SolutionEntities conditional field and boolean which is true if field was set.
func (*InputMediaPoll) SetCorrectAnswers ¶
func (i *InputMediaPoll) SetCorrectAnswers(value [][]byte)
SetCorrectAnswers sets value of CorrectAnswers conditional field.
func (*InputMediaPoll) SetSolution ¶
func (i *InputMediaPoll) SetSolution(value string)
SetSolution sets value of Solution conditional field.
func (*InputMediaPoll) SetSolutionEntities ¶
func (i *InputMediaPoll) SetSolutionEntities(value []MessageEntityClass)
SetSolutionEntities sets value of SolutionEntities conditional field.
func (*InputMediaPoll) String ¶ added in v0.12.0
func (i *InputMediaPoll) String() string
String implements fmt.Stringer.
type InputMediaUploadedDocument ¶
type InputMediaUploadedDocument struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the specified document is a video file with no audio tracks (a GIF animation (even as MPEG4), for example)
NosoundVideo bool
// Force the media file to be uploaded as document
ForceFile bool
// The uploaded file¹
//
// Links:
// 1) https://core.telegram.org/api/files
File InputFileClass
// Thumbnail of the document, uploaded as for the file
//
// Use SetThumb and GetThumb helpers.
Thumb InputFileClass
// MIME type of document
MimeType string
// Attributes that specify the type of the document (video, audio, voice, sticker, etc.)
Attributes []DocumentAttributeClass
// Attached stickers
//
// Use SetStickers and GetStickers helpers.
Stickers []InputDocumentClass
// Time to live in seconds of self-destructing document
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
InputMediaUploadedDocument represents TL type `inputMediaUploadedDocument#5b38c6c1`. New document
See https://core.telegram.org/constructor/inputMediaUploadedDocument for reference.
func (*InputMediaUploadedDocument) Decode ¶
func (i *InputMediaUploadedDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaUploadedDocument) Encode ¶
func (i *InputMediaUploadedDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaUploadedDocument) GetStickers ¶
func (i *InputMediaUploadedDocument) GetStickers() (value []InputDocumentClass, ok bool)
GetStickers returns value of Stickers conditional field and boolean which is true if field was set.
func (*InputMediaUploadedDocument) GetTTLSeconds ¶
func (i *InputMediaUploadedDocument) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaUploadedDocument) GetThumb ¶
func (i *InputMediaUploadedDocument) GetThumb() (value InputFileClass, ok bool)
GetThumb returns value of Thumb conditional field and boolean which is true if field was set.
func (*InputMediaUploadedDocument) SetForceFile ¶
func (i *InputMediaUploadedDocument) SetForceFile(value bool)
SetForceFile sets value of ForceFile conditional field.
func (*InputMediaUploadedDocument) SetNosoundVideo ¶
func (i *InputMediaUploadedDocument) SetNosoundVideo(value bool)
SetNosoundVideo sets value of NosoundVideo conditional field.
func (*InputMediaUploadedDocument) SetStickers ¶
func (i *InputMediaUploadedDocument) SetStickers(value []InputDocumentClass)
SetStickers sets value of Stickers conditional field.
func (*InputMediaUploadedDocument) SetTTLSeconds ¶
func (i *InputMediaUploadedDocument) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaUploadedDocument) SetThumb ¶
func (i *InputMediaUploadedDocument) SetThumb(value InputFileClass)
SetThumb sets value of Thumb conditional field.
func (*InputMediaUploadedDocument) String ¶ added in v0.12.0
func (i *InputMediaUploadedDocument) String() string
String implements fmt.Stringer.
type InputMediaUploadedPhoto ¶
type InputMediaUploadedPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The uploaded file¹
//
// Links:
// 1) https://core.telegram.org/api/files
File InputFileClass
// Attached mask stickers
//
// Use SetStickers and GetStickers helpers.
Stickers []InputDocumentClass
// Time to live in seconds of self-destructing photo
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
InputMediaUploadedPhoto represents TL type `inputMediaUploadedPhoto#1e287d04`. Photo
See https://core.telegram.org/constructor/inputMediaUploadedPhoto for reference.
func (*InputMediaUploadedPhoto) Decode ¶
func (i *InputMediaUploadedPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaUploadedPhoto) Encode ¶
func (i *InputMediaUploadedPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaUploadedPhoto) GetStickers ¶
func (i *InputMediaUploadedPhoto) GetStickers() (value []InputDocumentClass, ok bool)
GetStickers returns value of Stickers conditional field and boolean which is true if field was set.
func (*InputMediaUploadedPhoto) GetTTLSeconds ¶
func (i *InputMediaUploadedPhoto) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*InputMediaUploadedPhoto) SetStickers ¶
func (i *InputMediaUploadedPhoto) SetStickers(value []InputDocumentClass)
SetStickers sets value of Stickers conditional field.
func (*InputMediaUploadedPhoto) SetTTLSeconds ¶
func (i *InputMediaUploadedPhoto) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*InputMediaUploadedPhoto) String ¶ added in v0.12.0
func (i *InputMediaUploadedPhoto) String() string
String implements fmt.Stringer.
type InputMediaVenue ¶
type InputMediaVenue struct {
// Geolocation
GeoPoint InputGeoPointClass
// Venue name
Title string
// Physical address of the venue
Address string
// Venue provider: currently only "foursquare" needs to be supported
Provider string
// Venue ID in the provider's database
VenueID string
// Venue type in the provider's database
VenueType string
}
InputMediaVenue represents TL type `inputMediaVenue#c13d1c11`. Can be used to send a venue geolocation.
See https://core.telegram.org/constructor/inputMediaVenue for reference.
func (*InputMediaVenue) Decode ¶
func (i *InputMediaVenue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMediaVenue) Encode ¶
func (i *InputMediaVenue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMediaVenue) String ¶ added in v0.12.0
func (i *InputMediaVenue) String() string
String implements fmt.Stringer.
type InputMessageBox ¶
type InputMessageBox struct {
InputMessage InputMessageClass
}
InputMessage boxes the InputMessageClass providing a helper.
type InputMessageCallbackQuery ¶
InputMessageCallbackQuery represents TL type `inputMessageCallbackQuery#acfa1a7e`. Used by bots for fetching information about the message that originated a callback query
See https://core.telegram.org/constructor/inputMessageCallbackQuery for reference.
func (*InputMessageCallbackQuery) Decode ¶
func (i *InputMessageCallbackQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessageCallbackQuery) Encode ¶
func (i *InputMessageCallbackQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessageCallbackQuery) String ¶ added in v0.12.0
func (i *InputMessageCallbackQuery) String() string
String implements fmt.Stringer.
type InputMessageClass ¶
type InputMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputMessageClass represents InputMessage generic type.
See https://core.telegram.org/type/InputMessage for reference.
Example:
g, err := DecodeInputMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputMessageID: // inputMessageID#a676a322
case *InputMessageReplyTo: // inputMessageReplyTo#bad88395
case *InputMessagePinned: // inputMessagePinned#86872538
case *InputMessageCallbackQuery: // inputMessageCallbackQuery#acfa1a7e
default: panic(v)
}
func DecodeInputMessage ¶
func DecodeInputMessage(buf *bin.Buffer) (InputMessageClass, error)
DecodeInputMessage implements binary de-serialization for InputMessageClass.
type InputMessageEntityMentionName ¶
type InputMessageEntityMentionName struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
// Identifier of the user that was mentioned
UserID InputUserClass
}
InputMessageEntityMentionName represents TL type `inputMessageEntityMentionName#208e68c9`. Message entity that can be used to create a user user mention¹: received mentions use the messageEntityMentionName² constructor, instead.
Links:
- https://core.telegram.org/api/mentions
- https://core.telegram.org/constructor/messageEntityMentionName
See https://core.telegram.org/constructor/inputMessageEntityMentionName for reference.
func (*InputMessageEntityMentionName) Decode ¶
func (i *InputMessageEntityMentionName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessageEntityMentionName) Encode ¶
func (i *InputMessageEntityMentionName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessageEntityMentionName) String ¶ added in v0.12.0
func (i *InputMessageEntityMentionName) String() string
String implements fmt.Stringer.
type InputMessageID ¶
type InputMessageID struct {
// Message ID
ID int
}
InputMessageID represents TL type `inputMessageID#a676a322`. Message by ID
See https://core.telegram.org/constructor/inputMessageID for reference.
func (*InputMessageID) Decode ¶
func (i *InputMessageID) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessageID) Encode ¶
func (i *InputMessageID) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessageID) String ¶ added in v0.12.0
func (i *InputMessageID) String() string
String implements fmt.Stringer.
type InputMessagePinned ¶
type InputMessagePinned struct {
}
InputMessagePinned represents TL type `inputMessagePinned#86872538`. Pinned message
See https://core.telegram.org/constructor/inputMessagePinned for reference.
func (*InputMessagePinned) Decode ¶
func (i *InputMessagePinned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagePinned) Encode ¶
func (i *InputMessagePinned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagePinned) String ¶ added in v0.12.0
func (i *InputMessagePinned) String() string
String implements fmt.Stringer.
type InputMessageReplyTo ¶
type InputMessageReplyTo struct {
// ID of the message that replies to the message we need
ID int
}
InputMessageReplyTo represents TL type `inputMessageReplyTo#bad88395`. Message to which the specified message replies to
See https://core.telegram.org/constructor/inputMessageReplyTo for reference.
func (*InputMessageReplyTo) Decode ¶
func (i *InputMessageReplyTo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessageReplyTo) Encode ¶
func (i *InputMessageReplyTo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessageReplyTo) String ¶ added in v0.12.0
func (i *InputMessageReplyTo) String() string
String implements fmt.Stringer.
type InputMessagesFilterChatPhotos ¶
type InputMessagesFilterChatPhotos struct {
}
InputMessagesFilterChatPhotos represents TL type `inputMessagesFilterChatPhotos#3a20ecb8`. Return only chat photo changes
See https://core.telegram.org/constructor/inputMessagesFilterChatPhotos for reference.
func (*InputMessagesFilterChatPhotos) Decode ¶
func (i *InputMessagesFilterChatPhotos) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterChatPhotos) Encode ¶
func (i *InputMessagesFilterChatPhotos) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterChatPhotos) String ¶ added in v0.12.0
func (i *InputMessagesFilterChatPhotos) String() string
String implements fmt.Stringer.
type InputMessagesFilterContacts ¶
type InputMessagesFilterContacts struct {
}
InputMessagesFilterContacts represents TL type `inputMessagesFilterContacts#e062db83`. Return only messages containing contacts
See https://core.telegram.org/constructor/inputMessagesFilterContacts for reference.
func (*InputMessagesFilterContacts) Decode ¶
func (i *InputMessagesFilterContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterContacts) Encode ¶
func (i *InputMessagesFilterContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterContacts) String ¶ added in v0.12.0
func (i *InputMessagesFilterContacts) String() string
String implements fmt.Stringer.
type InputMessagesFilterDocument ¶
type InputMessagesFilterDocument struct {
}
InputMessagesFilterDocument represents TL type `inputMessagesFilterDocument#9eddf188`. Filter for messages containing documents.
See https://core.telegram.org/constructor/inputMessagesFilterDocument for reference.
func (*InputMessagesFilterDocument) Decode ¶
func (i *InputMessagesFilterDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterDocument) Encode ¶
func (i *InputMessagesFilterDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterDocument) String ¶ added in v0.12.0
func (i *InputMessagesFilterDocument) String() string
String implements fmt.Stringer.
type InputMessagesFilterEmpty ¶
type InputMessagesFilterEmpty struct {
}
InputMessagesFilterEmpty represents TL type `inputMessagesFilterEmpty#57e2f66c`. Filter is absent.
See https://core.telegram.org/constructor/inputMessagesFilterEmpty for reference.
func (*InputMessagesFilterEmpty) Decode ¶
func (i *InputMessagesFilterEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterEmpty) Encode ¶
func (i *InputMessagesFilterEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterEmpty) String ¶ added in v0.12.0
func (i *InputMessagesFilterEmpty) String() string
String implements fmt.Stringer.
type InputMessagesFilterGeo ¶
type InputMessagesFilterGeo struct {
}
InputMessagesFilterGeo represents TL type `inputMessagesFilterGeo#e7026d0d`. Return only messages containing geolocations
See https://core.telegram.org/constructor/inputMessagesFilterGeo for reference.
func (*InputMessagesFilterGeo) Decode ¶
func (i *InputMessagesFilterGeo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterGeo) Encode ¶
func (i *InputMessagesFilterGeo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterGeo) String ¶ added in v0.12.0
func (i *InputMessagesFilterGeo) String() string
String implements fmt.Stringer.
type InputMessagesFilterGif ¶
type InputMessagesFilterGif struct {
}
InputMessagesFilterGif represents TL type `inputMessagesFilterGif#ffc86587`. Return only messages containing gifs
See https://core.telegram.org/constructor/inputMessagesFilterGif for reference.
func (*InputMessagesFilterGif) Decode ¶
func (i *InputMessagesFilterGif) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterGif) Encode ¶
func (i *InputMessagesFilterGif) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterGif) String ¶ added in v0.12.0
func (i *InputMessagesFilterGif) String() string
String implements fmt.Stringer.
type InputMessagesFilterMusic ¶
type InputMessagesFilterMusic struct {
}
InputMessagesFilterMusic represents TL type `inputMessagesFilterMusic#3751b49e`. Return only messages containing audio files
See https://core.telegram.org/constructor/inputMessagesFilterMusic for reference.
func (*InputMessagesFilterMusic) Decode ¶
func (i *InputMessagesFilterMusic) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterMusic) Encode ¶
func (i *InputMessagesFilterMusic) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterMusic) String ¶ added in v0.12.0
func (i *InputMessagesFilterMusic) String() string
String implements fmt.Stringer.
type InputMessagesFilterMyMentions ¶
type InputMessagesFilterMyMentions struct {
}
InputMessagesFilterMyMentions represents TL type `inputMessagesFilterMyMentions#c1f8e69a`. Return only messages where the current user was mentioned¹.
Links:
See https://core.telegram.org/constructor/inputMessagesFilterMyMentions for reference.
func (*InputMessagesFilterMyMentions) Decode ¶
func (i *InputMessagesFilterMyMentions) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterMyMentions) Encode ¶
func (i *InputMessagesFilterMyMentions) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterMyMentions) String ¶ added in v0.12.0
func (i *InputMessagesFilterMyMentions) String() string
String implements fmt.Stringer.
type InputMessagesFilterPhoneCalls ¶
type InputMessagesFilterPhoneCalls struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Return only missed phone calls
Missed bool
}
InputMessagesFilterPhoneCalls represents TL type `inputMessagesFilterPhoneCalls#80c99768`. Return only phone calls
See https://core.telegram.org/constructor/inputMessagesFilterPhoneCalls for reference.
func (*InputMessagesFilterPhoneCalls) Decode ¶
func (i *InputMessagesFilterPhoneCalls) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterPhoneCalls) Encode ¶
func (i *InputMessagesFilterPhoneCalls) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterPhoneCalls) SetMissed ¶
func (i *InputMessagesFilterPhoneCalls) SetMissed(value bool)
SetMissed sets value of Missed conditional field.
func (*InputMessagesFilterPhoneCalls) String ¶ added in v0.12.0
func (i *InputMessagesFilterPhoneCalls) String() string
String implements fmt.Stringer.
type InputMessagesFilterPhotoVideo ¶
type InputMessagesFilterPhotoVideo struct {
}
InputMessagesFilterPhotoVideo represents TL type `inputMessagesFilterPhotoVideo#56e9f0e4`. Filter for messages containing photos or videos.
See https://core.telegram.org/constructor/inputMessagesFilterPhotoVideo for reference.
func (*InputMessagesFilterPhotoVideo) Decode ¶
func (i *InputMessagesFilterPhotoVideo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterPhotoVideo) Encode ¶
func (i *InputMessagesFilterPhotoVideo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterPhotoVideo) String ¶ added in v0.12.0
func (i *InputMessagesFilterPhotoVideo) String() string
String implements fmt.Stringer.
type InputMessagesFilterPhotos ¶
type InputMessagesFilterPhotos struct {
}
InputMessagesFilterPhotos represents TL type `inputMessagesFilterPhotos#9609a51c`. Filter for messages containing photos.
See https://core.telegram.org/constructor/inputMessagesFilterPhotos for reference.
func (*InputMessagesFilterPhotos) Decode ¶
func (i *InputMessagesFilterPhotos) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterPhotos) Encode ¶
func (i *InputMessagesFilterPhotos) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterPhotos) String ¶ added in v0.12.0
func (i *InputMessagesFilterPhotos) String() string
String implements fmt.Stringer.
type InputMessagesFilterPinned ¶
type InputMessagesFilterPinned struct {
}
InputMessagesFilterPinned represents TL type `inputMessagesFilterPinned#1bb00451`. Fetch only pinned messages
See https://core.telegram.org/constructor/inputMessagesFilterPinned for reference.
func (*InputMessagesFilterPinned) Decode ¶
func (i *InputMessagesFilterPinned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterPinned) Encode ¶
func (i *InputMessagesFilterPinned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterPinned) String ¶ added in v0.12.0
func (i *InputMessagesFilterPinned) String() string
String implements fmt.Stringer.
type InputMessagesFilterRoundVideo ¶
type InputMessagesFilterRoundVideo struct {
}
InputMessagesFilterRoundVideo represents TL type `inputMessagesFilterRoundVideo#b549da53`. Return only round videos
See https://core.telegram.org/constructor/inputMessagesFilterRoundVideo for reference.
func (*InputMessagesFilterRoundVideo) Decode ¶
func (i *InputMessagesFilterRoundVideo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterRoundVideo) Encode ¶
func (i *InputMessagesFilterRoundVideo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterRoundVideo) String ¶ added in v0.12.0
func (i *InputMessagesFilterRoundVideo) String() string
String implements fmt.Stringer.
type InputMessagesFilterRoundVoice ¶
type InputMessagesFilterRoundVoice struct {
}
InputMessagesFilterRoundVoice represents TL type `inputMessagesFilterRoundVoice#7a7c17a4`. Return only round videos and voice notes
See https://core.telegram.org/constructor/inputMessagesFilterRoundVoice for reference.
func (*InputMessagesFilterRoundVoice) Decode ¶
func (i *InputMessagesFilterRoundVoice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterRoundVoice) Encode ¶
func (i *InputMessagesFilterRoundVoice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterRoundVoice) String ¶ added in v0.12.0
func (i *InputMessagesFilterRoundVoice) String() string
String implements fmt.Stringer.
type InputMessagesFilterUrl ¶
type InputMessagesFilterUrl struct {
}
InputMessagesFilterUrl represents TL type `inputMessagesFilterUrl#7ef0dd87`. Return only messages containing URLs
See https://core.telegram.org/constructor/inputMessagesFilterUrl for reference.
func (*InputMessagesFilterUrl) Decode ¶
func (i *InputMessagesFilterUrl) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterUrl) Encode ¶
func (i *InputMessagesFilterUrl) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterUrl) String ¶ added in v0.12.0
func (i *InputMessagesFilterUrl) String() string
String implements fmt.Stringer.
type InputMessagesFilterVideo ¶
type InputMessagesFilterVideo struct {
}
InputMessagesFilterVideo represents TL type `inputMessagesFilterVideo#9fc00e65`. Filter for messages containing videos.
See https://core.telegram.org/constructor/inputMessagesFilterVideo for reference.
func (*InputMessagesFilterVideo) Decode ¶
func (i *InputMessagesFilterVideo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterVideo) Encode ¶
func (i *InputMessagesFilterVideo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterVideo) String ¶ added in v0.12.0
func (i *InputMessagesFilterVideo) String() string
String implements fmt.Stringer.
type InputMessagesFilterVoice ¶
type InputMessagesFilterVoice struct {
}
InputMessagesFilterVoice represents TL type `inputMessagesFilterVoice#50f5c392`. Return only messages containing voice notes
See https://core.telegram.org/constructor/inputMessagesFilterVoice for reference.
func (*InputMessagesFilterVoice) Decode ¶
func (i *InputMessagesFilterVoice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputMessagesFilterVoice) Encode ¶
func (i *InputMessagesFilterVoice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputMessagesFilterVoice) String ¶ added in v0.12.0
func (i *InputMessagesFilterVoice) String() string
String implements fmt.Stringer.
type InputNotifyBroadcasts ¶
type InputNotifyBroadcasts struct {
}
InputNotifyBroadcasts represents TL type `inputNotifyBroadcasts#b1db7c7e`. All channels¹
Links:
See https://core.telegram.org/constructor/inputNotifyBroadcasts for reference.
func (*InputNotifyBroadcasts) Decode ¶
func (i *InputNotifyBroadcasts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputNotifyBroadcasts) Encode ¶
func (i *InputNotifyBroadcasts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputNotifyBroadcasts) String ¶ added in v0.12.0
func (i *InputNotifyBroadcasts) String() string
String implements fmt.Stringer.
type InputNotifyChats ¶
type InputNotifyChats struct {
}
InputNotifyChats represents TL type `inputNotifyChats#4a95e84e`. Notifications generated by all groups.
See https://core.telegram.org/constructor/inputNotifyChats for reference.
func (*InputNotifyChats) Decode ¶
func (i *InputNotifyChats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputNotifyChats) Encode ¶
func (i *InputNotifyChats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputNotifyChats) String ¶ added in v0.12.0
func (i *InputNotifyChats) String() string
String implements fmt.Stringer.
type InputNotifyPeer ¶
type InputNotifyPeer struct {
// User or group
Peer InputPeerClass
}
InputNotifyPeer represents TL type `inputNotifyPeer#b8bc5b0c`. Notifications generated by a certain user or group.
See https://core.telegram.org/constructor/inputNotifyPeer for reference.
func (*InputNotifyPeer) Decode ¶
func (i *InputNotifyPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputNotifyPeer) Encode ¶
func (i *InputNotifyPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputNotifyPeer) String ¶ added in v0.12.0
func (i *InputNotifyPeer) String() string
String implements fmt.Stringer.
type InputNotifyPeerBox ¶
type InputNotifyPeerBox struct {
InputNotifyPeer InputNotifyPeerClass
}
InputNotifyPeer boxes the InputNotifyPeerClass providing a helper.
type InputNotifyPeerClass ¶
type InputNotifyPeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputNotifyPeerClass represents InputNotifyPeer generic type.
See https://core.telegram.org/type/InputNotifyPeer for reference.
Example:
g, err := DecodeInputNotifyPeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputNotifyPeer: // inputNotifyPeer#b8bc5b0c
case *InputNotifyUsers: // inputNotifyUsers#193b4417
case *InputNotifyChats: // inputNotifyChats#4a95e84e
case *InputNotifyBroadcasts: // inputNotifyBroadcasts#b1db7c7e
default: panic(v)
}
func DecodeInputNotifyPeer ¶
func DecodeInputNotifyPeer(buf *bin.Buffer) (InputNotifyPeerClass, error)
DecodeInputNotifyPeer implements binary de-serialization for InputNotifyPeerClass.
type InputNotifyUsers ¶
type InputNotifyUsers struct {
}
InputNotifyUsers represents TL type `inputNotifyUsers#193b4417`. Notifications generated by all users.
See https://core.telegram.org/constructor/inputNotifyUsers for reference.
func (*InputNotifyUsers) Decode ¶
func (i *InputNotifyUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputNotifyUsers) Encode ¶
func (i *InputNotifyUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputNotifyUsers) String ¶ added in v0.12.0
func (i *InputNotifyUsers) String() string
String implements fmt.Stringer.
type InputPaymentCredentials ¶
type InputPaymentCredentials struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Save payment credential for future use
Save bool
// Payment credentials
Data DataJSON
}
InputPaymentCredentials represents TL type `inputPaymentCredentials#3417d728`. Payment credentials
See https://core.telegram.org/constructor/inputPaymentCredentials for reference.
func (*InputPaymentCredentials) Decode ¶
func (i *InputPaymentCredentials) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPaymentCredentials) Encode ¶
func (i *InputPaymentCredentials) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPaymentCredentials) SetSave ¶
func (i *InputPaymentCredentials) SetSave(value bool)
SetSave sets value of Save conditional field.
func (*InputPaymentCredentials) String ¶ added in v0.12.0
func (i *InputPaymentCredentials) String() string
String implements fmt.Stringer.
type InputPaymentCredentialsAndroidPay ¶
type InputPaymentCredentialsAndroidPay struct {
// Android pay payment token
PaymentToken DataJSON
// Google transaction ID
GoogleTransactionID string
}
InputPaymentCredentialsAndroidPay represents TL type `inputPaymentCredentialsAndroidPay#ca05d50e`. Android pay payment credentials
See https://core.telegram.org/constructor/inputPaymentCredentialsAndroidPay for reference.
func (*InputPaymentCredentialsAndroidPay) Decode ¶
func (i *InputPaymentCredentialsAndroidPay) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPaymentCredentialsAndroidPay) Encode ¶
func (i *InputPaymentCredentialsAndroidPay) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPaymentCredentialsAndroidPay) String ¶ added in v0.12.0
func (i *InputPaymentCredentialsAndroidPay) String() string
String implements fmt.Stringer.
type InputPaymentCredentialsApplePay ¶
type InputPaymentCredentialsApplePay struct {
// Payment data
PaymentData DataJSON
}
InputPaymentCredentialsApplePay represents TL type `inputPaymentCredentialsApplePay#aa1c39f`. Apple pay payment credentials
See https://core.telegram.org/constructor/inputPaymentCredentialsApplePay for reference.
func (*InputPaymentCredentialsApplePay) Decode ¶
func (i *InputPaymentCredentialsApplePay) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPaymentCredentialsApplePay) Encode ¶
func (i *InputPaymentCredentialsApplePay) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPaymentCredentialsApplePay) String ¶ added in v0.12.0
func (i *InputPaymentCredentialsApplePay) String() string
String implements fmt.Stringer.
type InputPaymentCredentialsBox ¶
type InputPaymentCredentialsBox struct {
InputPaymentCredentials InputPaymentCredentialsClass
}
InputPaymentCredentials boxes the InputPaymentCredentialsClass providing a helper.
type InputPaymentCredentialsClass ¶
type InputPaymentCredentialsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputPaymentCredentialsClass represents InputPaymentCredentials generic type.
See https://core.telegram.org/type/InputPaymentCredentials for reference.
Example:
g, err := DecodeInputPaymentCredentials(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputPaymentCredentialsSaved: // inputPaymentCredentialsSaved#c10eb2cf
case *InputPaymentCredentials: // inputPaymentCredentials#3417d728
case *InputPaymentCredentialsApplePay: // inputPaymentCredentialsApplePay#aa1c39f
case *InputPaymentCredentialsAndroidPay: // inputPaymentCredentialsAndroidPay#ca05d50e
default: panic(v)
}
func DecodeInputPaymentCredentials ¶
func DecodeInputPaymentCredentials(buf *bin.Buffer) (InputPaymentCredentialsClass, error)
DecodeInputPaymentCredentials implements binary de-serialization for InputPaymentCredentialsClass.
type InputPaymentCredentialsSaved ¶
type InputPaymentCredentialsSaved struct {
// Credential ID
ID string
// Temporary password
TmpPassword []byte
}
InputPaymentCredentialsSaved represents TL type `inputPaymentCredentialsSaved#c10eb2cf`. Saved payment credentials
See https://core.telegram.org/constructor/inputPaymentCredentialsSaved for reference.
func (*InputPaymentCredentialsSaved) Decode ¶
func (i *InputPaymentCredentialsSaved) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPaymentCredentialsSaved) Encode ¶
func (i *InputPaymentCredentialsSaved) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPaymentCredentialsSaved) String ¶ added in v0.12.0
func (i *InputPaymentCredentialsSaved) String() string
String implements fmt.Stringer.
type InputPeerBox ¶
type InputPeerBox struct {
InputPeer InputPeerClass
}
InputPeer boxes the InputPeerClass providing a helper.
type InputPeerChannel ¶
type InputPeerChannel struct {
// Channel identifier
ChannelID int
// access_hash value from the channel¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/channel
AccessHash int64
}
InputPeerChannel represents TL type `inputPeerChannel#20adaef8`. Defines a channel for further interaction.
See https://core.telegram.org/constructor/inputPeerChannel for reference.
func (*InputPeerChannel) Decode ¶
func (i *InputPeerChannel) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerChannel) Encode ¶
func (i *InputPeerChannel) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerChannel) String ¶ added in v0.12.0
func (i *InputPeerChannel) String() string
String implements fmt.Stringer.
type InputPeerChannelFromMessage ¶
type InputPeerChannelFromMessage struct {
// The chat where the channel's message was seen
Peer InputPeerClass
// The message ID
MsgID int
// The identifier of the channel that was seen
ChannelID int
}
InputPeerChannelFromMessage represents TL type `inputPeerChannelFromMessage#9c95f7bb`. Defines a min¹ channel that was seen in a certain message of a certain chat.
Links:
See https://core.telegram.org/constructor/inputPeerChannelFromMessage for reference.
func (*InputPeerChannelFromMessage) Decode ¶
func (i *InputPeerChannelFromMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerChannelFromMessage) Encode ¶
func (i *InputPeerChannelFromMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerChannelFromMessage) String ¶ added in v0.12.0
func (i *InputPeerChannelFromMessage) String() string
String implements fmt.Stringer.
type InputPeerChat ¶
type InputPeerChat struct {
// Chat idientifier
ChatID int
}
InputPeerChat represents TL type `inputPeerChat#179be863`. Defines a chat for further interaction.
See https://core.telegram.org/constructor/inputPeerChat for reference.
func (*InputPeerChat) Decode ¶
func (i *InputPeerChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerChat) Encode ¶
func (i *InputPeerChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerChat) String ¶ added in v0.12.0
func (i *InputPeerChat) String() string
String implements fmt.Stringer.
type InputPeerClass ¶
type InputPeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputPeerClass represents InputPeer generic type.
See https://core.telegram.org/type/InputPeer for reference.
Example:
g, err := DecodeInputPeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputPeerEmpty: // inputPeerEmpty#7f3b18ea
case *InputPeerSelf: // inputPeerSelf#7da07ec9
case *InputPeerChat: // inputPeerChat#179be863
case *InputPeerUser: // inputPeerUser#7b8e7de6
case *InputPeerChannel: // inputPeerChannel#20adaef8
case *InputPeerUserFromMessage: // inputPeerUserFromMessage#17bae2e6
case *InputPeerChannelFromMessage: // inputPeerChannelFromMessage#9c95f7bb
default: panic(v)
}
func DecodeInputPeer ¶
func DecodeInputPeer(buf *bin.Buffer) (InputPeerClass, error)
DecodeInputPeer implements binary de-serialization for InputPeerClass.
type InputPeerEmpty ¶
type InputPeerEmpty struct {
}
InputPeerEmpty represents TL type `inputPeerEmpty#7f3b18ea`. An empty constructor, no user or chat is defined.
See https://core.telegram.org/constructor/inputPeerEmpty for reference.
func (*InputPeerEmpty) Decode ¶
func (i *InputPeerEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerEmpty) Encode ¶
func (i *InputPeerEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerEmpty) String ¶ added in v0.12.0
func (i *InputPeerEmpty) String() string
String implements fmt.Stringer.
type InputPeerNotifySettings ¶
type InputPeerNotifySettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If the text of the message shall be displayed in notification
//
// Use SetShowPreviews and GetShowPreviews helpers.
ShowPreviews bool
// Peer was muted?
//
// Use SetSilent and GetSilent helpers.
Silent bool
// Date until which all notifications shall be switched off
//
// Use SetMuteUntil and GetMuteUntil helpers.
MuteUntil int
// Name of an audio file for notification
//
// Use SetSound and GetSound helpers.
Sound string
}
InputPeerNotifySettings represents TL type `inputPeerNotifySettings#9c3d198e`. Notification settings.
See https://core.telegram.org/constructor/inputPeerNotifySettings for reference.
func (*InputPeerNotifySettings) Decode ¶
func (i *InputPeerNotifySettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerNotifySettings) Encode ¶
func (i *InputPeerNotifySettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerNotifySettings) GetMuteUntil ¶
func (i *InputPeerNotifySettings) GetMuteUntil() (value int, ok bool)
GetMuteUntil returns value of MuteUntil conditional field and boolean which is true if field was set.
func (*InputPeerNotifySettings) GetShowPreviews ¶ added in v0.17.0
func (i *InputPeerNotifySettings) GetShowPreviews() (value bool, ok bool)
GetShowPreviews returns value of ShowPreviews conditional field and boolean which is true if field was set.
func (*InputPeerNotifySettings) GetSilent ¶ added in v0.17.0
func (i *InputPeerNotifySettings) GetSilent() (value bool, ok bool)
GetSilent returns value of Silent conditional field and boolean which is true if field was set.
func (*InputPeerNotifySettings) GetSound ¶
func (i *InputPeerNotifySettings) GetSound() (value string, ok bool)
GetSound returns value of Sound conditional field and boolean which is true if field was set.
func (*InputPeerNotifySettings) SetMuteUntil ¶
func (i *InputPeerNotifySettings) SetMuteUntil(value int)
SetMuteUntil sets value of MuteUntil conditional field.
func (*InputPeerNotifySettings) SetShowPreviews ¶
func (i *InputPeerNotifySettings) SetShowPreviews(value bool)
SetShowPreviews sets value of ShowPreviews conditional field.
func (*InputPeerNotifySettings) SetSilent ¶
func (i *InputPeerNotifySettings) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*InputPeerNotifySettings) SetSound ¶
func (i *InputPeerNotifySettings) SetSound(value string)
SetSound sets value of Sound conditional field.
func (*InputPeerNotifySettings) String ¶ added in v0.12.0
func (i *InputPeerNotifySettings) String() string
String implements fmt.Stringer.
type InputPeerPhotoFileLocation ¶
type InputPeerPhotoFileLocation struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to download the high-quality version of the picture
Big bool
// The peer whose profile picture should be downloaded
Peer InputPeerClass
// Volume ID from FileLocation¹ met in the profile photo container.
//
// Links:
// 1) https://core.telegram.org/type/FileLocation
VolumeID int64
// Local ID from FileLocation¹ met in the profile photo container.
//
// Links:
// 1) https://core.telegram.org/type/FileLocation
LocalID int
}
InputPeerPhotoFileLocation represents TL type `inputPeerPhotoFileLocation#27d69997`. Location of profile photo of channel/group/supergroup/user
See https://core.telegram.org/constructor/inputPeerPhotoFileLocation for reference.
func (*InputPeerPhotoFileLocation) Decode ¶
func (i *InputPeerPhotoFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerPhotoFileLocation) Encode ¶
func (i *InputPeerPhotoFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerPhotoFileLocation) SetBig ¶
func (i *InputPeerPhotoFileLocation) SetBig(value bool)
SetBig sets value of Big conditional field.
func (*InputPeerPhotoFileLocation) String ¶ added in v0.12.0
func (i *InputPeerPhotoFileLocation) String() string
String implements fmt.Stringer.
type InputPeerSelf ¶
type InputPeerSelf struct {
}
InputPeerSelf represents TL type `inputPeerSelf#7da07ec9`. Defines the current user.
See https://core.telegram.org/constructor/inputPeerSelf for reference.
func (*InputPeerSelf) Decode ¶
func (i *InputPeerSelf) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerSelf) Encode ¶
func (i *InputPeerSelf) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerSelf) String ¶ added in v0.12.0
func (i *InputPeerSelf) String() string
String implements fmt.Stringer.
type InputPeerUser ¶
type InputPeerUser struct {
// User identifier
UserID int
// access_hash value from the user¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/user
AccessHash int64
}
InputPeerUser represents TL type `inputPeerUser#7b8e7de6`. Defines a user for further interaction.
See https://core.telegram.org/constructor/inputPeerUser for reference.
func (*InputPeerUser) Decode ¶
func (i *InputPeerUser) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerUser) Encode ¶
func (i *InputPeerUser) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerUser) String ¶ added in v0.12.0
func (i *InputPeerUser) String() string
String implements fmt.Stringer.
type InputPeerUserFromMessage ¶
type InputPeerUserFromMessage struct {
// The chat where the user was seen
Peer InputPeerClass
// The message ID
MsgID int
// The identifier of the user that was seen
UserID int
}
InputPeerUserFromMessage represents TL type `inputPeerUserFromMessage#17bae2e6`. Defines a min¹ user that was seen in a certain message of a certain chat.
Links:
See https://core.telegram.org/constructor/inputPeerUserFromMessage for reference.
func (*InputPeerUserFromMessage) Decode ¶
func (i *InputPeerUserFromMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPeerUserFromMessage) Encode ¶
func (i *InputPeerUserFromMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPeerUserFromMessage) String ¶ added in v0.12.0
func (i *InputPeerUserFromMessage) String() string
String implements fmt.Stringer.
type InputPhoneCall ¶
InputPhoneCall represents TL type `inputPhoneCall#1e36fded`. Phone call
See https://core.telegram.org/constructor/inputPhoneCall for reference.
func (*InputPhoneCall) Decode ¶
func (i *InputPhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhoneCall) Encode ¶
func (i *InputPhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhoneCall) String ¶ added in v0.12.0
func (i *InputPhoneCall) String() string
String implements fmt.Stringer.
type InputPhoneContact ¶
type InputPhoneContact struct {
// User identifier on the client
ClientID int64
// Phone number
Phone string
// Contact's first name
FirstName string
// Contact's last name
LastName string
}
InputPhoneContact represents TL type `inputPhoneContact#f392b7f4`. Phone contact. The client_id is just an arbitrary contact ID: it should be set, for example, to an incremental number when using contacts.importContacts¹, in order to retry importing only the contacts that weren't imported successfully.
Links:
See https://core.telegram.org/constructor/inputPhoneContact for reference.
func (*InputPhoneContact) Decode ¶
func (i *InputPhoneContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhoneContact) Encode ¶
func (i *InputPhoneContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhoneContact) String ¶ added in v0.12.0
func (i *InputPhoneContact) String() string
String implements fmt.Stringer.
type InputPhoto ¶
type InputPhoto struct {
// Photo identifier
ID int64
// access_hash value from the photo¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/photo
AccessHash int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
}
InputPhoto represents TL type `inputPhoto#3bb3b94a`. Defines a photo for further interaction.
See https://core.telegram.org/constructor/inputPhoto for reference.
func (*InputPhoto) Decode ¶
func (i *InputPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhoto) Encode ¶
func (i *InputPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhoto) String ¶ added in v0.12.0
func (i *InputPhoto) String() string
String implements fmt.Stringer.
type InputPhotoBox ¶
type InputPhotoBox struct {
InputPhoto InputPhotoClass
}
InputPhoto boxes the InputPhotoClass providing a helper.
type InputPhotoClass ¶
type InputPhotoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputPhotoClass represents InputPhoto generic type.
See https://core.telegram.org/type/InputPhoto for reference.
Example:
g, err := DecodeInputPhoto(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputPhotoEmpty: // inputPhotoEmpty#1cd7bf0d
case *InputPhoto: // inputPhoto#3bb3b94a
default: panic(v)
}
func DecodeInputPhoto ¶
func DecodeInputPhoto(buf *bin.Buffer) (InputPhotoClass, error)
DecodeInputPhoto implements binary de-serialization for InputPhotoClass.
type InputPhotoEmpty ¶
type InputPhotoEmpty struct {
}
InputPhotoEmpty represents TL type `inputPhotoEmpty#1cd7bf0d`. Empty constructor.
See https://core.telegram.org/constructor/inputPhotoEmpty for reference.
func (*InputPhotoEmpty) Decode ¶
func (i *InputPhotoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhotoEmpty) Encode ¶
func (i *InputPhotoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhotoEmpty) String ¶ added in v0.12.0
func (i *InputPhotoEmpty) String() string
String implements fmt.Stringer.
type InputPhotoFileLocation ¶
type InputPhotoFileLocation struct {
// Photo ID, obtained from the photo¹ object
//
// Links:
// 1) https://core.telegram.org/constructor/photo
ID int64
// Photo's access hash, obtained from the photo¹ object
//
// Links:
// 1) https://core.telegram.org/constructor/photo
AccessHash int64
// File reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
// The PhotoSize¹ to download: must be set to the type field of the desired PhotoSize object of the photo²
//
// Links:
// 1) https://core.telegram.org/type/PhotoSize
// 2) https://core.telegram.org/constructor/photo
ThumbSize string
}
InputPhotoFileLocation represents TL type `inputPhotoFileLocation#40181ffe`. Use this object to download a photo with upload.getFile¹ method
Links:
See https://core.telegram.org/constructor/inputPhotoFileLocation for reference.
func (*InputPhotoFileLocation) Decode ¶
func (i *InputPhotoFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhotoFileLocation) Encode ¶
func (i *InputPhotoFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhotoFileLocation) String ¶ added in v0.12.0
func (i *InputPhotoFileLocation) String() string
String implements fmt.Stringer.
type InputPhotoLegacyFileLocation ¶
type InputPhotoLegacyFileLocation struct {
// Photo ID
ID int64
// Access hash
AccessHash int64
// File reference
FileReference []byte
// Volume ID
VolumeID int64
// Local ID
LocalID int
// Secret
Secret int64
}
InputPhotoLegacyFileLocation represents TL type `inputPhotoLegacyFileLocation#d83466f3`. Legacy photo file location
See https://core.telegram.org/constructor/inputPhotoLegacyFileLocation for reference.
func (*InputPhotoLegacyFileLocation) Decode ¶
func (i *InputPhotoLegacyFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPhotoLegacyFileLocation) Encode ¶
func (i *InputPhotoLegacyFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPhotoLegacyFileLocation) String ¶ added in v0.12.0
func (i *InputPhotoLegacyFileLocation) String() string
String implements fmt.Stringer.
type InputPrivacyKeyAddedByPhone ¶
type InputPrivacyKeyAddedByPhone struct {
}
InputPrivacyKeyAddedByPhone represents TL type `inputPrivacyKeyAddedByPhone#d1219bdd`. Whether people can add you to their contact list by your phone number
See https://core.telegram.org/constructor/inputPrivacyKeyAddedByPhone for reference.
func (*InputPrivacyKeyAddedByPhone) Decode ¶
func (i *InputPrivacyKeyAddedByPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyAddedByPhone) Encode ¶
func (i *InputPrivacyKeyAddedByPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyAddedByPhone) String ¶ added in v0.12.0
func (i *InputPrivacyKeyAddedByPhone) String() string
String implements fmt.Stringer.
type InputPrivacyKeyBox ¶
type InputPrivacyKeyBox struct {
InputPrivacyKey InputPrivacyKeyClass
}
InputPrivacyKey boxes the InputPrivacyKeyClass providing a helper.
type InputPrivacyKeyChatInvite ¶
type InputPrivacyKeyChatInvite struct {
}
InputPrivacyKeyChatInvite represents TL type `inputPrivacyKeyChatInvite#bdfb0426`. Whether the user can be invited to chats
See https://core.telegram.org/constructor/inputPrivacyKeyChatInvite for reference.
func (*InputPrivacyKeyChatInvite) Decode ¶
func (i *InputPrivacyKeyChatInvite) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyChatInvite) Encode ¶
func (i *InputPrivacyKeyChatInvite) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyChatInvite) String ¶ added in v0.12.0
func (i *InputPrivacyKeyChatInvite) String() string
String implements fmt.Stringer.
type InputPrivacyKeyClass ¶
type InputPrivacyKeyClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputPrivacyKeyClass represents InputPrivacyKey generic type.
See https://core.telegram.org/type/InputPrivacyKey for reference.
Example:
g, err := DecodeInputPrivacyKey(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputPrivacyKeyStatusTimestamp: // inputPrivacyKeyStatusTimestamp#4f96cb18
case *InputPrivacyKeyChatInvite: // inputPrivacyKeyChatInvite#bdfb0426
case *InputPrivacyKeyPhoneCall: // inputPrivacyKeyPhoneCall#fabadc5f
case *InputPrivacyKeyPhoneP2P: // inputPrivacyKeyPhoneP2P#db9e70d2
case *InputPrivacyKeyForwards: // inputPrivacyKeyForwards#a4dd4c08
case *InputPrivacyKeyProfilePhoto: // inputPrivacyKeyProfilePhoto#5719bacc
case *InputPrivacyKeyPhoneNumber: // inputPrivacyKeyPhoneNumber#352dafa
case *InputPrivacyKeyAddedByPhone: // inputPrivacyKeyAddedByPhone#d1219bdd
default: panic(v)
}
func DecodeInputPrivacyKey ¶
func DecodeInputPrivacyKey(buf *bin.Buffer) (InputPrivacyKeyClass, error)
DecodeInputPrivacyKey implements binary de-serialization for InputPrivacyKeyClass.
type InputPrivacyKeyForwards ¶
type InputPrivacyKeyForwards struct {
}
InputPrivacyKeyForwards represents TL type `inputPrivacyKeyForwards#a4dd4c08`. Whether messages forwarded from this user will be anonymous¹
Links:
See https://core.telegram.org/constructor/inputPrivacyKeyForwards for reference.
func (*InputPrivacyKeyForwards) Decode ¶
func (i *InputPrivacyKeyForwards) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyForwards) Encode ¶
func (i *InputPrivacyKeyForwards) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyForwards) String ¶ added in v0.12.0
func (i *InputPrivacyKeyForwards) String() string
String implements fmt.Stringer.
type InputPrivacyKeyPhoneCall ¶
type InputPrivacyKeyPhoneCall struct {
}
InputPrivacyKeyPhoneCall represents TL type `inputPrivacyKeyPhoneCall#fabadc5f`. Whether the user will accept phone calls
See https://core.telegram.org/constructor/inputPrivacyKeyPhoneCall for reference.
func (*InputPrivacyKeyPhoneCall) Decode ¶
func (i *InputPrivacyKeyPhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyPhoneCall) Encode ¶
func (i *InputPrivacyKeyPhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyPhoneCall) String ¶ added in v0.12.0
func (i *InputPrivacyKeyPhoneCall) String() string
String implements fmt.Stringer.
type InputPrivacyKeyPhoneNumber ¶
type InputPrivacyKeyPhoneNumber struct {
}
InputPrivacyKeyPhoneNumber represents TL type `inputPrivacyKeyPhoneNumber#352dafa`. Whether people will be able to see the user's phone number
See https://core.telegram.org/constructor/inputPrivacyKeyPhoneNumber for reference.
func (*InputPrivacyKeyPhoneNumber) Decode ¶
func (i *InputPrivacyKeyPhoneNumber) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyPhoneNumber) Encode ¶
func (i *InputPrivacyKeyPhoneNumber) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyPhoneNumber) String ¶ added in v0.12.0
func (i *InputPrivacyKeyPhoneNumber) String() string
String implements fmt.Stringer.
type InputPrivacyKeyPhoneP2P ¶
type InputPrivacyKeyPhoneP2P struct {
}
InputPrivacyKeyPhoneP2P represents TL type `inputPrivacyKeyPhoneP2P#db9e70d2`. Whether the user allows P2P communication during VoIP calls
See https://core.telegram.org/constructor/inputPrivacyKeyPhoneP2P for reference.
func (*InputPrivacyKeyPhoneP2P) Decode ¶
func (i *InputPrivacyKeyPhoneP2P) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyPhoneP2P) Encode ¶
func (i *InputPrivacyKeyPhoneP2P) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyPhoneP2P) String ¶ added in v0.12.0
func (i *InputPrivacyKeyPhoneP2P) String() string
String implements fmt.Stringer.
type InputPrivacyKeyProfilePhoto ¶
type InputPrivacyKeyProfilePhoto struct {
}
InputPrivacyKeyProfilePhoto represents TL type `inputPrivacyKeyProfilePhoto#5719bacc`. Whether people will be able to see the user's profile picture
See https://core.telegram.org/constructor/inputPrivacyKeyProfilePhoto for reference.
func (*InputPrivacyKeyProfilePhoto) Decode ¶
func (i *InputPrivacyKeyProfilePhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyProfilePhoto) Encode ¶
func (i *InputPrivacyKeyProfilePhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyProfilePhoto) String ¶ added in v0.12.0
func (i *InputPrivacyKeyProfilePhoto) String() string
String implements fmt.Stringer.
type InputPrivacyKeyStatusTimestamp ¶
type InputPrivacyKeyStatusTimestamp struct {
}
InputPrivacyKeyStatusTimestamp represents TL type `inputPrivacyKeyStatusTimestamp#4f96cb18`. Whether we can see the exact last online timestamp of the user
See https://core.telegram.org/constructor/inputPrivacyKeyStatusTimestamp for reference.
func (*InputPrivacyKeyStatusTimestamp) Decode ¶
func (i *InputPrivacyKeyStatusTimestamp) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyKeyStatusTimestamp) Encode ¶
func (i *InputPrivacyKeyStatusTimestamp) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyKeyStatusTimestamp) String ¶ added in v0.12.0
func (i *InputPrivacyKeyStatusTimestamp) String() string
String implements fmt.Stringer.
type InputPrivacyRuleBox ¶
type InputPrivacyRuleBox struct {
InputPrivacyRule InputPrivacyRuleClass
}
InputPrivacyRule boxes the InputPrivacyRuleClass providing a helper.
type InputPrivacyRuleClass ¶
type InputPrivacyRuleClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputPrivacyRuleClass represents InputPrivacyRule generic type.
See https://core.telegram.org/type/InputPrivacyRule for reference.
Example:
g, err := DecodeInputPrivacyRule(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputPrivacyValueAllowContacts: // inputPrivacyValueAllowContacts#d09e07b
case *InputPrivacyValueAllowAll: // inputPrivacyValueAllowAll#184b35ce
case *InputPrivacyValueAllowUsers: // inputPrivacyValueAllowUsers#131cc67f
case *InputPrivacyValueDisallowContacts: // inputPrivacyValueDisallowContacts#ba52007
case *InputPrivacyValueDisallowAll: // inputPrivacyValueDisallowAll#d66b66c9
case *InputPrivacyValueDisallowUsers: // inputPrivacyValueDisallowUsers#90110467
case *InputPrivacyValueAllowChatParticipants: // inputPrivacyValueAllowChatParticipants#4c81c1ba
case *InputPrivacyValueDisallowChatParticipants: // inputPrivacyValueDisallowChatParticipants#d82363af
default: panic(v)
}
func DecodeInputPrivacyRule ¶
func DecodeInputPrivacyRule(buf *bin.Buffer) (InputPrivacyRuleClass, error)
DecodeInputPrivacyRule implements binary de-serialization for InputPrivacyRuleClass.
type InputPrivacyValueAllowAll ¶
type InputPrivacyValueAllowAll struct {
}
InputPrivacyValueAllowAll represents TL type `inputPrivacyValueAllowAll#184b35ce`. Allow all users
See https://core.telegram.org/constructor/inputPrivacyValueAllowAll for reference.
func (*InputPrivacyValueAllowAll) Decode ¶
func (i *InputPrivacyValueAllowAll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueAllowAll) Encode ¶
func (i *InputPrivacyValueAllowAll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueAllowAll) String ¶ added in v0.12.0
func (i *InputPrivacyValueAllowAll) String() string
String implements fmt.Stringer.
type InputPrivacyValueAllowChatParticipants ¶
type InputPrivacyValueAllowChatParticipants struct {
// Allowed chat IDs
Chats []int
}
InputPrivacyValueAllowChatParticipants represents TL type `inputPrivacyValueAllowChatParticipants#4c81c1ba`. Allow only participants of certain chats
See https://core.telegram.org/constructor/inputPrivacyValueAllowChatParticipants for reference.
func (*InputPrivacyValueAllowChatParticipants) Decode ¶
func (i *InputPrivacyValueAllowChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueAllowChatParticipants) Encode ¶
func (i *InputPrivacyValueAllowChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueAllowChatParticipants) String ¶ added in v0.12.0
func (i *InputPrivacyValueAllowChatParticipants) String() string
String implements fmt.Stringer.
type InputPrivacyValueAllowContacts ¶
type InputPrivacyValueAllowContacts struct {
}
InputPrivacyValueAllowContacts represents TL type `inputPrivacyValueAllowContacts#d09e07b`. Allow only contacts
See https://core.telegram.org/constructor/inputPrivacyValueAllowContacts for reference.
func (*InputPrivacyValueAllowContacts) Decode ¶
func (i *InputPrivacyValueAllowContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueAllowContacts) Encode ¶
func (i *InputPrivacyValueAllowContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueAllowContacts) String ¶ added in v0.12.0
func (i *InputPrivacyValueAllowContacts) String() string
String implements fmt.Stringer.
type InputPrivacyValueAllowUsers ¶
type InputPrivacyValueAllowUsers struct {
// Allowed users
Users []InputUserClass
}
InputPrivacyValueAllowUsers represents TL type `inputPrivacyValueAllowUsers#131cc67f`. Allow only certain users
See https://core.telegram.org/constructor/inputPrivacyValueAllowUsers for reference.
func (*InputPrivacyValueAllowUsers) Decode ¶
func (i *InputPrivacyValueAllowUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueAllowUsers) Encode ¶
func (i *InputPrivacyValueAllowUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueAllowUsers) String ¶ added in v0.12.0
func (i *InputPrivacyValueAllowUsers) String() string
String implements fmt.Stringer.
type InputPrivacyValueDisallowAll ¶
type InputPrivacyValueDisallowAll struct {
}
InputPrivacyValueDisallowAll represents TL type `inputPrivacyValueDisallowAll#d66b66c9`. Disallow all
See https://core.telegram.org/constructor/inputPrivacyValueDisallowAll for reference.
func (*InputPrivacyValueDisallowAll) Decode ¶
func (i *InputPrivacyValueDisallowAll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueDisallowAll) Encode ¶
func (i *InputPrivacyValueDisallowAll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueDisallowAll) String ¶ added in v0.12.0
func (i *InputPrivacyValueDisallowAll) String() string
String implements fmt.Stringer.
type InputPrivacyValueDisallowChatParticipants ¶
type InputPrivacyValueDisallowChatParticipants struct {
// Disallowed chat IDs
Chats []int
}
InputPrivacyValueDisallowChatParticipants represents TL type `inputPrivacyValueDisallowChatParticipants#d82363af`. Disallow only participants of certain chats
See https://core.telegram.org/constructor/inputPrivacyValueDisallowChatParticipants for reference.
func (*InputPrivacyValueDisallowChatParticipants) Decode ¶
func (i *InputPrivacyValueDisallowChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueDisallowChatParticipants) Encode ¶
func (i *InputPrivacyValueDisallowChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueDisallowChatParticipants) String ¶ added in v0.12.0
func (i *InputPrivacyValueDisallowChatParticipants) String() string
String implements fmt.Stringer.
type InputPrivacyValueDisallowContacts ¶
type InputPrivacyValueDisallowContacts struct {
}
InputPrivacyValueDisallowContacts represents TL type `inputPrivacyValueDisallowContacts#ba52007`. Disallow only contacts
See https://core.telegram.org/constructor/inputPrivacyValueDisallowContacts for reference.
func (*InputPrivacyValueDisallowContacts) Decode ¶
func (i *InputPrivacyValueDisallowContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueDisallowContacts) Encode ¶
func (i *InputPrivacyValueDisallowContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueDisallowContacts) String ¶ added in v0.12.0
func (i *InputPrivacyValueDisallowContacts) String() string
String implements fmt.Stringer.
type InputPrivacyValueDisallowUsers ¶
type InputPrivacyValueDisallowUsers struct {
// Users to disallow
Users []InputUserClass
}
InputPrivacyValueDisallowUsers represents TL type `inputPrivacyValueDisallowUsers#90110467`. Disallow only certain users
See https://core.telegram.org/constructor/inputPrivacyValueDisallowUsers for reference.
func (*InputPrivacyValueDisallowUsers) Decode ¶
func (i *InputPrivacyValueDisallowUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputPrivacyValueDisallowUsers) Encode ¶
func (i *InputPrivacyValueDisallowUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputPrivacyValueDisallowUsers) String ¶ added in v0.12.0
func (i *InputPrivacyValueDisallowUsers) String() string
String implements fmt.Stringer.
type InputReportReasonChildAbuse ¶
type InputReportReasonChildAbuse struct {
}
InputReportReasonChildAbuse represents TL type `inputReportReasonChildAbuse#adf44ee3`. Report for child abuse
See https://core.telegram.org/constructor/inputReportReasonChildAbuse for reference.
func (*InputReportReasonChildAbuse) Decode ¶
func (i *InputReportReasonChildAbuse) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonChildAbuse) Encode ¶
func (i *InputReportReasonChildAbuse) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonChildAbuse) String ¶ added in v0.12.0
func (i *InputReportReasonChildAbuse) String() string
String implements fmt.Stringer.
type InputReportReasonCopyright ¶
type InputReportReasonCopyright struct {
}
InputReportReasonCopyright represents TL type `inputReportReasonCopyright#9b89f93a`. Report for copyrighted content
See https://core.telegram.org/constructor/inputReportReasonCopyright for reference.
func (*InputReportReasonCopyright) Decode ¶
func (i *InputReportReasonCopyright) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonCopyright) Encode ¶
func (i *InputReportReasonCopyright) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonCopyright) String ¶ added in v0.12.0
func (i *InputReportReasonCopyright) String() string
String implements fmt.Stringer.
type InputReportReasonGeoIrrelevant ¶
type InputReportReasonGeoIrrelevant struct {
}
InputReportReasonGeoIrrelevant represents TL type `inputReportReasonGeoIrrelevant#dbd4feed`. Report an irrelevant geogroup
See https://core.telegram.org/constructor/inputReportReasonGeoIrrelevant for reference.
func (*InputReportReasonGeoIrrelevant) Decode ¶
func (i *InputReportReasonGeoIrrelevant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonGeoIrrelevant) Encode ¶
func (i *InputReportReasonGeoIrrelevant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonGeoIrrelevant) String ¶ added in v0.12.0
func (i *InputReportReasonGeoIrrelevant) String() string
String implements fmt.Stringer.
type InputReportReasonOther ¶
type InputReportReasonOther struct {
// Other report reason
Text string
}
InputReportReasonOther represents TL type `inputReportReasonOther#e1746d0a`. Other
See https://core.telegram.org/constructor/inputReportReasonOther for reference.
func (*InputReportReasonOther) Decode ¶
func (i *InputReportReasonOther) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonOther) Encode ¶
func (i *InputReportReasonOther) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonOther) String ¶ added in v0.12.0
func (i *InputReportReasonOther) String() string
String implements fmt.Stringer.
type InputReportReasonPornography ¶
type InputReportReasonPornography struct {
}
InputReportReasonPornography represents TL type `inputReportReasonPornography#2e59d922`. Report for pornography
See https://core.telegram.org/constructor/inputReportReasonPornography for reference.
func (*InputReportReasonPornography) Decode ¶
func (i *InputReportReasonPornography) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonPornography) Encode ¶
func (i *InputReportReasonPornography) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonPornography) String ¶ added in v0.12.0
func (i *InputReportReasonPornography) String() string
String implements fmt.Stringer.
type InputReportReasonSpam ¶
type InputReportReasonSpam struct {
}
InputReportReasonSpam represents TL type `inputReportReasonSpam#58dbcab8`. Report for spam
See https://core.telegram.org/constructor/inputReportReasonSpam for reference.
func (*InputReportReasonSpam) Decode ¶
func (i *InputReportReasonSpam) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonSpam) Encode ¶
func (i *InputReportReasonSpam) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonSpam) String ¶ added in v0.12.0
func (i *InputReportReasonSpam) String() string
String implements fmt.Stringer.
type InputReportReasonViolence ¶
type InputReportReasonViolence struct {
}
InputReportReasonViolence represents TL type `inputReportReasonViolence#1e22c78d`. Report for violence
See https://core.telegram.org/constructor/inputReportReasonViolence for reference.
func (*InputReportReasonViolence) Decode ¶
func (i *InputReportReasonViolence) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputReportReasonViolence) Encode ¶
func (i *InputReportReasonViolence) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputReportReasonViolence) String ¶ added in v0.12.0
func (i *InputReportReasonViolence) String() string
String implements fmt.Stringer.
type InputSecureFile ¶
type InputSecureFile struct {
// Secure file ID
ID int64
// Secure file access hash
AccessHash int64
}
InputSecureFile represents TL type `inputSecureFile#5367e5be`. Preuploaded passport¹ file, for more info see the passport docs »²
Links:
See https://core.telegram.org/constructor/inputSecureFile for reference.
func (*InputSecureFile) Decode ¶
func (i *InputSecureFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputSecureFile) Encode ¶
func (i *InputSecureFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputSecureFile) String ¶ added in v0.12.0
func (i *InputSecureFile) String() string
String implements fmt.Stringer.
type InputSecureFileBox ¶
type InputSecureFileBox struct {
InputSecureFile InputSecureFileClass
}
InputSecureFile boxes the InputSecureFileClass providing a helper.
type InputSecureFileClass ¶
type InputSecureFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputSecureFileClass represents InputSecureFile generic type.
See https://core.telegram.org/type/InputSecureFile for reference.
Example:
g, err := DecodeInputSecureFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputSecureFileUploaded: // inputSecureFileUploaded#3334b0f0
case *InputSecureFile: // inputSecureFile#5367e5be
default: panic(v)
}
func DecodeInputSecureFile ¶
func DecodeInputSecureFile(buf *bin.Buffer) (InputSecureFileClass, error)
DecodeInputSecureFile implements binary de-serialization for InputSecureFileClass.
type InputSecureFileLocation ¶
type InputSecureFileLocation struct {
// File ID, id parameter value from secureFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/secureFile
ID int64
// Checksum, access_hash parameter value from secureFile¹
//
// Links:
// 1) https://core.telegram.org/constructor/secureFile
AccessHash int64
}
InputSecureFileLocation represents TL type `inputSecureFileLocation#cbc7ee28`. Location of encrypted telegram passport¹ file.
Links:
See https://core.telegram.org/constructor/inputSecureFileLocation for reference.
func (*InputSecureFileLocation) Decode ¶
func (i *InputSecureFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputSecureFileLocation) Encode ¶
func (i *InputSecureFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputSecureFileLocation) String ¶ added in v0.12.0
func (i *InputSecureFileLocation) String() string
String implements fmt.Stringer.
type InputSecureFileUploaded ¶
type InputSecureFileUploaded struct {
// Secure file ID
ID int64
// Secure file part count
Parts int
// MD5 hash of encrypted uploaded file, to be checked server-side
Md5Checksum string
// File hash
FileHash []byte
// Secret
Secret []byte
}
InputSecureFileUploaded represents TL type `inputSecureFileUploaded#3334b0f0`. Uploaded secure file, for more info see the passport docs »¹
Links:
See https://core.telegram.org/constructor/inputSecureFileUploaded for reference.
func (*InputSecureFileUploaded) Decode ¶
func (i *InputSecureFileUploaded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputSecureFileUploaded) Encode ¶
func (i *InputSecureFileUploaded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputSecureFileUploaded) String ¶ added in v0.12.0
func (i *InputSecureFileUploaded) String() string
String implements fmt.Stringer.
type InputSecureValue ¶
type InputSecureValue struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Secure passport¹ value type
//
// Links:
// 1) https://core.telegram.org/passport
Type SecureValueTypeClass
// Encrypted Telegram Passport¹ element data
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetData and GetData helpers.
Data SecureData
// Encrypted passport¹ file with the front side of the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetFrontSide and GetFrontSide helpers.
FrontSide InputSecureFileClass
// Encrypted passport¹ file with the reverse side of the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetReverseSide and GetReverseSide helpers.
ReverseSide InputSecureFileClass
// Encrypted passport¹ file with a selfie of the user holding the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetSelfie and GetSelfie helpers.
Selfie InputSecureFileClass
// Array of encrypted passport¹ files with translated versions of the provided documents
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetTranslation and GetTranslation helpers.
Translation []InputSecureFileClass
// Array of encrypted passport¹ files with photos the of the documents
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetFiles and GetFiles helpers.
Files []InputSecureFileClass
// Plaintext verified passport¹ data
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetPlainData and GetPlainData helpers.
PlainData SecurePlainDataClass
}
InputSecureValue represents TL type `inputSecureValue#db21d0a7`. Secure value, for more info see the passport docs »¹
Links:
See https://core.telegram.org/constructor/inputSecureValue for reference.
func (*InputSecureValue) Decode ¶
func (i *InputSecureValue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputSecureValue) Encode ¶
func (i *InputSecureValue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputSecureValue) GetData ¶
func (i *InputSecureValue) GetData() (value SecureData, ok bool)
GetData returns value of Data conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetFiles ¶
func (i *InputSecureValue) GetFiles() (value []InputSecureFileClass, ok bool)
GetFiles returns value of Files conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetFrontSide ¶
func (i *InputSecureValue) GetFrontSide() (value InputSecureFileClass, ok bool)
GetFrontSide returns value of FrontSide conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetPlainData ¶
func (i *InputSecureValue) GetPlainData() (value SecurePlainDataClass, ok bool)
GetPlainData returns value of PlainData conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetReverseSide ¶
func (i *InputSecureValue) GetReverseSide() (value InputSecureFileClass, ok bool)
GetReverseSide returns value of ReverseSide conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetSelfie ¶
func (i *InputSecureValue) GetSelfie() (value InputSecureFileClass, ok bool)
GetSelfie returns value of Selfie conditional field and boolean which is true if field was set.
func (*InputSecureValue) GetTranslation ¶
func (i *InputSecureValue) GetTranslation() (value []InputSecureFileClass, ok bool)
GetTranslation returns value of Translation conditional field and boolean which is true if field was set.
func (*InputSecureValue) SetData ¶
func (i *InputSecureValue) SetData(value SecureData)
SetData sets value of Data conditional field.
func (*InputSecureValue) SetFiles ¶
func (i *InputSecureValue) SetFiles(value []InputSecureFileClass)
SetFiles sets value of Files conditional field.
func (*InputSecureValue) SetFrontSide ¶
func (i *InputSecureValue) SetFrontSide(value InputSecureFileClass)
SetFrontSide sets value of FrontSide conditional field.
func (*InputSecureValue) SetPlainData ¶
func (i *InputSecureValue) SetPlainData(value SecurePlainDataClass)
SetPlainData sets value of PlainData conditional field.
func (*InputSecureValue) SetReverseSide ¶
func (i *InputSecureValue) SetReverseSide(value InputSecureFileClass)
SetReverseSide sets value of ReverseSide conditional field.
func (*InputSecureValue) SetSelfie ¶
func (i *InputSecureValue) SetSelfie(value InputSecureFileClass)
SetSelfie sets value of Selfie conditional field.
func (*InputSecureValue) SetTranslation ¶
func (i *InputSecureValue) SetTranslation(value []InputSecureFileClass)
SetTranslation sets value of Translation conditional field.
func (*InputSecureValue) String ¶ added in v0.12.0
func (i *InputSecureValue) String() string
String implements fmt.Stringer.
type InputSingleMedia ¶
type InputSingleMedia struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The media
Media InputMediaClass
// Unique client media ID required to prevent message resending
RandomID int64
// A caption for the media
Message string
// Message entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
InputSingleMedia represents TL type `inputSingleMedia#1cc6e91f`. A single media in an album or grouped media¹ sent with messages.sendMultiMedia².
Links:
- https://core.telegram.org/api/files#albums-grouped-media
- https://core.telegram.org/method/messages.sendMultiMedia
See https://core.telegram.org/constructor/inputSingleMedia for reference.
func (*InputSingleMedia) Decode ¶
func (i *InputSingleMedia) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputSingleMedia) Encode ¶
func (i *InputSingleMedia) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputSingleMedia) GetEntities ¶
func (i *InputSingleMedia) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*InputSingleMedia) SetEntities ¶
func (i *InputSingleMedia) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*InputSingleMedia) String ¶ added in v0.12.0
func (i *InputSingleMedia) String() string
String implements fmt.Stringer.
type InputStickerSetAnimatedEmoji ¶
type InputStickerSetAnimatedEmoji struct {
}
InputStickerSetAnimatedEmoji represents TL type `inputStickerSetAnimatedEmoji#28703c8`. Animated emojis stickerset
See https://core.telegram.org/constructor/inputStickerSetAnimatedEmoji for reference.
func (*InputStickerSetAnimatedEmoji) Decode ¶
func (i *InputStickerSetAnimatedEmoji) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetAnimatedEmoji) Encode ¶
func (i *InputStickerSetAnimatedEmoji) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetAnimatedEmoji) String ¶ added in v0.12.0
func (i *InputStickerSetAnimatedEmoji) String() string
String implements fmt.Stringer.
type InputStickerSetBox ¶
type InputStickerSetBox struct {
InputStickerSet InputStickerSetClass
}
InputStickerSet boxes the InputStickerSetClass providing a helper.
type InputStickerSetClass ¶
type InputStickerSetClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputStickerSetClass represents InputStickerSet generic type.
See https://core.telegram.org/type/InputStickerSet for reference.
Example:
g, err := DecodeInputStickerSet(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputStickerSetEmpty: // inputStickerSetEmpty#ffb62b95
case *InputStickerSetID: // inputStickerSetID#9de7a269
case *InputStickerSetShortName: // inputStickerSetShortName#861cc8a0
case *InputStickerSetAnimatedEmoji: // inputStickerSetAnimatedEmoji#28703c8
case *InputStickerSetDice: // inputStickerSetDice#e67f520e
default: panic(v)
}
func DecodeInputStickerSet ¶
func DecodeInputStickerSet(buf *bin.Buffer) (InputStickerSetClass, error)
DecodeInputStickerSet implements binary de-serialization for InputStickerSetClass.
type InputStickerSetDice ¶
type InputStickerSetDice struct {
// The emoji, for now , and are supported
Emoticon string
}
InputStickerSetDice represents TL type `inputStickerSetDice#e67f520e`. Used for fetching animated dice stickers¹
Links:
See https://core.telegram.org/constructor/inputStickerSetDice for reference.
func (*InputStickerSetDice) Decode ¶
func (i *InputStickerSetDice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetDice) Encode ¶
func (i *InputStickerSetDice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetDice) String ¶ added in v0.12.0
func (i *InputStickerSetDice) String() string
String implements fmt.Stringer.
type InputStickerSetEmpty ¶
type InputStickerSetEmpty struct {
}
InputStickerSetEmpty represents TL type `inputStickerSetEmpty#ffb62b95`. Empty constructor
See https://core.telegram.org/constructor/inputStickerSetEmpty for reference.
func (*InputStickerSetEmpty) Decode ¶
func (i *InputStickerSetEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetEmpty) Encode ¶
func (i *InputStickerSetEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetEmpty) String ¶ added in v0.12.0
func (i *InputStickerSetEmpty) String() string
String implements fmt.Stringer.
type InputStickerSetID ¶
InputStickerSetID represents TL type `inputStickerSetID#9de7a269`. Stickerset by ID
See https://core.telegram.org/constructor/inputStickerSetID for reference.
func (*InputStickerSetID) Decode ¶
func (i *InputStickerSetID) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetID) Encode ¶
func (i *InputStickerSetID) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetID) String ¶ added in v0.12.0
func (i *InputStickerSetID) String() string
String implements fmt.Stringer.
type InputStickerSetItem ¶
type InputStickerSetItem struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The sticker
Document InputDocumentClass
// Associated emoji
Emoji string
// Coordinates for mask sticker
//
// Use SetMaskCoords and GetMaskCoords helpers.
MaskCoords MaskCoords
}
InputStickerSetItem represents TL type `inputStickerSetItem#ffa0a496`. Sticker in a stickerset
See https://core.telegram.org/constructor/inputStickerSetItem for reference.
func (*InputStickerSetItem) Decode ¶
func (i *InputStickerSetItem) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetItem) Encode ¶
func (i *InputStickerSetItem) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetItem) GetMaskCoords ¶
func (i *InputStickerSetItem) GetMaskCoords() (value MaskCoords, ok bool)
GetMaskCoords returns value of MaskCoords conditional field and boolean which is true if field was set.
func (*InputStickerSetItem) SetMaskCoords ¶
func (i *InputStickerSetItem) SetMaskCoords(value MaskCoords)
SetMaskCoords sets value of MaskCoords conditional field.
func (*InputStickerSetItem) String ¶ added in v0.12.0
func (i *InputStickerSetItem) String() string
String implements fmt.Stringer.
type InputStickerSetShortName ¶
type InputStickerSetShortName struct {
// From tg://addstickers?set=short_name
ShortName string
}
InputStickerSetShortName represents TL type `inputStickerSetShortName#861cc8a0`. Stickerset by short name, from tg://addstickers?set=short_name
See https://core.telegram.org/constructor/inputStickerSetShortName for reference.
func (*InputStickerSetShortName) Decode ¶
func (i *InputStickerSetShortName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetShortName) Encode ¶
func (i *InputStickerSetShortName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetShortName) String ¶ added in v0.12.0
func (i *InputStickerSetShortName) String() string
String implements fmt.Stringer.
type InputStickerSetThumb ¶
type InputStickerSetThumb struct {
// Sticker set
Stickerset InputStickerSetClass
// Volume ID
VolumeID int64
// Local ID
LocalID int
}
InputStickerSetThumb represents TL type `inputStickerSetThumb#dbaeae9`. Location of stickerset thumbnail (see files¹)
Links:
See https://core.telegram.org/constructor/inputStickerSetThumb for reference.
func (*InputStickerSetThumb) Decode ¶
func (i *InputStickerSetThumb) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickerSetThumb) Encode ¶
func (i *InputStickerSetThumb) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickerSetThumb) String ¶ added in v0.12.0
func (i *InputStickerSetThumb) String() string
String implements fmt.Stringer.
type InputStickeredMediaBox ¶
type InputStickeredMediaBox struct {
InputStickeredMedia InputStickeredMediaClass
}
InputStickeredMedia boxes the InputStickeredMediaClass providing a helper.
type InputStickeredMediaClass ¶
type InputStickeredMediaClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputStickeredMediaClass represents InputStickeredMedia generic type.
See https://core.telegram.org/type/InputStickeredMedia for reference.
Example:
g, err := DecodeInputStickeredMedia(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputStickeredMediaPhoto: // inputStickeredMediaPhoto#4a992157
case *InputStickeredMediaDocument: // inputStickeredMediaDocument#438865b
default: panic(v)
}
func DecodeInputStickeredMedia ¶
func DecodeInputStickeredMedia(buf *bin.Buffer) (InputStickeredMediaClass, error)
DecodeInputStickeredMedia implements binary de-serialization for InputStickeredMediaClass.
type InputStickeredMediaDocument ¶
type InputStickeredMediaDocument struct {
// The document
ID InputDocumentClass
}
InputStickeredMediaDocument represents TL type `inputStickeredMediaDocument#438865b`. A document with stickers attached
See https://core.telegram.org/constructor/inputStickeredMediaDocument for reference.
func (*InputStickeredMediaDocument) Decode ¶
func (i *InputStickeredMediaDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickeredMediaDocument) Encode ¶
func (i *InputStickeredMediaDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickeredMediaDocument) String ¶ added in v0.12.0
func (i *InputStickeredMediaDocument) String() string
String implements fmt.Stringer.
type InputStickeredMediaPhoto ¶
type InputStickeredMediaPhoto struct {
// The photo
ID InputPhotoClass
}
InputStickeredMediaPhoto represents TL type `inputStickeredMediaPhoto#4a992157`. A photo with stickers attached
See https://core.telegram.org/constructor/inputStickeredMediaPhoto for reference.
func (*InputStickeredMediaPhoto) Decode ¶
func (i *InputStickeredMediaPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputStickeredMediaPhoto) Encode ¶
func (i *InputStickeredMediaPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputStickeredMediaPhoto) String ¶ added in v0.12.0
func (i *InputStickeredMediaPhoto) String() string
String implements fmt.Stringer.
type InputTakeoutFileLocation ¶
type InputTakeoutFileLocation struct {
}
InputTakeoutFileLocation represents TL type `inputTakeoutFileLocation#29be5899`. Empty constructor for takeout
See https://core.telegram.org/constructor/inputTakeoutFileLocation for reference.
func (*InputTakeoutFileLocation) Decode ¶
func (i *InputTakeoutFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputTakeoutFileLocation) Encode ¶
func (i *InputTakeoutFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputTakeoutFileLocation) String ¶ added in v0.12.0
func (i *InputTakeoutFileLocation) String() string
String implements fmt.Stringer.
type InputTheme ¶
InputTheme represents TL type `inputTheme#3c5693e9`. Theme
See https://core.telegram.org/constructor/inputTheme for reference.
func (*InputTheme) Decode ¶
func (i *InputTheme) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputTheme) Encode ¶
func (i *InputTheme) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputTheme) String ¶ added in v0.12.0
func (i *InputTheme) String() string
String implements fmt.Stringer.
type InputThemeBox ¶
type InputThemeBox struct {
InputTheme InputThemeClass
}
InputTheme boxes the InputThemeClass providing a helper.
type InputThemeClass ¶
type InputThemeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputThemeClass represents InputTheme generic type.
See https://core.telegram.org/type/InputTheme for reference.
Example:
g, err := DecodeInputTheme(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputTheme: // inputTheme#3c5693e9
case *InputThemeSlug: // inputThemeSlug#f5890df1
default: panic(v)
}
func DecodeInputTheme ¶
func DecodeInputTheme(buf *bin.Buffer) (InputThemeClass, error)
DecodeInputTheme implements binary de-serialization for InputThemeClass.
type InputThemeSettings ¶
type InputThemeSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Default theme on which this theme is based
BaseTheme BaseThemeClass
// Accent color, RGB24 format
AccentColor int
// Message gradient color (top), RGB24 format
//
// Use SetMessageTopColor and GetMessageTopColor helpers.
MessageTopColor int
// Message gradient color (bottom), RGB24 format
//
// Use SetMessageBottomColor and GetMessageBottomColor helpers.
MessageBottomColor int
// Wallpaper
//
// Use SetWallpaper and GetWallpaper helpers.
Wallpaper InputWallPaperClass
// Wallpaper settings
//
// Use SetWallpaperSettings and GetWallpaperSettings helpers.
WallpaperSettings WallPaperSettings
}
InputThemeSettings represents TL type `inputThemeSettings#bd507cd1`. Theme settings
See https://core.telegram.org/constructor/inputThemeSettings for reference.
func (*InputThemeSettings) Decode ¶
func (i *InputThemeSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputThemeSettings) Encode ¶
func (i *InputThemeSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputThemeSettings) GetMessageBottomColor ¶
func (i *InputThemeSettings) GetMessageBottomColor() (value int, ok bool)
GetMessageBottomColor returns value of MessageBottomColor conditional field and boolean which is true if field was set.
func (*InputThemeSettings) GetMessageTopColor ¶
func (i *InputThemeSettings) GetMessageTopColor() (value int, ok bool)
GetMessageTopColor returns value of MessageTopColor conditional field and boolean which is true if field was set.
func (*InputThemeSettings) GetWallpaper ¶
func (i *InputThemeSettings) GetWallpaper() (value InputWallPaperClass, ok bool)
GetWallpaper returns value of Wallpaper conditional field and boolean which is true if field was set.
func (*InputThemeSettings) GetWallpaperSettings ¶
func (i *InputThemeSettings) GetWallpaperSettings() (value WallPaperSettings, ok bool)
GetWallpaperSettings returns value of WallpaperSettings conditional field and boolean which is true if field was set.
func (*InputThemeSettings) SetMessageBottomColor ¶
func (i *InputThemeSettings) SetMessageBottomColor(value int)
SetMessageBottomColor sets value of MessageBottomColor conditional field.
func (*InputThemeSettings) SetMessageTopColor ¶
func (i *InputThemeSettings) SetMessageTopColor(value int)
SetMessageTopColor sets value of MessageTopColor conditional field.
func (*InputThemeSettings) SetWallpaper ¶
func (i *InputThemeSettings) SetWallpaper(value InputWallPaperClass)
SetWallpaper sets value of Wallpaper conditional field.
func (*InputThemeSettings) SetWallpaperSettings ¶
func (i *InputThemeSettings) SetWallpaperSettings(value WallPaperSettings)
SetWallpaperSettings sets value of WallpaperSettings conditional field.
func (*InputThemeSettings) String ¶ added in v0.12.0
func (i *InputThemeSettings) String() string
String implements fmt.Stringer.
type InputThemeSlug ¶
type InputThemeSlug struct {
// Unique theme ID
Slug string
}
InputThemeSlug represents TL type `inputThemeSlug#f5890df1`. Theme by theme ID
See https://core.telegram.org/constructor/inputThemeSlug for reference.
func (*InputThemeSlug) Decode ¶
func (i *InputThemeSlug) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputThemeSlug) Encode ¶
func (i *InputThemeSlug) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputThemeSlug) String ¶ added in v0.12.0
func (i *InputThemeSlug) String() string
String implements fmt.Stringer.
type InputUser ¶
type InputUser struct {
// User identifier
UserID int
// access_hash value from the user¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/user
AccessHash int64
}
InputUser represents TL type `inputUser#d8292816`. Defines a user for further interaction.
See https://core.telegram.org/constructor/inputUser for reference.
type InputUserBox ¶
type InputUserBox struct {
InputUser InputUserClass
}
InputUser boxes the InputUserClass providing a helper.
type InputUserClass ¶
type InputUserClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputUserClass represents InputUser generic type.
See https://core.telegram.org/type/InputUser for reference.
Example:
g, err := DecodeInputUser(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputUserEmpty: // inputUserEmpty#b98886cf
case *InputUserSelf: // inputUserSelf#f7c1b13f
case *InputUser: // inputUser#d8292816
case *InputUserFromMessage: // inputUserFromMessage#2d117597
default: panic(v)
}
func DecodeInputUser ¶
func DecodeInputUser(buf *bin.Buffer) (InputUserClass, error)
DecodeInputUser implements binary de-serialization for InputUserClass.
type InputUserEmpty ¶
type InputUserEmpty struct {
}
InputUserEmpty represents TL type `inputUserEmpty#b98886cf`. Empty constructor, does not define a user.
See https://core.telegram.org/constructor/inputUserEmpty for reference.
func (*InputUserEmpty) Decode ¶
func (i *InputUserEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputUserEmpty) Encode ¶
func (i *InputUserEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputUserEmpty) String ¶ added in v0.12.0
func (i *InputUserEmpty) String() string
String implements fmt.Stringer.
type InputUserFromMessage ¶
type InputUserFromMessage struct {
// The chat where the user was seen
Peer InputPeerClass
// The message ID
MsgID int
// The identifier of the user that was seen
UserID int
}
InputUserFromMessage represents TL type `inputUserFromMessage#2d117597`. Defines a min¹ user that was seen in a certain message of a certain chat.
Links:
See https://core.telegram.org/constructor/inputUserFromMessage for reference.
func (*InputUserFromMessage) Decode ¶
func (i *InputUserFromMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputUserFromMessage) Encode ¶
func (i *InputUserFromMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputUserFromMessage) String ¶ added in v0.12.0
func (i *InputUserFromMessage) String() string
String implements fmt.Stringer.
type InputUserSelf ¶
type InputUserSelf struct {
}
InputUserSelf represents TL type `inputUserSelf#f7c1b13f`. Defines the current user.
See https://core.telegram.org/constructor/inputUserSelf for reference.
func (*InputUserSelf) Decode ¶
func (i *InputUserSelf) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputUserSelf) Encode ¶
func (i *InputUserSelf) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputUserSelf) String ¶ added in v0.12.0
func (i *InputUserSelf) String() string
String implements fmt.Stringer.
type InputWallPaper ¶
InputWallPaper represents TL type `inputWallPaper#e630b979`. Wallpaper
See https://core.telegram.org/constructor/inputWallPaper for reference.
func (*InputWallPaper) Decode ¶
func (i *InputWallPaper) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWallPaper) Encode ¶
func (i *InputWallPaper) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWallPaper) String ¶ added in v0.12.0
func (i *InputWallPaper) String() string
String implements fmt.Stringer.
type InputWallPaperBox ¶
type InputWallPaperBox struct {
InputWallPaper InputWallPaperClass
}
InputWallPaper boxes the InputWallPaperClass providing a helper.
type InputWallPaperClass ¶
type InputWallPaperClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputWallPaperClass represents InputWallPaper generic type.
See https://core.telegram.org/type/InputWallPaper for reference.
Example:
g, err := DecodeInputWallPaper(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputWallPaper: // inputWallPaper#e630b979
case *InputWallPaperSlug: // inputWallPaperSlug#72091c80
case *InputWallPaperNoFile: // inputWallPaperNoFile#8427bbac
default: panic(v)
}
func DecodeInputWallPaper ¶
func DecodeInputWallPaper(buf *bin.Buffer) (InputWallPaperClass, error)
DecodeInputWallPaper implements binary de-serialization for InputWallPaperClass.
type InputWallPaperNoFile ¶
type InputWallPaperNoFile struct {
}
InputWallPaperNoFile represents TL type `inputWallPaperNoFile#8427bbac`. Wallpaper with no file
See https://core.telegram.org/constructor/inputWallPaperNoFile for reference.
func (*InputWallPaperNoFile) Decode ¶
func (i *InputWallPaperNoFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWallPaperNoFile) Encode ¶
func (i *InputWallPaperNoFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWallPaperNoFile) String ¶ added in v0.12.0
func (i *InputWallPaperNoFile) String() string
String implements fmt.Stringer.
type InputWallPaperSlug ¶
type InputWallPaperSlug struct {
// Unique wallpaper ID
Slug string
}
InputWallPaperSlug represents TL type `inputWallPaperSlug#72091c80`. Wallpaper by slug (a unique ID)
See https://core.telegram.org/constructor/inputWallPaperSlug for reference.
func (*InputWallPaperSlug) Decode ¶
func (i *InputWallPaperSlug) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWallPaperSlug) Encode ¶
func (i *InputWallPaperSlug) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWallPaperSlug) String ¶ added in v0.12.0
func (i *InputWallPaperSlug) String() string
String implements fmt.Stringer.
type InputWebDocument ¶
type InputWebDocument struct {
// Remote document URL to be downloaded using the appropriate method¹
//
// Links:
// 1) https://core.telegram.org/api/files
URL string
// Remote file size
Size int
// Mime type
MimeType string
// Attributes for media types
Attributes []DocumentAttributeClass
}
InputWebDocument represents TL type `inputWebDocument#9bed434d`. The document
See https://core.telegram.org/constructor/inputWebDocument for reference.
func (*InputWebDocument) Decode ¶
func (i *InputWebDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWebDocument) Encode ¶
func (i *InputWebDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWebDocument) String ¶ added in v0.12.0
func (i *InputWebDocument) String() string
String implements fmt.Stringer.
type InputWebFileGeoPointLocation ¶
type InputWebFileGeoPointLocation struct {
// Geolocation
GeoPoint InputGeoPointClass
// Access hash
AccessHash int64
// Map width in pixels before applying scale; 16-1024
W int
// Map height in pixels before applying scale; 16-1024
H int
// Map zoom level; 13-20
Zoom int
// Map scale; 1-3
Scale int
}
InputWebFileGeoPointLocation represents TL type `inputWebFileGeoPointLocation#9f2221c9`. Geolocation
See https://core.telegram.org/constructor/inputWebFileGeoPointLocation for reference.
func (*InputWebFileGeoPointLocation) Decode ¶
func (i *InputWebFileGeoPointLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWebFileGeoPointLocation) Encode ¶
func (i *InputWebFileGeoPointLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWebFileGeoPointLocation) String ¶ added in v0.12.0
func (i *InputWebFileGeoPointLocation) String() string
String implements fmt.Stringer.
type InputWebFileLocation ¶
InputWebFileLocation represents TL type `inputWebFileLocation#c239d686`. Location of a remote HTTP(s) file
See https://core.telegram.org/constructor/inputWebFileLocation for reference.
func (*InputWebFileLocation) Decode ¶
func (i *InputWebFileLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InputWebFileLocation) Encode ¶
func (i *InputWebFileLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InputWebFileLocation) String ¶ added in v0.12.0
func (i *InputWebFileLocation) String() string
String implements fmt.Stringer.
type InputWebFileLocationBox ¶
type InputWebFileLocationBox struct {
InputWebFileLocation InputWebFileLocationClass
}
InputWebFileLocation boxes the InputWebFileLocationClass providing a helper.
type InputWebFileLocationClass ¶
type InputWebFileLocationClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
InputWebFileLocationClass represents InputWebFileLocation generic type.
See https://core.telegram.org/type/InputWebFileLocation for reference.
Example:
g, err := DecodeInputWebFileLocation(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputWebFileLocation: // inputWebFileLocation#c239d686
case *InputWebFileGeoPointLocation: // inputWebFileGeoPointLocation#9f2221c9
default: panic(v)
}
func DecodeInputWebFileLocation ¶
func DecodeInputWebFileLocation(buf *bin.Buffer) (InputWebFileLocationClass, error)
DecodeInputWebFileLocation implements binary de-serialization for InputWebFileLocationClass.
type IntVector ¶ added in v0.8.0
type IntVector struct {
// Elements of Vector<int>
Elems []int
}
IntVector is a box for Vector<int>
type Invoice ¶
type Invoice struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Test invoice
Test bool
// Set this flag if you require the user's full name to complete the order
NameRequested bool
// Set this flag if you require the user's phone number to complete the order
PhoneRequested bool
// Set this flag if you require the user's email address to complete the order
EmailRequested bool
// Set this flag if you require the user's shipping address to complete the order
ShippingAddressRequested bool
// Set this flag if the final price depends on the shipping method
Flexible bool
// Set this flag if user's phone number should be sent to provider
PhoneToProvider bool
// Set this flag if user's email address should be sent to provider
EmailToProvider bool
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Price breakdown, a list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.)
Prices []LabeledPrice
}
Invoice represents TL type `invoice#c30aa358`. Invoice
See https://core.telegram.org/constructor/invoice for reference.
func (*Invoice) SetEmailRequested ¶
SetEmailRequested sets value of EmailRequested conditional field.
func (*Invoice) SetEmailToProvider ¶
SetEmailToProvider sets value of EmailToProvider conditional field.
func (*Invoice) SetFlexible ¶
SetFlexible sets value of Flexible conditional field.
func (*Invoice) SetNameRequested ¶
SetNameRequested sets value of NameRequested conditional field.
func (*Invoice) SetPhoneRequested ¶
SetPhoneRequested sets value of PhoneRequested conditional field.
func (*Invoice) SetPhoneToProvider ¶
SetPhoneToProvider sets value of PhoneToProvider conditional field.
func (*Invoice) SetShippingAddressRequested ¶
SetShippingAddressRequested sets value of ShippingAddressRequested conditional field.
type InvokeAfterMsgRequest ¶ added in v0.18.0
type InvokeAfterMsgRequest struct {
// Message identifier on which a current query depends
MsgID int64
// The query itself
Query bin.Object
}
InvokeAfterMsgRequest represents TL type `invokeAfterMsg#cb9f372d`. Invokes a query after successfull completion of one of the previous queries.
See https://core.telegram.org/constructor/invokeAfterMsg for reference.
func (*InvokeAfterMsgRequest) Decode ¶ added in v0.18.0
func (i *InvokeAfterMsgRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeAfterMsgRequest) Encode ¶ added in v0.18.0
func (i *InvokeAfterMsgRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeAfterMsgRequest) String ¶ added in v0.18.0
func (i *InvokeAfterMsgRequest) String() string
String implements fmt.Stringer.
type InvokeAfterMsgsRequest ¶ added in v0.18.0
type InvokeAfterMsgsRequest struct {
// List of messages on which a current query depends
MsgIds []int64
// The query itself
Query bin.Object
}
InvokeAfterMsgsRequest represents TL type `invokeAfterMsgs#3dc4b4f0`. Invokes a query after a successfull completion of previous queries
See https://core.telegram.org/constructor/invokeAfterMsgs for reference.
func (*InvokeAfterMsgsRequest) Decode ¶ added in v0.18.0
func (i *InvokeAfterMsgsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeAfterMsgsRequest) Encode ¶ added in v0.18.0
func (i *InvokeAfterMsgsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeAfterMsgsRequest) String ¶ added in v0.18.0
func (i *InvokeAfterMsgsRequest) String() string
String implements fmt.Stringer.
type InvokeWithLayerRequest ¶ added in v0.18.0
InvokeWithLayerRequest represents TL type `invokeWithLayer#da9b0d0d`. Invoke the specified query using the specified API layer¹
Links:
See https://core.telegram.org/constructor/invokeWithLayer for reference.
func (*InvokeWithLayerRequest) Decode ¶ added in v0.18.0
func (i *InvokeWithLayerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeWithLayerRequest) Encode ¶ added in v0.18.0
func (i *InvokeWithLayerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeWithLayerRequest) String ¶ added in v0.18.0
func (i *InvokeWithLayerRequest) String() string
String implements fmt.Stringer.
type InvokeWithMessagesRangeRequest ¶ added in v0.18.0
type InvokeWithMessagesRangeRequest struct {
// Message range
Range MessageRange
// Query
Query bin.Object
}
InvokeWithMessagesRangeRequest represents TL type `invokeWithMessagesRange#365275f2`. Invoke with the given message range
See https://core.telegram.org/constructor/invokeWithMessagesRange for reference.
func (*InvokeWithMessagesRangeRequest) Decode ¶ added in v0.18.0
func (i *InvokeWithMessagesRangeRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeWithMessagesRangeRequest) Encode ¶ added in v0.18.0
func (i *InvokeWithMessagesRangeRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeWithMessagesRangeRequest) String ¶ added in v0.18.0
func (i *InvokeWithMessagesRangeRequest) String() string
String implements fmt.Stringer.
type InvokeWithTakeoutRequest ¶ added in v0.18.0
type InvokeWithTakeoutRequest struct {
// Takeout session ID
TakeoutID int64
// Query
Query bin.Object
}
InvokeWithTakeoutRequest represents TL type `invokeWithTakeout#aca9fd2e`. Invoke a method within a takeout session
See https://core.telegram.org/constructor/invokeWithTakeout for reference.
func (*InvokeWithTakeoutRequest) Decode ¶ added in v0.18.0
func (i *InvokeWithTakeoutRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeWithTakeoutRequest) Encode ¶ added in v0.18.0
func (i *InvokeWithTakeoutRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeWithTakeoutRequest) String ¶ added in v0.18.0
func (i *InvokeWithTakeoutRequest) String() string
String implements fmt.Stringer.
type InvokeWithoutUpdatesRequest ¶ added in v0.18.0
InvokeWithoutUpdatesRequest represents TL type `invokeWithoutUpdates#bf9459b7`. Invoke a request without subscribing the used connection for updates¹ (this is enabled by default for file queries²).
Links:
See https://core.telegram.org/constructor/invokeWithoutUpdates for reference.
func (*InvokeWithoutUpdatesRequest) Decode ¶ added in v0.18.0
func (i *InvokeWithoutUpdatesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*InvokeWithoutUpdatesRequest) Encode ¶ added in v0.18.0
func (i *InvokeWithoutUpdatesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*InvokeWithoutUpdatesRequest) String ¶ added in v0.18.0
func (i *InvokeWithoutUpdatesRequest) String() string
String implements fmt.Stringer.
type Invoker ¶
type Invoker interface {
InvokeRaw(ctx context.Context, input bin.Encoder, output bin.Decoder) error
}
Invoker can invoke raw MTProto rpc calls.
type JSONValueBox ¶
type JSONValueBox struct {
JSONValue JSONValueClass
}
JSONValue boxes the JSONValueClass providing a helper.
type JSONValueClass ¶
type JSONValueClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
JSONValueClass represents JSONValue generic type.
See https://core.telegram.org/type/JSONValue for reference.
Example:
g, err := DecodeJSONValue(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *JsonNull: // jsonNull#3f6d7b68
case *JsonBool: // jsonBool#c7345e6a
case *JsonNumber: // jsonNumber#2be0dfa4
case *JsonString: // jsonString#b71e767a
case *JsonArray: // jsonArray#f7444763
case *JsonObject: // jsonObject#99c1d49d
default: panic(v)
}
func DecodeJSONValue ¶
func DecodeJSONValue(buf *bin.Buffer) (JSONValueClass, error)
DecodeJSONValue implements binary de-serialization for JSONValueClass.
type JsonArray ¶
type JsonArray struct {
// JSON values
Value []JSONValueClass
}
JsonArray represents TL type `jsonArray#f7444763`. JSON array
See https://core.telegram.org/constructor/jsonArray for reference.
type JsonBool ¶
type JsonBool struct {
// Value
Value bool
}
JsonBool represents TL type `jsonBool#c7345e6a`. JSON boolean value
See https://core.telegram.org/constructor/jsonBool for reference.
type JsonNull ¶
type JsonNull struct {
}
JsonNull represents TL type `jsonNull#3f6d7b68`. null JSON value
See https://core.telegram.org/constructor/jsonNull for reference.
type JsonNumber ¶
type JsonNumber struct {
// Value
Value float64
}
JsonNumber represents TL type `jsonNumber#2be0dfa4`. JSON numeric value
See https://core.telegram.org/constructor/jsonNumber for reference.
func (*JsonNumber) Decode ¶
func (j *JsonNumber) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*JsonNumber) Encode ¶
func (j *JsonNumber) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*JsonNumber) String ¶ added in v0.12.0
func (j *JsonNumber) String() string
String implements fmt.Stringer.
type JsonObject ¶
type JsonObject struct {
// Values
Value []JsonObjectValue
}
JsonObject represents TL type `jsonObject#99c1d49d`. JSON object value
See https://core.telegram.org/constructor/jsonObject for reference.
func (*JsonObject) Decode ¶
func (j *JsonObject) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*JsonObject) Encode ¶
func (j *JsonObject) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*JsonObject) String ¶ added in v0.12.0
func (j *JsonObject) String() string
String implements fmt.Stringer.
type JsonObjectValue ¶
type JsonObjectValue struct {
// Key
Key string
// Value
Value JSONValueClass
}
JsonObjectValue represents TL type `jsonObjectValue#c0de1bd9`. JSON key: value pair
See https://core.telegram.org/constructor/jsonObjectValue for reference.
func (*JsonObjectValue) Decode ¶
func (j *JsonObjectValue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*JsonObjectValue) Encode ¶
func (j *JsonObjectValue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*JsonObjectValue) String ¶ added in v0.12.0
func (j *JsonObjectValue) String() string
String implements fmt.Stringer.
type JsonString ¶
type JsonString struct {
// Value
Value string
}
JsonString represents TL type `jsonString#b71e767a`. JSON string
See https://core.telegram.org/constructor/jsonString for reference.
func (*JsonString) Decode ¶
func (j *JsonString) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*JsonString) Encode ¶
func (j *JsonString) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*JsonString) String ¶ added in v0.12.0
func (j *JsonString) String() string
String implements fmt.Stringer.
type KeyboardButton ¶
type KeyboardButton struct {
// Button text
Text string
}
KeyboardButton represents TL type `keyboardButton#a2fa4880`. Bot keyboard button
See https://core.telegram.org/constructor/keyboardButton for reference.
func (*KeyboardButton) Decode ¶
func (k *KeyboardButton) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButton) Encode ¶
func (k *KeyboardButton) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButton) String ¶ added in v0.12.0
func (k *KeyboardButton) String() string
String implements fmt.Stringer.
type KeyboardButtonBox ¶
type KeyboardButtonBox struct {
KeyboardButton KeyboardButtonClass
}
KeyboardButton boxes the KeyboardButtonClass providing a helper.
type KeyboardButtonBuy ¶
type KeyboardButtonBuy struct {
// Button text
Text string
}
KeyboardButtonBuy represents TL type `keyboardButtonBuy#afd93fbb`. Button to buy a product
See https://core.telegram.org/constructor/keyboardButtonBuy for reference.
func (*KeyboardButtonBuy) Decode ¶
func (k *KeyboardButtonBuy) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonBuy) Encode ¶
func (k *KeyboardButtonBuy) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonBuy) String ¶ added in v0.12.0
func (k *KeyboardButtonBuy) String() string
String implements fmt.Stringer.
type KeyboardButtonCallback ¶
type KeyboardButtonCallback struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user should verify his identity by entering his 2FA SRP parameters¹ to the messages.getBotCallbackAnswer² method. NOTE: telegram and the bot WILL NOT have access to the plaintext password, thanks to SRP³. This button is mainly used by the official @botfather⁴ bot, for verifying the user's identity before transferring ownership of a bot to another user.
//
// Links:
// 1) https://core.telegram.org/api/srp
// 2) https://core.telegram.org/method/messages.getBotCallbackAnswer
// 3) https://core.telegram.org/api/srp
// 4) https://t.me/botfather
RequiresPassword bool
// Button text
Text string
// Callback data
Data []byte
}
KeyboardButtonCallback represents TL type `keyboardButtonCallback#35bbdb6b`. Callback button
See https://core.telegram.org/constructor/keyboardButtonCallback for reference.
func (*KeyboardButtonCallback) Decode ¶
func (k *KeyboardButtonCallback) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonCallback) Encode ¶
func (k *KeyboardButtonCallback) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonCallback) SetRequiresPassword ¶
func (k *KeyboardButtonCallback) SetRequiresPassword(value bool)
SetRequiresPassword sets value of RequiresPassword conditional field.
func (*KeyboardButtonCallback) String ¶ added in v0.12.0
func (k *KeyboardButtonCallback) String() string
String implements fmt.Stringer.
type KeyboardButtonClass ¶
type KeyboardButtonClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
KeyboardButtonClass represents KeyboardButton generic type.
See https://core.telegram.org/type/KeyboardButton for reference.
Example:
g, err := DecodeKeyboardButton(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *KeyboardButton: // keyboardButton#a2fa4880
case *KeyboardButtonUrl: // keyboardButtonUrl#258aff05
case *KeyboardButtonCallback: // keyboardButtonCallback#35bbdb6b
case *KeyboardButtonRequestPhone: // keyboardButtonRequestPhone#b16a6c29
case *KeyboardButtonRequestGeoLocation: // keyboardButtonRequestGeoLocation#fc796b3f
case *KeyboardButtonSwitchInline: // keyboardButtonSwitchInline#568a748
case *KeyboardButtonGame: // keyboardButtonGame#50f41ccf
case *KeyboardButtonBuy: // keyboardButtonBuy#afd93fbb
case *KeyboardButtonUrlAuth: // keyboardButtonUrlAuth#10b78d29
case *InputKeyboardButtonUrlAuth: // inputKeyboardButtonUrlAuth#d02e7fd4
case *KeyboardButtonRequestPoll: // keyboardButtonRequestPoll#bbc7515d
default: panic(v)
}
func DecodeKeyboardButton ¶
func DecodeKeyboardButton(buf *bin.Buffer) (KeyboardButtonClass, error)
DecodeKeyboardButton implements binary de-serialization for KeyboardButtonClass.
type KeyboardButtonGame ¶
type KeyboardButtonGame struct {
// Button text
Text string
}
KeyboardButtonGame represents TL type `keyboardButtonGame#50f41ccf`. Button to start a game
See https://core.telegram.org/constructor/keyboardButtonGame for reference.
func (*KeyboardButtonGame) Decode ¶
func (k *KeyboardButtonGame) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonGame) Encode ¶
func (k *KeyboardButtonGame) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonGame) String ¶ added in v0.12.0
func (k *KeyboardButtonGame) String() string
String implements fmt.Stringer.
type KeyboardButtonRequestGeoLocation ¶
type KeyboardButtonRequestGeoLocation struct {
// Button text
Text string
}
KeyboardButtonRequestGeoLocation represents TL type `keyboardButtonRequestGeoLocation#fc796b3f`. Button to request a user's geolocation
See https://core.telegram.org/constructor/keyboardButtonRequestGeoLocation for reference.
func (*KeyboardButtonRequestGeoLocation) Decode ¶
func (k *KeyboardButtonRequestGeoLocation) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonRequestGeoLocation) Encode ¶
func (k *KeyboardButtonRequestGeoLocation) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonRequestGeoLocation) String ¶ added in v0.12.0
func (k *KeyboardButtonRequestGeoLocation) String() string
String implements fmt.Stringer.
type KeyboardButtonRequestPhone ¶
type KeyboardButtonRequestPhone struct {
// Button text
Text string
}
KeyboardButtonRequestPhone represents TL type `keyboardButtonRequestPhone#b16a6c29`. Button to request a user's phone number
See https://core.telegram.org/constructor/keyboardButtonRequestPhone for reference.
func (*KeyboardButtonRequestPhone) Decode ¶
func (k *KeyboardButtonRequestPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonRequestPhone) Encode ¶
func (k *KeyboardButtonRequestPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonRequestPhone) String ¶ added in v0.12.0
func (k *KeyboardButtonRequestPhone) String() string
String implements fmt.Stringer.
type KeyboardButtonRequestPoll ¶
type KeyboardButtonRequestPoll struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, only quiz polls can be sent
//
// Use SetQuiz and GetQuiz helpers.
Quiz bool
// Button text
Text string
}
KeyboardButtonRequestPoll represents TL type `keyboardButtonRequestPoll#bbc7515d`. A button that allows the user to create and send a poll when pressed; available only in private
See https://core.telegram.org/constructor/keyboardButtonRequestPoll for reference.
func (*KeyboardButtonRequestPoll) Decode ¶
func (k *KeyboardButtonRequestPoll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonRequestPoll) Encode ¶
func (k *KeyboardButtonRequestPoll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonRequestPoll) GetQuiz ¶ added in v0.17.0
func (k *KeyboardButtonRequestPoll) GetQuiz() (value bool, ok bool)
GetQuiz returns value of Quiz conditional field and boolean which is true if field was set.
func (*KeyboardButtonRequestPoll) SetQuiz ¶
func (k *KeyboardButtonRequestPoll) SetQuiz(value bool)
SetQuiz sets value of Quiz conditional field.
func (*KeyboardButtonRequestPoll) String ¶ added in v0.12.0
func (k *KeyboardButtonRequestPoll) String() string
String implements fmt.Stringer.
type KeyboardButtonRow ¶
type KeyboardButtonRow struct {
// Bot or inline keyboard buttons
Buttons []KeyboardButtonClass
}
KeyboardButtonRow represents TL type `keyboardButtonRow#77608b83`. Inline keyboard row
See https://core.telegram.org/constructor/keyboardButtonRow for reference.
func (*KeyboardButtonRow) Decode ¶
func (k *KeyboardButtonRow) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonRow) Encode ¶
func (k *KeyboardButtonRow) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonRow) String ¶ added in v0.12.0
func (k *KeyboardButtonRow) String() string
String implements fmt.Stringer.
type KeyboardButtonSwitchInline ¶
type KeyboardButtonSwitchInline struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, pressing the button will insert the bot‘s username and the specified inline query in the current chat's input field.
SamePeer bool
// Button label
Text string
// The inline query to use
Query string
}
KeyboardButtonSwitchInline represents TL type `keyboardButtonSwitchInline#568a748`. Button to force a user to switch to inline mode Pressing the button will prompt the user to select one of their chats, open that chat and insert the bot‘s username and the specified inline query in the input field.
See https://core.telegram.org/constructor/keyboardButtonSwitchInline for reference.
func (*KeyboardButtonSwitchInline) Decode ¶
func (k *KeyboardButtonSwitchInline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonSwitchInline) Encode ¶
func (k *KeyboardButtonSwitchInline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonSwitchInline) SetSamePeer ¶
func (k *KeyboardButtonSwitchInline) SetSamePeer(value bool)
SetSamePeer sets value of SamePeer conditional field.
func (*KeyboardButtonSwitchInline) String ¶ added in v0.12.0
func (k *KeyboardButtonSwitchInline) String() string
String implements fmt.Stringer.
type KeyboardButtonUrl ¶
KeyboardButtonUrl represents TL type `keyboardButtonUrl#258aff05`. URL button
See https://core.telegram.org/constructor/keyboardButtonUrl for reference.
func (*KeyboardButtonUrl) Decode ¶
func (k *KeyboardButtonUrl) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonUrl) Encode ¶
func (k *KeyboardButtonUrl) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonUrl) String ¶ added in v0.12.0
func (k *KeyboardButtonUrl) String() string
String implements fmt.Stringer.
type KeyboardButtonUrlAuth ¶
type KeyboardButtonUrlAuth struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Button label
Text string
// New text of the button in forwarded messages.
//
// Use SetFwdText and GetFwdText helpers.
FwdText string
// An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in Receiving authorization data¹.NOTE: Services must always check the hash of the received data to verify the authentication and the integrity of the data as described in Checking authorization².
//
// Links:
// 1) https://core.telegram.org/widgets/login#receiving-authorization-data
// 2) https://core.telegram.org/widgets/login#checking-authorization
URL string
// ID of the button to pass to messages.requestUrlAuth¹
//
// Links:
// 1) https://core.telegram.org/method/messages.requestUrlAuth
ButtonID int
}
KeyboardButtonUrlAuth represents TL type `keyboardButtonUrlAuth#10b78d29`. Button to request a user to authorize via URL using Seamless Telegram Login¹. When the user clicks on such a button, messages.requestUrlAuth² should be called, providing the button_id and the ID of the container message. The returned urlAuthResultRequest³ object will contain more details about the authorization request (request_write_access if the bot would like to send messages to the user along with the username of the bot which will be used for user authorization). Finally, the user can choose to call messages.acceptUrlAuth⁴ to get a urlAuthResultAccepted⁵ with the URL to open instead of the url of this constructor, or a urlAuthResultDefault⁶, in which case the url of this constructor must be opened, instead. If the user refuses the authorization request but still wants to open the link, the url of this constructor must be used.
Links:
- https://telegram.org/blog/privacy-discussions-web-bots#meet-seamless-web-bots
- https://core.telegram.org/method/messages.requestUrlAuth
- https://core.telegram.org/constructor/urlAuthResultRequest
- https://core.telegram.org/method/messages.acceptUrlAuth
- https://core.telegram.org/constructor/urlAuthResultAccepted
- https://core.telegram.org/constructor/urlAuthResultDefault
See https://core.telegram.org/constructor/keyboardButtonUrlAuth for reference.
func (*KeyboardButtonUrlAuth) Decode ¶
func (k *KeyboardButtonUrlAuth) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*KeyboardButtonUrlAuth) Encode ¶
func (k *KeyboardButtonUrlAuth) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*KeyboardButtonUrlAuth) GetFwdText ¶
func (k *KeyboardButtonUrlAuth) GetFwdText() (value string, ok bool)
GetFwdText returns value of FwdText conditional field and boolean which is true if field was set.
func (*KeyboardButtonUrlAuth) SetFwdText ¶
func (k *KeyboardButtonUrlAuth) SetFwdText(value string)
SetFwdText sets value of FwdText conditional field.
func (*KeyboardButtonUrlAuth) String ¶ added in v0.12.0
func (k *KeyboardButtonUrlAuth) String() string
String implements fmt.Stringer.
type LabeledPrice ¶
type LabeledPrice struct {
// Portion label
Label string
// Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
Amount int64
}
LabeledPrice represents TL type `labeledPrice#cb296bf8`. This object represents a portion of the price for goods or services.
See https://core.telegram.org/constructor/labeledPrice for reference.
func (*LabeledPrice) Decode ¶
func (l *LabeledPrice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LabeledPrice) Encode ¶
func (l *LabeledPrice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LabeledPrice) String ¶ added in v0.12.0
func (l *LabeledPrice) String() string
String implements fmt.Stringer.
type LangPackDifference ¶
type LangPackDifference struct {
// Language code
LangCode string
// Previous version number
FromVersion int
// New version number
Version int
// Localized strings
Strings []LangPackStringClass
}
LangPackDifference represents TL type `langPackDifference#f385c1f6`. Changes to the app's localization pack
See https://core.telegram.org/constructor/langPackDifference for reference.
func (*LangPackDifference) Decode ¶
func (l *LangPackDifference) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackDifference) Encode ¶
func (l *LangPackDifference) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackDifference) String ¶ added in v0.12.0
func (l *LangPackDifference) String() string
String implements fmt.Stringer.
type LangPackHandler ¶ added in v0.9.0
type LangPackHandler func(ctx UpdateContext, update *UpdateLangPack) error
LangPackHandler is a LangPack event handler.
type LangPackLanguage ¶
type LangPackLanguage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the language pack is official
Official bool
// Is this a localization pack for an RTL language
Rtl bool
// Is this a beta localization pack?
Beta bool
// Language name
Name string
// Language name in the language itself
NativeName string
// Language code (pack identifier)
LangCode string
// Identifier of a base language pack; may be empty. If a string is missed in the language pack, then it should be fetched from base language pack. Unsupported in custom language packs
//
// Use SetBaseLangCode and GetBaseLangCode helpers.
BaseLangCode string
// A language code to be used to apply plural forms. See https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html¹ for more info
//
// Links:
// 1) https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html
PluralCode string
// Total number of non-deleted strings from the language pack
StringsCount int
// Total number of translated strings from the language pack
TranslatedCount int
// Link to language translation interface; empty for custom local language packs
TranslationsURL string
}
LangPackLanguage represents TL type `langPackLanguage#eeca5ce3`. Identifies a localization pack
See https://core.telegram.org/constructor/langPackLanguage for reference.
func (*LangPackLanguage) Decode ¶
func (l *LangPackLanguage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackLanguage) Encode ¶
func (l *LangPackLanguage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackLanguage) GetBaseLangCode ¶
func (l *LangPackLanguage) GetBaseLangCode() (value string, ok bool)
GetBaseLangCode returns value of BaseLangCode conditional field and boolean which is true if field was set.
func (*LangPackLanguage) SetBaseLangCode ¶
func (l *LangPackLanguage) SetBaseLangCode(value string)
SetBaseLangCode sets value of BaseLangCode conditional field.
func (*LangPackLanguage) SetBeta ¶
func (l *LangPackLanguage) SetBeta(value bool)
SetBeta sets value of Beta conditional field.
func (*LangPackLanguage) SetOfficial ¶
func (l *LangPackLanguage) SetOfficial(value bool)
SetOfficial sets value of Official conditional field.
func (*LangPackLanguage) SetRtl ¶
func (l *LangPackLanguage) SetRtl(value bool)
SetRtl sets value of Rtl conditional field.
func (*LangPackLanguage) String ¶ added in v0.12.0
func (l *LangPackLanguage) String() string
String implements fmt.Stringer.
type LangPackLanguageVector ¶ added in v0.8.0
type LangPackLanguageVector struct {
// Elements of Vector<LangPackLanguage>
Elems []LangPackLanguage
}
LangPackLanguageVector is a box for Vector<LangPackLanguage>
func (*LangPackLanguageVector) Decode ¶ added in v0.8.0
func (vec *LangPackLanguageVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackLanguageVector) Encode ¶ added in v0.8.0
func (vec *LangPackLanguageVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackLanguageVector) String ¶ added in v0.12.0
func (vec *LangPackLanguageVector) String() string
String implements fmt.Stringer.
type LangPackString ¶
LangPackString represents TL type `langPackString#cad181f6`. Translated localization string
See https://core.telegram.org/constructor/langPackString for reference.
func (*LangPackString) Decode ¶
func (l *LangPackString) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackString) Encode ¶
func (l *LangPackString) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackString) String ¶ added in v0.12.0
func (l *LangPackString) String() string
String implements fmt.Stringer.
type LangPackStringBox ¶
type LangPackStringBox struct {
LangPackString LangPackStringClass
}
LangPackString boxes the LangPackStringClass providing a helper.
type LangPackStringClass ¶
type LangPackStringClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
LangPackStringClass represents LangPackString generic type.
See https://core.telegram.org/type/LangPackString for reference.
Example:
g, err := DecodeLangPackString(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *LangPackString: // langPackString#cad181f6
case *LangPackStringPluralized: // langPackStringPluralized#6c47ac9f
case *LangPackStringDeleted: // langPackStringDeleted#2979eeb2
default: panic(v)
}
func DecodeLangPackString ¶
func DecodeLangPackString(buf *bin.Buffer) (LangPackStringClass, error)
DecodeLangPackString implements binary de-serialization for LangPackStringClass.
type LangPackStringClassVector ¶ added in v0.8.0
type LangPackStringClassVector struct {
// Elements of Vector<LangPackString>
Elems []LangPackStringClass
}
LangPackStringClassVector is a box for Vector<LangPackString>
func (*LangPackStringClassVector) Decode ¶ added in v0.8.0
func (vec *LangPackStringClassVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackStringClassVector) Encode ¶ added in v0.8.0
func (vec *LangPackStringClassVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackStringClassVector) String ¶ added in v0.12.0
func (vec *LangPackStringClassVector) String() string
String implements fmt.Stringer.
type LangPackStringDeleted ¶
type LangPackStringDeleted struct {
// Localization key
Key string
}
LangPackStringDeleted represents TL type `langPackStringDeleted#2979eeb2`. Deleted localization string
See https://core.telegram.org/constructor/langPackStringDeleted for reference.
func (*LangPackStringDeleted) Decode ¶
func (l *LangPackStringDeleted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackStringDeleted) Encode ¶
func (l *LangPackStringDeleted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackStringDeleted) String ¶ added in v0.12.0
func (l *LangPackStringDeleted) String() string
String implements fmt.Stringer.
type LangPackStringPluralized ¶
type LangPackStringPluralized struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Localization key
Key string
// Value for zero objects
//
// Use SetZeroValue and GetZeroValue helpers.
ZeroValue string
// Value for one object
//
// Use SetOneValue and GetOneValue helpers.
OneValue string
// Value for two objects
//
// Use SetTwoValue and GetTwoValue helpers.
TwoValue string
// Value for a few objects
//
// Use SetFewValue and GetFewValue helpers.
FewValue string
// Value for many objects
//
// Use SetManyValue and GetManyValue helpers.
ManyValue string
// Default value
OtherValue string
}
LangPackStringPluralized represents TL type `langPackStringPluralized#6c47ac9f`. A language pack string which has different forms based on the number of some object it mentions. See https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html¹ for more info
Links:
See https://core.telegram.org/constructor/langPackStringPluralized for reference.
func (*LangPackStringPluralized) Decode ¶
func (l *LangPackStringPluralized) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangPackStringPluralized) Encode ¶
func (l *LangPackStringPluralized) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangPackStringPluralized) GetFewValue ¶
func (l *LangPackStringPluralized) GetFewValue() (value string, ok bool)
GetFewValue returns value of FewValue conditional field and boolean which is true if field was set.
func (*LangPackStringPluralized) GetManyValue ¶
func (l *LangPackStringPluralized) GetManyValue() (value string, ok bool)
GetManyValue returns value of ManyValue conditional field and boolean which is true if field was set.
func (*LangPackStringPluralized) GetOneValue ¶
func (l *LangPackStringPluralized) GetOneValue() (value string, ok bool)
GetOneValue returns value of OneValue conditional field and boolean which is true if field was set.
func (*LangPackStringPluralized) GetTwoValue ¶
func (l *LangPackStringPluralized) GetTwoValue() (value string, ok bool)
GetTwoValue returns value of TwoValue conditional field and boolean which is true if field was set.
func (*LangPackStringPluralized) GetZeroValue ¶
func (l *LangPackStringPluralized) GetZeroValue() (value string, ok bool)
GetZeroValue returns value of ZeroValue conditional field and boolean which is true if field was set.
func (*LangPackStringPluralized) SetFewValue ¶
func (l *LangPackStringPluralized) SetFewValue(value string)
SetFewValue sets value of FewValue conditional field.
func (*LangPackStringPluralized) SetManyValue ¶
func (l *LangPackStringPluralized) SetManyValue(value string)
SetManyValue sets value of ManyValue conditional field.
func (*LangPackStringPluralized) SetOneValue ¶
func (l *LangPackStringPluralized) SetOneValue(value string)
SetOneValue sets value of OneValue conditional field.
func (*LangPackStringPluralized) SetTwoValue ¶
func (l *LangPackStringPluralized) SetTwoValue(value string)
SetTwoValue sets value of TwoValue conditional field.
func (*LangPackStringPluralized) SetZeroValue ¶
func (l *LangPackStringPluralized) SetZeroValue(value string)
SetZeroValue sets value of ZeroValue conditional field.
func (*LangPackStringPluralized) String ¶ added in v0.12.0
func (l *LangPackStringPluralized) String() string
String implements fmt.Stringer.
type LangPackTooLongHandler ¶ added in v0.9.0
type LangPackTooLongHandler func(ctx UpdateContext, update *UpdateLangPackTooLong) error
LangPackTooLongHandler is a LangPackTooLong event handler.
type LangpackGetDifferenceRequest ¶
type LangpackGetDifferenceRequest struct {
// Language pack
LangPack string
// Language code
LangCode string
// Previous localization pack version
FromVersion int
}
LangpackGetDifferenceRequest represents TL type `langpack.getDifference#cd984aa5`. Get new strings in languagepack
See https://core.telegram.org/method/langpack.getDifference for reference.
func (*LangpackGetDifferenceRequest) Decode ¶
func (g *LangpackGetDifferenceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangpackGetDifferenceRequest) Encode ¶
func (g *LangpackGetDifferenceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangpackGetDifferenceRequest) String ¶ added in v0.12.0
func (g *LangpackGetDifferenceRequest) String() string
String implements fmt.Stringer.
type LangpackGetLangPackRequest ¶
type LangpackGetLangPackRequest struct {
// Language pack name
LangPack string
// Language code
LangCode string
}
LangpackGetLangPackRequest represents TL type `langpack.getLangPack#f2f2330a`. Get localization pack strings
See https://core.telegram.org/method/langpack.getLangPack for reference.
func (*LangpackGetLangPackRequest) Decode ¶
func (g *LangpackGetLangPackRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangpackGetLangPackRequest) Encode ¶
func (g *LangpackGetLangPackRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangpackGetLangPackRequest) String ¶ added in v0.12.0
func (g *LangpackGetLangPackRequest) String() string
String implements fmt.Stringer.
type LangpackGetLanguageRequest ¶
type LangpackGetLanguageRequest struct {
// Language pack name
LangPack string
// Language code
LangCode string
}
LangpackGetLanguageRequest represents TL type `langpack.getLanguage#6a596502`. Get information about a language in a localization pack
See https://core.telegram.org/method/langpack.getLanguage for reference.
func (*LangpackGetLanguageRequest) Decode ¶
func (g *LangpackGetLanguageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangpackGetLanguageRequest) Encode ¶
func (g *LangpackGetLanguageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangpackGetLanguageRequest) String ¶ added in v0.12.0
func (g *LangpackGetLanguageRequest) String() string
String implements fmt.Stringer.
type LangpackGetLanguagesRequest ¶
type LangpackGetLanguagesRequest struct {
// Language pack
LangPack string
}
LangpackGetLanguagesRequest represents TL type `langpack.getLanguages#42c6978f`. Get information about all languages in a localization pack
See https://core.telegram.org/method/langpack.getLanguages for reference.
func (*LangpackGetLanguagesRequest) Decode ¶
func (g *LangpackGetLanguagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangpackGetLanguagesRequest) Encode ¶
func (g *LangpackGetLanguagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangpackGetLanguagesRequest) String ¶ added in v0.12.0
func (g *LangpackGetLanguagesRequest) String() string
String implements fmt.Stringer.
type LangpackGetStringsRequest ¶
type LangpackGetStringsRequest struct {
// Language pack name
LangPack string
// Language code
LangCode string
// Strings to get
Keys []string
}
LangpackGetStringsRequest represents TL type `langpack.getStrings#efea3803`. Get strings from a language pack
See https://core.telegram.org/method/langpack.getStrings for reference.
func (*LangpackGetStringsRequest) Decode ¶
func (g *LangpackGetStringsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LangpackGetStringsRequest) Encode ¶
func (g *LangpackGetStringsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LangpackGetStringsRequest) String ¶ added in v0.12.0
func (g *LangpackGetStringsRequest) String() string
String implements fmt.Stringer.
type LoginTokenHandler ¶ added in v0.9.0
type LoginTokenHandler func(ctx UpdateContext, update *UpdateLoginToken) error
LoginTokenHandler is a LoginToken event handler.
type LongVector ¶ added in v0.8.0
type LongVector struct {
// Elements of Vector<long>
Elems []int64
}
LongVector is a box for Vector<long>
func (*LongVector) Decode ¶ added in v0.8.0
func (vec *LongVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*LongVector) Encode ¶ added in v0.8.0
func (vec *LongVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*LongVector) String ¶ added in v0.12.0
func (vec *LongVector) String() string
String implements fmt.Stringer.
type MaskCoords ¶
type MaskCoords struct {
// Part of the face, relative to which the mask should be placed
N int
// Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. (For example, -1.0 will place the mask just to the left of the default mask position)
X float64
// Shift by Y-axis measured in widths of the mask scaled to the face size, from left to right. (For example, -1.0 will place the mask just to the left of the default mask position)
Y float64
// Mask scaling coefficient. (For example, 2.0 means a doubled size)
Zoom float64
}
MaskCoords represents TL type `maskCoords#aed6dbb2`. Position on a photo where a mask should be placed The n position indicates where the mask should be placed:
See https://core.telegram.org/constructor/maskCoords for reference.
func (*MaskCoords) Decode ¶
func (m *MaskCoords) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MaskCoords) Encode ¶
func (m *MaskCoords) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MaskCoords) String ¶ added in v0.12.0
func (m *MaskCoords) String() string
String implements fmt.Stringer.
type Message ¶
type Message struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this an outgoing message
Out bool
// Whether we were mentioned¹ in this message
//
// Links:
// 1) https://core.telegram.org/api/mentions
Mentioned bool
// Whether there are unread media attachments in this message
MediaUnread bool
// Whether this is a silent message (no notification triggered)
Silent bool
// Whether this is a channel post
Post bool
// Whether this is a scheduled message¹
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
FromScheduled bool
// This is a legacy message: it has to be refetched with the new layer
Legacy bool
// Whether the message should be shown as not modified to the user, even if an edit date is present
EditHide bool
// Whether this message is pinned¹
//
// Links:
// 1) https://core.telegram.org/api/pin
Pinned bool
// ID of the message
ID int
// ID of the sender of the message
//
// Use SetFromID and GetFromID helpers.
FromID PeerClass
// Peer ID, the chat where this message was sent
PeerID PeerClass
// Info about forwarded messages
//
// Use SetFwdFrom and GetFwdFrom helpers.
FwdFrom MessageFwdHeader
// ID of the inline bot that generated the message
//
// Use SetViaBotID and GetViaBotID helpers.
ViaBotID int
// Reply information
//
// Use SetReplyTo and GetReplyTo helpers.
ReplyTo MessageReplyHeader
// Date of the message
Date int
// The message
Message string
// Media attachment
//
// Use SetMedia and GetMedia helpers.
Media MessageMediaClass
// Reply markup (bot/inline keyboards)
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
// Message entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// View count for channel posts
//
// Use SetViews and GetViews helpers.
Views int
// Forward counter
//
// Use SetForwards and GetForwards helpers.
Forwards int
// Info about post comments (for channels) or message replies (for groups)¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReplies and GetReplies helpers.
Replies MessageReplies
// Last edit date of this message
//
// Use SetEditDate and GetEditDate helpers.
EditDate int
// Name of the author of this message for channel posts (with signatures enabled)
//
// Use SetPostAuthor and GetPostAuthor helpers.
PostAuthor string
// Multiple media messages sent using messages.sendMultiMedia¹ with the same grouped ID indicate an album or media group²
//
// Links:
// 1) https://core.telegram.org/method/messages.sendMultiMedia
// 2) https://core.telegram.org/api/files#albums-grouped-media
//
// Use SetGroupedID and GetGroupedID helpers.
GroupedID int64
// Contains the reason why access to this message must be restricted.
//
// Use SetRestrictionReason and GetRestrictionReason helpers.
RestrictionReason []RestrictionReason
}
Message represents TL type `message#58ae39c9`. A message
See https://core.telegram.org/constructor/message for reference.
func (*Message) GetEditDate ¶
GetEditDate returns value of EditDate conditional field and boolean which is true if field was set.
func (*Message) GetEntities ¶
func (m *Message) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*Message) GetForwards ¶
GetForwards returns value of Forwards conditional field and boolean which is true if field was set.
func (*Message) GetFromID ¶
GetFromID returns value of FromID conditional field and boolean which is true if field was set.
func (*Message) GetFwdFrom ¶
func (m *Message) GetFwdFrom() (value MessageFwdHeader, ok bool)
GetFwdFrom returns value of FwdFrom conditional field and boolean which is true if field was set.
func (*Message) GetGroupedID ¶
GetGroupedID returns value of GroupedID conditional field and boolean which is true if field was set.
func (*Message) GetMedia ¶
func (m *Message) GetMedia() (value MessageMediaClass, ok bool)
GetMedia returns value of Media conditional field and boolean which is true if field was set.
func (*Message) GetPostAuthor ¶
GetPostAuthor returns value of PostAuthor conditional field and boolean which is true if field was set.
func (*Message) GetReplies ¶
func (m *Message) GetReplies() (value MessageReplies, ok bool)
GetReplies returns value of Replies conditional field and boolean which is true if field was set.
func (*Message) GetReplyMarkup ¶
func (m *Message) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*Message) GetReplyTo ¶
func (m *Message) GetReplyTo() (value MessageReplyHeader, ok bool)
GetReplyTo returns value of ReplyTo conditional field and boolean which is true if field was set.
func (*Message) GetRestrictionReason ¶
func (m *Message) GetRestrictionReason() (value []RestrictionReason, ok bool)
GetRestrictionReason returns value of RestrictionReason conditional field and boolean which is true if field was set.
func (*Message) GetViaBotID ¶
GetViaBotID returns value of ViaBotID conditional field and boolean which is true if field was set.
func (*Message) GetViews ¶
GetViews returns value of Views conditional field and boolean which is true if field was set.
func (*Message) SetEditDate ¶
SetEditDate sets value of EditDate conditional field.
func (*Message) SetEditHide ¶
SetEditHide sets value of EditHide conditional field.
func (*Message) SetEntities ¶
func (m *Message) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*Message) SetForwards ¶
SetForwards sets value of Forwards conditional field.
func (*Message) SetFromScheduled ¶
SetFromScheduled sets value of FromScheduled conditional field.
func (*Message) SetFwdFrom ¶
func (m *Message) SetFwdFrom(value MessageFwdHeader)
SetFwdFrom sets value of FwdFrom conditional field.
func (*Message) SetGroupedID ¶
SetGroupedID sets value of GroupedID conditional field.
func (*Message) SetMedia ¶
func (m *Message) SetMedia(value MessageMediaClass)
SetMedia sets value of Media conditional field.
func (*Message) SetMediaUnread ¶
SetMediaUnread sets value of MediaUnread conditional field.
func (*Message) SetMentioned ¶
SetMentioned sets value of Mentioned conditional field.
func (*Message) SetPostAuthor ¶
SetPostAuthor sets value of PostAuthor conditional field.
func (*Message) SetReplies ¶
func (m *Message) SetReplies(value MessageReplies)
SetReplies sets value of Replies conditional field.
func (*Message) SetReplyMarkup ¶
func (m *Message) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*Message) SetReplyTo ¶
func (m *Message) SetReplyTo(value MessageReplyHeader)
SetReplyTo sets value of ReplyTo conditional field.
func (*Message) SetRestrictionReason ¶
func (m *Message) SetRestrictionReason(value []RestrictionReason)
SetRestrictionReason sets value of RestrictionReason conditional field.
func (*Message) SetViaBotID ¶
SetViaBotID sets value of ViaBotID conditional field.
type MessageActionBotAllowed ¶
type MessageActionBotAllowed struct {
// The domain name of the website on which the user has logged in.
Domain string
}
MessageActionBotAllowed represents TL type `messageActionBotAllowed#abe9affe`. The domain name of the website on which the user has logged in. More about Telegram Login »¹
Links:
See https://core.telegram.org/constructor/messageActionBotAllowed for reference.
func (*MessageActionBotAllowed) Decode ¶
func (m *MessageActionBotAllowed) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionBotAllowed) Encode ¶
func (m *MessageActionBotAllowed) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionBotAllowed) String ¶ added in v0.12.0
func (m *MessageActionBotAllowed) String() string
String implements fmt.Stringer.
type MessageActionBox ¶
type MessageActionBox struct {
MessageAction MessageActionClass
}
MessageAction boxes the MessageActionClass providing a helper.
type MessageActionChannelCreate ¶
type MessageActionChannelCreate struct {
// Original channel/supergroup title
Title string
}
MessageActionChannelCreate represents TL type `messageActionChannelCreate#95d2ac92`. The channel was created
See https://core.telegram.org/constructor/messageActionChannelCreate for reference.
func (*MessageActionChannelCreate) Decode ¶
func (m *MessageActionChannelCreate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChannelCreate) Encode ¶
func (m *MessageActionChannelCreate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChannelCreate) String ¶ added in v0.12.0
func (m *MessageActionChannelCreate) String() string
String implements fmt.Stringer.
type MessageActionChannelMigrateFrom ¶
type MessageActionChannelMigrateFrom struct {
// The old chat tite
Title string
// The old chat ID
ChatID int
}
MessageActionChannelMigrateFrom represents TL type `messageActionChannelMigrateFrom#b055eaee`. Indicates the channel was migrated¹ from the specified chat
Links:
See https://core.telegram.org/constructor/messageActionChannelMigrateFrom for reference.
func (*MessageActionChannelMigrateFrom) Decode ¶
func (m *MessageActionChannelMigrateFrom) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChannelMigrateFrom) Encode ¶
func (m *MessageActionChannelMigrateFrom) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChannelMigrateFrom) String ¶ added in v0.12.0
func (m *MessageActionChannelMigrateFrom) String() string
String implements fmt.Stringer.
type MessageActionChatAddUser ¶
type MessageActionChatAddUser struct {
// Users that were invited to the chat
Users []int
}
MessageActionChatAddUser represents TL type `messageActionChatAddUser#488a7337`. New member in the group
See https://core.telegram.org/constructor/messageActionChatAddUser for reference.
func (*MessageActionChatAddUser) Decode ¶
func (m *MessageActionChatAddUser) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatAddUser) Encode ¶
func (m *MessageActionChatAddUser) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatAddUser) String ¶ added in v0.12.0
func (m *MessageActionChatAddUser) String() string
String implements fmt.Stringer.
type MessageActionChatCreate ¶
type MessageActionChatCreate struct {
// Group name
Title string
// List of group members
Users []int
}
MessageActionChatCreate represents TL type `messageActionChatCreate#a6638b9a`. Group created
See https://core.telegram.org/constructor/messageActionChatCreate for reference.
func (*MessageActionChatCreate) Decode ¶
func (m *MessageActionChatCreate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatCreate) Encode ¶
func (m *MessageActionChatCreate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatCreate) String ¶ added in v0.12.0
func (m *MessageActionChatCreate) String() string
String implements fmt.Stringer.
type MessageActionChatDeletePhoto ¶
type MessageActionChatDeletePhoto struct {
}
MessageActionChatDeletePhoto represents TL type `messageActionChatDeletePhoto#95e3fbef`. Group profile photo removed.
See https://core.telegram.org/constructor/messageActionChatDeletePhoto for reference.
func (*MessageActionChatDeletePhoto) Decode ¶
func (m *MessageActionChatDeletePhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatDeletePhoto) Encode ¶
func (m *MessageActionChatDeletePhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatDeletePhoto) String ¶ added in v0.12.0
func (m *MessageActionChatDeletePhoto) String() string
String implements fmt.Stringer.
type MessageActionChatDeleteUser ¶
type MessageActionChatDeleteUser struct {
// Leaving user ID
UserID int
}
MessageActionChatDeleteUser represents TL type `messageActionChatDeleteUser#b2ae9b0c`. User left the group.
See https://core.telegram.org/constructor/messageActionChatDeleteUser for reference.
func (*MessageActionChatDeleteUser) Decode ¶
func (m *MessageActionChatDeleteUser) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatDeleteUser) Encode ¶
func (m *MessageActionChatDeleteUser) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatDeleteUser) String ¶ added in v0.12.0
func (m *MessageActionChatDeleteUser) String() string
String implements fmt.Stringer.
type MessageActionChatEditPhoto ¶
type MessageActionChatEditPhoto struct {
// New group pofile photo
Photo PhotoClass
}
MessageActionChatEditPhoto represents TL type `messageActionChatEditPhoto#7fcb13a8`. Group profile changed
See https://core.telegram.org/constructor/messageActionChatEditPhoto for reference.
func (*MessageActionChatEditPhoto) Decode ¶
func (m *MessageActionChatEditPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatEditPhoto) Encode ¶
func (m *MessageActionChatEditPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatEditPhoto) String ¶ added in v0.12.0
func (m *MessageActionChatEditPhoto) String() string
String implements fmt.Stringer.
type MessageActionChatEditTitle ¶
type MessageActionChatEditTitle struct {
// New group name
Title string
}
MessageActionChatEditTitle represents TL type `messageActionChatEditTitle#b5a1ce5a`. Group name changed.
See https://core.telegram.org/constructor/messageActionChatEditTitle for reference.
func (*MessageActionChatEditTitle) Decode ¶
func (m *MessageActionChatEditTitle) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatEditTitle) Encode ¶
func (m *MessageActionChatEditTitle) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatEditTitle) String ¶ added in v0.12.0
func (m *MessageActionChatEditTitle) String() string
String implements fmt.Stringer.
type MessageActionChatJoinedByLink ¶
type MessageActionChatJoinedByLink struct {
// ID of the user that created the invite link
InviterID int
}
MessageActionChatJoinedByLink represents TL type `messageActionChatJoinedByLink#f89cf5e8`. A user joined the chat via an invite link
See https://core.telegram.org/constructor/messageActionChatJoinedByLink for reference.
func (*MessageActionChatJoinedByLink) Decode ¶
func (m *MessageActionChatJoinedByLink) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatJoinedByLink) Encode ¶
func (m *MessageActionChatJoinedByLink) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatJoinedByLink) String ¶ added in v0.12.0
func (m *MessageActionChatJoinedByLink) String() string
String implements fmt.Stringer.
type MessageActionChatMigrateTo ¶
type MessageActionChatMigrateTo struct {
// The supergroup it was migrated to
ChannelID int
}
MessageActionChatMigrateTo represents TL type `messageActionChatMigrateTo#51bdb021`. Indicates the chat was migrated¹ to the specified supergroup
Links:
See https://core.telegram.org/constructor/messageActionChatMigrateTo for reference.
func (*MessageActionChatMigrateTo) Decode ¶
func (m *MessageActionChatMigrateTo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionChatMigrateTo) Encode ¶
func (m *MessageActionChatMigrateTo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionChatMigrateTo) String ¶ added in v0.12.0
func (m *MessageActionChatMigrateTo) String() string
String implements fmt.Stringer.
type MessageActionClass ¶
type MessageActionClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessageActionClass represents MessageAction generic type.
See https://core.telegram.org/type/MessageAction for reference.
Example:
g, err := DecodeMessageAction(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessageActionEmpty: // messageActionEmpty#b6aef7b0
case *MessageActionChatCreate: // messageActionChatCreate#a6638b9a
case *MessageActionChatEditTitle: // messageActionChatEditTitle#b5a1ce5a
case *MessageActionChatEditPhoto: // messageActionChatEditPhoto#7fcb13a8
case *MessageActionChatDeletePhoto: // messageActionChatDeletePhoto#95e3fbef
case *MessageActionChatAddUser: // messageActionChatAddUser#488a7337
case *MessageActionChatDeleteUser: // messageActionChatDeleteUser#b2ae9b0c
case *MessageActionChatJoinedByLink: // messageActionChatJoinedByLink#f89cf5e8
case *MessageActionChannelCreate: // messageActionChannelCreate#95d2ac92
case *MessageActionChatMigrateTo: // messageActionChatMigrateTo#51bdb021
case *MessageActionChannelMigrateFrom: // messageActionChannelMigrateFrom#b055eaee
case *MessageActionPinMessage: // messageActionPinMessage#94bd38ed
case *MessageActionHistoryClear: // messageActionHistoryClear#9fbab604
case *MessageActionGameScore: // messageActionGameScore#92a72876
case *MessageActionPaymentSentMe: // messageActionPaymentSentMe#8f31b327
case *MessageActionPaymentSent: // messageActionPaymentSent#40699cd0
case *MessageActionPhoneCall: // messageActionPhoneCall#80e11a7f
case *MessageActionScreenshotTaken: // messageActionScreenshotTaken#4792929b
case *MessageActionCustomAction: // messageActionCustomAction#fae69f56
case *MessageActionBotAllowed: // messageActionBotAllowed#abe9affe
case *MessageActionSecureValuesSentMe: // messageActionSecureValuesSentMe#1b287353
case *MessageActionSecureValuesSent: // messageActionSecureValuesSent#d95c6154
case *MessageActionContactSignUp: // messageActionContactSignUp#f3f25f76
case *MessageActionGeoProximityReached: // messageActionGeoProximityReached#98e0d697
case *MessageActionGroupCall: // messageActionGroupCall#7a0d7f42
case *MessageActionInviteToGroupCall: // messageActionInviteToGroupCall#76b9f11a
default: panic(v)
}
func DecodeMessageAction ¶
func DecodeMessageAction(buf *bin.Buffer) (MessageActionClass, error)
DecodeMessageAction implements binary de-serialization for MessageActionClass.
type MessageActionContactSignUp ¶
type MessageActionContactSignUp struct {
}
MessageActionContactSignUp represents TL type `messageActionContactSignUp#f3f25f76`. A contact just signed up to telegram
See https://core.telegram.org/constructor/messageActionContactSignUp for reference.
func (*MessageActionContactSignUp) Decode ¶
func (m *MessageActionContactSignUp) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionContactSignUp) Encode ¶
func (m *MessageActionContactSignUp) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionContactSignUp) String ¶ added in v0.12.0
func (m *MessageActionContactSignUp) String() string
String implements fmt.Stringer.
type MessageActionCustomAction ¶
type MessageActionCustomAction struct {
// Action message
Message string
}
MessageActionCustomAction represents TL type `messageActionCustomAction#fae69f56`. Custom action (most likely not supported by the current layer, an upgrade might be needed)
See https://core.telegram.org/constructor/messageActionCustomAction for reference.
func (*MessageActionCustomAction) Decode ¶
func (m *MessageActionCustomAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionCustomAction) Encode ¶
func (m *MessageActionCustomAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionCustomAction) String ¶ added in v0.12.0
func (m *MessageActionCustomAction) String() string
String implements fmt.Stringer.
type MessageActionEmpty ¶
type MessageActionEmpty struct {
}
MessageActionEmpty represents TL type `messageActionEmpty#b6aef7b0`. Empty constructor.
See https://core.telegram.org/constructor/messageActionEmpty for reference.
func (*MessageActionEmpty) Decode ¶
func (m *MessageActionEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionEmpty) Encode ¶
func (m *MessageActionEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionEmpty) String ¶ added in v0.12.0
func (m *MessageActionEmpty) String() string
String implements fmt.Stringer.
type MessageActionGameScore ¶
MessageActionGameScore represents TL type `messageActionGameScore#92a72876`. Someone scored in a game
See https://core.telegram.org/constructor/messageActionGameScore for reference.
func (*MessageActionGameScore) Decode ¶
func (m *MessageActionGameScore) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionGameScore) Encode ¶
func (m *MessageActionGameScore) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionGameScore) String ¶ added in v0.12.0
func (m *MessageActionGameScore) String() string
String implements fmt.Stringer.
type MessageActionGeoProximityReached ¶
type MessageActionGeoProximityReached struct {
// The user or chat that is now in proximity of to_id
FromID PeerClass
// The user or chat that subscribed to live geolocation proximity alerts¹
//
// Links:
// 1) https://core.telegram.org/api/live-location#proximity-alert
ToID PeerClass
// Distance, in meters (0-100000)
Distance int
}
MessageActionGeoProximityReached represents TL type `messageActionGeoProximityReached#98e0d697`. A user of the chat is now in proximity of another user
See https://core.telegram.org/constructor/messageActionGeoProximityReached for reference.
func (*MessageActionGeoProximityReached) Decode ¶
func (m *MessageActionGeoProximityReached) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionGeoProximityReached) Encode ¶
func (m *MessageActionGeoProximityReached) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionGeoProximityReached) String ¶ added in v0.12.0
func (m *MessageActionGeoProximityReached) String() string
String implements fmt.Stringer.
type MessageActionGroupCall ¶ added in v0.13.0
type MessageActionGroupCall struct {
// Flags field of MessageActionGroupCall.
Flags bin.Fields
// Call field of MessageActionGroupCall.
Call InputGroupCall
// Duration field of MessageActionGroupCall.
//
// Use SetDuration and GetDuration helpers.
Duration int
}
MessageActionGroupCall represents TL type `messageActionGroupCall#7a0d7f42`.
See https://core.telegram.org/constructor/messageActionGroupCall for reference.
func (*MessageActionGroupCall) Decode ¶ added in v0.13.0
func (m *MessageActionGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionGroupCall) Encode ¶ added in v0.13.0
func (m *MessageActionGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionGroupCall) GetDuration ¶ added in v0.13.0
func (m *MessageActionGroupCall) GetDuration() (value int, ok bool)
GetDuration returns value of Duration conditional field and boolean which is true if field was set.
func (*MessageActionGroupCall) SetDuration ¶ added in v0.13.0
func (m *MessageActionGroupCall) SetDuration(value int)
SetDuration sets value of Duration conditional field.
func (*MessageActionGroupCall) String ¶ added in v0.13.0
func (m *MessageActionGroupCall) String() string
String implements fmt.Stringer.
type MessageActionHistoryClear ¶
type MessageActionHistoryClear struct {
}
MessageActionHistoryClear represents TL type `messageActionHistoryClear#9fbab604`. Chat history was cleared
See https://core.telegram.org/constructor/messageActionHistoryClear for reference.
func (*MessageActionHistoryClear) Decode ¶
func (m *MessageActionHistoryClear) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionHistoryClear) Encode ¶
func (m *MessageActionHistoryClear) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionHistoryClear) String ¶ added in v0.12.0
func (m *MessageActionHistoryClear) String() string
String implements fmt.Stringer.
type MessageActionInviteToGroupCall ¶ added in v0.13.0
type MessageActionInviteToGroupCall struct {
// Call field of MessageActionInviteToGroupCall.
Call InputGroupCall
// Users field of MessageActionInviteToGroupCall.
Users []int
}
MessageActionInviteToGroupCall represents TL type `messageActionInviteToGroupCall#76b9f11a`.
See https://core.telegram.org/constructor/messageActionInviteToGroupCall for reference.
func (*MessageActionInviteToGroupCall) Decode ¶ added in v0.13.0
func (m *MessageActionInviteToGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionInviteToGroupCall) Encode ¶ added in v0.13.0
func (m *MessageActionInviteToGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionInviteToGroupCall) String ¶ added in v0.13.0
func (m *MessageActionInviteToGroupCall) String() string
String implements fmt.Stringer.
type MessageActionPaymentSent ¶
type MessageActionPaymentSent struct {
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
TotalAmount int64
}
MessageActionPaymentSent represents TL type `messageActionPaymentSent#40699cd0`. A payment was sent
See https://core.telegram.org/constructor/messageActionPaymentSent for reference.
func (*MessageActionPaymentSent) Decode ¶
func (m *MessageActionPaymentSent) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionPaymentSent) Encode ¶
func (m *MessageActionPaymentSent) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionPaymentSent) String ¶ added in v0.12.0
func (m *MessageActionPaymentSent) String() string
String implements fmt.Stringer.
type MessageActionPaymentSentMe ¶
type MessageActionPaymentSentMe struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
TotalAmount int64
// Bot specified invoice payload
Payload []byte
// Order info provided by the user
//
// Use SetInfo and GetInfo helpers.
Info PaymentRequestedInfo
// Identifier of the shipping option chosen by the user
//
// Use SetShippingOptionID and GetShippingOptionID helpers.
ShippingOptionID string
// Provider payment identifier
Charge PaymentCharge
}
MessageActionPaymentSentMe represents TL type `messageActionPaymentSentMe#8f31b327`. A user just sent a payment to me (a bot)
See https://core.telegram.org/constructor/messageActionPaymentSentMe for reference.
func (*MessageActionPaymentSentMe) Decode ¶
func (m *MessageActionPaymentSentMe) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionPaymentSentMe) Encode ¶
func (m *MessageActionPaymentSentMe) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionPaymentSentMe) GetInfo ¶
func (m *MessageActionPaymentSentMe) GetInfo() (value PaymentRequestedInfo, ok bool)
GetInfo returns value of Info conditional field and boolean which is true if field was set.
func (*MessageActionPaymentSentMe) GetShippingOptionID ¶
func (m *MessageActionPaymentSentMe) GetShippingOptionID() (value string, ok bool)
GetShippingOptionID returns value of ShippingOptionID conditional field and boolean which is true if field was set.
func (*MessageActionPaymentSentMe) SetInfo ¶
func (m *MessageActionPaymentSentMe) SetInfo(value PaymentRequestedInfo)
SetInfo sets value of Info conditional field.
func (*MessageActionPaymentSentMe) SetShippingOptionID ¶
func (m *MessageActionPaymentSentMe) SetShippingOptionID(value string)
SetShippingOptionID sets value of ShippingOptionID conditional field.
func (*MessageActionPaymentSentMe) String ¶ added in v0.12.0
func (m *MessageActionPaymentSentMe) String() string
String implements fmt.Stringer.
type MessageActionPhoneCall ¶
type MessageActionPhoneCall struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this a video call?
Video bool
// Call ID
CallID int64
// If the call has ended, the reason why it ended
//
// Use SetReason and GetReason helpers.
Reason PhoneCallDiscardReasonClass
// Duration of the call in seconds
//
// Use SetDuration and GetDuration helpers.
Duration int
}
MessageActionPhoneCall represents TL type `messageActionPhoneCall#80e11a7f`. A phone call
See https://core.telegram.org/constructor/messageActionPhoneCall for reference.
func (*MessageActionPhoneCall) Decode ¶
func (m *MessageActionPhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionPhoneCall) Encode ¶
func (m *MessageActionPhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionPhoneCall) GetDuration ¶
func (m *MessageActionPhoneCall) GetDuration() (value int, ok bool)
GetDuration returns value of Duration conditional field and boolean which is true if field was set.
func (*MessageActionPhoneCall) GetReason ¶
func (m *MessageActionPhoneCall) GetReason() (value PhoneCallDiscardReasonClass, ok bool)
GetReason returns value of Reason conditional field and boolean which is true if field was set.
func (*MessageActionPhoneCall) SetDuration ¶
func (m *MessageActionPhoneCall) SetDuration(value int)
SetDuration sets value of Duration conditional field.
func (*MessageActionPhoneCall) SetReason ¶
func (m *MessageActionPhoneCall) SetReason(value PhoneCallDiscardReasonClass)
SetReason sets value of Reason conditional field.
func (*MessageActionPhoneCall) SetVideo ¶
func (m *MessageActionPhoneCall) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*MessageActionPhoneCall) String ¶ added in v0.12.0
func (m *MessageActionPhoneCall) String() string
String implements fmt.Stringer.
type MessageActionPinMessage ¶
type MessageActionPinMessage struct {
}
MessageActionPinMessage represents TL type `messageActionPinMessage#94bd38ed`. A message was pinned
See https://core.telegram.org/constructor/messageActionPinMessage for reference.
func (*MessageActionPinMessage) Decode ¶
func (m *MessageActionPinMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionPinMessage) Encode ¶
func (m *MessageActionPinMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionPinMessage) String ¶ added in v0.12.0
func (m *MessageActionPinMessage) String() string
String implements fmt.Stringer.
type MessageActionScreenshotTaken ¶
type MessageActionScreenshotTaken struct {
}
MessageActionScreenshotTaken represents TL type `messageActionScreenshotTaken#4792929b`. A screenshot of the chat was taken
See https://core.telegram.org/constructor/messageActionScreenshotTaken for reference.
func (*MessageActionScreenshotTaken) Decode ¶
func (m *MessageActionScreenshotTaken) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionScreenshotTaken) Encode ¶
func (m *MessageActionScreenshotTaken) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionScreenshotTaken) String ¶ added in v0.12.0
func (m *MessageActionScreenshotTaken) String() string
String implements fmt.Stringer.
type MessageActionSecureValuesSent ¶
type MessageActionSecureValuesSent struct {
// Secure value types
Types []SecureValueTypeClass
}
MessageActionSecureValuesSent represents TL type `messageActionSecureValuesSent#d95c6154`. Request for secure telegram passport¹ values was sent
Links:
See https://core.telegram.org/constructor/messageActionSecureValuesSent for reference.
func (*MessageActionSecureValuesSent) Decode ¶
func (m *MessageActionSecureValuesSent) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionSecureValuesSent) Encode ¶
func (m *MessageActionSecureValuesSent) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionSecureValuesSent) String ¶ added in v0.12.0
func (m *MessageActionSecureValuesSent) String() string
String implements fmt.Stringer.
type MessageActionSecureValuesSentMe ¶
type MessageActionSecureValuesSentMe struct {
// Vector with information about documents and other Telegram Passport elements that were shared with the bot
Values []SecureValue
// Encrypted credentials required to decrypt the data
Credentials SecureCredentialsEncrypted
}
MessageActionSecureValuesSentMe represents TL type `messageActionSecureValuesSentMe#1b287353`. Secure telegram passport¹ values were received
Links:
See https://core.telegram.org/constructor/messageActionSecureValuesSentMe for reference.
func (*MessageActionSecureValuesSentMe) Decode ¶
func (m *MessageActionSecureValuesSentMe) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageActionSecureValuesSentMe) Encode ¶
func (m *MessageActionSecureValuesSentMe) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageActionSecureValuesSentMe) String ¶ added in v0.12.0
func (m *MessageActionSecureValuesSentMe) String() string
String implements fmt.Stringer.
type MessageBox ¶
type MessageBox struct {
Message MessageClass
}
Message boxes the MessageClass providing a helper.
type MessageClass ¶
type MessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessageClass represents Message generic type.
See https://core.telegram.org/type/Message for reference.
Example:
g, err := DecodeMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessageEmpty: // messageEmpty#83e5de54
case *Message: // message#58ae39c9
case *MessageService: // messageService#286fa604
default: panic(v)
}
func DecodeMessage ¶
func DecodeMessage(buf *bin.Buffer) (MessageClass, error)
DecodeMessage implements binary de-serialization for MessageClass.
type MessageEmpty ¶
type MessageEmpty struct {
// Message identifier
ID int
}
MessageEmpty represents TL type `messageEmpty#83e5de54`. Empty constructor, non-existent message.
See https://core.telegram.org/constructor/messageEmpty for reference.
func (*MessageEmpty) Decode ¶
func (m *MessageEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEmpty) Encode ¶
func (m *MessageEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEmpty) String ¶ added in v0.12.0
func (m *MessageEmpty) String() string
String implements fmt.Stringer.
type MessageEntityBankCard ¶
type MessageEntityBankCard struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityBankCard represents TL type `messageEntityBankCard#761e6af4`. Indicates a credit card number
See https://core.telegram.org/constructor/messageEntityBankCard for reference.
func (*MessageEntityBankCard) Decode ¶
func (m *MessageEntityBankCard) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityBankCard) Encode ¶
func (m *MessageEntityBankCard) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityBankCard) String ¶ added in v0.12.0
func (m *MessageEntityBankCard) String() string
String implements fmt.Stringer.
type MessageEntityBlockquote ¶
type MessageEntityBlockquote struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityBlockquote represents TL type `messageEntityBlockquote#20df5d0`. Message entity representing a block quote.
See https://core.telegram.org/constructor/messageEntityBlockquote for reference.
func (*MessageEntityBlockquote) Decode ¶
func (m *MessageEntityBlockquote) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityBlockquote) Encode ¶
func (m *MessageEntityBlockquote) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityBlockquote) String ¶ added in v0.12.0
func (m *MessageEntityBlockquote) String() string
String implements fmt.Stringer.
type MessageEntityBold ¶
type MessageEntityBold struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityBold represents TL type `messageEntityBold#bd610bc9`. Message entity representing bold text.
See https://core.telegram.org/constructor/messageEntityBold for reference.
func (*MessageEntityBold) Decode ¶
func (m *MessageEntityBold) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityBold) Encode ¶
func (m *MessageEntityBold) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityBold) String ¶ added in v0.12.0
func (m *MessageEntityBold) String() string
String implements fmt.Stringer.
type MessageEntityBotCommand ¶
type MessageEntityBotCommand struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityBotCommand represents TL type `messageEntityBotCommand#6cef8ac7`. Message entity representing a bot /command
See https://core.telegram.org/constructor/messageEntityBotCommand for reference.
func (*MessageEntityBotCommand) Decode ¶
func (m *MessageEntityBotCommand) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityBotCommand) Encode ¶
func (m *MessageEntityBotCommand) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityBotCommand) String ¶ added in v0.12.0
func (m *MessageEntityBotCommand) String() string
String implements fmt.Stringer.
type MessageEntityBox ¶
type MessageEntityBox struct {
MessageEntity MessageEntityClass
}
MessageEntity boxes the MessageEntityClass providing a helper.
type MessageEntityCashtag ¶
type MessageEntityCashtag struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityCashtag represents TL type `messageEntityCashtag#4c4e743f`. Message entity representing a $cashtag.
See https://core.telegram.org/constructor/messageEntityCashtag for reference.
func (*MessageEntityCashtag) Decode ¶
func (m *MessageEntityCashtag) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityCashtag) Encode ¶
func (m *MessageEntityCashtag) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityCashtag) String ¶ added in v0.12.0
func (m *MessageEntityCashtag) String() string
String implements fmt.Stringer.
type MessageEntityClass ¶
type MessageEntityClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessageEntityClass represents MessageEntity generic type.
See https://core.telegram.org/type/MessageEntity for reference.
Example:
g, err := DecodeMessageEntity(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessageEntityUnknown: // messageEntityUnknown#bb92ba95
case *MessageEntityMention: // messageEntityMention#fa04579d
case *MessageEntityHashtag: // messageEntityHashtag#6f635b0d
case *MessageEntityBotCommand: // messageEntityBotCommand#6cef8ac7
case *MessageEntityUrl: // messageEntityUrl#6ed02538
case *MessageEntityEmail: // messageEntityEmail#64e475c2
case *MessageEntityBold: // messageEntityBold#bd610bc9
case *MessageEntityItalic: // messageEntityItalic#826f8b60
case *MessageEntityCode: // messageEntityCode#28a20571
case *MessageEntityPre: // messageEntityPre#73924be0
case *MessageEntityTextUrl: // messageEntityTextUrl#76a6d327
case *MessageEntityMentionName: // messageEntityMentionName#352dca58
case *InputMessageEntityMentionName: // inputMessageEntityMentionName#208e68c9
case *MessageEntityPhone: // messageEntityPhone#9b69e34b
case *MessageEntityCashtag: // messageEntityCashtag#4c4e743f
case *MessageEntityUnderline: // messageEntityUnderline#9c4e7e8b
case *MessageEntityStrike: // messageEntityStrike#bf0693d4
case *MessageEntityBlockquote: // messageEntityBlockquote#20df5d0
case *MessageEntityBankCard: // messageEntityBankCard#761e6af4
default: panic(v)
}
func DecodeMessageEntity ¶
func DecodeMessageEntity(buf *bin.Buffer) (MessageEntityClass, error)
DecodeMessageEntity implements binary de-serialization for MessageEntityClass.
type MessageEntityCode ¶
type MessageEntityCode struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityCode represents TL type `messageEntityCode#28a20571`. Message entity representing a codeblock.
See https://core.telegram.org/constructor/messageEntityCode for reference.
func (*MessageEntityCode) Decode ¶
func (m *MessageEntityCode) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityCode) Encode ¶
func (m *MessageEntityCode) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityCode) String ¶ added in v0.12.0
func (m *MessageEntityCode) String() string
String implements fmt.Stringer.
type MessageEntityEmail ¶
type MessageEntityEmail struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityEmail represents TL type `messageEntityEmail#64e475c2`. Message entity representing an email@example.com¹.
Links:
See https://core.telegram.org/constructor/messageEntityEmail for reference.
func (*MessageEntityEmail) Decode ¶
func (m *MessageEntityEmail) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityEmail) Encode ¶
func (m *MessageEntityEmail) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityEmail) String ¶ added in v0.12.0
func (m *MessageEntityEmail) String() string
String implements fmt.Stringer.
type MessageEntityHashtag ¶
type MessageEntityHashtag struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityHashtag represents TL type `messageEntityHashtag#6f635b0d`. #hashtag message entity
See https://core.telegram.org/constructor/messageEntityHashtag for reference.
func (*MessageEntityHashtag) Decode ¶
func (m *MessageEntityHashtag) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityHashtag) Encode ¶
func (m *MessageEntityHashtag) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityHashtag) String ¶ added in v0.12.0
func (m *MessageEntityHashtag) String() string
String implements fmt.Stringer.
type MessageEntityItalic ¶
type MessageEntityItalic struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityItalic represents TL type `messageEntityItalic#826f8b60`. Message entity representing italic text.
See https://core.telegram.org/constructor/messageEntityItalic for reference.
func (*MessageEntityItalic) Decode ¶
func (m *MessageEntityItalic) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityItalic) Encode ¶
func (m *MessageEntityItalic) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityItalic) String ¶ added in v0.12.0
func (m *MessageEntityItalic) String() string
String implements fmt.Stringer.
type MessageEntityMention ¶
type MessageEntityMention struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityMention represents TL type `messageEntityMention#fa04579d`. Message entity mentioning¹ the current user
Links:
See https://core.telegram.org/constructor/messageEntityMention for reference.
func (*MessageEntityMention) Decode ¶
func (m *MessageEntityMention) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityMention) Encode ¶
func (m *MessageEntityMention) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityMention) String ¶ added in v0.12.0
func (m *MessageEntityMention) String() string
String implements fmt.Stringer.
type MessageEntityMentionName ¶
type MessageEntityMentionName struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
// Identifier of the user that was mentioned
UserID int
}
MessageEntityMentionName represents TL type `messageEntityMentionName#352dca58`. Message entity representing a user mention¹: for creating a mention use inputMessageEntityMentionName².
Links:
- https://core.telegram.org/api/mentions
- https://core.telegram.org/constructor/inputMessageEntityMentionName
See https://core.telegram.org/constructor/messageEntityMentionName for reference.
func (*MessageEntityMentionName) Decode ¶
func (m *MessageEntityMentionName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityMentionName) Encode ¶
func (m *MessageEntityMentionName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityMentionName) String ¶ added in v0.12.0
func (m *MessageEntityMentionName) String() string
String implements fmt.Stringer.
type MessageEntityPhone ¶
type MessageEntityPhone struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityPhone represents TL type `messageEntityPhone#9b69e34b`. Message entity representing a phone number.
See https://core.telegram.org/constructor/messageEntityPhone for reference.
func (*MessageEntityPhone) Decode ¶
func (m *MessageEntityPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityPhone) Encode ¶
func (m *MessageEntityPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityPhone) String ¶ added in v0.12.0
func (m *MessageEntityPhone) String() string
String implements fmt.Stringer.
type MessageEntityPre ¶
type MessageEntityPre struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
// Programming language of the code
Language string
}
MessageEntityPre represents TL type `messageEntityPre#73924be0`. Message entity representing a preformatted codeblock, allowing the user to specify a programming language for the codeblock.
See https://core.telegram.org/constructor/messageEntityPre for reference.
func (*MessageEntityPre) Decode ¶
func (m *MessageEntityPre) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityPre) Encode ¶
func (m *MessageEntityPre) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityPre) String ¶ added in v0.12.0
func (m *MessageEntityPre) String() string
String implements fmt.Stringer.
type MessageEntityStrike ¶
type MessageEntityStrike struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityStrike represents TL type `messageEntityStrike#bf0693d4`. Message entity representing strikethrough text.
See https://core.telegram.org/constructor/messageEntityStrike for reference.
func (*MessageEntityStrike) Decode ¶
func (m *MessageEntityStrike) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityStrike) Encode ¶
func (m *MessageEntityStrike) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityStrike) String ¶ added in v0.12.0
func (m *MessageEntityStrike) String() string
String implements fmt.Stringer.
type MessageEntityTextUrl ¶
type MessageEntityTextUrl struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
// The actual URL
URL string
}
MessageEntityTextUrl represents TL type `messageEntityTextUrl#76a6d327`. Message entity representing a text url¹: for in-text urls like https://google.com² use messageEntityUrl³.
Links:
See https://core.telegram.org/constructor/messageEntityTextUrl for reference.
func (*MessageEntityTextUrl) Decode ¶
func (m *MessageEntityTextUrl) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityTextUrl) Encode ¶
func (m *MessageEntityTextUrl) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityTextUrl) String ¶ added in v0.12.0
func (m *MessageEntityTextUrl) String() string
String implements fmt.Stringer.
type MessageEntityUnderline ¶
type MessageEntityUnderline struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityUnderline represents TL type `messageEntityUnderline#9c4e7e8b`. Message entity representing underlined text.
See https://core.telegram.org/constructor/messageEntityUnderline for reference.
func (*MessageEntityUnderline) Decode ¶
func (m *MessageEntityUnderline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityUnderline) Encode ¶
func (m *MessageEntityUnderline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityUnderline) String ¶ added in v0.12.0
func (m *MessageEntityUnderline) String() string
String implements fmt.Stringer.
type MessageEntityUnknown ¶
type MessageEntityUnknown struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityUnknown represents TL type `messageEntityUnknown#bb92ba95`. Unknown message entity
See https://core.telegram.org/constructor/messageEntityUnknown for reference.
func (*MessageEntityUnknown) Decode ¶
func (m *MessageEntityUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityUnknown) Encode ¶
func (m *MessageEntityUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityUnknown) String ¶ added in v0.12.0
func (m *MessageEntityUnknown) String() string
String implements fmt.Stringer.
type MessageEntityUrl ¶
type MessageEntityUrl struct {
// Offset of message entity within message (in UTF-8 codepoints)
Offset int
// Length of message entity within message (in UTF-8 codepoints)
Length int
}
MessageEntityUrl represents TL type `messageEntityUrl#6ed02538`. Message entity representing an in-text url: https://google.com¹; for text urls², use messageEntityTextUrl³.
Links:
See https://core.telegram.org/constructor/messageEntityUrl for reference.
func (*MessageEntityUrl) Decode ¶
func (m *MessageEntityUrl) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageEntityUrl) Encode ¶
func (m *MessageEntityUrl) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageEntityUrl) String ¶ added in v0.12.0
func (m *MessageEntityUrl) String() string
String implements fmt.Stringer.
type MessageFwdHeader ¶
type MessageFwdHeader struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The ID of the user that originally sent the message
//
// Use SetFromID and GetFromID helpers.
FromID PeerClass
// The name of the user that originally sent the message
//
// Use SetFromName and GetFromName helpers.
FromName string
// When was the message originally sent
Date int
// ID of the channel message that was forwarded
//
// Use SetChannelPost and GetChannelPost helpers.
ChannelPost int
// For channels and if signatures are enabled, author of the channel message
//
// Use SetPostAuthor and GetPostAuthor helpers.
PostAuthor string
// Only for messages forwarded to the current user (inputPeerSelf), full info about the user/channel that originally sent the message
//
// Use SetSavedFromPeer and GetSavedFromPeer helpers.
SavedFromPeer PeerClass
// Only for messages forwarded to the current user (inputPeerSelf), ID of the message that was forwarded from the original user/channel
//
// Use SetSavedFromMsgID and GetSavedFromMsgID helpers.
SavedFromMsgID int
// PSA type
//
// Use SetPsaType and GetPsaType helpers.
PsaType string
}
MessageFwdHeader represents TL type `messageFwdHeader#5f777dce`. Info about a forwarded message
See https://core.telegram.org/constructor/messageFwdHeader for reference.
func (*MessageFwdHeader) Decode ¶
func (m *MessageFwdHeader) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageFwdHeader) Encode ¶
func (m *MessageFwdHeader) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageFwdHeader) GetChannelPost ¶
func (m *MessageFwdHeader) GetChannelPost() (value int, ok bool)
GetChannelPost returns value of ChannelPost conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetFromID ¶
func (m *MessageFwdHeader) GetFromID() (value PeerClass, ok bool)
GetFromID returns value of FromID conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetFromName ¶
func (m *MessageFwdHeader) GetFromName() (value string, ok bool)
GetFromName returns value of FromName conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetPostAuthor ¶
func (m *MessageFwdHeader) GetPostAuthor() (value string, ok bool)
GetPostAuthor returns value of PostAuthor conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetPsaType ¶
func (m *MessageFwdHeader) GetPsaType() (value string, ok bool)
GetPsaType returns value of PsaType conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetSavedFromMsgID ¶
func (m *MessageFwdHeader) GetSavedFromMsgID() (value int, ok bool)
GetSavedFromMsgID returns value of SavedFromMsgID conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) GetSavedFromPeer ¶
func (m *MessageFwdHeader) GetSavedFromPeer() (value PeerClass, ok bool)
GetSavedFromPeer returns value of SavedFromPeer conditional field and boolean which is true if field was set.
func (*MessageFwdHeader) SetChannelPost ¶
func (m *MessageFwdHeader) SetChannelPost(value int)
SetChannelPost sets value of ChannelPost conditional field.
func (*MessageFwdHeader) SetFromID ¶
func (m *MessageFwdHeader) SetFromID(value PeerClass)
SetFromID sets value of FromID conditional field.
func (*MessageFwdHeader) SetFromName ¶
func (m *MessageFwdHeader) SetFromName(value string)
SetFromName sets value of FromName conditional field.
func (*MessageFwdHeader) SetPostAuthor ¶
func (m *MessageFwdHeader) SetPostAuthor(value string)
SetPostAuthor sets value of PostAuthor conditional field.
func (*MessageFwdHeader) SetPsaType ¶
func (m *MessageFwdHeader) SetPsaType(value string)
SetPsaType sets value of PsaType conditional field.
func (*MessageFwdHeader) SetSavedFromMsgID ¶
func (m *MessageFwdHeader) SetSavedFromMsgID(value int)
SetSavedFromMsgID sets value of SavedFromMsgID conditional field.
func (*MessageFwdHeader) SetSavedFromPeer ¶
func (m *MessageFwdHeader) SetSavedFromPeer(value PeerClass)
SetSavedFromPeer sets value of SavedFromPeer conditional field.
func (*MessageFwdHeader) String ¶ added in v0.12.0
func (m *MessageFwdHeader) String() string
String implements fmt.Stringer.
type MessageIDHandler ¶ added in v0.9.0
type MessageIDHandler func(ctx UpdateContext, update *UpdateMessageID) error
MessageIDHandler is a MessageID event handler.
type MessageInteractionCounters ¶
type MessageInteractionCounters struct {
// Message ID
MsgID int
// Views
Views int
// Number of times this message was forwarded
Forwards int
}
MessageInteractionCounters represents TL type `messageInteractionCounters#ad4fc9bd`. Message interaction counters
See https://core.telegram.org/constructor/messageInteractionCounters for reference.
func (*MessageInteractionCounters) Decode ¶
func (m *MessageInteractionCounters) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageInteractionCounters) Encode ¶
func (m *MessageInteractionCounters) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageInteractionCounters) String ¶ added in v0.12.0
func (m *MessageInteractionCounters) String() string
String implements fmt.Stringer.
type MessageMediaBox ¶
type MessageMediaBox struct {
MessageMedia MessageMediaClass
}
MessageMedia boxes the MessageMediaClass providing a helper.
type MessageMediaClass ¶
type MessageMediaClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessageMediaClass represents MessageMedia generic type.
See https://core.telegram.org/type/MessageMedia for reference.
Example:
g, err := DecodeMessageMedia(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessageMediaEmpty: // messageMediaEmpty#3ded6320
case *MessageMediaPhoto: // messageMediaPhoto#695150d7
case *MessageMediaGeo: // messageMediaGeo#56e0d474
case *MessageMediaContact: // messageMediaContact#cbf24940
case *MessageMediaUnsupported: // messageMediaUnsupported#9f84f49e
case *MessageMediaDocument: // messageMediaDocument#9cb070d7
case *MessageMediaWebPage: // messageMediaWebPage#a32dd600
case *MessageMediaVenue: // messageMediaVenue#2ec0533f
case *MessageMediaGame: // messageMediaGame#fdb19008
case *MessageMediaInvoice: // messageMediaInvoice#84551347
case *MessageMediaGeoLive: // messageMediaGeoLive#b940c666
case *MessageMediaPoll: // messageMediaPoll#4bd6e798
case *MessageMediaDice: // messageMediaDice#3f7ee58b
default: panic(v)
}
func DecodeMessageMedia ¶
func DecodeMessageMedia(buf *bin.Buffer) (MessageMediaClass, error)
DecodeMessageMedia implements binary de-serialization for MessageMediaClass.
type MessageMediaContact ¶
type MessageMediaContact struct {
// Phone number
PhoneNumber string
// Contact's first name
FirstName string
// Contact's last name
LastName string
// VCARD of contact
Vcard string
// User identifier or 0, if the user with the given phone number is not registered
UserID int
}
MessageMediaContact represents TL type `messageMediaContact#cbf24940`. Attached contact.
See https://core.telegram.org/constructor/messageMediaContact for reference.
func (*MessageMediaContact) Decode ¶
func (m *MessageMediaContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaContact) Encode ¶
func (m *MessageMediaContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaContact) String ¶ added in v0.12.0
func (m *MessageMediaContact) String() string
String implements fmt.Stringer.
type MessageMediaDice ¶
type MessageMediaDice struct {
// Dice value¹
//
// Links:
// 1) https://core.telegram.org/api/dice
Value int
// The emoji, for now , and are supported
Emoticon string
}
MessageMediaDice represents TL type `messageMediaDice#3f7ee58b`. Dice-based animated sticker¹
Links:
See https://core.telegram.org/constructor/messageMediaDice for reference.
func (*MessageMediaDice) Decode ¶
func (m *MessageMediaDice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaDice) Encode ¶
func (m *MessageMediaDice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaDice) String ¶ added in v0.12.0
func (m *MessageMediaDice) String() string
String implements fmt.Stringer.
type MessageMediaDocument ¶
type MessageMediaDocument struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Attached document
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
// Time to live of self-destructing document
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
MessageMediaDocument represents TL type `messageMediaDocument#9cb070d7`. Document (video, audio, voice, sticker, any media type except photo)
See https://core.telegram.org/constructor/messageMediaDocument for reference.
func (*MessageMediaDocument) Decode ¶
func (m *MessageMediaDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaDocument) Encode ¶
func (m *MessageMediaDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaDocument) GetDocument ¶
func (m *MessageMediaDocument) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*MessageMediaDocument) GetTTLSeconds ¶
func (m *MessageMediaDocument) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*MessageMediaDocument) SetDocument ¶
func (m *MessageMediaDocument) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
func (*MessageMediaDocument) SetTTLSeconds ¶
func (m *MessageMediaDocument) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*MessageMediaDocument) String ¶ added in v0.12.0
func (m *MessageMediaDocument) String() string
String implements fmt.Stringer.
type MessageMediaEmpty ¶
type MessageMediaEmpty struct {
}
MessageMediaEmpty represents TL type `messageMediaEmpty#3ded6320`. Empty constructor.
See https://core.telegram.org/constructor/messageMediaEmpty for reference.
func (*MessageMediaEmpty) Decode ¶
func (m *MessageMediaEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaEmpty) Encode ¶
func (m *MessageMediaEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaEmpty) String ¶ added in v0.12.0
func (m *MessageMediaEmpty) String() string
String implements fmt.Stringer.
type MessageMediaGame ¶
type MessageMediaGame struct {
// Game
Game Game
}
MessageMediaGame represents TL type `messageMediaGame#fdb19008`. Telegram game
See https://core.telegram.org/constructor/messageMediaGame for reference.
func (*MessageMediaGame) Decode ¶
func (m *MessageMediaGame) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaGame) Encode ¶
func (m *MessageMediaGame) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaGame) String ¶ added in v0.12.0
func (m *MessageMediaGame) String() string
String implements fmt.Stringer.
type MessageMediaGeo ¶
type MessageMediaGeo struct {
// GeoPoint
Geo GeoPointClass
}
MessageMediaGeo represents TL type `messageMediaGeo#56e0d474`. Attached map.
See https://core.telegram.org/constructor/messageMediaGeo for reference.
func (*MessageMediaGeo) Decode ¶
func (m *MessageMediaGeo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaGeo) Encode ¶
func (m *MessageMediaGeo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaGeo) String ¶ added in v0.12.0
func (m *MessageMediaGeo) String() string
String implements fmt.Stringer.
type MessageMediaGeoLive ¶
type MessageMediaGeoLive struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Geolocation
Geo GeoPointClass
// For live locations¹, a direction in which the location moves, in degrees; 1-360
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetHeading and GetHeading helpers.
Heading int
// Validity period of provided geolocation
Period int
// For live locations¹, a maximum distance to another chat member for proximity alerts, in meters (0-100000).
//
// Links:
// 1) https://core.telegram.org/api/live-location
//
// Use SetProximityNotificationRadius and GetProximityNotificationRadius helpers.
ProximityNotificationRadius int
}
MessageMediaGeoLive represents TL type `messageMediaGeoLive#b940c666`. Indicates a live geolocation¹
Links:
See https://core.telegram.org/constructor/messageMediaGeoLive for reference.
func (*MessageMediaGeoLive) Decode ¶
func (m *MessageMediaGeoLive) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaGeoLive) Encode ¶
func (m *MessageMediaGeoLive) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaGeoLive) GetHeading ¶
func (m *MessageMediaGeoLive) GetHeading() (value int, ok bool)
GetHeading returns value of Heading conditional field and boolean which is true if field was set.
func (*MessageMediaGeoLive) GetProximityNotificationRadius ¶
func (m *MessageMediaGeoLive) GetProximityNotificationRadius() (value int, ok bool)
GetProximityNotificationRadius returns value of ProximityNotificationRadius conditional field and boolean which is true if field was set.
func (*MessageMediaGeoLive) SetHeading ¶
func (m *MessageMediaGeoLive) SetHeading(value int)
SetHeading sets value of Heading conditional field.
func (*MessageMediaGeoLive) SetProximityNotificationRadius ¶
func (m *MessageMediaGeoLive) SetProximityNotificationRadius(value int)
SetProximityNotificationRadius sets value of ProximityNotificationRadius conditional field.
func (*MessageMediaGeoLive) String ¶ added in v0.12.0
func (m *MessageMediaGeoLive) String() string
String implements fmt.Stringer.
type MessageMediaInvoice ¶
type MessageMediaInvoice struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the shipping address was requested
ShippingAddressRequested bool
// Whether this is an example invoice
Test bool
// Product name, 1-32 characters
Title string
// Product description, 1-255 characters
Description string
// URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for.
//
// Use SetPhoto and GetPhoto helpers.
Photo WebDocumentClass
// Message ID of receipt: if set, clients should change the text of the first keyboardButtonBuy¹ button always attached to the message² to a localized version of the word Receipt
//
// Links:
// 1) https://core.telegram.org/constructor/keyboardButtonBuy
// 2) https://core.telegram.org/constructor/message
//
// Use SetReceiptMsgID and GetReceiptMsgID helpers.
ReceiptMsgID int
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Total price in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
TotalAmount int64
// Unique bot deep-linking parameter that can be used to generate this invoice
StartParam string
}
MessageMediaInvoice represents TL type `messageMediaInvoice#84551347`. Invoice
See https://core.telegram.org/constructor/messageMediaInvoice for reference.
func (*MessageMediaInvoice) Decode ¶
func (m *MessageMediaInvoice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaInvoice) Encode ¶
func (m *MessageMediaInvoice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaInvoice) GetPhoto ¶
func (m *MessageMediaInvoice) GetPhoto() (value WebDocumentClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*MessageMediaInvoice) GetReceiptMsgID ¶
func (m *MessageMediaInvoice) GetReceiptMsgID() (value int, ok bool)
GetReceiptMsgID returns value of ReceiptMsgID conditional field and boolean which is true if field was set.
func (*MessageMediaInvoice) SetPhoto ¶
func (m *MessageMediaInvoice) SetPhoto(value WebDocumentClass)
SetPhoto sets value of Photo conditional field.
func (*MessageMediaInvoice) SetReceiptMsgID ¶
func (m *MessageMediaInvoice) SetReceiptMsgID(value int)
SetReceiptMsgID sets value of ReceiptMsgID conditional field.
func (*MessageMediaInvoice) SetShippingAddressRequested ¶
func (m *MessageMediaInvoice) SetShippingAddressRequested(value bool)
SetShippingAddressRequested sets value of ShippingAddressRequested conditional field.
func (*MessageMediaInvoice) SetTest ¶
func (m *MessageMediaInvoice) SetTest(value bool)
SetTest sets value of Test conditional field.
func (*MessageMediaInvoice) String ¶ added in v0.12.0
func (m *MessageMediaInvoice) String() string
String implements fmt.Stringer.
type MessageMediaPhoto ¶
type MessageMediaPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Photo
//
// Use SetPhoto and GetPhoto helpers.
Photo PhotoClass
// Time to live in seconds of self-destructing photo
//
// Use SetTTLSeconds and GetTTLSeconds helpers.
TTLSeconds int
}
MessageMediaPhoto represents TL type `messageMediaPhoto#695150d7`. Attached photo.
See https://core.telegram.org/constructor/messageMediaPhoto for reference.
func (*MessageMediaPhoto) Decode ¶
func (m *MessageMediaPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaPhoto) Encode ¶
func (m *MessageMediaPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaPhoto) GetPhoto ¶
func (m *MessageMediaPhoto) GetPhoto() (value PhotoClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*MessageMediaPhoto) GetTTLSeconds ¶
func (m *MessageMediaPhoto) GetTTLSeconds() (value int, ok bool)
GetTTLSeconds returns value of TTLSeconds conditional field and boolean which is true if field was set.
func (*MessageMediaPhoto) SetPhoto ¶
func (m *MessageMediaPhoto) SetPhoto(value PhotoClass)
SetPhoto sets value of Photo conditional field.
func (*MessageMediaPhoto) SetTTLSeconds ¶
func (m *MessageMediaPhoto) SetTTLSeconds(value int)
SetTTLSeconds sets value of TTLSeconds conditional field.
func (*MessageMediaPhoto) String ¶ added in v0.12.0
func (m *MessageMediaPhoto) String() string
String implements fmt.Stringer.
type MessageMediaPoll ¶
type MessageMediaPoll struct {
// The poll
Poll Poll
// The results of the poll
Results PollResults
}
MessageMediaPoll represents TL type `messageMediaPoll#4bd6e798`. Poll
See https://core.telegram.org/constructor/messageMediaPoll for reference.
func (*MessageMediaPoll) Decode ¶
func (m *MessageMediaPoll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaPoll) Encode ¶
func (m *MessageMediaPoll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaPoll) String ¶ added in v0.12.0
func (m *MessageMediaPoll) String() string
String implements fmt.Stringer.
type MessageMediaUnsupported ¶
type MessageMediaUnsupported struct {
}
MessageMediaUnsupported represents TL type `messageMediaUnsupported#9f84f49e`. Current version of the client does not support this media type.
See https://core.telegram.org/constructor/messageMediaUnsupported for reference.
func (*MessageMediaUnsupported) Decode ¶
func (m *MessageMediaUnsupported) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaUnsupported) Encode ¶
func (m *MessageMediaUnsupported) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaUnsupported) String ¶ added in v0.12.0
func (m *MessageMediaUnsupported) String() string
String implements fmt.Stringer.
type MessageMediaVenue ¶
type MessageMediaVenue struct {
// Geolocation of venue
Geo GeoPointClass
// Venue name
Title string
// Address
Address string
// Venue provider: currently only "foursquare" needs to be supported
Provider string
// Venue ID in the provider's database
VenueID string
// Venue type in the provider's database
VenueType string
}
MessageMediaVenue represents TL type `messageMediaVenue#2ec0533f`. Venue
See https://core.telegram.org/constructor/messageMediaVenue for reference.
func (*MessageMediaVenue) Decode ¶
func (m *MessageMediaVenue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaVenue) Encode ¶
func (m *MessageMediaVenue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaVenue) String ¶ added in v0.12.0
func (m *MessageMediaVenue) String() string
String implements fmt.Stringer.
type MessageMediaWebPage ¶
type MessageMediaWebPage struct {
// Webpage preview
Webpage WebPageClass
}
MessageMediaWebPage represents TL type `messageMediaWebPage#a32dd600`. Preview of webpage
See https://core.telegram.org/constructor/messageMediaWebPage for reference.
func (*MessageMediaWebPage) Decode ¶
func (m *MessageMediaWebPage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageMediaWebPage) Encode ¶
func (m *MessageMediaWebPage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageMediaWebPage) String ¶ added in v0.12.0
func (m *MessageMediaWebPage) String() string
String implements fmt.Stringer.
type MessagePollHandler ¶ added in v0.9.0
type MessagePollHandler func(ctx UpdateContext, update *UpdateMessagePoll) error
MessagePollHandler is a MessagePoll event handler.
type MessagePollVoteHandler ¶ added in v0.9.0
type MessagePollVoteHandler func(ctx UpdateContext, update *UpdateMessagePollVote) error
MessagePollVoteHandler is a MessagePollVote event handler.
type MessageRange ¶
type MessageRange struct {
// Start of range (message ID)
MinID int
// End of range (message ID)
MaxID int
}
MessageRange represents TL type `messageRange#ae30253`. Indicates a range of chat messages
See https://core.telegram.org/constructor/messageRange for reference.
func (*MessageRange) Decode ¶
func (m *MessageRange) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageRange) Encode ¶
func (m *MessageRange) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageRange) String ¶ added in v0.12.0
func (m *MessageRange) String() string
String implements fmt.Stringer.
type MessageRangeVector ¶ added in v0.8.0
type MessageRangeVector struct {
// Elements of Vector<MessageRange>
Elems []MessageRange
}
MessageRangeVector is a box for Vector<MessageRange>
func (*MessageRangeVector) Decode ¶ added in v0.8.0
func (vec *MessageRangeVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageRangeVector) Encode ¶ added in v0.8.0
func (vec *MessageRangeVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageRangeVector) String ¶ added in v0.12.0
func (vec *MessageRangeVector) String() string
String implements fmt.Stringer.
type MessageReplies ¶
type MessageReplies struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this constructor contains information about the comment section of a channel post, or a simple message thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
Comments bool
// Contains the total number of replies in this thread or comment section.
Replies int
// PTS¹ of the message that started this thread.
//
// Links:
// 1) https://core.telegram.org/api/updates
RepliesPts int
// For channel post comments, contains information about the last few comment posters for a specific thread, to show a small list of commenter profile pictures in client previews.
//
// Use SetRecentRepliers and GetRecentRepliers helpers.
RecentRepliers []PeerClass
// For channel post comments, contains the ID of the associated discussion supergroup¹
//
// Links:
// 1) https://core.telegram.org/api/discussion
//
// Use SetChannelID and GetChannelID helpers.
ChannelID int
// ID of the latest message in this thread or comment section.
//
// Use SetMaxID and GetMaxID helpers.
MaxID int
// Contains the ID of the latest read message in this thread or comment section.
//
// Use SetReadMaxID and GetReadMaxID helpers.
ReadMaxID int
}
MessageReplies represents TL type `messageReplies#4128faac`. Info about the comment section of a channel post, or a simple message thread¹
Links:
See https://core.telegram.org/constructor/messageReplies for reference.
func (*MessageReplies) Decode ¶
func (m *MessageReplies) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageReplies) Encode ¶
func (m *MessageReplies) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageReplies) GetChannelID ¶
func (m *MessageReplies) GetChannelID() (value int, ok bool)
GetChannelID returns value of ChannelID conditional field and boolean which is true if field was set.
func (*MessageReplies) GetMaxID ¶
func (m *MessageReplies) GetMaxID() (value int, ok bool)
GetMaxID returns value of MaxID conditional field and boolean which is true if field was set.
func (*MessageReplies) GetReadMaxID ¶
func (m *MessageReplies) GetReadMaxID() (value int, ok bool)
GetReadMaxID returns value of ReadMaxID conditional field and boolean which is true if field was set.
func (*MessageReplies) GetRecentRepliers ¶
func (m *MessageReplies) GetRecentRepliers() (value []PeerClass, ok bool)
GetRecentRepliers returns value of RecentRepliers conditional field and boolean which is true if field was set.
func (*MessageReplies) SetChannelID ¶
func (m *MessageReplies) SetChannelID(value int)
SetChannelID sets value of ChannelID conditional field.
func (*MessageReplies) SetComments ¶
func (m *MessageReplies) SetComments(value bool)
SetComments sets value of Comments conditional field.
func (*MessageReplies) SetMaxID ¶
func (m *MessageReplies) SetMaxID(value int)
SetMaxID sets value of MaxID conditional field.
func (*MessageReplies) SetReadMaxID ¶
func (m *MessageReplies) SetReadMaxID(value int)
SetReadMaxID sets value of ReadMaxID conditional field.
func (*MessageReplies) SetRecentRepliers ¶
func (m *MessageReplies) SetRecentRepliers(value []PeerClass)
SetRecentRepliers sets value of RecentRepliers conditional field.
func (*MessageReplies) String ¶ added in v0.12.0
func (m *MessageReplies) String() string
String implements fmt.Stringer.
type MessageReplyHeader ¶
type MessageReplyHeader struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// ID of message to which this message is replying
ReplyToMsgID int
// For replies sent in channel discussion threads¹ of which the current user is not a member, the discussion group ID
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReplyToPeerID and GetReplyToPeerID helpers.
ReplyToPeerID PeerClass
// ID of the message that started this message thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReplyToTopID and GetReplyToTopID helpers.
ReplyToTopID int
}
MessageReplyHeader represents TL type `messageReplyHeader#a6d57763`. Message replies and thread¹ information
Links:
See https://core.telegram.org/constructor/messageReplyHeader for reference.
func (*MessageReplyHeader) Decode ¶
func (m *MessageReplyHeader) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageReplyHeader) Encode ¶
func (m *MessageReplyHeader) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageReplyHeader) GetReplyToPeerID ¶
func (m *MessageReplyHeader) GetReplyToPeerID() (value PeerClass, ok bool)
GetReplyToPeerID returns value of ReplyToPeerID conditional field and boolean which is true if field was set.
func (*MessageReplyHeader) GetReplyToTopID ¶
func (m *MessageReplyHeader) GetReplyToTopID() (value int, ok bool)
GetReplyToTopID returns value of ReplyToTopID conditional field and boolean which is true if field was set.
func (*MessageReplyHeader) SetReplyToPeerID ¶
func (m *MessageReplyHeader) SetReplyToPeerID(value PeerClass)
SetReplyToPeerID sets value of ReplyToPeerID conditional field.
func (*MessageReplyHeader) SetReplyToTopID ¶
func (m *MessageReplyHeader) SetReplyToTopID(value int)
SetReplyToTopID sets value of ReplyToTopID conditional field.
func (*MessageReplyHeader) String ¶ added in v0.12.0
func (m *MessageReplyHeader) String() string
String implements fmt.Stringer.
type MessageService ¶
type MessageService struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the message is outgoing
Out bool
// Whether we were mentioned in the message
Mentioned bool
// Whether the message contains unread media
MediaUnread bool
// Whether the message is silent
Silent bool
// Whether it's a channel post
Post bool
// This is a legacy message: it has to be refetched with the new layer
Legacy bool
// Message ID
ID int
// ID of the sender of this message
//
// Use SetFromID and GetFromID helpers.
FromID PeerClass
// Sender of service message
PeerID PeerClass
// Reply (thread) information
//
// Use SetReplyTo and GetReplyTo helpers.
ReplyTo MessageReplyHeader
// Message date
Date int
// Event connected with the service message
Action MessageActionClass
}
MessageService represents TL type `messageService#286fa604`. Indicates a service message
See https://core.telegram.org/constructor/messageService for reference.
func (*MessageService) Decode ¶
func (m *MessageService) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageService) Encode ¶
func (m *MessageService) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageService) GetFromID ¶
func (m *MessageService) GetFromID() (value PeerClass, ok bool)
GetFromID returns value of FromID conditional field and boolean which is true if field was set.
func (*MessageService) GetReplyTo ¶
func (m *MessageService) GetReplyTo() (value MessageReplyHeader, ok bool)
GetReplyTo returns value of ReplyTo conditional field and boolean which is true if field was set.
func (*MessageService) SetFromID ¶
func (m *MessageService) SetFromID(value PeerClass)
SetFromID sets value of FromID conditional field.
func (*MessageService) SetLegacy ¶
func (m *MessageService) SetLegacy(value bool)
SetLegacy sets value of Legacy conditional field.
func (*MessageService) SetMediaUnread ¶
func (m *MessageService) SetMediaUnread(value bool)
SetMediaUnread sets value of MediaUnread conditional field.
func (*MessageService) SetMentioned ¶
func (m *MessageService) SetMentioned(value bool)
SetMentioned sets value of Mentioned conditional field.
func (*MessageService) SetOut ¶
func (m *MessageService) SetOut(value bool)
SetOut sets value of Out conditional field.
func (*MessageService) SetPost ¶
func (m *MessageService) SetPost(value bool)
SetPost sets value of Post conditional field.
func (*MessageService) SetReplyTo ¶
func (m *MessageService) SetReplyTo(value MessageReplyHeader)
SetReplyTo sets value of ReplyTo conditional field.
func (*MessageService) SetSilent ¶
func (m *MessageService) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessageService) String ¶ added in v0.12.0
func (m *MessageService) String() string
String implements fmt.Stringer.
type MessageUserVote ¶
type MessageUserVote struct {
// User ID
UserID int
// The option chosen by the user
Option []byte
// When did the user cast the vote
Date int
}
MessageUserVote represents TL type `messageUserVote#a28e5559`. How a user voted in a poll
See https://core.telegram.org/constructor/messageUserVote for reference.
func (*MessageUserVote) Decode ¶
func (m *MessageUserVote) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageUserVote) Encode ¶
func (m *MessageUserVote) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageUserVote) String ¶ added in v0.12.0
func (m *MessageUserVote) String() string
String implements fmt.Stringer.
type MessageUserVoteBox ¶
type MessageUserVoteBox struct {
MessageUserVote MessageUserVoteClass
}
MessageUserVote boxes the MessageUserVoteClass providing a helper.
type MessageUserVoteClass ¶
type MessageUserVoteClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessageUserVoteClass represents MessageUserVote generic type.
See https://core.telegram.org/type/MessageUserVote for reference.
Example:
g, err := DecodeMessageUserVote(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessageUserVote: // messageUserVote#a28e5559
case *MessageUserVoteInputOption: // messageUserVoteInputOption#36377430
case *MessageUserVoteMultiple: // messageUserVoteMultiple#e8fe0de
default: panic(v)
}
func DecodeMessageUserVote ¶
func DecodeMessageUserVote(buf *bin.Buffer) (MessageUserVoteClass, error)
DecodeMessageUserVote implements binary de-serialization for MessageUserVoteClass.
type MessageUserVoteInputOption ¶
type MessageUserVoteInputOption struct {
// The user that voted for the queried option
UserID int
// When did the user cast the vote
Date int
}
MessageUserVoteInputOption represents TL type `messageUserVoteInputOption#36377430`. How a user voted in a poll (reduced constructor, returned if an option was provided to messages.getPollVotes¹)
Links:
See https://core.telegram.org/constructor/messageUserVoteInputOption for reference.
func (*MessageUserVoteInputOption) Decode ¶
func (m *MessageUserVoteInputOption) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageUserVoteInputOption) Encode ¶
func (m *MessageUserVoteInputOption) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageUserVoteInputOption) String ¶ added in v0.12.0
func (m *MessageUserVoteInputOption) String() string
String implements fmt.Stringer.
type MessageUserVoteMultiple ¶
type MessageUserVoteMultiple struct {
// User ID
UserID int
// Options chosen by the user
Options [][]byte
// When did the user cast their votes
Date int
}
MessageUserVoteMultiple represents TL type `messageUserVoteMultiple#e8fe0de`. How a user voted in a multiple-choice poll
See https://core.telegram.org/constructor/messageUserVoteMultiple for reference.
func (*MessageUserVoteMultiple) Decode ¶
func (m *MessageUserVoteMultiple) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageUserVoteMultiple) Encode ¶
func (m *MessageUserVoteMultiple) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageUserVoteMultiple) String ¶ added in v0.12.0
func (m *MessageUserVoteMultiple) String() string
String implements fmt.Stringer.
type MessageViews ¶
type MessageViews struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Viewcount of message
//
// Use SetViews and GetViews helpers.
Views int
// Forward count of message
//
// Use SetForwards and GetForwards helpers.
Forwards int
// Reply and thread¹ information of message
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReplies and GetReplies helpers.
Replies MessageReplies
}
MessageViews represents TL type `messageViews#455b853d`. View, forward counter + info about replies of a specific message
See https://core.telegram.org/constructor/messageViews for reference.
func (*MessageViews) Decode ¶
func (m *MessageViews) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessageViews) Encode ¶
func (m *MessageViews) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessageViews) GetForwards ¶
func (m *MessageViews) GetForwards() (value int, ok bool)
GetForwards returns value of Forwards conditional field and boolean which is true if field was set.
func (*MessageViews) GetReplies ¶
func (m *MessageViews) GetReplies() (value MessageReplies, ok bool)
GetReplies returns value of Replies conditional field and boolean which is true if field was set.
func (*MessageViews) GetViews ¶
func (m *MessageViews) GetViews() (value int, ok bool)
GetViews returns value of Views conditional field and boolean which is true if field was set.
func (*MessageViews) SetForwards ¶
func (m *MessageViews) SetForwards(value int)
SetForwards sets value of Forwards conditional field.
func (*MessageViews) SetReplies ¶
func (m *MessageViews) SetReplies(value MessageReplies)
SetReplies sets value of Replies conditional field.
func (*MessageViews) SetViews ¶
func (m *MessageViews) SetViews(value int)
SetViews sets value of Views conditional field.
func (*MessageViews) String ¶ added in v0.12.0
func (m *MessageViews) String() string
String implements fmt.Stringer.
type MessagesAcceptEncryptionRequest ¶
type MessagesAcceptEncryptionRequest struct {
// Secret chat ID
Peer InputEncryptedChat
// B = g ^ b mod p, see Wikipedia¹
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
GB []byte
// 64-bit fingerprint of the received key
KeyFingerprint int64
}
MessagesAcceptEncryptionRequest represents TL type `messages.acceptEncryption#3dbc0415`. Confirms creation of a secret chat
See https://core.telegram.org/method/messages.acceptEncryption for reference.
func (*MessagesAcceptEncryptionRequest) Decode ¶
func (a *MessagesAcceptEncryptionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAcceptEncryptionRequest) Encode ¶
func (a *MessagesAcceptEncryptionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAcceptEncryptionRequest) String ¶ added in v0.12.0
func (a *MessagesAcceptEncryptionRequest) String() string
String implements fmt.Stringer.
type MessagesAcceptUrlAuthRequest ¶
type MessagesAcceptUrlAuthRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag to allow the bot to send messages to you (if requested)
WriteAllowed bool
// The location of the message
Peer InputPeerClass
// Message ID of the message with the login button
MsgID int
// ID of the login button
ButtonID int
}
MessagesAcceptUrlAuthRequest represents TL type `messages.acceptUrlAuth#f729ea98`. Use this to accept a Seamless Telegram Login authorization request, for more info click here »¹
Links:
See https://core.telegram.org/method/messages.acceptUrlAuth for reference.
func (*MessagesAcceptUrlAuthRequest) Decode ¶
func (a *MessagesAcceptUrlAuthRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAcceptUrlAuthRequest) Encode ¶
func (a *MessagesAcceptUrlAuthRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAcceptUrlAuthRequest) SetWriteAllowed ¶
func (a *MessagesAcceptUrlAuthRequest) SetWriteAllowed(value bool)
SetWriteAllowed sets value of WriteAllowed conditional field.
func (*MessagesAcceptUrlAuthRequest) String ¶ added in v0.12.0
func (a *MessagesAcceptUrlAuthRequest) String() string
String implements fmt.Stringer.
type MessagesAddChatUserRequest ¶
type MessagesAddChatUserRequest struct {
// Chat ID
ChatID int
// User ID to be added
UserID InputUserClass
// Number of last messages to be forwarded
FwdLimit int
}
MessagesAddChatUserRequest represents TL type `messages.addChatUser#f9a0aa09`. Adds a user to a chat and sends a service message on it.
See https://core.telegram.org/method/messages.addChatUser for reference.
func (*MessagesAddChatUserRequest) Decode ¶
func (a *MessagesAddChatUserRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAddChatUserRequest) Encode ¶
func (a *MessagesAddChatUserRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAddChatUserRequest) String ¶ added in v0.12.0
func (a *MessagesAddChatUserRequest) String() string
String implements fmt.Stringer.
type MessagesAffectedHistory ¶
type MessagesAffectedHistory struct {
// Number of events occured in a text box
Pts int
// Number of affected events
PtsCount int
// If a parameter contains positive value, it is necessary to repeat the method call using the given value; during the proceeding of all the history the value itself shall gradually decrease
Offset int
}
MessagesAffectedHistory represents TL type `messages.affectedHistory#b45c69d1`. Affected part of communication history with the user or in a chat.
See https://core.telegram.org/constructor/messages.affectedHistory for reference.
func (*MessagesAffectedHistory) Decode ¶
func (a *MessagesAffectedHistory) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAffectedHistory) Encode ¶
func (a *MessagesAffectedHistory) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAffectedHistory) String ¶ added in v0.12.0
func (a *MessagesAffectedHistory) String() string
String implements fmt.Stringer.
type MessagesAffectedMessages ¶
type MessagesAffectedMessages struct {
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
MessagesAffectedMessages represents TL type `messages.affectedMessages#84d19185`. Events affected by operation
See https://core.telegram.org/constructor/messages.affectedMessages for reference.
func (*MessagesAffectedMessages) Decode ¶
func (a *MessagesAffectedMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAffectedMessages) Encode ¶
func (a *MessagesAffectedMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAffectedMessages) String ¶ added in v0.12.0
func (a *MessagesAffectedMessages) String() string
String implements fmt.Stringer.
type MessagesAllStickers ¶
type MessagesAllStickers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// All stickersets
Sets []StickerSet
}
MessagesAllStickers represents TL type `messages.allStickers#edfd405f`. Info about all installed stickers
See https://core.telegram.org/constructor/messages.allStickers for reference.
func (*MessagesAllStickers) Decode ¶
func (a *MessagesAllStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAllStickers) Encode ¶
func (a *MessagesAllStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAllStickers) String ¶ added in v0.12.0
func (a *MessagesAllStickers) String() string
String implements fmt.Stringer.
type MessagesAllStickersBox ¶
type MessagesAllStickersBox struct {
AllStickers MessagesAllStickersClass
}
MessagesAllStickers boxes the MessagesAllStickersClass providing a helper.
type MessagesAllStickersClass ¶
type MessagesAllStickersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesAllStickersClass represents messages.AllStickers generic type.
See https://core.telegram.org/type/messages.AllStickers for reference.
Example:
g, err := DecodeMessagesAllStickers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesAllStickersNotModified: // messages.allStickersNotModified#e86602c3
case *MessagesAllStickers: // messages.allStickers#edfd405f
default: panic(v)
}
func DecodeMessagesAllStickers ¶
func DecodeMessagesAllStickers(buf *bin.Buffer) (MessagesAllStickersClass, error)
DecodeMessagesAllStickers implements binary de-serialization for MessagesAllStickersClass.
type MessagesAllStickersNotModified ¶
type MessagesAllStickersNotModified struct {
}
MessagesAllStickersNotModified represents TL type `messages.allStickersNotModified#e86602c3`. Info about all installed stickers hasn't changed
See https://core.telegram.org/constructor/messages.allStickersNotModified for reference.
func (*MessagesAllStickersNotModified) Decode ¶
func (a *MessagesAllStickersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesAllStickersNotModified) Encode ¶
func (a *MessagesAllStickersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesAllStickersNotModified) String ¶ added in v0.12.0
func (a *MessagesAllStickersNotModified) String() string
String implements fmt.Stringer.
type MessagesArchivedStickers ¶
type MessagesArchivedStickers struct {
// Number of archived stickers
Count int
// Archived stickersets
Sets []StickerSetCoveredClass
}
MessagesArchivedStickers represents TL type `messages.archivedStickers#4fcba9c8`. Archived stickersets
See https://core.telegram.org/constructor/messages.archivedStickers for reference.
func (*MessagesArchivedStickers) Decode ¶
func (a *MessagesArchivedStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesArchivedStickers) Encode ¶
func (a *MessagesArchivedStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesArchivedStickers) String ¶ added in v0.12.0
func (a *MessagesArchivedStickers) String() string
String implements fmt.Stringer.
type MessagesBotCallbackAnswer ¶
type MessagesBotCallbackAnswer struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether an alert should be shown to the user instead of a toast notification
Alert bool
// Whether an URL is present
HasURL bool
// Whether to show games in WebView or in native UI.
NativeUI bool
// Alert to show
//
// Use SetMessage and GetMessage helpers.
Message string
// URL to open
//
// Use SetURL and GetURL helpers.
URL string
// For how long should this answer be cached
CacheTime int
}
MessagesBotCallbackAnswer represents TL type `messages.botCallbackAnswer#36585ea4`. Callback answer sent by the bot in response to a button press
See https://core.telegram.org/constructor/messages.botCallbackAnswer for reference.
func (*MessagesBotCallbackAnswer) Decode ¶
func (b *MessagesBotCallbackAnswer) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesBotCallbackAnswer) Encode ¶
func (b *MessagesBotCallbackAnswer) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesBotCallbackAnswer) GetMessage ¶
func (b *MessagesBotCallbackAnswer) GetMessage() (value string, ok bool)
GetMessage returns value of Message conditional field and boolean which is true if field was set.
func (*MessagesBotCallbackAnswer) GetURL ¶
func (b *MessagesBotCallbackAnswer) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*MessagesBotCallbackAnswer) SetAlert ¶
func (b *MessagesBotCallbackAnswer) SetAlert(value bool)
SetAlert sets value of Alert conditional field.
func (*MessagesBotCallbackAnswer) SetHasURL ¶
func (b *MessagesBotCallbackAnswer) SetHasURL(value bool)
SetHasURL sets value of HasURL conditional field.
func (*MessagesBotCallbackAnswer) SetMessage ¶
func (b *MessagesBotCallbackAnswer) SetMessage(value string)
SetMessage sets value of Message conditional field.
func (*MessagesBotCallbackAnswer) SetNativeUI ¶
func (b *MessagesBotCallbackAnswer) SetNativeUI(value bool)
SetNativeUI sets value of NativeUI conditional field.
func (*MessagesBotCallbackAnswer) SetURL ¶
func (b *MessagesBotCallbackAnswer) SetURL(value string)
SetURL sets value of URL conditional field.
func (*MessagesBotCallbackAnswer) String ¶ added in v0.12.0
func (b *MessagesBotCallbackAnswer) String() string
String implements fmt.Stringer.
type MessagesBotResults ¶
type MessagesBotResults struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the result is a picture gallery
Gallery bool
// Query ID
QueryID int64
// The next offset to use when navigating through results
//
// Use SetNextOffset and GetNextOffset helpers.
NextOffset string
// Whether the bot requested the user to message him in private
//
// Use SetSwitchPm and GetSwitchPm helpers.
SwitchPm InlineBotSwitchPM
// The results
Results []BotInlineResultClass
// Caching validity of the results
CacheTime int
// Users mentioned in the results
Users []UserClass
}
MessagesBotResults represents TL type `messages.botResults#947ca848`. Result of a query to an inline bot
See https://core.telegram.org/constructor/messages.botResults for reference.
func (*MessagesBotResults) Decode ¶
func (b *MessagesBotResults) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesBotResults) Encode ¶
func (b *MessagesBotResults) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesBotResults) GetNextOffset ¶
func (b *MessagesBotResults) GetNextOffset() (value string, ok bool)
GetNextOffset returns value of NextOffset conditional field and boolean which is true if field was set.
func (*MessagesBotResults) GetSwitchPm ¶
func (b *MessagesBotResults) GetSwitchPm() (value InlineBotSwitchPM, ok bool)
GetSwitchPm returns value of SwitchPm conditional field and boolean which is true if field was set.
func (*MessagesBotResults) SetGallery ¶
func (b *MessagesBotResults) SetGallery(value bool)
SetGallery sets value of Gallery conditional field.
func (*MessagesBotResults) SetNextOffset ¶
func (b *MessagesBotResults) SetNextOffset(value string)
SetNextOffset sets value of NextOffset conditional field.
func (*MessagesBotResults) SetSwitchPm ¶
func (b *MessagesBotResults) SetSwitchPm(value InlineBotSwitchPM)
SetSwitchPm sets value of SwitchPm conditional field.
func (*MessagesBotResults) String ¶ added in v0.12.0
func (b *MessagesBotResults) String() string
String implements fmt.Stringer.
type MessagesChannelMessages ¶
type MessagesChannelMessages struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, returned results may be inexact
Inexact bool
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Total number of results were found server-side (may not be all included here)
Count int
// Indicates the absolute position of messages[0] within the total result set with count count. This is useful, for example, if the result was fetched using offset_id, and we need to display a progress/total counter (like photo 134 of 200, for all media in a chat, we could simply use photo ${offset_id_offset} of ${count}.
//
// Use SetOffsetIDOffset and GetOffsetIDOffset helpers.
OffsetIDOffset int
// Found messages
Messages []MessageClass
// Chats
Chats []ChatClass
// Users
Users []UserClass
}
MessagesChannelMessages represents TL type `messages.channelMessages#64479808`. Channel messages
See https://core.telegram.org/constructor/messages.channelMessages for reference.
func (*MessagesChannelMessages) Decode ¶
func (c *MessagesChannelMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesChannelMessages) Encode ¶
func (c *MessagesChannelMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesChannelMessages) GetOffsetIDOffset ¶
func (c *MessagesChannelMessages) GetOffsetIDOffset() (value int, ok bool)
GetOffsetIDOffset returns value of OffsetIDOffset conditional field and boolean which is true if field was set.
func (*MessagesChannelMessages) SetInexact ¶
func (c *MessagesChannelMessages) SetInexact(value bool)
SetInexact sets value of Inexact conditional field.
func (*MessagesChannelMessages) SetOffsetIDOffset ¶
func (c *MessagesChannelMessages) SetOffsetIDOffset(value int)
SetOffsetIDOffset sets value of OffsetIDOffset conditional field.
func (*MessagesChannelMessages) String ¶ added in v0.12.0
func (c *MessagesChannelMessages) String() string
String implements fmt.Stringer.
type MessagesChatFull ¶
type MessagesChatFull struct {
// Extended info on a chat
FullChat ChatFullClass
// List containing basic info on chat
Chats []ChatClass
// List of users mentioned above
Users []UserClass
}
MessagesChatFull represents TL type `messages.chatFull#e5d7d19c`. Extended info on chat and auxiliary data.
See https://core.telegram.org/constructor/messages.chatFull for reference.
func (*MessagesChatFull) Decode ¶
func (c *MessagesChatFull) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesChatFull) Encode ¶
func (c *MessagesChatFull) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesChatFull) String ¶ added in v0.12.0
func (c *MessagesChatFull) String() string
String implements fmt.Stringer.
type MessagesChats ¶
type MessagesChats struct {
// List of chats
Chats []ChatClass
}
MessagesChats represents TL type `messages.chats#64ff9fd5`. List of chats with auxiliary data.
See https://core.telegram.org/constructor/messages.chats for reference.
func (*MessagesChats) Decode ¶
func (c *MessagesChats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesChats) Encode ¶
func (c *MessagesChats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesChats) String ¶ added in v0.12.0
func (c *MessagesChats) String() string
String implements fmt.Stringer.
type MessagesChatsBox ¶
type MessagesChatsBox struct {
Chats MessagesChatsClass
}
MessagesChats boxes the MessagesChatsClass providing a helper.
type MessagesChatsClass ¶
type MessagesChatsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesChatsClass represents messages.Chats generic type.
See https://core.telegram.org/type/messages.Chats for reference.
Example:
g, err := DecodeMessagesChats(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesChats: // messages.chats#64ff9fd5
case *MessagesChatsSlice: // messages.chatsSlice#9cd81144
default: panic(v)
}
func DecodeMessagesChats ¶
func DecodeMessagesChats(buf *bin.Buffer) (MessagesChatsClass, error)
DecodeMessagesChats implements binary de-serialization for MessagesChatsClass.
type MessagesChatsSlice ¶
type MessagesChatsSlice struct {
// Total number of results that were found server-side (not all are included in chats)
Count int
// Chats
Chats []ChatClass
}
MessagesChatsSlice represents TL type `messages.chatsSlice#9cd81144`. Partial list of chats, more would have to be fetched with pagination¹
Links:
See https://core.telegram.org/constructor/messages.chatsSlice for reference.
func (*MessagesChatsSlice) Decode ¶
func (c *MessagesChatsSlice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesChatsSlice) Encode ¶
func (c *MessagesChatsSlice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesChatsSlice) String ¶ added in v0.12.0
func (c *MessagesChatsSlice) String() string
String implements fmt.Stringer.
type MessagesCheckChatInviteRequest ¶
type MessagesCheckChatInviteRequest struct {
// Invite hash in t.me/joinchat/hash
Hash string
}
MessagesCheckChatInviteRequest represents TL type `messages.checkChatInvite#3eadb1bb`. Check the validity of a chat invite link and get basic info about it
See https://core.telegram.org/method/messages.checkChatInvite for reference.
func (*MessagesCheckChatInviteRequest) Decode ¶
func (c *MessagesCheckChatInviteRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesCheckChatInviteRequest) Encode ¶
func (c *MessagesCheckChatInviteRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesCheckChatInviteRequest) String ¶ added in v0.12.0
func (c *MessagesCheckChatInviteRequest) String() string
String implements fmt.Stringer.
type MessagesClearAllDraftsRequest ¶
type MessagesClearAllDraftsRequest struct {
}
MessagesClearAllDraftsRequest represents TL type `messages.clearAllDrafts#7e58ee9c`. Clear all drafts¹.
Links:
See https://core.telegram.org/method/messages.clearAllDrafts for reference.
func (*MessagesClearAllDraftsRequest) Decode ¶
func (c *MessagesClearAllDraftsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesClearAllDraftsRequest) Encode ¶
func (c *MessagesClearAllDraftsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesClearAllDraftsRequest) String ¶ added in v0.12.0
func (c *MessagesClearAllDraftsRequest) String() string
String implements fmt.Stringer.
type MessagesClearRecentStickersRequest ¶
type MessagesClearRecentStickersRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag to clear the list of stickers recently attached to photo or video files
Attached bool
}
MessagesClearRecentStickersRequest represents TL type `messages.clearRecentStickers#8999602d`. Clear recent stickers
See https://core.telegram.org/method/messages.clearRecentStickers for reference.
func (*MessagesClearRecentStickersRequest) Decode ¶
func (c *MessagesClearRecentStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesClearRecentStickersRequest) Encode ¶
func (c *MessagesClearRecentStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesClearRecentStickersRequest) SetAttached ¶
func (c *MessagesClearRecentStickersRequest) SetAttached(value bool)
SetAttached sets value of Attached conditional field.
func (*MessagesClearRecentStickersRequest) String ¶ added in v0.12.0
func (c *MessagesClearRecentStickersRequest) String() string
String implements fmt.Stringer.
type MessagesCreateChatRequest ¶
type MessagesCreateChatRequest struct {
// List of user IDs to be invited
Users []InputUserClass
// Chat name
Title string
}
MessagesCreateChatRequest represents TL type `messages.createChat#9cb126e`. Creates a new chat.
See https://core.telegram.org/method/messages.createChat for reference.
func (*MessagesCreateChatRequest) Decode ¶
func (c *MessagesCreateChatRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesCreateChatRequest) Encode ¶
func (c *MessagesCreateChatRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesCreateChatRequest) String ¶ added in v0.12.0
func (c *MessagesCreateChatRequest) String() string
String implements fmt.Stringer.
type MessagesDeleteChatUserRequest ¶
type MessagesDeleteChatUserRequest struct {
// Chat ID
ChatID int
// User ID to be deleted
UserID InputUserClass
}
MessagesDeleteChatUserRequest represents TL type `messages.deleteChatUser#e0611f16`. Deletes a user from a chat and sends a service message on it.
See https://core.telegram.org/method/messages.deleteChatUser for reference.
func (*MessagesDeleteChatUserRequest) Decode ¶
func (d *MessagesDeleteChatUserRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDeleteChatUserRequest) Encode ¶
func (d *MessagesDeleteChatUserRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDeleteChatUserRequest) String ¶ added in v0.12.0
func (d *MessagesDeleteChatUserRequest) String() string
String implements fmt.Stringer.
type MessagesDeleteHistoryRequest ¶
type MessagesDeleteHistoryRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Just clear history for the current user, without actually removing messages for every chat user
JustClear bool
// Whether to delete the message history for all chat participants
Revoke bool
// User or chat, communication history of which will be deleted
Peer InputPeerClass
// Maximum ID of message to delete
MaxID int
}
MessagesDeleteHistoryRequest represents TL type `messages.deleteHistory#1c015b09`. Deletes communication history.
See https://core.telegram.org/method/messages.deleteHistory for reference.
func (*MessagesDeleteHistoryRequest) Decode ¶
func (d *MessagesDeleteHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDeleteHistoryRequest) Encode ¶
func (d *MessagesDeleteHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDeleteHistoryRequest) SetJustClear ¶
func (d *MessagesDeleteHistoryRequest) SetJustClear(value bool)
SetJustClear sets value of JustClear conditional field.
func (*MessagesDeleteHistoryRequest) SetRevoke ¶
func (d *MessagesDeleteHistoryRequest) SetRevoke(value bool)
SetRevoke sets value of Revoke conditional field.
func (*MessagesDeleteHistoryRequest) String ¶ added in v0.12.0
func (d *MessagesDeleteHistoryRequest) String() string
String implements fmt.Stringer.
type MessagesDeleteMessagesRequest ¶
type MessagesDeleteMessagesRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to delete messages for all participants of the chat
Revoke bool
// Message ID list
ID []int
}
MessagesDeleteMessagesRequest represents TL type `messages.deleteMessages#e58e95d2`. Deletes messages by their identifiers.
See https://core.telegram.org/method/messages.deleteMessages for reference.
func (*MessagesDeleteMessagesRequest) Decode ¶
func (d *MessagesDeleteMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDeleteMessagesRequest) Encode ¶
func (d *MessagesDeleteMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDeleteMessagesRequest) SetRevoke ¶
func (d *MessagesDeleteMessagesRequest) SetRevoke(value bool)
SetRevoke sets value of Revoke conditional field.
func (*MessagesDeleteMessagesRequest) String ¶ added in v0.12.0
func (d *MessagesDeleteMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesDeleteScheduledMessagesRequest ¶
type MessagesDeleteScheduledMessagesRequest struct {
// Peer
Peer InputPeerClass
// Scheduled message IDs
ID []int
}
MessagesDeleteScheduledMessagesRequest represents TL type `messages.deleteScheduledMessages#59ae2b16`. Delete scheduled messages
See https://core.telegram.org/method/messages.deleteScheduledMessages for reference.
func (*MessagesDeleteScheduledMessagesRequest) Decode ¶
func (d *MessagesDeleteScheduledMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDeleteScheduledMessagesRequest) Encode ¶
func (d *MessagesDeleteScheduledMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDeleteScheduledMessagesRequest) String ¶ added in v0.12.0
func (d *MessagesDeleteScheduledMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesDhConfig ¶
type MessagesDhConfig struct {
// New value prime, see Wikipedia¹
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
G int
// New value primitive root, see Wikipedia¹
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
P []byte
// Vestion of set of parameters
Version int
// Random sequence of bytes of assigned length
Random []byte
}
MessagesDhConfig represents TL type `messages.dhConfig#2c221edd`. New set of configuring parameters.
See https://core.telegram.org/constructor/messages.dhConfig for reference.
func (*MessagesDhConfig) Decode ¶
func (d *MessagesDhConfig) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDhConfig) Encode ¶
func (d *MessagesDhConfig) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDhConfig) String ¶ added in v0.12.0
func (d *MessagesDhConfig) String() string
String implements fmt.Stringer.
type MessagesDhConfigBox ¶
type MessagesDhConfigBox struct {
DhConfig MessagesDhConfigClass
}
MessagesDhConfig boxes the MessagesDhConfigClass providing a helper.
type MessagesDhConfigClass ¶
type MessagesDhConfigClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesDhConfigClass represents messages.DhConfig generic type.
See https://core.telegram.org/type/messages.DhConfig for reference.
Example:
g, err := DecodeMessagesDhConfig(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesDhConfigNotModified: // messages.dhConfigNotModified#c0e24635
case *MessagesDhConfig: // messages.dhConfig#2c221edd
default: panic(v)
}
func DecodeMessagesDhConfig ¶
func DecodeMessagesDhConfig(buf *bin.Buffer) (MessagesDhConfigClass, error)
DecodeMessagesDhConfig implements binary de-serialization for MessagesDhConfigClass.
type MessagesDhConfigNotModified ¶
type MessagesDhConfigNotModified struct {
// Random sequence of bytes of assigned length
Random []byte
}
MessagesDhConfigNotModified represents TL type `messages.dhConfigNotModified#c0e24635`. Configuring parameters did not change.
See https://core.telegram.org/constructor/messages.dhConfigNotModified for reference.
func (*MessagesDhConfigNotModified) Decode ¶
func (d *MessagesDhConfigNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDhConfigNotModified) Encode ¶
func (d *MessagesDhConfigNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDhConfigNotModified) String ¶ added in v0.12.0
func (d *MessagesDhConfigNotModified) String() string
String implements fmt.Stringer.
type MessagesDialogs ¶
type MessagesDialogs struct {
// List of chats
Dialogs []DialogClass
// List of last messages from each chat
Messages []MessageClass
// List of groups mentioned in the chats
Chats []ChatClass
// List of users mentioned in messages and groups
Users []UserClass
}
MessagesDialogs represents TL type `messages.dialogs#15ba6c40`. Full list of chats with messages and auxiliary data.
See https://core.telegram.org/constructor/messages.dialogs for reference.
func (*MessagesDialogs) Decode ¶
func (d *MessagesDialogs) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDialogs) Encode ¶
func (d *MessagesDialogs) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDialogs) String ¶ added in v0.12.0
func (d *MessagesDialogs) String() string
String implements fmt.Stringer.
type MessagesDialogsBox ¶
type MessagesDialogsBox struct {
Dialogs MessagesDialogsClass
}
MessagesDialogs boxes the MessagesDialogsClass providing a helper.
type MessagesDialogsClass ¶
type MessagesDialogsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesDialogsClass represents messages.Dialogs generic type.
See https://core.telegram.org/type/messages.Dialogs for reference.
Example:
g, err := DecodeMessagesDialogs(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesDialogs: // messages.dialogs#15ba6c40
case *MessagesDialogsSlice: // messages.dialogsSlice#71e094f3
case *MessagesDialogsNotModified: // messages.dialogsNotModified#f0e3e596
default: panic(v)
}
func DecodeMessagesDialogs ¶
func DecodeMessagesDialogs(buf *bin.Buffer) (MessagesDialogsClass, error)
DecodeMessagesDialogs implements binary de-serialization for MessagesDialogsClass.
type MessagesDialogsNotModified ¶
type MessagesDialogsNotModified struct {
// Number of dialogs found server-side by the query
Count int
}
MessagesDialogsNotModified represents TL type `messages.dialogsNotModified#f0e3e596`. Dialogs haven't changed
See https://core.telegram.org/constructor/messages.dialogsNotModified for reference.
func (*MessagesDialogsNotModified) Decode ¶
func (d *MessagesDialogsNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDialogsNotModified) Encode ¶
func (d *MessagesDialogsNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDialogsNotModified) String ¶ added in v0.12.0
func (d *MessagesDialogsNotModified) String() string
String implements fmt.Stringer.
type MessagesDialogsSlice ¶
type MessagesDialogsSlice struct {
// Total number of dialogs
Count int
// List of dialogs
Dialogs []DialogClass
// List of last messages from dialogs
Messages []MessageClass
// List of chats mentioned in dialogs
Chats []ChatClass
// List of users mentioned in messages and chats
Users []UserClass
}
MessagesDialogsSlice represents TL type `messages.dialogsSlice#71e094f3`. Incomplete list of dialogs with messages and auxiliary data.
See https://core.telegram.org/constructor/messages.dialogsSlice for reference.
func (*MessagesDialogsSlice) Decode ¶
func (d *MessagesDialogsSlice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDialogsSlice) Encode ¶
func (d *MessagesDialogsSlice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDialogsSlice) String ¶ added in v0.12.0
func (d *MessagesDialogsSlice) String() string
String implements fmt.Stringer.
type MessagesDiscardEncryptionRequest ¶
type MessagesDiscardEncryptionRequest struct {
// Secret chat ID
ChatID int
}
MessagesDiscardEncryptionRequest represents TL type `messages.discardEncryption#edd923c5`. Cancels a request for creation and/or delete info on secret chat.
See https://core.telegram.org/method/messages.discardEncryption for reference.
func (*MessagesDiscardEncryptionRequest) Decode ¶
func (d *MessagesDiscardEncryptionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDiscardEncryptionRequest) Encode ¶
func (d *MessagesDiscardEncryptionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDiscardEncryptionRequest) String ¶ added in v0.12.0
func (d *MessagesDiscardEncryptionRequest) String() string
String implements fmt.Stringer.
type MessagesDiscussionMessage ¶
type MessagesDiscussionMessage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Discussion messages
Messages []MessageClass
// Message ID of latest reply in this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetMaxID and GetMaxID helpers.
MaxID int
// Message ID of latest read incoming message in this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReadInboxMaxID and GetReadInboxMaxID helpers.
ReadInboxMaxID int
// Message ID of latest read outgoing message in this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReadOutboxMaxID and GetReadOutboxMaxID helpers.
ReadOutboxMaxID int
// Chats mentioned in constructor
Chats []ChatClass
// Users mentioned in constructor
Users []UserClass
}
MessagesDiscussionMessage represents TL type `messages.discussionMessage#f5dd8f9d`. Information about a message thread¹
Links:
See https://core.telegram.org/constructor/messages.discussionMessage for reference.
func (*MessagesDiscussionMessage) Decode ¶
func (d *MessagesDiscussionMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesDiscussionMessage) Encode ¶
func (d *MessagesDiscussionMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesDiscussionMessage) GetMaxID ¶
func (d *MessagesDiscussionMessage) GetMaxID() (value int, ok bool)
GetMaxID returns value of MaxID conditional field and boolean which is true if field was set.
func (*MessagesDiscussionMessage) GetReadInboxMaxID ¶
func (d *MessagesDiscussionMessage) GetReadInboxMaxID() (value int, ok bool)
GetReadInboxMaxID returns value of ReadInboxMaxID conditional field and boolean which is true if field was set.
func (*MessagesDiscussionMessage) GetReadOutboxMaxID ¶
func (d *MessagesDiscussionMessage) GetReadOutboxMaxID() (value int, ok bool)
GetReadOutboxMaxID returns value of ReadOutboxMaxID conditional field and boolean which is true if field was set.
func (*MessagesDiscussionMessage) SetMaxID ¶
func (d *MessagesDiscussionMessage) SetMaxID(value int)
SetMaxID sets value of MaxID conditional field.
func (*MessagesDiscussionMessage) SetReadInboxMaxID ¶
func (d *MessagesDiscussionMessage) SetReadInboxMaxID(value int)
SetReadInboxMaxID sets value of ReadInboxMaxID conditional field.
func (*MessagesDiscussionMessage) SetReadOutboxMaxID ¶
func (d *MessagesDiscussionMessage) SetReadOutboxMaxID(value int)
SetReadOutboxMaxID sets value of ReadOutboxMaxID conditional field.
func (*MessagesDiscussionMessage) String ¶ added in v0.12.0
func (d *MessagesDiscussionMessage) String() string
String implements fmt.Stringer.
type MessagesEditChatAboutRequest ¶
type MessagesEditChatAboutRequest struct {
// The group/supergroup/channel¹.
//
// Links:
// 1) https://core.telegram.org/api/channel
Peer InputPeerClass
// The new description
About string
}
MessagesEditChatAboutRequest represents TL type `messages.editChatAbout#def60797`. Edit the description of a group/supergroup/channel¹.
Links:
See https://core.telegram.org/method/messages.editChatAbout for reference.
func (*MessagesEditChatAboutRequest) Decode ¶
func (e *MessagesEditChatAboutRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditChatAboutRequest) Encode ¶
func (e *MessagesEditChatAboutRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditChatAboutRequest) String ¶ added in v0.12.0
func (e *MessagesEditChatAboutRequest) String() string
String implements fmt.Stringer.
type MessagesEditChatAdminRequest ¶
type MessagesEditChatAdminRequest struct {
// The ID of the group
ChatID int
// The user to make admin
UserID InputUserClass
// Whether to make him admin
IsAdmin bool
}
MessagesEditChatAdminRequest represents TL type `messages.editChatAdmin#a9e69f2e`. Make a user admin in a legacy group¹.
Links:
See https://core.telegram.org/method/messages.editChatAdmin for reference.
func (*MessagesEditChatAdminRequest) Decode ¶
func (e *MessagesEditChatAdminRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditChatAdminRequest) Encode ¶
func (e *MessagesEditChatAdminRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditChatAdminRequest) String ¶ added in v0.12.0
func (e *MessagesEditChatAdminRequest) String() string
String implements fmt.Stringer.
type MessagesEditChatDefaultBannedRightsRequest ¶
type MessagesEditChatDefaultBannedRightsRequest struct {
// The peer
Peer InputPeerClass
// The new global rights
BannedRights ChatBannedRights
}
MessagesEditChatDefaultBannedRightsRequest represents TL type `messages.editChatDefaultBannedRights#a5866b41`. Edit the default banned rights of a channel/supergroup/group¹.
Links:
See https://core.telegram.org/method/messages.editChatDefaultBannedRights for reference.
func (*MessagesEditChatDefaultBannedRightsRequest) Decode ¶
func (e *MessagesEditChatDefaultBannedRightsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditChatDefaultBannedRightsRequest) Encode ¶
func (e *MessagesEditChatDefaultBannedRightsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditChatDefaultBannedRightsRequest) String ¶ added in v0.12.0
func (e *MessagesEditChatDefaultBannedRightsRequest) String() string
String implements fmt.Stringer.
type MessagesEditChatPhotoRequest ¶
type MessagesEditChatPhotoRequest struct {
// Chat ID
ChatID int
// Photo to be set
Photo InputChatPhotoClass
}
MessagesEditChatPhotoRequest represents TL type `messages.editChatPhoto#ca4c79d8`. Changes chat photo and sends a service message on it
See https://core.telegram.org/method/messages.editChatPhoto for reference.
func (*MessagesEditChatPhotoRequest) Decode ¶
func (e *MessagesEditChatPhotoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditChatPhotoRequest) Encode ¶
func (e *MessagesEditChatPhotoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditChatPhotoRequest) String ¶ added in v0.12.0
func (e *MessagesEditChatPhotoRequest) String() string
String implements fmt.Stringer.
type MessagesEditChatTitleRequest ¶
type MessagesEditChatTitleRequest struct {
// Chat ID
ChatID int
// New chat name, different from the old one
Title string
}
MessagesEditChatTitleRequest represents TL type `messages.editChatTitle#dc452855`. Chanages chat name and sends a service message on it.
See https://core.telegram.org/method/messages.editChatTitle for reference.
func (*MessagesEditChatTitleRequest) Decode ¶
func (e *MessagesEditChatTitleRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditChatTitleRequest) Encode ¶
func (e *MessagesEditChatTitleRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditChatTitleRequest) String ¶ added in v0.12.0
func (e *MessagesEditChatTitleRequest) String() string
String implements fmt.Stringer.
type MessagesEditInlineBotMessageRequest ¶
type MessagesEditInlineBotMessageRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable webpage preview
NoWebpage bool
// Sent inline message ID
ID InputBotInlineMessageID
// Message
//
// Use SetMessage and GetMessage helpers.
Message string
// Media
//
// Use SetMedia and GetMedia helpers.
Media InputMediaClass
// Reply markup for inline keyboards
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
MessagesEditInlineBotMessageRequest represents TL type `messages.editInlineBotMessage#83557dba`. Edit an inline bot message
See https://core.telegram.org/method/messages.editInlineBotMessage for reference.
func (*MessagesEditInlineBotMessageRequest) Decode ¶
func (e *MessagesEditInlineBotMessageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditInlineBotMessageRequest) Encode ¶
func (e *MessagesEditInlineBotMessageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditInlineBotMessageRequest) GetEntities ¶
func (e *MessagesEditInlineBotMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesEditInlineBotMessageRequest) GetMedia ¶
func (e *MessagesEditInlineBotMessageRequest) GetMedia() (value InputMediaClass, ok bool)
GetMedia returns value of Media conditional field and boolean which is true if field was set.
func (*MessagesEditInlineBotMessageRequest) GetMessage ¶
func (e *MessagesEditInlineBotMessageRequest) GetMessage() (value string, ok bool)
GetMessage returns value of Message conditional field and boolean which is true if field was set.
func (*MessagesEditInlineBotMessageRequest) GetReplyMarkup ¶
func (e *MessagesEditInlineBotMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*MessagesEditInlineBotMessageRequest) SetEntities ¶
func (e *MessagesEditInlineBotMessageRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesEditInlineBotMessageRequest) SetMedia ¶
func (e *MessagesEditInlineBotMessageRequest) SetMedia(value InputMediaClass)
SetMedia sets value of Media conditional field.
func (*MessagesEditInlineBotMessageRequest) SetMessage ¶
func (e *MessagesEditInlineBotMessageRequest) SetMessage(value string)
SetMessage sets value of Message conditional field.
func (*MessagesEditInlineBotMessageRequest) SetNoWebpage ¶
func (e *MessagesEditInlineBotMessageRequest) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*MessagesEditInlineBotMessageRequest) SetReplyMarkup ¶
func (e *MessagesEditInlineBotMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*MessagesEditInlineBotMessageRequest) String ¶ added in v0.12.0
func (e *MessagesEditInlineBotMessageRequest) String() string
String implements fmt.Stringer.
type MessagesEditMessageRequest ¶
type MessagesEditMessageRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable webpage preview
NoWebpage bool
// Where was the message sent
Peer InputPeerClass
// ID of the message to edit
ID int
// New message
//
// Use SetMessage and GetMessage helpers.
Message string
// New attached media
//
// Use SetMedia and GetMedia helpers.
Media InputMediaClass
// Reply markup for inline keyboards
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Scheduled message date for scheduled messages¹
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesEditMessageRequest represents TL type `messages.editMessage#48f71778`. Edit message
See https://core.telegram.org/method/messages.editMessage for reference.
func (*MessagesEditMessageRequest) Decode ¶
func (e *MessagesEditMessageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesEditMessageRequest) Encode ¶
func (e *MessagesEditMessageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesEditMessageRequest) GetEntities ¶
func (e *MessagesEditMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesEditMessageRequest) GetMedia ¶
func (e *MessagesEditMessageRequest) GetMedia() (value InputMediaClass, ok bool)
GetMedia returns value of Media conditional field and boolean which is true if field was set.
func (*MessagesEditMessageRequest) GetMessage ¶
func (e *MessagesEditMessageRequest) GetMessage() (value string, ok bool)
GetMessage returns value of Message conditional field and boolean which is true if field was set.
func (*MessagesEditMessageRequest) GetReplyMarkup ¶
func (e *MessagesEditMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*MessagesEditMessageRequest) GetScheduleDate ¶
func (e *MessagesEditMessageRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesEditMessageRequest) SetEntities ¶
func (e *MessagesEditMessageRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesEditMessageRequest) SetMedia ¶
func (e *MessagesEditMessageRequest) SetMedia(value InputMediaClass)
SetMedia sets value of Media conditional field.
func (*MessagesEditMessageRequest) SetMessage ¶
func (e *MessagesEditMessageRequest) SetMessage(value string)
SetMessage sets value of Message conditional field.
func (*MessagesEditMessageRequest) SetNoWebpage ¶
func (e *MessagesEditMessageRequest) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*MessagesEditMessageRequest) SetReplyMarkup ¶
func (e *MessagesEditMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*MessagesEditMessageRequest) SetScheduleDate ¶
func (e *MessagesEditMessageRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesEditMessageRequest) String ¶ added in v0.12.0
func (e *MessagesEditMessageRequest) String() string
String implements fmt.Stringer.
type MessagesExportChatInviteRequest ¶
type MessagesExportChatInviteRequest struct {
// Chat
Peer InputPeerClass
}
MessagesExportChatInviteRequest represents TL type `messages.exportChatInvite#df7534c`. Export an invite link for a chat
See https://core.telegram.org/method/messages.exportChatInvite for reference.
func (*MessagesExportChatInviteRequest) Decode ¶
func (e *MessagesExportChatInviteRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesExportChatInviteRequest) Encode ¶
func (e *MessagesExportChatInviteRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesExportChatInviteRequest) String ¶ added in v0.12.0
func (e *MessagesExportChatInviteRequest) String() string
String implements fmt.Stringer.
type MessagesFaveStickerRequest ¶
type MessagesFaveStickerRequest struct {
// Sticker to mark as favorite
ID InputDocumentClass
// Unfavorite
Unfave bool
}
MessagesFaveStickerRequest represents TL type `messages.faveSticker#b9ffc55b`. Mark a sticker as favorite
See https://core.telegram.org/method/messages.faveSticker for reference.
func (*MessagesFaveStickerRequest) Decode ¶
func (f *MessagesFaveStickerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFaveStickerRequest) Encode ¶
func (f *MessagesFaveStickerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFaveStickerRequest) String ¶ added in v0.12.0
func (f *MessagesFaveStickerRequest) String() string
String implements fmt.Stringer.
type MessagesFavedStickers ¶
type MessagesFavedStickers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Emojis associated to stickers
Packs []StickerPack
// Favorited stickers
Stickers []DocumentClass
}
MessagesFavedStickers represents TL type `messages.favedStickers#f37f2f16`. Favorited stickers
See https://core.telegram.org/constructor/messages.favedStickers for reference.
func (*MessagesFavedStickers) Decode ¶
func (f *MessagesFavedStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFavedStickers) Encode ¶
func (f *MessagesFavedStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFavedStickers) String ¶ added in v0.12.0
func (f *MessagesFavedStickers) String() string
String implements fmt.Stringer.
type MessagesFavedStickersBox ¶
type MessagesFavedStickersBox struct {
FavedStickers MessagesFavedStickersClass
}
MessagesFavedStickers boxes the MessagesFavedStickersClass providing a helper.
type MessagesFavedStickersClass ¶
type MessagesFavedStickersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesFavedStickersClass represents messages.FavedStickers generic type.
See https://core.telegram.org/type/messages.FavedStickers for reference.
Example:
g, err := DecodeMessagesFavedStickers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesFavedStickersNotModified: // messages.favedStickersNotModified#9e8fa6d3
case *MessagesFavedStickers: // messages.favedStickers#f37f2f16
default: panic(v)
}
func DecodeMessagesFavedStickers ¶
func DecodeMessagesFavedStickers(buf *bin.Buffer) (MessagesFavedStickersClass, error)
DecodeMessagesFavedStickers implements binary de-serialization for MessagesFavedStickersClass.
type MessagesFavedStickersNotModified ¶
type MessagesFavedStickersNotModified struct {
}
MessagesFavedStickersNotModified represents TL type `messages.favedStickersNotModified#9e8fa6d3`. No new favorited stickers were found
See https://core.telegram.org/constructor/messages.favedStickersNotModified for reference.
func (*MessagesFavedStickersNotModified) Decode ¶
func (f *MessagesFavedStickersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFavedStickersNotModified) Encode ¶
func (f *MessagesFavedStickersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFavedStickersNotModified) String ¶ added in v0.12.0
func (f *MessagesFavedStickersNotModified) String() string
String implements fmt.Stringer.
type MessagesFeaturedStickers ¶
type MessagesFeaturedStickers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Total number of featured stickers
Count int
// Featured stickersets
Sets []StickerSetCoveredClass
// IDs of new featured stickersets
Unread []int64
}
MessagesFeaturedStickers represents TL type `messages.featuredStickers#b6abc341`. Featured stickersets
See https://core.telegram.org/constructor/messages.featuredStickers for reference.
func (*MessagesFeaturedStickers) Decode ¶
func (f *MessagesFeaturedStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFeaturedStickers) Encode ¶
func (f *MessagesFeaturedStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFeaturedStickers) String ¶ added in v0.12.0
func (f *MessagesFeaturedStickers) String() string
String implements fmt.Stringer.
type MessagesFeaturedStickersBox ¶
type MessagesFeaturedStickersBox struct {
FeaturedStickers MessagesFeaturedStickersClass
}
MessagesFeaturedStickers boxes the MessagesFeaturedStickersClass providing a helper.
type MessagesFeaturedStickersClass ¶
type MessagesFeaturedStickersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesFeaturedStickersClass represents messages.FeaturedStickers generic type.
See https://core.telegram.org/type/messages.FeaturedStickers for reference.
Example:
g, err := DecodeMessagesFeaturedStickers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesFeaturedStickersNotModified: // messages.featuredStickersNotModified#c6dc0c66
case *MessagesFeaturedStickers: // messages.featuredStickers#b6abc341
default: panic(v)
}
func DecodeMessagesFeaturedStickers ¶
func DecodeMessagesFeaturedStickers(buf *bin.Buffer) (MessagesFeaturedStickersClass, error)
DecodeMessagesFeaturedStickers implements binary de-serialization for MessagesFeaturedStickersClass.
type MessagesFeaturedStickersNotModified ¶
type MessagesFeaturedStickersNotModified struct {
// Total number of featured stickers
Count int
}
MessagesFeaturedStickersNotModified represents TL type `messages.featuredStickersNotModified#c6dc0c66`. Featured stickers haven't changed
See https://core.telegram.org/constructor/messages.featuredStickersNotModified for reference.
func (*MessagesFeaturedStickersNotModified) Decode ¶
func (f *MessagesFeaturedStickersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFeaturedStickersNotModified) Encode ¶
func (f *MessagesFeaturedStickersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFeaturedStickersNotModified) String ¶ added in v0.12.0
func (f *MessagesFeaturedStickersNotModified) String() string
String implements fmt.Stringer.
type MessagesFilterBox ¶
type MessagesFilterBox struct {
MessagesFilter MessagesFilterClass
}
MessagesFilter boxes the MessagesFilterClass providing a helper.
type MessagesFilterClass ¶
type MessagesFilterClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesFilterClass represents MessagesFilter generic type.
See https://core.telegram.org/type/MessagesFilter for reference.
Example:
g, err := DecodeMessagesFilter(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputMessagesFilterEmpty: // inputMessagesFilterEmpty#57e2f66c
case *InputMessagesFilterPhotos: // inputMessagesFilterPhotos#9609a51c
case *InputMessagesFilterVideo: // inputMessagesFilterVideo#9fc00e65
case *InputMessagesFilterPhotoVideo: // inputMessagesFilterPhotoVideo#56e9f0e4
case *InputMessagesFilterDocument: // inputMessagesFilterDocument#9eddf188
case *InputMessagesFilterUrl: // inputMessagesFilterUrl#7ef0dd87
case *InputMessagesFilterGif: // inputMessagesFilterGif#ffc86587
case *InputMessagesFilterVoice: // inputMessagesFilterVoice#50f5c392
case *InputMessagesFilterMusic: // inputMessagesFilterMusic#3751b49e
case *InputMessagesFilterChatPhotos: // inputMessagesFilterChatPhotos#3a20ecb8
case *InputMessagesFilterPhoneCalls: // inputMessagesFilterPhoneCalls#80c99768
case *InputMessagesFilterRoundVoice: // inputMessagesFilterRoundVoice#7a7c17a4
case *InputMessagesFilterRoundVideo: // inputMessagesFilterRoundVideo#b549da53
case *InputMessagesFilterMyMentions: // inputMessagesFilterMyMentions#c1f8e69a
case *InputMessagesFilterGeo: // inputMessagesFilterGeo#e7026d0d
case *InputMessagesFilterContacts: // inputMessagesFilterContacts#e062db83
case *InputMessagesFilterPinned: // inputMessagesFilterPinned#1bb00451
default: panic(v)
}
func DecodeMessagesFilter ¶
func DecodeMessagesFilter(buf *bin.Buffer) (MessagesFilterClass, error)
DecodeMessagesFilter implements binary de-serialization for MessagesFilterClass.
type MessagesForwardMessagesRequest ¶
type MessagesForwardMessagesRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to send messages silently (no notification will be triggered on the destination clients)
Silent bool
// Whether to send the message in background
Background bool
// When forwarding games, whether to include your score in the game
WithMyScore bool
// Source of messages
FromPeer InputPeerClass
// IDs of messages
ID []int
// Random ID to prevent resending of messages
RandomID []int64
// Destination peer
ToPeer InputPeerClass
// Scheduled message date for scheduled messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesForwardMessagesRequest represents TL type `messages.forwardMessages#d9fee60e`. Forwards messages by their IDs.
See https://core.telegram.org/method/messages.forwardMessages for reference.
func (*MessagesForwardMessagesRequest) Decode ¶
func (f *MessagesForwardMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesForwardMessagesRequest) Encode ¶
func (f *MessagesForwardMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesForwardMessagesRequest) GetScheduleDate ¶
func (f *MessagesForwardMessagesRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesForwardMessagesRequest) SetBackground ¶
func (f *MessagesForwardMessagesRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*MessagesForwardMessagesRequest) SetScheduleDate ¶
func (f *MessagesForwardMessagesRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesForwardMessagesRequest) SetSilent ¶
func (f *MessagesForwardMessagesRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesForwardMessagesRequest) SetWithMyScore ¶
func (f *MessagesForwardMessagesRequest) SetWithMyScore(value bool)
SetWithMyScore sets value of WithMyScore conditional field.
func (*MessagesForwardMessagesRequest) String ¶ added in v0.12.0
func (f *MessagesForwardMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesFoundStickerSets ¶
type MessagesFoundStickerSets struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Found stickersets
Sets []StickerSetCoveredClass
}
MessagesFoundStickerSets represents TL type `messages.foundStickerSets#5108d648`. Found stickersets
See https://core.telegram.org/constructor/messages.foundStickerSets for reference.
func (*MessagesFoundStickerSets) Decode ¶
func (f *MessagesFoundStickerSets) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFoundStickerSets) Encode ¶
func (f *MessagesFoundStickerSets) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFoundStickerSets) String ¶ added in v0.12.0
func (f *MessagesFoundStickerSets) String() string
String implements fmt.Stringer.
type MessagesFoundStickerSetsBox ¶
type MessagesFoundStickerSetsBox struct {
FoundStickerSets MessagesFoundStickerSetsClass
}
MessagesFoundStickerSets boxes the MessagesFoundStickerSetsClass providing a helper.
type MessagesFoundStickerSetsClass ¶
type MessagesFoundStickerSetsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesFoundStickerSetsClass represents messages.FoundStickerSets generic type.
See https://core.telegram.org/type/messages.FoundStickerSets for reference.
Example:
g, err := DecodeMessagesFoundStickerSets(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesFoundStickerSetsNotModified: // messages.foundStickerSetsNotModified#d54b65d
case *MessagesFoundStickerSets: // messages.foundStickerSets#5108d648
default: panic(v)
}
func DecodeMessagesFoundStickerSets ¶
func DecodeMessagesFoundStickerSets(buf *bin.Buffer) (MessagesFoundStickerSetsClass, error)
DecodeMessagesFoundStickerSets implements binary de-serialization for MessagesFoundStickerSetsClass.
type MessagesFoundStickerSetsNotModified ¶
type MessagesFoundStickerSetsNotModified struct {
}
MessagesFoundStickerSetsNotModified represents TL type `messages.foundStickerSetsNotModified#d54b65d`. No further results were found
See https://core.telegram.org/constructor/messages.foundStickerSetsNotModified for reference.
func (*MessagesFoundStickerSetsNotModified) Decode ¶
func (f *MessagesFoundStickerSetsNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesFoundStickerSetsNotModified) Encode ¶
func (f *MessagesFoundStickerSetsNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesFoundStickerSetsNotModified) String ¶ added in v0.12.0
func (f *MessagesFoundStickerSetsNotModified) String() string
String implements fmt.Stringer.
type MessagesGetAllChatsRequest ¶
type MessagesGetAllChatsRequest struct {
// Except these chats/channels/supergroups
ExceptIds []int
}
MessagesGetAllChatsRequest represents TL type `messages.getAllChats#eba80ff0`. Get all chats, channels and supergroups
See https://core.telegram.org/method/messages.getAllChats for reference.
func (*MessagesGetAllChatsRequest) Decode ¶
func (g *MessagesGetAllChatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetAllChatsRequest) Encode ¶
func (g *MessagesGetAllChatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetAllChatsRequest) String ¶ added in v0.12.0
func (g *MessagesGetAllChatsRequest) String() string
String implements fmt.Stringer.
type MessagesGetAllDraftsRequest ¶
type MessagesGetAllDraftsRequest struct {
}
MessagesGetAllDraftsRequest represents TL type `messages.getAllDrafts#6a3f8d65`. Save get all message drafts¹.
Links:
See https://core.telegram.org/method/messages.getAllDrafts for reference.
func (*MessagesGetAllDraftsRequest) Decode ¶
func (g *MessagesGetAllDraftsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetAllDraftsRequest) Encode ¶
func (g *MessagesGetAllDraftsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetAllDraftsRequest) String ¶ added in v0.12.0
func (g *MessagesGetAllDraftsRequest) String() string
String implements fmt.Stringer.
type MessagesGetAllStickersRequest ¶
type MessagesGetAllStickersRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetAllStickersRequest represents TL type `messages.getAllStickers#1c9618b1`. Get all installed stickers
See https://core.telegram.org/method/messages.getAllStickers for reference.
func (*MessagesGetAllStickersRequest) Decode ¶
func (g *MessagesGetAllStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetAllStickersRequest) Encode ¶
func (g *MessagesGetAllStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetAllStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetAllStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetArchivedStickersRequest ¶
type MessagesGetArchivedStickersRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Get mask stickers
Masks bool
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int64
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
}
MessagesGetArchivedStickersRequest represents TL type `messages.getArchivedStickers#57f17692`. Get all archived stickers
See https://core.telegram.org/method/messages.getArchivedStickers for reference.
func (*MessagesGetArchivedStickersRequest) Decode ¶
func (g *MessagesGetArchivedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetArchivedStickersRequest) Encode ¶
func (g *MessagesGetArchivedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetArchivedStickersRequest) SetMasks ¶
func (g *MessagesGetArchivedStickersRequest) SetMasks(value bool)
SetMasks sets value of Masks conditional field.
func (*MessagesGetArchivedStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetArchivedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetAttachedStickersRequest ¶
type MessagesGetAttachedStickersRequest struct {
// Stickered media
Media InputStickeredMediaClass
}
MessagesGetAttachedStickersRequest represents TL type `messages.getAttachedStickers#cc5b67cc`. Get stickers attached to a photo or video
See https://core.telegram.org/method/messages.getAttachedStickers for reference.
func (*MessagesGetAttachedStickersRequest) Decode ¶
func (g *MessagesGetAttachedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetAttachedStickersRequest) Encode ¶
func (g *MessagesGetAttachedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetAttachedStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetAttachedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetBotCallbackAnswerRequest ¶
type MessagesGetBotCallbackAnswerRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a "play game" button
Game bool
// Where was the inline keyboard sent
Peer InputPeerClass
// ID of the Message with the inline keyboard
MsgID int
// Callback data
//
// Use SetData and GetData helpers.
Data []byte
// For buttons requiring you to verify your identity with your 2FA password¹, the SRP payload generated using SRP².
//
// Links:
// 1) https://core.telegram.org/constructor/keyboardButtonCallback
// 2) https://core.telegram.org/api/srp
//
// Use SetPassword and GetPassword helpers.
Password InputCheckPasswordSRPClass
}
MessagesGetBotCallbackAnswerRequest represents TL type `messages.getBotCallbackAnswer#9342ca07`. Press an inline callback button and get a callback answer from the bot
See https://core.telegram.org/method/messages.getBotCallbackAnswer for reference.
func (*MessagesGetBotCallbackAnswerRequest) Decode ¶
func (g *MessagesGetBotCallbackAnswerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetBotCallbackAnswerRequest) Encode ¶
func (g *MessagesGetBotCallbackAnswerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetBotCallbackAnswerRequest) GetData ¶
func (g *MessagesGetBotCallbackAnswerRequest) GetData() (value []byte, ok bool)
GetData returns value of Data conditional field and boolean which is true if field was set.
func (*MessagesGetBotCallbackAnswerRequest) GetPassword ¶
func (g *MessagesGetBotCallbackAnswerRequest) GetPassword() (value InputCheckPasswordSRPClass, ok bool)
GetPassword returns value of Password conditional field and boolean which is true if field was set.
func (*MessagesGetBotCallbackAnswerRequest) SetData ¶
func (g *MessagesGetBotCallbackAnswerRequest) SetData(value []byte)
SetData sets value of Data conditional field.
func (*MessagesGetBotCallbackAnswerRequest) SetGame ¶
func (g *MessagesGetBotCallbackAnswerRequest) SetGame(value bool)
SetGame sets value of Game conditional field.
func (*MessagesGetBotCallbackAnswerRequest) SetPassword ¶
func (g *MessagesGetBotCallbackAnswerRequest) SetPassword(value InputCheckPasswordSRPClass)
SetPassword sets value of Password conditional field.
func (*MessagesGetBotCallbackAnswerRequest) String ¶ added in v0.12.0
func (g *MessagesGetBotCallbackAnswerRequest) String() string
String implements fmt.Stringer.
type MessagesGetChatsRequest ¶
type MessagesGetChatsRequest struct {
// List of chat IDs
ID []int
}
MessagesGetChatsRequest represents TL type `messages.getChats#3c6aa187`. Returns chat basic info on their IDs.
See https://core.telegram.org/method/messages.getChats for reference.
func (*MessagesGetChatsRequest) Decode ¶
func (g *MessagesGetChatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetChatsRequest) Encode ¶
func (g *MessagesGetChatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetChatsRequest) String ¶ added in v0.12.0
func (g *MessagesGetChatsRequest) String() string
String implements fmt.Stringer.
type MessagesGetCommonChatsRequest ¶
type MessagesGetCommonChatsRequest struct {
// User ID
UserID InputUserClass
// Maximum ID of chat to return (see pagination¹)
//
// Links:
// 1) https://core.telegram.org/api/offsets
MaxID int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
}
MessagesGetCommonChatsRequest represents TL type `messages.getCommonChats#d0a48c4`. Get chats in common with a user
See https://core.telegram.org/method/messages.getCommonChats for reference.
func (*MessagesGetCommonChatsRequest) Decode ¶
func (g *MessagesGetCommonChatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetCommonChatsRequest) Encode ¶
func (g *MessagesGetCommonChatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetCommonChatsRequest) String ¶ added in v0.12.0
func (g *MessagesGetCommonChatsRequest) String() string
String implements fmt.Stringer.
type MessagesGetDhConfigRequest ¶
type MessagesGetDhConfigRequest struct {
// Value of the version parameter from messages.dhConfig¹, avialable at the client
//
// Links:
// 1) https://core.telegram.org/constructor/messages.dhConfig
Version int
// Length of the required random sequence
RandomLength int
}
MessagesGetDhConfigRequest represents TL type `messages.getDhConfig#26cf8950`. Returns configuration parameters for Diffie-Hellman key generation. Can also return a random sequence of bytes of required length.
See https://core.telegram.org/method/messages.getDhConfig for reference.
func (*MessagesGetDhConfigRequest) Decode ¶
func (g *MessagesGetDhConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDhConfigRequest) Encode ¶
func (g *MessagesGetDhConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDhConfigRequest) String ¶ added in v0.12.0
func (g *MessagesGetDhConfigRequest) String() string
String implements fmt.Stringer.
type MessagesGetDialogFiltersRequest ¶
type MessagesGetDialogFiltersRequest struct {
}
MessagesGetDialogFiltersRequest represents TL type `messages.getDialogFilters#f19ed96d`. Get folders¹
Links:
See https://core.telegram.org/method/messages.getDialogFilters for reference.
func (*MessagesGetDialogFiltersRequest) Decode ¶
func (g *MessagesGetDialogFiltersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDialogFiltersRequest) Encode ¶
func (g *MessagesGetDialogFiltersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDialogFiltersRequest) String ¶ added in v0.12.0
func (g *MessagesGetDialogFiltersRequest) String() string
String implements fmt.Stringer.
type MessagesGetDialogUnreadMarksRequest ¶
type MessagesGetDialogUnreadMarksRequest struct {
}
MessagesGetDialogUnreadMarksRequest represents TL type `messages.getDialogUnreadMarks#22e24e22`. Get dialogs manually marked as unread
See https://core.telegram.org/method/messages.getDialogUnreadMarks for reference.
func (*MessagesGetDialogUnreadMarksRequest) Decode ¶
func (g *MessagesGetDialogUnreadMarksRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDialogUnreadMarksRequest) Encode ¶
func (g *MessagesGetDialogUnreadMarksRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDialogUnreadMarksRequest) String ¶ added in v0.12.0
func (g *MessagesGetDialogUnreadMarksRequest) String() string
String implements fmt.Stringer.
type MessagesGetDialogsRequest ¶
type MessagesGetDialogsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Exclude pinned dialogs
ExcludePinned bool
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetDate int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int
// Offset peer for pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetPeer InputPeerClass
// Number of list elements to be returned
Limit int
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetDialogsRequest represents TL type `messages.getDialogs#a0ee3b73`. Returns the current user dialog list.
See https://core.telegram.org/method/messages.getDialogs for reference.
func (*MessagesGetDialogsRequest) Decode ¶
func (g *MessagesGetDialogsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDialogsRequest) Encode ¶
func (g *MessagesGetDialogsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDialogsRequest) GetFolderID ¶
func (g *MessagesGetDialogsRequest) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*MessagesGetDialogsRequest) SetExcludePinned ¶
func (g *MessagesGetDialogsRequest) SetExcludePinned(value bool)
SetExcludePinned sets value of ExcludePinned conditional field.
func (*MessagesGetDialogsRequest) SetFolderID ¶
func (g *MessagesGetDialogsRequest) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*MessagesGetDialogsRequest) String ¶ added in v0.12.0
func (g *MessagesGetDialogsRequest) String() string
String implements fmt.Stringer.
type MessagesGetDiscussionMessageRequest ¶
type MessagesGetDiscussionMessageRequest struct {
// Channel ID¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Peer InputPeerClass
// Message ID
MsgID int
}
MessagesGetDiscussionMessageRequest represents TL type `messages.getDiscussionMessage#446972fd`. Get discussion message¹ from the associated discussion group² of a channel to show it on top of the comment section, without actually joining the group
Links:
See https://core.telegram.org/method/messages.getDiscussionMessage for reference.
func (*MessagesGetDiscussionMessageRequest) Decode ¶
func (g *MessagesGetDiscussionMessageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDiscussionMessageRequest) Encode ¶
func (g *MessagesGetDiscussionMessageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDiscussionMessageRequest) String ¶ added in v0.12.0
func (g *MessagesGetDiscussionMessageRequest) String() string
String implements fmt.Stringer.
type MessagesGetDocumentByHashRequest ¶
type MessagesGetDocumentByHashRequest struct {
// SHA256 of file
Sha256 []byte
// Size of the file in bytes
Size int
// Mime type
MimeType string
}
MessagesGetDocumentByHashRequest represents TL type `messages.getDocumentByHash#338e2464`. Get a document by its SHA256 hash, mainly used for gifs
See https://core.telegram.org/method/messages.getDocumentByHash for reference.
func (*MessagesGetDocumentByHashRequest) Decode ¶
func (g *MessagesGetDocumentByHashRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetDocumentByHashRequest) Encode ¶
func (g *MessagesGetDocumentByHashRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetDocumentByHashRequest) String ¶ added in v0.12.0
func (g *MessagesGetDocumentByHashRequest) String() string
String implements fmt.Stringer.
type MessagesGetEmojiKeywordsDifferenceRequest ¶
type MessagesGetEmojiKeywordsDifferenceRequest struct {
// Language code
LangCode string
// Previous emoji keyword localization version
FromVersion int
}
MessagesGetEmojiKeywordsDifferenceRequest represents TL type `messages.getEmojiKeywordsDifference#1508b6af`. Get changed emoji keywords
See https://core.telegram.org/method/messages.getEmojiKeywordsDifference for reference.
func (*MessagesGetEmojiKeywordsDifferenceRequest) Decode ¶
func (g *MessagesGetEmojiKeywordsDifferenceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetEmojiKeywordsDifferenceRequest) Encode ¶
func (g *MessagesGetEmojiKeywordsDifferenceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetEmojiKeywordsDifferenceRequest) String ¶ added in v0.12.0
func (g *MessagesGetEmojiKeywordsDifferenceRequest) String() string
String implements fmt.Stringer.
type MessagesGetEmojiKeywordsLanguagesRequest ¶
type MessagesGetEmojiKeywordsLanguagesRequest struct {
// Language codes
LangCodes []string
}
MessagesGetEmojiKeywordsLanguagesRequest represents TL type `messages.getEmojiKeywordsLanguages#4e9963b2`. Get info about an emoji keyword localization
See https://core.telegram.org/method/messages.getEmojiKeywordsLanguages for reference.
func (*MessagesGetEmojiKeywordsLanguagesRequest) Decode ¶
func (g *MessagesGetEmojiKeywordsLanguagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetEmojiKeywordsLanguagesRequest) Encode ¶
func (g *MessagesGetEmojiKeywordsLanguagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetEmojiKeywordsLanguagesRequest) String ¶ added in v0.12.0
func (g *MessagesGetEmojiKeywordsLanguagesRequest) String() string
String implements fmt.Stringer.
type MessagesGetEmojiKeywordsRequest ¶
type MessagesGetEmojiKeywordsRequest struct {
// Language code
LangCode string
}
MessagesGetEmojiKeywordsRequest represents TL type `messages.getEmojiKeywords#35a0e062`. Get localized emoji keywords
See https://core.telegram.org/method/messages.getEmojiKeywords for reference.
func (*MessagesGetEmojiKeywordsRequest) Decode ¶
func (g *MessagesGetEmojiKeywordsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetEmojiKeywordsRequest) Encode ¶
func (g *MessagesGetEmojiKeywordsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetEmojiKeywordsRequest) String ¶ added in v0.12.0
func (g *MessagesGetEmojiKeywordsRequest) String() string
String implements fmt.Stringer.
type MessagesGetEmojiURLRequest ¶
type MessagesGetEmojiURLRequest struct {
// Language code for which the emoji replacements will be suggested
LangCode string
}
MessagesGetEmojiURLRequest represents TL type `messages.getEmojiURL#d5b10c26`. Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation
See https://core.telegram.org/method/messages.getEmojiURL for reference.
func (*MessagesGetEmojiURLRequest) Decode ¶
func (g *MessagesGetEmojiURLRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetEmojiURLRequest) Encode ¶
func (g *MessagesGetEmojiURLRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetEmojiURLRequest) String ¶ added in v0.12.0
func (g *MessagesGetEmojiURLRequest) String() string
String implements fmt.Stringer.
type MessagesGetFavedStickersRequest ¶
type MessagesGetFavedStickersRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetFavedStickersRequest represents TL type `messages.getFavedStickers#21ce0b0e`. Get faved stickers
See https://core.telegram.org/method/messages.getFavedStickers for reference.
func (*MessagesGetFavedStickersRequest) Decode ¶
func (g *MessagesGetFavedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetFavedStickersRequest) Encode ¶
func (g *MessagesGetFavedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetFavedStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetFavedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetFeaturedStickersRequest ¶
type MessagesGetFeaturedStickersRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetFeaturedStickersRequest represents TL type `messages.getFeaturedStickers#2dacca4f`. Get featured stickers
See https://core.telegram.org/method/messages.getFeaturedStickers for reference.
func (*MessagesGetFeaturedStickersRequest) Decode ¶
func (g *MessagesGetFeaturedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetFeaturedStickersRequest) Encode ¶
func (g *MessagesGetFeaturedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetFeaturedStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetFeaturedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetFullChatRequest ¶
type MessagesGetFullChatRequest struct {
// Chat ID
ChatID int
}
MessagesGetFullChatRequest represents TL type `messages.getFullChat#3b831c66`. Returns full chat info according to its ID.
See https://core.telegram.org/method/messages.getFullChat for reference.
func (*MessagesGetFullChatRequest) Decode ¶
func (g *MessagesGetFullChatRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetFullChatRequest) Encode ¶
func (g *MessagesGetFullChatRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetFullChatRequest) String ¶ added in v0.12.0
func (g *MessagesGetFullChatRequest) String() string
String implements fmt.Stringer.
type MessagesGetGameHighScoresRequest ¶
type MessagesGetGameHighScoresRequest struct {
// Where was the game sent
Peer InputPeerClass
// ID of message with game media attachment
ID int
// Get high scores made by a certain user
UserID InputUserClass
}
MessagesGetGameHighScoresRequest represents TL type `messages.getGameHighScores#e822649d`. Get highscores of a game
See https://core.telegram.org/method/messages.getGameHighScores for reference.
func (*MessagesGetGameHighScoresRequest) Decode ¶
func (g *MessagesGetGameHighScoresRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetGameHighScoresRequest) Encode ¶
func (g *MessagesGetGameHighScoresRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetGameHighScoresRequest) String ¶ added in v0.12.0
func (g *MessagesGetGameHighScoresRequest) String() string
String implements fmt.Stringer.
type MessagesGetHistoryRequest ¶
type MessagesGetHistoryRequest struct {
// Target peer
Peer InputPeerClass
// Only return messages starting from the specified message ID
OffsetID int
// Only return messages sent before the specified date
OffsetDate int
// Number of list elements to be skipped, negative values are also accepted.
AddOffset int
// Number of results to return
Limit int
// If a positive value was transferred, the method will return only messages with IDs less than max_id
MaxID int
// If a positive value was transferred, the method will return only messages with IDs more than min_id
MinID int
// Result hash¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Hash int
}
MessagesGetHistoryRequest represents TL type `messages.getHistory#dcbb8260`. Gets back the conversation history with one interlocutor / within a chat
See https://core.telegram.org/method/messages.getHistory for reference.
func (*MessagesGetHistoryRequest) Decode ¶
func (g *MessagesGetHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetHistoryRequest) Encode ¶
func (g *MessagesGetHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetHistoryRequest) String ¶ added in v0.12.0
func (g *MessagesGetHistoryRequest) String() string
String implements fmt.Stringer.
type MessagesGetInlineBotResultsRequest ¶
type MessagesGetInlineBotResultsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The bot to query
Bot InputUserClass
// The currently opened chat
Peer InputPeerClass
// The geolocation, if requested
//
// Use SetGeoPoint and GetGeoPoint helpers.
GeoPoint InputGeoPointClass
// The query
Query string
// The offset within the results, will be passed directly as-is to the bot.
Offset string
}
MessagesGetInlineBotResultsRequest represents TL type `messages.getInlineBotResults#514e999d`. Query an inline bot
See https://core.telegram.org/method/messages.getInlineBotResults for reference.
func (*MessagesGetInlineBotResultsRequest) Decode ¶
func (g *MessagesGetInlineBotResultsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetInlineBotResultsRequest) Encode ¶
func (g *MessagesGetInlineBotResultsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetInlineBotResultsRequest) GetGeoPoint ¶
func (g *MessagesGetInlineBotResultsRequest) GetGeoPoint() (value InputGeoPointClass, ok bool)
GetGeoPoint returns value of GeoPoint conditional field and boolean which is true if field was set.
func (*MessagesGetInlineBotResultsRequest) SetGeoPoint ¶
func (g *MessagesGetInlineBotResultsRequest) SetGeoPoint(value InputGeoPointClass)
SetGeoPoint sets value of GeoPoint conditional field.
func (*MessagesGetInlineBotResultsRequest) String ¶ added in v0.12.0
func (g *MessagesGetInlineBotResultsRequest) String() string
String implements fmt.Stringer.
type MessagesGetInlineGameHighScoresRequest ¶
type MessagesGetInlineGameHighScoresRequest struct {
// ID of inline message
ID InputBotInlineMessageID
// Get high scores of a certain user
UserID InputUserClass
}
MessagesGetInlineGameHighScoresRequest represents TL type `messages.getInlineGameHighScores#f635e1b`. Get highscores of a game sent using an inline bot
See https://core.telegram.org/method/messages.getInlineGameHighScores for reference.
func (*MessagesGetInlineGameHighScoresRequest) Decode ¶
func (g *MessagesGetInlineGameHighScoresRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetInlineGameHighScoresRequest) Encode ¶
func (g *MessagesGetInlineGameHighScoresRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetInlineGameHighScoresRequest) String ¶ added in v0.12.0
func (g *MessagesGetInlineGameHighScoresRequest) String() string
String implements fmt.Stringer.
type MessagesGetMaskStickersRequest ¶
type MessagesGetMaskStickersRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetMaskStickersRequest represents TL type `messages.getMaskStickers#65b8c79f`. Get installed mask stickers
See https://core.telegram.org/method/messages.getMaskStickers for reference.
func (*MessagesGetMaskStickersRequest) Decode ¶
func (g *MessagesGetMaskStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetMaskStickersRequest) Encode ¶
func (g *MessagesGetMaskStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetMaskStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetMaskStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetMessageEditDataRequest ¶
type MessagesGetMessageEditDataRequest struct {
// Peer where the media was sent
Peer InputPeerClass
// ID of message
ID int
}
MessagesGetMessageEditDataRequest represents TL type `messages.getMessageEditData#fda68d36`. Find out if a media message's caption can be edited
See https://core.telegram.org/method/messages.getMessageEditData for reference.
func (*MessagesGetMessageEditDataRequest) Decode ¶
func (g *MessagesGetMessageEditDataRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetMessageEditDataRequest) Encode ¶
func (g *MessagesGetMessageEditDataRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetMessageEditDataRequest) String ¶ added in v0.12.0
func (g *MessagesGetMessageEditDataRequest) String() string
String implements fmt.Stringer.
type MessagesGetMessagesRequest ¶
type MessagesGetMessagesRequest struct {
// Message ID list
ID []InputMessageClass
}
MessagesGetMessagesRequest represents TL type `messages.getMessages#63c66506`. Returns the list of messages by their IDs.
See https://core.telegram.org/method/messages.getMessages for reference.
func (*MessagesGetMessagesRequest) Decode ¶
func (g *MessagesGetMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetMessagesRequest) Encode ¶
func (g *MessagesGetMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetMessagesRequest) String ¶ added in v0.12.0
func (g *MessagesGetMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesGetMessagesViewsRequest ¶
type MessagesGetMessagesViewsRequest struct {
// Peer where the message was found
Peer InputPeerClass
// ID of message
ID []int
// Whether to mark the message as viewed and increment the view counter
Increment bool
}
MessagesGetMessagesViewsRequest represents TL type `messages.getMessagesViews#5784d3e1`. Get and increase the view counter of a message sent or forwarded from a channel¹
Links:
See https://core.telegram.org/method/messages.getMessagesViews for reference.
func (*MessagesGetMessagesViewsRequest) Decode ¶
func (g *MessagesGetMessagesViewsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetMessagesViewsRequest) Encode ¶
func (g *MessagesGetMessagesViewsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetMessagesViewsRequest) String ¶ added in v0.12.0
func (g *MessagesGetMessagesViewsRequest) String() string
String implements fmt.Stringer.
type MessagesGetOldFeaturedStickersRequest ¶
type MessagesGetOldFeaturedStickersRequest struct {
// Offset
Offset int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetOldFeaturedStickersRequest represents TL type `messages.getOldFeaturedStickers#5fe7025b`. Method for fetching previously featured stickers
See https://core.telegram.org/method/messages.getOldFeaturedStickers for reference.
func (*MessagesGetOldFeaturedStickersRequest) Decode ¶
func (g *MessagesGetOldFeaturedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetOldFeaturedStickersRequest) Encode ¶
func (g *MessagesGetOldFeaturedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetOldFeaturedStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetOldFeaturedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetOnlinesRequest ¶
type MessagesGetOnlinesRequest struct {
// The chat
Peer InputPeerClass
}
MessagesGetOnlinesRequest represents TL type `messages.getOnlines#6e2be050`. Get count of online users in a chat
See https://core.telegram.org/method/messages.getOnlines for reference.
func (*MessagesGetOnlinesRequest) Decode ¶
func (g *MessagesGetOnlinesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetOnlinesRequest) Encode ¶
func (g *MessagesGetOnlinesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetOnlinesRequest) String ¶ added in v0.12.0
func (g *MessagesGetOnlinesRequest) String() string
String implements fmt.Stringer.
type MessagesGetPeerDialogsRequest ¶
type MessagesGetPeerDialogsRequest struct {
// Peers
Peers []InputDialogPeerClass
}
MessagesGetPeerDialogsRequest represents TL type `messages.getPeerDialogs#e470bcfd`. Get dialog info of specified peers
See https://core.telegram.org/method/messages.getPeerDialogs for reference.
func (*MessagesGetPeerDialogsRequest) Decode ¶
func (g *MessagesGetPeerDialogsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetPeerDialogsRequest) Encode ¶
func (g *MessagesGetPeerDialogsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetPeerDialogsRequest) String ¶ added in v0.12.0
func (g *MessagesGetPeerDialogsRequest) String() string
String implements fmt.Stringer.
type MessagesGetPeerSettingsRequest ¶
type MessagesGetPeerSettingsRequest struct {
// The peer
Peer InputPeerClass
}
MessagesGetPeerSettingsRequest represents TL type `messages.getPeerSettings#3672e09c`. Get peer settings
See https://core.telegram.org/method/messages.getPeerSettings for reference.
func (*MessagesGetPeerSettingsRequest) Decode ¶
func (g *MessagesGetPeerSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetPeerSettingsRequest) Encode ¶
func (g *MessagesGetPeerSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetPeerSettingsRequest) String ¶ added in v0.12.0
func (g *MessagesGetPeerSettingsRequest) String() string
String implements fmt.Stringer.
type MessagesGetPinnedDialogsRequest ¶
type MessagesGetPinnedDialogsRequest struct {
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
}
MessagesGetPinnedDialogsRequest represents TL type `messages.getPinnedDialogs#d6b94df2`. Get pinned dialogs
See https://core.telegram.org/method/messages.getPinnedDialogs for reference.
func (*MessagesGetPinnedDialogsRequest) Decode ¶
func (g *MessagesGetPinnedDialogsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetPinnedDialogsRequest) Encode ¶
func (g *MessagesGetPinnedDialogsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetPinnedDialogsRequest) String ¶ added in v0.12.0
func (g *MessagesGetPinnedDialogsRequest) String() string
String implements fmt.Stringer.
type MessagesGetPollResultsRequest ¶
type MessagesGetPollResultsRequest struct {
// Peer where the poll was found
Peer InputPeerClass
// Message ID of poll message
MsgID int
}
MessagesGetPollResultsRequest represents TL type `messages.getPollResults#73bb643b`. Get poll results
See https://core.telegram.org/method/messages.getPollResults for reference.
func (*MessagesGetPollResultsRequest) Decode ¶
func (g *MessagesGetPollResultsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetPollResultsRequest) Encode ¶
func (g *MessagesGetPollResultsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetPollResultsRequest) String ¶ added in v0.12.0
func (g *MessagesGetPollResultsRequest) String() string
String implements fmt.Stringer.
type MessagesGetPollVotesRequest ¶
type MessagesGetPollVotesRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Chat where the poll was sent
Peer InputPeerClass
// Message ID
ID int
// Get only results for the specified poll option
//
// Use SetOption and GetOption helpers.
Option []byte
// Offset for results, taken from the next_offset field of messages.votesList¹, initially an empty string. Note: if no more results are available, the method call will return an empty next_offset; thus, avoid providing the next_offset returned in messages.votesList² if it is empty, to avoid an infinite loop.
//
// Links:
// 1) https://core.telegram.org/constructor/messages.votesList
// 2) https://core.telegram.org/constructor/messages.votesList
//
// Use SetOffset and GetOffset helpers.
Offset string
// Number of results to return
Limit int
}
MessagesGetPollVotesRequest represents TL type `messages.getPollVotes#b86e380e`. Get poll results for non-anonymous polls
See https://core.telegram.org/method/messages.getPollVotes for reference.
func (*MessagesGetPollVotesRequest) Decode ¶
func (g *MessagesGetPollVotesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetPollVotesRequest) Encode ¶
func (g *MessagesGetPollVotesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetPollVotesRequest) GetOffset ¶
func (g *MessagesGetPollVotesRequest) GetOffset() (value string, ok bool)
GetOffset returns value of Offset conditional field and boolean which is true if field was set.
func (*MessagesGetPollVotesRequest) GetOption ¶
func (g *MessagesGetPollVotesRequest) GetOption() (value []byte, ok bool)
GetOption returns value of Option conditional field and boolean which is true if field was set.
func (*MessagesGetPollVotesRequest) SetOffset ¶
func (g *MessagesGetPollVotesRequest) SetOffset(value string)
SetOffset sets value of Offset conditional field.
func (*MessagesGetPollVotesRequest) SetOption ¶
func (g *MessagesGetPollVotesRequest) SetOption(value []byte)
SetOption sets value of Option conditional field.
func (*MessagesGetPollVotesRequest) String ¶ added in v0.12.0
func (g *MessagesGetPollVotesRequest) String() string
String implements fmt.Stringer.
type MessagesGetRecentLocationsRequest ¶
type MessagesGetRecentLocationsRequest struct {
// User
Peer InputPeerClass
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetRecentLocationsRequest represents TL type `messages.getRecentLocations#bbc45b09`. Get live location history of a certain user
See https://core.telegram.org/method/messages.getRecentLocations for reference.
func (*MessagesGetRecentLocationsRequest) Decode ¶
func (g *MessagesGetRecentLocationsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetRecentLocationsRequest) Encode ¶
func (g *MessagesGetRecentLocationsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetRecentLocationsRequest) String ¶ added in v0.12.0
func (g *MessagesGetRecentLocationsRequest) String() string
String implements fmt.Stringer.
type MessagesGetRecentStickersRequest ¶
type MessagesGetRecentStickersRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Get stickers recently attached to photo or video files
Attached bool
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetRecentStickersRequest represents TL type `messages.getRecentStickers#5ea192c9`. Get recent stickers
See https://core.telegram.org/method/messages.getRecentStickers for reference.
func (*MessagesGetRecentStickersRequest) Decode ¶
func (g *MessagesGetRecentStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetRecentStickersRequest) Encode ¶
func (g *MessagesGetRecentStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetRecentStickersRequest) SetAttached ¶
func (g *MessagesGetRecentStickersRequest) SetAttached(value bool)
SetAttached sets value of Attached conditional field.
func (*MessagesGetRecentStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetRecentStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetRepliesRequest ¶
type MessagesGetRepliesRequest struct {
// Peer
Peer InputPeerClass
// Message ID
MsgID int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetDate int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
AddOffset int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// If a positive value was transferred, the method will return only messages with ID smaller than max_id
MaxID int
// If a positive value was transferred, the method will return only messages with ID bigger than min_id
MinID int
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetRepliesRequest represents TL type `messages.getReplies#24b581ba`. Get messages in a reply thread
See https://core.telegram.org/method/messages.getReplies for reference.
func (*MessagesGetRepliesRequest) Decode ¶
func (g *MessagesGetRepliesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetRepliesRequest) Encode ¶
func (g *MessagesGetRepliesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetRepliesRequest) String ¶ added in v0.12.0
func (g *MessagesGetRepliesRequest) String() string
String implements fmt.Stringer.
type MessagesGetSavedGifsRequest ¶
type MessagesGetSavedGifsRequest struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetSavedGifsRequest represents TL type `messages.getSavedGifs#83bf3d52`. Get saved GIFs
See https://core.telegram.org/method/messages.getSavedGifs for reference.
func (*MessagesGetSavedGifsRequest) Decode ¶
func (g *MessagesGetSavedGifsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetSavedGifsRequest) Encode ¶
func (g *MessagesGetSavedGifsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetSavedGifsRequest) String ¶ added in v0.12.0
func (g *MessagesGetSavedGifsRequest) String() string
String implements fmt.Stringer.
type MessagesGetScheduledHistoryRequest ¶
type MessagesGetScheduledHistoryRequest struct {
// Peer
Peer InputPeerClass
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetScheduledHistoryRequest represents TL type `messages.getScheduledHistory#e2c2685b`. Get scheduled messages
See https://core.telegram.org/method/messages.getScheduledHistory for reference.
func (*MessagesGetScheduledHistoryRequest) Decode ¶
func (g *MessagesGetScheduledHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetScheduledHistoryRequest) Encode ¶
func (g *MessagesGetScheduledHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetScheduledHistoryRequest) String ¶ added in v0.12.0
func (g *MessagesGetScheduledHistoryRequest) String() string
String implements fmt.Stringer.
type MessagesGetScheduledMessagesRequest ¶
type MessagesGetScheduledMessagesRequest struct {
// Peer
Peer InputPeerClass
// IDs of scheduled messages
ID []int
}
MessagesGetScheduledMessagesRequest represents TL type `messages.getScheduledMessages#bdbb0464`. Get scheduled messages
See https://core.telegram.org/method/messages.getScheduledMessages for reference.
func (*MessagesGetScheduledMessagesRequest) Decode ¶
func (g *MessagesGetScheduledMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetScheduledMessagesRequest) Encode ¶
func (g *MessagesGetScheduledMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetScheduledMessagesRequest) String ¶ added in v0.12.0
func (g *MessagesGetScheduledMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesGetSearchCountersRequest ¶
type MessagesGetSearchCountersRequest struct {
// Peer where to search
Peer InputPeerClass
// Search filters
Filters []MessagesFilterClass
}
MessagesGetSearchCountersRequest represents TL type `messages.getSearchCounters#732eef00`. Get the number of results that would be found by a messages.search¹ call with the same parameters
Links:
See https://core.telegram.org/method/messages.getSearchCounters for reference.
func (*MessagesGetSearchCountersRequest) Decode ¶
func (g *MessagesGetSearchCountersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetSearchCountersRequest) Encode ¶
func (g *MessagesGetSearchCountersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetSearchCountersRequest) String ¶ added in v0.12.0
func (g *MessagesGetSearchCountersRequest) String() string
String implements fmt.Stringer.
type MessagesGetSplitRangesRequest ¶
type MessagesGetSplitRangesRequest struct {
}
MessagesGetSplitRangesRequest represents TL type `messages.getSplitRanges#1cff7e08`. Get message ranges for saving the user's chat history
See https://core.telegram.org/method/messages.getSplitRanges for reference.
func (*MessagesGetSplitRangesRequest) Decode ¶
func (g *MessagesGetSplitRangesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetSplitRangesRequest) Encode ¶
func (g *MessagesGetSplitRangesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetSplitRangesRequest) String ¶ added in v0.12.0
func (g *MessagesGetSplitRangesRequest) String() string
String implements fmt.Stringer.
type MessagesGetStatsURLRequest ¶
type MessagesGetStatsURLRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Pass true if a URL with the dark theme must be returned
Dark bool
// Chat identifier
Peer InputPeerClass
// Parameters from tg://statsrefresh?params=****** link
Params string
}
MessagesGetStatsURLRequest represents TL type `messages.getStatsURL#812c2ae6`. Returns URL with the chat statistics. Currently this method can be used only for channels
See https://core.telegram.org/method/messages.getStatsURL for reference.
func (*MessagesGetStatsURLRequest) Decode ¶
func (g *MessagesGetStatsURLRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetStatsURLRequest) Encode ¶
func (g *MessagesGetStatsURLRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetStatsURLRequest) SetDark ¶
func (g *MessagesGetStatsURLRequest) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*MessagesGetStatsURLRequest) String ¶ added in v0.12.0
func (g *MessagesGetStatsURLRequest) String() string
String implements fmt.Stringer.
type MessagesGetStickerSetRequest ¶
type MessagesGetStickerSetRequest struct {
// Stickerset
Stickerset InputStickerSetClass
}
MessagesGetStickerSetRequest represents TL type `messages.getStickerSet#2619a90e`. Get info about a stickerset
See https://core.telegram.org/method/messages.getStickerSet for reference.
func (*MessagesGetStickerSetRequest) Decode ¶
func (g *MessagesGetStickerSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetStickerSetRequest) Encode ¶
func (g *MessagesGetStickerSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetStickerSetRequest) String ¶ added in v0.12.0
func (g *MessagesGetStickerSetRequest) String() string
String implements fmt.Stringer.
type MessagesGetStickersRequest ¶
type MessagesGetStickersRequest struct {
// The emoji
Emoticon string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetStickersRequest represents TL type `messages.getStickers#43d4f2c`. Get stickers by emoji
See https://core.telegram.org/method/messages.getStickers for reference.
func (*MessagesGetStickersRequest) Decode ¶
func (g *MessagesGetStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetStickersRequest) Encode ¶
func (g *MessagesGetStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetStickersRequest) String ¶ added in v0.12.0
func (g *MessagesGetStickersRequest) String() string
String implements fmt.Stringer.
type MessagesGetSuggestedDialogFiltersRequest ¶
type MessagesGetSuggestedDialogFiltersRequest struct {
}
MessagesGetSuggestedDialogFiltersRequest represents TL type `messages.getSuggestedDialogFilters#a29cd42c`. Get suggested folders¹
Links:
See https://core.telegram.org/method/messages.getSuggestedDialogFilters for reference.
func (*MessagesGetSuggestedDialogFiltersRequest) Decode ¶
func (g *MessagesGetSuggestedDialogFiltersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetSuggestedDialogFiltersRequest) Encode ¶
func (g *MessagesGetSuggestedDialogFiltersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetSuggestedDialogFiltersRequest) String ¶ added in v0.12.0
func (g *MessagesGetSuggestedDialogFiltersRequest) String() string
String implements fmt.Stringer.
type MessagesGetUnreadMentionsRequest ¶
type MessagesGetUnreadMentionsRequest struct {
// Peer where to look for mentions
Peer InputPeerClass
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
AddOffset int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Maximum message ID to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
MaxID int
// Minimum message ID to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
MinID int
}
MessagesGetUnreadMentionsRequest represents TL type `messages.getUnreadMentions#46578472`. Get unread messages where we were mentioned
See https://core.telegram.org/method/messages.getUnreadMentions for reference.
func (*MessagesGetUnreadMentionsRequest) Decode ¶
func (g *MessagesGetUnreadMentionsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetUnreadMentionsRequest) Encode ¶
func (g *MessagesGetUnreadMentionsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetUnreadMentionsRequest) String ¶ added in v0.12.0
func (g *MessagesGetUnreadMentionsRequest) String() string
String implements fmt.Stringer.
type MessagesGetWebPagePreviewRequest ¶
type MessagesGetWebPagePreviewRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Message from which to extract the preview
Message string
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
MessagesGetWebPagePreviewRequest represents TL type `messages.getWebPagePreview#8b68b0cc`. Get preview of webpage
See https://core.telegram.org/method/messages.getWebPagePreview for reference.
func (*MessagesGetWebPagePreviewRequest) Decode ¶
func (g *MessagesGetWebPagePreviewRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetWebPagePreviewRequest) Encode ¶
func (g *MessagesGetWebPagePreviewRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetWebPagePreviewRequest) GetEntities ¶
func (g *MessagesGetWebPagePreviewRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesGetWebPagePreviewRequest) SetEntities ¶
func (g *MessagesGetWebPagePreviewRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesGetWebPagePreviewRequest) String ¶ added in v0.12.0
func (g *MessagesGetWebPagePreviewRequest) String() string
String implements fmt.Stringer.
type MessagesGetWebPageRequest ¶
type MessagesGetWebPageRequest struct {
// URL of IV page to fetch
URL string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesGetWebPageRequest represents TL type `messages.getWebPage#32ca8f91`. Get instant view¹ page
Links:
See https://core.telegram.org/method/messages.getWebPage for reference.
func (*MessagesGetWebPageRequest) Decode ¶
func (g *MessagesGetWebPageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesGetWebPageRequest) Encode ¶
func (g *MessagesGetWebPageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesGetWebPageRequest) String ¶ added in v0.12.0
func (g *MessagesGetWebPageRequest) String() string
String implements fmt.Stringer.
type MessagesHidePeerSettingsBarRequest ¶
type MessagesHidePeerSettingsBarRequest struct {
// Peer
Peer InputPeerClass
}
MessagesHidePeerSettingsBarRequest represents TL type `messages.hidePeerSettingsBar#4facb138`. Should be called after the user hides the report spam/add as contact bar of a new chat, effectively prevents the user from executing the actions specified in the peer's settings¹.
Links:
See https://core.telegram.org/method/messages.hidePeerSettingsBar for reference.
func (*MessagesHidePeerSettingsBarRequest) Decode ¶
func (h *MessagesHidePeerSettingsBarRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesHidePeerSettingsBarRequest) Encode ¶
func (h *MessagesHidePeerSettingsBarRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesHidePeerSettingsBarRequest) String ¶ added in v0.12.0
func (h *MessagesHidePeerSettingsBarRequest) String() string
String implements fmt.Stringer.
type MessagesHighScores ¶
type MessagesHighScores struct {
// Highscores
Scores []HighScore
// Users, associated to the highscores
Users []UserClass
}
MessagesHighScores represents TL type `messages.highScores#9a3bfd99`. Highscores in a game
See https://core.telegram.org/constructor/messages.highScores for reference.
func (*MessagesHighScores) Decode ¶
func (h *MessagesHighScores) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesHighScores) Encode ¶
func (h *MessagesHighScores) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesHighScores) String ¶ added in v0.12.0
func (h *MessagesHighScores) String() string
String implements fmt.Stringer.
type MessagesImportChatInviteRequest ¶
type MessagesImportChatInviteRequest struct {
// hash from t.me/joinchat/hash
Hash string
}
MessagesImportChatInviteRequest represents TL type `messages.importChatInvite#6c50051c`. Import a chat invite and join a private chat/supergroup/channel
See https://core.telegram.org/method/messages.importChatInvite for reference.
func (*MessagesImportChatInviteRequest) Decode ¶
func (i *MessagesImportChatInviteRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesImportChatInviteRequest) Encode ¶
func (i *MessagesImportChatInviteRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesImportChatInviteRequest) String ¶ added in v0.12.0
func (i *MessagesImportChatInviteRequest) String() string
String implements fmt.Stringer.
type MessagesInactiveChats ¶
type MessagesInactiveChats struct {
// When was the chat last active
Dates []int
// Chat list
Chats []ChatClass
// Users mentioned in the chat list
Users []UserClass
}
MessagesInactiveChats represents TL type `messages.inactiveChats#a927fec5`. Inactive chat list
See https://core.telegram.org/constructor/messages.inactiveChats for reference.
func (*MessagesInactiveChats) Decode ¶
func (i *MessagesInactiveChats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesInactiveChats) Encode ¶
func (i *MessagesInactiveChats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesInactiveChats) String ¶ added in v0.12.0
func (i *MessagesInactiveChats) String() string
String implements fmt.Stringer.
type MessagesInstallStickerSetRequest ¶
type MessagesInstallStickerSetRequest struct {
// Stickerset to install
Stickerset InputStickerSetClass
// Whether to archive stickerset
Archived bool
}
MessagesInstallStickerSetRequest represents TL type `messages.installStickerSet#c78fe460`. Install a stickerset
See https://core.telegram.org/method/messages.installStickerSet for reference.
func (*MessagesInstallStickerSetRequest) Decode ¶
func (i *MessagesInstallStickerSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesInstallStickerSetRequest) Encode ¶
func (i *MessagesInstallStickerSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesInstallStickerSetRequest) String ¶ added in v0.12.0
func (i *MessagesInstallStickerSetRequest) String() string
String implements fmt.Stringer.
type MessagesMarkDialogUnreadRequest ¶
type MessagesMarkDialogUnreadRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Mark as unread/read
Unread bool
// Dialog
Peer InputDialogPeerClass
}
MessagesMarkDialogUnreadRequest represents TL type `messages.markDialogUnread#c286d98f`. Manually mark dialog as unread
See https://core.telegram.org/method/messages.markDialogUnread for reference.
func (*MessagesMarkDialogUnreadRequest) Decode ¶
func (m *MessagesMarkDialogUnreadRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMarkDialogUnreadRequest) Encode ¶
func (m *MessagesMarkDialogUnreadRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMarkDialogUnreadRequest) SetUnread ¶
func (m *MessagesMarkDialogUnreadRequest) SetUnread(value bool)
SetUnread sets value of Unread conditional field.
func (*MessagesMarkDialogUnreadRequest) String ¶ added in v0.12.0
func (m *MessagesMarkDialogUnreadRequest) String() string
String implements fmt.Stringer.
type MessagesMessageEditData ¶
type MessagesMessageEditData struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Media caption, if the specified media's caption can be edited
Caption bool
}
MessagesMessageEditData represents TL type `messages.messageEditData#26b5dde6`. Message edit data for media
See https://core.telegram.org/constructor/messages.messageEditData for reference.
func (*MessagesMessageEditData) Decode ¶
func (m *MessagesMessageEditData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMessageEditData) Encode ¶
func (m *MessagesMessageEditData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMessageEditData) SetCaption ¶
func (m *MessagesMessageEditData) SetCaption(value bool)
SetCaption sets value of Caption conditional field.
func (*MessagesMessageEditData) String ¶ added in v0.12.0
func (m *MessagesMessageEditData) String() string
String implements fmt.Stringer.
type MessagesMessageViews ¶
type MessagesMessageViews struct {
// View, forward counter + info about replies
Views []MessageViews
// Chats mentioned in constructor
Chats []ChatClass
// Users mentioned in constructor
Users []UserClass
}
MessagesMessageViews represents TL type `messages.messageViews#b6c4f543`. View, forward counter + info about replies
See https://core.telegram.org/constructor/messages.messageViews for reference.
func (*MessagesMessageViews) Decode ¶
func (m *MessagesMessageViews) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMessageViews) Encode ¶
func (m *MessagesMessageViews) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMessageViews) String ¶ added in v0.12.0
func (m *MessagesMessageViews) String() string
String implements fmt.Stringer.
type MessagesMessages ¶
type MessagesMessages struct {
// List of messages
Messages []MessageClass
// List of chats mentioned in dialogs
Chats []ChatClass
// List of users mentioned in messages and chats
Users []UserClass
}
MessagesMessages represents TL type `messages.messages#8c718e87`. Full list of messages with auxilary data.
See https://core.telegram.org/constructor/messages.messages for reference.
func (*MessagesMessages) Decode ¶
func (m *MessagesMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMessages) Encode ¶
func (m *MessagesMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMessages) String ¶ added in v0.12.0
func (m *MessagesMessages) String() string
String implements fmt.Stringer.
type MessagesMessagesBox ¶
type MessagesMessagesBox struct {
Messages MessagesMessagesClass
}
MessagesMessages boxes the MessagesMessagesClass providing a helper.
type MessagesMessagesClass ¶
type MessagesMessagesClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesMessagesClass represents messages.Messages generic type.
See https://core.telegram.org/type/messages.Messages for reference.
Example:
g, err := DecodeMessagesMessages(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesMessages: // messages.messages#8c718e87
case *MessagesMessagesSlice: // messages.messagesSlice#3a54685e
case *MessagesChannelMessages: // messages.channelMessages#64479808
case *MessagesMessagesNotModified: // messages.messagesNotModified#74535f21
default: panic(v)
}
func DecodeMessagesMessages ¶
func DecodeMessagesMessages(buf *bin.Buffer) (MessagesMessagesClass, error)
DecodeMessagesMessages implements binary de-serialization for MessagesMessagesClass.
type MessagesMessagesNotModified ¶
type MessagesMessagesNotModified struct {
// Number of results found server-side by the given query
Count int
}
MessagesMessagesNotModified represents TL type `messages.messagesNotModified#74535f21`. No new messages matching the query were found
See https://core.telegram.org/constructor/messages.messagesNotModified for reference.
func (*MessagesMessagesNotModified) Decode ¶
func (m *MessagesMessagesNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMessagesNotModified) Encode ¶
func (m *MessagesMessagesNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMessagesNotModified) String ¶ added in v0.12.0
func (m *MessagesMessagesNotModified) String() string
String implements fmt.Stringer.
type MessagesMessagesSlice ¶
type MessagesMessagesSlice struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, indicates that the results may be inexact
Inexact bool
// Total number of messages in the list
Count int
// Rate to use in the offset_rate parameter in the next call to messages.searchGlobal¹
//
// Links:
// 1) https://core.telegram.org/method/messages.searchGlobal
//
// Use SetNextRate and GetNextRate helpers.
NextRate int
// Indicates the absolute position of messages[0] within the total result set with count count. This is useful, for example, if the result was fetched using offset_id, and we need to display a progress/total counter (like photo 134 of 200, for all media in a chat, we could simply use photo ${offset_id_offset} of ${count}.
//
// Use SetOffsetIDOffset and GetOffsetIDOffset helpers.
OffsetIDOffset int
// List of messages
Messages []MessageClass
// List of chats mentioned in messages
Chats []ChatClass
// List of users mentioned in messages and chats
Users []UserClass
}
MessagesMessagesSlice represents TL type `messages.messagesSlice#3a54685e`. Incomplete list of messages and auxiliary data.
See https://core.telegram.org/constructor/messages.messagesSlice for reference.
func (*MessagesMessagesSlice) Decode ¶
func (m *MessagesMessagesSlice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMessagesSlice) Encode ¶
func (m *MessagesMessagesSlice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMessagesSlice) GetNextRate ¶
func (m *MessagesMessagesSlice) GetNextRate() (value int, ok bool)
GetNextRate returns value of NextRate conditional field and boolean which is true if field was set.
func (*MessagesMessagesSlice) GetOffsetIDOffset ¶
func (m *MessagesMessagesSlice) GetOffsetIDOffset() (value int, ok bool)
GetOffsetIDOffset returns value of OffsetIDOffset conditional field and boolean which is true if field was set.
func (*MessagesMessagesSlice) SetInexact ¶
func (m *MessagesMessagesSlice) SetInexact(value bool)
SetInexact sets value of Inexact conditional field.
func (*MessagesMessagesSlice) SetNextRate ¶
func (m *MessagesMessagesSlice) SetNextRate(value int)
SetNextRate sets value of NextRate conditional field.
func (*MessagesMessagesSlice) SetOffsetIDOffset ¶
func (m *MessagesMessagesSlice) SetOffsetIDOffset(value int)
SetOffsetIDOffset sets value of OffsetIDOffset conditional field.
func (*MessagesMessagesSlice) String ¶ added in v0.12.0
func (m *MessagesMessagesSlice) String() string
String implements fmt.Stringer.
type MessagesMigrateChatRequest ¶
type MessagesMigrateChatRequest struct {
// Legacy group to migrate
ChatID int
}
MessagesMigrateChatRequest represents TL type `messages.migrateChat#15a3b8e3`. Turn a legacy group into a supergroup¹
Links:
See https://core.telegram.org/method/messages.migrateChat for reference.
func (*MessagesMigrateChatRequest) Decode ¶
func (m *MessagesMigrateChatRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesMigrateChatRequest) Encode ¶
func (m *MessagesMigrateChatRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesMigrateChatRequest) String ¶ added in v0.12.0
func (m *MessagesMigrateChatRequest) String() string
String implements fmt.Stringer.
type MessagesPeerDialogs ¶
type MessagesPeerDialogs struct {
// Dialog info
Dialogs []DialogClass
// Messages mentioned in dialog info
Messages []MessageClass
// Chats
Chats []ChatClass
// Users
Users []UserClass
// Current update state of dialog¹
//
// Links:
// 1) https://core.telegram.org/api/updates
State UpdatesState
}
MessagesPeerDialogs represents TL type `messages.peerDialogs#3371c354`. Dialog info of multiple peers
See https://core.telegram.org/constructor/messages.peerDialogs for reference.
func (*MessagesPeerDialogs) Decode ¶
func (p *MessagesPeerDialogs) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesPeerDialogs) Encode ¶
func (p *MessagesPeerDialogs) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesPeerDialogs) String ¶ added in v0.12.0
func (p *MessagesPeerDialogs) String() string
String implements fmt.Stringer.
type MessagesReadDiscussionRequest ¶
type MessagesReadDiscussionRequest struct {
// Group ID
Peer InputPeerClass
// ID of message that started the thread
MsgID int
// ID up to which thread messages were read
ReadMaxID int
}
MessagesReadDiscussionRequest represents TL type `messages.readDiscussion#f731a9f4`. Mark a thread¹ as read
Links:
See https://core.telegram.org/method/messages.readDiscussion for reference.
func (*MessagesReadDiscussionRequest) Decode ¶
func (r *MessagesReadDiscussionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadDiscussionRequest) Encode ¶
func (r *MessagesReadDiscussionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadDiscussionRequest) String ¶ added in v0.12.0
func (r *MessagesReadDiscussionRequest) String() string
String implements fmt.Stringer.
type MessagesReadEncryptedHistoryRequest ¶
type MessagesReadEncryptedHistoryRequest struct {
// Secret chat ID
Peer InputEncryptedChat
// Maximum date value for received messages in history
MaxDate int
}
MessagesReadEncryptedHistoryRequest represents TL type `messages.readEncryptedHistory#7f4b690a`. Marks message history within a secret chat as read.
See https://core.telegram.org/method/messages.readEncryptedHistory for reference.
func (*MessagesReadEncryptedHistoryRequest) Decode ¶
func (r *MessagesReadEncryptedHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadEncryptedHistoryRequest) Encode ¶
func (r *MessagesReadEncryptedHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadEncryptedHistoryRequest) String ¶ added in v0.12.0
func (r *MessagesReadEncryptedHistoryRequest) String() string
String implements fmt.Stringer.
type MessagesReadFeaturedStickersRequest ¶
type MessagesReadFeaturedStickersRequest struct {
// IDs of stickersets to mark as read
ID []int64
}
MessagesReadFeaturedStickersRequest represents TL type `messages.readFeaturedStickers#5b118126`. Mark new featured stickers as read
See https://core.telegram.org/method/messages.readFeaturedStickers for reference.
func (*MessagesReadFeaturedStickersRequest) Decode ¶
func (r *MessagesReadFeaturedStickersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadFeaturedStickersRequest) Encode ¶
func (r *MessagesReadFeaturedStickersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadFeaturedStickersRequest) String ¶ added in v0.12.0
func (r *MessagesReadFeaturedStickersRequest) String() string
String implements fmt.Stringer.
type MessagesReadHistoryRequest ¶
type MessagesReadHistoryRequest struct {
// Target user or group
Peer InputPeerClass
// If a positive value is passed, only messages with identifiers less or equal than the given one will be read
MaxID int
}
MessagesReadHistoryRequest represents TL type `messages.readHistory#e306d3a`. Marks message history as read.
See https://core.telegram.org/method/messages.readHistory for reference.
func (*MessagesReadHistoryRequest) Decode ¶
func (r *MessagesReadHistoryRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadHistoryRequest) Encode ¶
func (r *MessagesReadHistoryRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadHistoryRequest) String ¶ added in v0.12.0
func (r *MessagesReadHistoryRequest) String() string
String implements fmt.Stringer.
type MessagesReadMentionsRequest ¶
type MessagesReadMentionsRequest struct {
// Dialog
Peer InputPeerClass
}
MessagesReadMentionsRequest represents TL type `messages.readMentions#f0189d3`. Mark mentions as read
See https://core.telegram.org/method/messages.readMentions for reference.
func (*MessagesReadMentionsRequest) Decode ¶
func (r *MessagesReadMentionsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadMentionsRequest) Encode ¶
func (r *MessagesReadMentionsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadMentionsRequest) String ¶ added in v0.12.0
func (r *MessagesReadMentionsRequest) String() string
String implements fmt.Stringer.
type MessagesReadMessageContentsRequest ¶
type MessagesReadMessageContentsRequest struct {
// Message ID list
ID []int
}
MessagesReadMessageContentsRequest represents TL type `messages.readMessageContents#36a73f77`. Notifies the sender about the recipient having listened a voice message or watched a video.
See https://core.telegram.org/method/messages.readMessageContents for reference.
func (*MessagesReadMessageContentsRequest) Decode ¶
func (r *MessagesReadMessageContentsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReadMessageContentsRequest) Encode ¶
func (r *MessagesReadMessageContentsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReadMessageContentsRequest) String ¶ added in v0.12.0
func (r *MessagesReadMessageContentsRequest) String() string
String implements fmt.Stringer.
type MessagesReceivedMessagesRequest ¶
type MessagesReceivedMessagesRequest struct {
// Maximum message ID available in a client.
MaxID int
}
MessagesReceivedMessagesRequest represents TL type `messages.receivedMessages#5a954c0`. Confirms receipt of messages by a client, cancels PUSH-notification sending.
See https://core.telegram.org/method/messages.receivedMessages for reference.
func (*MessagesReceivedMessagesRequest) Decode ¶
func (r *MessagesReceivedMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReceivedMessagesRequest) Encode ¶
func (r *MessagesReceivedMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReceivedMessagesRequest) String ¶ added in v0.12.0
func (r *MessagesReceivedMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesReceivedQueueRequest ¶
type MessagesReceivedQueueRequest struct {
// Maximum qts value available at the client
MaxQts int
}
MessagesReceivedQueueRequest represents TL type `messages.receivedQueue#55a5bb66`. Confirms receipt of messages in a secret chat by client, cancels push notifications.
See https://core.telegram.org/method/messages.receivedQueue for reference.
func (*MessagesReceivedQueueRequest) Decode ¶
func (r *MessagesReceivedQueueRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReceivedQueueRequest) Encode ¶
func (r *MessagesReceivedQueueRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReceivedQueueRequest) String ¶ added in v0.12.0
func (r *MessagesReceivedQueueRequest) String() string
String implements fmt.Stringer.
type MessagesRecentStickers ¶
type MessagesRecentStickers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Emojis associated to stickers
Packs []StickerPack
// Recent stickers
Stickers []DocumentClass
// When was each sticker last used
Dates []int
}
MessagesRecentStickers represents TL type `messages.recentStickers#22f3afb3`. Recently used stickers
See https://core.telegram.org/constructor/messages.recentStickers for reference.
func (*MessagesRecentStickers) Decode ¶
func (r *MessagesRecentStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesRecentStickers) Encode ¶
func (r *MessagesRecentStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesRecentStickers) String ¶ added in v0.12.0
func (r *MessagesRecentStickers) String() string
String implements fmt.Stringer.
type MessagesRecentStickersBox ¶
type MessagesRecentStickersBox struct {
RecentStickers MessagesRecentStickersClass
}
MessagesRecentStickers boxes the MessagesRecentStickersClass providing a helper.
type MessagesRecentStickersClass ¶
type MessagesRecentStickersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesRecentStickersClass represents messages.RecentStickers generic type.
See https://core.telegram.org/type/messages.RecentStickers for reference.
Example:
g, err := DecodeMessagesRecentStickers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesRecentStickersNotModified: // messages.recentStickersNotModified#b17f890
case *MessagesRecentStickers: // messages.recentStickers#22f3afb3
default: panic(v)
}
func DecodeMessagesRecentStickers ¶
func DecodeMessagesRecentStickers(buf *bin.Buffer) (MessagesRecentStickersClass, error)
DecodeMessagesRecentStickers implements binary de-serialization for MessagesRecentStickersClass.
type MessagesRecentStickersNotModified ¶
type MessagesRecentStickersNotModified struct {
}
MessagesRecentStickersNotModified represents TL type `messages.recentStickersNotModified#b17f890`. No new recent sticker was found
See https://core.telegram.org/constructor/messages.recentStickersNotModified for reference.
func (*MessagesRecentStickersNotModified) Decode ¶
func (r *MessagesRecentStickersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesRecentStickersNotModified) Encode ¶
func (r *MessagesRecentStickersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesRecentStickersNotModified) String ¶ added in v0.12.0
func (r *MessagesRecentStickersNotModified) String() string
String implements fmt.Stringer.
type MessagesReorderPinnedDialogsRequest ¶
type MessagesReorderPinnedDialogsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, dialogs pinned server-side but not present in the order field will be unpinned.
Force bool
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
FolderID int
// New dialog order
Order []InputDialogPeerClass
}
MessagesReorderPinnedDialogsRequest represents TL type `messages.reorderPinnedDialogs#3b1adf37`. Reorder pinned dialogs
See https://core.telegram.org/method/messages.reorderPinnedDialogs for reference.
func (*MessagesReorderPinnedDialogsRequest) Decode ¶
func (r *MessagesReorderPinnedDialogsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReorderPinnedDialogsRequest) Encode ¶
func (r *MessagesReorderPinnedDialogsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReorderPinnedDialogsRequest) SetForce ¶
func (r *MessagesReorderPinnedDialogsRequest) SetForce(value bool)
SetForce sets value of Force conditional field.
func (*MessagesReorderPinnedDialogsRequest) String ¶ added in v0.12.0
func (r *MessagesReorderPinnedDialogsRequest) String() string
String implements fmt.Stringer.
type MessagesReorderStickerSetsRequest ¶
type MessagesReorderStickerSetsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Reorder mask stickersets
Masks bool
// New stickerset order by stickerset IDs
Order []int64
}
MessagesReorderStickerSetsRequest represents TL type `messages.reorderStickerSets#78337739`. Reorder installed stickersets
See https://core.telegram.org/method/messages.reorderStickerSets for reference.
func (*MessagesReorderStickerSetsRequest) Decode ¶
func (r *MessagesReorderStickerSetsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReorderStickerSetsRequest) Encode ¶
func (r *MessagesReorderStickerSetsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReorderStickerSetsRequest) SetMasks ¶
func (r *MessagesReorderStickerSetsRequest) SetMasks(value bool)
SetMasks sets value of Masks conditional field.
func (*MessagesReorderStickerSetsRequest) String ¶ added in v0.12.0
func (r *MessagesReorderStickerSetsRequest) String() string
String implements fmt.Stringer.
type MessagesReportEncryptedSpamRequest ¶
type MessagesReportEncryptedSpamRequest struct {
// The secret chat to report
Peer InputEncryptedChat
}
MessagesReportEncryptedSpamRequest represents TL type `messages.reportEncryptedSpam#4b0c8c0f`. Report a secret chat for spam
See https://core.telegram.org/method/messages.reportEncryptedSpam for reference.
func (*MessagesReportEncryptedSpamRequest) Decode ¶
func (r *MessagesReportEncryptedSpamRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReportEncryptedSpamRequest) Encode ¶
func (r *MessagesReportEncryptedSpamRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReportEncryptedSpamRequest) String ¶ added in v0.12.0
func (r *MessagesReportEncryptedSpamRequest) String() string
String implements fmt.Stringer.
type MessagesReportRequest ¶
type MessagesReportRequest struct {
// Peer
Peer InputPeerClass
// IDs of messages to report
ID []int
// Why are these messages being reported
Reason ReportReasonClass
}
MessagesReportRequest represents TL type `messages.report#bd82b658`. Report a message in a chat for violation of telegram's Terms of Service
See https://core.telegram.org/method/messages.report for reference.
func (*MessagesReportRequest) Decode ¶
func (r *MessagesReportRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReportRequest) Encode ¶
func (r *MessagesReportRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReportRequest) String ¶ added in v0.12.0
func (r *MessagesReportRequest) String() string
String implements fmt.Stringer.
type MessagesReportSpamRequest ¶
type MessagesReportSpamRequest struct {
// Peer to report
Peer InputPeerClass
}
MessagesReportSpamRequest represents TL type `messages.reportSpam#cf1592db`. Report a new incoming chat for spam, if the peer settings¹ of the chat allow us to do that
Links:
See https://core.telegram.org/method/messages.reportSpam for reference.
func (*MessagesReportSpamRequest) Decode ¶
func (r *MessagesReportSpamRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesReportSpamRequest) Encode ¶
func (r *MessagesReportSpamRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesReportSpamRequest) String ¶ added in v0.12.0
func (r *MessagesReportSpamRequest) String() string
String implements fmt.Stringer.
type MessagesRequestEncryptionRequest ¶
type MessagesRequestEncryptionRequest struct {
// User ID
UserID InputUserClass
// Unique client request ID required to prevent resending. This also doubles as the chat ID.
RandomID int
// A = g ^ a mod p, see Wikipedia¹
//
// Links:
// 1) https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange
GA []byte
}
MessagesRequestEncryptionRequest represents TL type `messages.requestEncryption#f64daf43`. Sends a request to start a secret chat to the user.
See https://core.telegram.org/method/messages.requestEncryption for reference.
func (*MessagesRequestEncryptionRequest) Decode ¶
func (r *MessagesRequestEncryptionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesRequestEncryptionRequest) Encode ¶
func (r *MessagesRequestEncryptionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesRequestEncryptionRequest) String ¶ added in v0.12.0
func (r *MessagesRequestEncryptionRequest) String() string
String implements fmt.Stringer.
type MessagesRequestUrlAuthRequest ¶
type MessagesRequestUrlAuthRequest struct {
// Peer where the message is located
Peer InputPeerClass
// The message
MsgID int
// The ID of the button with the authorization request
ButtonID int
}
MessagesRequestUrlAuthRequest represents TL type `messages.requestUrlAuth#e33f5613`. Get more info about a Seamless Telegram Login authorization request, for more info click here »¹
Links:
See https://core.telegram.org/method/messages.requestUrlAuth for reference.
func (*MessagesRequestUrlAuthRequest) Decode ¶
func (r *MessagesRequestUrlAuthRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesRequestUrlAuthRequest) Encode ¶
func (r *MessagesRequestUrlAuthRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesRequestUrlAuthRequest) String ¶ added in v0.12.0
func (r *MessagesRequestUrlAuthRequest) String() string
String implements fmt.Stringer.
type MessagesSaveDraftRequest ¶
type MessagesSaveDraftRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable generation of the webpage preview
NoWebpage bool
// Message ID the message should reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// Destination of the message that should be sent
Peer InputPeerClass
// The draft
Message string
// Message entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
MessagesSaveDraftRequest represents TL type `messages.saveDraft#bc39e14b`. Save a message draft¹ associated to a chat.
Links:
See https://core.telegram.org/method/messages.saveDraft for reference.
func (*MessagesSaveDraftRequest) Decode ¶
func (s *MessagesSaveDraftRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSaveDraftRequest) Encode ¶
func (s *MessagesSaveDraftRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSaveDraftRequest) GetEntities ¶
func (s *MessagesSaveDraftRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesSaveDraftRequest) GetReplyToMsgID ¶
func (s *MessagesSaveDraftRequest) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*MessagesSaveDraftRequest) SetEntities ¶
func (s *MessagesSaveDraftRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesSaveDraftRequest) SetNoWebpage ¶
func (s *MessagesSaveDraftRequest) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*MessagesSaveDraftRequest) SetReplyToMsgID ¶
func (s *MessagesSaveDraftRequest) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*MessagesSaveDraftRequest) String ¶ added in v0.12.0
func (s *MessagesSaveDraftRequest) String() string
String implements fmt.Stringer.
type MessagesSaveGifRequest ¶
type MessagesSaveGifRequest struct {
// GIF to save
ID InputDocumentClass
// Whether to remove GIF from saved gifs list
Unsave bool
}
MessagesSaveGifRequest represents TL type `messages.saveGif#327a30cb`. Add GIF to saved gifs list
See https://core.telegram.org/method/messages.saveGif for reference.
func (*MessagesSaveGifRequest) Decode ¶
func (s *MessagesSaveGifRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSaveGifRequest) Encode ¶
func (s *MessagesSaveGifRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSaveGifRequest) String ¶ added in v0.12.0
func (s *MessagesSaveGifRequest) String() string
String implements fmt.Stringer.
type MessagesSaveRecentStickerRequest ¶
type MessagesSaveRecentStickerRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to add/remove stickers recently attached to photo or video files
Attached bool
// Sticker
ID InputDocumentClass
// Whether to save or unsave the sticker
Unsave bool
}
MessagesSaveRecentStickerRequest represents TL type `messages.saveRecentSticker#392718f8`. Add/remove sticker from recent stickers list
See https://core.telegram.org/method/messages.saveRecentSticker for reference.
func (*MessagesSaveRecentStickerRequest) Decode ¶
func (s *MessagesSaveRecentStickerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSaveRecentStickerRequest) Encode ¶
func (s *MessagesSaveRecentStickerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSaveRecentStickerRequest) SetAttached ¶
func (s *MessagesSaveRecentStickerRequest) SetAttached(value bool)
SetAttached sets value of Attached conditional field.
func (*MessagesSaveRecentStickerRequest) String ¶ added in v0.12.0
func (s *MessagesSaveRecentStickerRequest) String() string
String implements fmt.Stringer.
type MessagesSavedGifs ¶
type MessagesSavedGifs struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// List of saved gifs
Gifs []DocumentClass
}
MessagesSavedGifs represents TL type `messages.savedGifs#2e0709a5`. Saved gifs
See https://core.telegram.org/constructor/messages.savedGifs for reference.
func (*MessagesSavedGifs) Decode ¶
func (s *MessagesSavedGifs) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSavedGifs) Encode ¶
func (s *MessagesSavedGifs) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSavedGifs) String ¶ added in v0.12.0
func (s *MessagesSavedGifs) String() string
String implements fmt.Stringer.
type MessagesSavedGifsBox ¶
type MessagesSavedGifsBox struct {
SavedGifs MessagesSavedGifsClass
}
MessagesSavedGifs boxes the MessagesSavedGifsClass providing a helper.
type MessagesSavedGifsClass ¶
type MessagesSavedGifsClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesSavedGifsClass represents messages.SavedGifs generic type.
See https://core.telegram.org/type/messages.SavedGifs for reference.
Example:
g, err := DecodeMessagesSavedGifs(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesSavedGifsNotModified: // messages.savedGifsNotModified#e8025ca2
case *MessagesSavedGifs: // messages.savedGifs#2e0709a5
default: panic(v)
}
func DecodeMessagesSavedGifs ¶
func DecodeMessagesSavedGifs(buf *bin.Buffer) (MessagesSavedGifsClass, error)
DecodeMessagesSavedGifs implements binary de-serialization for MessagesSavedGifsClass.
type MessagesSavedGifsNotModified ¶
type MessagesSavedGifsNotModified struct {
}
MessagesSavedGifsNotModified represents TL type `messages.savedGifsNotModified#e8025ca2`. No new saved gifs were found
See https://core.telegram.org/constructor/messages.savedGifsNotModified for reference.
func (*MessagesSavedGifsNotModified) Decode ¶
func (s *MessagesSavedGifsNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSavedGifsNotModified) Encode ¶
func (s *MessagesSavedGifsNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSavedGifsNotModified) String ¶ added in v0.12.0
func (s *MessagesSavedGifsNotModified) String() string
String implements fmt.Stringer.
type MessagesSearchCounter ¶
type MessagesSearchCounter struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, the results may be inexact
Inexact bool
// Provided message filter
Filter MessagesFilterClass
// Number of results that were found server-side
Count int
}
MessagesSearchCounter represents TL type `messages.searchCounter#e844ebff`. Indicates how many results would be found by a messages.search¹ call with the same parameters
Links:
See https://core.telegram.org/constructor/messages.searchCounter for reference.
func (*MessagesSearchCounter) Decode ¶
func (s *MessagesSearchCounter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSearchCounter) Encode ¶
func (s *MessagesSearchCounter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSearchCounter) SetInexact ¶
func (s *MessagesSearchCounter) SetInexact(value bool)
SetInexact sets value of Inexact conditional field.
func (*MessagesSearchCounter) String ¶ added in v0.12.0
func (s *MessagesSearchCounter) String() string
String implements fmt.Stringer.
type MessagesSearchCounterVector ¶ added in v0.8.0
type MessagesSearchCounterVector struct {
// Elements of Vector<messages.SearchCounter>
Elems []MessagesSearchCounter
}
MessagesSearchCounterVector is a box for Vector<messages.SearchCounter>
func (*MessagesSearchCounterVector) Decode ¶ added in v0.8.0
func (vec *MessagesSearchCounterVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSearchCounterVector) Encode ¶ added in v0.8.0
func (vec *MessagesSearchCounterVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSearchCounterVector) String ¶ added in v0.12.0
func (vec *MessagesSearchCounterVector) String() string
String implements fmt.Stringer.
type MessagesSearchGlobalRequest ¶
type MessagesSearchGlobalRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Query
Q string
// Global search filter
Filter MessagesFilterClass
// If a positive value was specified, the method will return only messages with date bigger than min_date
MinDate int
// If a positive value was transferred, the method will return only messages with date smaller than max_date
MaxDate int
// Initially 0, then set to the next_rate parameter of messages.messagesSlice¹
//
// Links:
// 1) https://core.telegram.org/constructor/messages.messagesSlice
OffsetRate int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetPeer InputPeerClass
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
}
MessagesSearchGlobalRequest represents TL type `messages.searchGlobal#4bc6589a`. Search for messages and peers globally
See https://core.telegram.org/method/messages.searchGlobal for reference.
func (*MessagesSearchGlobalRequest) Decode ¶
func (s *MessagesSearchGlobalRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSearchGlobalRequest) Encode ¶
func (s *MessagesSearchGlobalRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSearchGlobalRequest) GetFolderID ¶
func (s *MessagesSearchGlobalRequest) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*MessagesSearchGlobalRequest) SetFolderID ¶
func (s *MessagesSearchGlobalRequest) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*MessagesSearchGlobalRequest) String ¶ added in v0.12.0
func (s *MessagesSearchGlobalRequest) String() string
String implements fmt.Stringer.
type MessagesSearchRequest ¶
type MessagesSearchRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// User or chat, histories with which are searched, or (inputPeerEmpty)¹ constructor for global search
//
// Links:
// 1) https://core.telegram.org/constructor/inputPeerEmpty
Peer InputPeerClass
// Text search request
Q string
// Only return messages sent by the specified user ID
//
// Use SetFromID and GetFromID helpers.
FromID InputPeerClass
// Thread ID¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetTopMsgID and GetTopMsgID helpers.
TopMsgID int
// Filter to return only specified message types
Filter MessagesFilterClass
// If a positive value was transferred, only messages with a sending date bigger than the transferred one will be returned
MinDate int
// If a positive value was transferred, only messages with a sending date smaller than the transferred one will be returned
MaxDate int
// Only return messages starting from the specified message ID
OffsetID int
// Additional offset¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
AddOffset int
// Number of results to return¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
// Maximum message ID to return¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
MaxID int
// Minimum message ID to return¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
MinID int
// Hash¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Hash int
}
MessagesSearchRequest represents TL type `messages.search#c352eec`. Gets back found messages
See https://core.telegram.org/method/messages.search for reference.
func (*MessagesSearchRequest) Decode ¶
func (s *MessagesSearchRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSearchRequest) Encode ¶
func (s *MessagesSearchRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSearchRequest) GetFromID ¶
func (s *MessagesSearchRequest) GetFromID() (value InputPeerClass, ok bool)
GetFromID returns value of FromID conditional field and boolean which is true if field was set.
func (*MessagesSearchRequest) GetTopMsgID ¶
func (s *MessagesSearchRequest) GetTopMsgID() (value int, ok bool)
GetTopMsgID returns value of TopMsgID conditional field and boolean which is true if field was set.
func (*MessagesSearchRequest) SetFromID ¶
func (s *MessagesSearchRequest) SetFromID(value InputPeerClass)
SetFromID sets value of FromID conditional field.
func (*MessagesSearchRequest) SetTopMsgID ¶
func (s *MessagesSearchRequest) SetTopMsgID(value int)
SetTopMsgID sets value of TopMsgID conditional field.
func (*MessagesSearchRequest) String ¶ added in v0.12.0
func (s *MessagesSearchRequest) String() string
String implements fmt.Stringer.
type MessagesSearchStickerSetsRequest ¶
type MessagesSearchStickerSetsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Exclude featured stickersets from results
ExcludeFeatured bool
// Query string
Q string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
}
MessagesSearchStickerSetsRequest represents TL type `messages.searchStickerSets#c2b7d08b`. Search for stickersets
See https://core.telegram.org/method/messages.searchStickerSets for reference.
func (*MessagesSearchStickerSetsRequest) Decode ¶
func (s *MessagesSearchStickerSetsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSearchStickerSetsRequest) Encode ¶
func (s *MessagesSearchStickerSetsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSearchStickerSetsRequest) SetExcludeFeatured ¶
func (s *MessagesSearchStickerSetsRequest) SetExcludeFeatured(value bool)
SetExcludeFeatured sets value of ExcludeFeatured conditional field.
func (*MessagesSearchStickerSetsRequest) String ¶ added in v0.12.0
func (s *MessagesSearchStickerSetsRequest) String() string
String implements fmt.Stringer.
type MessagesSendEncryptedFileRequest ¶
type MessagesSendEncryptedFileRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to send the file without triggering a notification
Silent bool
// Secret chat ID
Peer InputEncryptedChat
// Unique client message ID necessary to prevent message resending
RandomID int64
// TL-serialization of DecryptedMessage¹ type, encrypted with a key generated during chat initialization
//
// Links:
// 1) https://core.telegram.org/type/DecryptedMessage
Data []byte
// File attachment for the secret chat
File InputEncryptedFileClass
}
MessagesSendEncryptedFileRequest represents TL type `messages.sendEncryptedFile#5559481d`. Sends a message with a file attachment to a secret chat
See https://core.telegram.org/method/messages.sendEncryptedFile for reference.
func (*MessagesSendEncryptedFileRequest) Decode ¶
func (s *MessagesSendEncryptedFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendEncryptedFileRequest) Encode ¶
func (s *MessagesSendEncryptedFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendEncryptedFileRequest) SetSilent ¶
func (s *MessagesSendEncryptedFileRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendEncryptedFileRequest) String ¶ added in v0.12.0
func (s *MessagesSendEncryptedFileRequest) String() string
String implements fmt.Stringer.
type MessagesSendEncryptedRequest ¶
type MessagesSendEncryptedRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Send encrypted message without a notification
Silent bool
// Secret chat ID
Peer InputEncryptedChat
// Unique client message ID, necessary to avoid message resending
RandomID int64
// TL-serialization of DecryptedMessage¹ type, encrypted with a key that was created during chat initialization
//
// Links:
// 1) https://core.telegram.org/type/DecryptedMessage
Data []byte
}
MessagesSendEncryptedRequest represents TL type `messages.sendEncrypted#44fa7a15`. Sends a text message to a secret chat.
See https://core.telegram.org/method/messages.sendEncrypted for reference.
func (*MessagesSendEncryptedRequest) Decode ¶
func (s *MessagesSendEncryptedRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendEncryptedRequest) Encode ¶
func (s *MessagesSendEncryptedRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendEncryptedRequest) SetSilent ¶
func (s *MessagesSendEncryptedRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendEncryptedRequest) String ¶ added in v0.12.0
func (s *MessagesSendEncryptedRequest) String() string
String implements fmt.Stringer.
type MessagesSendEncryptedServiceRequest ¶
type MessagesSendEncryptedServiceRequest struct {
// Secret chat ID
Peer InputEncryptedChat
// Unique client message ID required to prevent message resending
RandomID int64
// TL-serialization of DecryptedMessage¹ type, encrypted with a key generated during chat initialization
//
// Links:
// 1) https://core.telegram.org/type/DecryptedMessage
Data []byte
}
MessagesSendEncryptedServiceRequest represents TL type `messages.sendEncryptedService#32d439a4`. Sends a service message to a secret chat.
See https://core.telegram.org/method/messages.sendEncryptedService for reference.
func (*MessagesSendEncryptedServiceRequest) Decode ¶
func (s *MessagesSendEncryptedServiceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendEncryptedServiceRequest) Encode ¶
func (s *MessagesSendEncryptedServiceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendEncryptedServiceRequest) String ¶ added in v0.12.0
func (s *MessagesSendEncryptedServiceRequest) String() string
String implements fmt.Stringer.
type MessagesSendInlineBotResultRequest ¶
type MessagesSendInlineBotResultRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to send the message silently (no notification will be triggered on the other client)
Silent bool
// Whether to send the message in background
Background bool
// Whether to clear the draft¹
//
// Links:
// 1) https://core.telegram.org/api/drafts
ClearDraft bool
// Whether to hide the via @botname in the resulting message (only for bot usernames encountered in the config¹)
//
// Links:
// 1) https://core.telegram.org/constructor/config
HideVia bool
// Destination
Peer InputPeerClass
// ID of the message this message should reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// Random ID to avoid resending the same query
RandomID int64
// Query ID from messages.getInlineBotResults¹
//
// Links:
// 1) https://core.telegram.org/method/messages.getInlineBotResults
QueryID int64
// Result ID from messages.getInlineBotResults¹
//
// Links:
// 1) https://core.telegram.org/method/messages.getInlineBotResults
ID string
// Scheduled message date for scheduled messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesSendInlineBotResultRequest represents TL type `messages.sendInlineBotResult#220815b0`. Send a result obtained using messages.getInlineBotResults¹.
Links:
See https://core.telegram.org/method/messages.sendInlineBotResult for reference.
func (*MessagesSendInlineBotResultRequest) Decode ¶
func (s *MessagesSendInlineBotResultRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendInlineBotResultRequest) Encode ¶
func (s *MessagesSendInlineBotResultRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendInlineBotResultRequest) GetReplyToMsgID ¶
func (s *MessagesSendInlineBotResultRequest) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*MessagesSendInlineBotResultRequest) GetScheduleDate ¶
func (s *MessagesSendInlineBotResultRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesSendInlineBotResultRequest) SetBackground ¶
func (s *MessagesSendInlineBotResultRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*MessagesSendInlineBotResultRequest) SetClearDraft ¶
func (s *MessagesSendInlineBotResultRequest) SetClearDraft(value bool)
SetClearDraft sets value of ClearDraft conditional field.
func (*MessagesSendInlineBotResultRequest) SetHideVia ¶
func (s *MessagesSendInlineBotResultRequest) SetHideVia(value bool)
SetHideVia sets value of HideVia conditional field.
func (*MessagesSendInlineBotResultRequest) SetReplyToMsgID ¶
func (s *MessagesSendInlineBotResultRequest) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*MessagesSendInlineBotResultRequest) SetScheduleDate ¶
func (s *MessagesSendInlineBotResultRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesSendInlineBotResultRequest) SetSilent ¶
func (s *MessagesSendInlineBotResultRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendInlineBotResultRequest) String ¶ added in v0.12.0
func (s *MessagesSendInlineBotResultRequest) String() string
String implements fmt.Stringer.
type MessagesSendMediaRequest ¶
type MessagesSendMediaRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Send message silently (no notification should be triggered)
Silent bool
// Send message in background
Background bool
// Clear the draft
ClearDraft bool
// Destination
Peer InputPeerClass
// Message ID to which this message should reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// Attached media
Media InputMediaClass
// Caption
Message string
// Random ID to avoid resending the same message
RandomID int64
// Reply markup for bot keyboards
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
// Message entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Scheduled message date for scheduled messages¹
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesSendMediaRequest represents TL type `messages.sendMedia#3491eba9`. Send a media
See https://core.telegram.org/method/messages.sendMedia for reference.
func (*MessagesSendMediaRequest) Decode ¶
func (s *MessagesSendMediaRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendMediaRequest) Encode ¶
func (s *MessagesSendMediaRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendMediaRequest) GetEntities ¶
func (s *MessagesSendMediaRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesSendMediaRequest) GetReplyMarkup ¶
func (s *MessagesSendMediaRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*MessagesSendMediaRequest) GetReplyToMsgID ¶
func (s *MessagesSendMediaRequest) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*MessagesSendMediaRequest) GetScheduleDate ¶
func (s *MessagesSendMediaRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesSendMediaRequest) SetBackground ¶
func (s *MessagesSendMediaRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*MessagesSendMediaRequest) SetClearDraft ¶
func (s *MessagesSendMediaRequest) SetClearDraft(value bool)
SetClearDraft sets value of ClearDraft conditional field.
func (*MessagesSendMediaRequest) SetEntities ¶
func (s *MessagesSendMediaRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesSendMediaRequest) SetReplyMarkup ¶
func (s *MessagesSendMediaRequest) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*MessagesSendMediaRequest) SetReplyToMsgID ¶
func (s *MessagesSendMediaRequest) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*MessagesSendMediaRequest) SetScheduleDate ¶
func (s *MessagesSendMediaRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesSendMediaRequest) SetSilent ¶
func (s *MessagesSendMediaRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendMediaRequest) String ¶ added in v0.12.0
func (s *MessagesSendMediaRequest) String() string
String implements fmt.Stringer.
type MessagesSendMessageRequest ¶
type MessagesSendMessageRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag to disable generation of the webpage preview
NoWebpage bool
// Send this message silently (no notifications for the receivers)
Silent bool
// Send this message as background message
Background bool
// Clear the draft field
ClearDraft bool
// The destination where the message will be sent
Peer InputPeerClass
// The message ID to which this message will reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// The message
Message string
// Unique client message ID required to prevent message resending
RandomID int64
// Reply markup for sending bot buttons
//
// Use SetReplyMarkup and GetReplyMarkup helpers.
ReplyMarkup ReplyMarkupClass
// Message entities¹ for sending styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
// Scheduled message date for scheduled messages¹
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesSendMessageRequest represents TL type `messages.sendMessage#520c3870`. Sends a message to a chat
See https://core.telegram.org/method/messages.sendMessage for reference.
func (*MessagesSendMessageRequest) Decode ¶
func (s *MessagesSendMessageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendMessageRequest) Encode ¶
func (s *MessagesSendMessageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendMessageRequest) GetEntities ¶
func (s *MessagesSendMessageRequest) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*MessagesSendMessageRequest) GetReplyMarkup ¶
func (s *MessagesSendMessageRequest) GetReplyMarkup() (value ReplyMarkupClass, ok bool)
GetReplyMarkup returns value of ReplyMarkup conditional field and boolean which is true if field was set.
func (*MessagesSendMessageRequest) GetReplyToMsgID ¶
func (s *MessagesSendMessageRequest) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*MessagesSendMessageRequest) GetScheduleDate ¶
func (s *MessagesSendMessageRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesSendMessageRequest) SetBackground ¶
func (s *MessagesSendMessageRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*MessagesSendMessageRequest) SetClearDraft ¶
func (s *MessagesSendMessageRequest) SetClearDraft(value bool)
SetClearDraft sets value of ClearDraft conditional field.
func (*MessagesSendMessageRequest) SetEntities ¶
func (s *MessagesSendMessageRequest) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*MessagesSendMessageRequest) SetNoWebpage ¶
func (s *MessagesSendMessageRequest) SetNoWebpage(value bool)
SetNoWebpage sets value of NoWebpage conditional field.
func (*MessagesSendMessageRequest) SetReplyMarkup ¶
func (s *MessagesSendMessageRequest) SetReplyMarkup(value ReplyMarkupClass)
SetReplyMarkup sets value of ReplyMarkup conditional field.
func (*MessagesSendMessageRequest) SetReplyToMsgID ¶
func (s *MessagesSendMessageRequest) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*MessagesSendMessageRequest) SetScheduleDate ¶
func (s *MessagesSendMessageRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesSendMessageRequest) SetSilent ¶
func (s *MessagesSendMessageRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendMessageRequest) String ¶ added in v0.12.0
func (s *MessagesSendMessageRequest) String() string
String implements fmt.Stringer.
type MessagesSendMultiMediaRequest ¶
type MessagesSendMultiMediaRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to send the album silently (no notification triggered)
Silent bool
// Send in background?
Background bool
// Whether to clear drafts¹
//
// Links:
// 1) https://core.telegram.org/api/drafts
ClearDraft bool
// The destination chat
Peer InputPeerClass
// The message to reply to
//
// Use SetReplyToMsgID and GetReplyToMsgID helpers.
ReplyToMsgID int
// The medias to send
MultiMedia []InputSingleMedia
// Scheduled message date for scheduled messages
//
// Use SetScheduleDate and GetScheduleDate helpers.
ScheduleDate int
}
MessagesSendMultiMediaRequest represents TL type `messages.sendMultiMedia#cc0110cb`. Send an album or grouped media¹
Links:
See https://core.telegram.org/method/messages.sendMultiMedia for reference.
func (*MessagesSendMultiMediaRequest) Decode ¶
func (s *MessagesSendMultiMediaRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendMultiMediaRequest) Encode ¶
func (s *MessagesSendMultiMediaRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendMultiMediaRequest) GetReplyToMsgID ¶
func (s *MessagesSendMultiMediaRequest) GetReplyToMsgID() (value int, ok bool)
GetReplyToMsgID returns value of ReplyToMsgID conditional field and boolean which is true if field was set.
func (*MessagesSendMultiMediaRequest) GetScheduleDate ¶
func (s *MessagesSendMultiMediaRequest) GetScheduleDate() (value int, ok bool)
GetScheduleDate returns value of ScheduleDate conditional field and boolean which is true if field was set.
func (*MessagesSendMultiMediaRequest) SetBackground ¶
func (s *MessagesSendMultiMediaRequest) SetBackground(value bool)
SetBackground sets value of Background conditional field.
func (*MessagesSendMultiMediaRequest) SetClearDraft ¶
func (s *MessagesSendMultiMediaRequest) SetClearDraft(value bool)
SetClearDraft sets value of ClearDraft conditional field.
func (*MessagesSendMultiMediaRequest) SetReplyToMsgID ¶
func (s *MessagesSendMultiMediaRequest) SetReplyToMsgID(value int)
SetReplyToMsgID sets value of ReplyToMsgID conditional field.
func (*MessagesSendMultiMediaRequest) SetScheduleDate ¶
func (s *MessagesSendMultiMediaRequest) SetScheduleDate(value int)
SetScheduleDate sets value of ScheduleDate conditional field.
func (*MessagesSendMultiMediaRequest) SetSilent ¶
func (s *MessagesSendMultiMediaRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesSendMultiMediaRequest) String ¶ added in v0.12.0
func (s *MessagesSendMultiMediaRequest) String() string
String implements fmt.Stringer.
type MessagesSendScheduledMessagesRequest ¶
type MessagesSendScheduledMessagesRequest struct {
// Peer
Peer InputPeerClass
// Scheduled message IDs
ID []int
}
MessagesSendScheduledMessagesRequest represents TL type `messages.sendScheduledMessages#bd38850a`. Send scheduled messages right away
See https://core.telegram.org/method/messages.sendScheduledMessages for reference.
func (*MessagesSendScheduledMessagesRequest) Decode ¶
func (s *MessagesSendScheduledMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendScheduledMessagesRequest) Encode ¶
func (s *MessagesSendScheduledMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendScheduledMessagesRequest) String ¶ added in v0.12.0
func (s *MessagesSendScheduledMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesSendScreenshotNotificationRequest ¶
type MessagesSendScreenshotNotificationRequest struct {
// Other user
Peer InputPeerClass
// ID of message that was screenshotted, can be 0
ReplyToMsgID int
// Random ID to avoid message resending
RandomID int64
}
MessagesSendScreenshotNotificationRequest represents TL type `messages.sendScreenshotNotification#c97df020`. Notify the other user in a private chat that a screenshot of the chat was taken
See https://core.telegram.org/method/messages.sendScreenshotNotification for reference.
func (*MessagesSendScreenshotNotificationRequest) Decode ¶
func (s *MessagesSendScreenshotNotificationRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendScreenshotNotificationRequest) Encode ¶
func (s *MessagesSendScreenshotNotificationRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendScreenshotNotificationRequest) String ¶ added in v0.12.0
func (s *MessagesSendScreenshotNotificationRequest) String() string
String implements fmt.Stringer.
type MessagesSendVoteRequest ¶
type MessagesSendVoteRequest struct {
// The chat where the poll was sent
Peer InputPeerClass
// The message ID of the poll
MsgID int
// The options that were chosen
Options [][]byte
}
MessagesSendVoteRequest represents TL type `messages.sendVote#10ea6184`. Vote in a poll¹
Links:
See https://core.telegram.org/method/messages.sendVote for reference.
func (*MessagesSendVoteRequest) Decode ¶
func (s *MessagesSendVoteRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSendVoteRequest) Encode ¶
func (s *MessagesSendVoteRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSendVoteRequest) String ¶ added in v0.12.0
func (s *MessagesSendVoteRequest) String() string
String implements fmt.Stringer.
type MessagesSentEncryptedFile ¶
type MessagesSentEncryptedFile struct {
// Sending date
Date int
// Attached file
File EncryptedFileClass
}
MessagesSentEncryptedFile represents TL type `messages.sentEncryptedFile#9493ff32`. Message with a file enclosure sent to a protected chat
See https://core.telegram.org/constructor/messages.sentEncryptedFile for reference.
func (*MessagesSentEncryptedFile) Decode ¶
func (s *MessagesSentEncryptedFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSentEncryptedFile) Encode ¶
func (s *MessagesSentEncryptedFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSentEncryptedFile) String ¶ added in v0.12.0
func (s *MessagesSentEncryptedFile) String() string
String implements fmt.Stringer.
type MessagesSentEncryptedMessage ¶
type MessagesSentEncryptedMessage struct {
// Date of sending
Date int
}
MessagesSentEncryptedMessage represents TL type `messages.sentEncryptedMessage#560f8935`. Message without file attachemts sent to an encrypted file.
See https://core.telegram.org/constructor/messages.sentEncryptedMessage for reference.
func (*MessagesSentEncryptedMessage) Decode ¶
func (s *MessagesSentEncryptedMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSentEncryptedMessage) Encode ¶
func (s *MessagesSentEncryptedMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSentEncryptedMessage) String ¶ added in v0.12.0
func (s *MessagesSentEncryptedMessage) String() string
String implements fmt.Stringer.
type MessagesSentEncryptedMessageBox ¶
type MessagesSentEncryptedMessageBox struct {
SentEncryptedMessage MessagesSentEncryptedMessageClass
}
MessagesSentEncryptedMessage boxes the MessagesSentEncryptedMessageClass providing a helper.
type MessagesSentEncryptedMessageClass ¶
type MessagesSentEncryptedMessageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesSentEncryptedMessageClass represents messages.SentEncryptedMessage generic type.
See https://core.telegram.org/type/messages.SentEncryptedMessage for reference.
Example:
g, err := DecodeMessagesSentEncryptedMessage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesSentEncryptedMessage: // messages.sentEncryptedMessage#560f8935
case *MessagesSentEncryptedFile: // messages.sentEncryptedFile#9493ff32
default: panic(v)
}
func DecodeMessagesSentEncryptedMessage ¶
func DecodeMessagesSentEncryptedMessage(buf *bin.Buffer) (MessagesSentEncryptedMessageClass, error)
DecodeMessagesSentEncryptedMessage implements binary de-serialization for MessagesSentEncryptedMessageClass.
type MessagesSetBotCallbackAnswerRequest ¶
type MessagesSetBotCallbackAnswerRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to show the message as a popup instead of a toast notification
Alert bool
// Query ID
QueryID int64
// Popup to show
//
// Use SetMessage and GetMessage helpers.
Message string
// URL to open
//
// Use SetURL and GetURL helpers.
URL string
// Cache validity
CacheTime int
}
MessagesSetBotCallbackAnswerRequest represents TL type `messages.setBotCallbackAnswer#d58f130a`. Set the callback answer to a user button press (bots only)
See https://core.telegram.org/method/messages.setBotCallbackAnswer for reference.
func (*MessagesSetBotCallbackAnswerRequest) Decode ¶
func (s *MessagesSetBotCallbackAnswerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetBotCallbackAnswerRequest) Encode ¶
func (s *MessagesSetBotCallbackAnswerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetBotCallbackAnswerRequest) GetMessage ¶
func (s *MessagesSetBotCallbackAnswerRequest) GetMessage() (value string, ok bool)
GetMessage returns value of Message conditional field and boolean which is true if field was set.
func (*MessagesSetBotCallbackAnswerRequest) GetURL ¶
func (s *MessagesSetBotCallbackAnswerRequest) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*MessagesSetBotCallbackAnswerRequest) SetAlert ¶
func (s *MessagesSetBotCallbackAnswerRequest) SetAlert(value bool)
SetAlert sets value of Alert conditional field.
func (*MessagesSetBotCallbackAnswerRequest) SetMessage ¶
func (s *MessagesSetBotCallbackAnswerRequest) SetMessage(value string)
SetMessage sets value of Message conditional field.
func (*MessagesSetBotCallbackAnswerRequest) SetURL ¶
func (s *MessagesSetBotCallbackAnswerRequest) SetURL(value string)
SetURL sets value of URL conditional field.
func (*MessagesSetBotCallbackAnswerRequest) String ¶ added in v0.12.0
func (s *MessagesSetBotCallbackAnswerRequest) String() string
String implements fmt.Stringer.
type MessagesSetBotPrecheckoutResultsRequest ¶
type MessagesSetBotPrecheckoutResultsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag if everything is alright (goods are available, etc.) and the bot is ready to proceed with the order, otherwise do not set it, and set the error field, instead
Success bool
// Unique identifier for the query to be answered
QueryID int64
// Required if the success isn't set. Error message in human readable form that explains the reason for failure to proceed with the checkout (e.g. "Sorry, somebody just bought the last of our amazing black T-shirts while you were busy filling out your payment details. Please choose a different color or garment!"). Telegram will display this message to the user.
//
// Use SetError and GetError helpers.
Error string
}
MessagesSetBotPrecheckoutResultsRequest represents TL type `messages.setBotPrecheckoutResults#9c2dd95`. Once the user has confirmed their payment and shipping details, the bot receives an updateBotPrecheckoutQuery¹ update. Use this method to respond to such pre-checkout queries. Note: Telegram must receive an answer within 10 seconds after the pre-checkout query was sent.
Links:
See https://core.telegram.org/method/messages.setBotPrecheckoutResults for reference.
func (*MessagesSetBotPrecheckoutResultsRequest) Decode ¶
func (s *MessagesSetBotPrecheckoutResultsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetBotPrecheckoutResultsRequest) Encode ¶
func (s *MessagesSetBotPrecheckoutResultsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetBotPrecheckoutResultsRequest) GetError ¶
func (s *MessagesSetBotPrecheckoutResultsRequest) GetError() (value string, ok bool)
GetError returns value of Error conditional field and boolean which is true if field was set.
func (*MessagesSetBotPrecheckoutResultsRequest) SetError ¶
func (s *MessagesSetBotPrecheckoutResultsRequest) SetError(value string)
SetError sets value of Error conditional field.
func (*MessagesSetBotPrecheckoutResultsRequest) SetSuccess ¶
func (s *MessagesSetBotPrecheckoutResultsRequest) SetSuccess(value bool)
SetSuccess sets value of Success conditional field.
func (*MessagesSetBotPrecheckoutResultsRequest) String ¶ added in v0.12.0
func (s *MessagesSetBotPrecheckoutResultsRequest) String() string
String implements fmt.Stringer.
type MessagesSetBotShippingResultsRequest ¶
type MessagesSetBotShippingResultsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Unique identifier for the query to be answered
QueryID int64
// Error message in human readable form that explains why it is impossible to complete the order (e.g. "Sorry, delivery to your desired address is unavailable'). Telegram will display this message to the user.
//
// Use SetError and GetError helpers.
Error string
// A vector of available shipping options.
//
// Use SetShippingOptions and GetShippingOptions helpers.
ShippingOptions []ShippingOption
}
MessagesSetBotShippingResultsRequest represents TL type `messages.setBotShippingResults#e5f672fa`. If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the bot will receive an updateBotShippingQuery¹ update. Use this method to reply to shipping queries.
Links:
See https://core.telegram.org/method/messages.setBotShippingResults for reference.
func (*MessagesSetBotShippingResultsRequest) Decode ¶
func (s *MessagesSetBotShippingResultsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetBotShippingResultsRequest) Encode ¶
func (s *MessagesSetBotShippingResultsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetBotShippingResultsRequest) GetError ¶
func (s *MessagesSetBotShippingResultsRequest) GetError() (value string, ok bool)
GetError returns value of Error conditional field and boolean which is true if field was set.
func (*MessagesSetBotShippingResultsRequest) GetShippingOptions ¶
func (s *MessagesSetBotShippingResultsRequest) GetShippingOptions() (value []ShippingOption, ok bool)
GetShippingOptions returns value of ShippingOptions conditional field and boolean which is true if field was set.
func (*MessagesSetBotShippingResultsRequest) SetError ¶
func (s *MessagesSetBotShippingResultsRequest) SetError(value string)
SetError sets value of Error conditional field.
func (*MessagesSetBotShippingResultsRequest) SetShippingOptions ¶
func (s *MessagesSetBotShippingResultsRequest) SetShippingOptions(value []ShippingOption)
SetShippingOptions sets value of ShippingOptions conditional field.
func (*MessagesSetBotShippingResultsRequest) String ¶ added in v0.12.0
func (s *MessagesSetBotShippingResultsRequest) String() string
String implements fmt.Stringer.
type MessagesSetEncryptedTypingRequest ¶
type MessagesSetEncryptedTypingRequest struct {
// Secret chat ID
Peer InputEncryptedChat
// Typing.Possible values:(boolTrue)¹, if the user started typing and more than 5 seconds have passed since the last request(boolFalse)², if the user stopped typing
//
// Links:
// 1) https://core.telegram.org/constructor/boolTrue
// 2) https://core.telegram.org/constructor/boolFalse
Typing bool
}
MessagesSetEncryptedTypingRequest represents TL type `messages.setEncryptedTyping#791451ed`. Send typing event by the current user to a secret chat.
See https://core.telegram.org/method/messages.setEncryptedTyping for reference.
func (*MessagesSetEncryptedTypingRequest) Decode ¶
func (s *MessagesSetEncryptedTypingRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetEncryptedTypingRequest) Encode ¶
func (s *MessagesSetEncryptedTypingRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetEncryptedTypingRequest) String ¶ added in v0.12.0
func (s *MessagesSetEncryptedTypingRequest) String() string
String implements fmt.Stringer.
type MessagesSetGameScoreRequest ¶
type MessagesSetGameScoreRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag if the game message should be automatically edited to include the current scoreboard
EditMessage bool
// Set this flag if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters
Force bool
// Unique identifier of target chat
Peer InputPeerClass
// Identifier of the sent message
ID int
// User identifier
UserID InputUserClass
// New score
Score int
}
MessagesSetGameScoreRequest represents TL type `messages.setGameScore#8ef8ecc0`. Use this method to set the score of the specified user in a game sent as a normal message (bots only).
See https://core.telegram.org/method/messages.setGameScore for reference.
func (*MessagesSetGameScoreRequest) Decode ¶
func (s *MessagesSetGameScoreRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetGameScoreRequest) Encode ¶
func (s *MessagesSetGameScoreRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetGameScoreRequest) SetEditMessage ¶
func (s *MessagesSetGameScoreRequest) SetEditMessage(value bool)
SetEditMessage sets value of EditMessage conditional field.
func (*MessagesSetGameScoreRequest) SetForce ¶
func (s *MessagesSetGameScoreRequest) SetForce(value bool)
SetForce sets value of Force conditional field.
func (*MessagesSetGameScoreRequest) String ¶ added in v0.12.0
func (s *MessagesSetGameScoreRequest) String() string
String implements fmt.Stringer.
type MessagesSetInlineBotResultsRequest ¶
type MessagesSetInlineBotResultsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag if the results are composed of media files
Gallery bool
// Set this flag if results may be cached on the server side only for the user that sent the query. By default, results may be returned to any user who sends the same query
Private bool
// Unique identifier for the answered query
QueryID int64
// Vector of results for the inline query
Results []InputBotInlineResultClass
// The maximum amount of time in seconds that the result of the inline query may be cached on the server. Defaults to 300.
CacheTime int
// Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don‘t support pagination. Offset length can’t exceed 64 bytes.
//
// Use SetNextOffset and GetNextOffset helpers.
NextOffset string
// If passed, clients will display a button with specified text that switches the user to a private chat with the bot and sends the bot a start message with a certain parameter.
//
// Use SetSwitchPm and GetSwitchPm helpers.
SwitchPm InlineBotSwitchPM
}
MessagesSetInlineBotResultsRequest represents TL type `messages.setInlineBotResults#eb5ea206`. Answer an inline query, for bots only
See https://core.telegram.org/method/messages.setInlineBotResults for reference.
func (*MessagesSetInlineBotResultsRequest) Decode ¶
func (s *MessagesSetInlineBotResultsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetInlineBotResultsRequest) Encode ¶
func (s *MessagesSetInlineBotResultsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetInlineBotResultsRequest) GetNextOffset ¶
func (s *MessagesSetInlineBotResultsRequest) GetNextOffset() (value string, ok bool)
GetNextOffset returns value of NextOffset conditional field and boolean which is true if field was set.
func (*MessagesSetInlineBotResultsRequest) GetSwitchPm ¶
func (s *MessagesSetInlineBotResultsRequest) GetSwitchPm() (value InlineBotSwitchPM, ok bool)
GetSwitchPm returns value of SwitchPm conditional field and boolean which is true if field was set.
func (*MessagesSetInlineBotResultsRequest) SetGallery ¶
func (s *MessagesSetInlineBotResultsRequest) SetGallery(value bool)
SetGallery sets value of Gallery conditional field.
func (*MessagesSetInlineBotResultsRequest) SetNextOffset ¶
func (s *MessagesSetInlineBotResultsRequest) SetNextOffset(value string)
SetNextOffset sets value of NextOffset conditional field.
func (*MessagesSetInlineBotResultsRequest) SetPrivate ¶
func (s *MessagesSetInlineBotResultsRequest) SetPrivate(value bool)
SetPrivate sets value of Private conditional field.
func (*MessagesSetInlineBotResultsRequest) SetSwitchPm ¶
func (s *MessagesSetInlineBotResultsRequest) SetSwitchPm(value InlineBotSwitchPM)
SetSwitchPm sets value of SwitchPm conditional field.
func (*MessagesSetInlineBotResultsRequest) String ¶ added in v0.12.0
func (s *MessagesSetInlineBotResultsRequest) String() string
String implements fmt.Stringer.
type MessagesSetInlineGameScoreRequest ¶
type MessagesSetInlineGameScoreRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set this flag if the game message should be automatically edited to include the current scoreboard
EditMessage bool
// Set this flag if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters
Force bool
// ID of the inline message
ID InputBotInlineMessageID
// User identifier
UserID InputUserClass
// New score
Score int
}
MessagesSetInlineGameScoreRequest represents TL type `messages.setInlineGameScore#15ad9f64`. Use this method to set the score of the specified user in a game sent as an inline message (bots only).
See https://core.telegram.org/method/messages.setInlineGameScore for reference.
func (*MessagesSetInlineGameScoreRequest) Decode ¶
func (s *MessagesSetInlineGameScoreRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetInlineGameScoreRequest) Encode ¶
func (s *MessagesSetInlineGameScoreRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetInlineGameScoreRequest) SetEditMessage ¶
func (s *MessagesSetInlineGameScoreRequest) SetEditMessage(value bool)
SetEditMessage sets value of EditMessage conditional field.
func (*MessagesSetInlineGameScoreRequest) SetForce ¶
func (s *MessagesSetInlineGameScoreRequest) SetForce(value bool)
SetForce sets value of Force conditional field.
func (*MessagesSetInlineGameScoreRequest) String ¶ added in v0.12.0
func (s *MessagesSetInlineGameScoreRequest) String() string
String implements fmt.Stringer.
type MessagesSetTypingRequest ¶
type MessagesSetTypingRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Target user or group
Peer InputPeerClass
// Thread ID¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetTopMsgID and GetTopMsgID helpers.
TopMsgID int
// Type of actionParameter added in Layer 17¹.
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-17
Action SendMessageActionClass
}
MessagesSetTypingRequest represents TL type `messages.setTyping#58943ee2`. Sends a current user typing event (see SendMessageAction¹ for all event types) to a conversation partner or group.
Links:
See https://core.telegram.org/method/messages.setTyping for reference.
func (*MessagesSetTypingRequest) Decode ¶
func (s *MessagesSetTypingRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesSetTypingRequest) Encode ¶
func (s *MessagesSetTypingRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesSetTypingRequest) GetTopMsgID ¶
func (s *MessagesSetTypingRequest) GetTopMsgID() (value int, ok bool)
GetTopMsgID returns value of TopMsgID conditional field and boolean which is true if field was set.
func (*MessagesSetTypingRequest) SetTopMsgID ¶
func (s *MessagesSetTypingRequest) SetTopMsgID(value int)
SetTopMsgID sets value of TopMsgID conditional field.
func (*MessagesSetTypingRequest) String ¶ added in v0.12.0
func (s *MessagesSetTypingRequest) String() string
String implements fmt.Stringer.
type MessagesStartBotRequest ¶
type MessagesStartBotRequest struct {
// The bot
Bot InputUserClass
// The chat where to start the bot, can be the bot's private chat or a group
Peer InputPeerClass
// Random ID to avoid resending the same message
RandomID int64
// Deep linking parameter¹
//
// Links:
// 1) https://core.telegram.org/bots#deep-linking
StartParam string
}
MessagesStartBotRequest represents TL type `messages.startBot#e6df7378`. Start a conversation with a bot using a deep linking parameter¹
Links:
See https://core.telegram.org/method/messages.startBot for reference.
func (*MessagesStartBotRequest) Decode ¶
func (s *MessagesStartBotRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStartBotRequest) Encode ¶
func (s *MessagesStartBotRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStartBotRequest) String ¶ added in v0.12.0
func (s *MessagesStartBotRequest) String() string
String implements fmt.Stringer.
type MessagesStickerSet ¶
type MessagesStickerSet struct {
// The stickerset
Set StickerSet
// Emoji info for stickers
Packs []StickerPack
// Stickers in stickerset
Documents []DocumentClass
}
MessagesStickerSet represents TL type `messages.stickerSet#b60a24a6`. Stickerset and stickers inside it
See https://core.telegram.org/constructor/messages.stickerSet for reference.
func (*MessagesStickerSet) Decode ¶
func (s *MessagesStickerSet) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStickerSet) Encode ¶
func (s *MessagesStickerSet) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStickerSet) String ¶ added in v0.12.0
func (s *MessagesStickerSet) String() string
String implements fmt.Stringer.
type MessagesStickerSetInstallResultArchive ¶
type MessagesStickerSetInstallResultArchive struct {
// Archived stickersets
Sets []StickerSetCoveredClass
}
MessagesStickerSetInstallResultArchive represents TL type `messages.stickerSetInstallResultArchive#35e410a8`. The stickerset was installed, but since there are too many stickersets some were archived
See https://core.telegram.org/constructor/messages.stickerSetInstallResultArchive for reference.
func (*MessagesStickerSetInstallResultArchive) Decode ¶
func (s *MessagesStickerSetInstallResultArchive) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStickerSetInstallResultArchive) Encode ¶
func (s *MessagesStickerSetInstallResultArchive) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStickerSetInstallResultArchive) String ¶ added in v0.12.0
func (s *MessagesStickerSetInstallResultArchive) String() string
String implements fmt.Stringer.
type MessagesStickerSetInstallResultBox ¶
type MessagesStickerSetInstallResultBox struct {
StickerSetInstallResult MessagesStickerSetInstallResultClass
}
MessagesStickerSetInstallResult boxes the MessagesStickerSetInstallResultClass providing a helper.
type MessagesStickerSetInstallResultClass ¶
type MessagesStickerSetInstallResultClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesStickerSetInstallResultClass represents messages.StickerSetInstallResult generic type.
See https://core.telegram.org/type/messages.StickerSetInstallResult for reference.
Example:
g, err := DecodeMessagesStickerSetInstallResult(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesStickerSetInstallResultSuccess: // messages.stickerSetInstallResultSuccess#38641628
case *MessagesStickerSetInstallResultArchive: // messages.stickerSetInstallResultArchive#35e410a8
default: panic(v)
}
func DecodeMessagesStickerSetInstallResult ¶
func DecodeMessagesStickerSetInstallResult(buf *bin.Buffer) (MessagesStickerSetInstallResultClass, error)
DecodeMessagesStickerSetInstallResult implements binary de-serialization for MessagesStickerSetInstallResultClass.
type MessagesStickerSetInstallResultSuccess ¶
type MessagesStickerSetInstallResultSuccess struct {
}
MessagesStickerSetInstallResultSuccess represents TL type `messages.stickerSetInstallResultSuccess#38641628`. The stickerset was installed successfully
See https://core.telegram.org/constructor/messages.stickerSetInstallResultSuccess for reference.
func (*MessagesStickerSetInstallResultSuccess) Decode ¶
func (s *MessagesStickerSetInstallResultSuccess) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStickerSetInstallResultSuccess) Encode ¶
func (s *MessagesStickerSetInstallResultSuccess) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStickerSetInstallResultSuccess) String ¶ added in v0.12.0
func (s *MessagesStickerSetInstallResultSuccess) String() string
String implements fmt.Stringer.
type MessagesStickers ¶
type MessagesStickers struct {
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Stickers
Stickers []DocumentClass
}
MessagesStickers represents TL type `messages.stickers#e4599bbd`. Found stickers
See https://core.telegram.org/constructor/messages.stickers for reference.
func (*MessagesStickers) Decode ¶
func (s *MessagesStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStickers) Encode ¶
func (s *MessagesStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStickers) String ¶ added in v0.12.0
func (s *MessagesStickers) String() string
String implements fmt.Stringer.
type MessagesStickersBox ¶
type MessagesStickersBox struct {
Stickers MessagesStickersClass
}
MessagesStickers boxes the MessagesStickersClass providing a helper.
type MessagesStickersClass ¶
type MessagesStickersClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
MessagesStickersClass represents messages.Stickers generic type.
See https://core.telegram.org/type/messages.Stickers for reference.
Example:
g, err := DecodeMessagesStickers(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *MessagesStickersNotModified: // messages.stickersNotModified#f1749a22
case *MessagesStickers: // messages.stickers#e4599bbd
default: panic(v)
}
func DecodeMessagesStickers ¶
func DecodeMessagesStickers(buf *bin.Buffer) (MessagesStickersClass, error)
DecodeMessagesStickers implements binary de-serialization for MessagesStickersClass.
type MessagesStickersNotModified ¶
type MessagesStickersNotModified struct {
}
MessagesStickersNotModified represents TL type `messages.stickersNotModified#f1749a22`. No new stickers were found for the given query
See https://core.telegram.org/constructor/messages.stickersNotModified for reference.
func (*MessagesStickersNotModified) Decode ¶
func (s *MessagesStickersNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesStickersNotModified) Encode ¶
func (s *MessagesStickersNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesStickersNotModified) String ¶ added in v0.12.0
func (s *MessagesStickersNotModified) String() string
String implements fmt.Stringer.
type MessagesToggleDialogPinRequest ¶
type MessagesToggleDialogPinRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to pin or unpin the dialog
Pinned bool
// The dialog to pin
Peer InputDialogPeerClass
}
MessagesToggleDialogPinRequest represents TL type `messages.toggleDialogPin#a731e257`. Pin/unpin a dialog
See https://core.telegram.org/method/messages.toggleDialogPin for reference.
func (*MessagesToggleDialogPinRequest) Decode ¶
func (t *MessagesToggleDialogPinRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesToggleDialogPinRequest) Encode ¶
func (t *MessagesToggleDialogPinRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesToggleDialogPinRequest) SetPinned ¶
func (t *MessagesToggleDialogPinRequest) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*MessagesToggleDialogPinRequest) String ¶ added in v0.12.0
func (t *MessagesToggleDialogPinRequest) String() string
String implements fmt.Stringer.
type MessagesToggleStickerSetsRequest ¶
type MessagesToggleStickerSetsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Uninstall the specified stickersets
Uninstall bool
// Archive the specified stickersets
Archive bool
// Unarchive the specified stickersets
Unarchive bool
// Stickersets to act upon
Stickersets []InputStickerSetClass
}
MessagesToggleStickerSetsRequest represents TL type `messages.toggleStickerSets#b5052fea`. Apply changes to multiple stickersets
See https://core.telegram.org/method/messages.toggleStickerSets for reference.
func (*MessagesToggleStickerSetsRequest) Decode ¶
func (t *MessagesToggleStickerSetsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesToggleStickerSetsRequest) Encode ¶
func (t *MessagesToggleStickerSetsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesToggleStickerSetsRequest) SetArchive ¶
func (t *MessagesToggleStickerSetsRequest) SetArchive(value bool)
SetArchive sets value of Archive conditional field.
func (*MessagesToggleStickerSetsRequest) SetUnarchive ¶
func (t *MessagesToggleStickerSetsRequest) SetUnarchive(value bool)
SetUnarchive sets value of Unarchive conditional field.
func (*MessagesToggleStickerSetsRequest) SetUninstall ¶
func (t *MessagesToggleStickerSetsRequest) SetUninstall(value bool)
SetUninstall sets value of Uninstall conditional field.
func (*MessagesToggleStickerSetsRequest) String ¶ added in v0.12.0
func (t *MessagesToggleStickerSetsRequest) String() string
String implements fmt.Stringer.
type MessagesUninstallStickerSetRequest ¶
type MessagesUninstallStickerSetRequest struct {
// The stickerset to uninstall
Stickerset InputStickerSetClass
}
MessagesUninstallStickerSetRequest represents TL type `messages.uninstallStickerSet#f96e55de`. Uninstall a stickerset
See https://core.telegram.org/method/messages.uninstallStickerSet for reference.
func (*MessagesUninstallStickerSetRequest) Decode ¶
func (u *MessagesUninstallStickerSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUninstallStickerSetRequest) Encode ¶
func (u *MessagesUninstallStickerSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUninstallStickerSetRequest) String ¶ added in v0.12.0
func (u *MessagesUninstallStickerSetRequest) String() string
String implements fmt.Stringer.
type MessagesUnpinAllMessagesRequest ¶
type MessagesUnpinAllMessagesRequest struct {
// Chat where to unpin
Peer InputPeerClass
}
MessagesUnpinAllMessagesRequest represents TL type `messages.unpinAllMessages#f025bc8b`. Unpin¹ all pinned messages
Links:
See https://core.telegram.org/method/messages.unpinAllMessages for reference.
func (*MessagesUnpinAllMessagesRequest) Decode ¶
func (u *MessagesUnpinAllMessagesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUnpinAllMessagesRequest) Encode ¶
func (u *MessagesUnpinAllMessagesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUnpinAllMessagesRequest) String ¶ added in v0.12.0
func (u *MessagesUnpinAllMessagesRequest) String() string
String implements fmt.Stringer.
type MessagesUpdateDialogFilterRequest ¶
type MessagesUpdateDialogFilterRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Folder¹ ID
//
// Links:
// 1) https://core.telegram.org/api/folders
ID int
// Folder¹ info
//
// Links:
// 1) https://core.telegram.org/api/folders
//
// Use SetFilter and GetFilter helpers.
Filter DialogFilter
}
MessagesUpdateDialogFilterRequest represents TL type `messages.updateDialogFilter#1ad4a04a`. Update folder¹
Links:
See https://core.telegram.org/method/messages.updateDialogFilter for reference.
func (*MessagesUpdateDialogFilterRequest) Decode ¶
func (u *MessagesUpdateDialogFilterRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUpdateDialogFilterRequest) Encode ¶
func (u *MessagesUpdateDialogFilterRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUpdateDialogFilterRequest) GetFilter ¶
func (u *MessagesUpdateDialogFilterRequest) GetFilter() (value DialogFilter, ok bool)
GetFilter returns value of Filter conditional field and boolean which is true if field was set.
func (*MessagesUpdateDialogFilterRequest) SetFilter ¶
func (u *MessagesUpdateDialogFilterRequest) SetFilter(value DialogFilter)
SetFilter sets value of Filter conditional field.
func (*MessagesUpdateDialogFilterRequest) String ¶ added in v0.12.0
func (u *MessagesUpdateDialogFilterRequest) String() string
String implements fmt.Stringer.
type MessagesUpdateDialogFiltersOrderRequest ¶
type MessagesUpdateDialogFiltersOrderRequest struct {
// New folder¹ order
//
// Links:
// 1) https://core.telegram.org/api/folders
Order []int
}
MessagesUpdateDialogFiltersOrderRequest represents TL type `messages.updateDialogFiltersOrder#c563c1e4`. Reorder folders¹
Links:
See https://core.telegram.org/method/messages.updateDialogFiltersOrder for reference.
func (*MessagesUpdateDialogFiltersOrderRequest) Decode ¶
func (u *MessagesUpdateDialogFiltersOrderRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUpdateDialogFiltersOrderRequest) Encode ¶
func (u *MessagesUpdateDialogFiltersOrderRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUpdateDialogFiltersOrderRequest) String ¶ added in v0.12.0
func (u *MessagesUpdateDialogFiltersOrderRequest) String() string
String implements fmt.Stringer.
type MessagesUpdatePinnedMessageRequest ¶
type MessagesUpdatePinnedMessageRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Pin the message silently, without triggering a notification
Silent bool
// Whether the message should unpinned or pinned
Unpin bool
// Whether the message should only be pinned on the local side of a one-to-one chat
PmOneside bool
// The peer where to pin the message
Peer InputPeerClass
// The message to pin or unpin
ID int
}
MessagesUpdatePinnedMessageRequest represents TL type `messages.updatePinnedMessage#d2aaf7ec`. Pin a message
See https://core.telegram.org/method/messages.updatePinnedMessage for reference.
func (*MessagesUpdatePinnedMessageRequest) Decode ¶
func (u *MessagesUpdatePinnedMessageRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUpdatePinnedMessageRequest) Encode ¶
func (u *MessagesUpdatePinnedMessageRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUpdatePinnedMessageRequest) SetPmOneside ¶
func (u *MessagesUpdatePinnedMessageRequest) SetPmOneside(value bool)
SetPmOneside sets value of PmOneside conditional field.
func (*MessagesUpdatePinnedMessageRequest) SetSilent ¶
func (u *MessagesUpdatePinnedMessageRequest) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*MessagesUpdatePinnedMessageRequest) SetUnpin ¶
func (u *MessagesUpdatePinnedMessageRequest) SetUnpin(value bool)
SetUnpin sets value of Unpin conditional field.
func (*MessagesUpdatePinnedMessageRequest) String ¶ added in v0.12.0
func (u *MessagesUpdatePinnedMessageRequest) String() string
String implements fmt.Stringer.
type MessagesUploadEncryptedFileRequest ¶
type MessagesUploadEncryptedFileRequest struct {
// The secret chat to associate the file to
Peer InputEncryptedChat
// The file
File InputEncryptedFileClass
}
MessagesUploadEncryptedFileRequest represents TL type `messages.uploadEncryptedFile#5057c497`. Upload encrypted file and associate it to a secret chat
See https://core.telegram.org/method/messages.uploadEncryptedFile for reference.
func (*MessagesUploadEncryptedFileRequest) Decode ¶
func (u *MessagesUploadEncryptedFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUploadEncryptedFileRequest) Encode ¶
func (u *MessagesUploadEncryptedFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUploadEncryptedFileRequest) String ¶ added in v0.12.0
func (u *MessagesUploadEncryptedFileRequest) String() string
String implements fmt.Stringer.
type MessagesUploadMediaRequest ¶
type MessagesUploadMediaRequest struct {
// The chat, can be an inputPeerEmpty¹ for bots
//
// Links:
// 1) https://core.telegram.org/constructor/inputPeerEmpty
Peer InputPeerClass
// File uploaded in chunks as described in files »¹
//
// Links:
// 1) https://core.telegram.org/api/files
Media InputMediaClass
}
MessagesUploadMediaRequest represents TL type `messages.uploadMedia#519bc2b1`. Upload a file and associate it to a chat (without actually sending it to the chat)
See https://core.telegram.org/method/messages.uploadMedia for reference.
func (*MessagesUploadMediaRequest) Decode ¶
func (u *MessagesUploadMediaRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesUploadMediaRequest) Encode ¶
func (u *MessagesUploadMediaRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesUploadMediaRequest) String ¶ added in v0.12.0
func (u *MessagesUploadMediaRequest) String() string
String implements fmt.Stringer.
type MessagesVotesList ¶
type MessagesVotesList struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Total number of votes for all options (or only for the chosen option, if provided to messages.getPollVotes¹)
//
// Links:
// 1) https://core.telegram.org/method/messages.getPollVotes
Count int
// Vote info for each user
Votes []MessageUserVoteClass
// Info about users that voted in the poll
Users []UserClass
// Offset to use with the next messages.getPollVotes¹ request, empty string if no more results are available.
//
// Links:
// 1) https://core.telegram.org/method/messages.getPollVotes
//
// Use SetNextOffset and GetNextOffset helpers.
NextOffset string
}
MessagesVotesList represents TL type `messages.votesList#823f649`. How users voted in a poll
See https://core.telegram.org/constructor/messages.votesList for reference.
func (*MessagesVotesList) Decode ¶
func (v *MessagesVotesList) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MessagesVotesList) Encode ¶
func (v *MessagesVotesList) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MessagesVotesList) GetNextOffset ¶
func (v *MessagesVotesList) GetNextOffset() (value string, ok bool)
GetNextOffset returns value of NextOffset conditional field and boolean which is true if field was set.
func (*MessagesVotesList) SetNextOffset ¶
func (v *MessagesVotesList) SetNextOffset(value string)
SetNextOffset sets value of NextOffset conditional field.
func (*MessagesVotesList) String ¶ added in v0.12.0
func (v *MessagesVotesList) String() string
String implements fmt.Stringer.
type NearestDc ¶
type NearestDc struct {
// Country code determined by geo-ip
Country string
// Number of current data centre
ThisDC int
// Number of nearest data centre
NearestDC int
}
NearestDc represents TL type `nearestDc#8e1a1775`. Nearest data centre, according to geo-ip.
See https://core.telegram.org/constructor/nearestDc for reference.
type NewChannelMessageHandler ¶ added in v0.9.0
type NewChannelMessageHandler func(ctx UpdateContext, update *UpdateNewChannelMessage) error
NewChannelMessageHandler is a NewChannelMessage event handler.
type NewEncryptedMessageHandler ¶ added in v0.9.0
type NewEncryptedMessageHandler func(ctx UpdateContext, update *UpdateNewEncryptedMessage) error
NewEncryptedMessageHandler is a NewEncryptedMessage event handler.
type NewMessageHandler ¶ added in v0.9.0
type NewMessageHandler func(ctx UpdateContext, update *UpdateNewMessage) error
NewMessageHandler is a NewMessage event handler.
type NewScheduledMessageHandler ¶ added in v0.9.0
type NewScheduledMessageHandler func(ctx UpdateContext, update *UpdateNewScheduledMessage) error
NewScheduledMessageHandler is a NewScheduledMessage event handler.
type NewStickerSetHandler ¶ added in v0.9.0
type NewStickerSetHandler func(ctx UpdateContext, update *UpdateNewStickerSet) error
NewStickerSetHandler is a NewStickerSet event handler.
type NotifyBroadcasts ¶
type NotifyBroadcasts struct {
}
NotifyBroadcasts represents TL type `notifyBroadcasts#d612e8ef`. Channel notification settings
See https://core.telegram.org/constructor/notifyBroadcasts for reference.
func (*NotifyBroadcasts) Decode ¶
func (n *NotifyBroadcasts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*NotifyBroadcasts) Encode ¶
func (n *NotifyBroadcasts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*NotifyBroadcasts) String ¶ added in v0.12.0
func (n *NotifyBroadcasts) String() string
String implements fmt.Stringer.
type NotifyChats ¶
type NotifyChats struct {
}
NotifyChats represents TL type `notifyChats#c007cec3`. Notifications generated by all groups.
See https://core.telegram.org/constructor/notifyChats for reference.
func (*NotifyChats) Decode ¶
func (n *NotifyChats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*NotifyChats) Encode ¶
func (n *NotifyChats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*NotifyChats) String ¶ added in v0.12.0
func (n *NotifyChats) String() string
String implements fmt.Stringer.
type NotifyPeer ¶
type NotifyPeer struct {
// user or group
Peer PeerClass
}
NotifyPeer represents TL type `notifyPeer#9fd40bd8`. Notifications generated by a certain user or group.
See https://core.telegram.org/constructor/notifyPeer for reference.
func (*NotifyPeer) Decode ¶
func (n *NotifyPeer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*NotifyPeer) Encode ¶
func (n *NotifyPeer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*NotifyPeer) String ¶ added in v0.12.0
func (n *NotifyPeer) String() string
String implements fmt.Stringer.
type NotifyPeerBox ¶
type NotifyPeerBox struct {
NotifyPeer NotifyPeerClass
}
NotifyPeer boxes the NotifyPeerClass providing a helper.
type NotifyPeerClass ¶
type NotifyPeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
NotifyPeerClass represents NotifyPeer generic type.
See https://core.telegram.org/type/NotifyPeer for reference.
Example:
g, err := DecodeNotifyPeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *NotifyPeer: // notifyPeer#9fd40bd8
case *NotifyUsers: // notifyUsers#b4c83b4c
case *NotifyChats: // notifyChats#c007cec3
case *NotifyBroadcasts: // notifyBroadcasts#d612e8ef
default: panic(v)
}
func DecodeNotifyPeer ¶
func DecodeNotifyPeer(buf *bin.Buffer) (NotifyPeerClass, error)
DecodeNotifyPeer implements binary de-serialization for NotifyPeerClass.
type NotifySettingsHandler ¶ added in v0.9.0
type NotifySettingsHandler func(ctx UpdateContext, update *UpdateNotifySettings) error
NotifySettingsHandler is a NotifySettings event handler.
type NotifyUsers ¶
type NotifyUsers struct {
}
NotifyUsers represents TL type `notifyUsers#b4c83b4c`. Notifications generated by all users.
See https://core.telegram.org/constructor/notifyUsers for reference.
func (*NotifyUsers) Decode ¶
func (n *NotifyUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*NotifyUsers) Encode ¶
func (n *NotifyUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*NotifyUsers) String ¶ added in v0.12.0
func (n *NotifyUsers) String() string
String implements fmt.Stringer.
type Null ¶
type Null struct {
}
Null represents TL type `null#56730bcc`. Corresponds to an arbitrary empty object.
See https://core.telegram.org/constructor/null for reference.
type Page ¶
type Page struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Indicates that not full page preview is available to the client and it will need to fetch full Instant View from the server using messages.getWebPagePreview¹.
//
// Links:
// 1) https://core.telegram.org/method/messages.getWebPagePreview
Part bool
// Whether the page contains RTL text
Rtl bool
// Whether this is an IV v2¹ page
//
// Links:
// 1) https://instantview.telegram.org/docs#what-39s-new-in-2-0
V2 bool
// Original page HTTP URL
URL string
// Page elements (like with HTML elements, only as TL constructors)
Blocks []PageBlockClass
// Photos in page
Photos []PhotoClass
// Media in page
Documents []DocumentClass
// Viewcount
//
// Use SetViews and GetViews helpers.
Views int
}
Page represents TL type `page#98657f0d`. Instant view¹ page
Links:
See https://core.telegram.org/constructor/page for reference.
func (*Page) GetViews ¶
GetViews returns value of Views conditional field and boolean which is true if field was set.
type PageBlockAnchor ¶
type PageBlockAnchor struct {
// Name of target section
Name string
}
PageBlockAnchor represents TL type `pageBlockAnchor#ce0d37b0`. Link to section within the page itself (like <a href="#target">anchor</a>)
See https://core.telegram.org/constructor/pageBlockAnchor for reference.
func (*PageBlockAnchor) Decode ¶
func (p *PageBlockAnchor) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockAnchor) Encode ¶
func (p *PageBlockAnchor) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockAnchor) String ¶ added in v0.12.0
func (p *PageBlockAnchor) String() string
String implements fmt.Stringer.
type PageBlockAudio ¶
type PageBlockAudio struct {
// Audio ID (to be fetched from the container page¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/page
AudioID int64
// Audio caption
Caption PageCaption
}
PageBlockAudio represents TL type `pageBlockAudio#804361ea`. Audio
See https://core.telegram.org/constructor/pageBlockAudio for reference.
func (*PageBlockAudio) Decode ¶
func (p *PageBlockAudio) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockAudio) Encode ¶
func (p *PageBlockAudio) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockAudio) String ¶ added in v0.12.0
func (p *PageBlockAudio) String() string
String implements fmt.Stringer.
type PageBlockAuthorDate ¶
type PageBlockAuthorDate struct {
// Author name
Author RichTextClass
// Date of pubblication
PublishedDate int
}
PageBlockAuthorDate represents TL type `pageBlockAuthorDate#baafe5e0`. Author and date of creation of article
See https://core.telegram.org/constructor/pageBlockAuthorDate for reference.
func (*PageBlockAuthorDate) Decode ¶
func (p *PageBlockAuthorDate) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockAuthorDate) Encode ¶
func (p *PageBlockAuthorDate) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockAuthorDate) String ¶ added in v0.12.0
func (p *PageBlockAuthorDate) String() string
String implements fmt.Stringer.
type PageBlockBlockquote ¶
type PageBlockBlockquote struct {
// Quote contents
Text RichTextClass
// Caption
Caption RichTextClass
}
PageBlockBlockquote represents TL type `pageBlockBlockquote#263d7c26`. Quote (equivalent to the HTML <blockquote>)
See https://core.telegram.org/constructor/pageBlockBlockquote for reference.
func (*PageBlockBlockquote) Decode ¶
func (p *PageBlockBlockquote) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockBlockquote) Encode ¶
func (p *PageBlockBlockquote) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockBlockquote) String ¶ added in v0.12.0
func (p *PageBlockBlockquote) String() string
String implements fmt.Stringer.
type PageBlockBox ¶
type PageBlockBox struct {
PageBlock PageBlockClass
}
PageBlock boxes the PageBlockClass providing a helper.
type PageBlockChannel ¶
type PageBlockChannel struct {
// The channel/supergroup/chat
Channel ChatClass
}
PageBlockChannel represents TL type `pageBlockChannel#ef1751b5`. Reference to a telegram channel
See https://core.telegram.org/constructor/pageBlockChannel for reference.
func (*PageBlockChannel) Decode ¶
func (p *PageBlockChannel) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockChannel) Encode ¶
func (p *PageBlockChannel) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockChannel) String ¶ added in v0.12.0
func (p *PageBlockChannel) String() string
String implements fmt.Stringer.
type PageBlockClass ¶
type PageBlockClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PageBlockClass represents PageBlock generic type.
See https://core.telegram.org/type/PageBlock for reference.
Example:
g, err := DecodePageBlock(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PageBlockUnsupported: // pageBlockUnsupported#13567e8a
case *PageBlockTitle: // pageBlockTitle#70abc3fd
case *PageBlockSubtitle: // pageBlockSubtitle#8ffa9a1f
case *PageBlockAuthorDate: // pageBlockAuthorDate#baafe5e0
case *PageBlockHeader: // pageBlockHeader#bfd064ec
case *PageBlockSubheader: // pageBlockSubheader#f12bb6e1
case *PageBlockParagraph: // pageBlockParagraph#467a0766
case *PageBlockPreformatted: // pageBlockPreformatted#c070d93e
case *PageBlockFooter: // pageBlockFooter#48870999
case *PageBlockDivider: // pageBlockDivider#db20b188
case *PageBlockAnchor: // pageBlockAnchor#ce0d37b0
case *PageBlockList: // pageBlockList#e4e88011
case *PageBlockBlockquote: // pageBlockBlockquote#263d7c26
case *PageBlockPullquote: // pageBlockPullquote#4f4456d3
case *PageBlockPhoto: // pageBlockPhoto#1759c560
case *PageBlockVideo: // pageBlockVideo#7c8fe7b6
case *PageBlockCover: // pageBlockCover#39f23300
case *PageBlockEmbed: // pageBlockEmbed#a8718dc5
case *PageBlockEmbedPost: // pageBlockEmbedPost#f259a80b
case *PageBlockCollage: // pageBlockCollage#65a0fa4d
case *PageBlockSlideshow: // pageBlockSlideshow#31f9590
case *PageBlockChannel: // pageBlockChannel#ef1751b5
case *PageBlockAudio: // pageBlockAudio#804361ea
case *PageBlockKicker: // pageBlockKicker#1e148390
case *PageBlockTable: // pageBlockTable#bf4dea82
case *PageBlockOrderedList: // pageBlockOrderedList#9a8ae1e1
case *PageBlockDetails: // pageBlockDetails#76768bed
case *PageBlockRelatedArticles: // pageBlockRelatedArticles#16115a96
case *PageBlockMap: // pageBlockMap#a44f3ef6
default: panic(v)
}
func DecodePageBlock ¶
func DecodePageBlock(buf *bin.Buffer) (PageBlockClass, error)
DecodePageBlock implements binary de-serialization for PageBlockClass.
type PageBlockCollage ¶
type PageBlockCollage struct {
// Media elements
Items []PageBlockClass
// Caption
Caption PageCaption
}
PageBlockCollage represents TL type `pageBlockCollage#65a0fa4d`. Collage of media
See https://core.telegram.org/constructor/pageBlockCollage for reference.
func (*PageBlockCollage) Decode ¶
func (p *PageBlockCollage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockCollage) Encode ¶
func (p *PageBlockCollage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockCollage) String ¶ added in v0.12.0
func (p *PageBlockCollage) String() string
String implements fmt.Stringer.
type PageBlockCover ¶
type PageBlockCover struct {
// Cover
Cover PageBlockClass
}
PageBlockCover represents TL type `pageBlockCover#39f23300`. A page cover
See https://core.telegram.org/constructor/pageBlockCover for reference.
func (*PageBlockCover) Decode ¶
func (p *PageBlockCover) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockCover) Encode ¶
func (p *PageBlockCover) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockCover) String ¶ added in v0.12.0
func (p *PageBlockCover) String() string
String implements fmt.Stringer.
type PageBlockDetails ¶
type PageBlockDetails struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the block is open by default
Open bool
// Block contents
Blocks []PageBlockClass
// Always visible heading for the block
Title RichTextClass
}
PageBlockDetails represents TL type `pageBlockDetails#76768bed`. A collapsible details block
See https://core.telegram.org/constructor/pageBlockDetails for reference.
func (*PageBlockDetails) Decode ¶
func (p *PageBlockDetails) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockDetails) Encode ¶
func (p *PageBlockDetails) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockDetails) SetOpen ¶
func (p *PageBlockDetails) SetOpen(value bool)
SetOpen sets value of Open conditional field.
func (*PageBlockDetails) String ¶ added in v0.12.0
func (p *PageBlockDetails) String() string
String implements fmt.Stringer.
type PageBlockDivider ¶
type PageBlockDivider struct {
}
PageBlockDivider represents TL type `pageBlockDivider#db20b188`. An empty block separating a page
See https://core.telegram.org/constructor/pageBlockDivider for reference.
func (*PageBlockDivider) Decode ¶
func (p *PageBlockDivider) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockDivider) Encode ¶
func (p *PageBlockDivider) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockDivider) String ¶ added in v0.12.0
func (p *PageBlockDivider) String() string
String implements fmt.Stringer.
type PageBlockEmbed ¶
type PageBlockEmbed struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the block should be full width
FullWidth bool
// Whether scrolling should be allowed
AllowScrolling bool
// Web page URL, if available
//
// Use SetURL and GetURL helpers.
URL string
// HTML-markup of the embedded page
//
// Use SetHTML and GetHTML helpers.
HTML string
// Poster photo, if available
//
// Use SetPosterPhotoID and GetPosterPhotoID helpers.
PosterPhotoID int64
// Block width, if known
//
// Use SetW and GetW helpers.
W int
// Block height, if known
//
// Use SetH and GetH helpers.
H int
// Caption
Caption PageCaption
}
PageBlockEmbed represents TL type `pageBlockEmbed#a8718dc5`. An embedded webpage
See https://core.telegram.org/constructor/pageBlockEmbed for reference.
func (*PageBlockEmbed) Decode ¶
func (p *PageBlockEmbed) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockEmbed) Encode ¶
func (p *PageBlockEmbed) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockEmbed) GetH ¶
func (p *PageBlockEmbed) GetH() (value int, ok bool)
GetH returns value of H conditional field and boolean which is true if field was set.
func (*PageBlockEmbed) GetHTML ¶
func (p *PageBlockEmbed) GetHTML() (value string, ok bool)
GetHTML returns value of HTML conditional field and boolean which is true if field was set.
func (*PageBlockEmbed) GetPosterPhotoID ¶
func (p *PageBlockEmbed) GetPosterPhotoID() (value int64, ok bool)
GetPosterPhotoID returns value of PosterPhotoID conditional field and boolean which is true if field was set.
func (*PageBlockEmbed) GetURL ¶
func (p *PageBlockEmbed) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*PageBlockEmbed) GetW ¶
func (p *PageBlockEmbed) GetW() (value int, ok bool)
GetW returns value of W conditional field and boolean which is true if field was set.
func (*PageBlockEmbed) SetAllowScrolling ¶
func (p *PageBlockEmbed) SetAllowScrolling(value bool)
SetAllowScrolling sets value of AllowScrolling conditional field.
func (*PageBlockEmbed) SetFullWidth ¶
func (p *PageBlockEmbed) SetFullWidth(value bool)
SetFullWidth sets value of FullWidth conditional field.
func (*PageBlockEmbed) SetH ¶
func (p *PageBlockEmbed) SetH(value int)
SetH sets value of H conditional field.
func (*PageBlockEmbed) SetHTML ¶
func (p *PageBlockEmbed) SetHTML(value string)
SetHTML sets value of HTML conditional field.
func (*PageBlockEmbed) SetPosterPhotoID ¶
func (p *PageBlockEmbed) SetPosterPhotoID(value int64)
SetPosterPhotoID sets value of PosterPhotoID conditional field.
func (*PageBlockEmbed) SetURL ¶
func (p *PageBlockEmbed) SetURL(value string)
SetURL sets value of URL conditional field.
func (*PageBlockEmbed) SetW ¶
func (p *PageBlockEmbed) SetW(value int)
SetW sets value of W conditional field.
func (*PageBlockEmbed) String ¶ added in v0.12.0
func (p *PageBlockEmbed) String() string
String implements fmt.Stringer.
type PageBlockEmbedPost ¶
type PageBlockEmbedPost struct {
// Web page URL
URL string
// ID of generated webpage preview
WebpageID int64
// ID of the author's photo
AuthorPhotoID int64
// Author name
Author string
// Creation date
Date int
// Post contents
Blocks []PageBlockClass
// Caption
Caption PageCaption
}
PageBlockEmbedPost represents TL type `pageBlockEmbedPost#f259a80b`. An embedded post
See https://core.telegram.org/constructor/pageBlockEmbedPost for reference.
func (*PageBlockEmbedPost) Decode ¶
func (p *PageBlockEmbedPost) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockEmbedPost) Encode ¶
func (p *PageBlockEmbedPost) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockEmbedPost) String ¶ added in v0.12.0
func (p *PageBlockEmbedPost) String() string
String implements fmt.Stringer.
type PageBlockFooter ¶
type PageBlockFooter struct {
Text RichTextClass
}
PageBlockFooter represents TL type `pageBlockFooter#48870999`. Page footer
See https://core.telegram.org/constructor/pageBlockFooter for reference.
func (*PageBlockFooter) Decode ¶
func (p *PageBlockFooter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockFooter) Encode ¶
func (p *PageBlockFooter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockFooter) String ¶ added in v0.12.0
func (p *PageBlockFooter) String() string
String implements fmt.Stringer.
type PageBlockHeader ¶
type PageBlockHeader struct {
// Contents
Text RichTextClass
}
PageBlockHeader represents TL type `pageBlockHeader#bfd064ec`. Page header
See https://core.telegram.org/constructor/pageBlockHeader for reference.
func (*PageBlockHeader) Decode ¶
func (p *PageBlockHeader) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockHeader) Encode ¶
func (p *PageBlockHeader) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockHeader) String ¶ added in v0.12.0
func (p *PageBlockHeader) String() string
String implements fmt.Stringer.
type PageBlockKicker ¶
type PageBlockKicker struct {
// Contents
Text RichTextClass
}
PageBlockKicker represents TL type `pageBlockKicker#1e148390`. Kicker
See https://core.telegram.org/constructor/pageBlockKicker for reference.
func (*PageBlockKicker) Decode ¶
func (p *PageBlockKicker) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockKicker) Encode ¶
func (p *PageBlockKicker) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockKicker) String ¶ added in v0.12.0
func (p *PageBlockKicker) String() string
String implements fmt.Stringer.
type PageBlockList ¶
type PageBlockList struct {
// List of blocks in an IV page
Items []PageListItemClass
}
PageBlockList represents TL type `pageBlockList#e4e88011`. Unordered list of IV blocks
See https://core.telegram.org/constructor/pageBlockList for reference.
func (*PageBlockList) Decode ¶
func (p *PageBlockList) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockList) Encode ¶
func (p *PageBlockList) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockList) String ¶ added in v0.12.0
func (p *PageBlockList) String() string
String implements fmt.Stringer.
type PageBlockMap ¶
type PageBlockMap struct {
// Location of the map center
Geo GeoPointClass
// Map zoom level; 13-20
Zoom int
// Map width in pixels before applying scale; 16-102
W int
// Map height in pixels before applying scale; 16-1024
H int
// Caption
Caption PageCaption
}
PageBlockMap represents TL type `pageBlockMap#a44f3ef6`. A map
See https://core.telegram.org/constructor/pageBlockMap for reference.
func (*PageBlockMap) Decode ¶
func (p *PageBlockMap) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockMap) Encode ¶
func (p *PageBlockMap) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockMap) String ¶ added in v0.12.0
func (p *PageBlockMap) String() string
String implements fmt.Stringer.
type PageBlockOrderedList ¶
type PageBlockOrderedList struct {
// List items
Items []PageListOrderedItemClass
}
PageBlockOrderedList represents TL type `pageBlockOrderedList#9a8ae1e1`. Ordered list of IV blocks
See https://core.telegram.org/constructor/pageBlockOrderedList for reference.
func (*PageBlockOrderedList) Decode ¶
func (p *PageBlockOrderedList) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockOrderedList) Encode ¶
func (p *PageBlockOrderedList) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockOrderedList) String ¶ added in v0.12.0
func (p *PageBlockOrderedList) String() string
String implements fmt.Stringer.
type PageBlockParagraph ¶
type PageBlockParagraph struct {
// Text
Text RichTextClass
}
PageBlockParagraph represents TL type `pageBlockParagraph#467a0766`. A paragraph
See https://core.telegram.org/constructor/pageBlockParagraph for reference.
func (*PageBlockParagraph) Decode ¶
func (p *PageBlockParagraph) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockParagraph) Encode ¶
func (p *PageBlockParagraph) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockParagraph) String ¶ added in v0.12.0
func (p *PageBlockParagraph) String() string
String implements fmt.Stringer.
type PageBlockPhoto ¶
type PageBlockPhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Photo ID
PhotoID int64
// Caption
Caption PageCaption
// HTTP URL of page the photo leads to when clicked
//
// Use SetURL and GetURL helpers.
URL string
// ID of preview of the page the photo leads to when clicked
//
// Use SetWebpageID and GetWebpageID helpers.
WebpageID int64
}
PageBlockPhoto represents TL type `pageBlockPhoto#1759c560`. A photo
See https://core.telegram.org/constructor/pageBlockPhoto for reference.
func (*PageBlockPhoto) Decode ¶
func (p *PageBlockPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockPhoto) Encode ¶
func (p *PageBlockPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockPhoto) GetURL ¶
func (p *PageBlockPhoto) GetURL() (value string, ok bool)
GetURL returns value of URL conditional field and boolean which is true if field was set.
func (*PageBlockPhoto) GetWebpageID ¶
func (p *PageBlockPhoto) GetWebpageID() (value int64, ok bool)
GetWebpageID returns value of WebpageID conditional field and boolean which is true if field was set.
func (*PageBlockPhoto) SetURL ¶
func (p *PageBlockPhoto) SetURL(value string)
SetURL sets value of URL conditional field.
func (*PageBlockPhoto) SetWebpageID ¶
func (p *PageBlockPhoto) SetWebpageID(value int64)
SetWebpageID sets value of WebpageID conditional field.
func (*PageBlockPhoto) String ¶ added in v0.12.0
func (p *PageBlockPhoto) String() string
String implements fmt.Stringer.
type PageBlockPreformatted ¶
type PageBlockPreformatted struct {
// Text
Text RichTextClass
// Programming language of preformatted text
Language string
}
PageBlockPreformatted represents TL type `pageBlockPreformatted#c070d93e`. Preformatted (<pre> text)
See https://core.telegram.org/constructor/pageBlockPreformatted for reference.
func (*PageBlockPreformatted) Decode ¶
func (p *PageBlockPreformatted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockPreformatted) Encode ¶
func (p *PageBlockPreformatted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockPreformatted) String ¶ added in v0.12.0
func (p *PageBlockPreformatted) String() string
String implements fmt.Stringer.
type PageBlockPullquote ¶
type PageBlockPullquote struct {
// Text
Text RichTextClass
// Caption
Caption RichTextClass
}
PageBlockPullquote represents TL type `pageBlockPullquote#4f4456d3`. Pullquote
See https://core.telegram.org/constructor/pageBlockPullquote for reference.
func (*PageBlockPullquote) Decode ¶
func (p *PageBlockPullquote) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockPullquote) Encode ¶
func (p *PageBlockPullquote) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockPullquote) String ¶ added in v0.12.0
func (p *PageBlockPullquote) String() string
String implements fmt.Stringer.
type PageBlockRelatedArticles ¶
type PageBlockRelatedArticles struct {
// Title
Title RichTextClass
// Related articles
Articles []PageRelatedArticle
}
PageBlockRelatedArticles represents TL type `pageBlockRelatedArticles#16115a96`. Related articles
See https://core.telegram.org/constructor/pageBlockRelatedArticles for reference.
func (*PageBlockRelatedArticles) Decode ¶
func (p *PageBlockRelatedArticles) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockRelatedArticles) Encode ¶
func (p *PageBlockRelatedArticles) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockRelatedArticles) String ¶ added in v0.12.0
func (p *PageBlockRelatedArticles) String() string
String implements fmt.Stringer.
type PageBlockSlideshow ¶
type PageBlockSlideshow struct {
// Slideshow items
Items []PageBlockClass
// Caption
Caption PageCaption
}
PageBlockSlideshow represents TL type `pageBlockSlideshow#31f9590`. Slideshow
See https://core.telegram.org/constructor/pageBlockSlideshow for reference.
func (*PageBlockSlideshow) Decode ¶
func (p *PageBlockSlideshow) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockSlideshow) Encode ¶
func (p *PageBlockSlideshow) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockSlideshow) String ¶ added in v0.12.0
func (p *PageBlockSlideshow) String() string
String implements fmt.Stringer.
type PageBlockSubheader ¶
type PageBlockSubheader struct {
// Subheader
Text RichTextClass
}
PageBlockSubheader represents TL type `pageBlockSubheader#f12bb6e1`. Subheader
See https://core.telegram.org/constructor/pageBlockSubheader for reference.
func (*PageBlockSubheader) Decode ¶
func (p *PageBlockSubheader) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockSubheader) Encode ¶
func (p *PageBlockSubheader) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockSubheader) String ¶ added in v0.12.0
func (p *PageBlockSubheader) String() string
String implements fmt.Stringer.
type PageBlockSubtitle ¶
type PageBlockSubtitle struct {
// Text
Text RichTextClass
}
PageBlockSubtitle represents TL type `pageBlockSubtitle#8ffa9a1f`. Subtitle
See https://core.telegram.org/constructor/pageBlockSubtitle for reference.
func (*PageBlockSubtitle) Decode ¶
func (p *PageBlockSubtitle) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockSubtitle) Encode ¶
func (p *PageBlockSubtitle) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockSubtitle) String ¶ added in v0.12.0
func (p *PageBlockSubtitle) String() string
String implements fmt.Stringer.
type PageBlockTable ¶
type PageBlockTable struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Does the table have a visible border?
Bordered bool
// Is the table striped?
Striped bool
// Title
Title RichTextClass
// Table rows
Rows []PageTableRow
}
PageBlockTable represents TL type `pageBlockTable#bf4dea82`. Table
See https://core.telegram.org/constructor/pageBlockTable for reference.
func (*PageBlockTable) Decode ¶
func (p *PageBlockTable) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockTable) Encode ¶
func (p *PageBlockTable) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockTable) SetBordered ¶
func (p *PageBlockTable) SetBordered(value bool)
SetBordered sets value of Bordered conditional field.
func (*PageBlockTable) SetStriped ¶
func (p *PageBlockTable) SetStriped(value bool)
SetStriped sets value of Striped conditional field.
func (*PageBlockTable) String ¶ added in v0.12.0
func (p *PageBlockTable) String() string
String implements fmt.Stringer.
type PageBlockTitle ¶
type PageBlockTitle struct {
// Title
Text RichTextClass
}
PageBlockTitle represents TL type `pageBlockTitle#70abc3fd`. Title
See https://core.telegram.org/constructor/pageBlockTitle for reference.
func (*PageBlockTitle) Decode ¶
func (p *PageBlockTitle) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockTitle) Encode ¶
func (p *PageBlockTitle) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockTitle) String ¶ added in v0.12.0
func (p *PageBlockTitle) String() string
String implements fmt.Stringer.
type PageBlockUnsupported ¶
type PageBlockUnsupported struct {
}
PageBlockUnsupported represents TL type `pageBlockUnsupported#13567e8a`. Unsupported IV element
See https://core.telegram.org/constructor/pageBlockUnsupported for reference.
func (*PageBlockUnsupported) Decode ¶
func (p *PageBlockUnsupported) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockUnsupported) Encode ¶
func (p *PageBlockUnsupported) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockUnsupported) String ¶ added in v0.12.0
func (p *PageBlockUnsupported) String() string
String implements fmt.Stringer.
type PageBlockVideo ¶
type PageBlockVideo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the video is set to autoplay
Autoplay bool
// Whether the video is set to loop
Loop bool
// Video ID
VideoID int64
// Caption
Caption PageCaption
}
PageBlockVideo represents TL type `pageBlockVideo#7c8fe7b6`. Video
See https://core.telegram.org/constructor/pageBlockVideo for reference.
func (*PageBlockVideo) Decode ¶
func (p *PageBlockVideo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageBlockVideo) Encode ¶
func (p *PageBlockVideo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageBlockVideo) SetAutoplay ¶
func (p *PageBlockVideo) SetAutoplay(value bool)
SetAutoplay sets value of Autoplay conditional field.
func (*PageBlockVideo) SetLoop ¶
func (p *PageBlockVideo) SetLoop(value bool)
SetLoop sets value of Loop conditional field.
func (*PageBlockVideo) String ¶ added in v0.12.0
func (p *PageBlockVideo) String() string
String implements fmt.Stringer.
type PageCaption ¶
type PageCaption struct {
// Caption
Text RichTextClass
// Credits
Credit RichTextClass
}
PageCaption represents TL type `pageCaption#6f747657`. Page caption
See https://core.telegram.org/constructor/pageCaption for reference.
func (*PageCaption) Decode ¶
func (p *PageCaption) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageCaption) Encode ¶
func (p *PageCaption) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageCaption) String ¶ added in v0.12.0
func (p *PageCaption) String() string
String implements fmt.Stringer.
type PageListItemBlocks ¶
type PageListItemBlocks struct {
// Blocks
Blocks []PageBlockClass
}
PageListItemBlocks represents TL type `pageListItemBlocks#25e073fc`. List item
See https://core.telegram.org/constructor/pageListItemBlocks for reference.
func (*PageListItemBlocks) Decode ¶
func (p *PageListItemBlocks) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageListItemBlocks) Encode ¶
func (p *PageListItemBlocks) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageListItemBlocks) String ¶ added in v0.12.0
func (p *PageListItemBlocks) String() string
String implements fmt.Stringer.
type PageListItemBox ¶
type PageListItemBox struct {
PageListItem PageListItemClass
}
PageListItem boxes the PageListItemClass providing a helper.
type PageListItemClass ¶
type PageListItemClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PageListItemClass represents PageListItem generic type.
See https://core.telegram.org/type/PageListItem for reference.
Example:
g, err := DecodePageListItem(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PageListItemText: // pageListItemText#b92fb6cd
case *PageListItemBlocks: // pageListItemBlocks#25e073fc
default: panic(v)
}
func DecodePageListItem ¶
func DecodePageListItem(buf *bin.Buffer) (PageListItemClass, error)
DecodePageListItem implements binary de-serialization for PageListItemClass.
type PageListItemText ¶
type PageListItemText struct {
// Text
Text RichTextClass
}
PageListItemText represents TL type `pageListItemText#b92fb6cd`. List item
See https://core.telegram.org/constructor/pageListItemText for reference.
func (*PageListItemText) Decode ¶
func (p *PageListItemText) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageListItemText) Encode ¶
func (p *PageListItemText) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageListItemText) String ¶ added in v0.12.0
func (p *PageListItemText) String() string
String implements fmt.Stringer.
type PageListOrderedItemBlocks ¶
type PageListOrderedItemBlocks struct {
// Number of element within ordered list
Num string
// Item contents
Blocks []PageBlockClass
}
PageListOrderedItemBlocks represents TL type `pageListOrderedItemBlocks#98dd8936`. Ordered list of IV¹ blocks
Links:
See https://core.telegram.org/constructor/pageListOrderedItemBlocks for reference.
func (*PageListOrderedItemBlocks) Decode ¶
func (p *PageListOrderedItemBlocks) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageListOrderedItemBlocks) Encode ¶
func (p *PageListOrderedItemBlocks) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageListOrderedItemBlocks) String ¶ added in v0.12.0
func (p *PageListOrderedItemBlocks) String() string
String implements fmt.Stringer.
type PageListOrderedItemBox ¶
type PageListOrderedItemBox struct {
PageListOrderedItem PageListOrderedItemClass
}
PageListOrderedItem boxes the PageListOrderedItemClass providing a helper.
type PageListOrderedItemClass ¶
type PageListOrderedItemClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PageListOrderedItemClass represents PageListOrderedItem generic type.
See https://core.telegram.org/type/PageListOrderedItem for reference.
Example:
g, err := DecodePageListOrderedItem(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PageListOrderedItemText: // pageListOrderedItemText#5e068047
case *PageListOrderedItemBlocks: // pageListOrderedItemBlocks#98dd8936
default: panic(v)
}
func DecodePageListOrderedItem ¶
func DecodePageListOrderedItem(buf *bin.Buffer) (PageListOrderedItemClass, error)
DecodePageListOrderedItem implements binary de-serialization for PageListOrderedItemClass.
type PageListOrderedItemText ¶
type PageListOrderedItemText struct {
// Number of element within ordered list
Num string
// Text
Text RichTextClass
}
PageListOrderedItemText represents TL type `pageListOrderedItemText#5e068047`. Ordered list of text items
See https://core.telegram.org/constructor/pageListOrderedItemText for reference.
func (*PageListOrderedItemText) Decode ¶
func (p *PageListOrderedItemText) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageListOrderedItemText) Encode ¶
func (p *PageListOrderedItemText) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageListOrderedItemText) String ¶ added in v0.12.0
func (p *PageListOrderedItemText) String() string
String implements fmt.Stringer.
type PageRelatedArticle ¶
type PageRelatedArticle struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// URL of article
URL string
// Webpage ID of generated IV preview
WebpageID int64
// Title
//
// Use SetTitle and GetTitle helpers.
Title string
// Description
//
// Use SetDescription and GetDescription helpers.
Description string
// ID of preview photo
//
// Use SetPhotoID and GetPhotoID helpers.
PhotoID int64
// Author name
//
// Use SetAuthor and GetAuthor helpers.
Author string
// Date of pubblication
//
// Use SetPublishedDate and GetPublishedDate helpers.
PublishedDate int
}
PageRelatedArticle represents TL type `pageRelatedArticle#b390dc08`. Related article
See https://core.telegram.org/constructor/pageRelatedArticle for reference.
func (*PageRelatedArticle) Decode ¶
func (p *PageRelatedArticle) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageRelatedArticle) Encode ¶
func (p *PageRelatedArticle) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageRelatedArticle) GetAuthor ¶
func (p *PageRelatedArticle) GetAuthor() (value string, ok bool)
GetAuthor returns value of Author conditional field and boolean which is true if field was set.
func (*PageRelatedArticle) GetDescription ¶
func (p *PageRelatedArticle) GetDescription() (value string, ok bool)
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*PageRelatedArticle) GetPhotoID ¶
func (p *PageRelatedArticle) GetPhotoID() (value int64, ok bool)
GetPhotoID returns value of PhotoID conditional field and boolean which is true if field was set.
func (*PageRelatedArticle) GetPublishedDate ¶
func (p *PageRelatedArticle) GetPublishedDate() (value int, ok bool)
GetPublishedDate returns value of PublishedDate conditional field and boolean which is true if field was set.
func (*PageRelatedArticle) GetTitle ¶
func (p *PageRelatedArticle) GetTitle() (value string, ok bool)
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*PageRelatedArticle) SetAuthor ¶
func (p *PageRelatedArticle) SetAuthor(value string)
SetAuthor sets value of Author conditional field.
func (*PageRelatedArticle) SetDescription ¶
func (p *PageRelatedArticle) SetDescription(value string)
SetDescription sets value of Description conditional field.
func (*PageRelatedArticle) SetPhotoID ¶
func (p *PageRelatedArticle) SetPhotoID(value int64)
SetPhotoID sets value of PhotoID conditional field.
func (*PageRelatedArticle) SetPublishedDate ¶
func (p *PageRelatedArticle) SetPublishedDate(value int)
SetPublishedDate sets value of PublishedDate conditional field.
func (*PageRelatedArticle) SetTitle ¶
func (p *PageRelatedArticle) SetTitle(value string)
SetTitle sets value of Title conditional field.
func (*PageRelatedArticle) String ¶ added in v0.12.0
func (p *PageRelatedArticle) String() string
String implements fmt.Stringer.
type PageTableCell ¶
type PageTableCell struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this element part of the column header
Header bool
// Horizontally centered block
AlignCenter bool
// Right-aligned block
AlignRight bool
// Vertically centered block
ValignMiddle bool
// Block vertically-alligned to the bottom
ValignBottom bool
// Content
//
// Use SetText and GetText helpers.
Text RichTextClass
// For how many columns should this cell extend
//
// Use SetColspan and GetColspan helpers.
Colspan int
// For how many rows should this cell extend
//
// Use SetRowspan and GetRowspan helpers.
Rowspan int
}
PageTableCell represents TL type `pageTableCell#34566b6a`. Table cell
See https://core.telegram.org/constructor/pageTableCell for reference.
func (*PageTableCell) Decode ¶
func (p *PageTableCell) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageTableCell) Encode ¶
func (p *PageTableCell) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageTableCell) GetColspan ¶
func (p *PageTableCell) GetColspan() (value int, ok bool)
GetColspan returns value of Colspan conditional field and boolean which is true if field was set.
func (*PageTableCell) GetRowspan ¶
func (p *PageTableCell) GetRowspan() (value int, ok bool)
GetRowspan returns value of Rowspan conditional field and boolean which is true if field was set.
func (*PageTableCell) GetText ¶
func (p *PageTableCell) GetText() (value RichTextClass, ok bool)
GetText returns value of Text conditional field and boolean which is true if field was set.
func (*PageTableCell) SetAlignCenter ¶
func (p *PageTableCell) SetAlignCenter(value bool)
SetAlignCenter sets value of AlignCenter conditional field.
func (*PageTableCell) SetAlignRight ¶
func (p *PageTableCell) SetAlignRight(value bool)
SetAlignRight sets value of AlignRight conditional field.
func (*PageTableCell) SetColspan ¶
func (p *PageTableCell) SetColspan(value int)
SetColspan sets value of Colspan conditional field.
func (*PageTableCell) SetHeader ¶
func (p *PageTableCell) SetHeader(value bool)
SetHeader sets value of Header conditional field.
func (*PageTableCell) SetRowspan ¶
func (p *PageTableCell) SetRowspan(value int)
SetRowspan sets value of Rowspan conditional field.
func (*PageTableCell) SetText ¶
func (p *PageTableCell) SetText(value RichTextClass)
SetText sets value of Text conditional field.
func (*PageTableCell) SetValignBottom ¶
func (p *PageTableCell) SetValignBottom(value bool)
SetValignBottom sets value of ValignBottom conditional field.
func (*PageTableCell) SetValignMiddle ¶
func (p *PageTableCell) SetValignMiddle(value bool)
SetValignMiddle sets value of ValignMiddle conditional field.
func (*PageTableCell) String ¶ added in v0.12.0
func (p *PageTableCell) String() string
String implements fmt.Stringer.
type PageTableRow ¶
type PageTableRow struct {
// Table cells
Cells []PageTableCell
}
PageTableRow represents TL type `pageTableRow#e0c0c5e5`. Table row
See https://core.telegram.org/constructor/pageTableRow for reference.
func (*PageTableRow) Decode ¶
func (p *PageTableRow) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PageTableRow) Encode ¶
func (p *PageTableRow) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PageTableRow) String ¶ added in v0.12.0
func (p *PageTableRow) String() string
String implements fmt.Stringer.
type PasswordKdfAlgoBox ¶
type PasswordKdfAlgoBox struct {
PasswordKdfAlgo PasswordKdfAlgoClass
}
PasswordKdfAlgo boxes the PasswordKdfAlgoClass providing a helper.
type PasswordKdfAlgoClass ¶
type PasswordKdfAlgoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PasswordKdfAlgoClass represents PasswordKdfAlgo generic type.
See https://core.telegram.org/type/PasswordKdfAlgo for reference.
Example:
g, err := DecodePasswordKdfAlgo(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PasswordKdfAlgoUnknown: // passwordKdfAlgoUnknown#d45ab096
case *PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow: // passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow#3a912d4a
default: panic(v)
}
func DecodePasswordKdfAlgo ¶
func DecodePasswordKdfAlgo(buf *bin.Buffer) (PasswordKdfAlgoClass, error)
DecodePasswordKdfAlgo implements binary de-serialization for PasswordKdfAlgoClass.
type PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow ¶
type PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow struct {
// One of two salts used by the derivation function (see SRP 2FA login¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
Salt1 []byte
// One of two salts used by the derivation function (see SRP 2FA login¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
Salt2 []byte
// Base (see SRP 2FA login¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
G int
// 2048-bit modulus (see SRP 2FA login¹)
//
// Links:
// 1) https://core.telegram.org/api/srp
P []byte
}
PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow represents TL type `passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow#3a912d4a`. This key derivation algorithm defines that SRP 2FA login¹ must be used
Links:
See https://core.telegram.org/constructor/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow for reference.
func (*PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) Decode ¶
func (p *PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) Encode ¶
func (p *PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) String ¶ added in v0.12.0
func (p *PasswordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow) String() string
String implements fmt.Stringer.
type PasswordKdfAlgoUnknown ¶
type PasswordKdfAlgoUnknown struct {
}
PasswordKdfAlgoUnknown represents TL type `passwordKdfAlgoUnknown#d45ab096`. Unknown KDF (most likely, the client is outdated and does not support the specified KDF algorithm)
See https://core.telegram.org/constructor/passwordKdfAlgoUnknown for reference.
func (*PasswordKdfAlgoUnknown) Decode ¶
func (p *PasswordKdfAlgoUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PasswordKdfAlgoUnknown) Encode ¶
func (p *PasswordKdfAlgoUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PasswordKdfAlgoUnknown) String ¶ added in v0.12.0
func (p *PasswordKdfAlgoUnknown) String() string
String implements fmt.Stringer.
type PaymentCharge ¶
type PaymentCharge struct {
// Telegram payment identifier
ID string
// Provider payment identifier
ProviderChargeID string
}
PaymentCharge represents TL type `paymentCharge#ea02c27e`. Payment identifier
See https://core.telegram.org/constructor/paymentCharge for reference.
func (*PaymentCharge) Decode ¶
func (p *PaymentCharge) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentCharge) Encode ¶
func (p *PaymentCharge) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentCharge) String ¶ added in v0.12.0
func (p *PaymentCharge) String() string
String implements fmt.Stringer.
type PaymentRequestedInfo ¶
type PaymentRequestedInfo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// User's full name
//
// Use SetName and GetName helpers.
Name string
// User's phone number
//
// Use SetPhone and GetPhone helpers.
Phone string
// User's email address
//
// Use SetEmail and GetEmail helpers.
Email string
// User's shipping address
//
// Use SetShippingAddress and GetShippingAddress helpers.
ShippingAddress PostAddress
}
PaymentRequestedInfo represents TL type `paymentRequestedInfo#909c3f94`. Order info provided by the user
See https://core.telegram.org/constructor/paymentRequestedInfo for reference.
func (*PaymentRequestedInfo) Decode ¶
func (p *PaymentRequestedInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentRequestedInfo) Encode ¶
func (p *PaymentRequestedInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentRequestedInfo) GetEmail ¶
func (p *PaymentRequestedInfo) GetEmail() (value string, ok bool)
GetEmail returns value of Email conditional field and boolean which is true if field was set.
func (*PaymentRequestedInfo) GetName ¶
func (p *PaymentRequestedInfo) GetName() (value string, ok bool)
GetName returns value of Name conditional field and boolean which is true if field was set.
func (*PaymentRequestedInfo) GetPhone ¶
func (p *PaymentRequestedInfo) GetPhone() (value string, ok bool)
GetPhone returns value of Phone conditional field and boolean which is true if field was set.
func (*PaymentRequestedInfo) GetShippingAddress ¶
func (p *PaymentRequestedInfo) GetShippingAddress() (value PostAddress, ok bool)
GetShippingAddress returns value of ShippingAddress conditional field and boolean which is true if field was set.
func (*PaymentRequestedInfo) SetEmail ¶
func (p *PaymentRequestedInfo) SetEmail(value string)
SetEmail sets value of Email conditional field.
func (*PaymentRequestedInfo) SetName ¶
func (p *PaymentRequestedInfo) SetName(value string)
SetName sets value of Name conditional field.
func (*PaymentRequestedInfo) SetPhone ¶
func (p *PaymentRequestedInfo) SetPhone(value string)
SetPhone sets value of Phone conditional field.
func (*PaymentRequestedInfo) SetShippingAddress ¶
func (p *PaymentRequestedInfo) SetShippingAddress(value PostAddress)
SetShippingAddress sets value of ShippingAddress conditional field.
func (*PaymentRequestedInfo) String ¶ added in v0.12.0
func (p *PaymentRequestedInfo) String() string
String implements fmt.Stringer.
type PaymentSavedCredentialsCard ¶
PaymentSavedCredentialsCard represents TL type `paymentSavedCredentialsCard#cdc27a1f`. Saved credit card
See https://core.telegram.org/constructor/paymentSavedCredentialsCard for reference.
func (*PaymentSavedCredentialsCard) Decode ¶
func (p *PaymentSavedCredentialsCard) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentSavedCredentialsCard) Encode ¶
func (p *PaymentSavedCredentialsCard) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentSavedCredentialsCard) String ¶ added in v0.12.0
func (p *PaymentSavedCredentialsCard) String() string
String implements fmt.Stringer.
type PaymentsBankCardData ¶
type PaymentsBankCardData struct {
// Credit card title
Title string
// Info URL(s) provided by the card's bank(s)
OpenUrls []BankCardOpenUrl
}
PaymentsBankCardData represents TL type `payments.bankCardData#3e24e573`. Credit card info, provided by the card's bank(s)
See https://core.telegram.org/constructor/payments.bankCardData for reference.
func (*PaymentsBankCardData) Decode ¶
func (b *PaymentsBankCardData) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsBankCardData) Encode ¶
func (b *PaymentsBankCardData) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsBankCardData) String ¶ added in v0.12.0
func (b *PaymentsBankCardData) String() string
String implements fmt.Stringer.
type PaymentsClearSavedInfoRequest ¶
type PaymentsClearSavedInfoRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Remove saved payment credentials
Credentials bool
// Clear the last order settings saved by the user
Info bool
}
PaymentsClearSavedInfoRequest represents TL type `payments.clearSavedInfo#d83d70c1`. Clear saved payment information
See https://core.telegram.org/method/payments.clearSavedInfo for reference.
func (*PaymentsClearSavedInfoRequest) Decode ¶
func (c *PaymentsClearSavedInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsClearSavedInfoRequest) Encode ¶
func (c *PaymentsClearSavedInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsClearSavedInfoRequest) SetCredentials ¶
func (c *PaymentsClearSavedInfoRequest) SetCredentials(value bool)
SetCredentials sets value of Credentials conditional field.
func (*PaymentsClearSavedInfoRequest) SetInfo ¶
func (c *PaymentsClearSavedInfoRequest) SetInfo(value bool)
SetInfo sets value of Info conditional field.
func (*PaymentsClearSavedInfoRequest) String ¶ added in v0.12.0
func (c *PaymentsClearSavedInfoRequest) String() string
String implements fmt.Stringer.
type PaymentsGetBankCardDataRequest ¶
type PaymentsGetBankCardDataRequest struct {
// Credit card number
Number string
}
PaymentsGetBankCardDataRequest represents TL type `payments.getBankCardData#2e79d779`. Get info about a credit card
See https://core.telegram.org/method/payments.getBankCardData for reference.
func (*PaymentsGetBankCardDataRequest) Decode ¶
func (g *PaymentsGetBankCardDataRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsGetBankCardDataRequest) Encode ¶
func (g *PaymentsGetBankCardDataRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsGetBankCardDataRequest) String ¶ added in v0.12.0
func (g *PaymentsGetBankCardDataRequest) String() string
String implements fmt.Stringer.
type PaymentsGetPaymentFormRequest ¶
type PaymentsGetPaymentFormRequest struct {
// Message ID of payment form
MsgID int
}
PaymentsGetPaymentFormRequest represents TL type `payments.getPaymentForm#99f09745`. Get a payment form
See https://core.telegram.org/method/payments.getPaymentForm for reference.
func (*PaymentsGetPaymentFormRequest) Decode ¶
func (g *PaymentsGetPaymentFormRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsGetPaymentFormRequest) Encode ¶
func (g *PaymentsGetPaymentFormRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsGetPaymentFormRequest) String ¶ added in v0.12.0
func (g *PaymentsGetPaymentFormRequest) String() string
String implements fmt.Stringer.
type PaymentsGetPaymentReceiptRequest ¶
type PaymentsGetPaymentReceiptRequest struct {
// Message ID of receipt
MsgID int
}
PaymentsGetPaymentReceiptRequest represents TL type `payments.getPaymentReceipt#a092a980`. Get payment receipt
See https://core.telegram.org/method/payments.getPaymentReceipt for reference.
func (*PaymentsGetPaymentReceiptRequest) Decode ¶
func (g *PaymentsGetPaymentReceiptRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsGetPaymentReceiptRequest) Encode ¶
func (g *PaymentsGetPaymentReceiptRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsGetPaymentReceiptRequest) String ¶ added in v0.12.0
func (g *PaymentsGetPaymentReceiptRequest) String() string
String implements fmt.Stringer.
type PaymentsGetSavedInfoRequest ¶
type PaymentsGetSavedInfoRequest struct {
}
PaymentsGetSavedInfoRequest represents TL type `payments.getSavedInfo#227d824b`. Get saved payment information
See https://core.telegram.org/method/payments.getSavedInfo for reference.
func (*PaymentsGetSavedInfoRequest) Decode ¶
func (g *PaymentsGetSavedInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsGetSavedInfoRequest) Encode ¶
func (g *PaymentsGetSavedInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsGetSavedInfoRequest) String ¶ added in v0.12.0
func (g *PaymentsGetSavedInfoRequest) String() string
String implements fmt.Stringer.
type PaymentsPaymentForm ¶
type PaymentsPaymentForm struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user can choose to save credentials.
CanSaveCredentials bool
// Indicates that the user can save payment credentials, but only after setting up a 2FA password¹ (currently the account doesn't have a 2FA password²)
//
// Links:
// 1) https://core.telegram.org/api/srp
// 2) https://core.telegram.org/api/srp
PasswordMissing bool
// Bot ID
BotID int
// Invoice
Invoice Invoice
// Payment provider ID.
ProviderID int
// Payment form URL
URL string
// Payment provider name.One of the following:- stripe
//
// Use SetNativeProvider and GetNativeProvider helpers.
NativeProvider string
// Contains information about the payment provider, if available, to support it natively without the need for opening the URL.A JSON object that can contain the following fields:- publishable_key: Stripe API publishable key- apple_pay_merchant_id: Apple Pay merchant ID- android_pay_public_key: Android Pay public key- android_pay_bgcolor: Android Pay form background color- android_pay_inverse: Whether to use the dark theme in the Android Pay form- need_country: True, if the user country must be provided,- need_zip: True, if the user ZIP/postal code must be provided,- need_cardholder_name: True, if the cardholder name must be provided
//
// Use SetNativeParams and GetNativeParams helpers.
NativeParams DataJSON
// Saved server-side order information
//
// Use SetSavedInfo and GetSavedInfo helpers.
SavedInfo PaymentRequestedInfo
// Contains information about saved card credentials
//
// Use SetSavedCredentials and GetSavedCredentials helpers.
SavedCredentials PaymentSavedCredentialsCard
// Users
Users []UserClass
}
PaymentsPaymentForm represents TL type `payments.paymentForm#3f56aea3`. Payment form
See https://core.telegram.org/constructor/payments.paymentForm for reference.
func (*PaymentsPaymentForm) Decode ¶
func (p *PaymentsPaymentForm) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsPaymentForm) Encode ¶
func (p *PaymentsPaymentForm) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsPaymentForm) GetNativeParams ¶
func (p *PaymentsPaymentForm) GetNativeParams() (value DataJSON, ok bool)
GetNativeParams returns value of NativeParams conditional field and boolean which is true if field was set.
func (*PaymentsPaymentForm) GetNativeProvider ¶
func (p *PaymentsPaymentForm) GetNativeProvider() (value string, ok bool)
GetNativeProvider returns value of NativeProvider conditional field and boolean which is true if field was set.
func (*PaymentsPaymentForm) GetSavedCredentials ¶
func (p *PaymentsPaymentForm) GetSavedCredentials() (value PaymentSavedCredentialsCard, ok bool)
GetSavedCredentials returns value of SavedCredentials conditional field and boolean which is true if field was set.
func (*PaymentsPaymentForm) GetSavedInfo ¶
func (p *PaymentsPaymentForm) GetSavedInfo() (value PaymentRequestedInfo, ok bool)
GetSavedInfo returns value of SavedInfo conditional field and boolean which is true if field was set.
func (*PaymentsPaymentForm) SetCanSaveCredentials ¶
func (p *PaymentsPaymentForm) SetCanSaveCredentials(value bool)
SetCanSaveCredentials sets value of CanSaveCredentials conditional field.
func (*PaymentsPaymentForm) SetNativeParams ¶
func (p *PaymentsPaymentForm) SetNativeParams(value DataJSON)
SetNativeParams sets value of NativeParams conditional field.
func (*PaymentsPaymentForm) SetNativeProvider ¶
func (p *PaymentsPaymentForm) SetNativeProvider(value string)
SetNativeProvider sets value of NativeProvider conditional field.
func (*PaymentsPaymentForm) SetPasswordMissing ¶
func (p *PaymentsPaymentForm) SetPasswordMissing(value bool)
SetPasswordMissing sets value of PasswordMissing conditional field.
func (*PaymentsPaymentForm) SetSavedCredentials ¶
func (p *PaymentsPaymentForm) SetSavedCredentials(value PaymentSavedCredentialsCard)
SetSavedCredentials sets value of SavedCredentials conditional field.
func (*PaymentsPaymentForm) SetSavedInfo ¶
func (p *PaymentsPaymentForm) SetSavedInfo(value PaymentRequestedInfo)
SetSavedInfo sets value of SavedInfo conditional field.
func (*PaymentsPaymentForm) String ¶ added in v0.12.0
func (p *PaymentsPaymentForm) String() string
String implements fmt.Stringer.
type PaymentsPaymentReceipt ¶
type PaymentsPaymentReceipt struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Date of generation
Date int
// Bot ID
BotID int
// Invoice
Invoice Invoice
// Provider ID
ProviderID int
// Info
//
// Use SetInfo and GetInfo helpers.
Info PaymentRequestedInfo
// Selected shipping option
//
// Use SetShipping and GetShipping helpers.
Shipping ShippingOption
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Total amount in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
TotalAmount int64
// Payment credential name
CredentialsTitle string
// Users
Users []UserClass
}
PaymentsPaymentReceipt represents TL type `payments.paymentReceipt#500911e1`. Receipt
See https://core.telegram.org/constructor/payments.paymentReceipt for reference.
func (*PaymentsPaymentReceipt) Decode ¶
func (p *PaymentsPaymentReceipt) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsPaymentReceipt) Encode ¶
func (p *PaymentsPaymentReceipt) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsPaymentReceipt) GetInfo ¶
func (p *PaymentsPaymentReceipt) GetInfo() (value PaymentRequestedInfo, ok bool)
GetInfo returns value of Info conditional field and boolean which is true if field was set.
func (*PaymentsPaymentReceipt) GetShipping ¶
func (p *PaymentsPaymentReceipt) GetShipping() (value ShippingOption, ok bool)
GetShipping returns value of Shipping conditional field and boolean which is true if field was set.
func (*PaymentsPaymentReceipt) SetInfo ¶
func (p *PaymentsPaymentReceipt) SetInfo(value PaymentRequestedInfo)
SetInfo sets value of Info conditional field.
func (*PaymentsPaymentReceipt) SetShipping ¶
func (p *PaymentsPaymentReceipt) SetShipping(value ShippingOption)
SetShipping sets value of Shipping conditional field.
func (*PaymentsPaymentReceipt) String ¶ added in v0.12.0
func (p *PaymentsPaymentReceipt) String() string
String implements fmt.Stringer.
type PaymentsPaymentResult ¶
type PaymentsPaymentResult struct {
// Info about the payment
Updates UpdatesClass
}
PaymentsPaymentResult represents TL type `payments.paymentResult#4e5f810d`. Payment result
See https://core.telegram.org/constructor/payments.paymentResult for reference.
func (*PaymentsPaymentResult) Decode ¶
func (p *PaymentsPaymentResult) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsPaymentResult) Encode ¶
func (p *PaymentsPaymentResult) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsPaymentResult) String ¶ added in v0.12.0
func (p *PaymentsPaymentResult) String() string
String implements fmt.Stringer.
type PaymentsPaymentResultBox ¶
type PaymentsPaymentResultBox struct {
PaymentResult PaymentsPaymentResultClass
}
PaymentsPaymentResult boxes the PaymentsPaymentResultClass providing a helper.
type PaymentsPaymentResultClass ¶
type PaymentsPaymentResultClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PaymentsPaymentResultClass represents payments.PaymentResult generic type.
See https://core.telegram.org/type/payments.PaymentResult for reference.
Example:
g, err := DecodePaymentsPaymentResult(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PaymentsPaymentResult: // payments.paymentResult#4e5f810d
case *PaymentsPaymentVerificationNeeded: // payments.paymentVerificationNeeded#d8411139
default: panic(v)
}
func DecodePaymentsPaymentResult ¶
func DecodePaymentsPaymentResult(buf *bin.Buffer) (PaymentsPaymentResultClass, error)
DecodePaymentsPaymentResult implements binary de-serialization for PaymentsPaymentResultClass.
type PaymentsPaymentVerificationNeeded ¶
type PaymentsPaymentVerificationNeeded struct {
// URL for additional payment credentials verification
URL string
}
PaymentsPaymentVerificationNeeded represents TL type `payments.paymentVerificationNeeded#d8411139`. Payment was not successful, additional verification is needed
See https://core.telegram.org/constructor/payments.paymentVerificationNeeded for reference.
func (*PaymentsPaymentVerificationNeeded) Decode ¶
func (p *PaymentsPaymentVerificationNeeded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsPaymentVerificationNeeded) Encode ¶
func (p *PaymentsPaymentVerificationNeeded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsPaymentVerificationNeeded) String ¶ added in v0.12.0
func (p *PaymentsPaymentVerificationNeeded) String() string
String implements fmt.Stringer.
type PaymentsSavedInfo ¶
type PaymentsSavedInfo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user has some saved payment credentials
HasSavedCredentials bool
// Saved server-side order information
//
// Use SetSavedInfo and GetSavedInfo helpers.
SavedInfo PaymentRequestedInfo
}
PaymentsSavedInfo represents TL type `payments.savedInfo#fb8fe43c`. Saved server-side order information
See https://core.telegram.org/constructor/payments.savedInfo for reference.
func (*PaymentsSavedInfo) Decode ¶
func (s *PaymentsSavedInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsSavedInfo) Encode ¶
func (s *PaymentsSavedInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsSavedInfo) GetSavedInfo ¶
func (s *PaymentsSavedInfo) GetSavedInfo() (value PaymentRequestedInfo, ok bool)
GetSavedInfo returns value of SavedInfo conditional field and boolean which is true if field was set.
func (*PaymentsSavedInfo) SetHasSavedCredentials ¶
func (s *PaymentsSavedInfo) SetHasSavedCredentials(value bool)
SetHasSavedCredentials sets value of HasSavedCredentials conditional field.
func (*PaymentsSavedInfo) SetSavedInfo ¶
func (s *PaymentsSavedInfo) SetSavedInfo(value PaymentRequestedInfo)
SetSavedInfo sets value of SavedInfo conditional field.
func (*PaymentsSavedInfo) String ¶ added in v0.12.0
func (s *PaymentsSavedInfo) String() string
String implements fmt.Stringer.
type PaymentsSendPaymentFormRequest ¶
type PaymentsSendPaymentFormRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Message ID of form
MsgID int
// ID of saved and validated order info¹
//
// Links:
// 1) https://core.telegram.org/constructor/payments.validatedRequestedInfo
//
// Use SetRequestedInfoID and GetRequestedInfoID helpers.
RequestedInfoID string
// Chosen shipping option ID
//
// Use SetShippingOptionID and GetShippingOptionID helpers.
ShippingOptionID string
// Payment credentials
Credentials InputPaymentCredentialsClass
}
PaymentsSendPaymentFormRequest represents TL type `payments.sendPaymentForm#2b8879b3`. Send compiled payment form
See https://core.telegram.org/method/payments.sendPaymentForm for reference.
func (*PaymentsSendPaymentFormRequest) Decode ¶
func (s *PaymentsSendPaymentFormRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsSendPaymentFormRequest) Encode ¶
func (s *PaymentsSendPaymentFormRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsSendPaymentFormRequest) GetRequestedInfoID ¶
func (s *PaymentsSendPaymentFormRequest) GetRequestedInfoID() (value string, ok bool)
GetRequestedInfoID returns value of RequestedInfoID conditional field and boolean which is true if field was set.
func (*PaymentsSendPaymentFormRequest) GetShippingOptionID ¶
func (s *PaymentsSendPaymentFormRequest) GetShippingOptionID() (value string, ok bool)
GetShippingOptionID returns value of ShippingOptionID conditional field and boolean which is true if field was set.
func (*PaymentsSendPaymentFormRequest) SetRequestedInfoID ¶
func (s *PaymentsSendPaymentFormRequest) SetRequestedInfoID(value string)
SetRequestedInfoID sets value of RequestedInfoID conditional field.
func (*PaymentsSendPaymentFormRequest) SetShippingOptionID ¶
func (s *PaymentsSendPaymentFormRequest) SetShippingOptionID(value string)
SetShippingOptionID sets value of ShippingOptionID conditional field.
func (*PaymentsSendPaymentFormRequest) String ¶ added in v0.12.0
func (s *PaymentsSendPaymentFormRequest) String() string
String implements fmt.Stringer.
type PaymentsValidateRequestedInfoRequest ¶
type PaymentsValidateRequestedInfoRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Save order information to re-use it for future orders
Save bool
// Message ID of payment form
MsgID int
// Requested order information
Info PaymentRequestedInfo
}
PaymentsValidateRequestedInfoRequest represents TL type `payments.validateRequestedInfo#770a8e74`. Submit requested order information for validation
See https://core.telegram.org/method/payments.validateRequestedInfo for reference.
func (*PaymentsValidateRequestedInfoRequest) Decode ¶
func (v *PaymentsValidateRequestedInfoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsValidateRequestedInfoRequest) Encode ¶
func (v *PaymentsValidateRequestedInfoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsValidateRequestedInfoRequest) SetSave ¶
func (v *PaymentsValidateRequestedInfoRequest) SetSave(value bool)
SetSave sets value of Save conditional field.
func (*PaymentsValidateRequestedInfoRequest) String ¶ added in v0.12.0
func (v *PaymentsValidateRequestedInfoRequest) String() string
String implements fmt.Stringer.
type PaymentsValidatedRequestedInfo ¶
type PaymentsValidatedRequestedInfo struct {
// Flags field of PaymentsValidatedRequestedInfo.
Flags bin.Fields
// ID field of PaymentsValidatedRequestedInfo.
//
// Use SetID and GetID helpers.
ID string
// ShippingOptions field of PaymentsValidatedRequestedInfo.
//
// Use SetShippingOptions and GetShippingOptions helpers.
ShippingOptions []ShippingOption
}
PaymentsValidatedRequestedInfo represents TL type `payments.validatedRequestedInfo#d1451883`.
See https://core.telegram.org/constructor/payments.validatedRequestedInfo for reference.
func (*PaymentsValidatedRequestedInfo) Decode ¶
func (v *PaymentsValidatedRequestedInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PaymentsValidatedRequestedInfo) Encode ¶
func (v *PaymentsValidatedRequestedInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PaymentsValidatedRequestedInfo) GetID ¶
func (v *PaymentsValidatedRequestedInfo) GetID() (value string, ok bool)
GetID returns value of ID conditional field and boolean which is true if field was set.
func (*PaymentsValidatedRequestedInfo) GetShippingOptions ¶
func (v *PaymentsValidatedRequestedInfo) GetShippingOptions() (value []ShippingOption, ok bool)
GetShippingOptions returns value of ShippingOptions conditional field and boolean which is true if field was set.
func (*PaymentsValidatedRequestedInfo) SetID ¶
func (v *PaymentsValidatedRequestedInfo) SetID(value string)
SetID sets value of ID conditional field.
func (*PaymentsValidatedRequestedInfo) SetShippingOptions ¶
func (v *PaymentsValidatedRequestedInfo) SetShippingOptions(value []ShippingOption)
SetShippingOptions sets value of ShippingOptions conditional field.
func (*PaymentsValidatedRequestedInfo) String ¶ added in v0.12.0
func (v *PaymentsValidatedRequestedInfo) String() string
String implements fmt.Stringer.
type PeerBlocked ¶
PeerBlocked represents TL type `peerBlocked#e8fd8014`. Information about a blocked peer
See https://core.telegram.org/constructor/peerBlocked for reference.
func (*PeerBlocked) Decode ¶
func (p *PeerBlocked) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerBlocked) Encode ¶
func (p *PeerBlocked) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerBlocked) String ¶ added in v0.12.0
func (p *PeerBlocked) String() string
String implements fmt.Stringer.
type PeerBlockedHandler ¶ added in v0.9.0
type PeerBlockedHandler func(ctx UpdateContext, update *UpdatePeerBlocked) error
PeerBlockedHandler is a PeerBlocked event handler.
type PeerBox ¶
type PeerBox struct {
Peer PeerClass
}
Peer boxes the PeerClass providing a helper.
type PeerChannel ¶
type PeerChannel struct {
// Channel ID
ChannelID int
}
PeerChannel represents TL type `peerChannel#bddde532`. Channel/supergroup
See https://core.telegram.org/constructor/peerChannel for reference.
func (*PeerChannel) Decode ¶
func (p *PeerChannel) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerChannel) Encode ¶
func (p *PeerChannel) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerChannel) String ¶ added in v0.12.0
func (p *PeerChannel) String() string
String implements fmt.Stringer.
type PeerChat ¶
type PeerChat struct {
// Group identifier
ChatID int
}
PeerChat represents TL type `peerChat#bad0e5bb`. Group.
See https://core.telegram.org/constructor/peerChat for reference.
type PeerClass ¶
type PeerClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PeerClass represents Peer generic type.
See https://core.telegram.org/type/Peer for reference.
Example:
g, err := DecodePeer(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PeerUser: // peerUser#9db1bc6d
case *PeerChat: // peerChat#bad0e5bb
case *PeerChannel: // peerChannel#bddde532
default: panic(v)
}
type PeerLocated ¶
type PeerLocated struct {
// Peer
Peer PeerClass
// Validity period of current data
Expires int
// Distance from the peer in meters
Distance int
}
PeerLocated represents TL type `peerLocated#ca461b5d`. Peer geolocated nearby
See https://core.telegram.org/constructor/peerLocated for reference.
func (*PeerLocated) Decode ¶
func (p *PeerLocated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerLocated) Encode ¶
func (p *PeerLocated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerLocated) String ¶ added in v0.12.0
func (p *PeerLocated) String() string
String implements fmt.Stringer.
type PeerLocatedBox ¶
type PeerLocatedBox struct {
PeerLocated PeerLocatedClass
}
PeerLocated boxes the PeerLocatedClass providing a helper.
type PeerLocatedClass ¶
type PeerLocatedClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PeerLocatedClass represents PeerLocated generic type.
See https://core.telegram.org/type/PeerLocated for reference.
Example:
g, err := DecodePeerLocated(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PeerLocated: // peerLocated#ca461b5d
case *PeerSelfLocated: // peerSelfLocated#f8ec284b
default: panic(v)
}
func DecodePeerLocated ¶
func DecodePeerLocated(buf *bin.Buffer) (PeerLocatedClass, error)
DecodePeerLocated implements binary de-serialization for PeerLocatedClass.
type PeerLocatedHandler ¶ added in v0.9.0
type PeerLocatedHandler func(ctx UpdateContext, update *UpdatePeerLocated) error
PeerLocatedHandler is a PeerLocated event handler.
type PeerNotifySettings ¶
type PeerNotifySettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Display text in notifications
//
// Use SetShowPreviews and GetShowPreviews helpers.
ShowPreviews bool
// Mute peer?
//
// Use SetSilent and GetSilent helpers.
Silent bool
// Mute all notifications until this date
//
// Use SetMuteUntil and GetMuteUntil helpers.
MuteUntil int
// Audio file name for notifications
//
// Use SetSound and GetSound helpers.
Sound string
}
PeerNotifySettings represents TL type `peerNotifySettings#af509d20`. Notification settings.
See https://core.telegram.org/constructor/peerNotifySettings for reference.
func (*PeerNotifySettings) Decode ¶
func (p *PeerNotifySettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerNotifySettings) Encode ¶
func (p *PeerNotifySettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerNotifySettings) GetMuteUntil ¶
func (p *PeerNotifySettings) GetMuteUntil() (value int, ok bool)
GetMuteUntil returns value of MuteUntil conditional field and boolean which is true if field was set.
func (*PeerNotifySettings) GetShowPreviews ¶ added in v0.17.0
func (p *PeerNotifySettings) GetShowPreviews() (value bool, ok bool)
GetShowPreviews returns value of ShowPreviews conditional field and boolean which is true if field was set.
func (*PeerNotifySettings) GetSilent ¶ added in v0.17.0
func (p *PeerNotifySettings) GetSilent() (value bool, ok bool)
GetSilent returns value of Silent conditional field and boolean which is true if field was set.
func (*PeerNotifySettings) GetSound ¶
func (p *PeerNotifySettings) GetSound() (value string, ok bool)
GetSound returns value of Sound conditional field and boolean which is true if field was set.
func (*PeerNotifySettings) SetMuteUntil ¶
func (p *PeerNotifySettings) SetMuteUntil(value int)
SetMuteUntil sets value of MuteUntil conditional field.
func (*PeerNotifySettings) SetShowPreviews ¶
func (p *PeerNotifySettings) SetShowPreviews(value bool)
SetShowPreviews sets value of ShowPreviews conditional field.
func (*PeerNotifySettings) SetSilent ¶
func (p *PeerNotifySettings) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*PeerNotifySettings) SetSound ¶
func (p *PeerNotifySettings) SetSound(value string)
SetSound sets value of Sound conditional field.
func (*PeerNotifySettings) String ¶ added in v0.12.0
func (p *PeerNotifySettings) String() string
String implements fmt.Stringer.
type PeerSelfLocated ¶
type PeerSelfLocated struct {
// Expiry of geolocation info for current peer
Expires int
}
PeerSelfLocated represents TL type `peerSelfLocated#f8ec284b`. Current peer
See https://core.telegram.org/constructor/peerSelfLocated for reference.
func (*PeerSelfLocated) Decode ¶
func (p *PeerSelfLocated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerSelfLocated) Encode ¶
func (p *PeerSelfLocated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerSelfLocated) String ¶ added in v0.12.0
func (p *PeerSelfLocated) String() string
String implements fmt.Stringer.
type PeerSettings ¶
type PeerSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether we can still report the user for spam
ReportSpam bool
// Whether we can add the user as contact
AddContact bool
// Whether we can block the user
BlockContact bool
ShareContact bool
// Whether a special exception for contacts is needed
NeedContactsException bool
// Whether we can report a geogroup is irrelevant for this location
ReportGeo bool
// Whether this peer was automatically archived according to privacy settings¹
//
// Links:
// 1) https://core.telegram.org/constructor/globalPrivacySettings
Autoarchived bool
// Distance in meters between us and this peer
//
// Use SetGeoDistance and GetGeoDistance helpers.
GeoDistance int
}
PeerSettings represents TL type `peerSettings#733f2961`. Peer settings
See https://core.telegram.org/constructor/peerSettings for reference.
func (*PeerSettings) Decode ¶
func (p *PeerSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PeerSettings) Encode ¶
func (p *PeerSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PeerSettings) GetGeoDistance ¶
func (p *PeerSettings) GetGeoDistance() (value int, ok bool)
GetGeoDistance returns value of GeoDistance conditional field and boolean which is true if field was set.
func (*PeerSettings) SetAddContact ¶
func (p *PeerSettings) SetAddContact(value bool)
SetAddContact sets value of AddContact conditional field.
func (*PeerSettings) SetAutoarchived ¶
func (p *PeerSettings) SetAutoarchived(value bool)
SetAutoarchived sets value of Autoarchived conditional field.
func (*PeerSettings) SetBlockContact ¶
func (p *PeerSettings) SetBlockContact(value bool)
SetBlockContact sets value of BlockContact conditional field.
func (*PeerSettings) SetGeoDistance ¶
func (p *PeerSettings) SetGeoDistance(value int)
SetGeoDistance sets value of GeoDistance conditional field.
func (*PeerSettings) SetNeedContactsException ¶
func (p *PeerSettings) SetNeedContactsException(value bool)
SetNeedContactsException sets value of NeedContactsException conditional field.
func (*PeerSettings) SetReportGeo ¶
func (p *PeerSettings) SetReportGeo(value bool)
SetReportGeo sets value of ReportGeo conditional field.
func (*PeerSettings) SetReportSpam ¶
func (p *PeerSettings) SetReportSpam(value bool)
SetReportSpam sets value of ReportSpam conditional field.
func (*PeerSettings) SetShareContact ¶
func (p *PeerSettings) SetShareContact(value bool)
SetShareContact sets value of ShareContact conditional field.
func (*PeerSettings) String ¶ added in v0.12.0
func (p *PeerSettings) String() string
String implements fmt.Stringer.
type PeerSettingsHandler ¶ added in v0.9.0
type PeerSettingsHandler func(ctx UpdateContext, update *UpdatePeerSettings) error
PeerSettingsHandler is a PeerSettings event handler.
type PeerUser ¶
type PeerUser struct {
// User identifier
UserID int
}
PeerUser represents TL type `peerUser#9db1bc6d`. Chat partner
See https://core.telegram.org/constructor/peerUser for reference.
type PhoneAcceptCallRequest ¶
type PhoneAcceptCallRequest struct {
// The call to accept
Peer InputPhoneCall
// Parameter for E2E encryption key exchange »¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GB []byte
// Phone call settings
Protocol PhoneCallProtocol
}
PhoneAcceptCallRequest represents TL type `phone.acceptCall#3bd2b4a0`. Accept incoming call
See https://core.telegram.org/method/phone.acceptCall for reference.
func (*PhoneAcceptCallRequest) Decode ¶
func (a *PhoneAcceptCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneAcceptCallRequest) Encode ¶
func (a *PhoneAcceptCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneAcceptCallRequest) String ¶ added in v0.12.0
func (a *PhoneAcceptCallRequest) String() string
String implements fmt.Stringer.
type PhoneCall ¶
type PhoneCall struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether P2P connection to the other peer is allowed
P2PAllowed bool
// Whether this is a video call
Video bool
// Call ID
ID int64
// Access hash
AccessHash int64
// Date of creation of the call
Date int
// User ID of the creator of the call
AdminID int
// User ID of the other participant in the call
ParticipantID int
// Parameter for key exchange¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GAOrB []byte
// Key fingerprint¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
KeyFingerprint int64
// Call protocol info to be passed to libtgvoip
Protocol PhoneCallProtocol
// List of endpoints the user can connect to to exchange call data
Connections []PhoneConnectionClass
// When was the call actually started
StartDate int
}
PhoneCall represents TL type `phoneCall#8742ae7f`. Phone call
See https://core.telegram.org/constructor/phoneCall for reference.
func (*PhoneCall) SetP2PAllowed ¶
SetP2PAllowed sets value of P2PAllowed conditional field.
type PhoneCallAccepted ¶
type PhoneCallAccepted struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a video call
Video bool
// ID of accepted phone call
ID int64
// Access hash of phone call
AccessHash int64
// When was the call accepted
Date int
// ID of the call creator
AdminID int
// ID of the other user in the call
ParticipantID int
// B parameter for secure E2E phone call key exchange¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GB []byte
// Protocol to use for phone call
Protocol PhoneCallProtocol
}
PhoneCallAccepted represents TL type `phoneCallAccepted#997c454a`. An accepted phone call
See https://core.telegram.org/constructor/phoneCallAccepted for reference.
func (*PhoneCallAccepted) Decode ¶
func (p *PhoneCallAccepted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallAccepted) Encode ¶
func (p *PhoneCallAccepted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallAccepted) SetVideo ¶
func (p *PhoneCallAccepted) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneCallAccepted) String ¶ added in v0.12.0
func (p *PhoneCallAccepted) String() string
String implements fmt.Stringer.
type PhoneCallBox ¶
type PhoneCallBox struct {
PhoneCall PhoneCallClass
}
PhoneCall boxes the PhoneCallClass providing a helper.
type PhoneCallClass ¶
type PhoneCallClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhoneCallClass represents PhoneCall generic type.
See https://core.telegram.org/type/PhoneCall for reference.
Example:
g, err := DecodePhoneCall(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhoneCallEmpty: // phoneCallEmpty#5366c915
case *PhoneCallWaiting: // phoneCallWaiting#1b8f4ad1
case *PhoneCallRequested: // phoneCallRequested#87eabb53
case *PhoneCallAccepted: // phoneCallAccepted#997c454a
case *PhoneCall: // phoneCall#8742ae7f
case *PhoneCallDiscarded: // phoneCallDiscarded#50ca4de1
default: panic(v)
}
func DecodePhoneCall ¶
func DecodePhoneCall(buf *bin.Buffer) (PhoneCallClass, error)
DecodePhoneCall implements binary de-serialization for PhoneCallClass.
type PhoneCallDiscardReasonBox ¶
type PhoneCallDiscardReasonBox struct {
PhoneCallDiscardReason PhoneCallDiscardReasonClass
}
PhoneCallDiscardReason boxes the PhoneCallDiscardReasonClass providing a helper.
type PhoneCallDiscardReasonBusy ¶
type PhoneCallDiscardReasonBusy struct {
}
PhoneCallDiscardReasonBusy represents TL type `phoneCallDiscardReasonBusy#faf7e8c9`. The phone call was discared because the user is busy in another call
See https://core.telegram.org/constructor/phoneCallDiscardReasonBusy for reference.
func (*PhoneCallDiscardReasonBusy) Decode ¶
func (p *PhoneCallDiscardReasonBusy) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallDiscardReasonBusy) Encode ¶
func (p *PhoneCallDiscardReasonBusy) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallDiscardReasonBusy) String ¶ added in v0.12.0
func (p *PhoneCallDiscardReasonBusy) String() string
String implements fmt.Stringer.
type PhoneCallDiscardReasonClass ¶
type PhoneCallDiscardReasonClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhoneCallDiscardReasonClass represents PhoneCallDiscardReason generic type.
See https://core.telegram.org/type/PhoneCallDiscardReason for reference.
Example:
g, err := DecodePhoneCallDiscardReason(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhoneCallDiscardReasonMissed: // phoneCallDiscardReasonMissed#85e42301
case *PhoneCallDiscardReasonDisconnect: // phoneCallDiscardReasonDisconnect#e095c1a0
case *PhoneCallDiscardReasonHangup: // phoneCallDiscardReasonHangup#57adc690
case *PhoneCallDiscardReasonBusy: // phoneCallDiscardReasonBusy#faf7e8c9
default: panic(v)
}
func DecodePhoneCallDiscardReason ¶
func DecodePhoneCallDiscardReason(buf *bin.Buffer) (PhoneCallDiscardReasonClass, error)
DecodePhoneCallDiscardReason implements binary de-serialization for PhoneCallDiscardReasonClass.
type PhoneCallDiscardReasonDisconnect ¶
type PhoneCallDiscardReasonDisconnect struct {
}
PhoneCallDiscardReasonDisconnect represents TL type `phoneCallDiscardReasonDisconnect#e095c1a0`. The phone call was disconnected
See https://core.telegram.org/constructor/phoneCallDiscardReasonDisconnect for reference.
func (*PhoneCallDiscardReasonDisconnect) Decode ¶
func (p *PhoneCallDiscardReasonDisconnect) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallDiscardReasonDisconnect) Encode ¶
func (p *PhoneCallDiscardReasonDisconnect) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallDiscardReasonDisconnect) String ¶ added in v0.12.0
func (p *PhoneCallDiscardReasonDisconnect) String() string
String implements fmt.Stringer.
type PhoneCallDiscardReasonHangup ¶
type PhoneCallDiscardReasonHangup struct {
}
PhoneCallDiscardReasonHangup represents TL type `phoneCallDiscardReasonHangup#57adc690`. The phone call was ended normally
See https://core.telegram.org/constructor/phoneCallDiscardReasonHangup for reference.
func (*PhoneCallDiscardReasonHangup) Decode ¶
func (p *PhoneCallDiscardReasonHangup) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallDiscardReasonHangup) Encode ¶
func (p *PhoneCallDiscardReasonHangup) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallDiscardReasonHangup) String ¶ added in v0.12.0
func (p *PhoneCallDiscardReasonHangup) String() string
String implements fmt.Stringer.
type PhoneCallDiscardReasonMissed ¶
type PhoneCallDiscardReasonMissed struct {
}
PhoneCallDiscardReasonMissed represents TL type `phoneCallDiscardReasonMissed#85e42301`. The phone call was missed
See https://core.telegram.org/constructor/phoneCallDiscardReasonMissed for reference.
func (*PhoneCallDiscardReasonMissed) Decode ¶
func (p *PhoneCallDiscardReasonMissed) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallDiscardReasonMissed) Encode ¶
func (p *PhoneCallDiscardReasonMissed) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallDiscardReasonMissed) String ¶ added in v0.12.0
func (p *PhoneCallDiscardReasonMissed) String() string
String implements fmt.Stringer.
type PhoneCallDiscarded ¶
type PhoneCallDiscarded struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the server required the user to rate¹ the call
//
// Links:
// 1) https://core.telegram.org/method/phone.setCallRating
NeedRating bool
// Whether the server required the client to send¹ the libtgvoip call debug data
//
// Links:
// 1) https://core.telegram.org/method/phone.saveCallDebug
NeedDebug bool
// Whether the call was a video call
Video bool
// Call ID
ID int64
// Why was the phone call discarded
//
// Use SetReason and GetReason helpers.
Reason PhoneCallDiscardReasonClass
// Duration of the phone call in seconds
//
// Use SetDuration and GetDuration helpers.
Duration int
}
PhoneCallDiscarded represents TL type `phoneCallDiscarded#50ca4de1`. Indicates a discarded phone call
See https://core.telegram.org/constructor/phoneCallDiscarded for reference.
func (*PhoneCallDiscarded) Decode ¶
func (p *PhoneCallDiscarded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallDiscarded) Encode ¶
func (p *PhoneCallDiscarded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallDiscarded) GetDuration ¶
func (p *PhoneCallDiscarded) GetDuration() (value int, ok bool)
GetDuration returns value of Duration conditional field and boolean which is true if field was set.
func (*PhoneCallDiscarded) GetReason ¶
func (p *PhoneCallDiscarded) GetReason() (value PhoneCallDiscardReasonClass, ok bool)
GetReason returns value of Reason conditional field and boolean which is true if field was set.
func (*PhoneCallDiscarded) SetDuration ¶
func (p *PhoneCallDiscarded) SetDuration(value int)
SetDuration sets value of Duration conditional field.
func (*PhoneCallDiscarded) SetNeedDebug ¶
func (p *PhoneCallDiscarded) SetNeedDebug(value bool)
SetNeedDebug sets value of NeedDebug conditional field.
func (*PhoneCallDiscarded) SetNeedRating ¶
func (p *PhoneCallDiscarded) SetNeedRating(value bool)
SetNeedRating sets value of NeedRating conditional field.
func (*PhoneCallDiscarded) SetReason ¶
func (p *PhoneCallDiscarded) SetReason(value PhoneCallDiscardReasonClass)
SetReason sets value of Reason conditional field.
func (*PhoneCallDiscarded) SetVideo ¶
func (p *PhoneCallDiscarded) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneCallDiscarded) String ¶ added in v0.12.0
func (p *PhoneCallDiscarded) String() string
String implements fmt.Stringer.
type PhoneCallEmpty ¶
type PhoneCallEmpty struct {
// Call ID
ID int64
}
PhoneCallEmpty represents TL type `phoneCallEmpty#5366c915`. Empty constructor
See https://core.telegram.org/constructor/phoneCallEmpty for reference.
func (*PhoneCallEmpty) Decode ¶
func (p *PhoneCallEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallEmpty) Encode ¶
func (p *PhoneCallEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallEmpty) String ¶ added in v0.12.0
func (p *PhoneCallEmpty) String() string
String implements fmt.Stringer.
type PhoneCallHandler ¶ added in v0.9.0
type PhoneCallHandler func(ctx UpdateContext, update *UpdatePhoneCall) error
PhoneCallHandler is a PhoneCall event handler.
type PhoneCallProtocol ¶
type PhoneCallProtocol struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to allow P2P connection to the other participant
UDPP2P bool
// Whether to allow connection to the other participants through the reflector servers
UDPReflector bool
// Minimum layer for remote libtgvoip
MinLayer int
// Maximum layer for remote libtgvoip
MaxLayer int
// When using phone.requestCall¹ and phone.acceptCall², specify all library versions supported by the client. The server will merge and choose the best library version supported by both peers, returning only the best value in the result of the callee's phone.acceptCall³ and in the phoneCallAccepted⁴ update received by the caller.
//
// Links:
// 1) https://core.telegram.org/method/phone.requestCall
// 2) https://core.telegram.org/method/phone.acceptCall
// 3) https://core.telegram.org/method/phone.acceptCall
// 4) https://core.telegram.org/constructor/phoneCallAccepted
LibraryVersions []string
}
PhoneCallProtocol represents TL type `phoneCallProtocol#fc878fc8`. Protocol info for libtgvoip
See https://core.telegram.org/constructor/phoneCallProtocol for reference.
func (*PhoneCallProtocol) Decode ¶
func (p *PhoneCallProtocol) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallProtocol) Encode ¶
func (p *PhoneCallProtocol) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallProtocol) SetUDPP2P ¶
func (p *PhoneCallProtocol) SetUDPP2P(value bool)
SetUDPP2P sets value of UDPP2P conditional field.
func (*PhoneCallProtocol) SetUDPReflector ¶
func (p *PhoneCallProtocol) SetUDPReflector(value bool)
SetUDPReflector sets value of UDPReflector conditional field.
func (*PhoneCallProtocol) String ¶ added in v0.12.0
func (p *PhoneCallProtocol) String() string
String implements fmt.Stringer.
type PhoneCallRequested ¶
type PhoneCallRequested struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a video call
Video bool
// Phone call ID
ID int64
// Access hash
AccessHash int64
// When was the phone call created
Date int
// ID of the creator of the phone call
AdminID int
// ID of the other participant of the phone call
ParticipantID int
// Parameter for key exchange¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GAHash []byte
// Call protocol info to be passed to libtgvoip
Protocol PhoneCallProtocol
}
PhoneCallRequested represents TL type `phoneCallRequested#87eabb53`. Requested phone call
See https://core.telegram.org/constructor/phoneCallRequested for reference.
func (*PhoneCallRequested) Decode ¶
func (p *PhoneCallRequested) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallRequested) Encode ¶
func (p *PhoneCallRequested) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallRequested) SetVideo ¶
func (p *PhoneCallRequested) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneCallRequested) String ¶ added in v0.12.0
func (p *PhoneCallRequested) String() string
String implements fmt.Stringer.
type PhoneCallSignalingDataHandler ¶ added in v0.9.0
type PhoneCallSignalingDataHandler func(ctx UpdateContext, update *UpdatePhoneCallSignalingData) error
PhoneCallSignalingDataHandler is a PhoneCallSignalingData event handler.
type PhoneCallWaiting ¶
type PhoneCallWaiting struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Is this a video call
Video bool
// Call ID
ID int64
// Access hash
AccessHash int64
// Date
Date int
// Admin ID
AdminID int
// Participant ID
ParticipantID int
// Phone call protocol info
Protocol PhoneCallProtocol
// When was the phone call received
//
// Use SetReceiveDate and GetReceiveDate helpers.
ReceiveDate int
}
PhoneCallWaiting represents TL type `phoneCallWaiting#1b8f4ad1`. Incoming phone call
See https://core.telegram.org/constructor/phoneCallWaiting for reference.
func (*PhoneCallWaiting) Decode ¶
func (p *PhoneCallWaiting) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCallWaiting) Encode ¶
func (p *PhoneCallWaiting) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCallWaiting) GetReceiveDate ¶
func (p *PhoneCallWaiting) GetReceiveDate() (value int, ok bool)
GetReceiveDate returns value of ReceiveDate conditional field and boolean which is true if field was set.
func (*PhoneCallWaiting) SetReceiveDate ¶
func (p *PhoneCallWaiting) SetReceiveDate(value int)
SetReceiveDate sets value of ReceiveDate conditional field.
func (*PhoneCallWaiting) SetVideo ¶
func (p *PhoneCallWaiting) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneCallWaiting) String ¶ added in v0.12.0
func (p *PhoneCallWaiting) String() string
String implements fmt.Stringer.
type PhoneCheckGroupCallRequest ¶ added in v0.13.0
type PhoneCheckGroupCallRequest struct {
// Call field of PhoneCheckGroupCallRequest.
Call InputGroupCall
// Source field of PhoneCheckGroupCallRequest.
Source int
}
PhoneCheckGroupCallRequest represents TL type `phone.checkGroupCall#b74a7bea`.
See https://core.telegram.org/method/phone.checkGroupCall for reference.
func (*PhoneCheckGroupCallRequest) Decode ¶ added in v0.13.0
func (c *PhoneCheckGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCheckGroupCallRequest) Encode ¶ added in v0.13.0
func (c *PhoneCheckGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCheckGroupCallRequest) String ¶ added in v0.13.0
func (c *PhoneCheckGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneConfirmCallRequest ¶
type PhoneConfirmCallRequest struct {
// The phone call
Peer InputPhoneCall
// Parameter for E2E encryption key exchange »¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GA []byte
// Key fingerprint
KeyFingerprint int64
// Phone call settings
Protocol PhoneCallProtocol
}
PhoneConfirmCallRequest represents TL type `phone.confirmCall#2efe1722`. Complete phone call E2E encryption key exchange »¹
Links:
See https://core.telegram.org/method/phone.confirmCall for reference.
func (*PhoneConfirmCallRequest) Decode ¶
func (c *PhoneConfirmCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneConfirmCallRequest) Encode ¶
func (c *PhoneConfirmCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneConfirmCallRequest) String ¶ added in v0.12.0
func (c *PhoneConfirmCallRequest) String() string
String implements fmt.Stringer.
type PhoneConnection ¶
type PhoneConnection struct {
// Endpoint ID
ID int64
// IP address of endpoint
IP string
// IPv6 address of endpoint
Ipv6 string
// Port ID
Port int
// Our peer tag
PeerTag []byte
}
PhoneConnection represents TL type `phoneConnection#9d4c17c0`. Identifies an endpoint that can be used to connect to the other user in a phone call
See https://core.telegram.org/constructor/phoneConnection for reference.
func (*PhoneConnection) Decode ¶
func (p *PhoneConnection) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneConnection) Encode ¶
func (p *PhoneConnection) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneConnection) String ¶ added in v0.12.0
func (p *PhoneConnection) String() string
String implements fmt.Stringer.
type PhoneConnectionBox ¶
type PhoneConnectionBox struct {
PhoneConnection PhoneConnectionClass
}
PhoneConnection boxes the PhoneConnectionClass providing a helper.
type PhoneConnectionClass ¶
type PhoneConnectionClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhoneConnectionClass represents PhoneConnection generic type.
See https://core.telegram.org/type/PhoneConnection for reference.
Example:
g, err := DecodePhoneConnection(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhoneConnection: // phoneConnection#9d4c17c0
case *PhoneConnectionWebrtc: // phoneConnectionWebrtc#635fe375
default: panic(v)
}
func DecodePhoneConnection ¶
func DecodePhoneConnection(buf *bin.Buffer) (PhoneConnectionClass, error)
DecodePhoneConnection implements binary de-serialization for PhoneConnectionClass.
type PhoneConnectionWebrtc ¶
type PhoneConnectionWebrtc struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a TURN endpoint
Turn bool
// Whether this is a STUN endpoint
Stun bool
// Endpoint ID
ID int64
// IP address
IP string
// IPv6 address
Ipv6 string
// Port
Port int
// Username
Username string
// Password
Password string
}
PhoneConnectionWebrtc represents TL type `phoneConnectionWebrtc#635fe375`. WebRTC connection parameters
See https://core.telegram.org/constructor/phoneConnectionWebrtc for reference.
func (*PhoneConnectionWebrtc) Decode ¶
func (p *PhoneConnectionWebrtc) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneConnectionWebrtc) Encode ¶
func (p *PhoneConnectionWebrtc) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneConnectionWebrtc) SetStun ¶
func (p *PhoneConnectionWebrtc) SetStun(value bool)
SetStun sets value of Stun conditional field.
func (*PhoneConnectionWebrtc) SetTurn ¶
func (p *PhoneConnectionWebrtc) SetTurn(value bool)
SetTurn sets value of Turn conditional field.
func (*PhoneConnectionWebrtc) String ¶ added in v0.12.0
func (p *PhoneConnectionWebrtc) String() string
String implements fmt.Stringer.
type PhoneCreateGroupCallRequest ¶ added in v0.13.0
type PhoneCreateGroupCallRequest struct {
// Peer field of PhoneCreateGroupCallRequest.
Peer InputPeerClass
// RandomID field of PhoneCreateGroupCallRequest.
RandomID int
}
PhoneCreateGroupCallRequest represents TL type `phone.createGroupCall#bd3dabe0`.
See https://core.telegram.org/method/phone.createGroupCall for reference.
func (*PhoneCreateGroupCallRequest) Decode ¶ added in v0.13.0
func (c *PhoneCreateGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneCreateGroupCallRequest) Encode ¶ added in v0.13.0
func (c *PhoneCreateGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneCreateGroupCallRequest) String ¶ added in v0.13.0
func (c *PhoneCreateGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneDiscardCallRequest ¶
type PhoneDiscardCallRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a video call
Video bool
// The phone call
Peer InputPhoneCall
// Call duration
Duration int
// Why was the call discarded
Reason PhoneCallDiscardReasonClass
// Preferred libtgvoip relay ID
ConnectionID int64
}
PhoneDiscardCallRequest represents TL type `phone.discardCall#b2cbc1c0`. Refuse or end running call
See https://core.telegram.org/method/phone.discardCall for reference.
func (*PhoneDiscardCallRequest) Decode ¶
func (d *PhoneDiscardCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneDiscardCallRequest) Encode ¶
func (d *PhoneDiscardCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneDiscardCallRequest) SetVideo ¶
func (d *PhoneDiscardCallRequest) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneDiscardCallRequest) String ¶ added in v0.12.0
func (d *PhoneDiscardCallRequest) String() string
String implements fmt.Stringer.
type PhoneDiscardGroupCallRequest ¶ added in v0.13.0
type PhoneDiscardGroupCallRequest struct {
// Call field of PhoneDiscardGroupCallRequest.
Call InputGroupCall
}
PhoneDiscardGroupCallRequest represents TL type `phone.discardGroupCall#7a777135`.
See https://core.telegram.org/method/phone.discardGroupCall for reference.
func (*PhoneDiscardGroupCallRequest) Decode ¶ added in v0.13.0
func (d *PhoneDiscardGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneDiscardGroupCallRequest) Encode ¶ added in v0.13.0
func (d *PhoneDiscardGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneDiscardGroupCallRequest) String ¶ added in v0.13.0
func (d *PhoneDiscardGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneEditGroupCallMemberRequest ¶ added in v0.13.0
type PhoneEditGroupCallMemberRequest struct {
// Flags field of PhoneEditGroupCallMemberRequest.
Flags bin.Fields
// Muted field of PhoneEditGroupCallMemberRequest.
Muted bool
// Call field of PhoneEditGroupCallMemberRequest.
Call InputGroupCall
// UserID field of PhoneEditGroupCallMemberRequest.
UserID InputUserClass
}
PhoneEditGroupCallMemberRequest represents TL type `phone.editGroupCallMember#63146ae4`.
See https://core.telegram.org/method/phone.editGroupCallMember for reference.
func (*PhoneEditGroupCallMemberRequest) Decode ¶ added in v0.13.0
func (e *PhoneEditGroupCallMemberRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneEditGroupCallMemberRequest) Encode ¶ added in v0.13.0
func (e *PhoneEditGroupCallMemberRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneEditGroupCallMemberRequest) SetMuted ¶ added in v0.13.0
func (e *PhoneEditGroupCallMemberRequest) SetMuted(value bool)
SetMuted sets value of Muted conditional field.
func (*PhoneEditGroupCallMemberRequest) String ¶ added in v0.13.0
func (e *PhoneEditGroupCallMemberRequest) String() string
String implements fmt.Stringer.
type PhoneGetCallConfigRequest ¶
type PhoneGetCallConfigRequest struct {
}
PhoneGetCallConfigRequest represents TL type `phone.getCallConfig#55451fa9`. Get phone call configuration to be passed to libtgvoip's shared config
See https://core.telegram.org/method/phone.getCallConfig for reference.
func (*PhoneGetCallConfigRequest) Decode ¶
func (g *PhoneGetCallConfigRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneGetCallConfigRequest) Encode ¶
func (g *PhoneGetCallConfigRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneGetCallConfigRequest) String ¶ added in v0.12.0
func (g *PhoneGetCallConfigRequest) String() string
String implements fmt.Stringer.
type PhoneGetGroupCallRequest ¶ added in v0.13.0
type PhoneGetGroupCallRequest struct {
// Call field of PhoneGetGroupCallRequest.
Call InputGroupCall
}
PhoneGetGroupCallRequest represents TL type `phone.getGroupCall#c7cb017`.
See https://core.telegram.org/method/phone.getGroupCall for reference.
func (*PhoneGetGroupCallRequest) Decode ¶ added in v0.13.0
func (g *PhoneGetGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneGetGroupCallRequest) Encode ¶ added in v0.13.0
func (g *PhoneGetGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneGetGroupCallRequest) String ¶ added in v0.13.0
func (g *PhoneGetGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneGetGroupParticipantsRequest ¶ added in v0.13.0
type PhoneGetGroupParticipantsRequest struct {
// Call field of PhoneGetGroupParticipantsRequest.
Call InputGroupCall
// Ids field of PhoneGetGroupParticipantsRequest.
Ids []int
// Sources field of PhoneGetGroupParticipantsRequest.
Sources []int
// Offset field of PhoneGetGroupParticipantsRequest.
Offset string
// Limit field of PhoneGetGroupParticipantsRequest.
Limit int
}
PhoneGetGroupParticipantsRequest represents TL type `phone.getGroupParticipants#c9f1d285`.
See https://core.telegram.org/method/phone.getGroupParticipants for reference.
func (*PhoneGetGroupParticipantsRequest) Decode ¶ added in v0.13.0
func (g *PhoneGetGroupParticipantsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneGetGroupParticipantsRequest) Encode ¶ added in v0.13.0
func (g *PhoneGetGroupParticipantsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneGetGroupParticipantsRequest) String ¶ added in v0.13.0
func (g *PhoneGetGroupParticipantsRequest) String() string
String implements fmt.Stringer.
type PhoneGroupCall ¶ added in v0.13.0
type PhoneGroupCall struct {
// Call field of PhoneGroupCall.
Call GroupCallClass
// Participants field of PhoneGroupCall.
Participants []GroupCallParticipant
// ParticipantsNextOffset field of PhoneGroupCall.
ParticipantsNextOffset string
// Users field of PhoneGroupCall.
Users []UserClass
}
PhoneGroupCall represents TL type `phone.groupCall#66ab0bfc`.
See https://core.telegram.org/constructor/phone.groupCall for reference.
func (*PhoneGroupCall) Decode ¶ added in v0.13.0
func (g *PhoneGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneGroupCall) Encode ¶ added in v0.13.0
func (g *PhoneGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneGroupCall) String ¶ added in v0.13.0
func (g *PhoneGroupCall) String() string
String implements fmt.Stringer.
type PhoneGroupParticipants ¶ added in v0.13.0
type PhoneGroupParticipants struct {
// Count field of PhoneGroupParticipants.
Count int
// Participants field of PhoneGroupParticipants.
Participants []GroupCallParticipant
// NextOffset field of PhoneGroupParticipants.
NextOffset string
// Users field of PhoneGroupParticipants.
Users []UserClass
// Version field of PhoneGroupParticipants.
Version int
}
PhoneGroupParticipants represents TL type `phone.groupParticipants#9cfeb92d`.
See https://core.telegram.org/constructor/phone.groupParticipants for reference.
func (*PhoneGroupParticipants) Decode ¶ added in v0.13.0
func (g *PhoneGroupParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneGroupParticipants) Encode ¶ added in v0.13.0
func (g *PhoneGroupParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneGroupParticipants) String ¶ added in v0.13.0
func (g *PhoneGroupParticipants) String() string
String implements fmt.Stringer.
type PhoneInviteToGroupCallRequest ¶ added in v0.13.0
type PhoneInviteToGroupCallRequest struct {
// Call field of PhoneInviteToGroupCallRequest.
Call InputGroupCall
// Users field of PhoneInviteToGroupCallRequest.
Users []InputUserClass
}
PhoneInviteToGroupCallRequest represents TL type `phone.inviteToGroupCall#7b393160`.
See https://core.telegram.org/method/phone.inviteToGroupCall for reference.
func (*PhoneInviteToGroupCallRequest) Decode ¶ added in v0.13.0
func (i *PhoneInviteToGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneInviteToGroupCallRequest) Encode ¶ added in v0.13.0
func (i *PhoneInviteToGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneInviteToGroupCallRequest) String ¶ added in v0.13.0
func (i *PhoneInviteToGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneJoinGroupCallRequest ¶ added in v0.13.0
type PhoneJoinGroupCallRequest struct {
// Flags field of PhoneJoinGroupCallRequest.
Flags bin.Fields
// Muted field of PhoneJoinGroupCallRequest.
Muted bool
// Call field of PhoneJoinGroupCallRequest.
Call InputGroupCall
// Params field of PhoneJoinGroupCallRequest.
Params DataJSON
}
PhoneJoinGroupCallRequest represents TL type `phone.joinGroupCall#5f9c8e62`.
See https://core.telegram.org/method/phone.joinGroupCall for reference.
func (*PhoneJoinGroupCallRequest) Decode ¶ added in v0.13.0
func (j *PhoneJoinGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneJoinGroupCallRequest) Encode ¶ added in v0.13.0
func (j *PhoneJoinGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneJoinGroupCallRequest) SetMuted ¶ added in v0.13.0
func (j *PhoneJoinGroupCallRequest) SetMuted(value bool)
SetMuted sets value of Muted conditional field.
func (*PhoneJoinGroupCallRequest) String ¶ added in v0.13.0
func (j *PhoneJoinGroupCallRequest) String() string
String implements fmt.Stringer.
type PhoneLeaveGroupCallRequest ¶ added in v0.13.0
type PhoneLeaveGroupCallRequest struct {
// Call field of PhoneLeaveGroupCallRequest.
Call InputGroupCall
// Source field of PhoneLeaveGroupCallRequest.
Source int
}
PhoneLeaveGroupCallRequest represents TL type `phone.leaveGroupCall#500377f9`.
See https://core.telegram.org/method/phone.leaveGroupCall for reference.
func (*PhoneLeaveGroupCallRequest) Decode ¶ added in v0.13.0
func (l *PhoneLeaveGroupCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneLeaveGroupCallRequest) Encode ¶ added in v0.13.0
func (l *PhoneLeaveGroupCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneLeaveGroupCallRequest) String ¶ added in v0.13.0
func (l *PhoneLeaveGroupCallRequest) String() string
String implements fmt.Stringer.
type PhonePhoneCall ¶
type PhonePhoneCall struct {
// The VoIP phone call
PhoneCall PhoneCallClass
// VoIP phone call participants
Users []UserClass
}
PhonePhoneCall represents TL type `phone.phoneCall#ec82e140`. A VoIP phone call
See https://core.telegram.org/constructor/phone.phoneCall for reference.
func (*PhonePhoneCall) Decode ¶
func (p *PhonePhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhonePhoneCall) Encode ¶
func (p *PhonePhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhonePhoneCall) String ¶ added in v0.12.0
func (p *PhonePhoneCall) String() string
String implements fmt.Stringer.
type PhoneReceivedCallRequest ¶
type PhoneReceivedCallRequest struct {
// The phone call we're currently in
Peer InputPhoneCall
}
PhoneReceivedCallRequest represents TL type `phone.receivedCall#17d54f61`. Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended.
See https://core.telegram.org/method/phone.receivedCall for reference.
func (*PhoneReceivedCallRequest) Decode ¶
func (r *PhoneReceivedCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneReceivedCallRequest) Encode ¶
func (r *PhoneReceivedCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneReceivedCallRequest) String ¶ added in v0.12.0
func (r *PhoneReceivedCallRequest) String() string
String implements fmt.Stringer.
type PhoneRequestCallRequest ¶
type PhoneRequestCallRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to start a video call
Video bool
// Destination of the phone call
UserID InputUserClass
// Random ID to avoid resending the same object
RandomID int
// Parameter for E2E encryption key exchange »¹
//
// Links:
// 1) https://core.telegram.org/api/end-to-end/voice-calls
GAHash []byte
// Phone call settings
Protocol PhoneCallProtocol
}
PhoneRequestCallRequest represents TL type `phone.requestCall#42ff96ed`. Start a telegram phone call
See https://core.telegram.org/method/phone.requestCall for reference.
func (*PhoneRequestCallRequest) Decode ¶
func (r *PhoneRequestCallRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneRequestCallRequest) Encode ¶
func (r *PhoneRequestCallRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneRequestCallRequest) SetVideo ¶
func (r *PhoneRequestCallRequest) SetVideo(value bool)
SetVideo sets value of Video conditional field.
func (*PhoneRequestCallRequest) String ¶ added in v0.12.0
func (r *PhoneRequestCallRequest) String() string
String implements fmt.Stringer.
type PhoneSaveCallDebugRequest ¶
type PhoneSaveCallDebugRequest struct {
// Phone call
Peer InputPhoneCall
// Debug statistics obtained from libtgvoip
Debug DataJSON
}
PhoneSaveCallDebugRequest represents TL type `phone.saveCallDebug#277add7e`. Send phone call debug data to server
See https://core.telegram.org/method/phone.saveCallDebug for reference.
func (*PhoneSaveCallDebugRequest) Decode ¶
func (s *PhoneSaveCallDebugRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneSaveCallDebugRequest) Encode ¶
func (s *PhoneSaveCallDebugRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneSaveCallDebugRequest) String ¶ added in v0.12.0
func (s *PhoneSaveCallDebugRequest) String() string
String implements fmt.Stringer.
type PhoneSendSignalingDataRequest ¶
type PhoneSendSignalingDataRequest struct {
// Phone call
Peer InputPhoneCall
// Signaling payload
Data []byte
}
PhoneSendSignalingDataRequest represents TL type `phone.sendSignalingData#ff7a9383`. Send VoIP signaling data
See https://core.telegram.org/method/phone.sendSignalingData for reference.
func (*PhoneSendSignalingDataRequest) Decode ¶
func (s *PhoneSendSignalingDataRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneSendSignalingDataRequest) Encode ¶
func (s *PhoneSendSignalingDataRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneSendSignalingDataRequest) String ¶ added in v0.12.0
func (s *PhoneSendSignalingDataRequest) String() string
String implements fmt.Stringer.
type PhoneSetCallRatingRequest ¶
type PhoneSetCallRatingRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the user decided on their own initiative to rate the call
UserInitiative bool
// The call to rate
Peer InputPhoneCall
// Rating in 1-5 stars
Rating int
// An additional comment
Comment string
}
PhoneSetCallRatingRequest represents TL type `phone.setCallRating#59ead627`. Rate a call
See https://core.telegram.org/method/phone.setCallRating for reference.
func (*PhoneSetCallRatingRequest) Decode ¶
func (s *PhoneSetCallRatingRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneSetCallRatingRequest) Encode ¶
func (s *PhoneSetCallRatingRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneSetCallRatingRequest) SetUserInitiative ¶
func (s *PhoneSetCallRatingRequest) SetUserInitiative(value bool)
SetUserInitiative sets value of UserInitiative conditional field.
func (*PhoneSetCallRatingRequest) String ¶ added in v0.12.0
func (s *PhoneSetCallRatingRequest) String() string
String implements fmt.Stringer.
type PhoneToggleGroupCallSettingsRequest ¶ added in v0.13.0
type PhoneToggleGroupCallSettingsRequest struct {
// Flags field of PhoneToggleGroupCallSettingsRequest.
Flags bin.Fields
// Call field of PhoneToggleGroupCallSettingsRequest.
Call InputGroupCall
// JoinMuted field of PhoneToggleGroupCallSettingsRequest.
//
// Use SetJoinMuted and GetJoinMuted helpers.
JoinMuted bool
}
PhoneToggleGroupCallSettingsRequest represents TL type `phone.toggleGroupCallSettings#74bbb43d`.
See https://core.telegram.org/method/phone.toggleGroupCallSettings for reference.
func (*PhoneToggleGroupCallSettingsRequest) Decode ¶ added in v0.13.0
func (t *PhoneToggleGroupCallSettingsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhoneToggleGroupCallSettingsRequest) Encode ¶ added in v0.13.0
func (t *PhoneToggleGroupCallSettingsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhoneToggleGroupCallSettingsRequest) GetJoinMuted ¶ added in v0.17.0
func (t *PhoneToggleGroupCallSettingsRequest) GetJoinMuted() (value bool, ok bool)
GetJoinMuted returns value of JoinMuted conditional field and boolean which is true if field was set.
func (*PhoneToggleGroupCallSettingsRequest) SetJoinMuted ¶ added in v0.13.0
func (t *PhoneToggleGroupCallSettingsRequest) SetJoinMuted(value bool)
SetJoinMuted sets value of JoinMuted conditional field.
func (*PhoneToggleGroupCallSettingsRequest) String ¶ added in v0.13.0
func (t *PhoneToggleGroupCallSettingsRequest) String() string
String implements fmt.Stringer.
type Photo ¶
type Photo struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the photo has mask stickers attached to it
HasStickers bool
// ID
ID int64
// Access hash
AccessHash int64
// file reference¹
//
// Links:
// 1) https://core.telegram.org/api/file_reference
FileReference []byte
// Date of upload
Date int
// Available sizes for download
Sizes []PhotoSizeClass
// For animated profiles¹, the MPEG4 videos
//
// Links:
// 1) https://core.telegram.org/api/files#animated-profile-pictures
//
// Use SetVideoSizes and GetVideoSizes helpers.
VideoSizes []VideoSize
// DC ID to use for download
DCID int
}
Photo represents TL type `photo#fb197a65`. Photo
See https://core.telegram.org/constructor/photo for reference.
func (*Photo) GetVideoSizes ¶
GetVideoSizes returns value of VideoSizes conditional field and boolean which is true if field was set.
func (*Photo) SetHasStickers ¶
SetHasStickers sets value of HasStickers conditional field.
func (*Photo) SetVideoSizes ¶
SetVideoSizes sets value of VideoSizes conditional field.
type PhotoBox ¶
type PhotoBox struct {
Photo PhotoClass
}
Photo boxes the PhotoClass providing a helper.
type PhotoCachedSize ¶
type PhotoCachedSize struct {
// Thumbnail type
Type string
// File location
Location FileLocationToBeDeprecated
// Image width
W int
// Image height
H int
// Binary data, file content
Bytes []byte
}
PhotoCachedSize represents TL type `photoCachedSize#e9a734fa`. Description of an image and its content.
See https://core.telegram.org/constructor/photoCachedSize for reference.
func (*PhotoCachedSize) Decode ¶
func (p *PhotoCachedSize) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoCachedSize) Encode ¶
func (p *PhotoCachedSize) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoCachedSize) String ¶ added in v0.12.0
func (p *PhotoCachedSize) String() string
String implements fmt.Stringer.
type PhotoClass ¶
type PhotoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhotoClass represents Photo generic type.
See https://core.telegram.org/type/Photo for reference.
Example:
g, err := DecodePhoto(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhotoEmpty: // photoEmpty#2331b22d
case *Photo: // photo#fb197a65
default: panic(v)
}
func DecodePhoto ¶
func DecodePhoto(buf *bin.Buffer) (PhotoClass, error)
DecodePhoto implements binary de-serialization for PhotoClass.
type PhotoEmpty ¶
type PhotoEmpty struct {
// Photo identifier
ID int64
}
PhotoEmpty represents TL type `photoEmpty#2331b22d`. Empty constructor, non-existent photo
See https://core.telegram.org/constructor/photoEmpty for reference.
func (*PhotoEmpty) Decode ¶
func (p *PhotoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoEmpty) Encode ¶
func (p *PhotoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoEmpty) String ¶ added in v0.12.0
func (p *PhotoEmpty) String() string
String implements fmt.Stringer.
type PhotoPathSize ¶
type PhotoPathSize struct {
// Always j
Type string
// Compressed SVG path payload, see here for decompression instructions¹
//
// Links:
// 1) https://core.telegram.org/api/files#vector-thumbnails
Bytes []byte
}
PhotoPathSize represents TL type `photoPathSize#d8214d41`. Messages with animated stickers can have a compressed svg (< 300 bytes) to show the outline of the sticker before fetching the actual lottie animation.
See https://core.telegram.org/constructor/photoPathSize for reference.
func (*PhotoPathSize) Decode ¶
func (p *PhotoPathSize) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoPathSize) Encode ¶
func (p *PhotoPathSize) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoPathSize) String ¶ added in v0.12.0
func (p *PhotoPathSize) String() string
String implements fmt.Stringer.
type PhotoSize ¶
type PhotoSize struct {
// Thumbnail type
Type string
// File location
Location FileLocationToBeDeprecated
// Image width
W int
// Image height
H int
// File size
Size int
}
PhotoSize represents TL type `photoSize#77bfb61b`. Image description.
See https://core.telegram.org/constructor/photoSize for reference.
type PhotoSizeBox ¶
type PhotoSizeBox struct {
PhotoSize PhotoSizeClass
}
PhotoSize boxes the PhotoSizeClass providing a helper.
type PhotoSizeClass ¶
type PhotoSizeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhotoSizeClass represents PhotoSize generic type.
See https://core.telegram.org/type/PhotoSize for reference.
Example:
g, err := DecodePhotoSize(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhotoSizeEmpty: // photoSizeEmpty#e17e23c
case *PhotoSize: // photoSize#77bfb61b
case *PhotoCachedSize: // photoCachedSize#e9a734fa
case *PhotoStrippedSize: // photoStrippedSize#e0b0bc2e
case *PhotoSizeProgressive: // photoSizeProgressive#5aa86a51
case *PhotoPathSize: // photoPathSize#d8214d41
default: panic(v)
}
func DecodePhotoSize ¶
func DecodePhotoSize(buf *bin.Buffer) (PhotoSizeClass, error)
DecodePhotoSize implements binary de-serialization for PhotoSizeClass.
type PhotoSizeEmpty ¶
type PhotoSizeEmpty struct {
// Thumbnail type (see. photoSize¹)
//
// Links:
// 1) https://core.telegram.org/constructor/photoSize
Type string
}
PhotoSizeEmpty represents TL type `photoSizeEmpty#e17e23c`. Empty constructor. Image with this thumbnail is unavailable.
See https://core.telegram.org/constructor/photoSizeEmpty for reference.
func (*PhotoSizeEmpty) Decode ¶
func (p *PhotoSizeEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoSizeEmpty) Encode ¶
func (p *PhotoSizeEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoSizeEmpty) String ¶ added in v0.12.0
func (p *PhotoSizeEmpty) String() string
String implements fmt.Stringer.
type PhotoSizeProgressive ¶
type PhotoSizeProgressive struct {
// Photosize type
Type string
// File location
Location FileLocationToBeDeprecated
// Photo width
W int
// Photo height
H int
// Sizes of progressive JPEG file prefixes, which can be used to preliminarily show the image.
Sizes []int
}
PhotoSizeProgressive represents TL type `photoSizeProgressive#5aa86a51`. Progressively encoded photosize
See https://core.telegram.org/constructor/photoSizeProgressive for reference.
func (*PhotoSizeProgressive) Decode ¶
func (p *PhotoSizeProgressive) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoSizeProgressive) Encode ¶
func (p *PhotoSizeProgressive) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoSizeProgressive) String ¶ added in v0.12.0
func (p *PhotoSizeProgressive) String() string
String implements fmt.Stringer.
type PhotoStrippedSize ¶
type PhotoStrippedSize struct {
// Thumbnail type
Type string
// Thumbnail data, see here for more info on decompression »¹
//
// Links:
// 1) https://core.telegram.org/api/files#stripped-thumbnails
Bytes []byte
}
PhotoStrippedSize represents TL type `photoStrippedSize#e0b0bc2e`. A low-resolution compressed JPG payload
See https://core.telegram.org/constructor/photoStrippedSize for reference.
func (*PhotoStrippedSize) Decode ¶
func (p *PhotoStrippedSize) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotoStrippedSize) Encode ¶
func (p *PhotoStrippedSize) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotoStrippedSize) String ¶ added in v0.12.0
func (p *PhotoStrippedSize) String() string
String implements fmt.Stringer.
type PhotosDeletePhotosRequest ¶
type PhotosDeletePhotosRequest struct {
// Input photos to delete
ID []InputPhotoClass
}
PhotosDeletePhotosRequest represents TL type `photos.deletePhotos#87cf7f2f`. Deletes profile photos.
See https://core.telegram.org/method/photos.deletePhotos for reference.
func (*PhotosDeletePhotosRequest) Decode ¶
func (d *PhotosDeletePhotosRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosDeletePhotosRequest) Encode ¶
func (d *PhotosDeletePhotosRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosDeletePhotosRequest) String ¶ added in v0.12.0
func (d *PhotosDeletePhotosRequest) String() string
String implements fmt.Stringer.
type PhotosGetUserPhotosRequest ¶
type PhotosGetUserPhotosRequest struct {
// User ID
UserID InputUserClass
// Number of list elements to be skipped
Offset int
// If a positive value was transferred, the method will return only photos with IDs less than the set one
MaxID int64
// Number of list elements to be returned
Limit int
}
PhotosGetUserPhotosRequest represents TL type `photos.getUserPhotos#91cd32a8`. Returns the list of user photos.
See https://core.telegram.org/method/photos.getUserPhotos for reference.
func (*PhotosGetUserPhotosRequest) Decode ¶
func (g *PhotosGetUserPhotosRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosGetUserPhotosRequest) Encode ¶
func (g *PhotosGetUserPhotosRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosGetUserPhotosRequest) String ¶ added in v0.12.0
func (g *PhotosGetUserPhotosRequest) String() string
String implements fmt.Stringer.
type PhotosPhoto ¶
type PhotosPhoto struct {
// Photo
Photo PhotoClass
// Users
Users []UserClass
}
PhotosPhoto represents TL type `photos.photo#20212ca8`. Photo with auxiliary data.
See https://core.telegram.org/constructor/photos.photo for reference.
func (*PhotosPhoto) Decode ¶
func (p *PhotosPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosPhoto) Encode ¶
func (p *PhotosPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosPhoto) String ¶ added in v0.12.0
func (p *PhotosPhoto) String() string
String implements fmt.Stringer.
type PhotosPhotos ¶
type PhotosPhotos struct {
// List of photos
Photos []PhotoClass
// List of mentioned users
Users []UserClass
}
PhotosPhotos represents TL type `photos.photos#8dca6aa5`. Full list of photos with auxiliary data.
See https://core.telegram.org/constructor/photos.photos for reference.
func (*PhotosPhotos) Decode ¶
func (p *PhotosPhotos) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosPhotos) Encode ¶
func (p *PhotosPhotos) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosPhotos) String ¶ added in v0.12.0
func (p *PhotosPhotos) String() string
String implements fmt.Stringer.
type PhotosPhotosBox ¶
type PhotosPhotosBox struct {
Photos PhotosPhotosClass
}
PhotosPhotos boxes the PhotosPhotosClass providing a helper.
type PhotosPhotosClass ¶
type PhotosPhotosClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PhotosPhotosClass represents photos.Photos generic type.
See https://core.telegram.org/type/photos.Photos for reference.
Example:
g, err := DecodePhotosPhotos(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PhotosPhotos: // photos.photos#8dca6aa5
case *PhotosPhotosSlice: // photos.photosSlice#15051f54
default: panic(v)
}
func DecodePhotosPhotos ¶
func DecodePhotosPhotos(buf *bin.Buffer) (PhotosPhotosClass, error)
DecodePhotosPhotos implements binary de-serialization for PhotosPhotosClass.
type PhotosPhotosSlice ¶
type PhotosPhotosSlice struct {
// Total number of photos
Count int
// List of photos
Photos []PhotoClass
// List of mentioned users
Users []UserClass
}
PhotosPhotosSlice represents TL type `photos.photosSlice#15051f54`. Incomplete list of photos with auxiliary data.
See https://core.telegram.org/constructor/photos.photosSlice for reference.
func (*PhotosPhotosSlice) Decode ¶
func (p *PhotosPhotosSlice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosPhotosSlice) Encode ¶
func (p *PhotosPhotosSlice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosPhotosSlice) String ¶ added in v0.12.0
func (p *PhotosPhotosSlice) String() string
String implements fmt.Stringer.
type PhotosUpdateProfilePhotoRequest ¶
type PhotosUpdateProfilePhotoRequest struct {
// Input photo
ID InputPhotoClass
}
PhotosUpdateProfilePhotoRequest represents TL type `photos.updateProfilePhoto#72d4742c`. Installs a previously uploaded photo as a profile photo.
See https://core.telegram.org/method/photos.updateProfilePhoto for reference.
func (*PhotosUpdateProfilePhotoRequest) Decode ¶
func (u *PhotosUpdateProfilePhotoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosUpdateProfilePhotoRequest) Encode ¶
func (u *PhotosUpdateProfilePhotoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosUpdateProfilePhotoRequest) String ¶ added in v0.12.0
func (u *PhotosUpdateProfilePhotoRequest) String() string
String implements fmt.Stringer.
type PhotosUploadProfilePhotoRequest ¶
type PhotosUploadProfilePhotoRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// File saved in parts by means of upload.saveFilePart¹ method
//
// Links:
// 1) https://core.telegram.org/method/upload.saveFilePart
//
// Use SetFile and GetFile helpers.
File InputFileClass
// Animated profile picture¹ video
//
// Links:
// 1) https://core.telegram.org/api/files#animated-profile-pictures
//
// Use SetVideo and GetVideo helpers.
Video InputFileClass
// Floating point UNIX timestamp in seconds, indicating the frame of the video that should be used as static preview.
//
// Use SetVideoStartTs and GetVideoStartTs helpers.
VideoStartTs float64
}
PhotosUploadProfilePhotoRequest represents TL type `photos.uploadProfilePhoto#89f30f69`. Updates current user profile photo.
See https://core.telegram.org/method/photos.uploadProfilePhoto for reference.
func (*PhotosUploadProfilePhotoRequest) Decode ¶
func (u *PhotosUploadProfilePhotoRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PhotosUploadProfilePhotoRequest) Encode ¶
func (u *PhotosUploadProfilePhotoRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PhotosUploadProfilePhotoRequest) GetFile ¶
func (u *PhotosUploadProfilePhotoRequest) GetFile() (value InputFileClass, ok bool)
GetFile returns value of File conditional field and boolean which is true if field was set.
func (*PhotosUploadProfilePhotoRequest) GetVideo ¶
func (u *PhotosUploadProfilePhotoRequest) GetVideo() (value InputFileClass, ok bool)
GetVideo returns value of Video conditional field and boolean which is true if field was set.
func (*PhotosUploadProfilePhotoRequest) GetVideoStartTs ¶
func (u *PhotosUploadProfilePhotoRequest) GetVideoStartTs() (value float64, ok bool)
GetVideoStartTs returns value of VideoStartTs conditional field and boolean which is true if field was set.
func (*PhotosUploadProfilePhotoRequest) SetFile ¶
func (u *PhotosUploadProfilePhotoRequest) SetFile(value InputFileClass)
SetFile sets value of File conditional field.
func (*PhotosUploadProfilePhotoRequest) SetVideo ¶
func (u *PhotosUploadProfilePhotoRequest) SetVideo(value InputFileClass)
SetVideo sets value of Video conditional field.
func (*PhotosUploadProfilePhotoRequest) SetVideoStartTs ¶
func (u *PhotosUploadProfilePhotoRequest) SetVideoStartTs(value float64)
SetVideoStartTs sets value of VideoStartTs conditional field.
func (*PhotosUploadProfilePhotoRequest) String ¶ added in v0.12.0
func (u *PhotosUploadProfilePhotoRequest) String() string
String implements fmt.Stringer.
type PinnedChannelMessagesHandler ¶ added in v0.9.0
type PinnedChannelMessagesHandler func(ctx UpdateContext, update *UpdatePinnedChannelMessages) error
PinnedChannelMessagesHandler is a PinnedChannelMessages event handler.
type PinnedDialogsHandler ¶ added in v0.9.0
type PinnedDialogsHandler func(ctx UpdateContext, update *UpdatePinnedDialogs) error
PinnedDialogsHandler is a PinnedDialogs event handler.
type PinnedMessagesHandler ¶ added in v0.9.0
type PinnedMessagesHandler func(ctx UpdateContext, update *UpdatePinnedMessages) error
PinnedMessagesHandler is a PinnedMessages event handler.
type Poll ¶
type Poll struct {
// ID of the poll
ID int64
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the poll is closed and doesn't accept any more answers
Closed bool
// Whether cast votes are publicly visible to all users (non-anonymous poll)
PublicVoters bool
// Whether multiple options can be chosen as answer
MultipleChoice bool
// Whether this is a quiz (with wrong and correct answers, results shown in the return type)
Quiz bool
// The question of the poll
Question string
// The possible answers, vote using messages.sendVote¹.
//
// Links:
// 1) https://core.telegram.org/method/messages.sendVote
Answers []PollAnswer
// Amount of time in seconds the poll will be active after creation, 5-600. Can't be used together with close_date.
//
// Use SetClosePeriod and GetClosePeriod helpers.
ClosePeriod int
// Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future; can't be used together with close_period.
//
// Use SetCloseDate and GetCloseDate helpers.
CloseDate int
}
Poll represents TL type `poll#86e18161`. Poll
See https://core.telegram.org/constructor/poll for reference.
func (*Poll) GetCloseDate ¶
GetCloseDate returns value of CloseDate conditional field and boolean which is true if field was set.
func (*Poll) GetClosePeriod ¶
GetClosePeriod returns value of ClosePeriod conditional field and boolean which is true if field was set.
func (*Poll) SetCloseDate ¶
SetCloseDate sets value of CloseDate conditional field.
func (*Poll) SetClosePeriod ¶
SetClosePeriod sets value of ClosePeriod conditional field.
func (*Poll) SetMultipleChoice ¶
SetMultipleChoice sets value of MultipleChoice conditional field.
func (*Poll) SetPublicVoters ¶
SetPublicVoters sets value of PublicVoters conditional field.
type PollAnswer ¶
type PollAnswer struct {
// Textual representation of the answer
Text string
// The param that has to be passed to messages.sendVote¹.
//
// Links:
// 1) https://core.telegram.org/method/messages.sendVote
Option []byte
}
PollAnswer represents TL type `pollAnswer#6ca9c2e9`. A possible answer of a poll
See https://core.telegram.org/constructor/pollAnswer for reference.
func (*PollAnswer) Decode ¶
func (p *PollAnswer) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PollAnswer) Encode ¶
func (p *PollAnswer) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PollAnswer) String ¶ added in v0.12.0
func (p *PollAnswer) String() string
String implements fmt.Stringer.
type PollAnswerVoters ¶
type PollAnswerVoters struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether we have chosen this answer
Chosen bool
// For quizes, whether the option we have chosen is correct
Correct bool
// The param that has to be passed to messages.sendVote¹.
//
// Links:
// 1) https://core.telegram.org/method/messages.sendVote
Option []byte
// How many users voted for this option
Voters int
}
PollAnswerVoters represents TL type `pollAnswerVoters#3b6ddad2`. A poll answer, and how users voted on it
See https://core.telegram.org/constructor/pollAnswerVoters for reference.
func (*PollAnswerVoters) Decode ¶
func (p *PollAnswerVoters) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PollAnswerVoters) Encode ¶
func (p *PollAnswerVoters) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PollAnswerVoters) SetChosen ¶
func (p *PollAnswerVoters) SetChosen(value bool)
SetChosen sets value of Chosen conditional field.
func (*PollAnswerVoters) SetCorrect ¶
func (p *PollAnswerVoters) SetCorrect(value bool)
SetCorrect sets value of Correct conditional field.
func (*PollAnswerVoters) String ¶ added in v0.12.0
func (p *PollAnswerVoters) String() string
String implements fmt.Stringer.
type PollResults ¶
type PollResults struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Similar to min¹ objects, used for poll constructors that are the same for all users so they don't have option chosen by the current user (you can use messages.getPollResults² to get the full poll results).
//
// Links:
// 1) https://core.telegram.org/api/min
// 2) https://core.telegram.org/method/messages.getPollResults
Min bool
// Poll results
//
// Use SetResults and GetResults helpers.
Results []PollAnswerVoters
// Total number of people that voted in the poll
//
// Use SetTotalVoters and GetTotalVoters helpers.
TotalVoters int
// IDs of the last users that recently voted in the poll
//
// Use SetRecentVoters and GetRecentVoters helpers.
RecentVoters []int
// Explanation of quiz solution
//
// Use SetSolution and GetSolution helpers.
Solution string
// Message entities for styled text in quiz solution¹
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetSolutionEntities and GetSolutionEntities helpers.
SolutionEntities []MessageEntityClass
}
PollResults represents TL type `pollResults#badcc1a3`. Results of poll
See https://core.telegram.org/constructor/pollResults for reference.
func (*PollResults) Decode ¶
func (p *PollResults) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PollResults) Encode ¶
func (p *PollResults) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PollResults) GetRecentVoters ¶
func (p *PollResults) GetRecentVoters() (value []int, ok bool)
GetRecentVoters returns value of RecentVoters conditional field and boolean which is true if field was set.
func (*PollResults) GetResults ¶
func (p *PollResults) GetResults() (value []PollAnswerVoters, ok bool)
GetResults returns value of Results conditional field and boolean which is true if field was set.
func (*PollResults) GetSolution ¶
func (p *PollResults) GetSolution() (value string, ok bool)
GetSolution returns value of Solution conditional field and boolean which is true if field was set.
func (*PollResults) GetSolutionEntities ¶
func (p *PollResults) GetSolutionEntities() (value []MessageEntityClass, ok bool)
GetSolutionEntities returns value of SolutionEntities conditional field and boolean which is true if field was set.
func (*PollResults) GetTotalVoters ¶
func (p *PollResults) GetTotalVoters() (value int, ok bool)
GetTotalVoters returns value of TotalVoters conditional field and boolean which is true if field was set.
func (*PollResults) SetMin ¶
func (p *PollResults) SetMin(value bool)
SetMin sets value of Min conditional field.
func (*PollResults) SetRecentVoters ¶
func (p *PollResults) SetRecentVoters(value []int)
SetRecentVoters sets value of RecentVoters conditional field.
func (*PollResults) SetResults ¶
func (p *PollResults) SetResults(value []PollAnswerVoters)
SetResults sets value of Results conditional field.
func (*PollResults) SetSolution ¶
func (p *PollResults) SetSolution(value string)
SetSolution sets value of Solution conditional field.
func (*PollResults) SetSolutionEntities ¶
func (p *PollResults) SetSolutionEntities(value []MessageEntityClass)
SetSolutionEntities sets value of SolutionEntities conditional field.
func (*PollResults) SetTotalVoters ¶
func (p *PollResults) SetTotalVoters(value int)
SetTotalVoters sets value of TotalVoters conditional field.
func (*PollResults) String ¶ added in v0.12.0
func (p *PollResults) String() string
String implements fmt.Stringer.
type PopularContact ¶
type PopularContact struct {
// Contact identifier
ClientID int64
// How many people imported this contact
Importers int
}
PopularContact represents TL type `popularContact#5ce14175`. Popular contact
See https://core.telegram.org/constructor/popularContact for reference.
func (*PopularContact) Decode ¶
func (p *PopularContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PopularContact) Encode ¶
func (p *PopularContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PopularContact) String ¶ added in v0.12.0
func (p *PopularContact) String() string
String implements fmt.Stringer.
type PostAddress ¶
type PostAddress struct {
// First line for the address
StreetLine1 string
// Second line for the address
StreetLine2 string
// City
City string
// State, if applicable (empty otherwise)
State string
// ISO 3166-1 alpha-2 country code
CountryIso2 string
// Address post code
PostCode string
}
PostAddress represents TL type `postAddress#1e8caaeb`. Shipping address
See https://core.telegram.org/constructor/postAddress for reference.
func (*PostAddress) Decode ¶
func (p *PostAddress) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PostAddress) Encode ¶
func (p *PostAddress) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PostAddress) String ¶ added in v0.12.0
func (p *PostAddress) String() string
String implements fmt.Stringer.
type PrivacyHandler ¶ added in v0.9.0
type PrivacyHandler func(ctx UpdateContext, update *UpdatePrivacy) error
PrivacyHandler is a Privacy event handler.
type PrivacyKeyAddedByPhone ¶
type PrivacyKeyAddedByPhone struct {
}
PrivacyKeyAddedByPhone represents TL type `privacyKeyAddedByPhone#42ffd42b`. Whether people can add you to their contact list by your phone number
See https://core.telegram.org/constructor/privacyKeyAddedByPhone for reference.
func (*PrivacyKeyAddedByPhone) Decode ¶
func (p *PrivacyKeyAddedByPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyAddedByPhone) Encode ¶
func (p *PrivacyKeyAddedByPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyAddedByPhone) String ¶ added in v0.12.0
func (p *PrivacyKeyAddedByPhone) String() string
String implements fmt.Stringer.
type PrivacyKeyBox ¶
type PrivacyKeyBox struct {
PrivacyKey PrivacyKeyClass
}
PrivacyKey boxes the PrivacyKeyClass providing a helper.
type PrivacyKeyChatInvite ¶
type PrivacyKeyChatInvite struct {
}
PrivacyKeyChatInvite represents TL type `privacyKeyChatInvite#500e6dfa`. Whether the user can be invited to chats
See https://core.telegram.org/constructor/privacyKeyChatInvite for reference.
func (*PrivacyKeyChatInvite) Decode ¶
func (p *PrivacyKeyChatInvite) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyChatInvite) Encode ¶
func (p *PrivacyKeyChatInvite) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyChatInvite) String ¶ added in v0.12.0
func (p *PrivacyKeyChatInvite) String() string
String implements fmt.Stringer.
type PrivacyKeyClass ¶
type PrivacyKeyClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PrivacyKeyClass represents PrivacyKey generic type.
See https://core.telegram.org/type/PrivacyKey for reference.
Example:
g, err := DecodePrivacyKey(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PrivacyKeyStatusTimestamp: // privacyKeyStatusTimestamp#bc2eab30
case *PrivacyKeyChatInvite: // privacyKeyChatInvite#500e6dfa
case *PrivacyKeyPhoneCall: // privacyKeyPhoneCall#3d662b7b
case *PrivacyKeyPhoneP2P: // privacyKeyPhoneP2P#39491cc8
case *PrivacyKeyForwards: // privacyKeyForwards#69ec56a3
case *PrivacyKeyProfilePhoto: // privacyKeyProfilePhoto#96151fed
case *PrivacyKeyPhoneNumber: // privacyKeyPhoneNumber#d19ae46d
case *PrivacyKeyAddedByPhone: // privacyKeyAddedByPhone#42ffd42b
default: panic(v)
}
func DecodePrivacyKey ¶
func DecodePrivacyKey(buf *bin.Buffer) (PrivacyKeyClass, error)
DecodePrivacyKey implements binary de-serialization for PrivacyKeyClass.
type PrivacyKeyForwards ¶
type PrivacyKeyForwards struct {
}
PrivacyKeyForwards represents TL type `privacyKeyForwards#69ec56a3`. Whether messages forwarded from the user will be anonymously forwarded¹
Links:
See https://core.telegram.org/constructor/privacyKeyForwards for reference.
func (*PrivacyKeyForwards) Decode ¶
func (p *PrivacyKeyForwards) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyForwards) Encode ¶
func (p *PrivacyKeyForwards) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyForwards) String ¶ added in v0.12.0
func (p *PrivacyKeyForwards) String() string
String implements fmt.Stringer.
type PrivacyKeyPhoneCall ¶
type PrivacyKeyPhoneCall struct {
}
PrivacyKeyPhoneCall represents TL type `privacyKeyPhoneCall#3d662b7b`. Whether the user accepts phone calls
See https://core.telegram.org/constructor/privacyKeyPhoneCall for reference.
func (*PrivacyKeyPhoneCall) Decode ¶
func (p *PrivacyKeyPhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyPhoneCall) Encode ¶
func (p *PrivacyKeyPhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyPhoneCall) String ¶ added in v0.12.0
func (p *PrivacyKeyPhoneCall) String() string
String implements fmt.Stringer.
type PrivacyKeyPhoneNumber ¶
type PrivacyKeyPhoneNumber struct {
}
PrivacyKeyPhoneNumber represents TL type `privacyKeyPhoneNumber#d19ae46d`. Whether the user allows us to see his phone number
See https://core.telegram.org/constructor/privacyKeyPhoneNumber for reference.
func (*PrivacyKeyPhoneNumber) Decode ¶
func (p *PrivacyKeyPhoneNumber) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyPhoneNumber) Encode ¶
func (p *PrivacyKeyPhoneNumber) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyPhoneNumber) String ¶ added in v0.12.0
func (p *PrivacyKeyPhoneNumber) String() string
String implements fmt.Stringer.
type PrivacyKeyPhoneP2P ¶
type PrivacyKeyPhoneP2P struct {
}
PrivacyKeyPhoneP2P represents TL type `privacyKeyPhoneP2P#39491cc8`. Whether P2P connections in phone calls are allowed
See https://core.telegram.org/constructor/privacyKeyPhoneP2P for reference.
func (*PrivacyKeyPhoneP2P) Decode ¶
func (p *PrivacyKeyPhoneP2P) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyPhoneP2P) Encode ¶
func (p *PrivacyKeyPhoneP2P) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyPhoneP2P) String ¶ added in v0.12.0
func (p *PrivacyKeyPhoneP2P) String() string
String implements fmt.Stringer.
type PrivacyKeyProfilePhoto ¶
type PrivacyKeyProfilePhoto struct {
}
PrivacyKeyProfilePhoto represents TL type `privacyKeyProfilePhoto#96151fed`. Whether the profile picture of the user is visible
See https://core.telegram.org/constructor/privacyKeyProfilePhoto for reference.
func (*PrivacyKeyProfilePhoto) Decode ¶
func (p *PrivacyKeyProfilePhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyProfilePhoto) Encode ¶
func (p *PrivacyKeyProfilePhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyProfilePhoto) String ¶ added in v0.12.0
func (p *PrivacyKeyProfilePhoto) String() string
String implements fmt.Stringer.
type PrivacyKeyStatusTimestamp ¶
type PrivacyKeyStatusTimestamp struct {
}
PrivacyKeyStatusTimestamp represents TL type `privacyKeyStatusTimestamp#bc2eab30`. Whether we can see the last online timestamp
See https://core.telegram.org/constructor/privacyKeyStatusTimestamp for reference.
func (*PrivacyKeyStatusTimestamp) Decode ¶
func (p *PrivacyKeyStatusTimestamp) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyKeyStatusTimestamp) Encode ¶
func (p *PrivacyKeyStatusTimestamp) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyKeyStatusTimestamp) String ¶ added in v0.12.0
func (p *PrivacyKeyStatusTimestamp) String() string
String implements fmt.Stringer.
type PrivacyRuleBox ¶
type PrivacyRuleBox struct {
PrivacyRule PrivacyRuleClass
}
PrivacyRule boxes the PrivacyRuleClass providing a helper.
type PrivacyRuleClass ¶
type PrivacyRuleClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
PrivacyRuleClass represents PrivacyRule generic type.
See https://core.telegram.org/type/PrivacyRule for reference.
Example:
g, err := DecodePrivacyRule(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *PrivacyValueAllowContacts: // privacyValueAllowContacts#fffe1bac
case *PrivacyValueAllowAll: // privacyValueAllowAll#65427b82
case *PrivacyValueAllowUsers: // privacyValueAllowUsers#4d5bbe0c
case *PrivacyValueDisallowContacts: // privacyValueDisallowContacts#f888fa1a
case *PrivacyValueDisallowAll: // privacyValueDisallowAll#8b73e763
case *PrivacyValueDisallowUsers: // privacyValueDisallowUsers#c7f49b7
case *PrivacyValueAllowChatParticipants: // privacyValueAllowChatParticipants#18be796b
case *PrivacyValueDisallowChatParticipants: // privacyValueDisallowChatParticipants#acae0690
default: panic(v)
}
func DecodePrivacyRule ¶
func DecodePrivacyRule(buf *bin.Buffer) (PrivacyRuleClass, error)
DecodePrivacyRule implements binary de-serialization for PrivacyRuleClass.
type PrivacyValueAllowAll ¶
type PrivacyValueAllowAll struct {
}
PrivacyValueAllowAll represents TL type `privacyValueAllowAll#65427b82`. Allow all users
See https://core.telegram.org/constructor/privacyValueAllowAll for reference.
func (*PrivacyValueAllowAll) Decode ¶
func (p *PrivacyValueAllowAll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueAllowAll) Encode ¶
func (p *PrivacyValueAllowAll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueAllowAll) String ¶ added in v0.12.0
func (p *PrivacyValueAllowAll) String() string
String implements fmt.Stringer.
type PrivacyValueAllowChatParticipants ¶
type PrivacyValueAllowChatParticipants struct {
// Allowed chats
Chats []int
}
PrivacyValueAllowChatParticipants represents TL type `privacyValueAllowChatParticipants#18be796b`. Allow all participants of certain chats
See https://core.telegram.org/constructor/privacyValueAllowChatParticipants for reference.
func (*PrivacyValueAllowChatParticipants) Decode ¶
func (p *PrivacyValueAllowChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueAllowChatParticipants) Encode ¶
func (p *PrivacyValueAllowChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueAllowChatParticipants) String ¶ added in v0.12.0
func (p *PrivacyValueAllowChatParticipants) String() string
String implements fmt.Stringer.
type PrivacyValueAllowContacts ¶
type PrivacyValueAllowContacts struct {
}
PrivacyValueAllowContacts represents TL type `privacyValueAllowContacts#fffe1bac`. Allow all contacts
See https://core.telegram.org/constructor/privacyValueAllowContacts for reference.
func (*PrivacyValueAllowContacts) Decode ¶
func (p *PrivacyValueAllowContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueAllowContacts) Encode ¶
func (p *PrivacyValueAllowContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueAllowContacts) String ¶ added in v0.12.0
func (p *PrivacyValueAllowContacts) String() string
String implements fmt.Stringer.
type PrivacyValueAllowUsers ¶
type PrivacyValueAllowUsers struct {
// Allowed users
Users []int
}
PrivacyValueAllowUsers represents TL type `privacyValueAllowUsers#4d5bbe0c`. Allow only certain users
See https://core.telegram.org/constructor/privacyValueAllowUsers for reference.
func (*PrivacyValueAllowUsers) Decode ¶
func (p *PrivacyValueAllowUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueAllowUsers) Encode ¶
func (p *PrivacyValueAllowUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueAllowUsers) String ¶ added in v0.12.0
func (p *PrivacyValueAllowUsers) String() string
String implements fmt.Stringer.
type PrivacyValueDisallowAll ¶
type PrivacyValueDisallowAll struct {
}
PrivacyValueDisallowAll represents TL type `privacyValueDisallowAll#8b73e763`. Disallow all users
See https://core.telegram.org/constructor/privacyValueDisallowAll for reference.
func (*PrivacyValueDisallowAll) Decode ¶
func (p *PrivacyValueDisallowAll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueDisallowAll) Encode ¶
func (p *PrivacyValueDisallowAll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueDisallowAll) String ¶ added in v0.12.0
func (p *PrivacyValueDisallowAll) String() string
String implements fmt.Stringer.
type PrivacyValueDisallowChatParticipants ¶
type PrivacyValueDisallowChatParticipants struct {
// Disallowed chats
Chats []int
}
PrivacyValueDisallowChatParticipants represents TL type `privacyValueDisallowChatParticipants#acae0690`. Disallow only participants of certain chats
See https://core.telegram.org/constructor/privacyValueDisallowChatParticipants for reference.
func (*PrivacyValueDisallowChatParticipants) Decode ¶
func (p *PrivacyValueDisallowChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueDisallowChatParticipants) Encode ¶
func (p *PrivacyValueDisallowChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueDisallowChatParticipants) String ¶ added in v0.12.0
func (p *PrivacyValueDisallowChatParticipants) String() string
String implements fmt.Stringer.
type PrivacyValueDisallowContacts ¶
type PrivacyValueDisallowContacts struct {
}
PrivacyValueDisallowContacts represents TL type `privacyValueDisallowContacts#f888fa1a`. Disallow only contacts
See https://core.telegram.org/constructor/privacyValueDisallowContacts for reference.
func (*PrivacyValueDisallowContacts) Decode ¶
func (p *PrivacyValueDisallowContacts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueDisallowContacts) Encode ¶
func (p *PrivacyValueDisallowContacts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueDisallowContacts) String ¶ added in v0.12.0
func (p *PrivacyValueDisallowContacts) String() string
String implements fmt.Stringer.
type PrivacyValueDisallowUsers ¶
type PrivacyValueDisallowUsers struct {
// Disallowed users
Users []int
}
PrivacyValueDisallowUsers represents TL type `privacyValueDisallowUsers#c7f49b7`. Disallow only certain users
See https://core.telegram.org/constructor/privacyValueDisallowUsers for reference.
func (*PrivacyValueDisallowUsers) Decode ¶
func (p *PrivacyValueDisallowUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PrivacyValueDisallowUsers) Encode ¶
func (p *PrivacyValueDisallowUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PrivacyValueDisallowUsers) String ¶ added in v0.12.0
func (p *PrivacyValueDisallowUsers) String() string
String implements fmt.Stringer.
type PtsChangedHandler ¶ added in v0.9.0
type PtsChangedHandler func(ctx UpdateContext, update *UpdatePtsChanged) error
PtsChangedHandler is a PtsChanged event handler.
type ReadChannelDiscussionInboxHandler ¶ added in v0.9.0
type ReadChannelDiscussionInboxHandler func(ctx UpdateContext, update *UpdateReadChannelDiscussionInbox) error
ReadChannelDiscussionInboxHandler is a ReadChannelDiscussionInbox event handler.
type ReadChannelDiscussionOutboxHandler ¶ added in v0.9.0
type ReadChannelDiscussionOutboxHandler func(ctx UpdateContext, update *UpdateReadChannelDiscussionOutbox) error
ReadChannelDiscussionOutboxHandler is a ReadChannelDiscussionOutbox event handler.
type ReadChannelInboxHandler ¶ added in v0.9.0
type ReadChannelInboxHandler func(ctx UpdateContext, update *UpdateReadChannelInbox) error
ReadChannelInboxHandler is a ReadChannelInbox event handler.
type ReadChannelOutboxHandler ¶ added in v0.9.0
type ReadChannelOutboxHandler func(ctx UpdateContext, update *UpdateReadChannelOutbox) error
ReadChannelOutboxHandler is a ReadChannelOutbox event handler.
type ReadFeaturedStickersHandler ¶ added in v0.9.0
type ReadFeaturedStickersHandler func(ctx UpdateContext, update *UpdateReadFeaturedStickers) error
ReadFeaturedStickersHandler is a ReadFeaturedStickers event handler.
type ReadHistoryInboxHandler ¶ added in v0.9.0
type ReadHistoryInboxHandler func(ctx UpdateContext, update *UpdateReadHistoryInbox) error
ReadHistoryInboxHandler is a ReadHistoryInbox event handler.
type ReadHistoryOutboxHandler ¶ added in v0.9.0
type ReadHistoryOutboxHandler func(ctx UpdateContext, update *UpdateReadHistoryOutbox) error
ReadHistoryOutboxHandler is a ReadHistoryOutbox event handler.
type ReadMessagesContentsHandler ¶ added in v0.9.0
type ReadMessagesContentsHandler func(ctx UpdateContext, update *UpdateReadMessagesContents) error
ReadMessagesContentsHandler is a ReadMessagesContents event handler.
type ReceivedNotifyMessage ¶
type ReceivedNotifyMessage struct {
// Message ID, for which PUSH-notifications were canceled
ID int
// Reserved for future use
Flags int
}
ReceivedNotifyMessage represents TL type `receivedNotifyMessage#a384b779`. Message ID, for which PUSH-notifications were cancelled.
See https://core.telegram.org/constructor/receivedNotifyMessage for reference.
func (*ReceivedNotifyMessage) Decode ¶
func (r *ReceivedNotifyMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReceivedNotifyMessage) Encode ¶
func (r *ReceivedNotifyMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReceivedNotifyMessage) String ¶ added in v0.12.0
func (r *ReceivedNotifyMessage) String() string
String implements fmt.Stringer.
type ReceivedNotifyMessageVector ¶ added in v0.8.0
type ReceivedNotifyMessageVector struct {
// Elements of Vector<ReceivedNotifyMessage>
Elems []ReceivedNotifyMessage
}
ReceivedNotifyMessageVector is a box for Vector<ReceivedNotifyMessage>
func (*ReceivedNotifyMessageVector) Decode ¶ added in v0.8.0
func (vec *ReceivedNotifyMessageVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReceivedNotifyMessageVector) Encode ¶ added in v0.8.0
func (vec *ReceivedNotifyMessageVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReceivedNotifyMessageVector) String ¶ added in v0.12.0
func (vec *ReceivedNotifyMessageVector) String() string
String implements fmt.Stringer.
type RecentMeUrlBox ¶
type RecentMeUrlBox struct {
RecentMeUrl RecentMeUrlClass
}
RecentMeUrl boxes the RecentMeUrlClass providing a helper.
type RecentMeUrlChat ¶
RecentMeUrlChat represents TL type `recentMeUrlChat#a01b22f9`. Recent t.me link to a chat
See https://core.telegram.org/constructor/recentMeUrlChat for reference.
func (*RecentMeUrlChat) Decode ¶
func (r *RecentMeUrlChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RecentMeUrlChat) Encode ¶
func (r *RecentMeUrlChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RecentMeUrlChat) String ¶ added in v0.12.0
func (r *RecentMeUrlChat) String() string
String implements fmt.Stringer.
type RecentMeUrlChatInvite ¶
type RecentMeUrlChatInvite struct {
// t.me URL
URL string
// Chat invitation
ChatInvite ChatInviteClass
}
RecentMeUrlChatInvite represents TL type `recentMeUrlChatInvite#eb49081d`. Recent t.me invite link to a chat
See https://core.telegram.org/constructor/recentMeUrlChatInvite for reference.
func (*RecentMeUrlChatInvite) Decode ¶
func (r *RecentMeUrlChatInvite) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RecentMeUrlChatInvite) Encode ¶
func (r *RecentMeUrlChatInvite) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RecentMeUrlChatInvite) String ¶ added in v0.12.0
func (r *RecentMeUrlChatInvite) String() string
String implements fmt.Stringer.
type RecentMeUrlClass ¶
type RecentMeUrlClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
RecentMeUrlClass represents RecentMeUrl generic type.
See https://core.telegram.org/type/RecentMeUrl for reference.
Example:
g, err := DecodeRecentMeUrl(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *RecentMeUrlUnknown: // recentMeUrlUnknown#46e1d13d
case *RecentMeUrlUser: // recentMeUrlUser#8dbc3336
case *RecentMeUrlChat: // recentMeUrlChat#a01b22f9
case *RecentMeUrlChatInvite: // recentMeUrlChatInvite#eb49081d
case *RecentMeUrlStickerSet: // recentMeUrlStickerSet#bc0a57dc
default: panic(v)
}
func DecodeRecentMeUrl ¶
func DecodeRecentMeUrl(buf *bin.Buffer) (RecentMeUrlClass, error)
DecodeRecentMeUrl implements binary de-serialization for RecentMeUrlClass.
type RecentMeUrlStickerSet ¶
type RecentMeUrlStickerSet struct {
// t.me URL
URL string
// Stickerset
Set StickerSetCoveredClass
}
RecentMeUrlStickerSet represents TL type `recentMeUrlStickerSet#bc0a57dc`. Recent t.me stickerset installation URL
See https://core.telegram.org/constructor/recentMeUrlStickerSet for reference.
func (*RecentMeUrlStickerSet) Decode ¶
func (r *RecentMeUrlStickerSet) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RecentMeUrlStickerSet) Encode ¶
func (r *RecentMeUrlStickerSet) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RecentMeUrlStickerSet) String ¶ added in v0.12.0
func (r *RecentMeUrlStickerSet) String() string
String implements fmt.Stringer.
type RecentMeUrlUnknown ¶
type RecentMeUrlUnknown struct {
// URL
URL string
}
RecentMeUrlUnknown represents TL type `recentMeUrlUnknown#46e1d13d`. Unknown t.me url
See https://core.telegram.org/constructor/recentMeUrlUnknown for reference.
func (*RecentMeUrlUnknown) Decode ¶
func (r *RecentMeUrlUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RecentMeUrlUnknown) Encode ¶
func (r *RecentMeUrlUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RecentMeUrlUnknown) String ¶ added in v0.12.0
func (r *RecentMeUrlUnknown) String() string
String implements fmt.Stringer.
type RecentMeUrlUser ¶
RecentMeUrlUser represents TL type `recentMeUrlUser#8dbc3336`. Recent t.me link to a user
See https://core.telegram.org/constructor/recentMeUrlUser for reference.
func (*RecentMeUrlUser) Decode ¶
func (r *RecentMeUrlUser) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RecentMeUrlUser) Encode ¶
func (r *RecentMeUrlUser) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RecentMeUrlUser) String ¶ added in v0.12.0
func (r *RecentMeUrlUser) String() string
String implements fmt.Stringer.
type RecentStickersHandler ¶ added in v0.9.0
type RecentStickersHandler func(ctx UpdateContext, update *UpdateRecentStickers) error
RecentStickersHandler is a RecentStickers event handler.
type ReplyInlineMarkup ¶
type ReplyInlineMarkup struct {
// Bot or inline keyboard rows
Rows []KeyboardButtonRow
}
ReplyInlineMarkup represents TL type `replyInlineMarkup#48a30254`. Bot or inline keyboard
See https://core.telegram.org/constructor/replyInlineMarkup for reference.
func (*ReplyInlineMarkup) Decode ¶
func (r *ReplyInlineMarkup) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReplyInlineMarkup) Encode ¶
func (r *ReplyInlineMarkup) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReplyInlineMarkup) String ¶ added in v0.12.0
func (r *ReplyInlineMarkup) String() string
String implements fmt.Stringer.
type ReplyKeyboardForceReply ¶
type ReplyKeyboardForceReply struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat – the user can press a special button in the input field to see the custom keyboard again.
SingleUse bool
// Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply_to_message_id), sender of the original message. Example: A user requests to change the bot‘s language, bot replies to the request with a keyboard to select the new language. Other users in the group don’t see the keyboard.
Selective bool
}
ReplyKeyboardForceReply represents TL type `replyKeyboardForceReply#f4108aa0`. Force the user to send a reply
See https://core.telegram.org/constructor/replyKeyboardForceReply for reference.
func (*ReplyKeyboardForceReply) Decode ¶
func (r *ReplyKeyboardForceReply) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReplyKeyboardForceReply) Encode ¶
func (r *ReplyKeyboardForceReply) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReplyKeyboardForceReply) SetSelective ¶
func (r *ReplyKeyboardForceReply) SetSelective(value bool)
SetSelective sets value of Selective conditional field.
func (*ReplyKeyboardForceReply) SetSingleUse ¶
func (r *ReplyKeyboardForceReply) SetSingleUse(value bool)
SetSingleUse sets value of SingleUse conditional field.
func (*ReplyKeyboardForceReply) String ¶ added in v0.12.0
func (r *ReplyKeyboardForceReply) String() string
String implements fmt.Stringer.
type ReplyKeyboardHide ¶
type ReplyKeyboardHide struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Use this flag if you want to remove the keyboard for specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply_to_message_id), sender of the original message.Example: A user votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet
Selective bool
}
ReplyKeyboardHide represents TL type `replyKeyboardHide#a03e5b85`. Hide sent bot keyboard
See https://core.telegram.org/constructor/replyKeyboardHide for reference.
func (*ReplyKeyboardHide) Decode ¶
func (r *ReplyKeyboardHide) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReplyKeyboardHide) Encode ¶
func (r *ReplyKeyboardHide) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReplyKeyboardHide) SetSelective ¶
func (r *ReplyKeyboardHide) SetSelective(value bool)
SetSelective sets value of Selective conditional field.
func (*ReplyKeyboardHide) String ¶ added in v0.12.0
func (r *ReplyKeyboardHide) String() string
String implements fmt.Stringer.
type ReplyKeyboardMarkup ¶
type ReplyKeyboardMarkup struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Requests clients to resize the keyboard vertically for optimal fit (e.g., make the keyboard smaller if there are just two rows of buttons). If not set, the custom keyboard is always of the same height as the app's standard keyboard.
Resize bool
// Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat – the user can press a special button in the input field to see the custom keyboard again.
SingleUse bool
// Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply_to_message_id), sender of the original message.Example: A user requests to change the bot‘s language, bot replies to the request with a keyboard to select the new language. Other users in the group don’t see the keyboard.
Selective bool
// Button row
Rows []KeyboardButtonRow
}
ReplyKeyboardMarkup represents TL type `replyKeyboardMarkup#3502758c`. Bot keyboard
See https://core.telegram.org/constructor/replyKeyboardMarkup for reference.
func (*ReplyKeyboardMarkup) Decode ¶
func (r *ReplyKeyboardMarkup) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReplyKeyboardMarkup) Encode ¶
func (r *ReplyKeyboardMarkup) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReplyKeyboardMarkup) SetResize ¶
func (r *ReplyKeyboardMarkup) SetResize(value bool)
SetResize sets value of Resize conditional field.
func (*ReplyKeyboardMarkup) SetSelective ¶
func (r *ReplyKeyboardMarkup) SetSelective(value bool)
SetSelective sets value of Selective conditional field.
func (*ReplyKeyboardMarkup) SetSingleUse ¶
func (r *ReplyKeyboardMarkup) SetSingleUse(value bool)
SetSingleUse sets value of SingleUse conditional field.
func (*ReplyKeyboardMarkup) String ¶ added in v0.12.0
func (r *ReplyKeyboardMarkup) String() string
String implements fmt.Stringer.
type ReplyMarkupBox ¶
type ReplyMarkupBox struct {
ReplyMarkup ReplyMarkupClass
}
ReplyMarkup boxes the ReplyMarkupClass providing a helper.
type ReplyMarkupClass ¶
type ReplyMarkupClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ReplyMarkupClass represents ReplyMarkup generic type.
See https://core.telegram.org/type/ReplyMarkup for reference.
Example:
g, err := DecodeReplyMarkup(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *ReplyKeyboardHide: // replyKeyboardHide#a03e5b85
case *ReplyKeyboardForceReply: // replyKeyboardForceReply#f4108aa0
case *ReplyKeyboardMarkup: // replyKeyboardMarkup#3502758c
case *ReplyInlineMarkup: // replyInlineMarkup#48a30254
default: panic(v)
}
func DecodeReplyMarkup ¶
func DecodeReplyMarkup(buf *bin.Buffer) (ReplyMarkupClass, error)
DecodeReplyMarkup implements binary de-serialization for ReplyMarkupClass.
type ReportReasonBox ¶
type ReportReasonBox struct {
ReportReason ReportReasonClass
}
ReportReason boxes the ReportReasonClass providing a helper.
type ReportReasonClass ¶
type ReportReasonClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
ReportReasonClass represents ReportReason generic type.
See https://core.telegram.org/type/ReportReason for reference.
Example:
g, err := DecodeReportReason(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *InputReportReasonSpam: // inputReportReasonSpam#58dbcab8
case *InputReportReasonViolence: // inputReportReasonViolence#1e22c78d
case *InputReportReasonPornography: // inputReportReasonPornography#2e59d922
case *InputReportReasonChildAbuse: // inputReportReasonChildAbuse#adf44ee3
case *InputReportReasonOther: // inputReportReasonOther#e1746d0a
case *InputReportReasonCopyright: // inputReportReasonCopyright#9b89f93a
case *InputReportReasonGeoIrrelevant: // inputReportReasonGeoIrrelevant#dbd4feed
default: panic(v)
}
func DecodeReportReason ¶
func DecodeReportReason(buf *bin.Buffer) (ReportReasonClass, error)
DecodeReportReason implements binary de-serialization for ReportReasonClass.
type RestrictionReason ¶
type RestrictionReason struct {
// Platform identifier (ios, android, wp, all, etc.), can be concatenated with a dash as separator (android-ios, ios-wp, etc)
Platform string
// Restriction reason (porno, terms, etc.)
Reason string
// Error message to be shown to the user
Text string
}
RestrictionReason represents TL type `restrictionReason#d072acb4`. Restriction reason. Contains the reason why access to a certain object must be restricted. Clients are supposed to deny access to the channel if the platform field is equal to all or to the current platform (ios, android, wp, etc.). Platforms can be concatenated (ios-android, ios-wp), unknown platforms are to be ignored. The text is the error message that should be shown to the user.
See https://core.telegram.org/constructor/restrictionReason for reference.
func (*RestrictionReason) Decode ¶
func (r *RestrictionReason) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RestrictionReason) Encode ¶
func (r *RestrictionReason) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RestrictionReason) String ¶ added in v0.12.0
func (r *RestrictionReason) String() string
String implements fmt.Stringer.
type RichTextBox ¶
type RichTextBox struct {
RichText RichTextClass
}
RichText boxes the RichTextClass providing a helper.
type RichTextClass ¶
type RichTextClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
RichTextClass represents RichText generic type.
See https://core.telegram.org/type/RichText for reference.
Example:
g, err := DecodeRichText(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *TextEmpty: // textEmpty#dc3d824f
case *TextPlain: // textPlain#744694e0
case *TextBold: // textBold#6724abc4
case *TextItalic: // textItalic#d912a59c
case *TextUnderline: // textUnderline#c12622c4
case *TextStrike: // textStrike#9bf8bb95
case *TextFixed: // textFixed#6c3f19b9
case *TextUrl: // textUrl#3c2884c1
case *TextEmail: // textEmail#de5a0dd6
case *TextConcat: // textConcat#7e6260d7
case *TextSubscript: // textSubscript#ed6a8504
case *TextSuperscript: // textSuperscript#c7fb5e01
case *TextMarked: // textMarked#34b8621
case *TextPhone: // textPhone#1ccb966a
case *TextImage: // textImage#81ccf4f
case *TextAnchor: // textAnchor#35553762
default: panic(v)
}
func DecodeRichText ¶
func DecodeRichText(buf *bin.Buffer) (RichTextClass, error)
DecodeRichText implements binary de-serialization for RichTextClass.
type SavedGifsHandler ¶ added in v0.9.0
type SavedGifsHandler func(ctx UpdateContext, update *UpdateSavedGifs) error
SavedGifsHandler is a SavedGifs event handler.
type SavedPhoneContact ¶
type SavedPhoneContact struct {
// Phone number
Phone string
// First name
FirstName string
// Last name
LastName string
// Date added
Date int
}
SavedPhoneContact represents TL type `savedPhoneContact#1142bd56`. Saved contact
See https://core.telegram.org/constructor/savedPhoneContact for reference.
func (*SavedPhoneContact) Decode ¶
func (s *SavedPhoneContact) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SavedPhoneContact) Encode ¶
func (s *SavedPhoneContact) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SavedPhoneContact) String ¶ added in v0.12.0
func (s *SavedPhoneContact) String() string
String implements fmt.Stringer.
type SavedPhoneContactVector ¶ added in v0.8.0
type SavedPhoneContactVector struct {
// Elements of Vector<SavedContact>
Elems []SavedPhoneContact
}
SavedPhoneContactVector is a box for Vector<SavedContact>
func (*SavedPhoneContactVector) Decode ¶ added in v0.8.0
func (vec *SavedPhoneContactVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SavedPhoneContactVector) Encode ¶ added in v0.8.0
func (vec *SavedPhoneContactVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SavedPhoneContactVector) String ¶ added in v0.12.0
func (vec *SavedPhoneContactVector) String() string
String implements fmt.Stringer.
type SecureCredentialsEncrypted ¶
type SecureCredentialsEncrypted struct {
// Encrypted JSON-serialized data with unique user's payload, data hashes and secrets required for EncryptedPassportElement decryption and authentication, as described in decrypting data »¹
//
// Links:
// 1) https://core.telegram.org/passport#decrypting-data
Data []byte
// Data hash for data authentication as described in decrypting data »¹
//
// Links:
// 1) https://core.telegram.org/passport#decrypting-data
Hash []byte
// Secret, encrypted with the bot's public RSA key, required for data decryption as described in decrypting data »¹
//
// Links:
// 1) https://core.telegram.org/passport#decrypting-data
Secret []byte
}
SecureCredentialsEncrypted represents TL type `secureCredentialsEncrypted#33f0ea47`. Encrypted credentials required to decrypt telegram passport¹ data.
Links:
See https://core.telegram.org/constructor/secureCredentialsEncrypted for reference.
func (*SecureCredentialsEncrypted) Decode ¶
func (s *SecureCredentialsEncrypted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureCredentialsEncrypted) Encode ¶
func (s *SecureCredentialsEncrypted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureCredentialsEncrypted) String ¶ added in v0.12.0
func (s *SecureCredentialsEncrypted) String() string
String implements fmt.Stringer.
type SecureData ¶
SecureData represents TL type `secureData#8aeabec3`. Secure passport¹ data, for more info see the passport docs »²
Links:
See https://core.telegram.org/constructor/secureData for reference.
func (*SecureData) Decode ¶
func (s *SecureData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureData) Encode ¶
func (s *SecureData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureData) String ¶ added in v0.12.0
func (s *SecureData) String() string
String implements fmt.Stringer.
type SecureFile ¶
type SecureFile struct {
// ID
ID int64
// Access hash
AccessHash int64
// File size
Size int
// DC ID
DCID int
// Date of upload
Date int
// File hash
FileHash []byte
// Secret
Secret []byte
}
SecureFile represents TL type `secureFile#e0277a62`. Secure passport¹ file, for more info see the passport docs »²
Links:
See https://core.telegram.org/constructor/secureFile for reference.
func (*SecureFile) Decode ¶
func (s *SecureFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureFile) Encode ¶
func (s *SecureFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureFile) String ¶ added in v0.12.0
func (s *SecureFile) String() string
String implements fmt.Stringer.
type SecureFileBox ¶
type SecureFileBox struct {
SecureFile SecureFileClass
}
SecureFile boxes the SecureFileClass providing a helper.
type SecureFileClass ¶
type SecureFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecureFileClass represents SecureFile generic type.
See https://core.telegram.org/type/SecureFile for reference.
Example:
g, err := DecodeSecureFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecureFileEmpty: // secureFileEmpty#64199744
case *SecureFile: // secureFile#e0277a62
default: panic(v)
}
func DecodeSecureFile ¶
func DecodeSecureFile(buf *bin.Buffer) (SecureFileClass, error)
DecodeSecureFile implements binary de-serialization for SecureFileClass.
type SecureFileEmpty ¶
type SecureFileEmpty struct {
}
SecureFileEmpty represents TL type `secureFileEmpty#64199744`. Empty constructor
See https://core.telegram.org/constructor/secureFileEmpty for reference.
func (*SecureFileEmpty) Decode ¶
func (s *SecureFileEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureFileEmpty) Encode ¶
func (s *SecureFileEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureFileEmpty) String ¶ added in v0.12.0
func (s *SecureFileEmpty) String() string
String implements fmt.Stringer.
type SecurePasswordKdfAlgoBox ¶
type SecurePasswordKdfAlgoBox struct {
SecurePasswordKdfAlgo SecurePasswordKdfAlgoClass
}
SecurePasswordKdfAlgo boxes the SecurePasswordKdfAlgoClass providing a helper.
type SecurePasswordKdfAlgoClass ¶
type SecurePasswordKdfAlgoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecurePasswordKdfAlgoClass represents SecurePasswordKdfAlgo generic type.
See https://core.telegram.org/type/SecurePasswordKdfAlgo for reference.
Example:
g, err := DecodeSecurePasswordKdfAlgo(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecurePasswordKdfAlgoUnknown: // securePasswordKdfAlgoUnknown#4a8537
case *SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000: // securePasswordKdfAlgoPBKDF2HMACSHA512iter100000#bbf2dda0
case *SecurePasswordKdfAlgoSHA512: // securePasswordKdfAlgoSHA512#86471d92
default: panic(v)
}
func DecodeSecurePasswordKdfAlgo ¶
func DecodeSecurePasswordKdfAlgo(buf *bin.Buffer) (SecurePasswordKdfAlgoClass, error)
DecodeSecurePasswordKdfAlgo implements binary de-serialization for SecurePasswordKdfAlgoClass.
type SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000 ¶
type SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000 struct {
// Salt
Salt []byte
}
SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000 represents TL type `securePasswordKdfAlgoPBKDF2HMACSHA512iter100000#bbf2dda0`. PBKDF2 with SHA512 and 100000 iterations KDF algo
See https://core.telegram.org/constructor/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000 for reference.
func (*SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) Decode ¶
func (s *SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) Encode ¶
func (s *SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) String ¶ added in v0.12.0
func (s *SecurePasswordKdfAlgoPBKDF2HMACSHA512iter100000) String() string
String implements fmt.Stringer.
type SecurePasswordKdfAlgoSHA512 ¶
type SecurePasswordKdfAlgoSHA512 struct {
// Salt
Salt []byte
}
SecurePasswordKdfAlgoSHA512 represents TL type `securePasswordKdfAlgoSHA512#86471d92`. SHA512 KDF algo
See https://core.telegram.org/constructor/securePasswordKdfAlgoSHA512 for reference.
func (*SecurePasswordKdfAlgoSHA512) Decode ¶
func (s *SecurePasswordKdfAlgoSHA512) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecurePasswordKdfAlgoSHA512) Encode ¶
func (s *SecurePasswordKdfAlgoSHA512) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecurePasswordKdfAlgoSHA512) String ¶ added in v0.12.0
func (s *SecurePasswordKdfAlgoSHA512) String() string
String implements fmt.Stringer.
type SecurePasswordKdfAlgoUnknown ¶
type SecurePasswordKdfAlgoUnknown struct {
}
SecurePasswordKdfAlgoUnknown represents TL type `securePasswordKdfAlgoUnknown#4a8537`. Unknown KDF algo (most likely the client has to be updated)
See https://core.telegram.org/constructor/securePasswordKdfAlgoUnknown for reference.
func (*SecurePasswordKdfAlgoUnknown) Decode ¶
func (s *SecurePasswordKdfAlgoUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecurePasswordKdfAlgoUnknown) Encode ¶
func (s *SecurePasswordKdfAlgoUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecurePasswordKdfAlgoUnknown) String ¶ added in v0.12.0
func (s *SecurePasswordKdfAlgoUnknown) String() string
String implements fmt.Stringer.
type SecurePlainDataBox ¶
type SecurePlainDataBox struct {
SecurePlainData SecurePlainDataClass
}
SecurePlainData boxes the SecurePlainDataClass providing a helper.
type SecurePlainDataClass ¶
type SecurePlainDataClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecurePlainDataClass represents SecurePlainData generic type.
See https://core.telegram.org/type/SecurePlainData for reference.
Example:
g, err := DecodeSecurePlainData(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecurePlainPhone: // securePlainPhone#7d6099dd
case *SecurePlainEmail: // securePlainEmail#21ec5a5f
default: panic(v)
}
func DecodeSecurePlainData ¶
func DecodeSecurePlainData(buf *bin.Buffer) (SecurePlainDataClass, error)
DecodeSecurePlainData implements binary de-serialization for SecurePlainDataClass.
type SecurePlainEmail ¶
type SecurePlainEmail struct {
// Email address
Email string
}
SecurePlainEmail represents TL type `securePlainEmail#21ec5a5f`. Email address to use in telegram passport¹: it must be verified, first »².
Links:
See https://core.telegram.org/constructor/securePlainEmail for reference.
func (*SecurePlainEmail) Decode ¶
func (s *SecurePlainEmail) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecurePlainEmail) Encode ¶
func (s *SecurePlainEmail) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecurePlainEmail) String ¶ added in v0.12.0
func (s *SecurePlainEmail) String() string
String implements fmt.Stringer.
type SecurePlainPhone ¶
type SecurePlainPhone struct {
// Phone number
Phone string
}
SecurePlainPhone represents TL type `securePlainPhone#7d6099dd`. Phone number to use in telegram passport¹: it must be verified, first »².
Links:
See https://core.telegram.org/constructor/securePlainPhone for reference.
func (*SecurePlainPhone) Decode ¶
func (s *SecurePlainPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecurePlainPhone) Encode ¶
func (s *SecurePlainPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecurePlainPhone) String ¶ added in v0.12.0
func (s *SecurePlainPhone) String() string
String implements fmt.Stringer.
type SecureRequiredType ¶
type SecureRequiredType struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Native names
NativeNames bool
// Is a selfie required
SelfieRequired bool
// Is a translation required
TranslationRequired bool
// Secure value type
Type SecureValueTypeClass
}
SecureRequiredType represents TL type `secureRequiredType#829d99da`. Required type
See https://core.telegram.org/constructor/secureRequiredType for reference.
func (*SecureRequiredType) Decode ¶
func (s *SecureRequiredType) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureRequiredType) Encode ¶
func (s *SecureRequiredType) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureRequiredType) SetNativeNames ¶
func (s *SecureRequiredType) SetNativeNames(value bool)
SetNativeNames sets value of NativeNames conditional field.
func (*SecureRequiredType) SetSelfieRequired ¶
func (s *SecureRequiredType) SetSelfieRequired(value bool)
SetSelfieRequired sets value of SelfieRequired conditional field.
func (*SecureRequiredType) SetTranslationRequired ¶
func (s *SecureRequiredType) SetTranslationRequired(value bool)
SetTranslationRequired sets value of TranslationRequired conditional field.
func (*SecureRequiredType) String ¶ added in v0.12.0
func (s *SecureRequiredType) String() string
String implements fmt.Stringer.
type SecureRequiredTypeBox ¶
type SecureRequiredTypeBox struct {
SecureRequiredType SecureRequiredTypeClass
}
SecureRequiredType boxes the SecureRequiredTypeClass providing a helper.
type SecureRequiredTypeClass ¶
type SecureRequiredTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecureRequiredTypeClass represents SecureRequiredType generic type.
See https://core.telegram.org/type/SecureRequiredType for reference.
Example:
g, err := DecodeSecureRequiredType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecureRequiredType: // secureRequiredType#829d99da
case *SecureRequiredTypeOneOf: // secureRequiredTypeOneOf#27477b4
default: panic(v)
}
func DecodeSecureRequiredType ¶
func DecodeSecureRequiredType(buf *bin.Buffer) (SecureRequiredTypeClass, error)
DecodeSecureRequiredType implements binary de-serialization for SecureRequiredTypeClass.
type SecureRequiredTypeOneOf ¶
type SecureRequiredTypeOneOf struct {
// Secure required value types
Types []SecureRequiredTypeClass
}
SecureRequiredTypeOneOf represents TL type `secureRequiredTypeOneOf#27477b4`. One of
See https://core.telegram.org/constructor/secureRequiredTypeOneOf for reference.
func (*SecureRequiredTypeOneOf) Decode ¶
func (s *SecureRequiredTypeOneOf) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureRequiredTypeOneOf) Encode ¶
func (s *SecureRequiredTypeOneOf) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureRequiredTypeOneOf) String ¶ added in v0.12.0
func (s *SecureRequiredTypeOneOf) String() string
String implements fmt.Stringer.
type SecureSecretSettings ¶
type SecureSecretSettings struct {
// Secure KDF algo
SecureAlgo SecurePasswordKdfAlgoClass
// Secure secret
SecureSecret []byte
// Secret ID
SecureSecretID int64
}
SecureSecretSettings represents TL type `secureSecretSettings#1527bcac`. Secure settings
See https://core.telegram.org/constructor/secureSecretSettings for reference.
func (*SecureSecretSettings) Decode ¶
func (s *SecureSecretSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureSecretSettings) Encode ¶
func (s *SecureSecretSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureSecretSettings) String ¶ added in v0.12.0
func (s *SecureSecretSettings) String() string
String implements fmt.Stringer.
type SecureValue ¶
type SecureValue struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Secure passport¹ value type
//
// Links:
// 1) https://core.telegram.org/passport
Type SecureValueTypeClass
// Encrypted Telegram Passport¹ element data
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetData and GetData helpers.
Data SecureData
// Encrypted passport¹ file with the front side of the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetFrontSide and GetFrontSide helpers.
FrontSide SecureFileClass
// Encrypted passport¹ file with the reverse side of the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetReverseSide and GetReverseSide helpers.
ReverseSide SecureFileClass
// Encrypted passport¹ file with a selfie of the user holding the document
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetSelfie and GetSelfie helpers.
Selfie SecureFileClass
// Array of encrypted passport¹ files with translated versions of the provided documents
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetTranslation and GetTranslation helpers.
Translation []SecureFileClass
// Array of encrypted passport¹ files with photos the of the documents
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetFiles and GetFiles helpers.
Files []SecureFileClass
// Plaintext verified passport¹ data
//
// Links:
// 1) https://core.telegram.org/passport
//
// Use SetPlainData and GetPlainData helpers.
PlainData SecurePlainDataClass
// Data hash
Hash []byte
}
SecureValue represents TL type `secureValue#187fa0ca`. Secure value
See https://core.telegram.org/constructor/secureValue for reference.
func (*SecureValue) Decode ¶
func (s *SecureValue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValue) Encode ¶
func (s *SecureValue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValue) GetData ¶
func (s *SecureValue) GetData() (value SecureData, ok bool)
GetData returns value of Data conditional field and boolean which is true if field was set.
func (*SecureValue) GetFiles ¶
func (s *SecureValue) GetFiles() (value []SecureFileClass, ok bool)
GetFiles returns value of Files conditional field and boolean which is true if field was set.
func (*SecureValue) GetFrontSide ¶
func (s *SecureValue) GetFrontSide() (value SecureFileClass, ok bool)
GetFrontSide returns value of FrontSide conditional field and boolean which is true if field was set.
func (*SecureValue) GetPlainData ¶
func (s *SecureValue) GetPlainData() (value SecurePlainDataClass, ok bool)
GetPlainData returns value of PlainData conditional field and boolean which is true if field was set.
func (*SecureValue) GetReverseSide ¶
func (s *SecureValue) GetReverseSide() (value SecureFileClass, ok bool)
GetReverseSide returns value of ReverseSide conditional field and boolean which is true if field was set.
func (*SecureValue) GetSelfie ¶
func (s *SecureValue) GetSelfie() (value SecureFileClass, ok bool)
GetSelfie returns value of Selfie conditional field and boolean which is true if field was set.
func (*SecureValue) GetTranslation ¶
func (s *SecureValue) GetTranslation() (value []SecureFileClass, ok bool)
GetTranslation returns value of Translation conditional field and boolean which is true if field was set.
func (*SecureValue) SetData ¶
func (s *SecureValue) SetData(value SecureData)
SetData sets value of Data conditional field.
func (*SecureValue) SetFiles ¶
func (s *SecureValue) SetFiles(value []SecureFileClass)
SetFiles sets value of Files conditional field.
func (*SecureValue) SetFrontSide ¶
func (s *SecureValue) SetFrontSide(value SecureFileClass)
SetFrontSide sets value of FrontSide conditional field.
func (*SecureValue) SetPlainData ¶
func (s *SecureValue) SetPlainData(value SecurePlainDataClass)
SetPlainData sets value of PlainData conditional field.
func (*SecureValue) SetReverseSide ¶
func (s *SecureValue) SetReverseSide(value SecureFileClass)
SetReverseSide sets value of ReverseSide conditional field.
func (*SecureValue) SetSelfie ¶
func (s *SecureValue) SetSelfie(value SecureFileClass)
SetSelfie sets value of Selfie conditional field.
func (*SecureValue) SetTranslation ¶
func (s *SecureValue) SetTranslation(value []SecureFileClass)
SetTranslation sets value of Translation conditional field.
func (*SecureValue) String ¶ added in v0.12.0
func (s *SecureValue) String() string
String implements fmt.Stringer.
type SecureValueError ¶
type SecureValueError struct {
// Type of element which has the issue
Type SecureValueTypeClass
// Hash
Hash []byte
// Error message
Text string
}
SecureValueError represents TL type `secureValueError#869d758f`. Secure value error
See https://core.telegram.org/constructor/secureValueError for reference.
func (*SecureValueError) Decode ¶
func (s *SecureValueError) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueError) Encode ¶
func (s *SecureValueError) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueError) String ¶ added in v0.12.0
func (s *SecureValueError) String() string
String implements fmt.Stringer.
type SecureValueErrorBox ¶
type SecureValueErrorBox struct {
SecureValueError SecureValueErrorClass
}
SecureValueError boxes the SecureValueErrorClass providing a helper.
type SecureValueErrorClass ¶
type SecureValueErrorClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecureValueErrorClass represents SecureValueError generic type.
See https://core.telegram.org/type/SecureValueError for reference.
Example:
g, err := DecodeSecureValueError(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecureValueErrorData: // secureValueErrorData#e8a40bd9
case *SecureValueErrorFrontSide: // secureValueErrorFrontSide#be3dfa
case *SecureValueErrorReverseSide: // secureValueErrorReverseSide#868a2aa5
case *SecureValueErrorSelfie: // secureValueErrorSelfie#e537ced6
case *SecureValueErrorFile: // secureValueErrorFile#7a700873
case *SecureValueErrorFiles: // secureValueErrorFiles#666220e9
case *SecureValueError: // secureValueError#869d758f
case *SecureValueErrorTranslationFile: // secureValueErrorTranslationFile#a1144770
case *SecureValueErrorTranslationFiles: // secureValueErrorTranslationFiles#34636dd8
default: panic(v)
}
func DecodeSecureValueError ¶
func DecodeSecureValueError(buf *bin.Buffer) (SecureValueErrorClass, error)
DecodeSecureValueError implements binary de-serialization for SecureValueErrorClass.
type SecureValueErrorData ¶
type SecureValueErrorData struct {
// The section of the user's Telegram Passport which has the error, one of secureValueTypePersonalDetails¹, secureValueTypePassport², secureValueTypeDriverLicense³, secureValueTypeIdentityCard⁴, secureValueTypeInternalPassport⁵, secureValueTypeAddress⁶
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypePersonalDetails
// 2) https://core.telegram.org/constructor/secureValueTypePassport
// 3) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 4) https://core.telegram.org/constructor/secureValueTypeIdentityCard
// 5) https://core.telegram.org/constructor/secureValueTypeInternalPassport
// 6) https://core.telegram.org/constructor/secureValueTypeAddress
Type SecureValueTypeClass
// Data hash
DataHash []byte
// Name of the data field which has the error
Field string
// Error message
Text string
}
SecureValueErrorData represents TL type `secureValueErrorData#e8a40bd9`. Represents an issue in one of the data fields that was provided by the user. The error is considered resolved when the field's value changes.
See https://core.telegram.org/constructor/secureValueErrorData for reference.
func (*SecureValueErrorData) Decode ¶
func (s *SecureValueErrorData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorData) Encode ¶
func (s *SecureValueErrorData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorData) String ¶ added in v0.12.0
func (s *SecureValueErrorData) String() string
String implements fmt.Stringer.
type SecureValueErrorFile ¶
type SecureValueErrorFile struct {
// One of secureValueTypeUtilityBill¹, secureValueTypeBankStatement², secureValueTypeRentalAgreement³, secureValueTypePassportRegistration⁴, secureValueTypeTemporaryRegistration⁵
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypeUtilityBill
// 2) https://core.telegram.org/constructor/secureValueTypeBankStatement
// 3) https://core.telegram.org/constructor/secureValueTypeRentalAgreement
// 4) https://core.telegram.org/constructor/secureValueTypePassportRegistration
// 5) https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration
Type SecureValueTypeClass
// File hash
FileHash []byte
// Error message
Text string
}
SecureValueErrorFile represents TL type `secureValueErrorFile#7a700873`. Represents an issue with a document scan. The error is considered resolved when the file with the document scan changes.
See https://core.telegram.org/constructor/secureValueErrorFile for reference.
func (*SecureValueErrorFile) Decode ¶
func (s *SecureValueErrorFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorFile) Encode ¶
func (s *SecureValueErrorFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorFile) String ¶ added in v0.12.0
func (s *SecureValueErrorFile) String() string
String implements fmt.Stringer.
type SecureValueErrorFiles ¶
type SecureValueErrorFiles struct {
// One of secureValueTypeUtilityBill¹, secureValueTypeBankStatement², secureValueTypeRentalAgreement³, secureValueTypePassportRegistration⁴, secureValueTypeTemporaryRegistration⁵
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypeUtilityBill
// 2) https://core.telegram.org/constructor/secureValueTypeBankStatement
// 3) https://core.telegram.org/constructor/secureValueTypeRentalAgreement
// 4) https://core.telegram.org/constructor/secureValueTypePassportRegistration
// 5) https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration
Type SecureValueTypeClass
// File hash
FileHash [][]byte
// Error message
Text string
}
SecureValueErrorFiles represents TL type `secureValueErrorFiles#666220e9`. Represents an issue with a list of scans. The error is considered resolved when the list of files containing the scans changes.
See https://core.telegram.org/constructor/secureValueErrorFiles for reference.
func (*SecureValueErrorFiles) Decode ¶
func (s *SecureValueErrorFiles) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorFiles) Encode ¶
func (s *SecureValueErrorFiles) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorFiles) String ¶ added in v0.12.0
func (s *SecureValueErrorFiles) String() string
String implements fmt.Stringer.
type SecureValueErrorFrontSide ¶
type SecureValueErrorFrontSide struct {
// One of secureValueTypePassport¹, secureValueTypeDriverLicense², secureValueTypeIdentityCard³, secureValueTypeInternalPassport⁴
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypePassport
// 2) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 3) https://core.telegram.org/constructor/secureValueTypeIdentityCard
// 4) https://core.telegram.org/constructor/secureValueTypeInternalPassport
Type SecureValueTypeClass
// File hash
FileHash []byte
// Error message
Text string
}
SecureValueErrorFrontSide represents TL type `secureValueErrorFrontSide#be3dfa`. Represents an issue with the front side of a document. The error is considered resolved when the file with the front side of the document changes.
See https://core.telegram.org/constructor/secureValueErrorFrontSide for reference.
func (*SecureValueErrorFrontSide) Decode ¶
func (s *SecureValueErrorFrontSide) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorFrontSide) Encode ¶
func (s *SecureValueErrorFrontSide) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorFrontSide) String ¶ added in v0.12.0
func (s *SecureValueErrorFrontSide) String() string
String implements fmt.Stringer.
type SecureValueErrorReverseSide ¶
type SecureValueErrorReverseSide struct {
// One of secureValueTypeDriverLicense¹, secureValueTypeIdentityCard²
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 2) https://core.telegram.org/constructor/secureValueTypeIdentityCard
Type SecureValueTypeClass
// File hash
FileHash []byte
// Error message
Text string
}
SecureValueErrorReverseSide represents TL type `secureValueErrorReverseSide#868a2aa5`. Represents an issue with the reverse side of a document. The error is considered resolved when the file with reverse side of the document changes.
See https://core.telegram.org/constructor/secureValueErrorReverseSide for reference.
func (*SecureValueErrorReverseSide) Decode ¶
func (s *SecureValueErrorReverseSide) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorReverseSide) Encode ¶
func (s *SecureValueErrorReverseSide) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorReverseSide) String ¶ added in v0.12.0
func (s *SecureValueErrorReverseSide) String() string
String implements fmt.Stringer.
type SecureValueErrorSelfie ¶
type SecureValueErrorSelfie struct {
// One of secureValueTypePassport¹, secureValueTypeDriverLicense², secureValueTypeIdentityCard³, secureValueTypeInternalPassport⁴
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypePassport
// 2) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 3) https://core.telegram.org/constructor/secureValueTypeIdentityCard
// 4) https://core.telegram.org/constructor/secureValueTypeInternalPassport
Type SecureValueTypeClass
// File hash
FileHash []byte
// Error message
Text string
}
SecureValueErrorSelfie represents TL type `secureValueErrorSelfie#e537ced6`. Represents an issue with the selfie with a document. The error is considered resolved when the file with the selfie changes.
See https://core.telegram.org/constructor/secureValueErrorSelfie for reference.
func (*SecureValueErrorSelfie) Decode ¶
func (s *SecureValueErrorSelfie) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorSelfie) Encode ¶
func (s *SecureValueErrorSelfie) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorSelfie) String ¶ added in v0.12.0
func (s *SecureValueErrorSelfie) String() string
String implements fmt.Stringer.
type SecureValueErrorTranslationFile ¶
type SecureValueErrorTranslationFile struct {
// One of secureValueTypePersonalDetails¹, secureValueTypePassport², secureValueTypeDriverLicense³, secureValueTypeIdentityCard⁴, secureValueTypeInternalPassport⁵, secureValueTypeUtilityBill⁶, secureValueTypeBankStatement⁷, secureValueTypeRentalAgreement⁸, secureValueTypePassportRegistration⁹, secureValueTypeTemporaryRegistration¹⁰
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypePersonalDetails
// 2) https://core.telegram.org/constructor/secureValueTypePassport
// 3) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 4) https://core.telegram.org/constructor/secureValueTypeIdentityCard
// 5) https://core.telegram.org/constructor/secureValueTypeInternalPassport
// 6) https://core.telegram.org/constructor/secureValueTypeUtilityBill
// 7) https://core.telegram.org/constructor/secureValueTypeBankStatement
// 8) https://core.telegram.org/constructor/secureValueTypeRentalAgreement
// 9) https://core.telegram.org/constructor/secureValueTypePassportRegistration
// 10) https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration
Type SecureValueTypeClass
// File hash
FileHash []byte
// Error message
Text string
}
SecureValueErrorTranslationFile represents TL type `secureValueErrorTranslationFile#a1144770`. Represents an issue with one of the files that constitute the translation of a document. The error is considered resolved when the file changes.
See https://core.telegram.org/constructor/secureValueErrorTranslationFile for reference.
func (*SecureValueErrorTranslationFile) Decode ¶
func (s *SecureValueErrorTranslationFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorTranslationFile) Encode ¶
func (s *SecureValueErrorTranslationFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorTranslationFile) String ¶ added in v0.12.0
func (s *SecureValueErrorTranslationFile) String() string
String implements fmt.Stringer.
type SecureValueErrorTranslationFiles ¶
type SecureValueErrorTranslationFiles struct {
// One of secureValueTypePersonalDetails¹, secureValueTypePassport², secureValueTypeDriverLicense³, secureValueTypeIdentityCard⁴, secureValueTypeInternalPassport⁵, secureValueTypeUtilityBill⁶, secureValueTypeBankStatement⁷, secureValueTypeRentalAgreement⁸, secureValueTypePassportRegistration⁹, secureValueTypeTemporaryRegistration¹⁰
//
// Links:
// 1) https://core.telegram.org/constructor/secureValueTypePersonalDetails
// 2) https://core.telegram.org/constructor/secureValueTypePassport
// 3) https://core.telegram.org/constructor/secureValueTypeDriverLicense
// 4) https://core.telegram.org/constructor/secureValueTypeIdentityCard
// 5) https://core.telegram.org/constructor/secureValueTypeInternalPassport
// 6) https://core.telegram.org/constructor/secureValueTypeUtilityBill
// 7) https://core.telegram.org/constructor/secureValueTypeBankStatement
// 8) https://core.telegram.org/constructor/secureValueTypeRentalAgreement
// 9) https://core.telegram.org/constructor/secureValueTypePassportRegistration
// 10) https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration
Type SecureValueTypeClass
// Hash
FileHash [][]byte
// Error message
Text string
}
SecureValueErrorTranslationFiles represents TL type `secureValueErrorTranslationFiles#34636dd8`. Represents an issue with the translated version of a document. The error is considered resolved when a file with the document translation changes.
See https://core.telegram.org/constructor/secureValueErrorTranslationFiles for reference.
func (*SecureValueErrorTranslationFiles) Decode ¶
func (s *SecureValueErrorTranslationFiles) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueErrorTranslationFiles) Encode ¶
func (s *SecureValueErrorTranslationFiles) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueErrorTranslationFiles) String ¶ added in v0.12.0
func (s *SecureValueErrorTranslationFiles) String() string
String implements fmt.Stringer.
type SecureValueHash ¶
type SecureValueHash struct {
// Secure value type
Type SecureValueTypeClass
// Hash
Hash []byte
}
SecureValueHash represents TL type `secureValueHash#ed1ecdb0`. Secure value hash
See https://core.telegram.org/constructor/secureValueHash for reference.
func (*SecureValueHash) Decode ¶
func (s *SecureValueHash) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueHash) Encode ¶
func (s *SecureValueHash) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueHash) String ¶ added in v0.12.0
func (s *SecureValueHash) String() string
String implements fmt.Stringer.
type SecureValueTypeAddress ¶
type SecureValueTypeAddress struct {
}
SecureValueTypeAddress represents TL type `secureValueTypeAddress#cbe31e26`. Address
See https://core.telegram.org/constructor/secureValueTypeAddress for reference.
func (*SecureValueTypeAddress) Decode ¶
func (s *SecureValueTypeAddress) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeAddress) Encode ¶
func (s *SecureValueTypeAddress) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeAddress) String ¶ added in v0.12.0
func (s *SecureValueTypeAddress) String() string
String implements fmt.Stringer.
type SecureValueTypeBankStatement ¶
type SecureValueTypeBankStatement struct {
}
SecureValueTypeBankStatement represents TL type `secureValueTypeBankStatement#89137c0d`. Bank statement
See https://core.telegram.org/constructor/secureValueTypeBankStatement for reference.
func (*SecureValueTypeBankStatement) Decode ¶
func (s *SecureValueTypeBankStatement) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeBankStatement) Encode ¶
func (s *SecureValueTypeBankStatement) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeBankStatement) String ¶ added in v0.12.0
func (s *SecureValueTypeBankStatement) String() string
String implements fmt.Stringer.
type SecureValueTypeBox ¶
type SecureValueTypeBox struct {
SecureValueType SecureValueTypeClass
}
SecureValueType boxes the SecureValueTypeClass providing a helper.
type SecureValueTypeClass ¶
type SecureValueTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SecureValueTypeClass represents SecureValueType generic type.
See https://core.telegram.org/type/SecureValueType for reference.
Example:
g, err := DecodeSecureValueType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SecureValueTypePersonalDetails: // secureValueTypePersonalDetails#9d2a81e3
case *SecureValueTypePassport: // secureValueTypePassport#3dac6a00
case *SecureValueTypeDriverLicense: // secureValueTypeDriverLicense#6e425c4
case *SecureValueTypeIdentityCard: // secureValueTypeIdentityCard#a0d0744b
case *SecureValueTypeInternalPassport: // secureValueTypeInternalPassport#99a48f23
case *SecureValueTypeAddress: // secureValueTypeAddress#cbe31e26
case *SecureValueTypeUtilityBill: // secureValueTypeUtilityBill#fc36954e
case *SecureValueTypeBankStatement: // secureValueTypeBankStatement#89137c0d
case *SecureValueTypeRentalAgreement: // secureValueTypeRentalAgreement#8b883488
case *SecureValueTypePassportRegistration: // secureValueTypePassportRegistration#99e3806a
case *SecureValueTypeTemporaryRegistration: // secureValueTypeTemporaryRegistration#ea02ec33
case *SecureValueTypePhone: // secureValueTypePhone#b320aadb
case *SecureValueTypeEmail: // secureValueTypeEmail#8e3ca7ee
default: panic(v)
}
func DecodeSecureValueType ¶
func DecodeSecureValueType(buf *bin.Buffer) (SecureValueTypeClass, error)
DecodeSecureValueType implements binary de-serialization for SecureValueTypeClass.
type SecureValueTypeDriverLicense ¶
type SecureValueTypeDriverLicense struct {
}
SecureValueTypeDriverLicense represents TL type `secureValueTypeDriverLicense#6e425c4`. Driver's license
See https://core.telegram.org/constructor/secureValueTypeDriverLicense for reference.
func (*SecureValueTypeDriverLicense) Decode ¶
func (s *SecureValueTypeDriverLicense) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeDriverLicense) Encode ¶
func (s *SecureValueTypeDriverLicense) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeDriverLicense) String ¶ added in v0.12.0
func (s *SecureValueTypeDriverLicense) String() string
String implements fmt.Stringer.
type SecureValueTypeEmail ¶
type SecureValueTypeEmail struct {
}
SecureValueTypeEmail represents TL type `secureValueTypeEmail#8e3ca7ee`. Email
See https://core.telegram.org/constructor/secureValueTypeEmail for reference.
func (*SecureValueTypeEmail) Decode ¶
func (s *SecureValueTypeEmail) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeEmail) Encode ¶
func (s *SecureValueTypeEmail) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeEmail) String ¶ added in v0.12.0
func (s *SecureValueTypeEmail) String() string
String implements fmt.Stringer.
type SecureValueTypeIdentityCard ¶
type SecureValueTypeIdentityCard struct {
}
SecureValueTypeIdentityCard represents TL type `secureValueTypeIdentityCard#a0d0744b`. Identity card
See https://core.telegram.org/constructor/secureValueTypeIdentityCard for reference.
func (*SecureValueTypeIdentityCard) Decode ¶
func (s *SecureValueTypeIdentityCard) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeIdentityCard) Encode ¶
func (s *SecureValueTypeIdentityCard) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeIdentityCard) String ¶ added in v0.12.0
func (s *SecureValueTypeIdentityCard) String() string
String implements fmt.Stringer.
type SecureValueTypeInternalPassport ¶
type SecureValueTypeInternalPassport struct {
}
SecureValueTypeInternalPassport represents TL type `secureValueTypeInternalPassport#99a48f23`. Internal passport¹
Links:
See https://core.telegram.org/constructor/secureValueTypeInternalPassport for reference.
func (*SecureValueTypeInternalPassport) Decode ¶
func (s *SecureValueTypeInternalPassport) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeInternalPassport) Encode ¶
func (s *SecureValueTypeInternalPassport) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeInternalPassport) String ¶ added in v0.12.0
func (s *SecureValueTypeInternalPassport) String() string
String implements fmt.Stringer.
type SecureValueTypePassport ¶
type SecureValueTypePassport struct {
}
SecureValueTypePassport represents TL type `secureValueTypePassport#3dac6a00`. Passport
See https://core.telegram.org/constructor/secureValueTypePassport for reference.
func (*SecureValueTypePassport) Decode ¶
func (s *SecureValueTypePassport) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypePassport) Encode ¶
func (s *SecureValueTypePassport) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypePassport) String ¶ added in v0.12.0
func (s *SecureValueTypePassport) String() string
String implements fmt.Stringer.
type SecureValueTypePassportRegistration ¶
type SecureValueTypePassportRegistration struct {
}
SecureValueTypePassportRegistration represents TL type `secureValueTypePassportRegistration#99e3806a`. Internal registration passport¹
Links:
See https://core.telegram.org/constructor/secureValueTypePassportRegistration for reference.
func (*SecureValueTypePassportRegistration) Decode ¶
func (s *SecureValueTypePassportRegistration) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypePassportRegistration) Encode ¶
func (s *SecureValueTypePassportRegistration) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypePassportRegistration) String ¶ added in v0.12.0
func (s *SecureValueTypePassportRegistration) String() string
String implements fmt.Stringer.
type SecureValueTypePersonalDetails ¶
type SecureValueTypePersonalDetails struct {
}
SecureValueTypePersonalDetails represents TL type `secureValueTypePersonalDetails#9d2a81e3`. Personal details
See https://core.telegram.org/constructor/secureValueTypePersonalDetails for reference.
func (*SecureValueTypePersonalDetails) Decode ¶
func (s *SecureValueTypePersonalDetails) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypePersonalDetails) Encode ¶
func (s *SecureValueTypePersonalDetails) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypePersonalDetails) String ¶ added in v0.12.0
func (s *SecureValueTypePersonalDetails) String() string
String implements fmt.Stringer.
type SecureValueTypePhone ¶
type SecureValueTypePhone struct {
}
SecureValueTypePhone represents TL type `secureValueTypePhone#b320aadb`. Phone
See https://core.telegram.org/constructor/secureValueTypePhone for reference.
func (*SecureValueTypePhone) Decode ¶
func (s *SecureValueTypePhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypePhone) Encode ¶
func (s *SecureValueTypePhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypePhone) String ¶ added in v0.12.0
func (s *SecureValueTypePhone) String() string
String implements fmt.Stringer.
type SecureValueTypeRentalAgreement ¶
type SecureValueTypeRentalAgreement struct {
}
SecureValueTypeRentalAgreement represents TL type `secureValueTypeRentalAgreement#8b883488`. Rental agreement
See https://core.telegram.org/constructor/secureValueTypeRentalAgreement for reference.
func (*SecureValueTypeRentalAgreement) Decode ¶
func (s *SecureValueTypeRentalAgreement) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeRentalAgreement) Encode ¶
func (s *SecureValueTypeRentalAgreement) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeRentalAgreement) String ¶ added in v0.12.0
func (s *SecureValueTypeRentalAgreement) String() string
String implements fmt.Stringer.
type SecureValueTypeTemporaryRegistration ¶
type SecureValueTypeTemporaryRegistration struct {
}
SecureValueTypeTemporaryRegistration represents TL type `secureValueTypeTemporaryRegistration#ea02ec33`. Temporary registration
See https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration for reference.
func (*SecureValueTypeTemporaryRegistration) Decode ¶
func (s *SecureValueTypeTemporaryRegistration) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeTemporaryRegistration) Encode ¶
func (s *SecureValueTypeTemporaryRegistration) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeTemporaryRegistration) String ¶ added in v0.12.0
func (s *SecureValueTypeTemporaryRegistration) String() string
String implements fmt.Stringer.
type SecureValueTypeUtilityBill ¶
type SecureValueTypeUtilityBill struct {
}
SecureValueTypeUtilityBill represents TL type `secureValueTypeUtilityBill#fc36954e`. Utility bill
See https://core.telegram.org/constructor/secureValueTypeUtilityBill for reference.
func (*SecureValueTypeUtilityBill) Decode ¶
func (s *SecureValueTypeUtilityBill) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueTypeUtilityBill) Encode ¶
func (s *SecureValueTypeUtilityBill) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueTypeUtilityBill) String ¶ added in v0.12.0
func (s *SecureValueTypeUtilityBill) String() string
String implements fmt.Stringer.
type SecureValueVector ¶ added in v0.8.0
type SecureValueVector struct {
// Elements of Vector<SecureValue>
Elems []SecureValue
}
SecureValueVector is a box for Vector<SecureValue>
func (*SecureValueVector) Decode ¶ added in v0.8.0
func (vec *SecureValueVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SecureValueVector) Encode ¶ added in v0.8.0
func (vec *SecureValueVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SecureValueVector) String ¶ added in v0.12.0
func (vec *SecureValueVector) String() string
String implements fmt.Stringer.
type SendMessageActionBox ¶
type SendMessageActionBox struct {
SendMessageAction SendMessageActionClass
}
SendMessageAction boxes the SendMessageActionClass providing a helper.
type SendMessageActionClass ¶
type SendMessageActionClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
SendMessageActionClass represents SendMessageAction generic type.
See https://core.telegram.org/type/SendMessageAction for reference.
Example:
g, err := DecodeSendMessageAction(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *SendMessageTypingAction: // sendMessageTypingAction#16bf744e
case *SendMessageCancelAction: // sendMessageCancelAction#fd5ec8f5
case *SendMessageRecordVideoAction: // sendMessageRecordVideoAction#a187d66f
case *SendMessageUploadVideoAction: // sendMessageUploadVideoAction#e9763aec
case *SendMessageRecordAudioAction: // sendMessageRecordAudioAction#d52f73f7
case *SendMessageUploadAudioAction: // sendMessageUploadAudioAction#f351d7ab
case *SendMessageUploadPhotoAction: // sendMessageUploadPhotoAction#d1d34a26
case *SendMessageUploadDocumentAction: // sendMessageUploadDocumentAction#aa0cd9e4
case *SendMessageGeoLocationAction: // sendMessageGeoLocationAction#176f8ba1
case *SendMessageChooseContactAction: // sendMessageChooseContactAction#628cbc6f
case *SendMessageGamePlayAction: // sendMessageGamePlayAction#dd6a8f48
case *SendMessageRecordRoundAction: // sendMessageRecordRoundAction#88f27fbc
case *SendMessageUploadRoundAction: // sendMessageUploadRoundAction#243e1c66
case *SpeakingInGroupCallAction: // speakingInGroupCallAction#d92c2285
default: panic(v)
}
func DecodeSendMessageAction ¶
func DecodeSendMessageAction(buf *bin.Buffer) (SendMessageActionClass, error)
DecodeSendMessageAction implements binary de-serialization for SendMessageActionClass.
type SendMessageCancelAction ¶
type SendMessageCancelAction struct {
}
SendMessageCancelAction represents TL type `sendMessageCancelAction#fd5ec8f5`. Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload.
See https://core.telegram.org/constructor/sendMessageCancelAction for reference.
func (*SendMessageCancelAction) Decode ¶
func (s *SendMessageCancelAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageCancelAction) Encode ¶
func (s *SendMessageCancelAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageCancelAction) String ¶ added in v0.12.0
func (s *SendMessageCancelAction) String() string
String implements fmt.Stringer.
type SendMessageChooseContactAction ¶
type SendMessageChooseContactAction struct {
}
SendMessageChooseContactAction represents TL type `sendMessageChooseContactAction#628cbc6f`. User is selecting a contact to share.
See https://core.telegram.org/constructor/sendMessageChooseContactAction for reference.
func (*SendMessageChooseContactAction) Decode ¶
func (s *SendMessageChooseContactAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageChooseContactAction) Encode ¶
func (s *SendMessageChooseContactAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageChooseContactAction) String ¶ added in v0.12.0
func (s *SendMessageChooseContactAction) String() string
String implements fmt.Stringer.
type SendMessageGamePlayAction ¶
type SendMessageGamePlayAction struct {
}
SendMessageGamePlayAction represents TL type `sendMessageGamePlayAction#dd6a8f48`. User is playing a game
See https://core.telegram.org/constructor/sendMessageGamePlayAction for reference.
func (*SendMessageGamePlayAction) Decode ¶
func (s *SendMessageGamePlayAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageGamePlayAction) Encode ¶
func (s *SendMessageGamePlayAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageGamePlayAction) String ¶ added in v0.12.0
func (s *SendMessageGamePlayAction) String() string
String implements fmt.Stringer.
type SendMessageGeoLocationAction ¶
type SendMessageGeoLocationAction struct {
}
SendMessageGeoLocationAction represents TL type `sendMessageGeoLocationAction#176f8ba1`. User is selecting a location to share.
See https://core.telegram.org/constructor/sendMessageGeoLocationAction for reference.
func (*SendMessageGeoLocationAction) Decode ¶
func (s *SendMessageGeoLocationAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageGeoLocationAction) Encode ¶
func (s *SendMessageGeoLocationAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageGeoLocationAction) String ¶ added in v0.12.0
func (s *SendMessageGeoLocationAction) String() string
String implements fmt.Stringer.
type SendMessageRecordAudioAction ¶
type SendMessageRecordAudioAction struct {
}
SendMessageRecordAudioAction represents TL type `sendMessageRecordAudioAction#d52f73f7`. User is recording a voice message.
See https://core.telegram.org/constructor/sendMessageRecordAudioAction for reference.
func (*SendMessageRecordAudioAction) Decode ¶
func (s *SendMessageRecordAudioAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageRecordAudioAction) Encode ¶
func (s *SendMessageRecordAudioAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageRecordAudioAction) String ¶ added in v0.12.0
func (s *SendMessageRecordAudioAction) String() string
String implements fmt.Stringer.
type SendMessageRecordRoundAction ¶
type SendMessageRecordRoundAction struct {
}
SendMessageRecordRoundAction represents TL type `sendMessageRecordRoundAction#88f27fbc`. User is recording a round video to share
See https://core.telegram.org/constructor/sendMessageRecordRoundAction for reference.
func (*SendMessageRecordRoundAction) Decode ¶
func (s *SendMessageRecordRoundAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageRecordRoundAction) Encode ¶
func (s *SendMessageRecordRoundAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageRecordRoundAction) String ¶ added in v0.12.0
func (s *SendMessageRecordRoundAction) String() string
String implements fmt.Stringer.
type SendMessageRecordVideoAction ¶
type SendMessageRecordVideoAction struct {
}
SendMessageRecordVideoAction represents TL type `sendMessageRecordVideoAction#a187d66f`. User is recording a video.
See https://core.telegram.org/constructor/sendMessageRecordVideoAction for reference.
func (*SendMessageRecordVideoAction) Decode ¶
func (s *SendMessageRecordVideoAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageRecordVideoAction) Encode ¶
func (s *SendMessageRecordVideoAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageRecordVideoAction) String ¶ added in v0.12.0
func (s *SendMessageRecordVideoAction) String() string
String implements fmt.Stringer.
type SendMessageTypingAction ¶
type SendMessageTypingAction struct {
}
SendMessageTypingAction represents TL type `sendMessageTypingAction#16bf744e`. User is typing.
See https://core.telegram.org/constructor/sendMessageTypingAction for reference.
func (*SendMessageTypingAction) Decode ¶
func (s *SendMessageTypingAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageTypingAction) Encode ¶
func (s *SendMessageTypingAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageTypingAction) String ¶ added in v0.12.0
func (s *SendMessageTypingAction) String() string
String implements fmt.Stringer.
type SendMessageUploadAudioAction ¶
type SendMessageUploadAudioAction struct {
// Progress percentage
Progress int
}
SendMessageUploadAudioAction represents TL type `sendMessageUploadAudioAction#f351d7ab`. User is uploading a voice message.
See https://core.telegram.org/constructor/sendMessageUploadAudioAction for reference.
func (*SendMessageUploadAudioAction) Decode ¶
func (s *SendMessageUploadAudioAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageUploadAudioAction) Encode ¶
func (s *SendMessageUploadAudioAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageUploadAudioAction) String ¶ added in v0.12.0
func (s *SendMessageUploadAudioAction) String() string
String implements fmt.Stringer.
type SendMessageUploadDocumentAction ¶
type SendMessageUploadDocumentAction struct {
// Progress percentage
Progress int
}
SendMessageUploadDocumentAction represents TL type `sendMessageUploadDocumentAction#aa0cd9e4`. User is uploading a file.
See https://core.telegram.org/constructor/sendMessageUploadDocumentAction for reference.
func (*SendMessageUploadDocumentAction) Decode ¶
func (s *SendMessageUploadDocumentAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageUploadDocumentAction) Encode ¶
func (s *SendMessageUploadDocumentAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageUploadDocumentAction) String ¶ added in v0.12.0
func (s *SendMessageUploadDocumentAction) String() string
String implements fmt.Stringer.
type SendMessageUploadPhotoAction ¶
type SendMessageUploadPhotoAction struct {
// Progress percentage
Progress int
}
SendMessageUploadPhotoAction represents TL type `sendMessageUploadPhotoAction#d1d34a26`. User is uploading a photo.
See https://core.telegram.org/constructor/sendMessageUploadPhotoAction for reference.
func (*SendMessageUploadPhotoAction) Decode ¶
func (s *SendMessageUploadPhotoAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageUploadPhotoAction) Encode ¶
func (s *SendMessageUploadPhotoAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageUploadPhotoAction) String ¶ added in v0.12.0
func (s *SendMessageUploadPhotoAction) String() string
String implements fmt.Stringer.
type SendMessageUploadRoundAction ¶
type SendMessageUploadRoundAction struct {
// Progress percentage
Progress int
}
SendMessageUploadRoundAction represents TL type `sendMessageUploadRoundAction#243e1c66`. User is uploading a round video
See https://core.telegram.org/constructor/sendMessageUploadRoundAction for reference.
func (*SendMessageUploadRoundAction) Decode ¶
func (s *SendMessageUploadRoundAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageUploadRoundAction) Encode ¶
func (s *SendMessageUploadRoundAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageUploadRoundAction) String ¶ added in v0.12.0
func (s *SendMessageUploadRoundAction) String() string
String implements fmt.Stringer.
type SendMessageUploadVideoAction ¶
type SendMessageUploadVideoAction struct {
// Progress percentage
Progress int
}
SendMessageUploadVideoAction represents TL type `sendMessageUploadVideoAction#e9763aec`. User is uploading a video.
See https://core.telegram.org/constructor/sendMessageUploadVideoAction for reference.
func (*SendMessageUploadVideoAction) Decode ¶
func (s *SendMessageUploadVideoAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SendMessageUploadVideoAction) Encode ¶
func (s *SendMessageUploadVideoAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SendMessageUploadVideoAction) String ¶ added in v0.12.0
func (s *SendMessageUploadVideoAction) String() string
String implements fmt.Stringer.
type ServiceNotificationHandler ¶ added in v0.9.0
type ServiceNotificationHandler func(ctx UpdateContext, update *UpdateServiceNotification) error
ServiceNotificationHandler is a ServiceNotification event handler.
type ShippingOption ¶
type ShippingOption struct {
// Option ID
ID string
// Title
Title string
// List of price portions
Prices []LabeledPrice
}
ShippingOption represents TL type `shippingOption#b6213cdf`. Shipping option
See https://core.telegram.org/constructor/shippingOption for reference.
func (*ShippingOption) Decode ¶
func (s *ShippingOption) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ShippingOption) Encode ¶
func (s *ShippingOption) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ShippingOption) String ¶ added in v0.12.0
func (s *ShippingOption) String() string
String implements fmt.Stringer.
type SpeakingInGroupCallAction ¶ added in v0.13.0
type SpeakingInGroupCallAction struct {
}
SpeakingInGroupCallAction represents TL type `speakingInGroupCallAction#d92c2285`.
See https://core.telegram.org/constructor/speakingInGroupCallAction for reference.
func (*SpeakingInGroupCallAction) Decode ¶ added in v0.13.0
func (s *SpeakingInGroupCallAction) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SpeakingInGroupCallAction) Encode ¶ added in v0.13.0
func (s *SpeakingInGroupCallAction) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SpeakingInGroupCallAction) String ¶ added in v0.13.0
func (s *SpeakingInGroupCallAction) String() string
String implements fmt.Stringer.
type StatsAbsValueAndPrev ¶
type StatsAbsValueAndPrev struct {
// Current value
Current float64
// Previous value
Previous float64
}
StatsAbsValueAndPrev represents TL type `statsAbsValueAndPrev#cb43acde`. Statistics value couple; intial and final value for period of time currently in consideration
See https://core.telegram.org/constructor/statsAbsValueAndPrev for reference.
func (*StatsAbsValueAndPrev) Decode ¶
func (s *StatsAbsValueAndPrev) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsAbsValueAndPrev) Encode ¶
func (s *StatsAbsValueAndPrev) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsAbsValueAndPrev) String ¶ added in v0.12.0
func (s *StatsAbsValueAndPrev) String() string
String implements fmt.Stringer.
type StatsBroadcastStats ¶
type StatsBroadcastStats struct {
// Period in consideration
Period StatsDateRangeDays
// Follower count change for period in consideration
Followers StatsAbsValueAndPrev
// total_viewcount/postcount, for posts posted during the period in consideration (views_per_post). Note that in this case, current refers to the period in consideration (min_date till max_date), and prev refers to the previous period ((min_date - (max_date - min_date)) till min_date).
ViewsPerPost StatsAbsValueAndPrev
SharesPerPost StatsAbsValueAndPrev
// Percentage of subscribers with enabled notifications
EnabledNotifications StatsPercentValue
// Channel growth graph (absolute subscriber count)
GrowthGraph StatsGraphClass
// Followers growth graph (relative subscriber count)
FollowersGraph StatsGraphClass
// Muted users graph (relative)
MuteGraph StatsGraphClass
// Views per hour graph (absolute)
TopHoursGraph StatsGraphClass
// Interactions graph (absolute)
InteractionsGraph StatsGraphClass
// IV interactions graph (absolute)
IvInteractionsGraph StatsGraphClass
// Views by source graph (absolute)
ViewsBySourceGraph StatsGraphClass
// New followers by source graph (absolute)
NewFollowersBySourceGraph StatsGraphClass
// Subscriber language graph (piechart)
LanguagesGraph StatsGraphClass
// Recent message interactions
RecentMessageInteractions []MessageInteractionCounters
}
StatsBroadcastStats represents TL type `stats.broadcastStats#bdf78394`. Channel statistics¹.
Links:
See https://core.telegram.org/constructor/stats.broadcastStats for reference.
func (*StatsBroadcastStats) Decode ¶
func (b *StatsBroadcastStats) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsBroadcastStats) Encode ¶
func (b *StatsBroadcastStats) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsBroadcastStats) String ¶ added in v0.12.0
func (b *StatsBroadcastStats) String() string
String implements fmt.Stringer.
type StatsDateRangeDays ¶
StatsDateRangeDays represents TL type `statsDateRangeDays#b637edaf`. Channel statistics¹ date range
Links:
See https://core.telegram.org/constructor/statsDateRangeDays for reference.
func (*StatsDateRangeDays) Decode ¶
func (s *StatsDateRangeDays) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsDateRangeDays) Encode ¶
func (s *StatsDateRangeDays) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsDateRangeDays) String ¶ added in v0.12.0
func (s *StatsDateRangeDays) String() string
String implements fmt.Stringer.
type StatsGetBroadcastStatsRequest ¶
type StatsGetBroadcastStatsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to enable dark theme for graph colors
Dark bool
// The channel
Channel InputChannelClass
}
StatsGetBroadcastStatsRequest represents TL type `stats.getBroadcastStats#ab42441a`. Get channel statistics¹
Links:
See https://core.telegram.org/method/stats.getBroadcastStats for reference.
func (*StatsGetBroadcastStatsRequest) Decode ¶
func (g *StatsGetBroadcastStatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGetBroadcastStatsRequest) Encode ¶
func (g *StatsGetBroadcastStatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGetBroadcastStatsRequest) SetDark ¶
func (g *StatsGetBroadcastStatsRequest) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*StatsGetBroadcastStatsRequest) String ¶ added in v0.12.0
func (g *StatsGetBroadcastStatsRequest) String() string
String implements fmt.Stringer.
type StatsGetMegagroupStatsRequest ¶
type StatsGetMegagroupStatsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to enable dark theme for graph colors
Dark bool
// Supergroup ID¹
//
// Links:
// 1) https://core.telegram.org/api/channel
Channel InputChannelClass
}
StatsGetMegagroupStatsRequest represents TL type `stats.getMegagroupStats#dcdf8607`. Get supergroup statistics¹
Links:
See https://core.telegram.org/method/stats.getMegagroupStats for reference.
func (*StatsGetMegagroupStatsRequest) Decode ¶
func (g *StatsGetMegagroupStatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGetMegagroupStatsRequest) Encode ¶
func (g *StatsGetMegagroupStatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGetMegagroupStatsRequest) SetDark ¶
func (g *StatsGetMegagroupStatsRequest) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*StatsGetMegagroupStatsRequest) String ¶ added in v0.12.0
func (g *StatsGetMegagroupStatsRequest) String() string
String implements fmt.Stringer.
type StatsGetMessagePublicForwardsRequest ¶
type StatsGetMessagePublicForwardsRequest struct {
// Source channel
Channel InputChannelClass
// Source message ID
MsgID int
// Initially 0, then set to the next_rate parameter of messages.messagesSlice¹
//
// Links:
// 1) https://core.telegram.org/constructor/messages.messagesSlice
OffsetRate int
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetPeer InputPeerClass
// Offsets for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
OffsetID int
// Maximum number of results to return, see pagination¹
//
// Links:
// 1) https://core.telegram.org/api/offsets
Limit int
}
StatsGetMessagePublicForwardsRequest represents TL type `stats.getMessagePublicForwards#5630281b`. Obtains a list of messages, indicating to which other public channels was a channel message forwarded. Will return a list of messages¹ with peer_id equal to the public channel to which this message was forwarded.
Links:
See https://core.telegram.org/method/stats.getMessagePublicForwards for reference.
func (*StatsGetMessagePublicForwardsRequest) Decode ¶
func (g *StatsGetMessagePublicForwardsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGetMessagePublicForwardsRequest) Encode ¶
func (g *StatsGetMessagePublicForwardsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGetMessagePublicForwardsRequest) String ¶ added in v0.12.0
func (g *StatsGetMessagePublicForwardsRequest) String() string
String implements fmt.Stringer.
type StatsGetMessageStatsRequest ¶
type StatsGetMessageStatsRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether to enable dark theme for graph colors
Dark bool
// Channel ID
Channel InputChannelClass
// Message ID
MsgID int
}
StatsGetMessageStatsRequest represents TL type `stats.getMessageStats#b6e0a3f5`. Get message statistics¹
Links:
See https://core.telegram.org/method/stats.getMessageStats for reference.
func (*StatsGetMessageStatsRequest) Decode ¶
func (g *StatsGetMessageStatsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGetMessageStatsRequest) Encode ¶
func (g *StatsGetMessageStatsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGetMessageStatsRequest) SetDark ¶
func (g *StatsGetMessageStatsRequest) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*StatsGetMessageStatsRequest) String ¶ added in v0.12.0
func (g *StatsGetMessageStatsRequest) String() string
String implements fmt.Stringer.
type StatsGraph ¶
type StatsGraph struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Statistics data
JSON DataJSON
// Zoom token
//
// Use SetZoomToken and GetZoomToken helpers.
ZoomToken string
}
StatsGraph represents TL type `statsGraph#8ea464b6`. Channel statistics graph¹
Links:
See https://core.telegram.org/constructor/statsGraph for reference.
func (*StatsGraph) Decode ¶
func (s *StatsGraph) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGraph) Encode ¶
func (s *StatsGraph) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGraph) GetZoomToken ¶
func (s *StatsGraph) GetZoomToken() (value string, ok bool)
GetZoomToken returns value of ZoomToken conditional field and boolean which is true if field was set.
func (*StatsGraph) SetZoomToken ¶
func (s *StatsGraph) SetZoomToken(value string)
SetZoomToken sets value of ZoomToken conditional field.
func (*StatsGraph) String ¶ added in v0.12.0
func (s *StatsGraph) String() string
String implements fmt.Stringer.
type StatsGraphAsync ¶
type StatsGraphAsync struct {
// Token to use for fetching the async graph
Token string
}
StatsGraphAsync represents TL type `statsGraphAsync#4a27eb2d`. This channel statistics graph¹ must be generated asynchronously using stats.loadAsyncGraph² to reduce server load
Links:
See https://core.telegram.org/constructor/statsGraphAsync for reference.
func (*StatsGraphAsync) Decode ¶
func (s *StatsGraphAsync) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGraphAsync) Encode ¶
func (s *StatsGraphAsync) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGraphAsync) String ¶ added in v0.12.0
func (s *StatsGraphAsync) String() string
String implements fmt.Stringer.
type StatsGraphBox ¶
type StatsGraphBox struct {
StatsGraph StatsGraphClass
}
StatsGraph boxes the StatsGraphClass providing a helper.
type StatsGraphClass ¶
type StatsGraphClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
StatsGraphClass represents StatsGraph generic type.
See https://core.telegram.org/type/StatsGraph for reference.
Example:
g, err := DecodeStatsGraph(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *StatsGraphAsync: // statsGraphAsync#4a27eb2d
case *StatsGraphError: // statsGraphError#bedc9822
case *StatsGraph: // statsGraph#8ea464b6
default: panic(v)
}
func DecodeStatsGraph ¶
func DecodeStatsGraph(buf *bin.Buffer) (StatsGraphClass, error)
DecodeStatsGraph implements binary de-serialization for StatsGraphClass.
type StatsGraphError ¶
type StatsGraphError struct {
// The error
Error string
}
StatsGraphError represents TL type `statsGraphError#bedc9822`. An error occurred while generating the statistics graph¹
Links:
See https://core.telegram.org/constructor/statsGraphError for reference.
func (*StatsGraphError) Decode ¶
func (s *StatsGraphError) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGraphError) Encode ¶
func (s *StatsGraphError) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGraphError) String ¶ added in v0.12.0
func (s *StatsGraphError) String() string
String implements fmt.Stringer.
type StatsGroupTopAdmin ¶
type StatsGroupTopAdmin struct {
// User ID
UserID int
// Number of deleted messages for statistics¹ period in consideration
//
// Links:
// 1) https://core.telegram.org/api/stats
Deleted int
// Number of kicked users for statistics¹ period in consideration
//
// Links:
// 1) https://core.telegram.org/api/stats
Kicked int
// Number of banned users for statistics¹ period in consideration
//
// Links:
// 1) https://core.telegram.org/api/stats
Banned int
}
StatsGroupTopAdmin represents TL type `statsGroupTopAdmin#6014f412`. Information about an active admin in a supergroup
See https://core.telegram.org/constructor/statsGroupTopAdmin for reference.
func (*StatsGroupTopAdmin) Decode ¶
func (s *StatsGroupTopAdmin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGroupTopAdmin) Encode ¶
func (s *StatsGroupTopAdmin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGroupTopAdmin) String ¶ added in v0.12.0
func (s *StatsGroupTopAdmin) String() string
String implements fmt.Stringer.
type StatsGroupTopInviter ¶
type StatsGroupTopInviter struct {
// User ID
UserID int
// Number of invitations for statistics¹ period in consideration
//
// Links:
// 1) https://core.telegram.org/api/stats
Invitations int
}
StatsGroupTopInviter represents TL type `statsGroupTopInviter#31962a4c`. Information about an active supergroup inviter
See https://core.telegram.org/constructor/statsGroupTopInviter for reference.
func (*StatsGroupTopInviter) Decode ¶
func (s *StatsGroupTopInviter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGroupTopInviter) Encode ¶
func (s *StatsGroupTopInviter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGroupTopInviter) String ¶ added in v0.12.0
func (s *StatsGroupTopInviter) String() string
String implements fmt.Stringer.
type StatsGroupTopPoster ¶
type StatsGroupTopPoster struct {
// User ID
UserID int
// Number of messages for statistics¹ period in consideration
//
// Links:
// 1) https://core.telegram.org/api/stats
Messages int
// Average number of characters per message
AvgChars int
}
StatsGroupTopPoster represents TL type `statsGroupTopPoster#18f3d0f7`. Information about an active user in a supergroup
See https://core.telegram.org/constructor/statsGroupTopPoster for reference.
func (*StatsGroupTopPoster) Decode ¶
func (s *StatsGroupTopPoster) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsGroupTopPoster) Encode ¶
func (s *StatsGroupTopPoster) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsGroupTopPoster) String ¶ added in v0.12.0
func (s *StatsGroupTopPoster) String() string
String implements fmt.Stringer.
type StatsLoadAsyncGraphRequest ¶
type StatsLoadAsyncGraphRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Graph token from statsGraphAsync¹ constructor
//
// Links:
// 1) https://core.telegram.org/constructor/statsGraphAsync
Token string
// Zoom value, if required
//
// Use SetX and GetX helpers.
X int64
}
StatsLoadAsyncGraphRequest represents TL type `stats.loadAsyncGraph#621d5fa0`. Load channel statistics graph¹ asynchronously
Links:
See https://core.telegram.org/method/stats.loadAsyncGraph for reference.
func (*StatsLoadAsyncGraphRequest) Decode ¶
func (l *StatsLoadAsyncGraphRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsLoadAsyncGraphRequest) Encode ¶
func (l *StatsLoadAsyncGraphRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsLoadAsyncGraphRequest) GetX ¶
func (l *StatsLoadAsyncGraphRequest) GetX() (value int64, ok bool)
GetX returns value of X conditional field and boolean which is true if field was set.
func (*StatsLoadAsyncGraphRequest) SetX ¶
func (l *StatsLoadAsyncGraphRequest) SetX(value int64)
SetX sets value of X conditional field.
func (*StatsLoadAsyncGraphRequest) String ¶ added in v0.12.0
func (l *StatsLoadAsyncGraphRequest) String() string
String implements fmt.Stringer.
type StatsMegagroupStats ¶
type StatsMegagroupStats struct {
// Period in consideration
Period StatsDateRangeDays
// Member count change for period in consideration
Members StatsAbsValueAndPrev
// Message number change for period in consideration
Messages StatsAbsValueAndPrev
// Number of users that viewed messages, for range in consideration
Viewers StatsAbsValueAndPrev
// Number of users that posted messages, for range in consideration
Posters StatsAbsValueAndPrev
// Supergroup growth graph (absolute subscriber count)
GrowthGraph StatsGraphClass
// Members growth (relative subscriber count)
MembersGraph StatsGraphClass
// New members by source graph
NewMembersBySourceGraph StatsGraphClass
// Subscriber language graph (piechart)
LanguagesGraph StatsGraphClass
// Message activity graph (stacked bar graph, message type)
MessagesGraph StatsGraphClass
// Group activity graph (deleted, modified messages, blocked users)
ActionsGraph StatsGraphClass
// Activity per hour graph (absolute)
TopHoursGraph StatsGraphClass
// Activity per day of week graph (absolute)
WeekdaysGraph StatsGraphClass
// Info about most active group members
TopPosters []StatsGroupTopPoster
// Info about most active group admins
TopAdmins []StatsGroupTopAdmin
// Info about most active group inviters
TopInviters []StatsGroupTopInviter
// Info about users mentioned in statistics
Users []UserClass
}
StatsMegagroupStats represents TL type `stats.megagroupStats#ef7ff916`. Supergroup statistics¹
Links:
See https://core.telegram.org/constructor/stats.megagroupStats for reference.
func (*StatsMegagroupStats) Decode ¶
func (m *StatsMegagroupStats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsMegagroupStats) Encode ¶
func (m *StatsMegagroupStats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsMegagroupStats) String ¶ added in v0.12.0
func (m *StatsMegagroupStats) String() string
String implements fmt.Stringer.
type StatsMessageStats ¶
type StatsMessageStats struct {
// Message view graph
ViewsGraph StatsGraphClass
}
StatsMessageStats represents TL type `stats.messageStats#8999f295`. Message statistics
See https://core.telegram.org/constructor/stats.messageStats for reference.
func (*StatsMessageStats) Decode ¶
func (m *StatsMessageStats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsMessageStats) Encode ¶
func (m *StatsMessageStats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsMessageStats) String ¶ added in v0.12.0
func (m *StatsMessageStats) String() string
String implements fmt.Stringer.
type StatsPercentValue ¶
StatsPercentValue represents TL type `statsPercentValue#cbce2fe0`. Channel statistics percentage¹. Compute the percentage simply by doing part * total / 100
Links:
See https://core.telegram.org/constructor/statsPercentValue for reference.
func (*StatsPercentValue) Decode ¶
func (s *StatsPercentValue) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StatsPercentValue) Encode ¶
func (s *StatsPercentValue) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StatsPercentValue) String ¶ added in v0.12.0
func (s *StatsPercentValue) String() string
String implements fmt.Stringer.
type StatsURL ¶
type StatsURL struct {
// Chat statistics
URL string
}
StatsURL represents TL type `statsURL#47a971e0`. URL with chat statistics
See https://core.telegram.org/constructor/statsURL for reference.
type StickerPack ¶
StickerPack represents TL type `stickerPack#12b299d4`. A stickerpack is a group of stickers associated to the same emoji. It is not a sticker pack the way it is usually intended, you may be looking for a StickerSet¹.
Links:
See https://core.telegram.org/constructor/stickerPack for reference.
func (*StickerPack) Decode ¶
func (s *StickerPack) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickerPack) Encode ¶
func (s *StickerPack) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickerPack) String ¶ added in v0.12.0
func (s *StickerPack) String() string
String implements fmt.Stringer.
type StickerSet ¶
type StickerSet struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this stickerset was archived (due to too many saved stickers in the current account)
Archived bool
// Is this stickerset official
Official bool
// Is this a mask stickerset
Masks bool
// Is this an animated stickerpack
Animated bool
// When was this stickerset installed
//
// Use SetInstalledDate and GetInstalledDate helpers.
InstalledDate int
// ID of the stickerset
ID int64
// Access hash of stickerset
AccessHash int64
// Title of stickerset
Title string
// Short name of stickerset to use in tg://addstickers?set=short_name
ShortName string
// Thumbs field of StickerSet.
//
// Use SetThumbs and GetThumbs helpers.
Thumbs []PhotoSizeClass
// DC ID of thumbnail
//
// Use SetThumbDCID and GetThumbDCID helpers.
ThumbDCID int
// Number of stickers in pack
Count int
// Hash
Hash int
}
StickerSet represents TL type `stickerSet#40e237a8`. Represents a stickerset (stickerpack)
See https://core.telegram.org/constructor/stickerSet for reference.
func (*StickerSet) Decode ¶
func (s *StickerSet) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickerSet) Encode ¶
func (s *StickerSet) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickerSet) GetInstalledDate ¶
func (s *StickerSet) GetInstalledDate() (value int, ok bool)
GetInstalledDate returns value of InstalledDate conditional field and boolean which is true if field was set.
func (*StickerSet) GetThumbDCID ¶
func (s *StickerSet) GetThumbDCID() (value int, ok bool)
GetThumbDCID returns value of ThumbDCID conditional field and boolean which is true if field was set.
func (*StickerSet) GetThumbs ¶ added in v0.13.0
func (s *StickerSet) GetThumbs() (value []PhotoSizeClass, ok bool)
GetThumbs returns value of Thumbs conditional field and boolean which is true if field was set.
func (*StickerSet) SetAnimated ¶
func (s *StickerSet) SetAnimated(value bool)
SetAnimated sets value of Animated conditional field.
func (*StickerSet) SetArchived ¶
func (s *StickerSet) SetArchived(value bool)
SetArchived sets value of Archived conditional field.
func (*StickerSet) SetInstalledDate ¶
func (s *StickerSet) SetInstalledDate(value int)
SetInstalledDate sets value of InstalledDate conditional field.
func (*StickerSet) SetMasks ¶
func (s *StickerSet) SetMasks(value bool)
SetMasks sets value of Masks conditional field.
func (*StickerSet) SetOfficial ¶
func (s *StickerSet) SetOfficial(value bool)
SetOfficial sets value of Official conditional field.
func (*StickerSet) SetThumbDCID ¶
func (s *StickerSet) SetThumbDCID(value int)
SetThumbDCID sets value of ThumbDCID conditional field.
func (*StickerSet) SetThumbs ¶ added in v0.13.0
func (s *StickerSet) SetThumbs(value []PhotoSizeClass)
SetThumbs sets value of Thumbs conditional field.
func (*StickerSet) String ¶ added in v0.12.0
func (s *StickerSet) String() string
String implements fmt.Stringer.
type StickerSetCovered ¶
type StickerSetCovered struct {
// Stickerset
Set StickerSet
// Preview
Cover DocumentClass
}
StickerSetCovered represents TL type `stickerSetCovered#6410a5d2`. Stickerset, with a specific sticker as preview
See https://core.telegram.org/constructor/stickerSetCovered for reference.
func (*StickerSetCovered) Decode ¶
func (s *StickerSetCovered) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickerSetCovered) Encode ¶
func (s *StickerSetCovered) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickerSetCovered) String ¶ added in v0.12.0
func (s *StickerSetCovered) String() string
String implements fmt.Stringer.
type StickerSetCoveredBox ¶
type StickerSetCoveredBox struct {
StickerSetCovered StickerSetCoveredClass
}
StickerSetCovered boxes the StickerSetCoveredClass providing a helper.
type StickerSetCoveredClass ¶
type StickerSetCoveredClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
StickerSetCoveredClass represents StickerSetCovered generic type.
See https://core.telegram.org/type/StickerSetCovered for reference.
Example:
g, err := DecodeStickerSetCovered(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *StickerSetCovered: // stickerSetCovered#6410a5d2
case *StickerSetMultiCovered: // stickerSetMultiCovered#3407e51b
default: panic(v)
}
func DecodeStickerSetCovered ¶
func DecodeStickerSetCovered(buf *bin.Buffer) (StickerSetCoveredClass, error)
DecodeStickerSetCovered implements binary de-serialization for StickerSetCoveredClass.
type StickerSetCoveredClassVector ¶ added in v0.8.0
type StickerSetCoveredClassVector struct {
// Elements of Vector<StickerSetCovered>
Elems []StickerSetCoveredClass
}
StickerSetCoveredClassVector is a box for Vector<StickerSetCovered>
func (*StickerSetCoveredClassVector) Decode ¶ added in v0.8.0
func (vec *StickerSetCoveredClassVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickerSetCoveredClassVector) Encode ¶ added in v0.8.0
func (vec *StickerSetCoveredClassVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickerSetCoveredClassVector) String ¶ added in v0.12.0
func (vec *StickerSetCoveredClassVector) String() string
String implements fmt.Stringer.
type StickerSetMultiCovered ¶
type StickerSetMultiCovered struct {
// Stickerset
Set StickerSet
// Preview stickers
Covers []DocumentClass
}
StickerSetMultiCovered represents TL type `stickerSetMultiCovered#3407e51b`. Stickerset, with a specific stickers as preview
See https://core.telegram.org/constructor/stickerSetMultiCovered for reference.
func (*StickerSetMultiCovered) Decode ¶
func (s *StickerSetMultiCovered) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickerSetMultiCovered) Encode ¶
func (s *StickerSetMultiCovered) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickerSetMultiCovered) String ¶ added in v0.12.0
func (s *StickerSetMultiCovered) String() string
String implements fmt.Stringer.
type StickerSetsHandler ¶ added in v0.9.0
type StickerSetsHandler func(ctx UpdateContext, update *UpdateStickerSets) error
StickerSetsHandler is a StickerSets event handler.
type StickerSetsOrderHandler ¶ added in v0.9.0
type StickerSetsOrderHandler func(ctx UpdateContext, update *UpdateStickerSetsOrder) error
StickerSetsOrderHandler is a StickerSetsOrder event handler.
type StickersAddStickerToSetRequest ¶
type StickersAddStickerToSetRequest struct {
// The stickerset
Stickerset InputStickerSetClass
// The sticker
Sticker InputStickerSetItem
}
StickersAddStickerToSetRequest represents TL type `stickers.addStickerToSet#8653febe`. Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot.
See https://core.telegram.org/method/stickers.addStickerToSet for reference.
func (*StickersAddStickerToSetRequest) Decode ¶
func (a *StickersAddStickerToSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickersAddStickerToSetRequest) Encode ¶
func (a *StickersAddStickerToSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickersAddStickerToSetRequest) String ¶ added in v0.12.0
func (a *StickersAddStickerToSetRequest) String() string
String implements fmt.Stringer.
type StickersChangeStickerPositionRequest ¶
type StickersChangeStickerPositionRequest struct {
// The sticker
Sticker InputDocumentClass
// The new position of the sticker, zero-based
Position int
}
StickersChangeStickerPositionRequest represents TL type `stickers.changeStickerPosition#ffb6d4ca`. Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot
See https://core.telegram.org/method/stickers.changeStickerPosition for reference.
func (*StickersChangeStickerPositionRequest) Decode ¶
func (c *StickersChangeStickerPositionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickersChangeStickerPositionRequest) Encode ¶
func (c *StickersChangeStickerPositionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickersChangeStickerPositionRequest) String ¶ added in v0.12.0
func (c *StickersChangeStickerPositionRequest) String() string
String implements fmt.Stringer.
type StickersCreateStickerSetRequest ¶
type StickersCreateStickerSetRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is a mask stickerset
Masks bool
// Whether this is an animated stickerset
Animated bool
// Stickerset owner
UserID InputUserClass
// Stickerset name, 1-64 chars
Title string
// Sticker set name. Can contain only English letters, digits and underscores. Must end with "by" ( is case insensitive); 1-64 characters
ShortName string
// Thumbnail
//
// Use SetThumb and GetThumb helpers.
Thumb InputDocumentClass
// Stickers
Stickers []InputStickerSetItem
}
StickersCreateStickerSetRequest represents TL type `stickers.createStickerSet#f1036780`. Create a stickerset, bots only.
See https://core.telegram.org/method/stickers.createStickerSet for reference.
func (*StickersCreateStickerSetRequest) Decode ¶
func (c *StickersCreateStickerSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickersCreateStickerSetRequest) Encode ¶
func (c *StickersCreateStickerSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickersCreateStickerSetRequest) GetThumb ¶
func (c *StickersCreateStickerSetRequest) GetThumb() (value InputDocumentClass, ok bool)
GetThumb returns value of Thumb conditional field and boolean which is true if field was set.
func (*StickersCreateStickerSetRequest) SetAnimated ¶
func (c *StickersCreateStickerSetRequest) SetAnimated(value bool)
SetAnimated sets value of Animated conditional field.
func (*StickersCreateStickerSetRequest) SetMasks ¶
func (c *StickersCreateStickerSetRequest) SetMasks(value bool)
SetMasks sets value of Masks conditional field.
func (*StickersCreateStickerSetRequest) SetThumb ¶
func (c *StickersCreateStickerSetRequest) SetThumb(value InputDocumentClass)
SetThumb sets value of Thumb conditional field.
func (*StickersCreateStickerSetRequest) String ¶ added in v0.12.0
func (c *StickersCreateStickerSetRequest) String() string
String implements fmt.Stringer.
type StickersRemoveStickerFromSetRequest ¶
type StickersRemoveStickerFromSetRequest struct {
// The sticker to remove
Sticker InputDocumentClass
}
StickersRemoveStickerFromSetRequest represents TL type `stickers.removeStickerFromSet#f7760f51`. Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot.
See https://core.telegram.org/method/stickers.removeStickerFromSet for reference.
func (*StickersRemoveStickerFromSetRequest) Decode ¶
func (r *StickersRemoveStickerFromSetRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickersRemoveStickerFromSetRequest) Encode ¶
func (r *StickersRemoveStickerFromSetRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickersRemoveStickerFromSetRequest) String ¶ added in v0.12.0
func (r *StickersRemoveStickerFromSetRequest) String() string
String implements fmt.Stringer.
type StickersSetStickerSetThumbRequest ¶
type StickersSetStickerSetThumbRequest struct {
// Stickerset
Stickerset InputStickerSetClass
// Thumbnail
Thumb InputDocumentClass
}
StickersSetStickerSetThumbRequest represents TL type `stickers.setStickerSetThumb#9a364e30`. Set stickerset thumbnail
See https://core.telegram.org/method/stickers.setStickerSetThumb for reference.
func (*StickersSetStickerSetThumbRequest) Decode ¶
func (s *StickersSetStickerSetThumbRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StickersSetStickerSetThumbRequest) Encode ¶
func (s *StickersSetStickerSetThumbRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StickersSetStickerSetThumbRequest) String ¶ added in v0.12.0
func (s *StickersSetStickerSetThumbRequest) String() string
String implements fmt.Stringer.
type StorageFileGif ¶
type StorageFileGif struct {
}
StorageFileGif represents TL type `storage.fileGif#cae1aadf`. GIF image. MIME type: image/gif.
See https://core.telegram.org/constructor/storage.fileGif for reference.
func (*StorageFileGif) Decode ¶
func (f *StorageFileGif) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileGif) Encode ¶
func (f *StorageFileGif) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileGif) String ¶ added in v0.12.0
func (f *StorageFileGif) String() string
String implements fmt.Stringer.
type StorageFileJpeg ¶
type StorageFileJpeg struct {
}
StorageFileJpeg represents TL type `storage.fileJpeg#7efe0e`. JPEG image. MIME type: image/jpeg.
See https://core.telegram.org/constructor/storage.fileJpeg for reference.
func (*StorageFileJpeg) Decode ¶
func (f *StorageFileJpeg) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileJpeg) Encode ¶
func (f *StorageFileJpeg) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileJpeg) String ¶ added in v0.12.0
func (f *StorageFileJpeg) String() string
String implements fmt.Stringer.
type StorageFileMov ¶
type StorageFileMov struct {
}
StorageFileMov represents TL type `storage.fileMov#4b09ebbc`. Quicktime video. MIME type: video/quicktime.
See https://core.telegram.org/constructor/storage.fileMov for reference.
func (*StorageFileMov) Decode ¶
func (f *StorageFileMov) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileMov) Encode ¶
func (f *StorageFileMov) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileMov) String ¶ added in v0.12.0
func (f *StorageFileMov) String() string
String implements fmt.Stringer.
type StorageFileMp3 ¶
type StorageFileMp3 struct {
}
StorageFileMp3 represents TL type `storage.fileMp3#528a0677`. Mp3 audio. MIME type: audio/mpeg.
See https://core.telegram.org/constructor/storage.fileMp3 for reference.
func (*StorageFileMp3) Decode ¶
func (f *StorageFileMp3) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileMp3) Encode ¶
func (f *StorageFileMp3) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileMp3) String ¶ added in v0.12.0
func (f *StorageFileMp3) String() string
String implements fmt.Stringer.
type StorageFileMp4 ¶
type StorageFileMp4 struct {
}
StorageFileMp4 represents TL type `storage.fileMp4#b3cea0e4`. MPEG-4 video. MIME type: video/mp4.
See https://core.telegram.org/constructor/storage.fileMp4 for reference.
func (*StorageFileMp4) Decode ¶
func (f *StorageFileMp4) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileMp4) Encode ¶
func (f *StorageFileMp4) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileMp4) String ¶ added in v0.12.0
func (f *StorageFileMp4) String() string
String implements fmt.Stringer.
type StorageFilePartial ¶
type StorageFilePartial struct {
}
StorageFilePartial represents TL type `storage.filePartial#40bc6f52`. Part of a bigger file.
See https://core.telegram.org/constructor/storage.filePartial for reference.
func (*StorageFilePartial) Decode ¶
func (f *StorageFilePartial) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFilePartial) Encode ¶
func (f *StorageFilePartial) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFilePartial) String ¶ added in v0.12.0
func (f *StorageFilePartial) String() string
String implements fmt.Stringer.
type StorageFilePdf ¶
type StorageFilePdf struct {
}
StorageFilePdf represents TL type `storage.filePdf#ae1e508d`. PDF document image. MIME type: application/pdf.
See https://core.telegram.org/constructor/storage.filePdf for reference.
func (*StorageFilePdf) Decode ¶
func (f *StorageFilePdf) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFilePdf) Encode ¶
func (f *StorageFilePdf) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFilePdf) String ¶ added in v0.12.0
func (f *StorageFilePdf) String() string
String implements fmt.Stringer.
type StorageFilePng ¶
type StorageFilePng struct {
}
StorageFilePng represents TL type `storage.filePng#a4f63c0`. PNG image. MIME type: image/png.
See https://core.telegram.org/constructor/storage.filePng for reference.
func (*StorageFilePng) Decode ¶
func (f *StorageFilePng) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFilePng) Encode ¶
func (f *StorageFilePng) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFilePng) String ¶ added in v0.12.0
func (f *StorageFilePng) String() string
String implements fmt.Stringer.
type StorageFileTypeBox ¶
type StorageFileTypeBox struct {
FileType StorageFileTypeClass
}
StorageFileType boxes the StorageFileTypeClass providing a helper.
type StorageFileTypeClass ¶
type StorageFileTypeClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
StorageFileTypeClass represents storage.FileType generic type.
See https://core.telegram.org/type/storage.FileType for reference.
Example:
g, err := DecodeStorageFileType(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *StorageFileUnknown: // storage.fileUnknown#aa963b05
case *StorageFilePartial: // storage.filePartial#40bc6f52
case *StorageFileJpeg: // storage.fileJpeg#7efe0e
case *StorageFileGif: // storage.fileGif#cae1aadf
case *StorageFilePng: // storage.filePng#a4f63c0
case *StorageFilePdf: // storage.filePdf#ae1e508d
case *StorageFileMp3: // storage.fileMp3#528a0677
case *StorageFileMov: // storage.fileMov#4b09ebbc
case *StorageFileMp4: // storage.fileMp4#b3cea0e4
case *StorageFileWebp: // storage.fileWebp#1081464c
default: panic(v)
}
func DecodeStorageFileType ¶
func DecodeStorageFileType(buf *bin.Buffer) (StorageFileTypeClass, error)
DecodeStorageFileType implements binary de-serialization for StorageFileTypeClass.
type StorageFileUnknown ¶
type StorageFileUnknown struct {
}
StorageFileUnknown represents TL type `storage.fileUnknown#aa963b05`. Unknown type.
See https://core.telegram.org/constructor/storage.fileUnknown for reference.
func (*StorageFileUnknown) Decode ¶
func (f *StorageFileUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileUnknown) Encode ¶
func (f *StorageFileUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileUnknown) String ¶ added in v0.12.0
func (f *StorageFileUnknown) String() string
String implements fmt.Stringer.
type StorageFileWebp ¶
type StorageFileWebp struct {
}
StorageFileWebp represents TL type `storage.fileWebp#1081464c`. WEBP image. MIME type: image/webp.
See https://core.telegram.org/constructor/storage.fileWebp for reference.
func (*StorageFileWebp) Decode ¶
func (f *StorageFileWebp) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*StorageFileWebp) Encode ¶
func (f *StorageFileWebp) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*StorageFileWebp) String ¶ added in v0.12.0
func (f *StorageFileWebp) String() string
String implements fmt.Stringer.
type TextAnchor ¶
type TextAnchor struct {
// Text
Text RichTextClass
// Section name
Name string
}
TextAnchor represents TL type `textAnchor#35553762`. Text linking to another section of the page
See https://core.telegram.org/constructor/textAnchor for reference.
func (*TextAnchor) Decode ¶
func (t *TextAnchor) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextAnchor) Encode ¶
func (t *TextAnchor) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextAnchor) String ¶ added in v0.12.0
func (t *TextAnchor) String() string
String implements fmt.Stringer.
type TextBold ¶
type TextBold struct {
// Text
Text RichTextClass
}
TextBold represents TL type `textBold#6724abc4`. Bold text
See https://core.telegram.org/constructor/textBold for reference.
type TextConcat ¶
type TextConcat struct {
// Concatenated rich texts
Texts []RichTextClass
}
TextConcat represents TL type `textConcat#7e6260d7`. Concatenation of rich texts
See https://core.telegram.org/constructor/textConcat for reference.
func (*TextConcat) Decode ¶
func (t *TextConcat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextConcat) Encode ¶
func (t *TextConcat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextConcat) String ¶ added in v0.12.0
func (t *TextConcat) String() string
String implements fmt.Stringer.
type TextEmail ¶
type TextEmail struct {
// Link text
Text RichTextClass
// Email address
Email string
}
TextEmail represents TL type `textEmail#de5a0dd6`. Rich text email link
See https://core.telegram.org/constructor/textEmail for reference.
type TextEmpty ¶
type TextEmpty struct {
}
TextEmpty represents TL type `textEmpty#dc3d824f`. Empty rich text element
See https://core.telegram.org/constructor/textEmpty for reference.
type TextFixed ¶
type TextFixed struct {
// Text
Text RichTextClass
}
TextFixed represents TL type `textFixed#6c3f19b9`. fixed-width rich text
See https://core.telegram.org/constructor/textFixed for reference.
type TextImage ¶
TextImage represents TL type `textImage#81ccf4f`. Inline image
See https://core.telegram.org/constructor/textImage for reference.
type TextItalic ¶
type TextItalic struct {
// Text
Text RichTextClass
}
TextItalic represents TL type `textItalic#d912a59c`. Italic text
See https://core.telegram.org/constructor/textItalic for reference.
func (*TextItalic) Decode ¶
func (t *TextItalic) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextItalic) Encode ¶
func (t *TextItalic) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextItalic) String ¶ added in v0.12.0
func (t *TextItalic) String() string
String implements fmt.Stringer.
type TextMarked ¶
type TextMarked struct {
// Text
Text RichTextClass
}
TextMarked represents TL type `textMarked#34b8621`. Highlighted text
See https://core.telegram.org/constructor/textMarked for reference.
func (*TextMarked) Decode ¶
func (t *TextMarked) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextMarked) Encode ¶
func (t *TextMarked) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextMarked) String ¶ added in v0.12.0
func (t *TextMarked) String() string
String implements fmt.Stringer.
type TextPhone ¶
type TextPhone struct {
// Text
Text RichTextClass
// Phone number
Phone string
}
TextPhone represents TL type `textPhone#1ccb966a`. Rich text linked to a phone number
See https://core.telegram.org/constructor/textPhone for reference.
type TextPlain ¶
type TextPlain struct {
// Text
Text string
}
TextPlain represents TL type `textPlain#744694e0`. Plain text
See https://core.telegram.org/constructor/textPlain for reference.
type TextStrike ¶
type TextStrike struct {
// Text
Text RichTextClass
}
TextStrike represents TL type `textStrike#9bf8bb95`. Strikethrough text
See https://core.telegram.org/constructor/textStrike for reference.
func (*TextStrike) Decode ¶
func (t *TextStrike) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextStrike) Encode ¶
func (t *TextStrike) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextStrike) String ¶ added in v0.12.0
func (t *TextStrike) String() string
String implements fmt.Stringer.
type TextSubscript ¶
type TextSubscript struct {
// Text
Text RichTextClass
}
TextSubscript represents TL type `textSubscript#ed6a8504`. Subscript text
See https://core.telegram.org/constructor/textSubscript for reference.
func (*TextSubscript) Decode ¶
func (t *TextSubscript) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextSubscript) Encode ¶
func (t *TextSubscript) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextSubscript) String ¶ added in v0.12.0
func (t *TextSubscript) String() string
String implements fmt.Stringer.
type TextSuperscript ¶
type TextSuperscript struct {
// Text
Text RichTextClass
}
TextSuperscript represents TL type `textSuperscript#c7fb5e01`. Superscript text
See https://core.telegram.org/constructor/textSuperscript for reference.
func (*TextSuperscript) Decode ¶
func (t *TextSuperscript) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextSuperscript) Encode ¶
func (t *TextSuperscript) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextSuperscript) String ¶ added in v0.12.0
func (t *TextSuperscript) String() string
String implements fmt.Stringer.
type TextUnderline ¶
type TextUnderline struct {
// Text
Text RichTextClass
}
TextUnderline represents TL type `textUnderline#c12622c4`. Underlined text
See https://core.telegram.org/constructor/textUnderline for reference.
func (*TextUnderline) Decode ¶
func (t *TextUnderline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TextUnderline) Encode ¶
func (t *TextUnderline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TextUnderline) String ¶ added in v0.12.0
func (t *TextUnderline) String() string
String implements fmt.Stringer.
type TextUrl ¶
type TextUrl struct {
// Text of link
Text RichTextClass
// Webpage HTTP URL
URL string
// If a preview was already generated for the page, the page ID
WebpageID int64
}
TextUrl represents TL type `textUrl#3c2884c1`. Link
See https://core.telegram.org/constructor/textUrl for reference.
type Theme ¶
type Theme struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the current user is the creator of this theme
Creator bool
// Whether this is the default theme
Default bool
// Theme ID
ID int64
// Theme access hash
AccessHash int64
// Unique theme ID
Slug string
// Theme name
Title string
// Theme
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
// Theme settings
//
// Use SetSettings and GetSettings helpers.
Settings ThemeSettings
// Installation count
InstallsCount int
}
Theme represents TL type `theme#28f1114`. Theme
See https://core.telegram.org/constructor/theme for reference.
func (*Theme) GetDocument ¶
func (t *Theme) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*Theme) GetSettings ¶
func (t *Theme) GetSettings() (value ThemeSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*Theme) SetCreator ¶
SetCreator sets value of Creator conditional field.
func (*Theme) SetDefault ¶
SetDefault sets value of Default conditional field.
func (*Theme) SetDocument ¶
func (t *Theme) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
func (*Theme) SetSettings ¶
func (t *Theme) SetSettings(value ThemeSettings)
SetSettings sets value of Settings conditional field.
type ThemeHandler ¶ added in v0.9.0
type ThemeHandler func(ctx UpdateContext, update *UpdateTheme) error
ThemeHandler is a Theme event handler.
type ThemeSettings ¶
type ThemeSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Base theme
BaseTheme BaseThemeClass
// Accent color, RGB24 format
AccentColor int
// Message gradient color (top), RGB24 format
//
// Use SetMessageTopColor and GetMessageTopColor helpers.
MessageTopColor int
// Message gradient color (bottom), RGB24 format
//
// Use SetMessageBottomColor and GetMessageBottomColor helpers.
MessageBottomColor int
// Wallpaper
//
// Use SetWallpaper and GetWallpaper helpers.
Wallpaper WallPaperClass
}
ThemeSettings represents TL type `themeSettings#9c14984a`. Theme settings
See https://core.telegram.org/constructor/themeSettings for reference.
func (*ThemeSettings) Decode ¶
func (t *ThemeSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ThemeSettings) Encode ¶
func (t *ThemeSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ThemeSettings) GetMessageBottomColor ¶
func (t *ThemeSettings) GetMessageBottomColor() (value int, ok bool)
GetMessageBottomColor returns value of MessageBottomColor conditional field and boolean which is true if field was set.
func (*ThemeSettings) GetMessageTopColor ¶
func (t *ThemeSettings) GetMessageTopColor() (value int, ok bool)
GetMessageTopColor returns value of MessageTopColor conditional field and boolean which is true if field was set.
func (*ThemeSettings) GetWallpaper ¶
func (t *ThemeSettings) GetWallpaper() (value WallPaperClass, ok bool)
GetWallpaper returns value of Wallpaper conditional field and boolean which is true if field was set.
func (*ThemeSettings) SetMessageBottomColor ¶
func (t *ThemeSettings) SetMessageBottomColor(value int)
SetMessageBottomColor sets value of MessageBottomColor conditional field.
func (*ThemeSettings) SetMessageTopColor ¶
func (t *ThemeSettings) SetMessageTopColor(value int)
SetMessageTopColor sets value of MessageTopColor conditional field.
func (*ThemeSettings) SetWallpaper ¶
func (t *ThemeSettings) SetWallpaper(value WallPaperClass)
SetWallpaper sets value of Wallpaper conditional field.
func (*ThemeSettings) String ¶ added in v0.12.0
func (t *ThemeSettings) String() string
String implements fmt.Stringer.
type TopPeer ¶
type TopPeer struct {
// Peer
Peer PeerClass
// Rating as computed in top peer rating »¹
//
// Links:
// 1) https://core.telegram.org/api/top-rating
Rating float64
}
TopPeer represents TL type `topPeer#edcdc05b`. Top peer
See https://core.telegram.org/constructor/topPeer for reference.
type TopPeerCategoryBotsInline ¶
type TopPeerCategoryBotsInline struct {
}
TopPeerCategoryBotsInline represents TL type `topPeerCategoryBotsInline#148677e2`. Most used inline bots
See https://core.telegram.org/constructor/topPeerCategoryBotsInline for reference.
func (*TopPeerCategoryBotsInline) Decode ¶
func (t *TopPeerCategoryBotsInline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryBotsInline) Encode ¶
func (t *TopPeerCategoryBotsInline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryBotsInline) String ¶ added in v0.12.0
func (t *TopPeerCategoryBotsInline) String() string
String implements fmt.Stringer.
type TopPeerCategoryBotsPM ¶
type TopPeerCategoryBotsPM struct {
}
TopPeerCategoryBotsPM represents TL type `topPeerCategoryBotsPM#ab661b5b`. Most used bots
See https://core.telegram.org/constructor/topPeerCategoryBotsPM for reference.
func (*TopPeerCategoryBotsPM) Decode ¶
func (t *TopPeerCategoryBotsPM) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryBotsPM) Encode ¶
func (t *TopPeerCategoryBotsPM) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryBotsPM) String ¶ added in v0.12.0
func (t *TopPeerCategoryBotsPM) String() string
String implements fmt.Stringer.
type TopPeerCategoryBox ¶
type TopPeerCategoryBox struct {
TopPeerCategory TopPeerCategoryClass
}
TopPeerCategory boxes the TopPeerCategoryClass providing a helper.
type TopPeerCategoryChannels ¶
type TopPeerCategoryChannels struct {
}
TopPeerCategoryChannels represents TL type `topPeerCategoryChannels#161d9628`. Most frequently visited channels
See https://core.telegram.org/constructor/topPeerCategoryChannels for reference.
func (*TopPeerCategoryChannels) Decode ¶
func (t *TopPeerCategoryChannels) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryChannels) Encode ¶
func (t *TopPeerCategoryChannels) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryChannels) String ¶ added in v0.12.0
func (t *TopPeerCategoryChannels) String() string
String implements fmt.Stringer.
type TopPeerCategoryClass ¶
type TopPeerCategoryClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
TopPeerCategoryClass represents TopPeerCategory generic type.
See https://core.telegram.org/type/TopPeerCategory for reference.
Example:
g, err := DecodeTopPeerCategory(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *TopPeerCategoryBotsPM: // topPeerCategoryBotsPM#ab661b5b
case *TopPeerCategoryBotsInline: // topPeerCategoryBotsInline#148677e2
case *TopPeerCategoryCorrespondents: // topPeerCategoryCorrespondents#637b7ed
case *TopPeerCategoryGroups: // topPeerCategoryGroups#bd17a14a
case *TopPeerCategoryChannels: // topPeerCategoryChannels#161d9628
case *TopPeerCategoryPhoneCalls: // topPeerCategoryPhoneCalls#1e76a78c
case *TopPeerCategoryForwardUsers: // topPeerCategoryForwardUsers#a8406ca9
case *TopPeerCategoryForwardChats: // topPeerCategoryForwardChats#fbeec0f0
default: panic(v)
}
func DecodeTopPeerCategory ¶
func DecodeTopPeerCategory(buf *bin.Buffer) (TopPeerCategoryClass, error)
DecodeTopPeerCategory implements binary de-serialization for TopPeerCategoryClass.
type TopPeerCategoryCorrespondents ¶
type TopPeerCategoryCorrespondents struct {
}
TopPeerCategoryCorrespondents represents TL type `topPeerCategoryCorrespondents#637b7ed`. Users we've chatted most frequently with
See https://core.telegram.org/constructor/topPeerCategoryCorrespondents for reference.
func (*TopPeerCategoryCorrespondents) Decode ¶
func (t *TopPeerCategoryCorrespondents) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryCorrespondents) Encode ¶
func (t *TopPeerCategoryCorrespondents) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryCorrespondents) String ¶ added in v0.12.0
func (t *TopPeerCategoryCorrespondents) String() string
String implements fmt.Stringer.
type TopPeerCategoryForwardChats ¶
type TopPeerCategoryForwardChats struct {
}
TopPeerCategoryForwardChats represents TL type `topPeerCategoryForwardChats#fbeec0f0`. Chats to which the users often forwards messages to
See https://core.telegram.org/constructor/topPeerCategoryForwardChats for reference.
func (*TopPeerCategoryForwardChats) Decode ¶
func (t *TopPeerCategoryForwardChats) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryForwardChats) Encode ¶
func (t *TopPeerCategoryForwardChats) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryForwardChats) String ¶ added in v0.12.0
func (t *TopPeerCategoryForwardChats) String() string
String implements fmt.Stringer.
type TopPeerCategoryForwardUsers ¶
type TopPeerCategoryForwardUsers struct {
}
TopPeerCategoryForwardUsers represents TL type `topPeerCategoryForwardUsers#a8406ca9`. Users to which the users often forwards messages to
See https://core.telegram.org/constructor/topPeerCategoryForwardUsers for reference.
func (*TopPeerCategoryForwardUsers) Decode ¶
func (t *TopPeerCategoryForwardUsers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryForwardUsers) Encode ¶
func (t *TopPeerCategoryForwardUsers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryForwardUsers) String ¶ added in v0.12.0
func (t *TopPeerCategoryForwardUsers) String() string
String implements fmt.Stringer.
type TopPeerCategoryGroups ¶
type TopPeerCategoryGroups struct {
}
TopPeerCategoryGroups represents TL type `topPeerCategoryGroups#bd17a14a`. Often-opened groups and supergroups
See https://core.telegram.org/constructor/topPeerCategoryGroups for reference.
func (*TopPeerCategoryGroups) Decode ¶
func (t *TopPeerCategoryGroups) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryGroups) Encode ¶
func (t *TopPeerCategoryGroups) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryGroups) String ¶ added in v0.12.0
func (t *TopPeerCategoryGroups) String() string
String implements fmt.Stringer.
type TopPeerCategoryPeers ¶
type TopPeerCategoryPeers struct {
// Top peer category of peers
Category TopPeerCategoryClass
// Count of peers
Count int
// Peers
Peers []TopPeer
}
TopPeerCategoryPeers represents TL type `topPeerCategoryPeers#fb834291`. Top peer category
See https://core.telegram.org/constructor/topPeerCategoryPeers for reference.
func (*TopPeerCategoryPeers) Decode ¶
func (t *TopPeerCategoryPeers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryPeers) Encode ¶
func (t *TopPeerCategoryPeers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryPeers) String ¶ added in v0.12.0
func (t *TopPeerCategoryPeers) String() string
String implements fmt.Stringer.
type TopPeerCategoryPhoneCalls ¶
type TopPeerCategoryPhoneCalls struct {
}
TopPeerCategoryPhoneCalls represents TL type `topPeerCategoryPhoneCalls#1e76a78c`. Most frequently called users
See https://core.telegram.org/constructor/topPeerCategoryPhoneCalls for reference.
func (*TopPeerCategoryPhoneCalls) Decode ¶
func (t *TopPeerCategoryPhoneCalls) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*TopPeerCategoryPhoneCalls) Encode ¶
func (t *TopPeerCategoryPhoneCalls) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*TopPeerCategoryPhoneCalls) String ¶ added in v0.12.0
func (t *TopPeerCategoryPhoneCalls) String() string
String implements fmt.Stringer.
type True ¶
type True struct {
}
True represents TL type `true#3fedd339`. See predefined identifiers¹.
Links:
See https://core.telegram.org/constructor/true for reference.
type UpdateBotCallbackQuery ¶
type UpdateBotCallbackQuery struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Query ID
QueryID int64
// ID of the user that pressed the button
UserID int
// Chat where the inline keyboard was sent
Peer PeerClass
// Message ID
MsgID int
// Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games.
ChatInstance int64
// Callback data
//
// Use SetData and GetData helpers.
Data []byte
// Short name of a Game to be returned, serves as the unique identifier for the game
//
// Use SetGameShortName and GetGameShortName helpers.
GameShortName string
}
UpdateBotCallbackQuery represents TL type `updateBotCallbackQuery#e73547e1`. A callback button was pressed, and the button data was sent to the bot that created the button
See https://core.telegram.org/constructor/updateBotCallbackQuery for reference.
func (*UpdateBotCallbackQuery) Decode ¶
func (u *UpdateBotCallbackQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotCallbackQuery) Encode ¶
func (u *UpdateBotCallbackQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotCallbackQuery) GetData ¶
func (u *UpdateBotCallbackQuery) GetData() (value []byte, ok bool)
GetData returns value of Data conditional field and boolean which is true if field was set.
func (*UpdateBotCallbackQuery) GetGameShortName ¶
func (u *UpdateBotCallbackQuery) GetGameShortName() (value string, ok bool)
GetGameShortName returns value of GameShortName conditional field and boolean which is true if field was set.
func (*UpdateBotCallbackQuery) SetData ¶
func (u *UpdateBotCallbackQuery) SetData(value []byte)
SetData sets value of Data conditional field.
func (*UpdateBotCallbackQuery) SetGameShortName ¶
func (u *UpdateBotCallbackQuery) SetGameShortName(value string)
SetGameShortName sets value of GameShortName conditional field.
func (*UpdateBotCallbackQuery) String ¶ added in v0.12.0
func (u *UpdateBotCallbackQuery) String() string
String implements fmt.Stringer.
type UpdateBotInlineQuery ¶
type UpdateBotInlineQuery struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Query ID
QueryID int64
// User that sent the query
UserID int
// Text of query
Query string
// Attached geolocation
//
// Use SetGeo and GetGeo helpers.
Geo GeoPointClass
// PeerType field of UpdateBotInlineQuery.
//
// Use SetPeerType and GetPeerType helpers.
PeerType InlineQueryPeerTypeClass
// Offset to navigate through results
Offset string
}
UpdateBotInlineQuery represents TL type `updateBotInlineQuery#3f2038db`. An incoming inline query
See https://core.telegram.org/constructor/updateBotInlineQuery for reference.
func (*UpdateBotInlineQuery) Decode ¶
func (u *UpdateBotInlineQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotInlineQuery) Encode ¶
func (u *UpdateBotInlineQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotInlineQuery) GetGeo ¶
func (u *UpdateBotInlineQuery) GetGeo() (value GeoPointClass, ok bool)
GetGeo returns value of Geo conditional field and boolean which is true if field was set.
func (*UpdateBotInlineQuery) GetPeerType ¶ added in v0.13.0
func (u *UpdateBotInlineQuery) GetPeerType() (value InlineQueryPeerTypeClass, ok bool)
GetPeerType returns value of PeerType conditional field and boolean which is true if field was set.
func (*UpdateBotInlineQuery) SetGeo ¶
func (u *UpdateBotInlineQuery) SetGeo(value GeoPointClass)
SetGeo sets value of Geo conditional field.
func (*UpdateBotInlineQuery) SetPeerType ¶ added in v0.13.0
func (u *UpdateBotInlineQuery) SetPeerType(value InlineQueryPeerTypeClass)
SetPeerType sets value of PeerType conditional field.
func (*UpdateBotInlineQuery) String ¶ added in v0.12.0
func (u *UpdateBotInlineQuery) String() string
String implements fmt.Stringer.
type UpdateBotInlineSend ¶
type UpdateBotInlineSend struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The user that chose the result
UserID int
// The query that was used to obtain the result
Query string
// Optional. Sender location, only for bots that require user location
//
// Use SetGeo and GetGeo helpers.
Geo GeoPointClass
// The unique identifier for the result that was chosen
ID string
// Identifier of the sent inline message. Available only if there is an inline keyboard attached to the message. Will be also received in callback queries and can be used to edit the message.
//
// Use SetMsgID and GetMsgID helpers.
MsgID InputBotInlineMessageID
}
UpdateBotInlineSend represents TL type `updateBotInlineSend#e48f964`. The result of an inline query that was chosen by a user and sent to their chat partner. Please see our documentation on the feedback collecting¹ for details on how to enable these updates for your bot.
Links:
See https://core.telegram.org/constructor/updateBotInlineSend for reference.
func (*UpdateBotInlineSend) Decode ¶
func (u *UpdateBotInlineSend) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotInlineSend) Encode ¶
func (u *UpdateBotInlineSend) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotInlineSend) GetGeo ¶
func (u *UpdateBotInlineSend) GetGeo() (value GeoPointClass, ok bool)
GetGeo returns value of Geo conditional field and boolean which is true if field was set.
func (*UpdateBotInlineSend) GetMsgID ¶
func (u *UpdateBotInlineSend) GetMsgID() (value InputBotInlineMessageID, ok bool)
GetMsgID returns value of MsgID conditional field and boolean which is true if field was set.
func (*UpdateBotInlineSend) SetGeo ¶
func (u *UpdateBotInlineSend) SetGeo(value GeoPointClass)
SetGeo sets value of Geo conditional field.
func (*UpdateBotInlineSend) SetMsgID ¶
func (u *UpdateBotInlineSend) SetMsgID(value InputBotInlineMessageID)
SetMsgID sets value of MsgID conditional field.
func (*UpdateBotInlineSend) String ¶ added in v0.12.0
func (u *UpdateBotInlineSend) String() string
String implements fmt.Stringer.
type UpdateBotPrecheckoutQuery ¶
type UpdateBotPrecheckoutQuery struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Unique query identifier
QueryID int64
// User who sent the query
UserID int
// Bot specified invoice payload
Payload []byte
// Order info provided by the user
//
// Use SetInfo and GetInfo helpers.
Info PaymentRequestedInfo
// Identifier of the shipping option chosen by the user
//
// Use SetShippingOptionID and GetShippingOptionID helpers.
ShippingOptionID string
// Three-letter ISO 4217 currency¹ code
//
// Links:
// 1) https://core.telegram.org/bots/payments#supported-currencies
Currency string
// Total amount in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json¹, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
//
// Links:
// 1) https://core.telegram.org/bots/payments/currencies.json
TotalAmount int64
}
UpdateBotPrecheckoutQuery represents TL type `updateBotPrecheckoutQuery#5d2f3aa9`. This object contains information about an incoming pre-checkout query.
See https://core.telegram.org/constructor/updateBotPrecheckoutQuery for reference.
func (*UpdateBotPrecheckoutQuery) Decode ¶
func (u *UpdateBotPrecheckoutQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotPrecheckoutQuery) Encode ¶
func (u *UpdateBotPrecheckoutQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotPrecheckoutQuery) GetInfo ¶
func (u *UpdateBotPrecheckoutQuery) GetInfo() (value PaymentRequestedInfo, ok bool)
GetInfo returns value of Info conditional field and boolean which is true if field was set.
func (*UpdateBotPrecheckoutQuery) GetShippingOptionID ¶
func (u *UpdateBotPrecheckoutQuery) GetShippingOptionID() (value string, ok bool)
GetShippingOptionID returns value of ShippingOptionID conditional field and boolean which is true if field was set.
func (*UpdateBotPrecheckoutQuery) SetInfo ¶
func (u *UpdateBotPrecheckoutQuery) SetInfo(value PaymentRequestedInfo)
SetInfo sets value of Info conditional field.
func (*UpdateBotPrecheckoutQuery) SetShippingOptionID ¶
func (u *UpdateBotPrecheckoutQuery) SetShippingOptionID(value string)
SetShippingOptionID sets value of ShippingOptionID conditional field.
func (*UpdateBotPrecheckoutQuery) String ¶ added in v0.12.0
func (u *UpdateBotPrecheckoutQuery) String() string
String implements fmt.Stringer.
type UpdateBotShippingQuery ¶
type UpdateBotShippingQuery struct {
// Unique query identifier
QueryID int64
// User who sent the query
UserID int
// Bot specified invoice payload
Payload []byte
// User specified shipping address
ShippingAddress PostAddress
}
UpdateBotShippingQuery represents TL type `updateBotShippingQuery#e0cdc940`. This object contains information about an incoming shipping query.
See https://core.telegram.org/constructor/updateBotShippingQuery for reference.
func (*UpdateBotShippingQuery) Decode ¶
func (u *UpdateBotShippingQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotShippingQuery) Encode ¶
func (u *UpdateBotShippingQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotShippingQuery) String ¶ added in v0.12.0
func (u *UpdateBotShippingQuery) String() string
String implements fmt.Stringer.
type UpdateBotWebhookJSON ¶
type UpdateBotWebhookJSON struct {
// The event
Data DataJSON
}
UpdateBotWebhookJSON represents TL type `updateBotWebhookJSON#8317c0c3`. A new incoming event; for bots only
See https://core.telegram.org/constructor/updateBotWebhookJSON for reference.
func (*UpdateBotWebhookJSON) Decode ¶
func (u *UpdateBotWebhookJSON) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotWebhookJSON) Encode ¶
func (u *UpdateBotWebhookJSON) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotWebhookJSON) String ¶ added in v0.12.0
func (u *UpdateBotWebhookJSON) String() string
String implements fmt.Stringer.
type UpdateBotWebhookJSONQuery ¶
type UpdateBotWebhookJSONQuery struct {
// Query identifier
QueryID int64
// Query data
Data DataJSON
// Query timeout
Timeout int
}
UpdateBotWebhookJSONQuery represents TL type `updateBotWebhookJSONQuery#9b9240a6`. A new incoming query; for bots only
See https://core.telegram.org/constructor/updateBotWebhookJSONQuery for reference.
func (*UpdateBotWebhookJSONQuery) Decode ¶
func (u *UpdateBotWebhookJSONQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateBotWebhookJSONQuery) Encode ¶
func (u *UpdateBotWebhookJSONQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateBotWebhookJSONQuery) String ¶ added in v0.12.0
func (u *UpdateBotWebhookJSONQuery) String() string
String implements fmt.Stringer.
type UpdateBox ¶
type UpdateBox struct {
Update UpdateClass
}
Update boxes the UpdateClass providing a helper.
type UpdateChannel ¶
type UpdateChannel struct {
// Channel ID
ChannelID int
}
UpdateChannel represents TL type `updateChannel#b6d45656`. A new channel is available
See https://core.telegram.org/constructor/updateChannel for reference.
func (*UpdateChannel) Decode ¶
func (u *UpdateChannel) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannel) Encode ¶
func (u *UpdateChannel) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannel) String ¶ added in v0.12.0
func (u *UpdateChannel) String() string
String implements fmt.Stringer.
type UpdateChannelAvailableMessages ¶
type UpdateChannelAvailableMessages struct {
// Channel/supergroup ID
ChannelID int
// Identifier of a maximum unavailable message in a channel due to hidden history.
AvailableMinID int
}
UpdateChannelAvailableMessages represents TL type `updateChannelAvailableMessages#70db6837`. The history of a channel/supergroup¹ was hidden.
Links:
See https://core.telegram.org/constructor/updateChannelAvailableMessages for reference.
func (*UpdateChannelAvailableMessages) Decode ¶
func (u *UpdateChannelAvailableMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelAvailableMessages) Encode ¶
func (u *UpdateChannelAvailableMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelAvailableMessages) String ¶ added in v0.12.0
func (u *UpdateChannelAvailableMessages) String() string
String implements fmt.Stringer.
type UpdateChannelMessageForwards ¶
type UpdateChannelMessageForwards struct {
// Channel ID
ChannelID int
// ID of the message
ID int
// New forward counter
Forwards int
}
UpdateChannelMessageForwards represents TL type `updateChannelMessageForwards#6e8a84df`. The forward counter of a message in a channel has changed
See https://core.telegram.org/constructor/updateChannelMessageForwards for reference.
func (*UpdateChannelMessageForwards) Decode ¶
func (u *UpdateChannelMessageForwards) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelMessageForwards) Encode ¶
func (u *UpdateChannelMessageForwards) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelMessageForwards) String ¶ added in v0.12.0
func (u *UpdateChannelMessageForwards) String() string
String implements fmt.Stringer.
type UpdateChannelMessageViews ¶
type UpdateChannelMessageViews struct {
// Channel ID
ChannelID int
// ID of the message
ID int
// New view counter
Views int
}
UpdateChannelMessageViews represents TL type `updateChannelMessageViews#98a12b4b`. The view counter of a message in a channel has changed
See https://core.telegram.org/constructor/updateChannelMessageViews for reference.
func (*UpdateChannelMessageViews) Decode ¶
func (u *UpdateChannelMessageViews) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelMessageViews) Encode ¶
func (u *UpdateChannelMessageViews) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelMessageViews) String ¶ added in v0.12.0
func (u *UpdateChannelMessageViews) String() string
String implements fmt.Stringer.
type UpdateChannelParticipant ¶
type UpdateChannelParticipant struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Channel ID
ChannelID int
// Date of the event
Date int
// User in question
UserID int
// Previous participant status
//
// Use SetPrevParticipant and GetPrevParticipant helpers.
PrevParticipant ChannelParticipantClass
// New participant status
//
// Use SetNewParticipant and GetNewParticipant helpers.
NewParticipant ChannelParticipantClass
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Qts int
}
UpdateChannelParticipant represents TL type `updateChannelParticipant#65d2b464`. A participant has left, joined, was banned or admined in a channel or supergroup¹.
Links:
See https://core.telegram.org/constructor/updateChannelParticipant for reference.
func (*UpdateChannelParticipant) Decode ¶
func (u *UpdateChannelParticipant) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelParticipant) Encode ¶
func (u *UpdateChannelParticipant) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelParticipant) GetNewParticipant ¶
func (u *UpdateChannelParticipant) GetNewParticipant() (value ChannelParticipantClass, ok bool)
GetNewParticipant returns value of NewParticipant conditional field and boolean which is true if field was set.
func (*UpdateChannelParticipant) GetPrevParticipant ¶
func (u *UpdateChannelParticipant) GetPrevParticipant() (value ChannelParticipantClass, ok bool)
GetPrevParticipant returns value of PrevParticipant conditional field and boolean which is true if field was set.
func (*UpdateChannelParticipant) SetNewParticipant ¶
func (u *UpdateChannelParticipant) SetNewParticipant(value ChannelParticipantClass)
SetNewParticipant sets value of NewParticipant conditional field.
func (*UpdateChannelParticipant) SetPrevParticipant ¶
func (u *UpdateChannelParticipant) SetPrevParticipant(value ChannelParticipantClass)
SetPrevParticipant sets value of PrevParticipant conditional field.
func (*UpdateChannelParticipant) String ¶ added in v0.12.0
func (u *UpdateChannelParticipant) String() string
String implements fmt.Stringer.
type UpdateChannelReadMessagesContents ¶
type UpdateChannelReadMessagesContents struct {
// Channel/supergroup¹ ID
//
// Links:
// 1) https://core.telegram.org/api/channel
ChannelID int
// IDs of messages that were read
Messages []int
}
UpdateChannelReadMessagesContents represents TL type `updateChannelReadMessagesContents#89893b45`. The specified channel/supergroup¹ messages were read
Links:
See https://core.telegram.org/constructor/updateChannelReadMessagesContents for reference.
func (*UpdateChannelReadMessagesContents) Decode ¶
func (u *UpdateChannelReadMessagesContents) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelReadMessagesContents) Encode ¶
func (u *UpdateChannelReadMessagesContents) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelReadMessagesContents) String ¶ added in v0.12.0
func (u *UpdateChannelReadMessagesContents) String() string
String implements fmt.Stringer.
type UpdateChannelTooLong ¶
type UpdateChannelTooLong struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// The channel
ChannelID int
// The PTS¹.
//
// Links:
// 1) https://core.telegram.org/api/updates
//
// Use SetPts and GetPts helpers.
Pts int
}
UpdateChannelTooLong represents TL type `updateChannelTooLong#eb0467fb`. There are new updates in the specified channel, the client must fetch them. If the difference is too long or if the channel isn't currently in the states, start fetching from the specified pts.
See https://core.telegram.org/constructor/updateChannelTooLong for reference.
func (*UpdateChannelTooLong) Decode ¶
func (u *UpdateChannelTooLong) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelTooLong) Encode ¶
func (u *UpdateChannelTooLong) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelTooLong) GetPts ¶
func (u *UpdateChannelTooLong) GetPts() (value int, ok bool)
GetPts returns value of Pts conditional field and boolean which is true if field was set.
func (*UpdateChannelTooLong) SetPts ¶
func (u *UpdateChannelTooLong) SetPts(value int)
SetPts sets value of Pts conditional field.
func (*UpdateChannelTooLong) String ¶ added in v0.12.0
func (u *UpdateChannelTooLong) String() string
String implements fmt.Stringer.
type UpdateChannelUserTyping ¶
type UpdateChannelUserTyping struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Channel ID
ChannelID int
// Thread ID¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetTopMsgID and GetTopMsgID helpers.
TopMsgID int
// User ID
UserID int
// Whether the user is typing, sending a media or doing something else
Action SendMessageActionClass
}
UpdateChannelUserTyping represents TL type `updateChannelUserTyping#ff2abe9f`. A user is typing in a supergroup, channel¹ or message thread²
Links:
See https://core.telegram.org/constructor/updateChannelUserTyping for reference.
func (*UpdateChannelUserTyping) Decode ¶
func (u *UpdateChannelUserTyping) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelUserTyping) Encode ¶
func (u *UpdateChannelUserTyping) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelUserTyping) GetTopMsgID ¶
func (u *UpdateChannelUserTyping) GetTopMsgID() (value int, ok bool)
GetTopMsgID returns value of TopMsgID conditional field and boolean which is true if field was set.
func (*UpdateChannelUserTyping) SetTopMsgID ¶
func (u *UpdateChannelUserTyping) SetTopMsgID(value int)
SetTopMsgID sets value of TopMsgID conditional field.
func (*UpdateChannelUserTyping) String ¶ added in v0.12.0
func (u *UpdateChannelUserTyping) String() string
String implements fmt.Stringer.
type UpdateChannelWebPage ¶
type UpdateChannelWebPage struct {
// Channel/supergroup¹ ID
//
// Links:
// 1) https://core.telegram.org/api/channel
ChannelID int
// Generated webpage preview
Webpage WebPageClass
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateChannelWebPage represents TL type `updateChannelWebPage#40771900`. A webpage preview of a link in a channel/supergroup¹ message was generated
Links:
See https://core.telegram.org/constructor/updateChannelWebPage for reference.
func (*UpdateChannelWebPage) Decode ¶
func (u *UpdateChannelWebPage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChannelWebPage) Encode ¶
func (u *UpdateChannelWebPage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChannelWebPage) String ¶ added in v0.12.0
func (u *UpdateChannelWebPage) String() string
String implements fmt.Stringer.
type UpdateChat ¶ added in v0.13.0
type UpdateChat struct {
// ChatID field of UpdateChat.
ChatID int
}
UpdateChat represents TL type `updateChat#1330a196`.
See https://core.telegram.org/constructor/updateChat for reference.
func (*UpdateChat) Decode ¶ added in v0.13.0
func (u *UpdateChat) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChat) Encode ¶ added in v0.13.0
func (u *UpdateChat) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChat) String ¶ added in v0.13.0
func (u *UpdateChat) String() string
String implements fmt.Stringer.
type UpdateChatDefaultBannedRights ¶
type UpdateChatDefaultBannedRights struct {
// The chat
Peer PeerClass
// New default banned rights
DefaultBannedRights ChatBannedRights
// Version
Version int
}
UpdateChatDefaultBannedRights represents TL type `updateChatDefaultBannedRights#54c01850`. Default banned rights in a normal chat¹ were updated
Links:
See https://core.telegram.org/constructor/updateChatDefaultBannedRights for reference.
func (*UpdateChatDefaultBannedRights) Decode ¶
func (u *UpdateChatDefaultBannedRights) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatDefaultBannedRights) Encode ¶
func (u *UpdateChatDefaultBannedRights) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatDefaultBannedRights) String ¶ added in v0.12.0
func (u *UpdateChatDefaultBannedRights) String() string
String implements fmt.Stringer.
type UpdateChatParticipantAdd ¶
type UpdateChatParticipantAdd struct {
// Group ID
ChatID int
// ID of the new member
UserID int
// ID of the user, who added member to the group
InviterID int
// When was the participant added
Date int
// Chat version number
Version int
}
UpdateChatParticipantAdd represents TL type `updateChatParticipantAdd#ea4b0e5c`. New group member.
See https://core.telegram.org/constructor/updateChatParticipantAdd for reference.
func (*UpdateChatParticipantAdd) Decode ¶
func (u *UpdateChatParticipantAdd) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatParticipantAdd) Encode ¶
func (u *UpdateChatParticipantAdd) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatParticipantAdd) String ¶ added in v0.12.0
func (u *UpdateChatParticipantAdd) String() string
String implements fmt.Stringer.
type UpdateChatParticipantAdmin ¶
type UpdateChatParticipantAdmin struct {
// Chat ID
ChatID int
// ID of the (de)admined user
UserID int
// Whether the user was rendered admin
IsAdmin bool
// Used in basic groups to reorder updates and make sure that all of them was received.
Version int
}
UpdateChatParticipantAdmin represents TL type `updateChatParticipantAdmin#b6901959`. Admin permissions of a user in a legacy group¹ were changed
Links:
See https://core.telegram.org/constructor/updateChatParticipantAdmin for reference.
func (*UpdateChatParticipantAdmin) Decode ¶
func (u *UpdateChatParticipantAdmin) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatParticipantAdmin) Encode ¶
func (u *UpdateChatParticipantAdmin) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatParticipantAdmin) String ¶ added in v0.12.0
func (u *UpdateChatParticipantAdmin) String() string
String implements fmt.Stringer.
type UpdateChatParticipantDelete ¶
type UpdateChatParticipantDelete struct {
// Group ID
ChatID int
// ID of the user
UserID int
// Used in basic groups to reorder updates and make sure that all of them was received.
Version int
}
UpdateChatParticipantDelete represents TL type `updateChatParticipantDelete#6e5f8c22`. A member has left the group.
See https://core.telegram.org/constructor/updateChatParticipantDelete for reference.
func (*UpdateChatParticipantDelete) Decode ¶
func (u *UpdateChatParticipantDelete) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatParticipantDelete) Encode ¶
func (u *UpdateChatParticipantDelete) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatParticipantDelete) String ¶ added in v0.12.0
func (u *UpdateChatParticipantDelete) String() string
String implements fmt.Stringer.
type UpdateChatParticipants ¶
type UpdateChatParticipants struct {
// Updated chat participants
Participants ChatParticipantsClass
}
UpdateChatParticipants represents TL type `updateChatParticipants#7761198`. Composition of chat participants changed.
See https://core.telegram.org/constructor/updateChatParticipants for reference.
func (*UpdateChatParticipants) Decode ¶
func (u *UpdateChatParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatParticipants) Encode ¶
func (u *UpdateChatParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatParticipants) String ¶ added in v0.12.0
func (u *UpdateChatParticipants) String() string
String implements fmt.Stringer.
type UpdateChatUserTyping ¶
type UpdateChatUserTyping struct {
// Group id
ChatID int
// User id
UserID int
// Type of actionParameter added in Layer 17¹.
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-17
Action SendMessageActionClass
}
UpdateChatUserTyping represents TL type `updateChatUserTyping#9a65ea1f`. The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no repeated update received after 6 seconds, it should be considered that the user stopped doing whatever he's been doing.
See https://core.telegram.org/constructor/updateChatUserTyping for reference.
func (*UpdateChatUserTyping) Decode ¶
func (u *UpdateChatUserTyping) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateChatUserTyping) Encode ¶
func (u *UpdateChatUserTyping) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateChatUserTyping) String ¶ added in v0.12.0
func (u *UpdateChatUserTyping) String() string
String implements fmt.Stringer.
type UpdateClass ¶
type UpdateClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UpdateClass represents Update generic type.
See https://core.telegram.org/type/Update for reference.
Example:
g, err := DecodeUpdate(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UpdateNewMessage: // updateNewMessage#1f2b0afd
case *UpdateMessageID: // updateMessageID#4e90bfd6
case *UpdateDeleteMessages: // updateDeleteMessages#a20db0e5
case *UpdateUserTyping: // updateUserTyping#5c486927
case *UpdateChatUserTyping: // updateChatUserTyping#9a65ea1f
case *UpdateChatParticipants: // updateChatParticipants#7761198
case *UpdateUserStatus: // updateUserStatus#1bfbd823
case *UpdateUserName: // updateUserName#a7332b73
case *UpdateUserPhoto: // updateUserPhoto#95313b0c
case *UpdateNewEncryptedMessage: // updateNewEncryptedMessage#12bcbd9a
case *UpdateEncryptedChatTyping: // updateEncryptedChatTyping#1710f156
case *UpdateEncryption: // updateEncryption#b4a2e88d
case *UpdateEncryptedMessagesRead: // updateEncryptedMessagesRead#38fe25b7
case *UpdateChatParticipantAdd: // updateChatParticipantAdd#ea4b0e5c
case *UpdateChatParticipantDelete: // updateChatParticipantDelete#6e5f8c22
case *UpdateDcOptions: // updateDcOptions#8e5e9873
case *UpdateNotifySettings: // updateNotifySettings#bec268ef
case *UpdateServiceNotification: // updateServiceNotification#ebe46819
case *UpdatePrivacy: // updatePrivacy#ee3b272a
case *UpdateUserPhone: // updateUserPhone#12b9417b
case *UpdateReadHistoryInbox: // updateReadHistoryInbox#9c974fdf
case *UpdateReadHistoryOutbox: // updateReadHistoryOutbox#2f2f21bf
case *UpdateWebPage: // updateWebPage#7f891213
case *UpdateReadMessagesContents: // updateReadMessagesContents#68c13933
case *UpdateChannelTooLong: // updateChannelTooLong#eb0467fb
case *UpdateChannel: // updateChannel#b6d45656
case *UpdateNewChannelMessage: // updateNewChannelMessage#62ba04d9
case *UpdateReadChannelInbox: // updateReadChannelInbox#330b5424
case *UpdateDeleteChannelMessages: // updateDeleteChannelMessages#c37521c9
case *UpdateChannelMessageViews: // updateChannelMessageViews#98a12b4b
case *UpdateChatParticipantAdmin: // updateChatParticipantAdmin#b6901959
case *UpdateNewStickerSet: // updateNewStickerSet#688a30aa
case *UpdateStickerSetsOrder: // updateStickerSetsOrder#bb2d201
case *UpdateStickerSets: // updateStickerSets#43ae3dec
case *UpdateSavedGifs: // updateSavedGifs#9375341e
case *UpdateBotInlineQuery: // updateBotInlineQuery#3f2038db
case *UpdateBotInlineSend: // updateBotInlineSend#e48f964
case *UpdateEditChannelMessage: // updateEditChannelMessage#1b3f4df7
case *UpdateBotCallbackQuery: // updateBotCallbackQuery#e73547e1
case *UpdateEditMessage: // updateEditMessage#e40370a3
case *UpdateInlineBotCallbackQuery: // updateInlineBotCallbackQuery#f9d27a5a
case *UpdateReadChannelOutbox: // updateReadChannelOutbox#25d6c9c7
case *UpdateDraftMessage: // updateDraftMessage#ee2bb969
case *UpdateReadFeaturedStickers: // updateReadFeaturedStickers#571d2742
case *UpdateRecentStickers: // updateRecentStickers#9a422c20
case *UpdateConfig: // updateConfig#a229dd06
case *UpdatePtsChanged: // updatePtsChanged#3354678f
case *UpdateChannelWebPage: // updateChannelWebPage#40771900
case *UpdateDialogPinned: // updateDialogPinned#6e6fe51c
case *UpdatePinnedDialogs: // updatePinnedDialogs#fa0f3ca2
case *UpdateBotWebhookJSON: // updateBotWebhookJSON#8317c0c3
case *UpdateBotWebhookJSONQuery: // updateBotWebhookJSONQuery#9b9240a6
case *UpdateBotShippingQuery: // updateBotShippingQuery#e0cdc940
case *UpdateBotPrecheckoutQuery: // updateBotPrecheckoutQuery#5d2f3aa9
case *UpdatePhoneCall: // updatePhoneCall#ab0f6b1e
case *UpdateLangPackTooLong: // updateLangPackTooLong#46560264
case *UpdateLangPack: // updateLangPack#56022f4d
case *UpdateFavedStickers: // updateFavedStickers#e511996d
case *UpdateChannelReadMessagesContents: // updateChannelReadMessagesContents#89893b45
case *UpdateContactsReset: // updateContactsReset#7084a7be
case *UpdateChannelAvailableMessages: // updateChannelAvailableMessages#70db6837
case *UpdateDialogUnreadMark: // updateDialogUnreadMark#e16459c3
case *UpdateMessagePoll: // updateMessagePoll#aca1657b
case *UpdateChatDefaultBannedRights: // updateChatDefaultBannedRights#54c01850
case *UpdateFolderPeers: // updateFolderPeers#19360dc0
case *UpdatePeerSettings: // updatePeerSettings#6a7e7366
case *UpdatePeerLocated: // updatePeerLocated#b4afcfb0
case *UpdateNewScheduledMessage: // updateNewScheduledMessage#39a51dfb
case *UpdateDeleteScheduledMessages: // updateDeleteScheduledMessages#90866cee
case *UpdateTheme: // updateTheme#8216fba3
case *UpdateGeoLiveViewed: // updateGeoLiveViewed#871fb939
case *UpdateLoginToken: // updateLoginToken#564fe691
case *UpdateMessagePollVote: // updateMessagePollVote#42f88f2c
case *UpdateDialogFilter: // updateDialogFilter#26ffde7d
case *UpdateDialogFilterOrder: // updateDialogFilterOrder#a5d72105
case *UpdateDialogFilters: // updateDialogFilters#3504914f
case *UpdatePhoneCallSignalingData: // updatePhoneCallSignalingData#2661bf09
case *UpdateChannelParticipant: // updateChannelParticipant#65d2b464
case *UpdateChannelMessageForwards: // updateChannelMessageForwards#6e8a84df
case *UpdateReadChannelDiscussionInbox: // updateReadChannelDiscussionInbox#1cc7de54
case *UpdateReadChannelDiscussionOutbox: // updateReadChannelDiscussionOutbox#4638a26c
case *UpdatePeerBlocked: // updatePeerBlocked#246a4b22
case *UpdateChannelUserTyping: // updateChannelUserTyping#ff2abe9f
case *UpdatePinnedMessages: // updatePinnedMessages#ed85eab5
case *UpdatePinnedChannelMessages: // updatePinnedChannelMessages#8588878b
case *UpdateChat: // updateChat#1330a196
case *UpdateGroupCallParticipants: // updateGroupCallParticipants#f2ebdb4e
case *UpdateGroupCall: // updateGroupCall#a45eb99b
default: panic(v)
}
func DecodeUpdate ¶
func DecodeUpdate(buf *bin.Buffer) (UpdateClass, error)
DecodeUpdate implements binary de-serialization for UpdateClass.
type UpdateConfig ¶
type UpdateConfig struct {
}
UpdateConfig represents TL type `updateConfig#a229dd06`. The server-side configuration has changed; the client should re-fetch the config using help.getConfig¹
Links:
See https://core.telegram.org/constructor/updateConfig for reference.
func (*UpdateConfig) Decode ¶
func (u *UpdateConfig) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateConfig) Encode ¶
func (u *UpdateConfig) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateConfig) String ¶ added in v0.12.0
func (u *UpdateConfig) String() string
String implements fmt.Stringer.
type UpdateContactsReset ¶
type UpdateContactsReset struct {
}
UpdateContactsReset represents TL type `updateContactsReset#7084a7be`. All contacts were deleted
See https://core.telegram.org/constructor/updateContactsReset for reference.
func (*UpdateContactsReset) Decode ¶
func (u *UpdateContactsReset) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateContactsReset) Encode ¶
func (u *UpdateContactsReset) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateContactsReset) String ¶ added in v0.12.0
func (u *UpdateContactsReset) String() string
String implements fmt.Stringer.
type UpdateContext ¶ added in v0.9.0
type UpdateDcOptions ¶
type UpdateDcOptions struct {
// New connection options
DCOptions []DcOption
}
UpdateDcOptions represents TL type `updateDcOptions#8e5e9873`. Changes in the data center configuration options.
See https://core.telegram.org/constructor/updateDcOptions for reference.
func (*UpdateDcOptions) Decode ¶
func (u *UpdateDcOptions) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDcOptions) Encode ¶
func (u *UpdateDcOptions) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDcOptions) String ¶ added in v0.12.0
func (u *UpdateDcOptions) String() string
String implements fmt.Stringer.
type UpdateDeleteChannelMessages ¶
type UpdateDeleteChannelMessages struct {
// Channel ID
ChannelID int
// IDs of messages that were deleted
Messages []int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateDeleteChannelMessages represents TL type `updateDeleteChannelMessages#c37521c9`. Some messages in a supergroup/channel¹ were deleted
Links:
See https://core.telegram.org/constructor/updateDeleteChannelMessages for reference.
func (*UpdateDeleteChannelMessages) Decode ¶
func (u *UpdateDeleteChannelMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDeleteChannelMessages) Encode ¶
func (u *UpdateDeleteChannelMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDeleteChannelMessages) String ¶ added in v0.12.0
func (u *UpdateDeleteChannelMessages) String() string
String implements fmt.Stringer.
type UpdateDeleteMessages ¶
type UpdateDeleteMessages struct {
// List of identifiers of deleted messages
Messages []int
// New quality of actions in a message box
Pts int
// Number of generated events¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateDeleteMessages represents TL type `updateDeleteMessages#a20db0e5`. Messages were deleted.
See https://core.telegram.org/constructor/updateDeleteMessages for reference.
func (*UpdateDeleteMessages) Decode ¶
func (u *UpdateDeleteMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDeleteMessages) Encode ¶
func (u *UpdateDeleteMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDeleteMessages) String ¶ added in v0.12.0
func (u *UpdateDeleteMessages) String() string
String implements fmt.Stringer.
type UpdateDeleteScheduledMessages ¶
type UpdateDeleteScheduledMessages struct {
// Peer
Peer PeerClass
// Deleted scheduled messages
Messages []int
}
UpdateDeleteScheduledMessages represents TL type `updateDeleteScheduledMessages#90866cee`. Some scheduled messages¹ were deleted from the schedule queue of a chat
Links:
See https://core.telegram.org/constructor/updateDeleteScheduledMessages for reference.
func (*UpdateDeleteScheduledMessages) Decode ¶
func (u *UpdateDeleteScheduledMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDeleteScheduledMessages) Encode ¶
func (u *UpdateDeleteScheduledMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDeleteScheduledMessages) String ¶ added in v0.12.0
func (u *UpdateDeleteScheduledMessages) String() string
String implements fmt.Stringer.
type UpdateDialogFilter ¶
type UpdateDialogFilter struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Folder¹ ID
//
// Links:
// 1) https://core.telegram.org/api/folders
ID int
// Folder¹ info
//
// Links:
// 1) https://core.telegram.org/api/folders
//
// Use SetFilter and GetFilter helpers.
Filter DialogFilter
}
UpdateDialogFilter represents TL type `updateDialogFilter#26ffde7d`. A new folder¹ was added
Links:
See https://core.telegram.org/constructor/updateDialogFilter for reference.
func (*UpdateDialogFilter) Decode ¶
func (u *UpdateDialogFilter) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDialogFilter) Encode ¶
func (u *UpdateDialogFilter) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDialogFilter) GetFilter ¶
func (u *UpdateDialogFilter) GetFilter() (value DialogFilter, ok bool)
GetFilter returns value of Filter conditional field and boolean which is true if field was set.
func (*UpdateDialogFilter) SetFilter ¶
func (u *UpdateDialogFilter) SetFilter(value DialogFilter)
SetFilter sets value of Filter conditional field.
func (*UpdateDialogFilter) String ¶ added in v0.12.0
func (u *UpdateDialogFilter) String() string
String implements fmt.Stringer.
type UpdateDialogFilterOrder ¶
type UpdateDialogFilterOrder struct {
// Ordered folder IDs¹
//
// Links:
// 1) https://core.telegram.org/api/folders
Order []int
}
UpdateDialogFilterOrder represents TL type `updateDialogFilterOrder#a5d72105`. New folder¹ order
Links:
See https://core.telegram.org/constructor/updateDialogFilterOrder for reference.
func (*UpdateDialogFilterOrder) Decode ¶
func (u *UpdateDialogFilterOrder) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDialogFilterOrder) Encode ¶
func (u *UpdateDialogFilterOrder) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDialogFilterOrder) String ¶ added in v0.12.0
func (u *UpdateDialogFilterOrder) String() string
String implements fmt.Stringer.
type UpdateDialogFilters ¶
type UpdateDialogFilters struct {
}
UpdateDialogFilters represents TL type `updateDialogFilters#3504914f`. Clients should update folder¹ info
Links:
See https://core.telegram.org/constructor/updateDialogFilters for reference.
func (*UpdateDialogFilters) Decode ¶
func (u *UpdateDialogFilters) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDialogFilters) Encode ¶
func (u *UpdateDialogFilters) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDialogFilters) String ¶ added in v0.12.0
func (u *UpdateDialogFilters) String() string
String implements fmt.Stringer.
type UpdateDialogPinned ¶
type UpdateDialogPinned struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the dialog was pinned
Pinned bool
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// The dialog
Peer DialogPeerClass
}
UpdateDialogPinned represents TL type `updateDialogPinned#6e6fe51c`. A dialog was pinned/unpinned
See https://core.telegram.org/constructor/updateDialogPinned for reference.
func (*UpdateDialogPinned) Decode ¶
func (u *UpdateDialogPinned) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDialogPinned) Encode ¶
func (u *UpdateDialogPinned) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDialogPinned) GetFolderID ¶
func (u *UpdateDialogPinned) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*UpdateDialogPinned) SetFolderID ¶
func (u *UpdateDialogPinned) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*UpdateDialogPinned) SetPinned ¶
func (u *UpdateDialogPinned) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*UpdateDialogPinned) String ¶ added in v0.12.0
func (u *UpdateDialogPinned) String() string
String implements fmt.Stringer.
type UpdateDialogUnreadMark ¶
type UpdateDialogUnreadMark struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Was the chat marked or unmarked as read
Unread bool
// The dialog
Peer DialogPeerClass
}
UpdateDialogUnreadMark represents TL type `updateDialogUnreadMark#e16459c3`. The manual unread mark of a chat was changed
See https://core.telegram.org/constructor/updateDialogUnreadMark for reference.
func (*UpdateDialogUnreadMark) Decode ¶
func (u *UpdateDialogUnreadMark) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDialogUnreadMark) Encode ¶
func (u *UpdateDialogUnreadMark) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDialogUnreadMark) SetUnread ¶
func (u *UpdateDialogUnreadMark) SetUnread(value bool)
SetUnread sets value of Unread conditional field.
func (*UpdateDialogUnreadMark) String ¶ added in v0.12.0
func (u *UpdateDialogUnreadMark) String() string
String implements fmt.Stringer.
type UpdateDispatcher ¶ added in v0.9.0
type UpdateDispatcher struct {
// contains filtered or unexported fields
}
func NewUpdateDispatcher ¶ added in v0.9.0
func NewUpdateDispatcher() UpdateDispatcher
func (UpdateDispatcher) Handle ¶ added in v0.9.0
func (u UpdateDispatcher) Handle(ctx context.Context, updates *Updates) error
func (UpdateDispatcher) OnBotCallbackQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotCallbackQuery(handler BotCallbackQueryHandler)
OnBotCallbackQuery sets BotCallbackQuery handler.
func (UpdateDispatcher) OnBotInlineQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotInlineQuery(handler BotInlineQueryHandler)
OnBotInlineQuery sets BotInlineQuery handler.
func (UpdateDispatcher) OnBotInlineSend ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotInlineSend(handler BotInlineSendHandler)
OnBotInlineSend sets BotInlineSend handler.
func (UpdateDispatcher) OnBotPrecheckoutQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotPrecheckoutQuery(handler BotPrecheckoutQueryHandler)
OnBotPrecheckoutQuery sets BotPrecheckoutQuery handler.
func (UpdateDispatcher) OnBotShippingQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotShippingQuery(handler BotShippingQueryHandler)
OnBotShippingQuery sets BotShippingQuery handler.
func (UpdateDispatcher) OnBotWebhookJSON ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotWebhookJSON(handler BotWebhookJSONHandler)
OnBotWebhookJSON sets BotWebhookJSON handler.
func (UpdateDispatcher) OnBotWebhookJSONQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnBotWebhookJSONQuery(handler BotWebhookJSONQueryHandler)
OnBotWebhookJSONQuery sets BotWebhookJSONQuery handler.
func (UpdateDispatcher) OnChannel ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannel(handler ChannelHandler)
OnChannel sets Channel handler.
func (UpdateDispatcher) OnChannelAvailableMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelAvailableMessages(handler ChannelAvailableMessagesHandler)
OnChannelAvailableMessages sets ChannelAvailableMessages handler.
func (UpdateDispatcher) OnChannelMessageForwards ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelMessageForwards(handler ChannelMessageForwardsHandler)
OnChannelMessageForwards sets ChannelMessageForwards handler.
func (UpdateDispatcher) OnChannelMessageViews ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelMessageViews(handler ChannelMessageViewsHandler)
OnChannelMessageViews sets ChannelMessageViews handler.
func (UpdateDispatcher) OnChannelParticipant ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelParticipant(handler ChannelParticipantHandler)
OnChannelParticipant sets ChannelParticipant handler.
func (UpdateDispatcher) OnChannelReadMessagesContents ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelReadMessagesContents(handler ChannelReadMessagesContentsHandler)
OnChannelReadMessagesContents sets ChannelReadMessagesContents handler.
func (UpdateDispatcher) OnChannelTooLong ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelTooLong(handler ChannelTooLongHandler)
OnChannelTooLong sets ChannelTooLong handler.
func (UpdateDispatcher) OnChannelUserTyping ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelUserTyping(handler ChannelUserTypingHandler)
OnChannelUserTyping sets ChannelUserTyping handler.
func (UpdateDispatcher) OnChannelWebPage ¶ added in v0.9.0
func (u UpdateDispatcher) OnChannelWebPage(handler ChannelWebPageHandler)
OnChannelWebPage sets ChannelWebPage handler.
func (UpdateDispatcher) OnChat ¶ added in v0.13.0
func (u UpdateDispatcher) OnChat(handler ChatHandler)
OnChat sets Chat handler.
func (UpdateDispatcher) OnChatDefaultBannedRights ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatDefaultBannedRights(handler ChatDefaultBannedRightsHandler)
OnChatDefaultBannedRights sets ChatDefaultBannedRights handler.
func (UpdateDispatcher) OnChatParticipantAdd ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatParticipantAdd(handler ChatParticipantAddHandler)
OnChatParticipantAdd sets ChatParticipantAdd handler.
func (UpdateDispatcher) OnChatParticipantAdmin ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatParticipantAdmin(handler ChatParticipantAdminHandler)
OnChatParticipantAdmin sets ChatParticipantAdmin handler.
func (UpdateDispatcher) OnChatParticipantDelete ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatParticipantDelete(handler ChatParticipantDeleteHandler)
OnChatParticipantDelete sets ChatParticipantDelete handler.
func (UpdateDispatcher) OnChatParticipants ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatParticipants(handler ChatParticipantsHandler)
OnChatParticipants sets ChatParticipants handler.
func (UpdateDispatcher) OnChatUserTyping ¶ added in v0.9.0
func (u UpdateDispatcher) OnChatUserTyping(handler ChatUserTypingHandler)
OnChatUserTyping sets ChatUserTyping handler.
func (UpdateDispatcher) OnConfig ¶ added in v0.9.0
func (u UpdateDispatcher) OnConfig(handler ConfigHandler)
OnConfig sets Config handler.
func (UpdateDispatcher) OnContactsReset ¶ added in v0.9.0
func (u UpdateDispatcher) OnContactsReset(handler ContactsResetHandler)
OnContactsReset sets ContactsReset handler.
func (UpdateDispatcher) OnDcOptions ¶ added in v0.9.0
func (u UpdateDispatcher) OnDcOptions(handler DcOptionsHandler)
OnDcOptions sets DcOptions handler.
func (UpdateDispatcher) OnDeleteChannelMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnDeleteChannelMessages(handler DeleteChannelMessagesHandler)
OnDeleteChannelMessages sets DeleteChannelMessages handler.
func (UpdateDispatcher) OnDeleteMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnDeleteMessages(handler DeleteMessagesHandler)
OnDeleteMessages sets DeleteMessages handler.
func (UpdateDispatcher) OnDeleteScheduledMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnDeleteScheduledMessages(handler DeleteScheduledMessagesHandler)
OnDeleteScheduledMessages sets DeleteScheduledMessages handler.
func (UpdateDispatcher) OnDialogFilter ¶ added in v0.9.0
func (u UpdateDispatcher) OnDialogFilter(handler DialogFilterHandler)
OnDialogFilter sets DialogFilter handler.
func (UpdateDispatcher) OnDialogFilterOrder ¶ added in v0.9.0
func (u UpdateDispatcher) OnDialogFilterOrder(handler DialogFilterOrderHandler)
OnDialogFilterOrder sets DialogFilterOrder handler.
func (UpdateDispatcher) OnDialogFilters ¶ added in v0.9.0
func (u UpdateDispatcher) OnDialogFilters(handler DialogFiltersHandler)
OnDialogFilters sets DialogFilters handler.
func (UpdateDispatcher) OnDialogPinned ¶ added in v0.9.0
func (u UpdateDispatcher) OnDialogPinned(handler DialogPinnedHandler)
OnDialogPinned sets DialogPinned handler.
func (UpdateDispatcher) OnDialogUnreadMark ¶ added in v0.9.0
func (u UpdateDispatcher) OnDialogUnreadMark(handler DialogUnreadMarkHandler)
OnDialogUnreadMark sets DialogUnreadMark handler.
func (UpdateDispatcher) OnDraftMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnDraftMessage(handler DraftMessageHandler)
OnDraftMessage sets DraftMessage handler.
func (UpdateDispatcher) OnEditChannelMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnEditChannelMessage(handler EditChannelMessageHandler)
OnEditChannelMessage sets EditChannelMessage handler.
func (UpdateDispatcher) OnEditMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnEditMessage(handler EditMessageHandler)
OnEditMessage sets EditMessage handler.
func (UpdateDispatcher) OnEncryptedChatTyping ¶ added in v0.9.0
func (u UpdateDispatcher) OnEncryptedChatTyping(handler EncryptedChatTypingHandler)
OnEncryptedChatTyping sets EncryptedChatTyping handler.
func (UpdateDispatcher) OnEncryptedMessagesRead ¶ added in v0.9.0
func (u UpdateDispatcher) OnEncryptedMessagesRead(handler EncryptedMessagesReadHandler)
OnEncryptedMessagesRead sets EncryptedMessagesRead handler.
func (UpdateDispatcher) OnEncryption ¶ added in v0.9.0
func (u UpdateDispatcher) OnEncryption(handler EncryptionHandler)
OnEncryption sets Encryption handler.
func (UpdateDispatcher) OnFavedStickers ¶ added in v0.9.0
func (u UpdateDispatcher) OnFavedStickers(handler FavedStickersHandler)
OnFavedStickers sets FavedStickers handler.
func (UpdateDispatcher) OnFolderPeers ¶ added in v0.9.0
func (u UpdateDispatcher) OnFolderPeers(handler FolderPeersHandler)
OnFolderPeers sets FolderPeers handler.
func (UpdateDispatcher) OnGeoLiveViewed ¶ added in v0.9.0
func (u UpdateDispatcher) OnGeoLiveViewed(handler GeoLiveViewedHandler)
OnGeoLiveViewed sets GeoLiveViewed handler.
func (UpdateDispatcher) OnGroupCall ¶ added in v0.13.0
func (u UpdateDispatcher) OnGroupCall(handler GroupCallHandler)
OnGroupCall sets GroupCall handler.
func (UpdateDispatcher) OnGroupCallParticipants ¶ added in v0.13.0
func (u UpdateDispatcher) OnGroupCallParticipants(handler GroupCallParticipantsHandler)
OnGroupCallParticipants sets GroupCallParticipants handler.
func (UpdateDispatcher) OnInlineBotCallbackQuery ¶ added in v0.9.0
func (u UpdateDispatcher) OnInlineBotCallbackQuery(handler InlineBotCallbackQueryHandler)
OnInlineBotCallbackQuery sets InlineBotCallbackQuery handler.
func (UpdateDispatcher) OnLangPack ¶ added in v0.9.0
func (u UpdateDispatcher) OnLangPack(handler LangPackHandler)
OnLangPack sets LangPack handler.
func (UpdateDispatcher) OnLangPackTooLong ¶ added in v0.9.0
func (u UpdateDispatcher) OnLangPackTooLong(handler LangPackTooLongHandler)
OnLangPackTooLong sets LangPackTooLong handler.
func (UpdateDispatcher) OnLoginToken ¶ added in v0.9.0
func (u UpdateDispatcher) OnLoginToken(handler LoginTokenHandler)
OnLoginToken sets LoginToken handler.
func (UpdateDispatcher) OnMessageID ¶ added in v0.9.0
func (u UpdateDispatcher) OnMessageID(handler MessageIDHandler)
OnMessageID sets MessageID handler.
func (UpdateDispatcher) OnMessagePoll ¶ added in v0.9.0
func (u UpdateDispatcher) OnMessagePoll(handler MessagePollHandler)
OnMessagePoll sets MessagePoll handler.
func (UpdateDispatcher) OnMessagePollVote ¶ added in v0.9.0
func (u UpdateDispatcher) OnMessagePollVote(handler MessagePollVoteHandler)
OnMessagePollVote sets MessagePollVote handler.
func (UpdateDispatcher) OnNewChannelMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnNewChannelMessage(handler NewChannelMessageHandler)
OnNewChannelMessage sets NewChannelMessage handler.
func (UpdateDispatcher) OnNewEncryptedMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnNewEncryptedMessage(handler NewEncryptedMessageHandler)
OnNewEncryptedMessage sets NewEncryptedMessage handler.
func (UpdateDispatcher) OnNewMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnNewMessage(handler NewMessageHandler)
OnNewMessage sets NewMessage handler.
func (UpdateDispatcher) OnNewScheduledMessage ¶ added in v0.9.0
func (u UpdateDispatcher) OnNewScheduledMessage(handler NewScheduledMessageHandler)
OnNewScheduledMessage sets NewScheduledMessage handler.
func (UpdateDispatcher) OnNewStickerSet ¶ added in v0.9.0
func (u UpdateDispatcher) OnNewStickerSet(handler NewStickerSetHandler)
OnNewStickerSet sets NewStickerSet handler.
func (UpdateDispatcher) OnNotifySettings ¶ added in v0.9.0
func (u UpdateDispatcher) OnNotifySettings(handler NotifySettingsHandler)
OnNotifySettings sets NotifySettings handler.
func (UpdateDispatcher) OnPeerBlocked ¶ added in v0.9.0
func (u UpdateDispatcher) OnPeerBlocked(handler PeerBlockedHandler)
OnPeerBlocked sets PeerBlocked handler.
func (UpdateDispatcher) OnPeerLocated ¶ added in v0.9.0
func (u UpdateDispatcher) OnPeerLocated(handler PeerLocatedHandler)
OnPeerLocated sets PeerLocated handler.
func (UpdateDispatcher) OnPeerSettings ¶ added in v0.9.0
func (u UpdateDispatcher) OnPeerSettings(handler PeerSettingsHandler)
OnPeerSettings sets PeerSettings handler.
func (UpdateDispatcher) OnPhoneCall ¶ added in v0.9.0
func (u UpdateDispatcher) OnPhoneCall(handler PhoneCallHandler)
OnPhoneCall sets PhoneCall handler.
func (UpdateDispatcher) OnPhoneCallSignalingData ¶ added in v0.9.0
func (u UpdateDispatcher) OnPhoneCallSignalingData(handler PhoneCallSignalingDataHandler)
OnPhoneCallSignalingData sets PhoneCallSignalingData handler.
func (UpdateDispatcher) OnPinnedChannelMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnPinnedChannelMessages(handler PinnedChannelMessagesHandler)
OnPinnedChannelMessages sets PinnedChannelMessages handler.
func (UpdateDispatcher) OnPinnedDialogs ¶ added in v0.9.0
func (u UpdateDispatcher) OnPinnedDialogs(handler PinnedDialogsHandler)
OnPinnedDialogs sets PinnedDialogs handler.
func (UpdateDispatcher) OnPinnedMessages ¶ added in v0.9.0
func (u UpdateDispatcher) OnPinnedMessages(handler PinnedMessagesHandler)
OnPinnedMessages sets PinnedMessages handler.
func (UpdateDispatcher) OnPrivacy ¶ added in v0.9.0
func (u UpdateDispatcher) OnPrivacy(handler PrivacyHandler)
OnPrivacy sets Privacy handler.
func (UpdateDispatcher) OnPtsChanged ¶ added in v0.9.0
func (u UpdateDispatcher) OnPtsChanged(handler PtsChangedHandler)
OnPtsChanged sets PtsChanged handler.
func (UpdateDispatcher) OnReadChannelDiscussionInbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadChannelDiscussionInbox(handler ReadChannelDiscussionInboxHandler)
OnReadChannelDiscussionInbox sets ReadChannelDiscussionInbox handler.
func (UpdateDispatcher) OnReadChannelDiscussionOutbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadChannelDiscussionOutbox(handler ReadChannelDiscussionOutboxHandler)
OnReadChannelDiscussionOutbox sets ReadChannelDiscussionOutbox handler.
func (UpdateDispatcher) OnReadChannelInbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadChannelInbox(handler ReadChannelInboxHandler)
OnReadChannelInbox sets ReadChannelInbox handler.
func (UpdateDispatcher) OnReadChannelOutbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadChannelOutbox(handler ReadChannelOutboxHandler)
OnReadChannelOutbox sets ReadChannelOutbox handler.
func (UpdateDispatcher) OnReadFeaturedStickers ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadFeaturedStickers(handler ReadFeaturedStickersHandler)
OnReadFeaturedStickers sets ReadFeaturedStickers handler.
func (UpdateDispatcher) OnReadHistoryInbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadHistoryInbox(handler ReadHistoryInboxHandler)
OnReadHistoryInbox sets ReadHistoryInbox handler.
func (UpdateDispatcher) OnReadHistoryOutbox ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadHistoryOutbox(handler ReadHistoryOutboxHandler)
OnReadHistoryOutbox sets ReadHistoryOutbox handler.
func (UpdateDispatcher) OnReadMessagesContents ¶ added in v0.9.0
func (u UpdateDispatcher) OnReadMessagesContents(handler ReadMessagesContentsHandler)
OnReadMessagesContents sets ReadMessagesContents handler.
func (UpdateDispatcher) OnRecentStickers ¶ added in v0.9.0
func (u UpdateDispatcher) OnRecentStickers(handler RecentStickersHandler)
OnRecentStickers sets RecentStickers handler.
func (UpdateDispatcher) OnSavedGifs ¶ added in v0.9.0
func (u UpdateDispatcher) OnSavedGifs(handler SavedGifsHandler)
OnSavedGifs sets SavedGifs handler.
func (UpdateDispatcher) OnServiceNotification ¶ added in v0.9.0
func (u UpdateDispatcher) OnServiceNotification(handler ServiceNotificationHandler)
OnServiceNotification sets ServiceNotification handler.
func (UpdateDispatcher) OnStickerSets ¶ added in v0.9.0
func (u UpdateDispatcher) OnStickerSets(handler StickerSetsHandler)
OnStickerSets sets StickerSets handler.
func (UpdateDispatcher) OnStickerSetsOrder ¶ added in v0.9.0
func (u UpdateDispatcher) OnStickerSetsOrder(handler StickerSetsOrderHandler)
OnStickerSetsOrder sets StickerSetsOrder handler.
func (UpdateDispatcher) OnTheme ¶ added in v0.9.0
func (u UpdateDispatcher) OnTheme(handler ThemeHandler)
OnTheme sets Theme handler.
func (UpdateDispatcher) OnUserName ¶ added in v0.9.0
func (u UpdateDispatcher) OnUserName(handler UserNameHandler)
OnUserName sets UserName handler.
func (UpdateDispatcher) OnUserPhone ¶ added in v0.9.0
func (u UpdateDispatcher) OnUserPhone(handler UserPhoneHandler)
OnUserPhone sets UserPhone handler.
func (UpdateDispatcher) OnUserPhoto ¶ added in v0.9.0
func (u UpdateDispatcher) OnUserPhoto(handler UserPhotoHandler)
OnUserPhoto sets UserPhoto handler.
func (UpdateDispatcher) OnUserStatus ¶ added in v0.9.0
func (u UpdateDispatcher) OnUserStatus(handler UserStatusHandler)
OnUserStatus sets UserStatus handler.
func (UpdateDispatcher) OnUserTyping ¶ added in v0.9.0
func (u UpdateDispatcher) OnUserTyping(handler UserTypingHandler)
OnUserTyping sets UserTyping handler.
func (UpdateDispatcher) OnWebPage ¶ added in v0.9.0
func (u UpdateDispatcher) OnWebPage(handler WebPageHandler)
OnWebPage sets WebPage handler.
type UpdateDraftMessage ¶
type UpdateDraftMessage struct {
// The peer to which the draft is associated
Peer PeerClass
// The draft
Draft DraftMessageClass
}
UpdateDraftMessage represents TL type `updateDraftMessage#ee2bb969`. Notifies a change of a message draft¹.
Links:
See https://core.telegram.org/constructor/updateDraftMessage for reference.
func (*UpdateDraftMessage) Decode ¶
func (u *UpdateDraftMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateDraftMessage) Encode ¶
func (u *UpdateDraftMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateDraftMessage) String ¶ added in v0.12.0
func (u *UpdateDraftMessage) String() string
String implements fmt.Stringer.
type UpdateEditChannelMessage ¶
type UpdateEditChannelMessage struct {
// The new message
Message MessageClass
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateEditChannelMessage represents TL type `updateEditChannelMessage#1b3f4df7`. A message was edited in a channel/supergroup¹
Links:
See https://core.telegram.org/constructor/updateEditChannelMessage for reference.
func (*UpdateEditChannelMessage) Decode ¶
func (u *UpdateEditChannelMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateEditChannelMessage) Encode ¶
func (u *UpdateEditChannelMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateEditChannelMessage) String ¶ added in v0.12.0
func (u *UpdateEditChannelMessage) String() string
String implements fmt.Stringer.
type UpdateEditMessage ¶
type UpdateEditMessage struct {
// The new edited message
Message MessageClass
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// PTS count¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateEditMessage represents TL type `updateEditMessage#e40370a3`. A message was edited
See https://core.telegram.org/constructor/updateEditMessage for reference.
func (*UpdateEditMessage) Decode ¶
func (u *UpdateEditMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateEditMessage) Encode ¶
func (u *UpdateEditMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateEditMessage) String ¶ added in v0.12.0
func (u *UpdateEditMessage) String() string
String implements fmt.Stringer.
type UpdateEncryptedChatTyping ¶
type UpdateEncryptedChatTyping struct {
// Chat ID
ChatID int
}
UpdateEncryptedChatTyping represents TL type `updateEncryptedChatTyping#1710f156`. Interlocutor is typing a message in an encrypted chat. Update period is 6 second. If upon this time there is no repeated update, it shall be considered that the interlocutor stopped typing.
See https://core.telegram.org/constructor/updateEncryptedChatTyping for reference.
func (*UpdateEncryptedChatTyping) Decode ¶
func (u *UpdateEncryptedChatTyping) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateEncryptedChatTyping) Encode ¶
func (u *UpdateEncryptedChatTyping) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateEncryptedChatTyping) String ¶ added in v0.12.0
func (u *UpdateEncryptedChatTyping) String() string
String implements fmt.Stringer.
type UpdateEncryptedMessagesRead ¶
type UpdateEncryptedMessagesRead struct {
// Chat ID
ChatID int
// Maximum value of data for read messages
MaxDate int
// Time when messages were read
Date int
}
UpdateEncryptedMessagesRead represents TL type `updateEncryptedMessagesRead#38fe25b7`. Communication history in an encrypted chat was marked as read.
See https://core.telegram.org/constructor/updateEncryptedMessagesRead for reference.
func (*UpdateEncryptedMessagesRead) Decode ¶
func (u *UpdateEncryptedMessagesRead) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateEncryptedMessagesRead) Encode ¶
func (u *UpdateEncryptedMessagesRead) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateEncryptedMessagesRead) String ¶ added in v0.12.0
func (u *UpdateEncryptedMessagesRead) String() string
String implements fmt.Stringer.
type UpdateEncryption ¶
type UpdateEncryption struct {
// Encrypted chat
Chat EncryptedChatClass
// Date of change
Date int
}
UpdateEncryption represents TL type `updateEncryption#b4a2e88d`. Change of state in an encrypted chat.
See https://core.telegram.org/constructor/updateEncryption for reference.
func (*UpdateEncryption) Decode ¶
func (u *UpdateEncryption) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateEncryption) Encode ¶
func (u *UpdateEncryption) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateEncryption) String ¶ added in v0.12.0
func (u *UpdateEncryption) String() string
String implements fmt.Stringer.
type UpdateFavedStickers ¶
type UpdateFavedStickers struct {
}
UpdateFavedStickers represents TL type `updateFavedStickers#e511996d`. The list of favorited stickers was changed, the client should call messages.getFavedStickers¹ to refetch the new list
Links:
See https://core.telegram.org/constructor/updateFavedStickers for reference.
func (*UpdateFavedStickers) Decode ¶
func (u *UpdateFavedStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateFavedStickers) Encode ¶
func (u *UpdateFavedStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateFavedStickers) String ¶ added in v0.12.0
func (u *UpdateFavedStickers) String() string
String implements fmt.Stringer.
type UpdateFolderPeers ¶
type UpdateFolderPeers struct {
// New peer list
FolderPeers []FolderPeer
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateFolderPeers represents TL type `updateFolderPeers#19360dc0`. The peer list of a peer folder¹ was updated
Links:
See https://core.telegram.org/constructor/updateFolderPeers for reference.
func (*UpdateFolderPeers) Decode ¶
func (u *UpdateFolderPeers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateFolderPeers) Encode ¶
func (u *UpdateFolderPeers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateFolderPeers) String ¶ added in v0.12.0
func (u *UpdateFolderPeers) String() string
String implements fmt.Stringer.
type UpdateGeoLiveViewed ¶
type UpdateGeoLiveViewed struct {
// The user that viewed the live geoposition
Peer PeerClass
// Message ID of geoposition message
MsgID int
}
UpdateGeoLiveViewed represents TL type `updateGeoLiveViewed#871fb939`. Live geoposition message was viewed
See https://core.telegram.org/constructor/updateGeoLiveViewed for reference.
func (*UpdateGeoLiveViewed) Decode ¶
func (u *UpdateGeoLiveViewed) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateGeoLiveViewed) Encode ¶
func (u *UpdateGeoLiveViewed) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateGeoLiveViewed) String ¶ added in v0.12.0
func (u *UpdateGeoLiveViewed) String() string
String implements fmt.Stringer.
type UpdateGroupCall ¶ added in v0.13.0
type UpdateGroupCall struct {
// ChatID field of UpdateGroupCall.
ChatID int
// Call field of UpdateGroupCall.
Call GroupCallClass
}
UpdateGroupCall represents TL type `updateGroupCall#a45eb99b`.
See https://core.telegram.org/constructor/updateGroupCall for reference.
func (*UpdateGroupCall) Decode ¶ added in v0.13.0
func (u *UpdateGroupCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateGroupCall) Encode ¶ added in v0.13.0
func (u *UpdateGroupCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateGroupCall) String ¶ added in v0.13.0
func (u *UpdateGroupCall) String() string
String implements fmt.Stringer.
type UpdateGroupCallParticipants ¶ added in v0.13.0
type UpdateGroupCallParticipants struct {
// Call field of UpdateGroupCallParticipants.
Call InputGroupCall
// Participants field of UpdateGroupCallParticipants.
Participants []GroupCallParticipant
// Version field of UpdateGroupCallParticipants.
Version int
}
UpdateGroupCallParticipants represents TL type `updateGroupCallParticipants#f2ebdb4e`.
See https://core.telegram.org/constructor/updateGroupCallParticipants for reference.
func (*UpdateGroupCallParticipants) Decode ¶ added in v0.13.0
func (u *UpdateGroupCallParticipants) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateGroupCallParticipants) Encode ¶ added in v0.13.0
func (u *UpdateGroupCallParticipants) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateGroupCallParticipants) String ¶ added in v0.13.0
func (u *UpdateGroupCallParticipants) String() string
String implements fmt.Stringer.
type UpdateInlineBotCallbackQuery ¶
type UpdateInlineBotCallbackQuery struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Query ID
QueryID int64
// ID of the user that pressed the button
UserID int
// ID of the inline message with the button
MsgID InputBotInlineMessageID
// Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games.
ChatInstance int64
// Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field.
//
// Use SetData and GetData helpers.
Data []byte
// Short name of a Game to be returned, serves as the unique identifier for the game
//
// Use SetGameShortName and GetGameShortName helpers.
GameShortName string
}
UpdateInlineBotCallbackQuery represents TL type `updateInlineBotCallbackQuery#f9d27a5a`. This notification is received by bots when a button is pressed
See https://core.telegram.org/constructor/updateInlineBotCallbackQuery for reference.
func (*UpdateInlineBotCallbackQuery) Decode ¶
func (u *UpdateInlineBotCallbackQuery) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateInlineBotCallbackQuery) Encode ¶
func (u *UpdateInlineBotCallbackQuery) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateInlineBotCallbackQuery) GetData ¶
func (u *UpdateInlineBotCallbackQuery) GetData() (value []byte, ok bool)
GetData returns value of Data conditional field and boolean which is true if field was set.
func (*UpdateInlineBotCallbackQuery) GetGameShortName ¶
func (u *UpdateInlineBotCallbackQuery) GetGameShortName() (value string, ok bool)
GetGameShortName returns value of GameShortName conditional field and boolean which is true if field was set.
func (*UpdateInlineBotCallbackQuery) SetData ¶
func (u *UpdateInlineBotCallbackQuery) SetData(value []byte)
SetData sets value of Data conditional field.
func (*UpdateInlineBotCallbackQuery) SetGameShortName ¶
func (u *UpdateInlineBotCallbackQuery) SetGameShortName(value string)
SetGameShortName sets value of GameShortName conditional field.
func (*UpdateInlineBotCallbackQuery) String ¶ added in v0.12.0
func (u *UpdateInlineBotCallbackQuery) String() string
String implements fmt.Stringer.
type UpdateLangPack ¶
type UpdateLangPack struct {
// Changed strings
Difference LangPackDifference
}
UpdateLangPack represents TL type `updateLangPack#56022f4d`. Language pack updated
See https://core.telegram.org/constructor/updateLangPack for reference.
func (*UpdateLangPack) Decode ¶
func (u *UpdateLangPack) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateLangPack) Encode ¶
func (u *UpdateLangPack) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateLangPack) String ¶ added in v0.12.0
func (u *UpdateLangPack) String() string
String implements fmt.Stringer.
type UpdateLangPackTooLong ¶
type UpdateLangPackTooLong struct {
// Language code
LangCode string
}
UpdateLangPackTooLong represents TL type `updateLangPackTooLong#46560264`. A language pack has changed, the client should manually fetch the changed strings using langpack.getDifference¹
Links:
See https://core.telegram.org/constructor/updateLangPackTooLong for reference.
func (*UpdateLangPackTooLong) Decode ¶
func (u *UpdateLangPackTooLong) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateLangPackTooLong) Encode ¶
func (u *UpdateLangPackTooLong) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateLangPackTooLong) String ¶ added in v0.12.0
func (u *UpdateLangPackTooLong) String() string
String implements fmt.Stringer.
type UpdateLoginToken ¶
type UpdateLoginToken struct {
}
UpdateLoginToken represents TL type `updateLoginToken#564fe691`. A login token (for login via QR code) was accepted.
See https://core.telegram.org/constructor/updateLoginToken for reference.
func (*UpdateLoginToken) Decode ¶
func (u *UpdateLoginToken) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateLoginToken) Encode ¶
func (u *UpdateLoginToken) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateLoginToken) String ¶ added in v0.12.0
func (u *UpdateLoginToken) String() string
String implements fmt.Stringer.
type UpdateMessageID ¶
type UpdateMessageID struct {
// id identifier of a respective Message¹
//
// Links:
// 1) https://core.telegram.org/type/Message
ID int
// Previuosly transferred client random_id identifier
RandomID int64
}
UpdateMessageID represents TL type `updateMessageID#4e90bfd6`. Sent message with random_id client identifier was assigned an identifier.
See https://core.telegram.org/constructor/updateMessageID for reference.
func (*UpdateMessageID) Decode ¶
func (u *UpdateMessageID) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateMessageID) Encode ¶
func (u *UpdateMessageID) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateMessageID) String ¶ added in v0.12.0
func (u *UpdateMessageID) String() string
String implements fmt.Stringer.
type UpdateMessagePoll ¶
type UpdateMessagePoll struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Poll ID
PollID int64
// If the server knows the client hasn't cached this poll yet, the poll itself
//
// Use SetPoll and GetPoll helpers.
Poll Poll
// New poll results
Results PollResults
}
UpdateMessagePoll represents TL type `updateMessagePoll#aca1657b`. The results of a poll have changed
See https://core.telegram.org/constructor/updateMessagePoll for reference.
func (*UpdateMessagePoll) Decode ¶
func (u *UpdateMessagePoll) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateMessagePoll) Encode ¶
func (u *UpdateMessagePoll) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateMessagePoll) GetPoll ¶
func (u *UpdateMessagePoll) GetPoll() (value Poll, ok bool)
GetPoll returns value of Poll conditional field and boolean which is true if field was set.
func (*UpdateMessagePoll) SetPoll ¶
func (u *UpdateMessagePoll) SetPoll(value Poll)
SetPoll sets value of Poll conditional field.
func (*UpdateMessagePoll) String ¶ added in v0.12.0
func (u *UpdateMessagePoll) String() string
String implements fmt.Stringer.
type UpdateMessagePollVote ¶
type UpdateMessagePollVote struct {
// Poll ID
PollID int64
// User ID
UserID int
// Chosen option(s)
Options [][]byte
}
UpdateMessagePollVote represents TL type `updateMessagePollVote#42f88f2c`. A specific user has voted in a poll
See https://core.telegram.org/constructor/updateMessagePollVote for reference.
func (*UpdateMessagePollVote) Decode ¶
func (u *UpdateMessagePollVote) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateMessagePollVote) Encode ¶
func (u *UpdateMessagePollVote) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateMessagePollVote) String ¶ added in v0.12.0
func (u *UpdateMessagePollVote) String() string
String implements fmt.Stringer.
type UpdateNewChannelMessage ¶
type UpdateNewChannelMessage struct {
// New message
Message MessageClass
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateNewChannelMessage represents TL type `updateNewChannelMessage#62ba04d9`. A new message was sent in a channel/supergroup¹
Links:
See https://core.telegram.org/constructor/updateNewChannelMessage for reference.
func (*UpdateNewChannelMessage) Decode ¶
func (u *UpdateNewChannelMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNewChannelMessage) Encode ¶
func (u *UpdateNewChannelMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNewChannelMessage) String ¶ added in v0.12.0
func (u *UpdateNewChannelMessage) String() string
String implements fmt.Stringer.
type UpdateNewEncryptedMessage ¶
type UpdateNewEncryptedMessage struct {
// Message
Message EncryptedMessageClass
// New qts value
Qts int
}
UpdateNewEncryptedMessage represents TL type `updateNewEncryptedMessage#12bcbd9a`. New encrypted message.
See https://core.telegram.org/constructor/updateNewEncryptedMessage for reference.
func (*UpdateNewEncryptedMessage) Decode ¶
func (u *UpdateNewEncryptedMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNewEncryptedMessage) Encode ¶
func (u *UpdateNewEncryptedMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNewEncryptedMessage) String ¶ added in v0.12.0
func (u *UpdateNewEncryptedMessage) String() string
String implements fmt.Stringer.
type UpdateNewMessage ¶
type UpdateNewMessage struct {
// Message
Message MessageClass
// New quantity of actions in a message box
Pts int
// Number of generated events
PtsCount int
}
UpdateNewMessage represents TL type `updateNewMessage#1f2b0afd`. New message in a private chat or in a legacy group¹.
Links:
See https://core.telegram.org/constructor/updateNewMessage for reference.
func (*UpdateNewMessage) Decode ¶
func (u *UpdateNewMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNewMessage) Encode ¶
func (u *UpdateNewMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNewMessage) String ¶ added in v0.12.0
func (u *UpdateNewMessage) String() string
String implements fmt.Stringer.
type UpdateNewScheduledMessage ¶
type UpdateNewScheduledMessage struct {
// Message
Message MessageClass
}
UpdateNewScheduledMessage represents TL type `updateNewScheduledMessage#39a51dfb`. A message was added to the schedule queue of a chat¹
Links:
See https://core.telegram.org/constructor/updateNewScheduledMessage for reference.
func (*UpdateNewScheduledMessage) Decode ¶
func (u *UpdateNewScheduledMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNewScheduledMessage) Encode ¶
func (u *UpdateNewScheduledMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNewScheduledMessage) String ¶ added in v0.12.0
func (u *UpdateNewScheduledMessage) String() string
String implements fmt.Stringer.
type UpdateNewStickerSet ¶
type UpdateNewStickerSet struct {
// The installed stickerset
Stickerset MessagesStickerSet
}
UpdateNewStickerSet represents TL type `updateNewStickerSet#688a30aa`. A new stickerset was installed
See https://core.telegram.org/constructor/updateNewStickerSet for reference.
func (*UpdateNewStickerSet) Decode ¶
func (u *UpdateNewStickerSet) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNewStickerSet) Encode ¶
func (u *UpdateNewStickerSet) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNewStickerSet) String ¶ added in v0.12.0
func (u *UpdateNewStickerSet) String() string
String implements fmt.Stringer.
type UpdateNotifySettings ¶
type UpdateNotifySettings struct {
// Nofication source
Peer NotifyPeerClass
// New notification settings
NotifySettings PeerNotifySettings
}
UpdateNotifySettings represents TL type `updateNotifySettings#bec268ef`. Changes in notification settings.
See https://core.telegram.org/constructor/updateNotifySettings for reference.
func (*UpdateNotifySettings) Decode ¶
func (u *UpdateNotifySettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateNotifySettings) Encode ¶
func (u *UpdateNotifySettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateNotifySettings) String ¶ added in v0.12.0
func (u *UpdateNotifySettings) String() string
String implements fmt.Stringer.
type UpdatePeerBlocked ¶
type UpdatePeerBlocked struct {
// The blocked peer
PeerID PeerClass
// Whether the peer was blocked or unblocked
Blocked bool
}
UpdatePeerBlocked represents TL type `updatePeerBlocked#246a4b22`. A peer was blocked
See https://core.telegram.org/constructor/updatePeerBlocked for reference.
func (*UpdatePeerBlocked) Decode ¶
func (u *UpdatePeerBlocked) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePeerBlocked) Encode ¶
func (u *UpdatePeerBlocked) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePeerBlocked) String ¶ added in v0.12.0
func (u *UpdatePeerBlocked) String() string
String implements fmt.Stringer.
type UpdatePeerLocated ¶
type UpdatePeerLocated struct {
// Geolocated peer list update
Peers []PeerLocatedClass
}
UpdatePeerLocated represents TL type `updatePeerLocated#b4afcfb0`. List of peers near you was updated
See https://core.telegram.org/constructor/updatePeerLocated for reference.
func (*UpdatePeerLocated) Decode ¶
func (u *UpdatePeerLocated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePeerLocated) Encode ¶
func (u *UpdatePeerLocated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePeerLocated) String ¶ added in v0.12.0
func (u *UpdatePeerLocated) String() string
String implements fmt.Stringer.
type UpdatePeerSettings ¶
type UpdatePeerSettings struct {
// The peer
Peer PeerClass
// Associated peer settings
Settings PeerSettings
}
UpdatePeerSettings represents TL type `updatePeerSettings#6a7e7366`. Settings of a certain peer have changed
See https://core.telegram.org/constructor/updatePeerSettings for reference.
func (*UpdatePeerSettings) Decode ¶
func (u *UpdatePeerSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePeerSettings) Encode ¶
func (u *UpdatePeerSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePeerSettings) String ¶ added in v0.12.0
func (u *UpdatePeerSettings) String() string
String implements fmt.Stringer.
type UpdatePhoneCall ¶
type UpdatePhoneCall struct {
// Phone call
PhoneCall PhoneCallClass
}
UpdatePhoneCall represents TL type `updatePhoneCall#ab0f6b1e`. An incoming phone call
See https://core.telegram.org/constructor/updatePhoneCall for reference.
func (*UpdatePhoneCall) Decode ¶
func (u *UpdatePhoneCall) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePhoneCall) Encode ¶
func (u *UpdatePhoneCall) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePhoneCall) String ¶ added in v0.12.0
func (u *UpdatePhoneCall) String() string
String implements fmt.Stringer.
type UpdatePhoneCallSignalingData ¶
type UpdatePhoneCallSignalingData struct {
// Phone call ID
PhoneCallID int64
// Signaling payload
Data []byte
}
UpdatePhoneCallSignalingData represents TL type `updatePhoneCallSignalingData#2661bf09`. Incoming phone call signaling payload
See https://core.telegram.org/constructor/updatePhoneCallSignalingData for reference.
func (*UpdatePhoneCallSignalingData) Decode ¶
func (u *UpdatePhoneCallSignalingData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePhoneCallSignalingData) Encode ¶
func (u *UpdatePhoneCallSignalingData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePhoneCallSignalingData) String ¶ added in v0.12.0
func (u *UpdatePhoneCallSignalingData) String() string
String implements fmt.Stringer.
type UpdatePinnedChannelMessages ¶
type UpdatePinnedChannelMessages struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the messages were pinned or unpinned
Pinned bool
// Channel ID
ChannelID int
// Messages
Messages []int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdatePinnedChannelMessages represents TL type `updatePinnedChannelMessages#8588878b`. Messages were pinned/unpinned in a channel/supergroup¹
Links:
See https://core.telegram.org/constructor/updatePinnedChannelMessages for reference.
func (*UpdatePinnedChannelMessages) Decode ¶
func (u *UpdatePinnedChannelMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePinnedChannelMessages) Encode ¶
func (u *UpdatePinnedChannelMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePinnedChannelMessages) SetPinned ¶
func (u *UpdatePinnedChannelMessages) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*UpdatePinnedChannelMessages) String ¶ added in v0.12.0
func (u *UpdatePinnedChannelMessages) String() string
String implements fmt.Stringer.
type UpdatePinnedDialogs ¶
type UpdatePinnedDialogs struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// New order of pinned dialogs
//
// Use SetOrder and GetOrder helpers.
Order []DialogPeerClass
}
UpdatePinnedDialogs represents TL type `updatePinnedDialogs#fa0f3ca2`. Pinned dialogs were updated
See https://core.telegram.org/constructor/updatePinnedDialogs for reference.
func (*UpdatePinnedDialogs) Decode ¶
func (u *UpdatePinnedDialogs) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePinnedDialogs) Encode ¶
func (u *UpdatePinnedDialogs) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePinnedDialogs) GetFolderID ¶
func (u *UpdatePinnedDialogs) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*UpdatePinnedDialogs) GetOrder ¶
func (u *UpdatePinnedDialogs) GetOrder() (value []DialogPeerClass, ok bool)
GetOrder returns value of Order conditional field and boolean which is true if field was set.
func (*UpdatePinnedDialogs) SetFolderID ¶
func (u *UpdatePinnedDialogs) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*UpdatePinnedDialogs) SetOrder ¶
func (u *UpdatePinnedDialogs) SetOrder(value []DialogPeerClass)
SetOrder sets value of Order conditional field.
func (*UpdatePinnedDialogs) String ¶ added in v0.12.0
func (u *UpdatePinnedDialogs) String() string
String implements fmt.Stringer.
type UpdatePinnedMessages ¶
type UpdatePinnedMessages struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the messages were pinned or unpinned
Pinned bool
// Peer
Peer PeerClass
// Message IDs
Messages []int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdatePinnedMessages represents TL type `updatePinnedMessages#ed85eab5`. Some messages were pinned in a chat
See https://core.telegram.org/constructor/updatePinnedMessages for reference.
func (*UpdatePinnedMessages) Decode ¶
func (u *UpdatePinnedMessages) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePinnedMessages) Encode ¶
func (u *UpdatePinnedMessages) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePinnedMessages) SetPinned ¶
func (u *UpdatePinnedMessages) SetPinned(value bool)
SetPinned sets value of Pinned conditional field.
func (*UpdatePinnedMessages) String ¶ added in v0.12.0
func (u *UpdatePinnedMessages) String() string
String implements fmt.Stringer.
type UpdatePrivacy ¶
type UpdatePrivacy struct {
// Peers to which the privacy rules apply
Key PrivacyKeyClass
// New privacy rules
Rules []PrivacyRuleClass
}
UpdatePrivacy represents TL type `updatePrivacy#ee3b272a`. Privacy rules were changed
See https://core.telegram.org/constructor/updatePrivacy for reference.
func (*UpdatePrivacy) Decode ¶
func (u *UpdatePrivacy) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePrivacy) Encode ¶
func (u *UpdatePrivacy) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePrivacy) String ¶ added in v0.12.0
func (u *UpdatePrivacy) String() string
String implements fmt.Stringer.
type UpdatePtsChanged ¶
type UpdatePtsChanged struct {
}
UpdatePtsChanged represents TL type `updatePtsChanged#3354678f`. Common message box sequence PTS¹ has changed, state has to be refetched using updates.getState²
Links:
See https://core.telegram.org/constructor/updatePtsChanged for reference.
func (*UpdatePtsChanged) Decode ¶
func (u *UpdatePtsChanged) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatePtsChanged) Encode ¶
func (u *UpdatePtsChanged) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatePtsChanged) String ¶ added in v0.12.0
func (u *UpdatePtsChanged) String() string
String implements fmt.Stringer.
type UpdateReadChannelDiscussionInbox ¶
type UpdateReadChannelDiscussionInbox struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Discussion group ID¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ChannelID int
// ID of the group message that started the thread¹ (message in linked discussion group)
//
// Links:
// 1) https://core.telegram.org/api/threads
TopMsgID int
// Message ID of latest read incoming message for this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
ReadMaxID int
// If set, contains the ID of the channel¹ that contains the post that started the comment thread² in the discussion group (channel_id)
//
// Links:
// 1) https://core.telegram.org/api/channel
// 2) https://core.telegram.org/api/threads
//
// Use SetBroadcastID and GetBroadcastID helpers.
BroadcastID int
// If set, contains the ID of the channel post that started the the comment thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetBroadcastPost and GetBroadcastPost helpers.
BroadcastPost int
}
UpdateReadChannelDiscussionInbox represents TL type `updateReadChannelDiscussionInbox#1cc7de54`. Incoming comments in a discussion thread¹ were marked as read
Links:
See https://core.telegram.org/constructor/updateReadChannelDiscussionInbox for reference.
func (*UpdateReadChannelDiscussionInbox) Decode ¶
func (u *UpdateReadChannelDiscussionInbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadChannelDiscussionInbox) Encode ¶
func (u *UpdateReadChannelDiscussionInbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadChannelDiscussionInbox) GetBroadcastID ¶
func (u *UpdateReadChannelDiscussionInbox) GetBroadcastID() (value int, ok bool)
GetBroadcastID returns value of BroadcastID conditional field and boolean which is true if field was set.
func (*UpdateReadChannelDiscussionInbox) GetBroadcastPost ¶
func (u *UpdateReadChannelDiscussionInbox) GetBroadcastPost() (value int, ok bool)
GetBroadcastPost returns value of BroadcastPost conditional field and boolean which is true if field was set.
func (*UpdateReadChannelDiscussionInbox) SetBroadcastID ¶
func (u *UpdateReadChannelDiscussionInbox) SetBroadcastID(value int)
SetBroadcastID sets value of BroadcastID conditional field.
func (*UpdateReadChannelDiscussionInbox) SetBroadcastPost ¶
func (u *UpdateReadChannelDiscussionInbox) SetBroadcastPost(value int)
SetBroadcastPost sets value of BroadcastPost conditional field.
func (*UpdateReadChannelDiscussionInbox) String ¶ added in v0.12.0
func (u *UpdateReadChannelDiscussionInbox) String() string
String implements fmt.Stringer.
type UpdateReadChannelDiscussionOutbox ¶
type UpdateReadChannelDiscussionOutbox struct {
// Supergroup ID¹
//
// Links:
// 1) https://core.telegram.org/api/channel
ChannelID int
// ID of the group message that started the thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
TopMsgID int
// Message ID of latest read outgoing message for this thread¹
//
// Links:
// 1) https://core.telegram.org/api/threads
ReadMaxID int
}
UpdateReadChannelDiscussionOutbox represents TL type `updateReadChannelDiscussionOutbox#4638a26c`. Outgoing comments in a discussion thread¹ were marked as read
Links:
See https://core.telegram.org/constructor/updateReadChannelDiscussionOutbox for reference.
func (*UpdateReadChannelDiscussionOutbox) Decode ¶
func (u *UpdateReadChannelDiscussionOutbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadChannelDiscussionOutbox) Encode ¶
func (u *UpdateReadChannelDiscussionOutbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadChannelDiscussionOutbox) String ¶ added in v0.12.0
func (u *UpdateReadChannelDiscussionOutbox) String() string
String implements fmt.Stringer.
type UpdateReadChannelInbox ¶
type UpdateReadChannelInbox struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Channel/supergroup ID
ChannelID int
// Position up to which all incoming messages are read.
MaxID int
// Count of messages weren't read yet
StillUnreadCount int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
}
UpdateReadChannelInbox represents TL type `updateReadChannelInbox#330b5424`. Incoming messages in a channel/supergroup¹ were read
Links:
See https://core.telegram.org/constructor/updateReadChannelInbox for reference.
func (*UpdateReadChannelInbox) Decode ¶
func (u *UpdateReadChannelInbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadChannelInbox) Encode ¶
func (u *UpdateReadChannelInbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadChannelInbox) GetFolderID ¶
func (u *UpdateReadChannelInbox) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*UpdateReadChannelInbox) SetFolderID ¶
func (u *UpdateReadChannelInbox) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*UpdateReadChannelInbox) String ¶ added in v0.12.0
func (u *UpdateReadChannelInbox) String() string
String implements fmt.Stringer.
type UpdateReadChannelOutbox ¶
type UpdateReadChannelOutbox struct {
// Channel/supergroup ID
ChannelID int
// Position up to which all outgoing messages are read.
MaxID int
}
UpdateReadChannelOutbox represents TL type `updateReadChannelOutbox#25d6c9c7`. Outgoing messages in a channel/supergroup¹ were read
Links:
See https://core.telegram.org/constructor/updateReadChannelOutbox for reference.
func (*UpdateReadChannelOutbox) Decode ¶
func (u *UpdateReadChannelOutbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadChannelOutbox) Encode ¶
func (u *UpdateReadChannelOutbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadChannelOutbox) String ¶ added in v0.12.0
func (u *UpdateReadChannelOutbox) String() string
String implements fmt.Stringer.
type UpdateReadFeaturedStickers ¶
type UpdateReadFeaturedStickers struct {
}
UpdateReadFeaturedStickers represents TL type `updateReadFeaturedStickers#571d2742`. Some featured stickers were marked as read
See https://core.telegram.org/constructor/updateReadFeaturedStickers for reference.
func (*UpdateReadFeaturedStickers) Decode ¶
func (u *UpdateReadFeaturedStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadFeaturedStickers) Encode ¶
func (u *UpdateReadFeaturedStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadFeaturedStickers) String ¶ added in v0.12.0
func (u *UpdateReadFeaturedStickers) String() string
String implements fmt.Stringer.
type UpdateReadHistoryInbox ¶
type UpdateReadHistoryInbox struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
// Peer
Peer PeerClass
// Maximum ID of messages read
MaxID int
// Number of messages that are still unread
StillUnreadCount int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateReadHistoryInbox represents TL type `updateReadHistoryInbox#9c974fdf`. Incoming messages were read
See https://core.telegram.org/constructor/updateReadHistoryInbox for reference.
func (*UpdateReadHistoryInbox) Decode ¶
func (u *UpdateReadHistoryInbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadHistoryInbox) Encode ¶
func (u *UpdateReadHistoryInbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadHistoryInbox) GetFolderID ¶
func (u *UpdateReadHistoryInbox) GetFolderID() (value int, ok bool)
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*UpdateReadHistoryInbox) SetFolderID ¶
func (u *UpdateReadHistoryInbox) SetFolderID(value int)
SetFolderID sets value of FolderID conditional field.
func (*UpdateReadHistoryInbox) String ¶ added in v0.12.0
func (u *UpdateReadHistoryInbox) String() string
String implements fmt.Stringer.
type UpdateReadHistoryOutbox ¶
type UpdateReadHistoryOutbox struct {
// Peer
Peer PeerClass
// Maximum ID of read outgoing messages
MaxID int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateReadHistoryOutbox represents TL type `updateReadHistoryOutbox#2f2f21bf`. Outgoing messages were read
See https://core.telegram.org/constructor/updateReadHistoryOutbox for reference.
func (*UpdateReadHistoryOutbox) Decode ¶
func (u *UpdateReadHistoryOutbox) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadHistoryOutbox) Encode ¶
func (u *UpdateReadHistoryOutbox) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadHistoryOutbox) String ¶ added in v0.12.0
func (u *UpdateReadHistoryOutbox) String() string
String implements fmt.Stringer.
type UpdateReadMessagesContents ¶
type UpdateReadMessagesContents struct {
// IDs of read messages
Messages []int
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateReadMessagesContents represents TL type `updateReadMessagesContents#68c13933`. Contents of messages in the common message box¹ were read
Links:
See https://core.telegram.org/constructor/updateReadMessagesContents for reference.
func (*UpdateReadMessagesContents) Decode ¶
func (u *UpdateReadMessagesContents) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateReadMessagesContents) Encode ¶
func (u *UpdateReadMessagesContents) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateReadMessagesContents) String ¶ added in v0.12.0
func (u *UpdateReadMessagesContents) String() string
String implements fmt.Stringer.
type UpdateRecentStickers ¶
type UpdateRecentStickers struct {
}
UpdateRecentStickers represents TL type `updateRecentStickers#9a422c20`. The recent sticker list was updated
See https://core.telegram.org/constructor/updateRecentStickers for reference.
func (*UpdateRecentStickers) Decode ¶
func (u *UpdateRecentStickers) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateRecentStickers) Encode ¶
func (u *UpdateRecentStickers) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateRecentStickers) String ¶ added in v0.12.0
func (u *UpdateRecentStickers) String() string
String implements fmt.Stringer.
type UpdateSavedGifs ¶
type UpdateSavedGifs struct {
}
UpdateSavedGifs represents TL type `updateSavedGifs#9375341e`. The saved gif list has changed, the client should refetch it using messages.getSavedGifs¹
Links:
See https://core.telegram.org/constructor/updateSavedGifs for reference.
func (*UpdateSavedGifs) Decode ¶
func (u *UpdateSavedGifs) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateSavedGifs) Encode ¶
func (u *UpdateSavedGifs) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateSavedGifs) String ¶ added in v0.12.0
func (u *UpdateSavedGifs) String() string
String implements fmt.Stringer.
type UpdateServiceNotification ¶
type UpdateServiceNotification struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// (boolTrue) if the message must be displayed in a popup.
Popup bool
// When was the notification receivedThe message must also be stored locally as part of the message history with the user id 777000 (Telegram Notifications).
//
// Use SetInboxDate and GetInboxDate helpers.
InboxDate int
// String, identical in format and contents to the type¹ field in API errors. Describes type of service message. It is acceptable to ignore repeated messages of the same type within a short period of time (15 minutes).
//
// Links:
// 1) https://core.telegram.org/api/errors#error-type
Type string
// Message text
Message string
// Media content (optional)
Media MessageMediaClass
// Message entities for styled text¹
//
// Links:
// 1) https://core.telegram.org/api/entities
Entities []MessageEntityClass
}
UpdateServiceNotification represents TL type `updateServiceNotification#ebe46819`. A service message for the user. The app must show the message to the user upon receiving this update. In case the popup parameter was passed, the text message must be displayed in a popup alert immediately upon receipt. It is recommended to handle the text as you would an ordinary message in terms of highlighting links, etc. The message must also be stored locally as part of the message history with the user id 777000 (Telegram Notifications).
See https://core.telegram.org/constructor/updateServiceNotification for reference.
func (*UpdateServiceNotification) Decode ¶
func (u *UpdateServiceNotification) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateServiceNotification) Encode ¶
func (u *UpdateServiceNotification) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateServiceNotification) GetInboxDate ¶
func (u *UpdateServiceNotification) GetInboxDate() (value int, ok bool)
GetInboxDate returns value of InboxDate conditional field and boolean which is true if field was set.
func (*UpdateServiceNotification) SetInboxDate ¶
func (u *UpdateServiceNotification) SetInboxDate(value int)
SetInboxDate sets value of InboxDate conditional field.
func (*UpdateServiceNotification) SetPopup ¶
func (u *UpdateServiceNotification) SetPopup(value bool)
SetPopup sets value of Popup conditional field.
func (*UpdateServiceNotification) String ¶ added in v0.12.0
func (u *UpdateServiceNotification) String() string
String implements fmt.Stringer.
type UpdateShort ¶
type UpdateShort struct {
// Update
Update UpdateClass
// Date of event
Date int
}
UpdateShort represents TL type `updateShort#78d4dec1`. Shortened constructor containing info on one update not requiring auxiliary data
See https://core.telegram.org/constructor/updateShort for reference.
func (*UpdateShort) Decode ¶
func (u *UpdateShort) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateShort) Encode ¶
func (u *UpdateShort) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateShort) String ¶ added in v0.12.0
func (u *UpdateShort) String() string
String implements fmt.Stringer.
type UpdateShortChatMessage ¶
type UpdateShortChatMessage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the message is outgoing
Out bool
// Whether we were mentioned in this message
Mentioned bool
// Whether the message contains some unread mentions
MediaUnread bool
// If true, the message is a silent message, no notifications should be triggered
Silent bool
// ID of the message
ID int
// ID of the sender of the message
FromID int
// ID of the chat where the message was sent
ChatID int
// Message
Message string
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// PTS count¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
// date¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Date int
// Info about a forwarded message
//
// Use SetFwdFrom and GetFwdFrom helpers.
FwdFrom MessageFwdHeader
// Info about the inline bot used to generate this message
//
// Use SetViaBotID and GetViaBotID helpers.
ViaBotID int
// Reply (thread) information
//
// Use SetReplyTo and GetReplyTo helpers.
ReplyTo MessageReplyHeader
// Entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
UpdateShortChatMessage represents TL type `updateShortChatMessage#402d5dbb`. Shortened constructor containing info on one new incoming text message from a chat
See https://core.telegram.org/constructor/updateShortChatMessage for reference.
func (*UpdateShortChatMessage) Decode ¶
func (u *UpdateShortChatMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateShortChatMessage) Encode ¶
func (u *UpdateShortChatMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateShortChatMessage) GetEntities ¶
func (u *UpdateShortChatMessage) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*UpdateShortChatMessage) GetFwdFrom ¶
func (u *UpdateShortChatMessage) GetFwdFrom() (value MessageFwdHeader, ok bool)
GetFwdFrom returns value of FwdFrom conditional field and boolean which is true if field was set.
func (*UpdateShortChatMessage) GetReplyTo ¶
func (u *UpdateShortChatMessage) GetReplyTo() (value MessageReplyHeader, ok bool)
GetReplyTo returns value of ReplyTo conditional field and boolean which is true if field was set.
func (*UpdateShortChatMessage) GetViaBotID ¶
func (u *UpdateShortChatMessage) GetViaBotID() (value int, ok bool)
GetViaBotID returns value of ViaBotID conditional field and boolean which is true if field was set.
func (*UpdateShortChatMessage) SetEntities ¶
func (u *UpdateShortChatMessage) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*UpdateShortChatMessage) SetFwdFrom ¶
func (u *UpdateShortChatMessage) SetFwdFrom(value MessageFwdHeader)
SetFwdFrom sets value of FwdFrom conditional field.
func (*UpdateShortChatMessage) SetMediaUnread ¶
func (u *UpdateShortChatMessage) SetMediaUnread(value bool)
SetMediaUnread sets value of MediaUnread conditional field.
func (*UpdateShortChatMessage) SetMentioned ¶
func (u *UpdateShortChatMessage) SetMentioned(value bool)
SetMentioned sets value of Mentioned conditional field.
func (*UpdateShortChatMessage) SetOut ¶
func (u *UpdateShortChatMessage) SetOut(value bool)
SetOut sets value of Out conditional field.
func (*UpdateShortChatMessage) SetReplyTo ¶
func (u *UpdateShortChatMessage) SetReplyTo(value MessageReplyHeader)
SetReplyTo sets value of ReplyTo conditional field.
func (*UpdateShortChatMessage) SetSilent ¶
func (u *UpdateShortChatMessage) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*UpdateShortChatMessage) SetViaBotID ¶
func (u *UpdateShortChatMessage) SetViaBotID(value int)
SetViaBotID sets value of ViaBotID conditional field.
func (*UpdateShortChatMessage) String ¶ added in v0.12.0
func (u *UpdateShortChatMessage) String() string
String implements fmt.Stringer.
type UpdateShortMessage ¶
type UpdateShortMessage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the message is outgoing
Out bool
// Whether we were mentioned in the message
Mentioned bool
// Whether there are some unread mentions in this message
MediaUnread bool
// If true, the message is a silent message, no notifications should be triggered
Silent bool
// The message ID
ID int
// The ID of the sender (if outgoing will be the ID of the destination) of the message
UserID int
// The message
Message string
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// PTS count¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
// date¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Date int
// Info about a forwarded message
//
// Use SetFwdFrom and GetFwdFrom helpers.
FwdFrom MessageFwdHeader
// Info about the inline bot used to generate this message
//
// Use SetViaBotID and GetViaBotID helpers.
ViaBotID int
// Reply and thread¹ information
//
// Links:
// 1) https://core.telegram.org/api/threads
//
// Use SetReplyTo and GetReplyTo helpers.
ReplyTo MessageReplyHeader
// Entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
UpdateShortMessage represents TL type `updateShortMessage#2296d2c8`. Info about a message sent to (received from) another user
See https://core.telegram.org/constructor/updateShortMessage for reference.
func (*UpdateShortMessage) Decode ¶
func (u *UpdateShortMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateShortMessage) Encode ¶
func (u *UpdateShortMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateShortMessage) GetEntities ¶
func (u *UpdateShortMessage) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*UpdateShortMessage) GetFwdFrom ¶
func (u *UpdateShortMessage) GetFwdFrom() (value MessageFwdHeader, ok bool)
GetFwdFrom returns value of FwdFrom conditional field and boolean which is true if field was set.
func (*UpdateShortMessage) GetReplyTo ¶
func (u *UpdateShortMessage) GetReplyTo() (value MessageReplyHeader, ok bool)
GetReplyTo returns value of ReplyTo conditional field and boolean which is true if field was set.
func (*UpdateShortMessage) GetViaBotID ¶
func (u *UpdateShortMessage) GetViaBotID() (value int, ok bool)
GetViaBotID returns value of ViaBotID conditional field and boolean which is true if field was set.
func (*UpdateShortMessage) SetEntities ¶
func (u *UpdateShortMessage) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*UpdateShortMessage) SetFwdFrom ¶
func (u *UpdateShortMessage) SetFwdFrom(value MessageFwdHeader)
SetFwdFrom sets value of FwdFrom conditional field.
func (*UpdateShortMessage) SetMediaUnread ¶
func (u *UpdateShortMessage) SetMediaUnread(value bool)
SetMediaUnread sets value of MediaUnread conditional field.
func (*UpdateShortMessage) SetMentioned ¶
func (u *UpdateShortMessage) SetMentioned(value bool)
SetMentioned sets value of Mentioned conditional field.
func (*UpdateShortMessage) SetOut ¶
func (u *UpdateShortMessage) SetOut(value bool)
SetOut sets value of Out conditional field.
func (*UpdateShortMessage) SetReplyTo ¶
func (u *UpdateShortMessage) SetReplyTo(value MessageReplyHeader)
SetReplyTo sets value of ReplyTo conditional field.
func (*UpdateShortMessage) SetSilent ¶
func (u *UpdateShortMessage) SetSilent(value bool)
SetSilent sets value of Silent conditional field.
func (*UpdateShortMessage) SetViaBotID ¶
func (u *UpdateShortMessage) SetViaBotID(value int)
SetViaBotID sets value of ViaBotID conditional field.
func (*UpdateShortMessage) String ¶ added in v0.12.0
func (u *UpdateShortMessage) String() string
String implements fmt.Stringer.
type UpdateShortSentMessage ¶
type UpdateShortSentMessage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the message is outgoing
Out bool
// ID of the sent message
ID int
// PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// PTS count¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
// date¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Date int
// Attached media
//
// Use SetMedia and GetMedia helpers.
Media MessageMediaClass
// Entities¹ for styled text
//
// Links:
// 1) https://core.telegram.org/api/entities
//
// Use SetEntities and GetEntities helpers.
Entities []MessageEntityClass
}
UpdateShortSentMessage represents TL type `updateShortSentMessage#11f1331c`. Shortened constructor containing info on one outgoing message to a contact (the destination chat has to be extracted from the method call that returned this object).
See https://core.telegram.org/constructor/updateShortSentMessage for reference.
func (*UpdateShortSentMessage) Decode ¶
func (u *UpdateShortSentMessage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateShortSentMessage) Encode ¶
func (u *UpdateShortSentMessage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateShortSentMessage) GetEntities ¶
func (u *UpdateShortSentMessage) GetEntities() (value []MessageEntityClass, ok bool)
GetEntities returns value of Entities conditional field and boolean which is true if field was set.
func (*UpdateShortSentMessage) GetMedia ¶
func (u *UpdateShortSentMessage) GetMedia() (value MessageMediaClass, ok bool)
GetMedia returns value of Media conditional field and boolean which is true if field was set.
func (*UpdateShortSentMessage) SetEntities ¶
func (u *UpdateShortSentMessage) SetEntities(value []MessageEntityClass)
SetEntities sets value of Entities conditional field.
func (*UpdateShortSentMessage) SetMedia ¶
func (u *UpdateShortSentMessage) SetMedia(value MessageMediaClass)
SetMedia sets value of Media conditional field.
func (*UpdateShortSentMessage) SetOut ¶
func (u *UpdateShortSentMessage) SetOut(value bool)
SetOut sets value of Out conditional field.
func (*UpdateShortSentMessage) String ¶ added in v0.12.0
func (u *UpdateShortSentMessage) String() string
String implements fmt.Stringer.
type UpdateStickerSets ¶
type UpdateStickerSets struct {
}
UpdateStickerSets represents TL type `updateStickerSets#43ae3dec`. Installed stickersets have changed, the client should refetch them using messages.getAllStickers¹
Links:
See https://core.telegram.org/constructor/updateStickerSets for reference.
func (*UpdateStickerSets) Decode ¶
func (u *UpdateStickerSets) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateStickerSets) Encode ¶
func (u *UpdateStickerSets) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateStickerSets) String ¶ added in v0.12.0
func (u *UpdateStickerSets) String() string
String implements fmt.Stringer.
type UpdateStickerSetsOrder ¶
type UpdateStickerSetsOrder struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the updated stickers are mask stickers
Masks bool
// New sticker order by sticker ID
Order []int64
}
UpdateStickerSetsOrder represents TL type `updateStickerSetsOrder#bb2d201`. The order of stickersets was changed
See https://core.telegram.org/constructor/updateStickerSetsOrder for reference.
func (*UpdateStickerSetsOrder) Decode ¶
func (u *UpdateStickerSetsOrder) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateStickerSetsOrder) Encode ¶
func (u *UpdateStickerSetsOrder) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateStickerSetsOrder) SetMasks ¶
func (u *UpdateStickerSetsOrder) SetMasks(value bool)
SetMasks sets value of Masks conditional field.
func (*UpdateStickerSetsOrder) String ¶ added in v0.12.0
func (u *UpdateStickerSetsOrder) String() string
String implements fmt.Stringer.
type UpdateTheme ¶
type UpdateTheme struct {
// Theme
Theme Theme
}
UpdateTheme represents TL type `updateTheme#8216fba3`. A cloud theme was updated
See https://core.telegram.org/constructor/updateTheme for reference.
func (*UpdateTheme) Decode ¶
func (u *UpdateTheme) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateTheme) Encode ¶
func (u *UpdateTheme) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateTheme) String ¶ added in v0.12.0
func (u *UpdateTheme) String() string
String implements fmt.Stringer.
type UpdateUserName ¶
type UpdateUserName struct {
// User identifier
UserID int
// New first name. Corresponds to the new value of real_first_name field of the userFull¹ constructor.
//
// Links:
// 1) https://core.telegram.org/constructor/userFull
FirstName string
// New last name. Corresponds to the new value of real_last_name field of the userFull¹ constructor.
//
// Links:
// 1) https://core.telegram.org/constructor/userFull
LastName string
// New username.Parameter added in Layer 18¹.
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-18
Username string
}
UpdateUserName represents TL type `updateUserName#a7332b73`. Changes the user's first name, last name and username.
See https://core.telegram.org/constructor/updateUserName for reference.
func (*UpdateUserName) Decode ¶
func (u *UpdateUserName) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateUserName) Encode ¶
func (u *UpdateUserName) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateUserName) String ¶ added in v0.12.0
func (u *UpdateUserName) String() string
String implements fmt.Stringer.
type UpdateUserPhone ¶
UpdateUserPhone represents TL type `updateUserPhone#12b9417b`. A user's phone number was changed
See https://core.telegram.org/constructor/updateUserPhone for reference.
func (*UpdateUserPhone) Decode ¶
func (u *UpdateUserPhone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateUserPhone) Encode ¶
func (u *UpdateUserPhone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateUserPhone) String ¶ added in v0.12.0
func (u *UpdateUserPhone) String() string
String implements fmt.Stringer.
type UpdateUserPhoto ¶
type UpdateUserPhoto struct {
// User identifier
UserID int
// Date of photo update.
Date int
// New profile photo
Photo UserProfilePhotoClass
// (boolTrue¹), if one of the previously used photos is set a profile photo.
//
// Links:
// 1) https://core.telegram.org/constructor/boolTrue
Previous bool
}
UpdateUserPhoto represents TL type `updateUserPhoto#95313b0c`. Change of contact's profile photo.
See https://core.telegram.org/constructor/updateUserPhoto for reference.
func (*UpdateUserPhoto) Decode ¶
func (u *UpdateUserPhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateUserPhoto) Encode ¶
func (u *UpdateUserPhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateUserPhoto) String ¶ added in v0.12.0
func (u *UpdateUserPhoto) String() string
String implements fmt.Stringer.
type UpdateUserStatus ¶
type UpdateUserStatus struct {
// User identifier
UserID int
// New status
Status UserStatusClass
}
UpdateUserStatus represents TL type `updateUserStatus#1bfbd823`. Contact status update.
See https://core.telegram.org/constructor/updateUserStatus for reference.
func (*UpdateUserStatus) Decode ¶
func (u *UpdateUserStatus) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateUserStatus) Encode ¶
func (u *UpdateUserStatus) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateUserStatus) String ¶ added in v0.12.0
func (u *UpdateUserStatus) String() string
String implements fmt.Stringer.
type UpdateUserTyping ¶
type UpdateUserTyping struct {
// User id
UserID int
// Action typeParam added in Layer 17¹.
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-17
Action SendMessageActionClass
}
UpdateUserTyping represents TL type `updateUserTyping#5c486927`. The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no repeated update received after 6 seconds, it should be considered that the user stopped doing whatever he's been doing.
See https://core.telegram.org/constructor/updateUserTyping for reference.
func (*UpdateUserTyping) Decode ¶
func (u *UpdateUserTyping) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateUserTyping) Encode ¶
func (u *UpdateUserTyping) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateUserTyping) String ¶ added in v0.12.0
func (u *UpdateUserTyping) String() string
String implements fmt.Stringer.
type UpdateWebPage ¶
type UpdateWebPage struct {
// Webpage preview
Webpage WebPageClass
// Event count after generation¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Number of events that were generated¹
//
// Links:
// 1) https://core.telegram.org/api/updates
PtsCount int
}
UpdateWebPage represents TL type `updateWebPage#7f891213`. An instant view¹ webpage preview was generated
Links:
See https://core.telegram.org/constructor/updateWebPage for reference.
func (*UpdateWebPage) Decode ¶
func (u *UpdateWebPage) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdateWebPage) Encode ¶
func (u *UpdateWebPage) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdateWebPage) String ¶ added in v0.12.0
func (u *UpdateWebPage) String() string
String implements fmt.Stringer.
type Updates ¶
type Updates struct {
// Updates field of Updates.
Updates []UpdateClass
// Users field of Updates.
Users []UserClass
// Chats field of Updates.
Chats []ChatClass
// Date field of Updates.
Date int
// Seq field of Updates.
Seq int
}
Updates represents TL type `updates#74ae4240`.
See https://core.telegram.org/constructor/updates for reference.
type UpdatesBox ¶
type UpdatesBox struct {
Updates UpdatesClass
}
Updates boxes the UpdatesClass providing a helper.
type UpdatesChannelDifference ¶
type UpdatesChannelDifference struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether there are more updates to be fetched using getDifference, starting from the provided pts
Final bool
// The PTS¹ from which to start getting updates the next time
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Clients are supposed to refetch the channel difference after timeout seconds have elapsed
//
// Use SetTimeout and GetTimeout helpers.
Timeout int
// New messages
NewMessages []MessageClass
// Other updates
OtherUpdates []UpdateClass
// Chats
Chats []ChatClass
// Users
Users []UserClass
}
UpdatesChannelDifference represents TL type `updates.channelDifference#2064674e`. The new updates
See https://core.telegram.org/constructor/updates.channelDifference for reference.
func (*UpdatesChannelDifference) Decode ¶
func (c *UpdatesChannelDifference) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesChannelDifference) Encode ¶
func (c *UpdatesChannelDifference) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesChannelDifference) GetTimeout ¶
func (c *UpdatesChannelDifference) GetTimeout() (value int, ok bool)
GetTimeout returns value of Timeout conditional field and boolean which is true if field was set.
func (*UpdatesChannelDifference) SetFinal ¶
func (c *UpdatesChannelDifference) SetFinal(value bool)
SetFinal sets value of Final conditional field.
func (*UpdatesChannelDifference) SetTimeout ¶
func (c *UpdatesChannelDifference) SetTimeout(value int)
SetTimeout sets value of Timeout conditional field.
func (*UpdatesChannelDifference) String ¶ added in v0.12.0
func (c *UpdatesChannelDifference) String() string
String implements fmt.Stringer.
type UpdatesChannelDifferenceBox ¶
type UpdatesChannelDifferenceBox struct {
ChannelDifference UpdatesChannelDifferenceClass
}
UpdatesChannelDifference boxes the UpdatesChannelDifferenceClass providing a helper.
type UpdatesChannelDifferenceClass ¶
type UpdatesChannelDifferenceClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UpdatesChannelDifferenceClass represents updates.ChannelDifference generic type.
See https://core.telegram.org/type/updates.ChannelDifference for reference.
Example:
g, err := DecodeUpdatesChannelDifference(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UpdatesChannelDifferenceEmpty: // updates.channelDifferenceEmpty#3e11affb
case *UpdatesChannelDifferenceTooLong: // updates.channelDifferenceTooLong#a4bcc6fe
case *UpdatesChannelDifference: // updates.channelDifference#2064674e
default: panic(v)
}
func DecodeUpdatesChannelDifference ¶
func DecodeUpdatesChannelDifference(buf *bin.Buffer) (UpdatesChannelDifferenceClass, error)
DecodeUpdatesChannelDifference implements binary de-serialization for UpdatesChannelDifferenceClass.
type UpdatesChannelDifferenceEmpty ¶
type UpdatesChannelDifferenceEmpty struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether there are more updates that must be fetched (always false)
Final bool
// The latest PTS¹
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// Clients are supposed to refetch the channel difference after timeout seconds have elapsed
//
// Use SetTimeout and GetTimeout helpers.
Timeout int
}
UpdatesChannelDifferenceEmpty represents TL type `updates.channelDifferenceEmpty#3e11affb`. There are no new updates
See https://core.telegram.org/constructor/updates.channelDifferenceEmpty for reference.
func (*UpdatesChannelDifferenceEmpty) Decode ¶
func (c *UpdatesChannelDifferenceEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesChannelDifferenceEmpty) Encode ¶
func (c *UpdatesChannelDifferenceEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesChannelDifferenceEmpty) GetTimeout ¶
func (c *UpdatesChannelDifferenceEmpty) GetTimeout() (value int, ok bool)
GetTimeout returns value of Timeout conditional field and boolean which is true if field was set.
func (*UpdatesChannelDifferenceEmpty) SetFinal ¶
func (c *UpdatesChannelDifferenceEmpty) SetFinal(value bool)
SetFinal sets value of Final conditional field.
func (*UpdatesChannelDifferenceEmpty) SetTimeout ¶
func (c *UpdatesChannelDifferenceEmpty) SetTimeout(value int)
SetTimeout sets value of Timeout conditional field.
func (*UpdatesChannelDifferenceEmpty) String ¶ added in v0.12.0
func (c *UpdatesChannelDifferenceEmpty) String() string
String implements fmt.Stringer.
type UpdatesChannelDifferenceTooLong ¶
type UpdatesChannelDifferenceTooLong struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether there are more updates that must be fetched (always false)
Final bool
// Clients are supposed to refetch the channel difference after timeout seconds have elapsed
//
// Use SetTimeout and GetTimeout helpers.
Timeout int
// Dialog containing the latest PTS¹ that can be used to reset the channel state
//
// Links:
// 1) https://core.telegram.org/api/updates
Dialog DialogClass
// The latest messages
Messages []MessageClass
// Chats from messages
Chats []ChatClass
// Users from messages
Users []UserClass
}
UpdatesChannelDifferenceTooLong represents TL type `updates.channelDifferenceTooLong#a4bcc6fe`. The provided pts + limit < remote pts. Simply, there are too many updates to be fetched (more than limit), the client has to resolve the update gap in one of the following ways:
See https://core.telegram.org/constructor/updates.channelDifferenceTooLong for reference.
func (*UpdatesChannelDifferenceTooLong) Decode ¶
func (c *UpdatesChannelDifferenceTooLong) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesChannelDifferenceTooLong) Encode ¶
func (c *UpdatesChannelDifferenceTooLong) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesChannelDifferenceTooLong) GetTimeout ¶
func (c *UpdatesChannelDifferenceTooLong) GetTimeout() (value int, ok bool)
GetTimeout returns value of Timeout conditional field and boolean which is true if field was set.
func (*UpdatesChannelDifferenceTooLong) SetFinal ¶
func (c *UpdatesChannelDifferenceTooLong) SetFinal(value bool)
SetFinal sets value of Final conditional field.
func (*UpdatesChannelDifferenceTooLong) SetTimeout ¶
func (c *UpdatesChannelDifferenceTooLong) SetTimeout(value int)
SetTimeout sets value of Timeout conditional field.
func (*UpdatesChannelDifferenceTooLong) String ¶ added in v0.12.0
func (c *UpdatesChannelDifferenceTooLong) String() string
String implements fmt.Stringer.
type UpdatesClass ¶
type UpdatesClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UpdatesClass represents Updates generic type.
See https://core.telegram.org/type/Updates for reference.
Example:
g, err := DecodeUpdates(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UpdatesTooLong: // updatesTooLong#e317af7e
case *UpdateShortMessage: // updateShortMessage#2296d2c8
case *UpdateShortChatMessage: // updateShortChatMessage#402d5dbb
case *UpdateShort: // updateShort#78d4dec1
case *UpdatesCombined: // updatesCombined#725b04c3
case *Updates: // updates#74ae4240
case *UpdateShortSentMessage: // updateShortSentMessage#11f1331c
default: panic(v)
}
func DecodeUpdates ¶
func DecodeUpdates(buf *bin.Buffer) (UpdatesClass, error)
DecodeUpdates implements binary de-serialization for UpdatesClass.
type UpdatesCombined ¶
type UpdatesCombined struct {
// List of updates
Updates []UpdateClass
// List of users mentioned in updates
Users []UserClass
// List of chats mentioned in updates
Chats []ChatClass
// Current date
Date int
// Value seq for the earliest update in a group
SeqStart int
// Value seq for the latest update in a group
Seq int
}
UpdatesCombined represents TL type `updatesCombined#725b04c3`. Constructor for a group of updates.
See https://core.telegram.org/constructor/updatesCombined for reference.
func (*UpdatesCombined) Decode ¶
func (u *UpdatesCombined) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesCombined) Encode ¶
func (u *UpdatesCombined) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesCombined) String ¶ added in v0.12.0
func (u *UpdatesCombined) String() string
String implements fmt.Stringer.
type UpdatesDifference ¶
type UpdatesDifference struct {
// List of new messages
NewMessages []MessageClass
// List of new encrypted secret chat messages
NewEncryptedMessages []EncryptedMessageClass
// List of updates
OtherUpdates []UpdateClass
// List of chats mentioned in events
Chats []ChatClass
// List of users mentioned in events
Users []UserClass
// Current state
State UpdatesState
}
UpdatesDifference represents TL type `updates.difference#f49ca0`. Full list of occurred events.
See https://core.telegram.org/constructor/updates.difference for reference.
func (*UpdatesDifference) Decode ¶
func (d *UpdatesDifference) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesDifference) Encode ¶
func (d *UpdatesDifference) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesDifference) String ¶ added in v0.12.0
func (d *UpdatesDifference) String() string
String implements fmt.Stringer.
type UpdatesDifferenceBox ¶
type UpdatesDifferenceBox struct {
Difference UpdatesDifferenceClass
}
UpdatesDifference boxes the UpdatesDifferenceClass providing a helper.
type UpdatesDifferenceClass ¶
type UpdatesDifferenceClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UpdatesDifferenceClass represents updates.Difference generic type.
See https://core.telegram.org/type/updates.Difference for reference.
Example:
g, err := DecodeUpdatesDifference(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UpdatesDifferenceEmpty: // updates.differenceEmpty#5d75a138
case *UpdatesDifference: // updates.difference#f49ca0
case *UpdatesDifferenceSlice: // updates.differenceSlice#a8fb1981
case *UpdatesDifferenceTooLong: // updates.differenceTooLong#4afe8f6d
default: panic(v)
}
func DecodeUpdatesDifference ¶
func DecodeUpdatesDifference(buf *bin.Buffer) (UpdatesDifferenceClass, error)
DecodeUpdatesDifference implements binary de-serialization for UpdatesDifferenceClass.
type UpdatesDifferenceEmpty ¶
UpdatesDifferenceEmpty represents TL type `updates.differenceEmpty#5d75a138`. No events.
See https://core.telegram.org/constructor/updates.differenceEmpty for reference.
func (*UpdatesDifferenceEmpty) Decode ¶
func (d *UpdatesDifferenceEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesDifferenceEmpty) Encode ¶
func (d *UpdatesDifferenceEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesDifferenceEmpty) String ¶ added in v0.12.0
func (d *UpdatesDifferenceEmpty) String() string
String implements fmt.Stringer.
type UpdatesDifferenceSlice ¶
type UpdatesDifferenceSlice struct {
// List of new messgaes
NewMessages []MessageClass
// New messages from the encrypted event sequence¹
//
// Links:
// 1) https://core.telegram.org/api/updates
NewEncryptedMessages []EncryptedMessageClass
// List of updates
OtherUpdates []UpdateClass
// List of chats mentioned in events
Chats []ChatClass
// List of users mentioned in events
Users []UserClass
// Intermediary state
IntermediateState UpdatesState
}
UpdatesDifferenceSlice represents TL type `updates.differenceSlice#a8fb1981`. Incomplete list of occurred events.
See https://core.telegram.org/constructor/updates.differenceSlice for reference.
func (*UpdatesDifferenceSlice) Decode ¶
func (d *UpdatesDifferenceSlice) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesDifferenceSlice) Encode ¶
func (d *UpdatesDifferenceSlice) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesDifferenceSlice) String ¶ added in v0.12.0
func (d *UpdatesDifferenceSlice) String() string
String implements fmt.Stringer.
type UpdatesDifferenceTooLong ¶
type UpdatesDifferenceTooLong struct {
// The new state to use.
Pts int
}
UpdatesDifferenceTooLong represents TL type `updates.differenceTooLong#4afe8f6d`. The difference is too long¹, and the specified state must be used to refetch updates.
Links:
See https://core.telegram.org/constructor/updates.differenceTooLong for reference.
func (*UpdatesDifferenceTooLong) Decode ¶
func (d *UpdatesDifferenceTooLong) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesDifferenceTooLong) Encode ¶
func (d *UpdatesDifferenceTooLong) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesDifferenceTooLong) String ¶ added in v0.12.0
func (d *UpdatesDifferenceTooLong) String() string
String implements fmt.Stringer.
type UpdatesGetChannelDifferenceRequest ¶
type UpdatesGetChannelDifferenceRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Set to true to skip some possibly unneeded updates and reduce server-side load
Force bool
// The channel
Channel InputChannelClass
// Messsage filter
Filter ChannelMessagesFilterClass
// Persistent timestamp (see updates¹)
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// How many updates to fetch, max 100000Ordinary (non-bot) users are supposed to pass 10-100
Limit int
}
UpdatesGetChannelDifferenceRequest represents TL type `updates.getChannelDifference#3173d78`. Returns the difference between the current state of updates of a certain channel and transmitted.
See https://core.telegram.org/method/updates.getChannelDifference for reference.
func (*UpdatesGetChannelDifferenceRequest) Decode ¶
func (g *UpdatesGetChannelDifferenceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesGetChannelDifferenceRequest) Encode ¶
func (g *UpdatesGetChannelDifferenceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesGetChannelDifferenceRequest) SetForce ¶
func (g *UpdatesGetChannelDifferenceRequest) SetForce(value bool)
SetForce sets value of Force conditional field.
func (*UpdatesGetChannelDifferenceRequest) String ¶ added in v0.12.0
func (g *UpdatesGetChannelDifferenceRequest) String() string
String implements fmt.Stringer.
type UpdatesGetDifferenceRequest ¶
type UpdatesGetDifferenceRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// PTS, see updates¹.
//
// Links:
// 1) https://core.telegram.org/api/updates
Pts int
// For fast updating: if provided and pts + pts_total_limit < remote pts, updates.differenceTooLong¹ will be returned.Simply tells the server to not return the difference if it is bigger than pts_total_limitIf the remote pts is too big (> ~4000000), this field will default to 1000000
//
// Links:
// 1) https://core.telegram.org/constructor/updates.differenceTooLong
//
// Use SetPtsTotalLimit and GetPtsTotalLimit helpers.
PtsTotalLimit int
// date, see updates¹.
//
// Links:
// 1) https://core.telegram.org/api/updates
Date int
// QTS, see updates¹.
//
// Links:
// 1) https://core.telegram.org/api/updates
Qts int
}
UpdatesGetDifferenceRequest represents TL type `updates.getDifference#25939651`. Get new updates¹.
Links:
See https://core.telegram.org/method/updates.getDifference for reference.
func (*UpdatesGetDifferenceRequest) Decode ¶
func (g *UpdatesGetDifferenceRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesGetDifferenceRequest) Encode ¶
func (g *UpdatesGetDifferenceRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesGetDifferenceRequest) GetPtsTotalLimit ¶
func (g *UpdatesGetDifferenceRequest) GetPtsTotalLimit() (value int, ok bool)
GetPtsTotalLimit returns value of PtsTotalLimit conditional field and boolean which is true if field was set.
func (*UpdatesGetDifferenceRequest) SetPtsTotalLimit ¶
func (g *UpdatesGetDifferenceRequest) SetPtsTotalLimit(value int)
SetPtsTotalLimit sets value of PtsTotalLimit conditional field.
func (*UpdatesGetDifferenceRequest) String ¶ added in v0.12.0
func (g *UpdatesGetDifferenceRequest) String() string
String implements fmt.Stringer.
type UpdatesGetStateRequest ¶
type UpdatesGetStateRequest struct {
}
UpdatesGetStateRequest represents TL type `updates.getState#edd4882a`. Returns a current state of updates.
See https://core.telegram.org/method/updates.getState for reference.
func (*UpdatesGetStateRequest) Decode ¶
func (g *UpdatesGetStateRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesGetStateRequest) Encode ¶
func (g *UpdatesGetStateRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesGetStateRequest) String ¶ added in v0.12.0
func (g *UpdatesGetStateRequest) String() string
String implements fmt.Stringer.
type UpdatesState ¶
type UpdatesState struct {
// Number of events occured in a text box
Pts int
// Position in a sequence of updates in secret chats. For further detailes refer to article secret chats¹Parameter was added in eigth layer².
//
// Links:
// 1) https://core.telegram.org/api/end-to-end
// 2) https://core.telegram.org/api/layers#layer-8
Qts int
// Date of condition
Date int
// Number of sent updates
Seq int
// Number of unread messages
UnreadCount int
}
UpdatesState represents TL type `updates.state#a56c2a3e`. Updates state.
See https://core.telegram.org/constructor/updates.state for reference.
func (*UpdatesState) Decode ¶
func (s *UpdatesState) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesState) Encode ¶
func (s *UpdatesState) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesState) String ¶ added in v0.12.0
func (s *UpdatesState) String() string
String implements fmt.Stringer.
type UpdatesTooLong ¶
type UpdatesTooLong struct {
}
UpdatesTooLong represents TL type `updatesTooLong#e317af7e`. Too many updates, it is necessary to execute updates.getDifference¹.
Links:
See https://core.telegram.org/constructor/updatesTooLong for reference.
func (*UpdatesTooLong) Decode ¶
func (u *UpdatesTooLong) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UpdatesTooLong) Encode ¶
func (u *UpdatesTooLong) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UpdatesTooLong) String ¶ added in v0.12.0
func (u *UpdatesTooLong) String() string
String implements fmt.Stringer.
type UploadCdnFile ¶
type UploadCdnFile struct {
// The data
Bytes []byte
}
UploadCdnFile represents TL type `upload.cdnFile#a99fca4f`. Represent a chunk of a CDN¹ file.
Links:
See https://core.telegram.org/constructor/upload.cdnFile for reference.
func (*UploadCdnFile) Decode ¶
func (c *UploadCdnFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadCdnFile) Encode ¶
func (c *UploadCdnFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadCdnFile) String ¶ added in v0.12.0
func (c *UploadCdnFile) String() string
String implements fmt.Stringer.
type UploadCdnFileBox ¶
type UploadCdnFileBox struct {
CdnFile UploadCdnFileClass
}
UploadCdnFile boxes the UploadCdnFileClass providing a helper.
type UploadCdnFileClass ¶
type UploadCdnFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UploadCdnFileClass represents upload.CdnFile generic type.
See https://core.telegram.org/type/upload.CdnFile for reference.
Example:
g, err := DecodeUploadCdnFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UploadCdnFileReuploadNeeded: // upload.cdnFileReuploadNeeded#eea8e46e
case *UploadCdnFile: // upload.cdnFile#a99fca4f
default: panic(v)
}
func DecodeUploadCdnFile ¶
func DecodeUploadCdnFile(buf *bin.Buffer) (UploadCdnFileClass, error)
DecodeUploadCdnFile implements binary de-serialization for UploadCdnFileClass.
type UploadCdnFileReuploadNeeded ¶
type UploadCdnFileReuploadNeeded struct {
// Request token (see CDN¹)
//
// Links:
// 1) https://core.telegram.org/cdn
RequestToken []byte
}
UploadCdnFileReuploadNeeded represents TL type `upload.cdnFileReuploadNeeded#eea8e46e`. The file was cleared from the temporary RAM cache of the CDN¹ and has to be reuploaded.
Links:
See https://core.telegram.org/constructor/upload.cdnFileReuploadNeeded for reference.
func (*UploadCdnFileReuploadNeeded) Decode ¶
func (c *UploadCdnFileReuploadNeeded) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadCdnFileReuploadNeeded) Encode ¶
func (c *UploadCdnFileReuploadNeeded) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadCdnFileReuploadNeeded) String ¶ added in v0.12.0
func (c *UploadCdnFileReuploadNeeded) String() string
String implements fmt.Stringer.
type UploadFile ¶
type UploadFile struct {
// File type
Type StorageFileTypeClass
// Modification type
Mtime int
// Binary data, file content
Bytes []byte
}
UploadFile represents TL type `upload.file#96a18d5`. File content.
See https://core.telegram.org/constructor/upload.file for reference.
func (*UploadFile) Decode ¶
func (f *UploadFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadFile) Encode ¶
func (f *UploadFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadFile) String ¶ added in v0.12.0
func (f *UploadFile) String() string
String implements fmt.Stringer.
type UploadFileBox ¶
type UploadFileBox struct {
File UploadFileClass
}
UploadFile boxes the UploadFileClass providing a helper.
type UploadFileCdnRedirect ¶
type UploadFileCdnRedirect struct {
// CDN DC¹ ID
//
// Links:
// 1) https://core.telegram.org/cdn
DCID int
// File token (see CDN files¹)
//
// Links:
// 1) https://core.telegram.org/cdn
FileToken []byte
// Encryption key (see CDN files¹)
//
// Links:
// 1) https://core.telegram.org/cdn
EncryptionKey []byte
// Encryption IV (see CDN files¹)
//
// Links:
// 1) https://core.telegram.org/cdn
EncryptionIv []byte
// File hashes (see CDN files¹)
//
// Links:
// 1) https://core.telegram.org/cdn
FileHashes []FileHash
}
UploadFileCdnRedirect represents TL type `upload.fileCdnRedirect#f18cda44`. The file must be downloaded from a CDN DC¹.
Links:
See https://core.telegram.org/constructor/upload.fileCdnRedirect for reference.
func (*UploadFileCdnRedirect) Decode ¶
func (f *UploadFileCdnRedirect) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadFileCdnRedirect) Encode ¶
func (f *UploadFileCdnRedirect) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadFileCdnRedirect) String ¶ added in v0.12.0
func (f *UploadFileCdnRedirect) String() string
String implements fmt.Stringer.
type UploadFileClass ¶
type UploadFileClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UploadFileClass represents upload.File generic type.
See https://core.telegram.org/type/upload.File for reference.
Example:
g, err := DecodeUploadFile(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UploadFile: // upload.file#96a18d5
case *UploadFileCdnRedirect: // upload.fileCdnRedirect#f18cda44
default: panic(v)
}
func DecodeUploadFile ¶
func DecodeUploadFile(buf *bin.Buffer) (UploadFileClass, error)
DecodeUploadFile implements binary de-serialization for UploadFileClass.
type UploadGetCdnFileHashesRequest ¶
type UploadGetCdnFileHashesRequest struct {
// File
FileToken []byte
// Offset from which to start getting hashes
Offset int
}
UploadGetCdnFileHashesRequest represents TL type `upload.getCdnFileHashes#4da54231`. Get SHA256 hashes for verifying downloaded CDN¹ files
Links:
See https://core.telegram.org/method/upload.getCdnFileHashes for reference.
func (*UploadGetCdnFileHashesRequest) Decode ¶
func (g *UploadGetCdnFileHashesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadGetCdnFileHashesRequest) Encode ¶
func (g *UploadGetCdnFileHashesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadGetCdnFileHashesRequest) String ¶ added in v0.12.0
func (g *UploadGetCdnFileHashesRequest) String() string
String implements fmt.Stringer.
type UploadGetCdnFileRequest ¶
type UploadGetCdnFileRequest struct {
// File token
FileToken []byte
// Offset of chunk to download
Offset int
// Length of chunk to download
Limit int
}
UploadGetCdnFileRequest represents TL type `upload.getCdnFile#2000bcc3`. Download a CDN¹ file.
Links:
See https://core.telegram.org/method/upload.getCdnFile for reference.
func (*UploadGetCdnFileRequest) Decode ¶
func (g *UploadGetCdnFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadGetCdnFileRequest) Encode ¶
func (g *UploadGetCdnFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadGetCdnFileRequest) String ¶ added in v0.12.0
func (g *UploadGetCdnFileRequest) String() string
String implements fmt.Stringer.
type UploadGetFileHashesRequest ¶
type UploadGetFileHashesRequest struct {
// File
Location InputFileLocationClass
// Offset from which to get file hashes
Offset int
}
UploadGetFileHashesRequest represents TL type `upload.getFileHashes#c7025931`. Get SHA256 hashes for verifying downloaded files
See https://core.telegram.org/method/upload.getFileHashes for reference.
func (*UploadGetFileHashesRequest) Decode ¶
func (g *UploadGetFileHashesRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadGetFileHashesRequest) Encode ¶
func (g *UploadGetFileHashesRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadGetFileHashesRequest) String ¶ added in v0.12.0
func (g *UploadGetFileHashesRequest) String() string
String implements fmt.Stringer.
type UploadGetFileRequest ¶
type UploadGetFileRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Disable some checks on limit and offset values, useful for example to stream videos by keyframes
Precise bool
// Whether the current client supports CDN downloads¹
//
// Links:
// 1) https://core.telegram.org/cdn
CDNSupported bool
// File location
Location InputFileLocationClass
// Number of bytes to be skipped
Offset int
// Number of bytes to be returned
Limit int
}
UploadGetFileRequest represents TL type `upload.getFile#b15a9afc`. Returns content of a whole file or its part.
See https://core.telegram.org/method/upload.getFile for reference.
func (*UploadGetFileRequest) Decode ¶
func (g *UploadGetFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadGetFileRequest) Encode ¶
func (g *UploadGetFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadGetFileRequest) SetCDNSupported ¶
func (g *UploadGetFileRequest) SetCDNSupported(value bool)
SetCDNSupported sets value of CDNSupported conditional field.
func (*UploadGetFileRequest) SetPrecise ¶
func (g *UploadGetFileRequest) SetPrecise(value bool)
SetPrecise sets value of Precise conditional field.
func (*UploadGetFileRequest) String ¶ added in v0.12.0
func (g *UploadGetFileRequest) String() string
String implements fmt.Stringer.
type UploadGetWebFileRequest ¶
type UploadGetWebFileRequest struct {
// Location field of UploadGetWebFileRequest.
Location InputWebFileLocationClass
// Offset field of UploadGetWebFileRequest.
Offset int
// Limit field of UploadGetWebFileRequest.
Limit int
}
UploadGetWebFileRequest represents TL type `upload.getWebFile#24e6818d`.
See https://core.telegram.org/method/upload.getWebFile for reference.
func (*UploadGetWebFileRequest) Decode ¶
func (g *UploadGetWebFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadGetWebFileRequest) Encode ¶
func (g *UploadGetWebFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadGetWebFileRequest) String ¶ added in v0.12.0
func (g *UploadGetWebFileRequest) String() string
String implements fmt.Stringer.
type UploadReuploadCdnFileRequest ¶
type UploadReuploadCdnFileRequest struct {
// File token
FileToken []byte
// Request token
RequestToken []byte
}
UploadReuploadCdnFileRequest represents TL type `upload.reuploadCdnFile#9b2754a8`. Request a reupload of a certain file to a CDN DC¹.
Links:
See https://core.telegram.org/method/upload.reuploadCdnFile for reference.
func (*UploadReuploadCdnFileRequest) Decode ¶
func (r *UploadReuploadCdnFileRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadReuploadCdnFileRequest) Encode ¶
func (r *UploadReuploadCdnFileRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadReuploadCdnFileRequest) String ¶ added in v0.12.0
func (r *UploadReuploadCdnFileRequest) String() string
String implements fmt.Stringer.
type UploadSaveBigFilePartRequest ¶
type UploadSaveBigFilePartRequest struct {
// Random file id, created by the client
FileID int64
// Part sequence number
FilePart int
// Total number of parts
FileTotalParts int
// Binary data, part contents
Bytes []byte
}
UploadSaveBigFilePartRequest represents TL type `upload.saveBigFilePart#de7b673d`. Saves a part of a large file (over 10Mb in size) to be later passed to one of the methods.
See https://core.telegram.org/method/upload.saveBigFilePart for reference.
func (*UploadSaveBigFilePartRequest) Decode ¶
func (s *UploadSaveBigFilePartRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadSaveBigFilePartRequest) Encode ¶
func (s *UploadSaveBigFilePartRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadSaveBigFilePartRequest) String ¶ added in v0.12.0
func (s *UploadSaveBigFilePartRequest) String() string
String implements fmt.Stringer.
type UploadSaveFilePartRequest ¶
type UploadSaveFilePartRequest struct {
// Random file identifier created by the client
FileID int64
// Numerical order of a part
FilePart int
// Binary data, contend of a part
Bytes []byte
}
UploadSaveFilePartRequest represents TL type `upload.saveFilePart#b304a621`. Saves a part of file for futher sending to one of the methods.
See https://core.telegram.org/method/upload.saveFilePart for reference.
func (*UploadSaveFilePartRequest) Decode ¶
func (s *UploadSaveFilePartRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadSaveFilePartRequest) Encode ¶
func (s *UploadSaveFilePartRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadSaveFilePartRequest) String ¶ added in v0.12.0
func (s *UploadSaveFilePartRequest) String() string
String implements fmt.Stringer.
type UploadWebFile ¶
type UploadWebFile struct {
// File size
Size int
// Mime type
MimeType string
// File type
FileType StorageFileTypeClass
// Modified time
Mtime int
// Data
Bytes []byte
}
UploadWebFile represents TL type `upload.webFile#21e753bc`. Represents a chunk of an HTTP webfile¹ downloaded through telegram's secure MTProto servers
Links:
See https://core.telegram.org/constructor/upload.webFile for reference.
func (*UploadWebFile) Decode ¶
func (w *UploadWebFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UploadWebFile) Encode ¶
func (w *UploadWebFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UploadWebFile) String ¶ added in v0.12.0
func (w *UploadWebFile) String() string
String implements fmt.Stringer.
type UrlAuthResultAccepted ¶
type UrlAuthResultAccepted struct {
// The URL name of the website on which the user has logged in.
URL string
}
UrlAuthResultAccepted represents TL type `urlAuthResultAccepted#8f8c0e4e`. Details about an accepted authorization request, for more info click here »¹
Links:
See https://core.telegram.org/constructor/urlAuthResultAccepted for reference.
func (*UrlAuthResultAccepted) Decode ¶
func (u *UrlAuthResultAccepted) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UrlAuthResultAccepted) Encode ¶
func (u *UrlAuthResultAccepted) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UrlAuthResultAccepted) String ¶ added in v0.12.0
func (u *UrlAuthResultAccepted) String() string
String implements fmt.Stringer.
type UrlAuthResultBox ¶
type UrlAuthResultBox struct {
UrlAuthResult UrlAuthResultClass
}
UrlAuthResult boxes the UrlAuthResultClass providing a helper.
type UrlAuthResultClass ¶
type UrlAuthResultClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UrlAuthResultClass represents UrlAuthResult generic type.
See https://core.telegram.org/type/UrlAuthResult for reference.
Example:
g, err := DecodeUrlAuthResult(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UrlAuthResultRequest: // urlAuthResultRequest#92d33a0e
case *UrlAuthResultAccepted: // urlAuthResultAccepted#8f8c0e4e
case *UrlAuthResultDefault: // urlAuthResultDefault#a9d6db1f
default: panic(v)
}
func DecodeUrlAuthResult ¶
func DecodeUrlAuthResult(buf *bin.Buffer) (UrlAuthResultClass, error)
DecodeUrlAuthResult implements binary de-serialization for UrlAuthResultClass.
type UrlAuthResultDefault ¶
type UrlAuthResultDefault struct {
}
UrlAuthResultDefault represents TL type `urlAuthResultDefault#a9d6db1f`. Details about an accepted authorization request, for more info click here »¹
Links:
See https://core.telegram.org/constructor/urlAuthResultDefault for reference.
func (*UrlAuthResultDefault) Decode ¶
func (u *UrlAuthResultDefault) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UrlAuthResultDefault) Encode ¶
func (u *UrlAuthResultDefault) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UrlAuthResultDefault) String ¶ added in v0.12.0
func (u *UrlAuthResultDefault) String() string
String implements fmt.Stringer.
type UrlAuthResultRequest ¶
type UrlAuthResultRequest struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether the bot would like to send messages to the user
RequestWriteAccess bool
// Username of a bot, which will be used for user authorization. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See Linking your domain to the bot¹ for more details.
//
// Links:
// 1) https://core.telegram.org/widgets/login#linking-your-domain-to-the-bot
Bot UserClass
// The domain name of the website on which the user will log in.
Domain string
}
UrlAuthResultRequest represents TL type `urlAuthResultRequest#92d33a0e`. Details about the authorization request, for more info click here »¹
Links:
See https://core.telegram.org/constructor/urlAuthResultRequest for reference.
func (*UrlAuthResultRequest) Decode ¶
func (u *UrlAuthResultRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UrlAuthResultRequest) Encode ¶
func (u *UrlAuthResultRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UrlAuthResultRequest) SetRequestWriteAccess ¶
func (u *UrlAuthResultRequest) SetRequestWriteAccess(value bool)
SetRequestWriteAccess sets value of RequestWriteAccess conditional field.
func (*UrlAuthResultRequest) String ¶ added in v0.12.0
func (u *UrlAuthResultRequest) String() string
String implements fmt.Stringer.
type User ¶
type User struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this user indicates the currently logged in user
Self bool
// Whether this user is a contact
Contact bool
// Whether this user is a mutual contact
MutualContact bool
// Whether the account of this user was deleted
Deleted bool
// Is this user a bot?
Bot bool
// Can the bot see all messages in groups?
BotChatHistory bool
// Can the bot be added to groups?
BotNochats bool
// Whether this user is verified
Verified bool
// Access to this user must be restricted for the reason specified in restriction_reason
Restricted bool
// See min¹
//
// Links:
// 1) https://core.telegram.org/api/min
Min bool
// Whether the bot can request our geolocation in inline mode
BotInlineGeo bool
// Whether this is an official support user
Support bool
// This may be a scam user
Scam bool
// If set, the profile picture for this user should be refetched
ApplyMinPhoto bool
// ID of the user
ID int
// Access hash of the user
//
// Use SetAccessHash and GetAccessHash helpers.
AccessHash int64
// First name
//
// Use SetFirstName and GetFirstName helpers.
FirstName string
// Last name
//
// Use SetLastName and GetLastName helpers.
LastName string
// Username
//
// Use SetUsername and GetUsername helpers.
Username string
// Phone number
//
// Use SetPhone and GetPhone helpers.
Phone string
// Profile picture of user
//
// Use SetPhoto and GetPhoto helpers.
Photo UserProfilePhotoClass
// Online status of user
//
// Use SetStatus and GetStatus helpers.
Status UserStatusClass
// Version of the bot_info field in userFull¹, incremented every time it changes
//
// Links:
// 1) https://core.telegram.org/constructor/userFull
//
// Use SetBotInfoVersion and GetBotInfoVersion helpers.
BotInfoVersion int
// Contains the reason why access to this user must be restricted.
//
// Use SetRestrictionReason and GetRestrictionReason helpers.
RestrictionReason []RestrictionReason
// Inline placeholder for this inline bot
//
// Use SetBotInlinePlaceholder and GetBotInlinePlaceholder helpers.
BotInlinePlaceholder string
// Language code of the user
//
// Use SetLangCode and GetLangCode helpers.
LangCode string
}
User represents TL type `user#938458c1`. Indicates info about a certain user
See https://core.telegram.org/constructor/user for reference.
func (*User) GetAccessHash ¶
GetAccessHash returns value of AccessHash conditional field and boolean which is true if field was set.
func (*User) GetBotInfoVersion ¶
GetBotInfoVersion returns value of BotInfoVersion conditional field and boolean which is true if field was set.
func (*User) GetBotInlinePlaceholder ¶
GetBotInlinePlaceholder returns value of BotInlinePlaceholder conditional field and boolean which is true if field was set.
func (*User) GetFirstName ¶
GetFirstName returns value of FirstName conditional field and boolean which is true if field was set.
func (*User) GetLangCode ¶
GetLangCode returns value of LangCode conditional field and boolean which is true if field was set.
func (*User) GetLastName ¶
GetLastName returns value of LastName conditional field and boolean which is true if field was set.
func (*User) GetPhone ¶
GetPhone returns value of Phone conditional field and boolean which is true if field was set.
func (*User) GetPhoto ¶
func (u *User) GetPhoto() (value UserProfilePhotoClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*User) GetRestrictionReason ¶
func (u *User) GetRestrictionReason() (value []RestrictionReason, ok bool)
GetRestrictionReason returns value of RestrictionReason conditional field and boolean which is true if field was set.
func (*User) GetStatus ¶
func (u *User) GetStatus() (value UserStatusClass, ok bool)
GetStatus returns value of Status conditional field and boolean which is true if field was set.
func (*User) GetUsername ¶
GetUsername returns value of Username conditional field and boolean which is true if field was set.
func (*User) SetAccessHash ¶
SetAccessHash sets value of AccessHash conditional field.
func (*User) SetApplyMinPhoto ¶
SetApplyMinPhoto sets value of ApplyMinPhoto conditional field.
func (*User) SetBotChatHistory ¶
SetBotChatHistory sets value of BotChatHistory conditional field.
func (*User) SetBotInfoVersion ¶
SetBotInfoVersion sets value of BotInfoVersion conditional field.
func (*User) SetBotInlineGeo ¶
SetBotInlineGeo sets value of BotInlineGeo conditional field.
func (*User) SetBotInlinePlaceholder ¶
SetBotInlinePlaceholder sets value of BotInlinePlaceholder conditional field.
func (*User) SetBotNochats ¶
SetBotNochats sets value of BotNochats conditional field.
func (*User) SetContact ¶
SetContact sets value of Contact conditional field.
func (*User) SetDeleted ¶
SetDeleted sets value of Deleted conditional field.
func (*User) SetFirstName ¶
SetFirstName sets value of FirstName conditional field.
func (*User) SetLangCode ¶
SetLangCode sets value of LangCode conditional field.
func (*User) SetLastName ¶
SetLastName sets value of LastName conditional field.
func (*User) SetMutualContact ¶
SetMutualContact sets value of MutualContact conditional field.
func (*User) SetPhoto ¶
func (u *User) SetPhoto(value UserProfilePhotoClass)
SetPhoto sets value of Photo conditional field.
func (*User) SetRestricted ¶
SetRestricted sets value of Restricted conditional field.
func (*User) SetRestrictionReason ¶
func (u *User) SetRestrictionReason(value []RestrictionReason)
SetRestrictionReason sets value of RestrictionReason conditional field.
func (*User) SetStatus ¶
func (u *User) SetStatus(value UserStatusClass)
SetStatus sets value of Status conditional field.
func (*User) SetSupport ¶
SetSupport sets value of Support conditional field.
func (*User) SetUsername ¶
SetUsername sets value of Username conditional field.
func (*User) SetVerified ¶
SetVerified sets value of Verified conditional field.
type UserBox ¶
type UserBox struct {
User UserClass
}
User boxes the UserClass providing a helper.
type UserClass ¶
type UserClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UserClass represents User generic type.
See https://core.telegram.org/type/User for reference.
Example:
g, err := DecodeUser(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UserEmpty: // userEmpty#200250ba
case *User: // user#938458c1
default: panic(v)
}
type UserClassVector ¶ added in v0.8.0
type UserClassVector struct {
// Elements of Vector<User>
Elems []UserClass
}
UserClassVector is a box for Vector<User>
func (*UserClassVector) Decode ¶ added in v0.8.0
func (vec *UserClassVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserClassVector) Encode ¶ added in v0.8.0
func (vec *UserClassVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserClassVector) String ¶ added in v0.12.0
func (vec *UserClassVector) String() string
String implements fmt.Stringer.
type UserEmpty ¶
type UserEmpty struct {
// User identifier or 0
ID int
}
UserEmpty represents TL type `userEmpty#200250ba`. Empty constructor, non-existent user.
See https://core.telegram.org/constructor/userEmpty for reference.
type UserFull ¶
type UserFull struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether you have blocked this user
Blocked bool
// Whether this user can make VoIP calls
PhoneCallsAvailable bool
// Whether this user's privacy settings allow you to call him
PhoneCallsPrivate bool
// Whether you can pin messages in the chat with this user, you can do this only for a chat with yourself
CanPinMessage bool
// Whether scheduled messages¹ are available
//
// Links:
// 1) https://core.telegram.org/api/scheduled-messages
HasScheduled bool
// Whether the user can receive video calls
VideoCallsAvailable bool
// Remaining user info
User UserClass
// Bio of the user
//
// Use SetAbout and GetAbout helpers.
About string
// Peer settings
Settings PeerSettings
// Profile photo
//
// Use SetProfilePhoto and GetProfilePhoto helpers.
ProfilePhoto PhotoClass
// Notification settings
NotifySettings PeerNotifySettings
// For bots, info about the bot (bot commands, etc)
//
// Use SetBotInfo and GetBotInfo helpers.
BotInfo BotInfo
// Message ID of the last pinned message¹
//
// Links:
// 1) https://core.telegram.org/api/pin
//
// Use SetPinnedMsgID and GetPinnedMsgID helpers.
PinnedMsgID int
// Chats in common with this user
CommonChatsCount int
// Peer folder ID, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/folders#peer-folders
//
// Use SetFolderID and GetFolderID helpers.
FolderID int
}
UserFull represents TL type `userFull#edf17c12`. Extended user info
See https://core.telegram.org/constructor/userFull for reference.
func (*UserFull) GetAbout ¶
GetAbout returns value of About conditional field and boolean which is true if field was set.
func (*UserFull) GetBotInfo ¶
GetBotInfo returns value of BotInfo conditional field and boolean which is true if field was set.
func (*UserFull) GetFolderID ¶
GetFolderID returns value of FolderID conditional field and boolean which is true if field was set.
func (*UserFull) GetPinnedMsgID ¶
GetPinnedMsgID returns value of PinnedMsgID conditional field and boolean which is true if field was set.
func (*UserFull) GetProfilePhoto ¶
func (u *UserFull) GetProfilePhoto() (value PhotoClass, ok bool)
GetProfilePhoto returns value of ProfilePhoto conditional field and boolean which is true if field was set.
func (*UserFull) SetBlocked ¶
SetBlocked sets value of Blocked conditional field.
func (*UserFull) SetBotInfo ¶
SetBotInfo sets value of BotInfo conditional field.
func (*UserFull) SetCanPinMessage ¶
SetCanPinMessage sets value of CanPinMessage conditional field.
func (*UserFull) SetFolderID ¶
SetFolderID sets value of FolderID conditional field.
func (*UserFull) SetHasScheduled ¶
SetHasScheduled sets value of HasScheduled conditional field.
func (*UserFull) SetPhoneCallsAvailable ¶
SetPhoneCallsAvailable sets value of PhoneCallsAvailable conditional field.
func (*UserFull) SetPhoneCallsPrivate ¶
SetPhoneCallsPrivate sets value of PhoneCallsPrivate conditional field.
func (*UserFull) SetPinnedMsgID ¶
SetPinnedMsgID sets value of PinnedMsgID conditional field.
func (*UserFull) SetProfilePhoto ¶
func (u *UserFull) SetProfilePhoto(value PhotoClass)
SetProfilePhoto sets value of ProfilePhoto conditional field.
func (*UserFull) SetVideoCallsAvailable ¶
SetVideoCallsAvailable sets value of VideoCallsAvailable conditional field.
type UserNameHandler ¶ added in v0.9.0
type UserNameHandler func(ctx UpdateContext, update *UpdateUserName) error
UserNameHandler is a UserName event handler.
type UserPhoneHandler ¶ added in v0.9.0
type UserPhoneHandler func(ctx UpdateContext, update *UpdateUserPhone) error
UserPhoneHandler is a UserPhone event handler.
type UserPhotoHandler ¶ added in v0.9.0
type UserPhotoHandler func(ctx UpdateContext, update *UpdateUserPhoto) error
UserPhotoHandler is a UserPhoto event handler.
type UserProfilePhoto ¶
type UserProfilePhoto struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether an animated profile picture¹ is available for this user
//
// Links:
// 1) https://core.telegram.org/api/files#animated-profile-pictures
HasVideo bool
// Identifier of the respective photoParameter added in Layer 2¹
//
// Links:
// 1) https://core.telegram.org/api/layers#layer-2
PhotoID int64
// Location of the file, corresponding to the small profile photo thumbnail
PhotoSmall FileLocationToBeDeprecated
// Location of the file, corresponding to the big profile photo thumbnail
PhotoBig FileLocationToBeDeprecated
// DC ID where the photo is stored
DCID int
}
UserProfilePhoto represents TL type `userProfilePhoto#69d3ab26`. User profile photo.
See https://core.telegram.org/constructor/userProfilePhoto for reference.
func (*UserProfilePhoto) Decode ¶
func (u *UserProfilePhoto) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserProfilePhoto) Encode ¶
func (u *UserProfilePhoto) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserProfilePhoto) SetHasVideo ¶
func (u *UserProfilePhoto) SetHasVideo(value bool)
SetHasVideo sets value of HasVideo conditional field.
func (*UserProfilePhoto) String ¶ added in v0.12.0
func (u *UserProfilePhoto) String() string
String implements fmt.Stringer.
type UserProfilePhotoBox ¶
type UserProfilePhotoBox struct {
UserProfilePhoto UserProfilePhotoClass
}
UserProfilePhoto boxes the UserProfilePhotoClass providing a helper.
type UserProfilePhotoClass ¶
type UserProfilePhotoClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UserProfilePhotoClass represents UserProfilePhoto generic type.
See https://core.telegram.org/type/UserProfilePhoto for reference.
Example:
g, err := DecodeUserProfilePhoto(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UserProfilePhotoEmpty: // userProfilePhotoEmpty#4f11bae1
case *UserProfilePhoto: // userProfilePhoto#69d3ab26
default: panic(v)
}
func DecodeUserProfilePhoto ¶
func DecodeUserProfilePhoto(buf *bin.Buffer) (UserProfilePhotoClass, error)
DecodeUserProfilePhoto implements binary de-serialization for UserProfilePhotoClass.
type UserProfilePhotoEmpty ¶
type UserProfilePhotoEmpty struct {
}
UserProfilePhotoEmpty represents TL type `userProfilePhotoEmpty#4f11bae1`. Profile photo has not been set, or was hidden.
See https://core.telegram.org/constructor/userProfilePhotoEmpty for reference.
func (*UserProfilePhotoEmpty) Decode ¶
func (u *UserProfilePhotoEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserProfilePhotoEmpty) Encode ¶
func (u *UserProfilePhotoEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserProfilePhotoEmpty) String ¶ added in v0.12.0
func (u *UserProfilePhotoEmpty) String() string
String implements fmt.Stringer.
type UserStatusBox ¶
type UserStatusBox struct {
UserStatus UserStatusClass
}
UserStatus boxes the UserStatusClass providing a helper.
type UserStatusClass ¶
type UserStatusClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
UserStatusClass represents UserStatus generic type.
See https://core.telegram.org/type/UserStatus for reference.
Example:
g, err := DecodeUserStatus(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *UserStatusEmpty: // userStatusEmpty#9d05049
case *UserStatusOnline: // userStatusOnline#edb93949
case *UserStatusOffline: // userStatusOffline#8c703f
case *UserStatusRecently: // userStatusRecently#e26f42f1
case *UserStatusLastWeek: // userStatusLastWeek#7bf09fc
case *UserStatusLastMonth: // userStatusLastMonth#77ebc742
default: panic(v)
}
func DecodeUserStatus ¶
func DecodeUserStatus(buf *bin.Buffer) (UserStatusClass, error)
DecodeUserStatus implements binary de-serialization for UserStatusClass.
type UserStatusEmpty ¶
type UserStatusEmpty struct {
}
UserStatusEmpty represents TL type `userStatusEmpty#9d05049`. User status has not been set yet.
See https://core.telegram.org/constructor/userStatusEmpty for reference.
func (*UserStatusEmpty) Decode ¶
func (u *UserStatusEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusEmpty) Encode ¶
func (u *UserStatusEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusEmpty) String ¶ added in v0.12.0
func (u *UserStatusEmpty) String() string
String implements fmt.Stringer.
type UserStatusHandler ¶ added in v0.9.0
type UserStatusHandler func(ctx UpdateContext, update *UpdateUserStatus) error
UserStatusHandler is a UserStatus event handler.
type UserStatusLastMonth ¶
type UserStatusLastMonth struct {
}
UserStatusLastMonth represents TL type `userStatusLastMonth#77ebc742`. Online status: last seen last month
See https://core.telegram.org/constructor/userStatusLastMonth for reference.
func (*UserStatusLastMonth) Decode ¶
func (u *UserStatusLastMonth) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusLastMonth) Encode ¶
func (u *UserStatusLastMonth) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusLastMonth) String ¶ added in v0.12.0
func (u *UserStatusLastMonth) String() string
String implements fmt.Stringer.
type UserStatusLastWeek ¶
type UserStatusLastWeek struct {
}
UserStatusLastWeek represents TL type `userStatusLastWeek#7bf09fc`. Online status: last seen last week
See https://core.telegram.org/constructor/userStatusLastWeek for reference.
func (*UserStatusLastWeek) Decode ¶
func (u *UserStatusLastWeek) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusLastWeek) Encode ¶
func (u *UserStatusLastWeek) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusLastWeek) String ¶ added in v0.12.0
func (u *UserStatusLastWeek) String() string
String implements fmt.Stringer.
type UserStatusOffline ¶
type UserStatusOffline struct {
// Time the user was last seen online
WasOnline int
}
UserStatusOffline represents TL type `userStatusOffline#8c703f`. The user's offline status.
See https://core.telegram.org/constructor/userStatusOffline for reference.
func (*UserStatusOffline) Decode ¶
func (u *UserStatusOffline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusOffline) Encode ¶
func (u *UserStatusOffline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusOffline) String ¶ added in v0.12.0
func (u *UserStatusOffline) String() string
String implements fmt.Stringer.
type UserStatusOnline ¶
type UserStatusOnline struct {
// Time to expiration of the current online status
Expires int
}
UserStatusOnline represents TL type `userStatusOnline#edb93949`. Online status of the user.
See https://core.telegram.org/constructor/userStatusOnline for reference.
func (*UserStatusOnline) Decode ¶
func (u *UserStatusOnline) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusOnline) Encode ¶
func (u *UserStatusOnline) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusOnline) String ¶ added in v0.12.0
func (u *UserStatusOnline) String() string
String implements fmt.Stringer.
type UserStatusRecently ¶
type UserStatusRecently struct {
}
UserStatusRecently represents TL type `userStatusRecently#e26f42f1`. Online status: last seen recently
See https://core.telegram.org/constructor/userStatusRecently for reference.
func (*UserStatusRecently) Decode ¶
func (u *UserStatusRecently) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UserStatusRecently) Encode ¶
func (u *UserStatusRecently) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UserStatusRecently) String ¶ added in v0.12.0
func (u *UserStatusRecently) String() string
String implements fmt.Stringer.
type UserTypingHandler ¶ added in v0.9.0
type UserTypingHandler func(ctx UpdateContext, update *UpdateUserTyping) error
UserTypingHandler is a UserTyping event handler.
type UsersGetFullUserRequest ¶
type UsersGetFullUserRequest struct {
// User ID
ID InputUserClass
}
UsersGetFullUserRequest represents TL type `users.getFullUser#ca30a5b1`. Returns extended user info by ID.
See https://core.telegram.org/method/users.getFullUser for reference.
func (*UsersGetFullUserRequest) Decode ¶
func (g *UsersGetFullUserRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UsersGetFullUserRequest) Encode ¶
func (g *UsersGetFullUserRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UsersGetFullUserRequest) String ¶ added in v0.12.0
func (g *UsersGetFullUserRequest) String() string
String implements fmt.Stringer.
type UsersGetUsersRequest ¶
type UsersGetUsersRequest struct {
// List of user identifiers
ID []InputUserClass
}
UsersGetUsersRequest represents TL type `users.getUsers#d91a548`. Returns basic user info according to their identifiers.
See https://core.telegram.org/method/users.getUsers for reference.
func (*UsersGetUsersRequest) Decode ¶
func (g *UsersGetUsersRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UsersGetUsersRequest) Encode ¶
func (g *UsersGetUsersRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UsersGetUsersRequest) String ¶ added in v0.12.0
func (g *UsersGetUsersRequest) String() string
String implements fmt.Stringer.
type UsersSetSecureValueErrorsRequest ¶
type UsersSetSecureValueErrorsRequest struct {
// The user
ID InputUserClass
// Errors
Errors []SecureValueErrorClass
}
UsersSetSecureValueErrorsRequest represents TL type `users.setSecureValueErrors#90c894b5`. Notify the user that the sent passport¹ data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change). Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues.
Links:
See https://core.telegram.org/method/users.setSecureValueErrors for reference.
func (*UsersSetSecureValueErrorsRequest) Decode ¶
func (s *UsersSetSecureValueErrorsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*UsersSetSecureValueErrorsRequest) Encode ¶
func (s *UsersSetSecureValueErrorsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*UsersSetSecureValueErrorsRequest) String ¶ added in v0.12.0
func (s *UsersSetSecureValueErrorsRequest) String() string
String implements fmt.Stringer.
type VideoSize ¶
type VideoSize struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// u for animated profile pictures, and v for trimmed and downscaled video previews
Type string
// File location
Location FileLocationToBeDeprecated
// Video width
W int
// Video height
H int
// File size
Size int
// Timestamp that should be shown as static preview to the user (seconds)
//
// Use SetVideoStartTs and GetVideoStartTs helpers.
VideoStartTs float64
}
VideoSize represents TL type `videoSize#e831c556`. Animated profile picture¹ in MPEG4 format
Links:
See https://core.telegram.org/constructor/videoSize for reference.
func (*VideoSize) GetVideoStartTs ¶
GetVideoStartTs returns value of VideoStartTs conditional field and boolean which is true if field was set.
func (*VideoSize) SetVideoStartTs ¶
SetVideoStartTs sets value of VideoStartTs conditional field.
type WallPaper ¶
type WallPaper struct {
// Identifier
ID int64
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Creator of the wallpaper
Creator bool
// Whether this is the default wallpaper
Default bool
// Pattern
Pattern bool
// Dark mode
Dark bool
// Access hash
AccessHash int64
// Unique wallpaper ID
Slug string
// The actual wallpaper
Document DocumentClass
// Wallpaper settings
//
// Use SetSettings and GetSettings helpers.
Settings WallPaperSettings
}
WallPaper represents TL type `wallPaper#a437c3ed`. Wallpaper settings.
See https://core.telegram.org/constructor/wallPaper for reference.
func (*WallPaper) GetSettings ¶
func (w *WallPaper) GetSettings() (value WallPaperSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*WallPaper) SetCreator ¶
SetCreator sets value of Creator conditional field.
func (*WallPaper) SetDefault ¶
SetDefault sets value of Default conditional field.
func (*WallPaper) SetPattern ¶
SetPattern sets value of Pattern conditional field.
func (*WallPaper) SetSettings ¶
func (w *WallPaper) SetSettings(value WallPaperSettings)
SetSettings sets value of Settings conditional field.
type WallPaperBox ¶
type WallPaperBox struct {
WallPaper WallPaperClass
}
WallPaper boxes the WallPaperClass providing a helper.
type WallPaperClass ¶
type WallPaperClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
WallPaperClass represents WallPaper generic type.
See https://core.telegram.org/type/WallPaper for reference.
Example:
g, err := DecodeWallPaper(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *WallPaper: // wallPaper#a437c3ed
case *WallPaperNoFile: // wallPaperNoFile#8af40b25
default: panic(v)
}
func DecodeWallPaper ¶
func DecodeWallPaper(buf *bin.Buffer) (WallPaperClass, error)
DecodeWallPaper implements binary de-serialization for WallPaperClass.
type WallPaperClassVector ¶ added in v0.8.0
type WallPaperClassVector struct {
// Elements of Vector<WallPaper>
Elems []WallPaperClass
}
WallPaperClassVector is a box for Vector<WallPaper>
func (*WallPaperClassVector) Decode ¶ added in v0.8.0
func (vec *WallPaperClassVector) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WallPaperClassVector) Encode ¶ added in v0.8.0
func (vec *WallPaperClassVector) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WallPaperClassVector) String ¶ added in v0.12.0
func (vec *WallPaperClassVector) String() string
String implements fmt.Stringer.
type WallPaperNoFile ¶
type WallPaperNoFile struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Whether this is the default wallpaper
Default bool
// Dark mode
Dark bool
// Wallpaper settings
//
// Use SetSettings and GetSettings helpers.
Settings WallPaperSettings
}
WallPaperNoFile represents TL type `wallPaperNoFile#8af40b25`. No file wallpaper
See https://core.telegram.org/constructor/wallPaperNoFile for reference.
func (*WallPaperNoFile) Decode ¶
func (w *WallPaperNoFile) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WallPaperNoFile) Encode ¶
func (w *WallPaperNoFile) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WallPaperNoFile) GetSettings ¶
func (w *WallPaperNoFile) GetSettings() (value WallPaperSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*WallPaperNoFile) SetDark ¶
func (w *WallPaperNoFile) SetDark(value bool)
SetDark sets value of Dark conditional field.
func (*WallPaperNoFile) SetDefault ¶
func (w *WallPaperNoFile) SetDefault(value bool)
SetDefault sets value of Default conditional field.
func (*WallPaperNoFile) SetSettings ¶
func (w *WallPaperNoFile) SetSettings(value WallPaperSettings)
SetSettings sets value of Settings conditional field.
func (*WallPaperNoFile) String ¶ added in v0.12.0
func (w *WallPaperNoFile) String() string
String implements fmt.Stringer.
type WallPaperSettings ¶
type WallPaperSettings struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// If set, the wallpaper must be downscaled to fit in 450x450 square and then box-blurred with radius 12
Blur bool
// If set, the background needs to be slightly moved when device is rotated
Motion bool
// If set, a PNG pattern is to be combined with the color chosen by the user: the main color of the background in RGB24 format
//
// Use SetBackgroundColor and GetBackgroundColor helpers.
BackgroundColor int
// If set, a PNG pattern is to be combined with the first and second background colors (RGB24 format) in a top-bottom gradient
//
// Use SetSecondBackgroundColor and GetSecondBackgroundColor helpers.
SecondBackgroundColor int
// Intensity of the pattern when it is shown above the main background color, 0-100
//
// Use SetIntensity and GetIntensity helpers.
Intensity int
// Clockwise rotation angle of the gradient, in degrees; 0-359. Should be always divisible by 45
//
// Use SetRotation and GetRotation helpers.
Rotation int
}
WallPaperSettings represents TL type `wallPaperSettings#5086cf8`. Wallpaper settings
See https://core.telegram.org/constructor/wallPaperSettings for reference.
func (*WallPaperSettings) Decode ¶
func (w *WallPaperSettings) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WallPaperSettings) Encode ¶
func (w *WallPaperSettings) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WallPaperSettings) GetBackgroundColor ¶
func (w *WallPaperSettings) GetBackgroundColor() (value int, ok bool)
GetBackgroundColor returns value of BackgroundColor conditional field and boolean which is true if field was set.
func (*WallPaperSettings) GetIntensity ¶
func (w *WallPaperSettings) GetIntensity() (value int, ok bool)
GetIntensity returns value of Intensity conditional field and boolean which is true if field was set.
func (*WallPaperSettings) GetRotation ¶
func (w *WallPaperSettings) GetRotation() (value int, ok bool)
GetRotation returns value of Rotation conditional field and boolean which is true if field was set.
func (*WallPaperSettings) GetSecondBackgroundColor ¶
func (w *WallPaperSettings) GetSecondBackgroundColor() (value int, ok bool)
GetSecondBackgroundColor returns value of SecondBackgroundColor conditional field and boolean which is true if field was set.
func (*WallPaperSettings) SetBackgroundColor ¶
func (w *WallPaperSettings) SetBackgroundColor(value int)
SetBackgroundColor sets value of BackgroundColor conditional field.
func (*WallPaperSettings) SetBlur ¶
func (w *WallPaperSettings) SetBlur(value bool)
SetBlur sets value of Blur conditional field.
func (*WallPaperSettings) SetIntensity ¶
func (w *WallPaperSettings) SetIntensity(value int)
SetIntensity sets value of Intensity conditional field.
func (*WallPaperSettings) SetMotion ¶
func (w *WallPaperSettings) SetMotion(value bool)
SetMotion sets value of Motion conditional field.
func (*WallPaperSettings) SetRotation ¶
func (w *WallPaperSettings) SetRotation(value int)
SetRotation sets value of Rotation conditional field.
func (*WallPaperSettings) SetSecondBackgroundColor ¶
func (w *WallPaperSettings) SetSecondBackgroundColor(value int)
SetSecondBackgroundColor sets value of SecondBackgroundColor conditional field.
func (*WallPaperSettings) String ¶ added in v0.12.0
func (w *WallPaperSettings) String() string
String implements fmt.Stringer.
type WebAuthorization ¶
type WebAuthorization struct {
// Authorization hash
Hash int64
// Bot ID
BotID int
// The domain name of the website on which the user has logged in.
Domain string
// Browser user-agent
Browser string
// Platform
Platform string
// When was the web session created
DateCreated int
// When was the web session last active
DateActive int
// IP address
IP string
// Region, determined from IP address
Region string
}
WebAuthorization represents TL type `webAuthorization#cac943f2`. Represents a bot logged in using the Telegram login widget¹
Links:
See https://core.telegram.org/constructor/webAuthorization for reference.
func (*WebAuthorization) Decode ¶
func (w *WebAuthorization) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebAuthorization) Encode ¶
func (w *WebAuthorization) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebAuthorization) String ¶ added in v0.12.0
func (w *WebAuthorization) String() string
String implements fmt.Stringer.
type WebDocument ¶
type WebDocument struct {
// Document URL
URL string
// Access hash
AccessHash int64
// File size
Size int
// MIME type
MimeType string
// Attributes for media types
Attributes []DocumentAttributeClass
}
WebDocument represents TL type `webDocument#1c570ed1`. Remote document
See https://core.telegram.org/constructor/webDocument for reference.
func (*WebDocument) Decode ¶
func (w *WebDocument) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebDocument) Encode ¶
func (w *WebDocument) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebDocument) String ¶ added in v0.12.0
func (w *WebDocument) String() string
String implements fmt.Stringer.
type WebDocumentBox ¶
type WebDocumentBox struct {
WebDocument WebDocumentClass
}
WebDocument boxes the WebDocumentClass providing a helper.
type WebDocumentClass ¶
type WebDocumentClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
WebDocumentClass represents WebDocument generic type.
See https://core.telegram.org/type/WebDocument for reference.
Example:
g, err := DecodeWebDocument(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *WebDocument: // webDocument#1c570ed1
case *WebDocumentNoProxy: // webDocumentNoProxy#f9c8bcc6
default: panic(v)
}
func DecodeWebDocument ¶
func DecodeWebDocument(buf *bin.Buffer) (WebDocumentClass, error)
DecodeWebDocument implements binary de-serialization for WebDocumentClass.
type WebDocumentNoProxy ¶
type WebDocumentNoProxy struct {
// Document URL
URL string
// File size
Size int
// MIME type
MimeType string
// Attributes for media types
Attributes []DocumentAttributeClass
}
WebDocumentNoProxy represents TL type `webDocumentNoProxy#f9c8bcc6`. Remote document that can be downloaded without proxying through telegram¹
Links:
See https://core.telegram.org/constructor/webDocumentNoProxy for reference.
func (*WebDocumentNoProxy) Decode ¶
func (w *WebDocumentNoProxy) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebDocumentNoProxy) Encode ¶
func (w *WebDocumentNoProxy) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebDocumentNoProxy) String ¶ added in v0.12.0
func (w *WebDocumentNoProxy) String() string
String implements fmt.Stringer.
type WebPage ¶
type WebPage struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Preview ID
ID int64
// URL of previewed webpage
URL string
// Webpage URL to be displayed to the user
DisplayURL string
// Hash for pagination, for more info click here¹
//
// Links:
// 1) https://core.telegram.org/api/offsets#hash-generation
Hash int
// Type of the web page. Can be: article, photo, audio, video, document, profile, app, or something else
//
// Use SetType and GetType helpers.
Type string
// Short name of the site (e.g., Google Docs, App Store)
//
// Use SetSiteName and GetSiteName helpers.
SiteName string
// Title of the content
//
// Use SetTitle and GetTitle helpers.
Title string
// Content description
//
// Use SetDescription and GetDescription helpers.
Description string
// Image representing the content
//
// Use SetPhoto and GetPhoto helpers.
Photo PhotoClass
// URL to show in the embedded preview
//
// Use SetEmbedURL and GetEmbedURL helpers.
EmbedURL string
// MIME type of the embedded preview, (e.g., text/html or video/mp4)
//
// Use SetEmbedType and GetEmbedType helpers.
EmbedType string
// Width of the embedded preview
//
// Use SetEmbedWidth and GetEmbedWidth helpers.
EmbedWidth int
// Height of the embedded preview
//
// Use SetEmbedHeight and GetEmbedHeight helpers.
EmbedHeight int
// Duration of the content, in seconds
//
// Use SetDuration and GetDuration helpers.
Duration int
// Author of the content
//
// Use SetAuthor and GetAuthor helpers.
Author string
// Preview of the content as a media file
//
// Use SetDocument and GetDocument helpers.
Document DocumentClass
// Page contents in instant view¹ format
//
// Links:
// 1) https://instantview.telegram.org
//
// Use SetCachedPage and GetCachedPage helpers.
CachedPage Page
// Webpage attributes
//
// Use SetAttributes and GetAttributes helpers.
Attributes []WebPageAttributeTheme
}
WebPage represents TL type `webPage#e89c45b2`. Webpage preview
See https://core.telegram.org/constructor/webPage for reference.
func (*WebPage) GetAttributes ¶
func (w *WebPage) GetAttributes() (value []WebPageAttributeTheme, ok bool)
GetAttributes returns value of Attributes conditional field and boolean which is true if field was set.
func (*WebPage) GetAuthor ¶
GetAuthor returns value of Author conditional field and boolean which is true if field was set.
func (*WebPage) GetCachedPage ¶
GetCachedPage returns value of CachedPage conditional field and boolean which is true if field was set.
func (*WebPage) GetDescription ¶
GetDescription returns value of Description conditional field and boolean which is true if field was set.
func (*WebPage) GetDocument ¶
func (w *WebPage) GetDocument() (value DocumentClass, ok bool)
GetDocument returns value of Document conditional field and boolean which is true if field was set.
func (*WebPage) GetDuration ¶
GetDuration returns value of Duration conditional field and boolean which is true if field was set.
func (*WebPage) GetEmbedHeight ¶
GetEmbedHeight returns value of EmbedHeight conditional field and boolean which is true if field was set.
func (*WebPage) GetEmbedType ¶
GetEmbedType returns value of EmbedType conditional field and boolean which is true if field was set.
func (*WebPage) GetEmbedURL ¶
GetEmbedURL returns value of EmbedURL conditional field and boolean which is true if field was set.
func (*WebPage) GetEmbedWidth ¶
GetEmbedWidth returns value of EmbedWidth conditional field and boolean which is true if field was set.
func (*WebPage) GetPhoto ¶
func (w *WebPage) GetPhoto() (value PhotoClass, ok bool)
GetPhoto returns value of Photo conditional field and boolean which is true if field was set.
func (*WebPage) GetSiteName ¶
GetSiteName returns value of SiteName conditional field and boolean which is true if field was set.
func (*WebPage) GetTitle ¶
GetTitle returns value of Title conditional field and boolean which is true if field was set.
func (*WebPage) GetType ¶
GetType returns value of Type conditional field and boolean which is true if field was set.
func (*WebPage) SetAttributes ¶
func (w *WebPage) SetAttributes(value []WebPageAttributeTheme)
SetAttributes sets value of Attributes conditional field.
func (*WebPage) SetCachedPage ¶
SetCachedPage sets value of CachedPage conditional field.
func (*WebPage) SetDescription ¶
SetDescription sets value of Description conditional field.
func (*WebPage) SetDocument ¶
func (w *WebPage) SetDocument(value DocumentClass)
SetDocument sets value of Document conditional field.
func (*WebPage) SetDuration ¶
SetDuration sets value of Duration conditional field.
func (*WebPage) SetEmbedHeight ¶
SetEmbedHeight sets value of EmbedHeight conditional field.
func (*WebPage) SetEmbedType ¶
SetEmbedType sets value of EmbedType conditional field.
func (*WebPage) SetEmbedURL ¶
SetEmbedURL sets value of EmbedURL conditional field.
func (*WebPage) SetEmbedWidth ¶
SetEmbedWidth sets value of EmbedWidth conditional field.
func (*WebPage) SetPhoto ¶
func (w *WebPage) SetPhoto(value PhotoClass)
SetPhoto sets value of Photo conditional field.
func (*WebPage) SetSiteName ¶
SetSiteName sets value of SiteName conditional field.
type WebPageAttributeTheme ¶
type WebPageAttributeTheme struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Theme files
//
// Use SetDocuments and GetDocuments helpers.
Documents []DocumentClass
// Theme settings
//
// Use SetSettings and GetSettings helpers.
Settings ThemeSettings
}
WebPageAttributeTheme represents TL type `webPageAttributeTheme#54b56617`. Page theme
See https://core.telegram.org/constructor/webPageAttributeTheme for reference.
func (*WebPageAttributeTheme) Decode ¶
func (w *WebPageAttributeTheme) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebPageAttributeTheme) Encode ¶
func (w *WebPageAttributeTheme) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebPageAttributeTheme) GetDocuments ¶
func (w *WebPageAttributeTheme) GetDocuments() (value []DocumentClass, ok bool)
GetDocuments returns value of Documents conditional field and boolean which is true if field was set.
func (*WebPageAttributeTheme) GetSettings ¶
func (w *WebPageAttributeTheme) GetSettings() (value ThemeSettings, ok bool)
GetSettings returns value of Settings conditional field and boolean which is true if field was set.
func (*WebPageAttributeTheme) SetDocuments ¶
func (w *WebPageAttributeTheme) SetDocuments(value []DocumentClass)
SetDocuments sets value of Documents conditional field.
func (*WebPageAttributeTheme) SetSettings ¶
func (w *WebPageAttributeTheme) SetSettings(value ThemeSettings)
SetSettings sets value of Settings conditional field.
func (*WebPageAttributeTheme) String ¶ added in v0.12.0
func (w *WebPageAttributeTheme) String() string
String implements fmt.Stringer.
type WebPageBox ¶
type WebPageBox struct {
WebPage WebPageClass
}
WebPage boxes the WebPageClass providing a helper.
type WebPageClass ¶
type WebPageClass interface {
bin.Encoder
bin.Decoder
fmt.Stringer
// contains filtered or unexported methods
}
WebPageClass represents WebPage generic type.
See https://core.telegram.org/type/WebPage for reference.
Example:
g, err := DecodeWebPage(buf)
if err != nil {
panic(err)
}
switch v := g.(type) {
case *WebPageEmpty: // webPageEmpty#eb1477e8
case *WebPagePending: // webPagePending#c586da1c
case *WebPage: // webPage#e89c45b2
case *WebPageNotModified: // webPageNotModified#7311ca11
default: panic(v)
}
func DecodeWebPage ¶
func DecodeWebPage(buf *bin.Buffer) (WebPageClass, error)
DecodeWebPage implements binary de-serialization for WebPageClass.
type WebPageEmpty ¶
type WebPageEmpty struct {
// Preview ID
ID int64
}
WebPageEmpty represents TL type `webPageEmpty#eb1477e8`. No preview is available for the webpage
See https://core.telegram.org/constructor/webPageEmpty for reference.
func (*WebPageEmpty) Decode ¶
func (w *WebPageEmpty) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebPageEmpty) Encode ¶
func (w *WebPageEmpty) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebPageEmpty) String ¶ added in v0.12.0
func (w *WebPageEmpty) String() string
String implements fmt.Stringer.
type WebPageHandler ¶ added in v0.9.0
type WebPageHandler func(ctx UpdateContext, update *UpdateWebPage) error
WebPageHandler is a WebPage event handler.
type WebPageNotModified ¶
type WebPageNotModified struct {
// Flags, see TL conditional fields¹
//
// Links:
// 1) https://core.telegram.org/mtproto/TL-combinators#conditional-fields
Flags bin.Fields
// Page view count
//
// Use SetCachedPageViews and GetCachedPageViews helpers.
CachedPageViews int
}
WebPageNotModified represents TL type `webPageNotModified#7311ca11`. The preview of the webpage hasn't changed
See https://core.telegram.org/constructor/webPageNotModified for reference.
func (*WebPageNotModified) Decode ¶
func (w *WebPageNotModified) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebPageNotModified) Encode ¶
func (w *WebPageNotModified) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebPageNotModified) GetCachedPageViews ¶
func (w *WebPageNotModified) GetCachedPageViews() (value int, ok bool)
GetCachedPageViews returns value of CachedPageViews conditional field and boolean which is true if field was set.
func (*WebPageNotModified) SetCachedPageViews ¶
func (w *WebPageNotModified) SetCachedPageViews(value int)
SetCachedPageViews sets value of CachedPageViews conditional field.
func (*WebPageNotModified) String ¶ added in v0.12.0
func (w *WebPageNotModified) String() string
String implements fmt.Stringer.
type WebPagePending ¶
type WebPagePending struct {
// ID of preview
ID int64
// When was the processing started
Date int
}
WebPagePending represents TL type `webPagePending#c586da1c`. A preview of the webpage is currently being generated
See https://core.telegram.org/constructor/webPagePending for reference.
func (*WebPagePending) Decode ¶
func (w *WebPagePending) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*WebPagePending) Encode ¶
func (w *WebPagePending) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*WebPagePending) String ¶ added in v0.12.0
func (w *WebPagePending) String() string
String implements fmt.Stringer.
Source Files
¶
- tg.go
- tl_account_accept_authorization_gen.go
- tl_account_authorization_form_gen.go
- tl_account_authorizations_gen.go
- tl_account_auto_download_settings_gen.go
- tl_account_cancel_password_email_gen.go
- tl_account_change_phone_gen.go
- tl_account_check_username_gen.go
- tl_account_confirm_password_email_gen.go
- tl_account_confirm_phone_gen.go
- tl_account_content_settings_gen.go
- tl_account_create_theme_gen.go
- tl_account_days_ttl_gen.go
- tl_account_delete_account_gen.go
- tl_account_delete_secure_value_gen.go
- tl_account_finish_takeout_session_gen.go
- tl_account_get_account_ttl_gen.go
- tl_account_get_all_secure_values_gen.go
- tl_account_get_authorization_form_gen.go
- tl_account_get_authorizations_gen.go
- tl_account_get_auto_download_settings_gen.go
- tl_account_get_contact_sign_up_notification_gen.go
- tl_account_get_content_settings_gen.go
- tl_account_get_global_privacy_settings_gen.go
- tl_account_get_multi_wall_papers_gen.go
- tl_account_get_notify_exceptions_gen.go
- tl_account_get_notify_settings_gen.go
- tl_account_get_password_gen.go
- tl_account_get_password_settings_gen.go
- tl_account_get_privacy_gen.go
- tl_account_get_secure_value_gen.go
- tl_account_get_theme_gen.go
- tl_account_get_themes_gen.go
- tl_account_get_tmp_password_gen.go
- tl_account_get_wall_paper_gen.go
- tl_account_get_wall_papers_gen.go
- tl_account_get_web_authorizations_gen.go
- tl_account_init_takeout_session_gen.go
- tl_account_install_theme_gen.go
- tl_account_install_wall_paper_gen.go
- tl_account_password_gen.go
- tl_account_password_input_settings_gen.go
- tl_account_password_settings_gen.go
- tl_account_privacy_rules_gen.go
- tl_account_register_device_gen.go
- tl_account_report_peer_gen.go
- tl_account_resend_password_email_gen.go
- tl_account_reset_authorization_gen.go
- tl_account_reset_notify_settings_gen.go
- tl_account_reset_wall_papers_gen.go
- tl_account_reset_web_authorization_gen.go
- tl_account_reset_web_authorizations_gen.go
- tl_account_save_auto_download_settings_gen.go
- tl_account_save_secure_value_gen.go
- tl_account_save_theme_gen.go
- tl_account_save_wall_paper_gen.go
- tl_account_send_change_phone_code_gen.go
- tl_account_send_confirm_phone_code_gen.go
- tl_account_send_verify_email_code_gen.go
- tl_account_send_verify_phone_code_gen.go
- tl_account_sent_email_code_gen.go
- tl_account_set_account_ttl_gen.go
- tl_account_set_contact_sign_up_notification_gen.go
- tl_account_set_content_settings_gen.go
- tl_account_set_global_privacy_settings_gen.go
- tl_account_set_privacy_gen.go
- tl_account_takeout_gen.go
- tl_account_themes_gen.go
- tl_account_tmp_password_gen.go
- tl_account_unregister_device_gen.go
- tl_account_update_device_locked_gen.go
- tl_account_update_notify_settings_gen.go
- tl_account_update_password_settings_gen.go
- tl_account_update_profile_gen.go
- tl_account_update_status_gen.go
- tl_account_update_theme_gen.go
- tl_account_update_username_gen.go
- tl_account_upload_theme_gen.go
- tl_account_upload_wall_paper_gen.go
- tl_account_verify_email_gen.go
- tl_account_verify_phone_gen.go
- tl_account_wall_papers_gen.go
- tl_account_web_authorizations_gen.go
- tl_auth_accept_login_token_gen.go
- tl_auth_authorization_gen.go
- tl_auth_bind_temp_auth_key_gen.go
- tl_auth_cancel_code_gen.go
- tl_auth_check_password_gen.go
- tl_auth_code_type_gen.go
- tl_auth_drop_temp_auth_keys_gen.go
- tl_auth_export_authorization_gen.go
- tl_auth_export_login_token_gen.go
- tl_auth_exported_authorization_gen.go
- tl_auth_import_authorization_gen.go
- tl_auth_import_bot_authorization_gen.go
- tl_auth_import_login_token_gen.go
- tl_auth_log_out_gen.go
- tl_auth_login_token_gen.go
- tl_auth_password_recovery_gen.go
- tl_auth_recover_password_gen.go
- tl_auth_request_password_recovery_gen.go
- tl_auth_resend_code_gen.go
- tl_auth_reset_authorizations_gen.go
- tl_auth_send_code_gen.go
- tl_auth_sent_code_gen.go
- tl_auth_sent_code_type_gen.go
- tl_auth_sign_in_gen.go
- tl_auth_sign_up_gen.go
- tl_authorization_gen.go
- tl_auto_download_settings_gen.go
- tl_bank_card_open_url_gen.go
- tl_base_theme_gen.go
- tl_bool_gen.go
- tl_bot_command_gen.go
- tl_bot_info_gen.go
- tl_bot_inline_message_gen.go
- tl_bot_inline_result_gen.go
- tl_bots_answer_webhook_json_query_gen.go
- tl_bots_send_custom_request_gen.go
- tl_bots_set_bot_commands_gen.go
- tl_cdn_config_gen.go
- tl_cdn_public_key_gen.go
- tl_channel_admin_log_event_action_gen.go
- tl_channel_admin_log_event_gen.go
- tl_channel_admin_log_events_filter_gen.go
- tl_channel_location_gen.go
- tl_channel_messages_filter_gen.go
- tl_channel_participant_gen.go
- tl_channel_participants_filter_gen.go
- tl_channels_admin_log_results_gen.go
- tl_channels_channel_participant_gen.go
- tl_channels_channel_participants_gen.go
- tl_channels_check_username_gen.go
- tl_channels_create_channel_gen.go
- tl_channels_delete_channel_gen.go
- tl_channels_delete_history_gen.go
- tl_channels_delete_messages_gen.go
- tl_channels_delete_user_history_gen.go
- tl_channels_edit_admin_gen.go
- tl_channels_edit_banned_gen.go
- tl_channels_edit_creator_gen.go
- tl_channels_edit_location_gen.go
- tl_channels_edit_photo_gen.go
- tl_channels_edit_title_gen.go
- tl_channels_export_message_link_gen.go
- tl_channels_get_admin_log_gen.go
- tl_channels_get_admined_public_channels_gen.go
- tl_channels_get_channels_gen.go
- tl_channels_get_full_channel_gen.go
- tl_channels_get_groups_for_discussion_gen.go
- tl_channels_get_inactive_channels_gen.go
- tl_channels_get_left_channels_gen.go
- tl_channels_get_messages_gen.go
- tl_channels_get_participant_gen.go
- tl_channels_get_participants_gen.go
- tl_channels_invite_to_channel_gen.go
- tl_channels_join_channel_gen.go
- tl_channels_leave_channel_gen.go
- tl_channels_read_history_gen.go
- tl_channels_read_message_contents_gen.go
- tl_channels_report_spam_gen.go
- tl_channels_set_discussion_group_gen.go
- tl_channels_set_stickers_gen.go
- tl_channels_toggle_pre_history_hidden_gen.go
- tl_channels_toggle_signatures_gen.go
- tl_channels_toggle_slow_mode_gen.go
- tl_channels_update_username_gen.go
- tl_chat_admin_rights_gen.go
- tl_chat_banned_rights_gen.go
- tl_chat_full_gen.go
- tl_chat_gen.go
- tl_chat_invite_gen.go
- tl_chat_onlines_gen.go
- tl_chat_participant_gen.go
- tl_chat_participants_gen.go
- tl_chat_photo_gen.go
- tl_client_gen.go
- tl_code_settings_gen.go
- tl_config_gen.go
- tl_contact_gen.go
- tl_contact_status_gen.go
- tl_contact_status_vector_gen.go
- tl_contacts_accept_contact_gen.go
- tl_contacts_add_contact_gen.go
- tl_contacts_block_from_replies_gen.go
- tl_contacts_block_gen.go
- tl_contacts_blocked_gen.go
- tl_contacts_contacts_gen.go
- tl_contacts_delete_by_phones_gen.go
- tl_contacts_delete_contacts_gen.go
- tl_contacts_found_gen.go
- tl_contacts_get_blocked_gen.go
- tl_contacts_get_contact_ids_gen.go
- tl_contacts_get_contacts_gen.go
- tl_contacts_get_located_gen.go
- tl_contacts_get_saved_gen.go
- tl_contacts_get_statuses_gen.go
- tl_contacts_get_top_peers_gen.go
- tl_contacts_import_contacts_gen.go
- tl_contacts_imported_contacts_gen.go
- tl_contacts_reset_saved_gen.go
- tl_contacts_reset_top_peer_rating_gen.go
- tl_contacts_resolve_username_gen.go
- tl_contacts_resolved_peer_gen.go
- tl_contacts_search_gen.go
- tl_contacts_toggle_top_peers_gen.go
- tl_contacts_top_peers_gen.go
- tl_contacts_unblock_gen.go
- tl_data_json_gen.go
- tl_dc_option_gen.go
- tl_dialog_filter_gen.go
- tl_dialog_filter_suggested_gen.go
- tl_dialog_filter_suggested_vector_gen.go
- tl_dialog_filter_vector_gen.go
- tl_dialog_gen.go
- tl_dialog_peer_class_vector_gen.go
- tl_dialog_peer_gen.go
- tl_document_attribute_gen.go
- tl_document_gen.go
- tl_draft_message_gen.go
- tl_emoji_keyword_gen.go
- tl_emoji_keywords_difference_gen.go
- tl_emoji_language_gen.go
- tl_emoji_language_vector_gen.go
- tl_emoji_url_gen.go
- tl_encrypted_chat_gen.go
- tl_encrypted_file_gen.go
- tl_encrypted_message_gen.go
- tl_error_gen.go
- tl_exported_chat_invite_gen.go
- tl_exported_message_link_gen.go
- tl_file_hash_gen.go
- tl_file_hash_vector_gen.go
- tl_file_location_to_be_deprecated_gen.go
- tl_folder_gen.go
- tl_folder_peer_gen.go
- tl_folders_delete_folder_gen.go
- tl_folders_edit_peer_folders_gen.go
- tl_game_gen.go
- tl_geo_point_gen.go
- tl_global_privacy_settings_gen.go
- tl_group_call_gen.go
- tl_group_call_participant_gen.go
- tl_handlers_gen.go
- tl_help_accept_terms_of_service_gen.go
- tl_help_app_update_gen.go
- tl_help_countries_list_gen.go
- tl_help_country_code_gen.go
- tl_help_country_gen.go
- tl_help_deep_link_info_gen.go
- tl_help_dismiss_suggestion_gen.go
- tl_help_edit_user_info_gen.go
- tl_help_get_app_changelog_gen.go
- tl_help_get_app_config_gen.go
- tl_help_get_app_update_gen.go
- tl_help_get_cdn_config_gen.go
- tl_help_get_config_gen.go
- tl_help_get_countries_list_gen.go
- tl_help_get_deep_link_info_gen.go
- tl_help_get_invite_text_gen.go
- tl_help_get_nearest_dc_gen.go
- tl_help_get_passport_config_gen.go
- tl_help_get_promo_data_gen.go
- tl_help_get_recent_me_urls_gen.go
- tl_help_get_support_gen.go
- tl_help_get_support_name_gen.go
- tl_help_get_terms_of_service_update_gen.go
- tl_help_get_user_info_gen.go
- tl_help_hide_promo_data_gen.go
- tl_help_invite_text_gen.go
- tl_help_passport_config_gen.go
- tl_help_promo_data_gen.go
- tl_help_recent_me_urls_gen.go
- tl_help_save_app_log_gen.go
- tl_help_set_bot_updates_status_gen.go
- tl_help_support_gen.go
- tl_help_support_name_gen.go
- tl_help_terms_of_service_gen.go
- tl_help_terms_of_service_update_gen.go
- tl_help_user_info_gen.go
- tl_high_score_gen.go
- tl_imported_contact_gen.go
- tl_init_connection_gen.go
- tl_inline_bot_switch_p_m_gen.go
- tl_inline_query_peer_type_gen.go
- tl_input_app_event_gen.go
- tl_input_bot_inline_message_gen.go
- tl_input_bot_inline_message_id_gen.go
- tl_input_bot_inline_result_gen.go
- tl_input_channel_gen.go
- tl_input_chat_photo_gen.go
- tl_input_check_password_s_r_p_gen.go
- tl_input_client_proxy_gen.go
- tl_input_dialog_peer_gen.go
- tl_input_document_gen.go
- tl_input_encrypted_chat_gen.go
- tl_input_encrypted_file_gen.go
- tl_input_file_gen.go
- tl_input_file_location_gen.go
- tl_input_folder_peer_gen.go
- tl_input_game_gen.go
- tl_input_geo_point_gen.go
- tl_input_group_call_gen.go
- tl_input_media_gen.go
- tl_input_message_gen.go
- tl_input_notify_peer_gen.go
- tl_input_payment_credentials_gen.go
- tl_input_peer_gen.go
- tl_input_peer_notify_settings_gen.go
- tl_input_phone_call_gen.go
- tl_input_phone_contact_gen.go
- tl_input_photo_gen.go
- tl_input_privacy_key_gen.go
- tl_input_privacy_rule_gen.go
- tl_input_secure_file_gen.go
- tl_input_secure_value_gen.go
- tl_input_single_media_gen.go
- tl_input_sticker_set_gen.go
- tl_input_sticker_set_item_gen.go
- tl_input_stickered_media_gen.go
- tl_input_theme_gen.go
- tl_input_theme_settings_gen.go
- tl_input_user_gen.go
- tl_input_wall_paper_gen.go
- tl_input_web_document_gen.go
- tl_input_web_file_location_gen.go
- tl_int_vector_gen.go
- tl_invoice_gen.go
- tl_invoke_after_msg_gen.go
- tl_invoke_after_msgs_gen.go
- tl_invoke_with_layer_gen.go
- tl_invoke_with_messages_range_gen.go
- tl_invoke_with_takeout_gen.go
- tl_invoke_without_updates_gen.go
- tl_json_object_value_gen.go
- tl_json_value_gen.go
- tl_keyboard_button_gen.go
- tl_keyboard_button_row_gen.go
- tl_labeled_price_gen.go
- tl_lang_pack_difference_gen.go
- tl_lang_pack_language_gen.go
- tl_lang_pack_language_vector_gen.go
- tl_lang_pack_string_class_vector_gen.go
- tl_lang_pack_string_gen.go
- tl_langpack_get_difference_gen.go
- tl_langpack_get_lang_pack_gen.go
- tl_langpack_get_language_gen.go
- tl_langpack_get_languages_gen.go
- tl_langpack_get_strings_gen.go
- tl_long_vector_gen.go
- tl_mask_coords_gen.go
- tl_message_action_gen.go
- tl_message_entity_gen.go
- tl_message_fwd_header_gen.go
- tl_message_gen.go
- tl_message_interaction_counters_gen.go
- tl_message_media_gen.go
- tl_message_range_gen.go
- tl_message_range_vector_gen.go
- tl_message_replies_gen.go
- tl_message_reply_header_gen.go
- tl_message_user_vote_gen.go
- tl_message_views_gen.go
- tl_messages_accept_encryption_gen.go
- tl_messages_accept_url_auth_gen.go
- tl_messages_add_chat_user_gen.go
- tl_messages_affected_history_gen.go
- tl_messages_affected_messages_gen.go
- tl_messages_all_stickers_gen.go
- tl_messages_archived_stickers_gen.go
- tl_messages_bot_callback_answer_gen.go
- tl_messages_bot_results_gen.go
- tl_messages_chat_full_gen.go
- tl_messages_chats_gen.go
- tl_messages_check_chat_invite_gen.go
- tl_messages_clear_all_drafts_gen.go
- tl_messages_clear_recent_stickers_gen.go
- tl_messages_create_chat_gen.go
- tl_messages_delete_chat_user_gen.go
- tl_messages_delete_history_gen.go
- tl_messages_delete_messages_gen.go
- tl_messages_delete_scheduled_messages_gen.go
- tl_messages_dh_config_gen.go
- tl_messages_dialogs_gen.go
- tl_messages_discard_encryption_gen.go
- tl_messages_discussion_message_gen.go
- tl_messages_edit_chat_about_gen.go
- tl_messages_edit_chat_admin_gen.go
- tl_messages_edit_chat_default_banned_rights_gen.go
- tl_messages_edit_chat_photo_gen.go
- tl_messages_edit_chat_title_gen.go
- tl_messages_edit_inline_bot_message_gen.go
- tl_messages_edit_message_gen.go
- tl_messages_export_chat_invite_gen.go
- tl_messages_fave_sticker_gen.go
- tl_messages_faved_stickers_gen.go
- tl_messages_featured_stickers_gen.go
- tl_messages_filter_gen.go
- tl_messages_forward_messages_gen.go
- tl_messages_found_sticker_sets_gen.go
- tl_messages_get_all_chats_gen.go
- tl_messages_get_all_drafts_gen.go
- tl_messages_get_all_stickers_gen.go
- tl_messages_get_archived_stickers_gen.go
- tl_messages_get_attached_stickers_gen.go
- tl_messages_get_bot_callback_answer_gen.go
- tl_messages_get_chats_gen.go
- tl_messages_get_common_chats_gen.go
- tl_messages_get_dh_config_gen.go
- tl_messages_get_dialog_filters_gen.go
- tl_messages_get_dialog_unread_marks_gen.go
- tl_messages_get_dialogs_gen.go
- tl_messages_get_discussion_message_gen.go
- tl_messages_get_document_by_hash_gen.go
- tl_messages_get_emoji_keywords_difference_gen.go
- tl_messages_get_emoji_keywords_gen.go
- tl_messages_get_emoji_keywords_languages_gen.go
- tl_messages_get_emoji_url_gen.go
- tl_messages_get_faved_stickers_gen.go
- tl_messages_get_featured_stickers_gen.go
- tl_messages_get_full_chat_gen.go
- tl_messages_get_game_high_scores_gen.go
- tl_messages_get_history_gen.go
- tl_messages_get_inline_bot_results_gen.go
- tl_messages_get_inline_game_high_scores_gen.go
- tl_messages_get_mask_stickers_gen.go
- tl_messages_get_message_edit_data_gen.go
- tl_messages_get_messages_gen.go
- tl_messages_get_messages_views_gen.go
- tl_messages_get_old_featured_stickers_gen.go
- tl_messages_get_onlines_gen.go
- tl_messages_get_peer_dialogs_gen.go
- tl_messages_get_peer_settings_gen.go
- tl_messages_get_pinned_dialogs_gen.go
- tl_messages_get_poll_results_gen.go
- tl_messages_get_poll_votes_gen.go
- tl_messages_get_recent_locations_gen.go
- tl_messages_get_recent_stickers_gen.go
- tl_messages_get_replies_gen.go
- tl_messages_get_saved_gifs_gen.go
- tl_messages_get_scheduled_history_gen.go
- tl_messages_get_scheduled_messages_gen.go
- tl_messages_get_search_counters_gen.go
- tl_messages_get_split_ranges_gen.go
- tl_messages_get_stats_url_gen.go
- tl_messages_get_sticker_set_gen.go
- tl_messages_get_stickers_gen.go
- tl_messages_get_suggested_dialog_filters_gen.go
- tl_messages_get_unread_mentions_gen.go
- tl_messages_get_web_page_gen.go
- tl_messages_get_web_page_preview_gen.go
- tl_messages_hide_peer_settings_bar_gen.go
- tl_messages_high_scores_gen.go
- tl_messages_import_chat_invite_gen.go
- tl_messages_inactive_chats_gen.go
- tl_messages_install_sticker_set_gen.go
- tl_messages_mark_dialog_unread_gen.go
- tl_messages_message_edit_data_gen.go
- tl_messages_message_views_gen.go
- tl_messages_messages_gen.go
- tl_messages_migrate_chat_gen.go
- tl_messages_peer_dialogs_gen.go
- tl_messages_read_discussion_gen.go
- tl_messages_read_encrypted_history_gen.go
- tl_messages_read_featured_stickers_gen.go
- tl_messages_read_history_gen.go
- tl_messages_read_mentions_gen.go
- tl_messages_read_message_contents_gen.go
- tl_messages_received_messages_gen.go
- tl_messages_received_queue_gen.go
- tl_messages_recent_stickers_gen.go
- tl_messages_reorder_pinned_dialogs_gen.go
- tl_messages_reorder_sticker_sets_gen.go
- tl_messages_report_encrypted_spam_gen.go
- tl_messages_report_gen.go
- tl_messages_report_spam_gen.go
- tl_messages_request_encryption_gen.go
- tl_messages_request_url_auth_gen.go
- tl_messages_save_draft_gen.go
- tl_messages_save_gif_gen.go
- tl_messages_save_recent_sticker_gen.go
- tl_messages_saved_gifs_gen.go
- tl_messages_search_counter_gen.go
- tl_messages_search_counter_vector_gen.go
- tl_messages_search_gen.go
- tl_messages_search_global_gen.go
- tl_messages_search_sticker_sets_gen.go
- tl_messages_send_encrypted_file_gen.go
- tl_messages_send_encrypted_gen.go
- tl_messages_send_encrypted_service_gen.go
- tl_messages_send_inline_bot_result_gen.go
- tl_messages_send_media_gen.go
- tl_messages_send_message_gen.go
- tl_messages_send_multi_media_gen.go
- tl_messages_send_scheduled_messages_gen.go
- tl_messages_send_screenshot_notification_gen.go
- tl_messages_send_vote_gen.go
- tl_messages_sent_encrypted_message_gen.go
- tl_messages_set_bot_callback_answer_gen.go
- tl_messages_set_bot_precheckout_results_gen.go
- tl_messages_set_bot_shipping_results_gen.go
- tl_messages_set_encrypted_typing_gen.go
- tl_messages_set_game_score_gen.go
- tl_messages_set_inline_bot_results_gen.go
- tl_messages_set_inline_game_score_gen.go
- tl_messages_set_typing_gen.go
- tl_messages_start_bot_gen.go
- tl_messages_sticker_set_gen.go
- tl_messages_sticker_set_install_result_gen.go
- tl_messages_stickers_gen.go
- tl_messages_toggle_dialog_pin_gen.go
- tl_messages_toggle_sticker_sets_gen.go
- tl_messages_uninstall_sticker_set_gen.go
- tl_messages_unpin_all_messages_gen.go
- tl_messages_update_dialog_filter_gen.go
- tl_messages_update_dialog_filters_order_gen.go
- tl_messages_update_pinned_message_gen.go
- tl_messages_upload_encrypted_file_gen.go
- tl_messages_upload_media_gen.go
- tl_messages_votes_list_gen.go
- tl_nearest_dc_gen.go
- tl_notify_peer_gen.go
- tl_null_gen.go
- tl_page_block_gen.go
- tl_page_caption_gen.go
- tl_page_gen.go
- tl_page_list_item_gen.go
- tl_page_list_ordered_item_gen.go
- tl_page_related_article_gen.go
- tl_page_table_cell_gen.go
- tl_page_table_row_gen.go
- tl_password_kdf_algo_gen.go
- tl_payment_charge_gen.go
- tl_payment_requested_info_gen.go
- tl_payment_saved_credentials_card_gen.go
- tl_payments_bank_card_data_gen.go
- tl_payments_clear_saved_info_gen.go
- tl_payments_get_bank_card_data_gen.go
- tl_payments_get_payment_form_gen.go
- tl_payments_get_payment_receipt_gen.go
- tl_payments_get_saved_info_gen.go
- tl_payments_payment_form_gen.go
- tl_payments_payment_receipt_gen.go
- tl_payments_payment_result_gen.go
- tl_payments_saved_info_gen.go
- tl_payments_send_payment_form_gen.go
- tl_payments_validate_requested_info_gen.go
- tl_payments_validated_requested_info_gen.go
- tl_peer_blocked_gen.go
- tl_peer_gen.go
- tl_peer_located_gen.go
- tl_peer_notify_settings_gen.go
- tl_peer_settings_gen.go
- tl_phone_accept_call_gen.go
- tl_phone_call_discard_reason_gen.go
- tl_phone_call_gen.go
- tl_phone_call_protocol_gen.go
- tl_phone_check_group_call_gen.go
- tl_phone_confirm_call_gen.go
- tl_phone_connection_gen.go
- tl_phone_create_group_call_gen.go
- tl_phone_discard_call_gen.go
- tl_phone_discard_group_call_gen.go
- tl_phone_edit_group_call_member_gen.go
- tl_phone_get_call_config_gen.go
- tl_phone_get_group_call_gen.go
- tl_phone_get_group_participants_gen.go
- tl_phone_group_call_gen.go
- tl_phone_group_participants_gen.go
- tl_phone_invite_to_group_call_gen.go
- tl_phone_join_group_call_gen.go
- tl_phone_leave_group_call_gen.go
- tl_phone_phone_call_gen.go
- tl_phone_received_call_gen.go
- tl_phone_request_call_gen.go
- tl_phone_save_call_debug_gen.go
- tl_phone_send_signaling_data_gen.go
- tl_phone_set_call_rating_gen.go
- tl_phone_toggle_group_call_settings_gen.go
- tl_photo_gen.go
- tl_photo_size_gen.go
- tl_photos_delete_photos_gen.go
- tl_photos_get_user_photos_gen.go
- tl_photos_photo_gen.go
- tl_photos_photos_gen.go
- tl_photos_update_profile_photo_gen.go
- tl_photos_upload_profile_photo_gen.go
- tl_poll_answer_gen.go
- tl_poll_answer_voters_gen.go
- tl_poll_gen.go
- tl_poll_results_gen.go
- tl_popular_contact_gen.go
- tl_post_address_gen.go
- tl_privacy_key_gen.go
- tl_privacy_rule_gen.go
- tl_received_notify_message_gen.go
- tl_received_notify_message_vector_gen.go
- tl_recent_me_url_gen.go
- tl_registry_gen.go
- tl_reply_markup_gen.go
- tl_report_reason_gen.go
- tl_restriction_reason_gen.go
- tl_rich_text_gen.go
- tl_saved_phone_contact_gen.go
- tl_saved_phone_contact_vector_gen.go
- tl_secure_credentials_encrypted_gen.go
- tl_secure_data_gen.go
- tl_secure_file_gen.go
- tl_secure_password_kdf_algo_gen.go
- tl_secure_plain_data_gen.go
- tl_secure_required_type_gen.go
- tl_secure_secret_settings_gen.go
- tl_secure_value_error_gen.go
- tl_secure_value_gen.go
- tl_secure_value_hash_gen.go
- tl_secure_value_type_gen.go
- tl_secure_value_vector_gen.go
- tl_send_message_action_gen.go
- tl_shipping_option_gen.go
- tl_stats_abs_value_and_prev_gen.go
- tl_stats_broadcast_stats_gen.go
- tl_stats_date_range_days_gen.go
- tl_stats_get_broadcast_stats_gen.go
- tl_stats_get_megagroup_stats_gen.go
- tl_stats_get_message_public_forwards_gen.go
- tl_stats_get_message_stats_gen.go
- tl_stats_graph_gen.go
- tl_stats_group_top_admin_gen.go
- tl_stats_group_top_inviter_gen.go
- tl_stats_group_top_poster_gen.go
- tl_stats_load_async_graph_gen.go
- tl_stats_megagroup_stats_gen.go
- tl_stats_message_stats_gen.go
- tl_stats_percent_value_gen.go
- tl_stats_url_gen.go
- tl_sticker_pack_gen.go
- tl_sticker_set_covered_class_vector_gen.go
- tl_sticker_set_covered_gen.go
- tl_sticker_set_gen.go
- tl_stickers_add_sticker_to_set_gen.go
- tl_stickers_change_sticker_position_gen.go
- tl_stickers_create_sticker_set_gen.go
- tl_stickers_remove_sticker_from_set_gen.go
- tl_stickers_set_sticker_set_thumb_gen.go
- tl_storage_file_type_gen.go
- tl_theme_gen.go
- tl_theme_settings_gen.go
- tl_top_peer_category_gen.go
- tl_top_peer_category_peers_gen.go
- tl_top_peer_gen.go
- tl_true_gen.go
- tl_update_gen.go
- tl_updates_channel_difference_gen.go
- tl_updates_difference_gen.go
- tl_updates_gen.go
- tl_updates_get_channel_difference_gen.go
- tl_updates_get_difference_gen.go
- tl_updates_get_state_gen.go
- tl_updates_state_gen.go
- tl_upload_cdn_file_gen.go
- tl_upload_file_gen.go
- tl_upload_get_cdn_file_gen.go
- tl_upload_get_cdn_file_hashes_gen.go
- tl_upload_get_file_gen.go
- tl_upload_get_file_hashes_gen.go
- tl_upload_get_web_file_gen.go
- tl_upload_reupload_cdn_file_gen.go
- tl_upload_save_big_file_part_gen.go
- tl_upload_save_file_part_gen.go
- tl_upload_web_file_gen.go
- tl_url_auth_result_gen.go
- tl_user_class_vector_gen.go
- tl_user_full_gen.go
- tl_user_gen.go
- tl_user_profile_photo_gen.go
- tl_user_status_gen.go
- tl_users_get_full_user_gen.go
- tl_users_get_users_gen.go
- tl_users_set_secure_value_errors_gen.go
- tl_video_size_gen.go
- tl_wall_paper_class_vector_gen.go
- tl_wall_paper_gen.go
- tl_wall_paper_settings_gen.go
- tl_web_authorization_gen.go
- tl_web_document_gen.go
- tl_web_page_attribute_theme_gen.go
- tl_web_page_gen.go