notifier

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnknownNotification = errors.New("slacknotifier: unknown notification")
	ErrInvalidLanguage     = errors.New("slacknotifier: invalid language")
)

Functions

This section is empty.

Types

type Notifier

type Notifier interface {
	Notify(
		ctx context.Context,
		notification *senderproto.Notification,
		recipient *notificationproto.Recipient,
		language notificationproto.Recipient_Language,
	) error
}

func NewSlackNotifier

func NewSlackNotifier(webURL string, opts ...Option) Notifier

type Option

type Option func(*options)

func WithLogger

func WithLogger(logger *zap.Logger) Option

func WithMetrics

func WithMetrics(r metrics.Registerer) Option

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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