Skip to content

Conversation

@MichaelUray
Copy link

Description:
Added more json fields to the AlertStatus webhook notification.
Added make test in documentation "Contributing to GoAlert".

for AlertStatus updates:

	Summary     string
	Details     string
	ServiceID   string
	ServiceName string
	Meta        map[string]string

Before these fields were only available in Alert notifications and it was not possible to send them to the user with acknowledge or close events.
notification for Alart and AlartStatus
Before was that field not available and it was not possible to send them to the user with messages.
MichaelUray and others added 2 commits December 1, 2025 23:00
Co-authored-by: Nathaniel Caza <mastercactapus@gmail.com>
AlertURL contains the full link to the alert page, or to the alarm list of the according service if it is an alert bundle.
Comment on lines 133 to 142
AlertURL: fmt.Sprintf("%s/alerts/%d", pubURL, m.AlertID),
}
case notification.AlertBundle:
payload = POSTDataAlertBundle{
AppName: cfg.ApplicationName(),
Type: "AlertBundle",
ServiceID: m.ServiceID,
ServiceName: m.ServiceName,
Count: m.Count,
AlertURL: fmt.Sprintf("%s/services/%s/alerts", pubURL, m.ServiceID),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These need to use cfg.CallbackURL which accounts for things like the short URL generation

for example cfg.CallbackURL(fmt.Sprintf("/services/%s/alerts", m.ServiceID))

fmt.Sprintf("%s/alerts/%d", pubURL, m.AlertID)
with
cfg.CallbackURL(fmt.Sprintf("/alerts/%d", m.AlertID))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants