Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Notification ¶
type Notifier ¶
type Notifier interface {
Name() string
// Notify is called for a payload event that is sent in full.
Notify(context.Context, *Notification) error
// NotifyBatch is called with events batched over a window, all for the same user and payload.
NotifyBatch(context.Context, []*Notification) error
// RateLimit returns how fast Notify and NotifyBatch may be called, per messenger API limits.
RateLimit() (rate.Limit, int)
}
Notifier must be implemented by all modules, which are going to notify users about payload events.
Click to show internal directories.
Click to hide internal directories.