alerta / alerta-contrib

Contributed integrations, plugins and custom webhooks
http://alerta.io
MIT License
119 stars 170 forks source link

Msteams MS_TEAMS_PAYLOAD #288

Closed jjh74 closed 5 years ago

jjh74 commented 5 years ago

Few commits to prepare for msteams webhook. These commits add MS_TEAMS_PAYLOAD that allows to fully customize the http POST json payload (this is similar to SLACK_PAYLOAD). pymsteams or requests.post timeout is set to MS_TEAMS_DEFAULT_TIMEOUT (7s) instead of the default pymsteams default 60s.

Question on naming msteams webhook: I tried to use webhooks/msteams/alerta_msteams.py for teams webhook, but I assume this conflicts with plugins/msteams ? When I renamed the webhook to webhooks/msteamswebhook/alerta_msteamswebhook.py it loads. What's the recommened way for naming webhooks ?

satterly commented 5 years ago

Question on naming msteams webhook: I tried to use webhooks/msteams/alerta_msteams.py for teams webhook, but I assume this conflicts with plugins/msteams ? When I renamed the webhook to webhooks/msteamswebhook/alerta_msteamswebhook.py it loads. What's the recommened way for naming webhooks ?

Did it work if you renamed it to webhooks/msteams/alerta_msteamswebhook.py ?

satterly commented 5 years ago

I'll merge this plugin PR for now and we can discuss webhook naming elsewhere. 👍 Thanks.