-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BREAKING CHANGE: Config format changed. To migrate the config follow the example below: Before: { "appToken": "", "deliveryToken": "" } After: { pushover: { "enabled": true, "appToken": "", "deliveryToken": "" } } This is due to the addition of Slack support, which requires it's own configuration, therefore each service has an object inside the configuration file.
- Loading branch information
1 parent
5abc5fe
commit d77957e
Showing
5 changed files
with
170 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,76 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-04/schema#", | ||
"type": "object", | ||
"properties": { | ||
"appToken": { | ||
"type": "string", | ||
"description": "The token of your Pushover application." | ||
"$schema": "http://json-schema.org/draft-04/schema#", | ||
"type": "object", | ||
"properties": { | ||
"pushover": { | ||
"enabled": { | ||
"type": "boolean", | ||
"description": "Whether pushover notifications are enabled or not.", | ||
"default": false | ||
}, | ||
"appToken": { | ||
"type": "string", | ||
"description": "The token of your Pushover application." | ||
}, | ||
"deliveryToken": { | ||
"type": "string", | ||
"description": "The token of either the Pushover group or individual user that notifications should be sent to." | ||
}, | ||
"priority": { | ||
"type": "integer", | ||
"description": "Affects how the receipient of the notification sees it. See https://pushover.net/api#priority", | ||
"default": 2, | ||
"minimum": -2, | ||
"maximum": 2 | ||
}, | ||
"retry": { | ||
"type": "integer", | ||
"description": "How often to re-display the notification until the user acknowledges it. Only applies when `priority` is `2`. See https://pushover.net/api#priority", | ||
"default": 30, | ||
"minimum": 30 | ||
}, | ||
"expire": { | ||
"type": "integer", | ||
"description": "How long to conintue re-displaying a notification before giving up. Only applies when `priority` is `2`. See https://pushover.net/api#priority", | ||
"default": 3600, | ||
"minimum": 60, | ||
"maximum": 86400 | ||
}, | ||
"requred": [ | ||
"appToken", | ||
"deliveryToken" | ||
] | ||
}, | ||
"slack": { | ||
"type": "object", | ||
"properties": { | ||
"enabled": { | ||
"type": "boolean", | ||
"description": "Whether Slack notifications are enabled or not.", | ||
"default": false | ||
}, | ||
"deliveryToken": { | ||
"type": "string", | ||
"description": "The token of either the Pushover group or individual user that notifications should be sent to." | ||
"user": { | ||
"type": "string", | ||
"description": "The username the alert should come from, for example 'NodeCG Alerts'." | ||
}, | ||
"priority": { | ||
"type": "integer", | ||
"description": "Affects how the receipient of the notification sees it. See https://pushover.net/api#priority", | ||
"default": 2, | ||
"minimum": -2, | ||
"maximum": 2 | ||
"destination": { | ||
"type": "string", | ||
"description": "Who should the message go to, can be a #channel or a @user." | ||
}, | ||
"retry": { | ||
"type": "integer", | ||
"description": "How often to re-display the notification until the user acknowledges it. Only applies when `priority` is `2`. See https://pushover.net/api#priority", | ||
"default": 30, | ||
"minimum": 30 | ||
"url": { | ||
"type": "string", | ||
"description": "The Webhook URL provided by Slack." | ||
}, | ||
"expire": { | ||
"type": "integer", | ||
"description": "How long to conintue re-displaying a notification before giving up. Only applies when `priority` is `2`. See https://pushover.net/api#priority", | ||
"default": 3600, | ||
"minimum": 60, | ||
"maximum": 86400 | ||
}, | ||
"requred": [ | ||
"appToken", | ||
"deliveryToken" | ||
"required": [ | ||
"user", | ||
"destination", | ||
"url" | ||
] | ||
} | ||
} | ||
} | ||
}, | ||
"required": [ | ||
"pushover", | ||
"slack" | ||
] | ||
} | ||
} |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters