Documentation
¶
Overview ¶
Package manifest holds shared notification template and rule type definitions. It is a leaf package so rules and template engines can import it without cycles.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Override ¶
type Override struct {
Channel string `json:"channel"`
Format string `json:"format"`
Template string `json:"template"`
}
Override defines a channel-specific template override.
type Rule ¶
type Rule struct {
ID string `json:"id"`
Action RuleAction `json:"action"`
Match RuleMatch `json:"match"`
Condition string `json:"condition"`
Priority int `json:"priority"`
Params RuleParams `json:"params"`
}
Rule defines a notification filtering or aggregation rule.
type RuleAction ¶
type RuleAction string
RuleAction defines the action to take when a rule matches.
const ( RuleActionThrottle RuleAction = "throttle" RuleActionAggregate RuleAction = "aggregate" RuleActionMute RuleAction = "mute" RuleActionDrop RuleAction = "drop" )
Rule action constants.
type RuleParams ¶
type RuleParams struct {
Window string `json:"window"`
Limit int `json:"limit"`
DigestTplID string `json:"digest_template_id"`
DelayedSend bool `json:"delayed_send"`
}
RuleParams holds action-specific parameters.
type Template ¶
type Template struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
DefaultFormat string `json:"default_format"`
DefaultTemplate string `json:"default_template"`
Overrides []Override `json:"overrides"`
}
Template defines a notification message template with optional per-channel overrides.
Click to show internal directories.
Click to hide internal directories.