webhook

package
v0.31.3 Latest Latest
Warning

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

Go to latest
Published: May 17, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewWebhookChannel

func NewWebhookChannel() notify.Channel

Types

type Config

type Config struct {
	EndpointURL    string            `json:"endpoint_url"`
	TimeoutSeconds int               `json:"timeout_seconds"`
	HMACSecret     string            `json:"hmac_secret,omitempty"`
	Headers        map[string]string `json:"headers,omitempty"`
}

type WebhookChannel

type WebhookChannel struct {
	// contains filtered or unexported fields
}

func (*WebhookChannel) Close

func (w *WebhookChannel) Close(ctx context.Context) error

func (*WebhookChannel) Healthy

func (w *WebhookChannel) Healthy() bool

func (*WebhookChannel) Init

func (*WebhookChannel) OnInbound

func (w *WebhookChannel) OnInbound(handler notify.InboundHandler)

func (*WebhookChannel) Send

func (*WebhookChannel) SupportsInbound

func (w *WebhookChannel) SupportsInbound() bool

func (*WebhookChannel) Type

func (w *WebhookChannel) Type() string

type WebhookPayload

type WebhookPayload struct {
	EventType string                 `json:"event_type"`
	Title     string                 `json:"title"`
	Text      string                 `json:"text"`
	Link      string                 `json:"link,omitempty"`
	Payload   map[string]interface{} `json:"payload,omitempty"`
}

Jump to

Keyboard shortcuts

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