notifier

package
v0.2.20 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Notifier

type Notifier interface {
	// 发送通知。
	//
	// 入参:
	//   - ctx:上下文。
	//   - subject:通知主题。
	//   - message:通知内容。
	//
	// 出参:
	//   - res:发送结果。
	//   - err: 错误。
	Notify(ctx context.Context, subject string, message string) (res *NotifyResult, err error)
}

表示定义消息通知器的抽象类型接口。

type NotifyResult

type NotifyResult struct {
	NotificationData map[string]any `json:"notificationData,omitempty"`
}

表示通知发送结果的数据结构。

Directories

Path Synopsis
providers

Jump to

Keyboard shortcuts

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