Versions in this module Expand all Collapse all v1 v1.1.0 Dec 21, 2023 Changes in this version type SMTPParams + InsecureSkipVerify bool v1.0.0 Aug 13, 2023 v0 v0.2.0 Oct 2, 2022 Changes in this version type SMTPParams + LoginAuth bool v0.1.1 May 20, 2022 v0.1.0 Apr 29, 2022 Changes in this version + func EscapeTelegramText(text string) string + func Send(ctx context.Context, notifiers []Notifier, destination, text string) error + func TelegramSupportedHTML(htmlText string) string + type Email struct + func NewEmail(smtpParams SMTPParams) *Email + func (e *Email) Schema() string + func (e *Email) Send(ctx context.Context, destination, text string) error + func (e *Email) String() string + type Notifier interface + Schema func() string + Send func(ctx context.Context, destination, text string) error + type SMTPParams struct + Charset string + ContentType string + Host string + Password string + Port int + StartTLS bool + TLS bool + TimeOut time.Duration + Username string + type Slack struct + func NewSlack(token string, opts ...slack.Option) *Slack + func (s *Slack) Schema() string + func (s *Slack) Send(ctx context.Context, destination, text string) error + func (s *Slack) String() string + type Telegram struct + func NewTelegram(params TelegramParams) (*Telegram, error) + func (t *Telegram) AddToken(token, user, site string, expires time.Time) + func (t *Telegram) CheckToken(token, user string) (telegram, site string, err error) + func (t *Telegram) GetBotUsername() string + func (t *Telegram) ProcessUpdate(ctx context.Context, textUpdate string) error + func (t *Telegram) Request(ctx context.Context, method string, b []byte, data interface{}) error + func (t *Telegram) Run(ctx context.Context) + func (t *Telegram) Schema() string + func (t *Telegram) Send(ctx context.Context, destination, text string) error + func (t *Telegram) String() string + type TelegramBotInfo struct + Username string + type TelegramParams struct + ErrorMsg string + SuccessMsg string + Timeout time.Duration + Token string + type TelegramUpdate struct + Result []struct{ ... } + type Webhook struct + func NewWebhook(params WebhookParams) *Webhook + func (wh *Webhook) Schema() string + func (wh *Webhook) Send(ctx context.Context, destination, text string) error + func (wh *Webhook) String() string + type WebhookParams struct + Headers []string + Timeout time.Duration