mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-02 19:46:26 -04:00
parent
6bd9d85a9a
commit
e34a8e2e4a
2 changed files with 36 additions and 0 deletions
|
@ -137,6 +137,24 @@ class Notification {
|
|||
throwGeneralAxiosError(error)
|
||||
}
|
||||
|
||||
} else if (notification.type === "pushy") {
|
||||
try {
|
||||
await axios.post(`https://api.pushy.me/push?api_key=${notification.pushyAPIKey}`, {
|
||||
"to": notification.pushyToken,
|
||||
"data": {
|
||||
"message": "Uptime-Kuma"
|
||||
},
|
||||
"notification": {
|
||||
"body": msg,
|
||||
"badge": 1,
|
||||
"sound": "ping.aiff"
|
||||
}
|
||||
})
|
||||
return true;
|
||||
} catch (error) {
|
||||
console.log(error)
|
||||
return false;
|
||||
}
|
||||
} else if (notification.type === "slack") {
|
||||
try {
|
||||
if (heartbeatJSON == null) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue