webhook

package
v0.0.0-...-f3f1ec7 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Call(string, string, string)
	CallWithErrorMessage(errMessage string)
}

Client defines the webhook client.

func New

func New(url string, timeout time.Duration, interval time.Duration) Client

New creates a new instance of webhook client

type Informer

type Informer interface {
	Add(Listener)
	Start()
}

Informer listens client events. For example, git-sync may call this informer periodically.

func NewInformer

func NewInformer(port int64) Informer

type Listener

type Listener func(string, string, string, string)

Listener is a callback function which is triggered on every event.

Jump to

Keyboard shortcuts

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