Script to change notification system

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

Moderator: leecollings

Post Reply
degmi
Posts: 3
Joined: Monday 02 May 2022 14:42
Target OS: Linux
Domoticz version:
Contact:

Script to change notification system

Post by degmi »

Hi to all,
can you help me create a script to change with a virtual switch the active system notification of some other switches?
in a nutshell I would like to change with a single switch the notification system of several other switches (from pushbullet to kodi) without having to do it manually every time. Thanks
degmi
Posts: 3
Joined: Monday 02 May 2022 14:42
Target OS: Linux
Domoticz version:
Contact:

Re: Script to change notification system

Post by degmi »

Ok, I i found the json string to use (
127.0.0.1:8080/json.htm?devidx=77&idx=56&param=updatenotification&tmsg=Attivo&tpriority=1&tsendalways=true&tsystems=pushbullet&ttype=7&tvalue=1&twhen=0&type=command)
, but now i have another problem, the notification idx value changes every time, how can i fix? Is it possible to assign a variable with that value and if so how?
degmi
Posts: 3
Joined: Monday 02 May 2022 14:42
Target OS: Linux
Domoticz version:
Contact:

Re: Script to change notification system

Post by degmi »

Ok, I fixed it by giving the command to remove (clear all) and add notification.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest