Notification domoticz app event

Easy to use, 100% Lua-based event scripting framework.

Moderator: leecollings

Post Reply
roetenbergr
Posts: 4
Joined: Thursday 30 July 2015 17:09
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Notification domoticz app event

Post by roetenbergr »

It is possible to send a notifcation to the domoticz app through a script? I tried DZVents, LUA and Blocky, nothing seems to work
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Notification domoticz app event

Post by waaren »

roetenbergr wrote: Friday 23 March 2018 13:25 It is possible to send a notifcation to the domoticz app through a script? I tried DZVents, LUA and Blocky, nothing seems to work
Can you please elaborate a little bit more what you try to achieve here and with what version of domoticz / dzVents / OS ?
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
roetenbergr
Posts: 4
Joined: Thursday 30 July 2015 17:09
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Notification domoticz app event

Post by roetenbergr »

Well i'm trying to send a message to the domoticz app itself with an script. So not through pushover or whatever, The native domoticz app.
roetenbergr
Posts: 4
Joined: Thursday 30 July 2015 17:09
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Notification domoticz app event

Post by roetenbergr »

Based on raspberry pi, beta version of domoticz.
User avatar
DewGew
Posts: 581
Joined: Thursday 21 April 2016 12:01
Target OS: Raspberry Pi / ODroid
Domoticz version: V4.10618
Location: Sweden
Contact:

Re: Notification domoticz app event

Post by DewGew »

Domoticz app is using gcm for notifications. This might work in dzVents: domoticz.notify(subject, message, priority, sound, extra, subsystem)
change 'subsystem' to gcm. I havn't tryed this yet. :D

Code: Select all

domoticz.notify('Your sub', 'Your text', domoticz.PRIORITY_NORMAL, domoticz.NSS_GOOGLE_CLOUD_MESSAGING)
Raspberry Pi 3 | domoticz | Aeon Labs Z-Stick GEN5 | RFlink gateway
NanoPi NEO-air | REGO6XX interface | Machinon theme | Homebridge | Domoticz Google Assistant | ideAlarm
roetenbergr
Posts: 4
Joined: Thursday 30 July 2015 17:09
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Notification domoticz app event

Post by roetenbergr »

Yeah it's working! Thanks!
veerboot007
Posts: 1
Joined: Monday 04 May 2020 12:24
Target OS: Raspberry Pi / ODroid
Domoticz version: 2020.2
Location: Netherlands
Contact:

Re: Notification domoticz app event

Post by veerboot007 »

I was wondering how you did this. Im olso looking for notifications in de native domoticz app. For example: if the doorbell rings i want to receive a notification in the app...

Could you help me out with sharing the "code" in dzVents..?

Domoticz version 2020-2 on raspberry 3b and Iphone app.
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Notification domoticz app event

Post by waaren »

veerboot007 wrote: Monday 04 May 2020 12:27 I was wondering how you did this. Im olso looking for notifications in de native domoticz app. For example: if the doorbell rings i want to receive a notification in the app...

Could you help me out with sharing the "code" in dzVents..?

Domoticz version 2020-2 on raspberry 3b and Iphone app.
No idea if Cloud messaging also works with an Iphone but the script could look (in it's most simple form) like below

Code: Select all

return 
{
    on = 
    {
        devices = 
        { 
            'Bel',
        },
    },

    execute = function(dz, item)
        if item.active then 
            dz.notify('Bel', 'Someone at the door', dz.PRIORITY_NORMAL,nil,nil,dz.NSS_FIREBASE_CLOUD_MESSAGING)
        end    
    end
}

Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
Post Reply

Who is online

Users browsing this forum: iw2fag and 1 guest