From fa2f03d1fd8c22d1b6d39fbff0809e0a054fbaf8 Mon Sep 17 00:00:00 2001 From: Arno Hautala Date: Fri, 1 Jul 2022 09:46:07 -0400 Subject: [PATCH] Adds Markdown support to Pushover (#607) --- apprise/plugins/NotifyPushover.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/apprise/plugins/NotifyPushover.py b/apprise/plugins/NotifyPushover.py index ef694d24..a4e8169f 100644 --- a/apprise/plugins/NotifyPushover.py +++ b/apprise/plugins/NotifyPushover.py @@ -30,6 +30,7 @@ import requests from .NotifyBase import NotifyBase from ..common import NotifyType from ..common import NotifyFormat +from ..conversion import convert_between from ..utils import parse_list from ..utils import validate_regex from ..AppriseLocale import gettext_lazy as _ @@ -367,6 +368,10 @@ class NotifyPushover(NotifyBase): if self.notify_format == NotifyFormat.HTML: # https://pushover.net/api#html payload['html'] = 1 + elif self.notify_format == NotifyFormat.MARKDOWN: + payload['message'] = convert_between( + NotifyFormat.MARKDOWN, NotifyFormat.HTML, body) + payload['html'] = 1 if self.priority == PushoverPriority.EMERGENCY: payload.update({'retry': self.retry, 'expire': self.expire})