Incoming Web Hooks

Does Discourse have functionality to receive an incoming webhook from a service like PagerDuty and post it to a forum? Basically I’d send alerts from PagerDuty to the WebHook URL for Discourse and it would create a new forum topic.

If so, is there a guide that I can follow to set this up?

You’ll need to make calls to the Discourse API, perhaps using some intermediary like Zapier, OR write a plugin to catch whatever arbitrary incoming stuff.

If you can get PagerDuty to conform to Discourse’s API, then you’re golden. You can search here for examples and/or see How to reverse engineer the Discourse API.

1 Like

Thanks @pfaffman. So there is only webhooks configuration to send FROM discourse TO another site?

Webhooks go out. API calls come in.

1 Like

ok, i only asked because sites like google chat will give you a url you can use to point web hooks to so I could copy that url and put it in pagerduty and have pagerduty send an alert to the google chat webhook url and post in google chat. wasnt sure if there was similar functionality with discourse

We support some webhooks, like for email bounce from some SMTP providers in core, and some webhooks in plugins, like Patreon webhooks in the Patreon plugin.

For your need, PagerDuty webhooks into Discourse topics, you will need to write a plugin.

We have a very similar plugin in early stage here: https://github.com/discourse/discourse-prometheus-alert-receiver

5 Likes