Documentation
¶
Index ¶
- func GetAll(config Config) map[string]Notifier
- type BasicAuth
- type Config
- type EmailOptions
- type GrafanaAnnotation
- type GrafanaOptions
- type Header
- type Notification
- type Notifier
- type OpsgenieOptions
- type SlackNotification
- type SlackOptions
- type SlackSpecific
- type WebhookNotification
- type WebhookOptions
- type WebhookSettings
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { Email *EmailOptions `json:"email"` Slack *SlackOptions `json:"slack"` Opsgenie *OpsgenieOptions `json:"opsgenie"` Grafana *GrafanaOptions `json:"grafana"` Webhook *WebhookOptions `json:"webhook"` }
type EmailOptions ¶
type GrafanaAnnotation ¶ added in v0.6.0
type GrafanaOptions ¶ added in v0.6.0
type Notification ¶ added in v0.4.0
type Notification struct { Title string `json:"title,omitempty"` Body string `json:"body,omitempty"` Slack *SlackNotification `json:"slack,omitempty"` Webhook map[string]WebhookNotification `json:"webhook,omitempty" patchStrategy:"replace"` }
type Notifier ¶
type Notifier interface {
Send(notification Notification, recipient string) error
}
func NewEmailNotifier ¶
func NewEmailNotifier(opts EmailOptions) Notifier
func NewGrafanaNotifier ¶ added in v0.6.0
func NewGrafanaNotifier(opts GrafanaOptions) Notifier
func NewOpsgenieNotifier ¶ added in v0.4.0
func NewOpsgenieNotifier(opts OpsgenieOptions) Notifier
func NewSlackNotifier ¶
func NewSlackNotifier(opts SlackOptions) Notifier
func NewWebhookNotifier ¶ added in v0.6.0
func NewWebhookNotifier(opts WebhookOptions) Notifier
type OpsgenieOptions ¶ added in v0.4.0
type SlackNotification ¶ added in v0.6.0
type SlackOptions ¶
type SlackSpecific ¶ added in v0.4.0
type WebhookNotification ¶ added in v0.6.0
type WebhookOptions ¶ added in v0.6.0
type WebhookOptions []WebhookSettings
WebhookOptions holds list of configured webhooks settings
Source Files
¶
Click to show internal directories.
Click to hide internal directories.