bot

package
v0.0.0-...-407f28a Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package bot contains routers and controllers for bots.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Ctrl

type Ctrl struct {
	Logger         *slog.Logger
	Store          store.Interface
	Service        *revisor.Service
	API            botx.API
	AdminIDs       []string
	AuthToken      string
	HandlerTimeout time.Duration
}

Ctrl provides routes and controllers for bot updates.

func (*Ctrl) NotifyAdmins

func (c *Ctrl) NotifyAdmins(ctx context.Context, msg string) error

NotifyAdmins sends a message to all admins.

func (*Ctrl) Routes

func (c *Ctrl) Routes() *botx.Router

Routes returns a multiplexer for bot controllers.

Jump to

Keyboard shortcuts

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