So far the only placeholder that successfully resolve is the %sitename. Are the other placeholders in the list available for use in the POSTDATA section of the HTTP notification?
Thanks.
Article Comments
I've already seen that KB article, but when I tried to use any of the placeholders (like %device, %status, %message) they only come up verbatim.
e.g,:
[%name] down Alert for '%server' %device is %down
That's why I would like to know if the placeholders usable inside the POSTDATA of an HTTP notification is different than that for email or other notification methods.
Thanks a lot.
Regards, Arthur
Aug, 2015 - Permalink
Hello Arthur,
please confirm that you are you running the latest PRTG version and how are you testing the HTTP Notification? Using the "Test" button within notifications or assigning the notification to a sensor and simulating an error status?
I've just tested the Postadata you've mentioned:
URL | http://YOURPRTGSERVER/errorurl/ |
Postdata | [%name] down Alert for '%server' %device is %down |
I've tested it against the own HTTP Server of PRTG so that I could review it in the webserver's access log and this is the result in the webserver's log and the notification did update the placeholders according to the values in the device/sensor.
/errorurl/?%5BGreen%20IT%20%28Green%20IT%29%5D%20down%20Alert%20for%20%27DependencyTest%27%20DependencyTest%20is%20&errormsg=
In the test above, the sensor's name is "Green IT" and the device's name is "Dependency Test".
Aug, 2015 - Permalink
Hi,
If I use the simulate error status or set notification on an actual warning, it works! The test button is not processing the placeholders properly but simulate is fine.
Thanks a lot.
Aug, 2015 - Permalink
Thank you for your feedback vivican.
It's great to hear that you got it working.
The test button will never substitute any placeholders, the test button sends the raw placeholders, its actually meant to test the end-to-end "delivery" of the message(Actually an HTTP operation in this case).
Best Regards,
Aug, 2015 - Permalink
Hello vivacan,
There's an article in our KB that lists all possible placeholders that can be used within notifications. I hope that helps :)
Best Regards,
Aug, 2015 - Permalink