Versions in this module Expand all Collapse all v1 v1.5.2 May 27, 2023 Changes in this version + func Idle() + type BasicClient struct + AllowedUpdates []string + AntiFloodData map[int64]*rawTypes.AntiFloodData + Beta bool + BotApiConfig Config + DownloadRefreshRate time.Duration + LoggerColorful bool + LoggerWriter Writer + LoggingLevel logger.LogLevel + MaxGoRoutines int + NoUpdates bool + SleepThreshold int + func (ctx *BasicClient) Clone(token string, dropUpdates bool, maxConnections int) error + func (ctx *BasicClient) OnAnyEditedMessage(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnAnyMessage(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnAnyMessageEvent(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnCallbackQuery(handler func(client *Client, update types.CallbackQuery)) + func (ctx *BasicClient) OnChannelPost(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnChatJoinRequest(handler func(client *Client, update types.ChatJoinRequest)) + func (ctx *BasicClient) OnChatMember(handler func(client *Client, update types.ChatMemberUpdated)) + func (ctx *BasicClient) OnChosenInlineResult(handler func(client *Client, update types.ChosenInlineResult)) + func (ctx *BasicClient) OnEditedChannelPost(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnEditedMessage(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnInlineQuery(handler func(client *Client, update types.InlineQuery)) + func (ctx *BasicClient) OnMessage(handler func(client *Client, update types.Message)) + func (ctx *BasicClient) OnMyChatMember(handler func(client *Client, update types.ChatMemberUpdated)) + func (ctx *BasicClient) OnPoll(handler func(client *Client, update types.Poll)) + func (ctx *BasicClient) OnPollAnswer(handler func(client *Client, update types.PollAnswer)) + func (ctx *BasicClient) OnPreCheckoutQuery(handler func(client *Client, update types.PreCheckoutQuery)) + func (ctx *BasicClient) OnRawUpdate(handler func(client *Client, update types.Update)) + func (ctx *BasicClient) OnShippingQuery(handler func(client *Client, update types.ShippingQuery)) + func (ctx *BasicClient) SetupBotAPI(hostName string, port int, https bool) + func (ctx *BasicClient) Stop() + type Client struct + Token string + func (ctx *Client) DownloadBytes(fileId string, progress rawTypes.ProgressCallable) ([]byte, error) + func (ctx *Client) DownloadFile(fileId, filePath string, progress rawTypes.ProgressCallable) error + func (ctx *Client) DownloadMedia(message types.Message, filePath string, progress rawTypes.ProgressCallable) error + func (ctx *Client) Invoke(method rawTypes.Method) (*rawTypes.Result, error) + func (ctx *Client) IsRunning() bool + func (ctx *Client) Self() types.User + type Config struct + HTTPS bool + HostName string + Port int + type Logger interface + Debug func(*Client, string, ...any) + Error func(*Client, string, ...any) + Info func(*Client, string, ...any) + Warn func(*Client, string, ...any) + func NewLogger(writer Writer, config logger.Config) Logger + type PollingClient struct + PollingTimeout time.Duration + func NewClient(token string) *PollingClient + func (ctx *PollingClient) Run() error + func (ctx *PollingClient) Start() error + type ServerConfig struct + HostName string + Port int + type WebhookClient struct + WebhookConfig *WebhookConfig + func NewWebhook(hostname string, port int) *WebhookClient + func NewWebhookWithCert(hostname string, port int, certFile, keyFile string) (*WebhookClient, error) + func (ctx *WebhookClient) Run() error + func (ctx *WebhookClient) Start() error + func (ctx *WebhookClient) Stop() + type WebhookConfig struct + CertificateFile string + Config ServerConfig + KeyFile string + func (ctx *WebhookConfig) GetAddress() string + type Writer interface + Printf func(string, ...any)