# Integration Guide: PagerDuty
*Version: 1.0| Last Updated: 2025-02-25*
## Overview
- **Integration Name:** PagerDuty
- **Purpose:** Integrate PagerDuty with MoovingON AI, enabling users to send PagerDuty notifications
- **Audience:** Support team, TAM
- **Prerequisites:**
- A valid Splunk account
- MoovingON AI account access with integration permissions
---
## Table of Contents
- [[#Setup Instructions]]
- [[#Configuration]]
- [[#Testing the Integration]]
- [[#FAQs]]
- [[#Related Links]]
---
## Setup Instructions
A webhook should be created in the MoovingON AI platform to send alerts to PagerDuty.
1. **Step 1:** Webhook should be created in settings
****
2. **Step 2:** Click on the **Plus** symbol in the upper bar:
****
3. **Step 3:** On the right side of the screen, a window will appear to create the webhook.
The parameters:
- **Name**: Webhook's name
- **Method**: POST
- **Content-Type**: JSON
- **URL**: This is the URL used to open the alert in OpsGenie "https://api.pagerduty.com/incidents"
- **Payload**: Creating an incident can be tested and configured in this [link](https://developer.pagerduty.com/api-reference/a7d81b0e9200f-create-an-incident)
Here is an example payload, which was used in the screenshot:
{
"incident": {
"type": "incident",
"title": "The server is on fire.",
"service": {
"id": "{SERVICE_ID}",
"type": "service_reference"
},
"priority": {
"id": "{PRIORITY_ID}",
"type": "priority_reference"
},
"urgency": "high",
"incident_key": "baf7cf21b1da41b4b0221008339ff357",
"body": {
"type": "incident_body",
"details": "TestDocumentation"
},
"escalation_policy": {
"id": "{ESCALATION_POLICY_ID}",
"type": "escalation_policy_reference"
}
}
}
###### Note: ID's extraction can be found in [[#Configuration]]
- Headers should be added by clicking "**Add Header**.":
1. Accept*: application/vnd.pagerduty+json;version=2
2. Content-Type*: application/json
3. From:
[email protected]
4. Authorization: Token token={TOKEN}
**NOTE**: values inside curly brackets should be inserted with the relevant values
****
---
## Configuration
Generate token (as stated in the [documentation](https://support.pagerduty.com/main/docs/api-access-keys#section-generating-a-general-access-rest-api-key)):
1. In the web app, navigate to **User Icon** , **My Profile** , **User Settings**.
2. In the section **API Access**, click **Create API User Token**.
3. Enter a **Description** to help you identify the key later.
4. Click **Create Key**.
This will generate a unique API key. Store it in a secure location, as this is the only time the key is displayed in full. If you lose a key, you will need to delete it and create a new one.
5. Click **Close**.
To get the ID of relevant fields:
6. **Service ID**: To get the ID, first, we have to create the service in the PagerDuty UI.
Afterward, entering the Service page, we can see the ID in the URL. For example:
****
**The same procedure applies to Escalation policies**
2. **Priority ID**:
To get the priority IDs, we have to run this API:
curl --request 'GET' \
--url 'https://api.pagerduty.com/priorities' \
--header 'Authorization: Token token=YOUR_PAGERDUTY_API_KEY' \
--header 'Accept: application/vnd.pagerduty+json;version=2'
Demonstration of response:
{
"priorities": [
{
"id": "P1",
"type": "priority",
"summary": "Critical"
},
{
"id": "P2",
"type": "priority",
"summary": "High"
},
{
"id": "P3",
"type": "priority",
"summary": "Medium"
},
{
"id": "P4",
"type": "priority",
"summary": "Low"
}
]
}
---
## Testing the Integration
- **Test Case:**
By running the webhook on alert, we receive this response:
****
We can see that it's received in PagerDuty as well:

---
## FAQs
- **Q:** How to extract a **Token**, **Service ID** or **Priority ID**?
**A:** It's explained in the [[#Configuration]] section
---
## Related Links
- **External Resources:** [Create an Incident](https://developer.pagerduty.com/api-reference/a7d81b0e9200f-create-an-incident) , [Services and Integrations](https://support.pagerduty.com/main/docs/services-and-integrations#section-events-API-v2) , [Incident Priority](https://support.pagerduty.com/main/docs/incident-priority#configure-incident-priority) , [API Keys](https://support.pagerduty.com/main/docs/api-access-keys#section-generating-a-general-access-rest-api-key) ,