The sdgtw is missing the "Critical" severity seen in ServiceNow

book

Article ID: 103613

calendar_today

Updated On:

Products

NIMSOFT PROBES DX Infrastructure Management

Issue/Introduction

The sdgtw is missing the "Critical" severity seen in ServiceNow

Cause

The "sdgtw" probe only allows 3 values in the mapping of the severity:
 
High=1
Medium=2
Low=3
 

Environment

UIM 8.51
sdgtw 1.4, 2.0
Service Desk: Service Now

Resolution

If you have modified your ServiceNow service desk application to allow additional values for the incident severity then you would use the following procedure to modify the NIM API to allow for this.

1. Install a REST client for your browser.  In this example will be using the postman app for the Chrome browser.

2. Make sure that the sdgtw probe has been activated, then from the sdgtw.log file (loglevel 5), locate a line similar to the following:  
Jan 02 08:55:56:490 [ServiceNow, sdgtw] In NIMClient method :url is http://localhost:57491/ca-nim-sm/api/v2/Incident?filter=%28creationUserID%3Dadmin%29%26%26%28status%3Dresolved%7C%7Cstatus%3Dclosed%29+%26%26+%28updatedTimeStamp%3E%3D2018-01-02T08%3A55%3A24.258-05%3A00%29&display=id,status&$lastIndex=100&startIndex=0
 
We are looking for the REST URI hostname and port that the sdgtw is using to communicate with the NIM API webapp running in the probe.  In this case the hostname is localhost and port is 57491.

3. From the REST client you opt to use, create a GET REST call using the following URI:  
http://localhost:57491/ca-nim-sm/api/v2/config/integration/ServiceNow/mapping/Incident

<Please see attached file for image>

Screenshot of using Postman to post to sdgtw NIM API

4. Next, define a Basic Auth Authorization header:Username: nimadmin
Password: nimadmin

<Please see attached file for image>

Second screenshot of using postman REST client to update the nim api for the sdgtw probe severities for ServiceNow

5. Build a Content-Type header (not needed for the GET REST call, but will be used later) with:Key: Content-Type 
Value: application/json

<Please see attached file for image>

Screenshot of postman to update the sdgtw probe list of Service Now severities

Select the Send button to retrieve the NIM API mappings for ServiceNow.  The XML outputs will be similar to the following if successful:
 
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<mappings>
    <Mapping>
        <NIMField>affectedCIID</NIMField>
        <MDRField>cmdb_ci</MDRField>
        <Description>CI on which Incident is created</Description>
    </Mapping>
    <Mapping>
        <NIMField>id</NIMField>
        <MDRField>sys_id</MDRField>
        <Description>Unique Identifier of the issue generated by the system</Description>
    </Mapping>
    <Mapping>
        <NIMField>assigneeUserID</NIMField>
        <MDRField>assigned_to</MDRField>
        <Description>User to which the incident is assigned</Description>
    </Mapping>
    <Mapping>
        <NIMField>assigneeCompany</NIMField>
        <MDRField>company</MDRField>
        <Description>Organization to which the assignee group or user belongs to</Description>
    </Mapping>
:
:
:

6. To change these, first locate the severity NIMField Mapping section in the XML outputs of the REST GET call.  It should look as follows:  
    <Mapping>
        <NIMField>severity</NIMField>
        <MDRField>severity</MDRField>
        <Description>Severity of the Incident</Description>
        <DefinedValues>High=1,Medium=2,Low=3,Critical=4</DefinedValues>
    </Mapping>

7. Work with your SeviceNow administrator to get the values that they have defined for the incident severity field in ServiceNow.

8. Create a PUT request to the NIM API (same URI and authorization and Content-Type headers), but this time add the following to the body of the request:  
[
  {
    "NIMField": "severity",
    "MDRField": "severity",
    "Description": "Severity of the Incident",
    "DefinedValues": "Critical=1,High=2,Medium=3,Low=4"
  }
]
 
NOTE:  Adjust the value of the DefinedValues key to match what you currently have configured in your ServiceNow application.  The above example assumes that a Critical severity has a numerical value of

9. In this example, the Critical severity actually has a numerical value of 4, so my example body below will most likely be different from what you will use:
 

<Please see attached file for image>

Post man POST to sdgtw probe

Select the Send button to update the NIM API mapping.  If you review the outputs of the PUT call, you should see the new severity settings allowed in the severity mapping section.

10. Cold start (deactivate, then activate) the sdgtw probe.  This time when you map the severity field for your ServiceNow connection, you should see the new Critical severity value available in ServiceNow:

<Please see attached file for image>

User-added image

Additional Information

NOTE:  This change will remain in place until you either upgrade the sdgtw probe to a new release or remove, then reinstall the probe.  In both of these cases, the ServiceNow severity field mapping values will go back to the default set of 3 values (High, Medium, and Low) and at that point it will be necessary to change them again via the steps specified above.
 

Attachments

1558618715345000103613_sktwi1ysjvsbg6bf.jpeg get_app
1558618713432000103613_sktwi1ysjvsbg6be.jpeg get_app
1558618711508000103613_sktwi1ysjvsbg6bd.jpeg get_app
1558618709579000103613_sktwi1ysjvsbg6bc.jpeg get_app
1558618707721000103613_sktwi1ysjvsbg6bb.jpeg get_app