Documentation ¶
Index ¶
Constants ¶
View Source
const ( // PollerTimeout is the default timeout for the bot poller. PollerTimeout = 10 * time.Second // VLANSelectCacheSize is the default size of the VLAN select cache. VLANSelectCacheSize = 100 // RandomIDLength is the default length of the random IDs. RandomIDLength = 32 )
Variables ¶
View Source
var ErrFailedToReadData = fmt.Errorf("failed to read data from message")
ErrFailedToReadData is returned when the data from the message could not be read.
Functions ¶
This section is empty.
Types ¶
type BotServer ¶
type BotServer struct {
// contains filtered or unexported fields
}
BotServer is a Telegram bot server.
func NewBotServer ¶
func NewBotServer(ctx context.Context, cfg *config.Config, db database.Database) (*BotServer, error)
NewBotServer creates a new BotServer.
func (*BotServer) NotifyLoginAttempt ¶
NotifyLoginAttempt sends a message to all the chat IDs when a login attempt is detected.
Click to show internal directories.
Click to hide internal directories.