What does OpsGenie offer to ServiceNow users?
OpsGenie has a specific update set which allows bi-directional integration between OpsGenie and ServiceNow. Using the integration, ServiceNow sends incident events to OpsGenie, with detailed information. And OpsGenie forwards alerts as incidents to ServiceNow. OpsGenie can determine the right people to notify based on on-call schedules, using email, text messages (SMS), phone calls and iOS & Android push notifications, and escalating alerts until the alert is acknowledged or closed.
Functionality of the Integration
- When an incident is created in ServiceNow, an alert will be created in OpsGenie.
- When an incident is resolved/closed in ServiceNow, the alert will be closed in OpsGenie.
- When the incident is assigned to a group in ServiceNow, the corresponding team will be added to the alert if the name of the group in ServiceNow and the name of the team in OpsGenie match.
- When the incident is assigned to a user in ServiceNow, the alert in OpsGenie will be assigned to the corresponding user.
- If Send Alert Updates Back to ServiceNow is enabled, actions for ServiceNow will be executed in ServiceNow when the chosen action is executed in OpsGenie for alerts which are created by the ServiceNow integration.
- If Create ServiceNow Incidents for OpsGenie Alerts is enabled, actions for ServiceNow will be executed in ServiceNow when the chosen action is executed in OpsGenie for alerts which have a source other than the ServiceNow integration.
- This action mapping features are explained in detail in the Action Mapping Feature section below.
- User & Group synchronization. (Optional)
Add ServiceNow Integration in OpsGenie
- Please create an OpsGenie account if you haven't done already.
- Go to ServiceNow Integration page.
- Specify who should be notified for ServiceNow alerts using the "Recipients" field. User(s), group(s), escalations policies and on-call schedules can be specified as the alert recipients. Auto-complete suggestions will be provided as you type.
- Copy the integration API Key by clicking on the copy button or selecting. You'll be using this in the ServiceNow configuration.
- Click "Save Integration".
Action Mapping Feature
- OpsGenie allows customers to define action mappings between OpsGenie actions and ServiceNow actions.
- You can use this section to map OpsGenie actions to ServiceNow actions when the source of the alert is ServiceNow (i.e When the alert is created by ServiceNow integration.)
- You can map different OpsGenie actions to different ServiceNow actions. For example, you can add note to ServiceNow incident, when the alert is acknowledged. In order to do this, you should define If alert is acknowledged in OpsGenie, add it as a work note to the incident in ServiceNow. mapping in Send Alert Updates Back to ServiceNow section.
- You can use this section to map OpsGenie actions to ServiceNow actions when the source of the alert is NOT ServiceNow (i.e When the alert is created by another integration.)
- For this purpose, you can use Create ServiceNow Incidents for OpsGenie Alerts section. In order to use this functionality, you need to map one OpsGenie action to create an incident ServiceNow action. The OpsGenie action doesn't have to be alert is created, it can be other actions as well.
- a tag is added to the alert and a custom action is executed on alert actions differ from other actions. When you select one of these actions, you'll see an extra field to enter for which tags or for which custom action this mapping will work.
- You can enter multiple tags by separating the tags with a comma. If you enter multiple tags, the mapping will work if the alert has one or more of the specified tags. You can also leave the tags field empty, if you would like the mapping to work for any tag.
- If you select a custom action mapping, you must specify the name of the custom action that the mapping will work. It cannot be left empty.
- If you map an OpsGenie action to multiple ServiceNow actions, you will get an error except for the a tag is added to the alert and a custom action is executed on alert actions. You can save multiple mappings for these actions, because they will differ by the given tags and the given custom action names.
For alerts created by ServiceNow
For other OpsGenie alerts
Installing the Integration in ServiceNow
- Download the update set.
- Upload, preview and commit the update set to your ServiceNow instance. You can refer here. Upon success, OpsGenie application menu should appear on the navigator.
- Under OpsGenie, select OpsGenie Configuration. OpsGenie configuration form will appear in a new tab.
- Replace the [YOUR OPSGENIE API KEY] part in the API Key field with the API key you copied earlier.
- Leave the OpsGenie Endpoint field as it is, if you are not using OpsGenie Sandbox.
- Check Use Synchronization option to value, if you would like to synchronize your users & groups in ServiceNow with OpsGenie. For more information please check out User & Group Synchronization (Optional) section below.
- Check Use Acknowledge Instead Of Assign option to value, if you would like to acknowledge the alert instead of assigning it to a user in OpsGenie when an incident is assigned to someone in ServiceNow. For more information please check out Acknowledging the Alert in OpsGenie When the Incident is Assigned in ServiceNow (Optional) section below.
- Click on Submit button to save the configuration.
Using Basic Authentication (Optional)
- The basic authentication feature is not enabled by default.
- In order to use it, you need to go to the advanced tab.
- In the settings part, you will find ServiceNow User Name (Optional) and ServiceNow Password (Optional) fields, under the Scripted REST API URL field.
- It's an optional feature, so you can leave the fields blank if you do would not like to use it.
- If you fill one of user name or password fields, you need to fill the other field to successfully save the integration. Otherwise it will show you an error.
- In order to enable basic authentication feature, you check "Requires Authentication" option to value for each resource of the Scripted REST API component of the OpsGenie application.
- You can find the Scripted REST API component, under the Scripted REST APIs menu item of the OpsGenie application.
- Click on opsgenie2sn in the Scripted REST APIs list.
- You will find Resources tab in the bottom of the page.
- For each resource in the list, you need to click on the resource to open it, and then check the Requires Authentication option to value.
- You can find the option under the security tab.
Acknowledging the Alert in OpsGenie When the Incident is Assigned in ServiceNow (Optional)
- Currently, when an incident is assigned to someone in ServiceNow, we also assign the alert to the same user in OpsGenie.
- Assigning an alert to a user in OpsGenie does not stop the notification flow.
- Instead, you may want to stop the notification flow when the incident is assigned to someone in ServiceNow. We have an option for this behaviour in our latest OpsGenie application in ServiceNow.
- It is not enabled by default. You can check the option to value in order to acknowledge the alert instead of assigning it to the user in OpsGenie.
Sending Payload to a Custom Scripted REST API Source Endpoint in ServiceNow (Optional)
- Our integration with ServiceNow supports sending a payload from an alert action to a custom endpoint in ServiceNow.
- You can map any alert action to the send to custom endpoint ServiceNow action, and when those alert actions take place, a payload will be sent to the endpoint that you specified.
- The payload we send for this send to custom endpoint ServiceNow action is similar to the payload of our Webhook integration except it does not include the integrationName and integrationId fields. You can check out this document to get more information about the payload.
- We've already created a Scripted REST API Resource for our latest OpsGenie application in ServiceNow called sample.
- We've developed a script to make an HTTP request to our Alert API and get the alert data from our Alert API and log it to the application logs as an example for this sample Scripted REST API Resource.
- You can map a custom OpsGenie action called sample to the send to custom endpoint ServiceNow action and enter sample as the custom endpoint to test the feature.
- This way, when you execute the sample custom action on an alert in OpsGenie, it will be forwarded to the sample endpoint in ServiceNow.
User & Group Synchronization (Optional)
- Our integration with ServiceNow supports synchronizing users and groups in ServiceNow with OpsGenie.
- Note that the synchronization is performed for the users and groups added to ServiceNow after the synchronization feature is enabled. We create a user in OpsGenie for each such user in ServiceNow and we create a team in OpsGenie for each such group in ServiceNow.
- When you create, update or delete a user or create, delete a group in ServiceNow, the changes will be applied to your OpsGenie account, if Use Synchronization option is checked in the OpsGenie Configuration form in ServiceNow.
- In OpsGenie-ServiceNow integration page, UNCHECK Restrict Access to Configurations option if it is checked.
- We get email, full name, business phone, mobile phone and timezone fields of a user from ServiceNow and use those fields in OpsGenie when creating a user.
- The role of a user created in OpsGenie will be User regardless of his/her role in ServiceNow.
- When one or more of the full name, business phone, mobile phone and timezone fields of a user change in ServiceNow, those fields will get changed in OpsGenie, too.
- OpsGenie does NOT allow special characters or spaces in team names, but ServiceNow does. So, we replace disallowed characters and spaces before creating a team in OpsGenie when a group is created in ServiceNow with those characters in name.
- Updating group name or group description in ServiceNow will NOT update team name and team description in OpsGenie.
- When a user is added to/removed from a group in ServiceNow, the user will be added to/removed from the team in OpsGenie.