Logic Apps service is an automation design solution for Microsoft Azure that allows building powerful automated workflows and business processes with a visual designer, without needing to write any code. Logic Apps provides the ability to interface with PagerDuty through PagerDuty’s REST API and Events API (v1), and to perform a variety of actions such as:
- Starting workflows based on events that occur in PagerDuty, such as incident creation, assignment of an incident to a user, or resolution of an incident;
- Obtaining user and incident data
- Incident operations, such as:
- Add a note
Create a REST API Key
This API key will be used by Azure Logic Apps to communicate with PagerDuty.
- From the Configuration menu in PagerDuty, select API Access.
- On the API Access page, click the Create New API Key button.
- In the dialog that pops up, you’ll be prompted to enter a Description for your key, and for the API version select v2. You will also have the option to create the key as Read-only; leave this box unchecked as a full-access API key is required.
- Once you have filled in your options, click Create Key.
- Once you click Create Key, you will see a dialog displaying your key and confirming the options you filled in on the previous step.
- Important: Make sure to copy this key and save it in a secure place, as you will not have access to the key after this step. If you lose a key that you created previously and need access to it again, you should remove the key and create a new one.
- Click Close once you have successfully copied your key.
Create an Events API Integration
To trigger incidents as stages in your workflow, you will need to create an Events API (v1) integration as well:
- Create a new service in your PagerDuty account, or open an existing service, to integrate with Logic Apps.
- Go to the Integrations tab of the service.
- Obtain an Events API integration key:
- If you have an existing v1 Events API integration, copy its Integration Key.
- Otherwise, click New Integration, select Use our API directly / Events API v1 for the Integration Type, click Add Integration and copy the key of the newly-made integration.
- Go to Logic Apps and create a new Logic App, or modify a new one, and at the desired workflow stage click New Step.
- Search for “PagerDuty”.
- Pick a PagerDuty action.
- If you have not yet created an API connection for PagerDuty in your Azure account, you will be prompted to add one by entering a Connection Name and API Key. In the PagerDuty API Key field, enter the REST API key that you created in the steps above.
- If the action is to create an incident, you will be prompted to enter your Events API key (a.k.a. Integration Key) created in the above steps. Enter it into the Service key field.
- If the action is to Get user by ID, you can obtain the user’s ID from the URL of their user profile page. It is the alphanumeric code at the end of the URL that begins with
You should now be able to perform any of the listed API-enabled actions in PagerDuty as part of automated workflows in Azure Logic Apps.