notify

package
v0.3.0-alpha.1 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Enabled is the master switch for notifications and alerts.
	Enabled bool `yaml:"enabled"`
	// Bell enables emitting the ASCII BEL character (\a) to the terminal.
	Bell bool `yaml:"bell"`
	// Desktop enables native operating-system desktop notifications.
	Desktop bool `yaml:"desktop"`
}

Config controls operator alert and notification behavior.

func DefaultConfig

func DefaultConfig() Config

DefaultConfig returns the default notification settings (all enabled).

func DisabledConfig

func DisabledConfig() Config

DisabledConfig returns settings with all notifications disabled.

type Notification

type Notification struct {
	Title     string
	Body      string
	SessionID string
	AgentName string
	Reason    string
	EventID   string
}

Notification carries display-safe information about an event needing operator attention.

type Notifier

type Notifier interface {
	Notify(Notification)
}

Notifier delivers operator notifications and alerts.

func New

func New(config Config, bellOutput io.Writer) Notifier

New constructs an active Notifier based on the given configuration.

func NewNoop

func NewNoop() Notifier

NewNoop returns a notifier that discards all notifications.

Jump to

Keyboard shortcuts

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