@@ -58,6 +58,9 @@ const (
5858 KeyNotifyDingtalkSecret = "notification.dingtalkSecret" // string
5959 KeyNotifyWebhookURL = "notification.webhookUrl" // string
6060 KeyNotifyWebhookSecret = "notification.webhookSecret" // string
61+ KeyNotifyWecomURL = "notification.wecomUrl" // string
62+ KeyNotifyFeishuURL = "notification.feishuUrl" // string
63+ KeyNotifyFeishuSecret = "notification.feishuSecret" // string
6164 KeyNotifyInAppEnabled = "notification.inAppEnabled" // bool
6265
6366 // 登录方式(外部身份源,L3 运行时配置——Harbor 模式:yaml 仅作
@@ -93,6 +96,7 @@ var ValidKeys = map[string]struct{}{
9396 KeyNotifySMTPUser : {}, KeyNotifySMTPPassword : {}, KeyNotifySMTPFrom : {},
9497 KeyNotifyDingtalkURL : {}, KeyNotifyDingtalkSecret : {},
9598 KeyNotifyWebhookURL : {}, KeyNotifyWebhookSecret : {}, KeyNotifyInAppEnabled : {},
99+ KeyNotifyWecomURL : {}, KeyNotifyFeishuURL : {}, KeyNotifyFeishuSecret : {},
96100
97101 KeyAuthLdapEnabled : {}, KeyAuthLdapAddr : {}, KeyAuthLdapBaseDn : {},
98102 KeyAuthLdapBindDn : {}, KeyAuthLdapBindPassword : {}, KeyAuthLdapUserFilter : {},
@@ -406,6 +410,10 @@ type NotificationSnapshot struct {
406410 WebhookURL string `json:"webhookUrl"`
407411 WebhookSecretSet bool `json:"webhookSecretSet"`
408412 WebhookSecretMasked string `json:"webhookSecretMasked,omitempty"`
413+ WecomURL string `json:"wecomUrl"`
414+ FeishuURL string `json:"feishuUrl"`
415+ FeishuSecretSet bool `json:"feishuSecretSet"`
416+ FeishuSecretMasked string `json:"feishuSecretMasked,omitempty"`
409417 InAppEnabled bool `json:"inAppEnabled"`
410418 Sources map [string ]string `json:"sources"`
411419}
@@ -420,6 +428,8 @@ func (l *Layered) NotificationSnapshot() NotificationSnapshot {
420428 SMTPFrom : stringOrEmpty (l .GetString (context .Background (), KeyNotifySMTPFrom )),
421429 DingtalkURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyDingtalkURL )),
422430 WebhookURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyWebhookURL )),
431+ WecomURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyWecomURL )),
432+ FeishuURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyFeishuURL )),
423433 InAppEnabled : l .GetBool (KeyNotifyInAppEnabled , true ),
424434 Sources : map [string ]string {},
425435 }
@@ -437,6 +447,7 @@ func (l *Layered) NotificationSnapshot() NotificationSnapshot {
437447 snap .SMTPPasswordSet , snap .SMTPPasswordMasked = mask (KeyNotifySMTPPassword )
438448 snap .DingtalkSecretSet , snap .DingtalkSecretMasked = mask (KeyNotifyDingtalkSecret )
439449 snap .WebhookSecretSet , snap .WebhookSecretMasked = mask (KeyNotifyWebhookSecret )
450+ snap .FeishuSecretSet , snap .FeishuSecretMasked = mask (KeyNotifyFeishuSecret )
440451 return snap
441452}
442453
@@ -468,6 +479,9 @@ type NotifyChannelsResolved struct {
468479 DingtalkSecret string
469480 WebhookURL string
470481 WebhookSecret string
482+ WecomURL string
483+ FeishuURL string
484+ FeishuSecret string
471485 InAppEnabled bool
472486 EmailEnabled bool
473487}
@@ -479,6 +493,9 @@ func (l *Layered) NotifyChannels() NotifyChannelsResolved {
479493 DingtalkSecret : stringOrEmpty (l .GetString (context .Background (), KeyNotifyDingtalkSecret )),
480494 WebhookURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyWebhookURL )),
481495 WebhookSecret : stringOrEmpty (l .GetString (context .Background (), KeyNotifyWebhookSecret )),
496+ WecomURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyWecomURL )),
497+ FeishuURL : stringOrEmpty (l .GetString (context .Background (), KeyNotifyFeishuURL )),
498+ FeishuSecret : stringOrEmpty (l .GetString (context .Background (), KeyNotifyFeishuSecret )),
482499 InAppEnabled : l .GetBool (KeyNotifyInAppEnabled , true ),
483500 EmailEnabled : l .GetBool (KeyNotifyEmailEnabled , false ),
484501 }
0 commit comments