Page 1 of 1
Custom Message in Notifications!!
Posted: Tuesday 10 December 2019 14:31
by Ressler
Hi all,
I'm trying to use notifications on an alert (dummy) to send myself a Pushover message.
This alert is activated via MQTT. I'm able to trigger the alert and the set Pushover action using the sensor but am struggling with the content of the message itself. I found that $value in the 'custom message' field returns me the state of the alert - 0/1/2/3/ etc. but not the text itself inside of my received Pushover message. What is the variable to use for this text?[
url=https://reversephonelookup.onl/]reverse phone lookup[/url]nba reddit pcpartpicker
Thanks in advance.
Re: Custom Message in Notifications!!
Posted: Tuesday 10 December 2019 23:33
by waaren
Ressler wrote: ↑Tuesday 10 December 2019 14:31
I'm trying to use notifications on an alert (dummy) to send myself a Pushover message.
This alert is activated via MQTT. I'm able to trigger the alert and the set Pushover action using the sensor but am struggling with the content of the message itself. I found that $value in the 'custom message' field returns me the state of the alert - 0/1/2/3/ etc. but not the text itself inside of my received Pushover message. What is the variable to use for this text?
I don't think there is another variable then $value and $name. If you want more flexibility you could consider scripting. In dzVents you can control the complete message. (see
dzVents wiki for howto )

- Notification.png (113.02 KiB) Viewed 1883 times
When not yet familiar with dzVents please start with reading
Get started Before implementing (~ 5 minutes). Special attention please for "In Domoticz go to Setup > Settings > Other and in the section EventSystem make sure the checkbox 'dzVents disabled' is not checked. Also make sure that in the Security section in the settings you allow 127.0.0.1 to not need a password. dzVents uses that port to send certain commands to Domoticz. Finally make sure you have set your current location in Setup > Settings > System > Location, otherwise there is no way to determine nighttime/daytime state."
Code: Select all
return
{
on =
{
devices = { 'notifyAlert'}, -- Name of your alert device
},
execute = function(dz, item)
local priority = dz.PRIORITY_MODERATE
if item.color == dz.ALERTLEVEL_RED then
priority = dz.PRIORITY_HIGH
end
--[[
dz.notify (
subject,
message,
priority,
sound,
extra,
subsystem
)
]]--
dz.notify ( 'My alert',
'Alertdevice ' .. item.name .. ' is now at level ' .. item.color .. '. Text is ' .. item.text,
priority,
nil,
nil,
{ dz.NSS_TELEGRAM, dz.NSS_PUSHOVER }
)
end
}
Re: Custom Message in Notifications!!
Posted: Monday 16 December 2019 11:58
by Larsoss
So i want to send a message when my thermostat is changed by value.
I want a Telegram Message true http: with the information on what value the thermostat is set on.
Is this possible?
https://ibb.co/NmQqrqV
https://ibb.co/XWMbDXN