Configuring Proactive Service Resolution for incidents in ServiceNow ITSM


As an administrator, configure Proactive Service Resolution to enable automated incident creation in ServiceNow ITSM for qualifying events.

When you configure the solution, Level 1 or Level 2 incidents are created depending on the information available in the event. For more information about levels, see Overview-of-Proactive-Service-Resolution

Before you begin

Make sure that the following conditions are met:

  • Obtain the endpoint URL, user credentials, client ID, secret key, and information about the grant type for connecting with ServiceNow ITSM. 
  • Proactive Service Resolution with BMC Helix Integration Service is not enabled from BMC Helix Operations Management. 



Step 1: To set up a connection

  1. On the BMC Helix Intelligent Automation console, click Solutions.
  2. Click Configure against the Proactive Service Resolution tile. 
    The configuration page is displayed. 
  3. Use the Incident Noise Reduction toggle key to turn off the capability. 

    About the Incident Noise Reduction toggle key

    The Incident Noise Reduction capability is available only for . Disable the Incident Noise Reduction option to view the  option. 

  4. Click Set Up and select the 

    ServiceNow ITSM

     option. 
    Setup connection ServiceNow Suppor PSR_243.png

  5. Provide the following connection details based on your ServiceNow ITSM deployment:
    1. (For cloud deployment)Type the following connection details:

      Field

      Description

      ServiceNow Endpoint URL

      The URL for the application.

      For example, https://host.service-now.com.

      Username

      User name to log on to the application. 

      Password

      Password that matches the user name.

      Grant Type

      ServiceNow ITSM API Grant Type.

      Client Id

      ServiceNow ITSM API Client ID.

      Client Secret

      ServiceNow ITSM API Client Secret.

    2. (For on-premises deployment) Click the download & install link to download the remote-restapi-plugin utility.
      You 
      must configure the on-premises connector to connect with the ServiceNow ITSM on-premises deployment.
      For more information, see Configuring-the-ServiceNow-ITSM-on-premises-connector.
  6. Click Save.
    The status is shown as Connected


Step 2: To define a trigger condition

By default, the trigger condition is set to Severity = Critical. When a critical event is generated in BMC Helix Operations Management, an incident gets created in ServiceNow ITSM. 

Important

You cannot edit the trigger condition in . After the solution is configured, the Predefined Policy for Incident notification policy is created in . You can edit the policy to add multiple and complex trigger conditions based on your requirements. Incidents are created based on the specified conditions. For more information, see Creating and enabling event policies

PSR_Trigger conditions_24202.png


Step 3: To provide the event to incident field mapping

By default, BMC Helix Intelligent Automation provides mapping of event fields to incident fields. Based on these mappings, an incident gets created. You can specify custom values for the default fields, add more fields, or apply transformation based on your requirements. For more information about the out-of-the-box field mappings, see Field-mappings-for-incidents-in-ServiceNow-ITSMThe Create or Update Incident Ticket automation policy is created as part of this step. 

  1. Click Configure against the Configure mapping: Event → Incident field.
    The default field mappings are displayed. 

    No. The minimum required fields for creating an incident are mapped with default values, and transformation is applied to some fields. You can update the existing values or add new fields to be used while creating an incident. Make sure that you do not delete any existing field mappings. PSR_Event to incident mapping_SNOWITSM_24202.png

  2. (Optional) If you do not use BMC Helix Discovery, locate the CILookupCriteria field, expand it, and click X (delete) against the correlation_id property. 

    About Level 2 incidents in ServiceNow ITSM

    By default, the configuration item (CI) information is obtained from BMC Helix Discovery. However, if you are not using BMC Helix Discovery, delete the correlation_id property from the CILookupCriteria field. The CI details are added by using the host name. 

  3. (Optional) To add a new incident field, click Add Incident Field and perform the following steps:
    The Add Incident Field panel displays the list of fields available in 
    ServiceNow ITSM.
    1. To use an existing field:
      1. Select any field from the list of all available fields and click Save.
      2. Click the field name and type the value. 
    2. To add a custom field: 
      1. Type the name of the field. 
      2. If you want this to be a required field, select Required.

        Important

        If you make a field mandatory, you cannot change it back to optional or delete the required field unless you delete the solution.

  4. (Optional) To add a condition to a field, click +Add Condition, add the incident field, and map it to the event field. 

    Important

    If using custom values, you can specify multiple values in the conditions.
    PSR improvement same values_24201.png

  5. (Optional) Against any field, click Transform fields and select the transformation type:
    • Source value to target value: Enables you to map the event source fields to the target incident fields. 
    • String: Enables you to concatenate or extract a part of a string.
  6. (Optional) To add multiple functions to process the strings for a field, navigate to a field and specify the conditions based on your requirement:

    Important

    • The following functions help transform the string data:
      • concat
      • substr: Specify values for Start and Length of the string to process
      • substrAfter: Specify the character and everything after the character gets processed
      • substrBefore: Specify the character and everything before the character gets processed
      • substrByByte: Specify the end index. For example, if you specify 99, all characters from 0-99 are processed.
      • toLowerCase: Transforms the entire string to lower case
      • toUpperCase: Transforms the entire string to upper case
    • When you add more than one function to transform data, conditions are applied in the order in which they are displayed.
    • You can use more than one function while mapping any field, for event-to-incident mapping or for incident-to-information event mapping.
  7. (Optional) To add a date and time function, add a new field, click Configure Text, and perform the following steps:
    1. Click Add.
    2. Select the transformation type as Date & Time.
    3. To transform the date, select the getDate function.
      The time zone format is generated based on your system settings. 
    4. Select an output format: 
      • ISO
      • yyyy-dd-MM hh:mm:ss
      • ddMMyyyy
      • MMddyyyy
    5. To transform time, select the getTime function and select the output format as hhmm.
    6. Save changes. 
  8. Click Save.
    The Policy published successfully message is displayed.  


Step 4: To provide the incident fields to Information Event mapping

By default, BMC Helix Intelligent Automation maps incident fields to event fields. Based on these mappings, an information event is created in BMC Helix Operations Management. Every time the incident is updated, the information event is updated too. For more information about the out-of-the-box field mappings, see Field-mappings-for-incidents-in-ServiceNow-ITSM. As part of this step, the Create an Information Event automation policy is created.

  1. Click Configure against the Configure mapping: Incident → Information Event field.
    The default field mappings are displayed. 
    PSR_Incident to InfoEvent_SNOWITSM_24202.png
  1. Make changes as required and click Save.
  2. Click Enable
    The 

    Proactive Service Resolution

     is enabled successfully message is displayed. 
    PSR_solution is configured_24202.png


Step 5: To create a business rule in ServiceNow ITSM

After configuring Proactive Service Resolution for ServiceNow ITSM, you must create a business rule to be able to create information events in BMC Helix Operations Management. The information events include information about the incident every time an incident is created or updated. 

For more information about business rules, see the ServiceNow ITSM documentation.

Before you begin

You must obtain the API access key and tenant ID for your BMC Helix tenant before creating a business rule. 

Click here to view the steps to obtain the API access key:
  1. Log on to BMC Helix Portal and navigate to User Access > Access keys.
  2. If a key is not created for BMC Helix Intelligent Automation, click Add key and type the key name.
  3. Select the key type as Access and click Confirm.
  4. Click Copy all key details and paste the content into a notepad. 
    You get the key details and the tenant ID for your BMC Helix tenant. 

    Sample key details
    key details:AU7RRPF1*****************I09TR3::urdx0zOVd7iqiQAhy4DyLryZt92o1i3iGU25fImmAeVS9YwZyA,tenant id: 10****5936

    For more information, see the To create an access key for user access section in Setting up access keys for programmatic access.

  5. For on-premises deployment, ensure that the ServiceNow ITSM connector is configured and running by using the remote plugin in BMC Helix Intelligent Automation. 
    For more information, see Configuring-the-ServiceNow-ITSM-on-premises-connector

To create a business rule

  1. Log on to ServiceNow ITSM and navigate to All > System Definition > Business Rules.
  2. Click New.
  3. Type a name for the rule. 
  1. Select the table depending on the type of incident that you want to create.
    For a case, select Case. For an incident, select Incident.
  2. Click Advanced and select the following options: 
    1. In the When to run tab, select after to run this rule after any of the selected actions take place.
    2. From the list of actions, select Insert, Update, and Delete.
    3. In the Advanced tab, copy and paste the following script. 
      When you copy the key details from BMC Helix Portal, you get the key details and the tenant ID.

      Copy the entire key details string to use as the access key in the following script: 
      (function executeRule(current, previous /*null when async*/ ) {

         //gs.info("Webhook body: " + JSON.stringify(current));
         var id = current.getValue('sys_id');
         var label = current.sys_meta.label;

         var request = new sn_ws.RESTMessageV2();
         request.setEndpoint(
             'https://portal-helix.com/intelligent-automation/restplugin/api/v1/tmf/callback?snow_nontmf=true'
          );
          request.setHttpMethod('
      POST');


          var tenantId = '
      <tenant_ID>';
          var accessKey = '
      <access_key>';

          request.setBasicAuth(tenantId, accessKey);
          request.setRequestHeader('
      Accept', '*/*');
          request.setRequestHeader('
      Content-Type', 'application/json');


          var body = {};
          body.ticket_id = id;
          body.display_id = current.getValue('
      number');
          body.caller_id = current.getValue('
      caller_id');
          body.priority = current.getValue('
      priority');
          body.company = current.getValue('
      company');
          body.description = current.getValue('
      description');
          body.correlation_id = current.getValue('
      short_description').substr(50);
          body.status = current.getValue('
      state');
          body.cmdb_ci = current.getValue('
      cmdb_ci');
          body.assigned_to = current.getValue('
      assigned_to');
          body.short_description = current.getValue('
      short_description');

         request.setRequestBody(JSON.stringify(body));

         var response = request.execute();

      })(current, previous);
    4. In the script, make the following changes: 
      1. For the request.setEndpoint parameter, specify the REST API URL where your BMC Helix Intelligent Automation is available. 

        Note

        If using an on-premises version of , set the request.setEndpoint to http://hostname:port/intelligent-automation/remote-restplugin/api/v1/tmf/callback?snow_nontmf=true, where the host name is the host where the ServiceNow connector is running, and the port is the value specified for the config.port parameter in the plugin.properties file. 

      2. For the tenantId parameter, specify the BMC Helix tenant ID. 
      3. For the accessKey parameter, specify the access key (combination of access key and secret key) for your BMC Helix tenant.
        For example, AU7RRPF1*****************I09TR3::urdx0zOVd7iqiQAhy4DyLryZt92o1i3iGU25fImmAeVS9YwZyA.
  3. Save changes to the business rule. 

Based on the business rule, every time an incident is created, updated, or deleted in ServiceNow ITSM, an information event with the appropriate details is created in BMC Helix Operations Management.  


Artifacts created for Proactive Service Resolution

After the solution is configured, the following artifacts are created across the BMC Helix environment:

Name

Type

Product

ServiceNow ITSM connector

Connector

BMC Helix Intelligent Automation

Create or Update Incident Ticket 

Automation policy

BMC Helix Intelligent Automation

Create an Information Event 

Automation policy

BMC Helix Intelligent Automation

Predefined Policy for Incident

Event policy

BMC Helix Operations Management

Incident and event updates and closure

When an event is updated, the incident is also updated. When an event is closed, the incident is automatically resolved. If the incident is closed, the corresponding information event is closed, however, the event is not closed. Based on the event policy, the event gets closed after the problem is resolved in the infrastructure. For more information about how events are closed, see Monitoring and managing events


To view Proactive Service Resolution

  1. On the Solutions page, click View.
    You can view the connection details, such as the IT service management system's name, endpoint URL, and the user name used for the connection. You can also view the trigger condition and the configured mappings.  
  2. Click Go back to return to the Solutions page. 


To disable Proactive Service Resolution

If there is downtime for any of the integrated products, or if you need to edit the configurations, you can disable the solution. This ensures that the artifacts and the customizations are not deleted when you enable the solution again. 

  1. Click Solutions > Proactive Service Resolution.
  2. Use the toggle key to disable or enable the solution.
    The Proactive Service Resolution disabled successfully message is displayed. 

Important

We recommend that you disable the solution only from . 

If the Predefined Policy for Incident gets disabled or deleted in , the solution is disabled in . If incidents are already created for events, information events about the status change in those incidents or events still get updated in . If the event is updated, the corresponding incident also gets updated. 


To modify Proactive Service Resolution

  1. Click Solutions > Proactive Service Resolution and use the toggle key to disable the solution.
    You can only view the connection details, such as the selected ITSM system, endpoint URL, and the user name (only for cloud deployements) used for connecting with the system.  
  2. Click Modify and make changes based on your requirements. 
  3. Click Save
  4. Click Enable.


To delete Proactive Service Resolution

  1. Click Solutions > 

    Proactive Service Resolution

     and use the toggle key to disable the solution.

  2. Click Delete.
    On the warning message that is displayed, click Yes.
    The Solution deleted successfully message is displayed. 
    When you delete the solution, all artifacts and any custom field mappings are deleted. If you configure the solution again, you must provide the custom values for field mappings again. 


Where to go from here

View the status of the automation policies run by ServiceNow ITSM for creating incidents. For more information, see Viewing-automation-policy-runs-history

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*