birthdays

package
v0.0.0-...-eb4b608 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2023 License: Unlicense Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Plugin

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

func New

func New(bot *telebot.Bot, birthdayService Service) *Plugin

func (*Plugin) Commands

func (p *Plugin) Commands() []telebot.Command

func (*Plugin) Handlers

func (p *Plugin) Handlers(botInfo *telebot.User) []plugin.Handler

func (*Plugin) Name

func (p *Plugin) Name() string

type Service

type Service interface {
	BirthdayNotificationsEnabled(chat *telebot.Chat) (bool, error)
	DeleteBirthday(user *telebot.User) error
	Birthdays(chat *telebot.Chat) ([]model.User, error)
	DisableBirthdayNotifications(chat *telebot.Chat) error
	EnableBirthdayNotifications(chat *telebot.Chat) error
	SetBirthday(user *telebot.User, birthday time.Time) error
	TodaysBirthdays() (map[int64][]model.User, error)
}

Jump to

Keyboard shortcuts

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