def __init__(self, token, **kwargs):
'''
Create a new TelegramNotifier
:param token: Your Bot's authentication token
:param recipients: The chatIDs or usernames that should
be contacted by this Notifier
:type recipients: Iterable of recipients or dict mapping categories to recipients
:param categories: The message categories this Notifier should relay
:type categories: Iterable
:param level: The minimum level for messages to be relayed
:type level: int
'''
if _has_telepot is False:
raise ImportError('The telepot package is required for this Notifier')
self.bot = telepot.Bot(token)
super().__init__(**kwargs)
评论列表
文章目录