Documentation ¶
Index ¶
Constants ¶
View Source
const TYPE_FTQQ_V1 = "ftqq_v1"
View Source
const TYPE_FTQQ_V2 = "ftqq_v2"
View Source
const TYPE_QMSG_CHAT = "qmsg_chat"
View Source
const TYPE_QMSG_GROUP_CHAT = "qmsg_group_chat"
View Source
const TYPE_TELEGRAM = "telegram"
Variables ¶
This section is empty.
Functions ¶
func TesterHandler ¶
func TesterHandler(targetArr []TargetConfig, notifierConfig NotifierConfig) string
TesterHandler is the entry func of the application.
Types ¶
type FtqqV1Notifier ¶
type FtqqV1Notifier struct{}
FtqqV1Notifier support WeChat .etc, see https://sct.ftqq.com/
func (FtqqV1Notifier) Notify ¶
func (notifier FtqqV1Notifier) Notify(msgToSend string, config NotifierConfig)
type FtqqV2Notifier ¶
type FtqqV2Notifier struct{}
FtqqV2Notifier support WeChat .etc, see https://sct.ftqq.com/
func (FtqqV2Notifier) Notify ¶
func (notifier FtqqV2Notifier) Notify(msgToSend string, config NotifierConfig)
type Notifier ¶
type Notifier interface {
Notify(msgToSend string, config NotifierConfig)
}
Notifier is the abstract interface for notifying users.
func GetNotifierByType ¶
GetNotifierByType is the way to produce concret notifier singleton instance.
type NotifierConfig ¶
type QmsgChatNotifier ¶
type QmsgChatNotifier struct{}
QmsgChatNotifier support QQ single chat, see https://qmsg.zendee.cn/index.html
func (QmsgChatNotifier) Notify ¶
func (notifier QmsgChatNotifier) Notify(msgToSend string, config NotifierConfig)
type QmsgGroupChatNotifier ¶
type QmsgGroupChatNotifier struct{}
QmsgGroupChatNotifier support QQ single chat, see https://qmsg.zendee.cn/index.html
func (QmsgGroupChatNotifier) Notify ¶
func (notifier QmsgGroupChatNotifier) Notify(msgToSend string, config NotifierConfig)
type TargetConfig ¶
type TargetConfig struct { URL string `json:"url"` ExpectedStatusCode int `json:"expectedStatusCode"` IgnoreAnalysis bool `json:"ignoreAnalysis"` NotifyMethod string `json:"notifyMethod"` }
TargetConfig is the info pair of the target url to be tested.
type TelegramNotifier ¶
type TelegramNotifier struct{}
TelegramNotifier, support Telegram, see url-tester-func docs.
func (TelegramNotifier) Notify ¶
func (notifier TelegramNotifier) Notify(msgToSend string, config NotifierConfig)
Click to show internal directories.
Click to hide internal directories.