notifiers

package
v2.2.5-rc3+incompatible Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2019 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClientFromConfig

func NewClientFromConfig(cfg *v3.HTTPClientConfig) (*http.Client, error)

NewClientFromConfig returns a new HTTP client configured for the given HTTPClientConfig.

func SendMessage

func SendMessage(notifier *v3.Notifier, recipient string, msg *Message) error

func TestEmail

func TestEmail(host, password, username string, port int, requireTLS bool, title, content, receiver, sender string) error

func TestPagerduty

func TestPagerduty(key, msg string, cfg *v3.HTTPClientConfig) error

func TestSlack

func TestSlack(url, channel, msg string, cfg *v3.HTTPClientConfig) error

func TestWebhook

func TestWebhook(url, msg string, cfg *v3.HTTPClientConfig) error

func TestWechat

func TestWechat(secret, agent, corp, receiverType, receiver, msg string, cfg *v3.HTTPClientConfig) error

Types

type Message

type Message struct {
	Title   string
	Content string
}

Jump to

Keyboard shortcuts

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