PagerDuty and Slack integration for users without a PagerDuty account

 November 29, 2021

Since you are here, you know how helpful PagerDuty is and its impact on customer satisfaction and revenue.

It is excellent for SAAS solutions, but how about on-premises installation?

I won't go into detail, but over time we had to identify solutions for Technical Support teams to trigger incidents based on their investigations on the on-premises installations. For example, in our, an incident would be initiated from Slack.

Now, if you got to this point, you might wonder why you haven't used the built-in Slack Integration. The answer is that it works only for users with a PagerDuty account. That would have increased the costs (to be honest, I might have researched non-billable accounts in PagerDuty, but I would have missed the fun)

Step 1, deploy as quickly as possible an API
For this scenario will use Google Scripts. We open a Google Sheet, Apps Extension. We can start from the Snippet bellow.

Shortly, the code is fetching the text provided in Slack and sending it via PagerDuty API.

 (since it's just a demo, no security implementations were considered).

As soon as we have everything ready, we go to Publish -> Deploy as Web App. This will generate a Web app URL, for e.g.: https://script.google.com/macros/s/AKfycbzmqtq

As soon as we have the WebApp, we can create an app  under : https://api.slack.com/apps/ . As soon as the app is created go to : Slash Commands and add your Slack command and the mapping with Web app URL.  

Learn how to optimize your JIRA Automations executions

You may be interested in