Documentation
¶
Index ¶
- Constants
- func ContentTypeForBodyType(bodyType string) (string, error)
- func ExportSecretPlain(config model.AlertConfig) (string, error)
- func ImportSecretPlain(plainText string) (string, error)
- func PlainView(config model.AlertConfig) (string, error)
- func ReencryptSecret(cipherText string) (string, error)
- func Resolve(config model.AlertConfig) (dto.AlertCustomWebhookResolvedConfig, error)
- func ValidateStored(config model.AlertConfig) error
- type PreparedConfig
Constants ¶
View Source
const ( MaskedSecret = "******" DefaultGenericJSONTemplate = `` /* 139-byte string literal not displayed */ )
Variables ¶
This section is empty.
Functions ¶
func ContentTypeForBodyType ¶
func ExportSecretPlain ¶
func ExportSecretPlain(config model.AlertConfig) (string, error)
func ImportSecretPlain ¶
func PlainView ¶
func PlainView(config model.AlertConfig) (string, error)
PlainView decrypts a custom webhook only for the authenticated alert-config read contract. The encrypted SecretConfig remains the sole persisted copy.
func ReencryptSecret ¶
func Resolve ¶
func Resolve(config model.AlertConfig) (dto.AlertCustomWebhookResolvedConfig, error)
func ValidateStored ¶
func ValidateStored(config model.AlertConfig) error
Types ¶
type PreparedConfig ¶
func NormalizeLegacy ¶
func NormalizeLegacy(rawConfig, status, fallbackName string) (PreparedConfig, string, bool, error)
func Prepare ¶
func Prepare(rawConfig, status string, existing *model.AlertConfig) (PreparedConfig, error)
Click to show internal directories.
Click to hide internal directories.