bot

package
v0.0.0-...-ea69daf Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MediaTypeWebp = "data:image/webp;base64,"
	MediaTypeJpg  = "data:image/jpeg;base64,"
)
View Source
const (
	StartCmd = "/start"
	AddAdCmd = "/add_ad"
	DelAdCmd = "/del_ad"
	AllAdCmd = "/all_ad"
)

Variables

View Source
var (
	Bot *tb.Bot
)

Functions

func AddAd

func AddAd(c tb.Context) error

func AllAd

func AllAd(c tb.Context) error

func BanChatMember

func BanChatMember(c tb.Context, res *adapter.RecognizeResult) (err error)

func CreatorCmdMiddleware

func CreatorCmdMiddleware(next tb.HandlerFunc) tb.HandlerFunc

func DelAd

func DelAd(c tb.Context) error

func Identifier

func Identifier() adapter.IModel

func LoadAdMenuBtn

func LoadAdMenuBtn(menu *tb.ReplyMarkup)

func OnChatMemberMessage

func OnChatMemberMessage(c tb.Context) error

func OnPhotoMessage

func OnPhotoMessage(c tb.Context) error

func OnStickerMessage

func OnStickerMessage(c tb.Context) error

func OnTextMessage

func OnTextMessage(c tb.Context) error

func PreCheck

func PreCheck(c tb.Context) (user *database.UserInfo, needCheck bool, err error)

func PreCmdMiddleware

func PreCmdMiddleware(next tb.HandlerFunc) tb.HandlerFunc

func PreGroupMiddleware

func PreGroupMiddleware(next tb.HandlerFunc) tb.HandlerFunc

func ProcessNickname

func ProcessNickname(nickname string) string

func RegisterCommands

func RegisterCommands()

func RegisterHandle

func RegisterHandle()

func Start

func Start() error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳