NotificationLatch/README.md

34 lines
951 B
Markdown
Raw Normal View History

2021-08-18 09:38:47 +00:00
# NotificationLatch
Filters notifications so that each one is only sent once until it is reactivated. Designed for use with Domoticz. At the time of writing only Pushover is supported as a target transport.
## Installing
Install Node.js, at least the current LTS version.
Install the dependencies and build the frontend:
```
npm install
cd frontend
npm install
npm run build
cd ..
```
Install PM2 and run the backend service:
```
2021-08-18 10:08:10 +00:00
sudo npm install pm2 -g
2021-08-18 09:38:47 +00:00
pm2 startup
2021-08-18 10:08:10 +00:00
pm2 start ./ecosystem.config.js
2021-08-18 09:38:47 +00:00
pm2 save
```
## Configuring Domoticz
Go to Setup - Settings - Notifications. Enable Custom HTTP/Action and fill in the following information:
| Field | Value |
|--|--|
| URL/Action | ```http://localhost:3369/api/notification``` |
| POST Data: | ```subject=#SUBJECT&message=#MESSAGE&priority=#PRIORITY``` |
| POST Content-Type: | ```application/x-www-form-urlencoded``` |
| POST Headers: | ```Authorization: Bearer <authToken from config.js>``` |