pingdom

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2017 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DisplayName      = "Pingdom"
	HandlerKey       = "pingdom"
	MessageDirection = "out"
	DocumentationURL = "https://www.pingdom.com/resources/webhooks"
)

Variables

This section is empty.

Functions

func ExampleMessage

func ExampleMessage(cfg config.Configuration, data util.ExampleData, eventSlug string) (cc.Message, error)

func Normalize

func Normalize(cfg config.Configuration, bytes []byte) (cc.Message, error)

Types

type Handler

type Handler struct {
	Config  config.Configuration
	Adapter adapters.Adapter
}

FastHttp request handler for Travis CI outbound webhook

func NewHandler

func NewHandler(cfg config.Configuration, adapter adapters.Adapter) Handler

FastHttp request handler constructor for Travis CI outbound webhook

func (Handler) HandleFastHTTP

func (h Handler) HandleFastHTTP(ctx *fasthttp.RequestCtx)

HandleFastHTTP is the method to respond to a fasthttp request.

func (Handler) HandlerKey

func (h Handler) HandlerKey() string

func (Handler) MessageDirection

func (h Handler) MessageDirection() string

type PingdomOutCheckParams

type PingdomOutCheckParams struct {
	BasicAuth  bool   `json:"basic_auth,omitempty"`
	Encryption bool   `json:"encryption,omitempty"`
	FullURL    string `json:"full_url,omitempty"`
	Header     string `json:"header,omitempty"`
	Hostname   string `json:"hostname,omitempty"`
	IPV6       bool   `json:"ipv6,omitempty"`
	Port       int    `json:"port,omitempty"`
	URL        string `json:"url,omitempty"`
}

type PingdomOutMessage

type PingdomOutMessage struct {
	CheckId               int64                 `json:"check_id,omitempty"`
	CheckName             string                `json:"check_name,omitempty"`
	CheckType             string                `json:"check_type,omitempty"`
	CheckParams           PingdomOutCheckParams `json:"check_params,omitempty"`
	Tags                  []string              `json:"tags,omitempty"`
	PreviousState         string                `json:"previous_state,omitempty"`
	CurrentState          string                `json:"current_state,omitempty"`
	StateChangedTimestamp int64                 `json:"state_changed_timestamp,omitempty"`
	StateChangedUTCTime   string                `json:"state_changed_utc_time,omitempty"`
	LongDescription       string                `json:"long_description,omitempty"`
	Description           string                `json:"description,omitempty"`
	FirstProbe            PingdomOutProbe       `json:"first_probe,omitempty"`
	SecondProbe           PingdomOutProbe       `json:"second_probe,omitempty"`
}

func PingdomOutMessageFromBytes

func PingdomOutMessageFromBytes(bytes []byte) (PingdomOutMessage, error)

func (*PingdomOutMessage) CheckURL

func (msg *PingdomOutMessage) CheckURL() string

type PingdomOutProbe

type PingdomOutProbe struct {
	IP       string
	IPV6     string
	Location string
}

Jump to

Keyboard shortcuts

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