1. Home
  2. Integrations
  3. ServiceNow Integration Guide – VictorOps

ServiceNow Integration Guide – VictorOps


Versions Supported: Helsinki

VictorOps Version Required: Enterprise

What you need to know: Please contact support to get the required XML file. 

If you would like to move forward with implementing ServiceNow, please contact support@victorops.com

If you would like to integrate with ServiceNow Express, please refer to this article: Service Now Express

Note: The current integration is supported for the Helsinki release and previous versions.

The VictorOps integration is delivered as a ServiceNow update set in a single XML file. It allows creation of incidents on the VictorOps platform based on creation or update of Task items in ServiceNow. It also can be configured for limited feedback to ServiceNow when incidents are acknowledged or resolved on the VictorOps platform.

The VictorOps integration creates a new kind of Task called “VictorOps Incident” that is explicitly for creating incidents on the VictorOps platform. It is also possible to enable the “out of the box” ServiceNow Problem and Incident Tasks to create incidents on the VictorOps platform. All three of these actions are enabled using Business Rules.

To get the latest version of the XML file please contact support by selecting the link in the upper right hand corner, or by emailing support@victorops.com.

In VictorOps

Before you begin, collect your organization ID and Service API key from integrations pages of the VictorOps platform. There is currently no single page (UI) where you can see both of these values. To get the key, go to the Service Now Integration Page, and copy your key from the URL shown. Be sure to copy the whole thing:

To get the organization ID, you will need the slugified version of your organization name (org slug).  When you are logged into the main VictorOps timeline, your org slug is located at the end of the URL.  (Ex. if the URL is https://portal.victorops.com/client/my-company, then the org slug in this case is “my-company”)

(If you are running into issues locating your organization ID please contact support by selecting the link in the upper right hand corner, or by emailing support@victorops.com)

In ServiceNow

In the ServiceNow administration interface, go to “Retrieved Update Sets” and click “Import Update Set from XML”:

Upload the VictorOps integration XML, (To get the latest version of the XML file please contact support by selecting the link in the upper right hand corner, or by emailing support@victorops.com.)

Click on VictorOps Integration and then Preview Update Set:

That should preview without errors. Then, click Commit Update Set:

Configuration Steps

Once committed, a new VictorOps menu will appear on the left. To configure, click VictorOps > Settings. Enter your organization ID and REST API key that you retrieved from the VictorOps portal, then click Save:

To test that this configuration is working, click New VictorOps Incident, fill in some fields and click Submit:

An incident will be created on the VictorOps platform:

Resolve the incident within ServiceNow by clicking Open VictorOps Incidents, then the incident (not shown). Change the state to “Closed Complete” and select Update:

You will see the incident resolve on the VictorOps platform:

Additional/Optional Configuration

Sending ServiceNow Incidents and Problems to Victorops: By default, VictorOps Incidents are sent to the VictorOps platform, but ServiceNow Incident and Problem tasks are not. The VictorOps integration does, however, include deactivated Business Rules to enable that functionality. If you choose, you may enable them by clicking Business Rules under the VictorOps menu, and setting active on the “VictorOps ServiceNow Incident” and/or “VictorOps ServiceNow Problem” rules to “true”:

Configuring ServiceNow user group -> VictorOps routing key mappings: You may affect how incidents are routed on the VictorOps platform by configuring routing keys. To do so, you create a mapping between ServiceNow groups and VictorOps routing keys. Under the VictorOps menu, click “VictorOps Group Routings”. Click “New”, then select a user group and routing key:

Select a ServiceNow user group and VictorOps routing key from the pop up windows. It is also possible to create a new VictorOps routing key on the fly from that window by clicking New:

Click Submit when finished.

In this example, any ServiceNow Task assigned to the “Database” user group will be sent to VictorOps with the “db-admins” routing key. More information about how VictorOps uses routing keys can be found here: Incident Routing

Note: At this time, rerouting an incident within VictorOps by updating the assigned group for the ServiceNow task is not supported. Also, routing to a specific individual within VictorOps is not supported, unless that individual is the only person on the team to which the routing key is assigned in VictorOps.

Enabling “Ack-Back”

The VictorOps Ack-Back feature allows acknowledgement and resolution of incidents on the VictorOps platform to update the state of the corresponding ServiceNow Task row.

To enable Ack-Back, a scheduled job must be created. Under the VictorOps menu, click “Scheduled Jobs”, then “New”, and in the Automation Creator, select “Automatically run a script of your choosing”.

Then configure the new job with the name “VictorOps Command Poll”, run schedule of “Periodically”, interval of 5 minutes, and paste the following script code into the script box:

(new VictorOpsHelper()).pollForCommands();

When done, it will look something like the following:

When incidents are acknowledged on the VictorOps platform, the corresponding ServiceNow Task state will be updated with an appropriate corresponding state:

Advanced Configuration

ServiceNow Problem and ServiceNow Incident tickets are being created with a priority field, which is mapped to a severity level of INFO, WARNING or CRITICAL when sent to VictorOps. The severity affects whether or not incidents are created and escalations run on the VictorOps platform.

By default, ServiceNow Problems created with Critical or High priority map to CRITICAL, Moderate maps to WARNING, and Info/Planning map to INFO:

Thus, for example, a Problem created with Moderate priority will not create a VictorOps incident. To change that behavior, you may either:

  • Enable incident creation on warning in the VictorOp admin interface as usual
  • Modify the business rule to treat “moderate” priority as “critical” in VictorOps

To do the latter, Open the “VictorOps ServiceNow Problem” business rule, and edit the rule script to add priority ‘3’ to the critical priority list:

If you so desire, the mapping of Info/Planning priorities can also be changed in the same business rule script. To have them handled as CRITICAL:

// openStates, ackStates, criticalPriorities, warningPriorities
(new VictorOpsHelper([1],[2,3],[1,2,3,4,5],[])).notify(current);

To handle them as WARNING:

// openStates, ackStates, criticalPriorities, warningPriorities
(new VictorOpsHelper([1],[2,3],[1,2,3],[4,5])).notify(current);

ServiceNow Incidents are handled in a similar way.

As always if you have any questions please reach out to support.

Learn more about why we built this integration on our blog.

Updated on October 12, 2017

Was this article helpful?

Related Articles