@@ -1308,21 +1308,23 @@ properties:
- finish
apprise:
type: object
- required: ['service_urls']
+ required: ['services']
additionalProperties: false
properties:
services:
- type: object
- required:
- - url
- - label
- properties:
- url:
- type: string
- example: "mastodon://accesskey/host/?visibility=direct"
- label:
- example: mastodon
+ type: array
+ items:
+ type: object
+ required:
+ - url
+ - label
+ properties:
+ url:
+ type: string
+ example: "mastodon://accesskey/host/?visibility=direct"
+ label:
+ example: mastodon
description: |
A list of Apprise services to publish to with URLs and labels.
The labels are used for logging.
@@ -53,7 +53,7 @@ def ping_monitor(hook_config, config, config_filename, state, monitoring_log_lev
notify_type = state_to_notify_type[state.name.lower()]
apprise_object = apprise.Apprise()
- apprise_object.add(map(lambda service: service['url'], hook_config.get('services')))
+ apprise_object.add(list(map(lambda service: service['url'], hook_config.get('services'))))
if dry_run:
return
@@ -34,8 +34,7 @@ setup(
'packaging',
'requests',
'ruamel.yaml>0.15.0,<0.18.0',
- 'setuptools',
- 'apprise'
+ 'setuptools'
),
extra_require={
"Apprise": ["apprise"]