What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

How to remove buttons with Slack integration

Votes:

0

While they might be useful for some, we'd like to remove the buttons that present with alarms in our Slack integration. We've opted to Define custom content in our Notification template, and removed many of the placeholders to streamline our received messages.

Specifically, the buttons are: Scan Now Acknowledge Alarm Pause Pause for 60 minutes Resume

notifications prtg slack

Created on Nov 1, 2018 10:13:24 PM



4 Replies

Accepted Answer

Votes:

1

Hello there,

The built-in Slack notification cannot be edited, however, you can create alternatively an Execute HTTP Action notification:

  1. Add the url of your Slack webhook
  2. Set HTTP Method to POST
  3. For "Payload" you can use something like this then for example: payload={ "text": "%device %status %down (%message)...", "link_names": 1, "attachments": [ { "title": "Sensor: %device %name", "title_link": "%homesensor.htm?id=%sensorid", "text": "*Status:* %status %down \n*Date/Time:* %datetime \n*Last Result:* %lastvalue \n*Last Message:* %message \n*Probe:* %probe \n*Group:* %group \n*Device:* %device () \n*Last Scan:* %lastcheck \n*Last Up:* %lastup \n*Last Down:* %lastdown \n*Uptime:* %uptime \n*Downtime:* %downtime \n*Cumulated since:* %cumsince \n*Location:* %location", "color": "%colorofstate", "mrkdwn_in": ["text", "pretext"] } ] }

Here you can find all PRTG placeholders if you like to adjust the content further.

Kind regards,

Erhard

Created on Nov 2, 2018 8:30:20 AM by  Erhard Mikulik [Paessler Support]

Last change on Nov 6, 2018 6:39:21 AM by  Erhard Mikulik [Paessler Support]



Votes:

0

This has worked exactly as we wanted. Thanks for the support.

Created on Nov 5, 2018 6:43:06 PM



Votes:

0

Hi - currently just tried to set this up and not receiving anything in Slack? Has the required config changed in later updates?

-Dave

Created on Jun 6, 2022 5:11:31 PM



Votes:

0

Hi Dave,

Thank you for your message.

The API of Slack might have indeed changed since the creation of this post and therefore the payload and URL might need to be adapted.

According to the documentation of Slack, the data is expected in JSON format and therefore it is also necessary to use a custom script (ex: PowerShell) with the Execute Program action within the notification template (Execute HTTP action doesn't support JSON/XML).

To do so, you need to copy the script under "C:\Program Files (x86)\PRTG Network Monitor\Notifications\EXE" on the PRTG server.

Here is the documentation from Slack for further information: https://api.slack.com/messaging/webhooks

Regards.

Created on Jun 9, 2022 11:45:16 AM by  Florian Lesage [Paessler Support]

Last change on Jun 9, 2022 11:47:14 AM by  Florian Lesage [Paessler Support]




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.