October 21, 2021
10am-5pm CT

Is that's possible to send url to an error or to stream in e-mail alert notifications on Graylog 4?

Description of your problem

I’m trying to set the e-mail Alert notifications with the URL of the error or the stream and it does not work.
I’m using Graylog 4.0.6

Description of steps you’ve taken to attempt to solve the issue

Created stream with the rules to receive an alert messages. Tried to add
${if backlog}Detail message hyperlink: ${foreach backlog msg}${msg.index}/${}
${end}${else} ${end}
for the error URL,seems like does not working.

I found on the forum that stream linking is not supported from 3.4.

I wounder if it’s possible to include URL of the Error or Stream in the alert message.

Operating system information

Windows Server


I have done what I believe your asking. Noted this is for Graylog version 4.0 and below. The newer GL version have HTML Body Template added to the notification template. If your using HTML that also has to be configured.

For an example here is my Notification Template /w out HTML

--- [Event Definition] ---------------------------
Title:       ${event_definition_title}
Description: ${event_definition_description}
Type:        ${event_definition_type}
--- [Event] --------------------------------------
Timestamp:            ${event.timestamp}
Message:              ${event.message}
Source:               ${event.source}
Priority:             ${event.priority}
Alert:                ${event.alert}
Timestamp Processing: ${event.timestamp}
Timerange Start:      ${event.timerange_start}
Timerange End:        ${event.timerange_end}
Stream URL:           ${event.stream_name}          
${if stream_url}Stream URL: ${stream_url}${end}

${if backlog}
--- [Backlog] ------------------------------------
Last messages accounting for this alert:
${foreach backlog message}${message.index}/${}
User:             ${message.fields.TargetUserName}
WorkStation Name:  ${message.fields.WorkstationName}
Event Time:       ${message.fields.EventReceivedTime}
Source:           ${message.source}
Logon Type:       ${message.LogonType}
---[backlog end]---------------------------------

Email notification received.


Hope that helps

Thank you, it works.

1 Like