telegram

package
v0.0.0-...-740e771 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CommandResponses = map[string]string{
	"/start": "Welcome to the bot! Use /help to see available commands.",
	"/help":  "Here are the available commands:\n/start - Start the bot\n/help - Show this help message",
}

CommandResponses stores the predefined responses for specific commands

Functions

This section is empty.

Types

type Bot

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

func NewBot

func NewBot(token string, logger *slog.Logger, db *database.DB, serverHandler *x3ui.ServerHandler) (*Bot, error)

func (*Bot) NotifyAdmins

func (b *Bot) NotifyAdmins(message string)

NotifyAdmins sends a message to all admins

func (*Bot) Start

func (b *Bot) Start()

func (*Bot) Stop

func (b *Bot) Stop()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL