Skip to page contentSkip to chat
ServiceNow support
    • Community
      Ask questions, give advice, and connect with fellow ServiceNow professionals.
      Developer
      Build, test, and deploy applications
      Documentation
      Find detailed information about ServiceNow products, apps, features, and releases.
      Impact
      Accelerate ROI and amplify your expertise.
      Learning
      Build skills with instructor-led and online training.
      Partner
      Grow your business with promotions, news, and marketing tools
      ServiceNow
      Learn about ServiceNow products & solutions.
      Store
      Download certified apps and integrations that complement ServiceNow.
      Support
      Manage your instances, access self-help, and get technical support.
How to send OI metrics using Rest API and view the same in Insight Explorer - Support and Troubleshooting
  • >
  • Knowledge Base
  • >
  • Support and Troubleshooting (Knowledge Base)
  • >
  • How to send OI metrics using Rest API and view the same in Insight Explorer
KB0853084

How to send OI metrics using Rest API and view the same in Insight Explorer


2249 Views Last updated : Jan 2, 2025 public Copy Permalink
KB Summary by Now Assist

Summary

Business Requirement:

  • The requirement is to send the metric data using operational intelligence API and view the same using Insight explorer. This KA will help to achieve the same business requirement.

Instructions

Prerequisites: 

    • Active Plugins: Event Management, Operational Intelligence
    • Working Clotho Database
    • Rest API Tool.
    • Working Mid Server.

Steps:

  • Configure Mid Web Server

    • Connect to the instance and Navigate to Mid Server >> Extensions >> Mid Web Server table
    • Create New Record and fill the details. make a note of the port and Authentication User Name and password.
    • Submit the record and Start the Web Server Record. It should look like below.



  • Configure the Operational Intelligence Metrics Context:

    • Connect to the instance and Navigate to Mid Server >> Extensions >> Operational Intelligence - open the table.
    • Create a new record, fill the required details. Make sure to select the "Enable Rest Listener" checkbox.
    • Submit the record - the final record should look like below.

  • Instance level Configuration:

    • Event Rule Configuration:
      Create an Event Rule for the metric source that will be used to bind the CI to the metric. - This is also a mandatory step.

  • Setting Up Rest API Tool:

    • Connect to the host which will be used to send the metric data.
    • Install Rest API Chrome Extension or Any other rest tool and set up the tool as per the below setting.

      Method - Post
      API Name - api/mid/sa/metrics
      Target URL : https://<Mid_IP_Address: Web Server Port>- Refer Configure Mid Web Server Section.
      Authorization: Mid Web Server User name and password. - Refer Configure Mid Web Server Section.
      Payload: The payload must start and end with "[" "]" brackets and the timestamp used in the payload must be an EPOCH time in milliseconds.

    • If you are trying to send data using any OOTB source value defined in the sa_metric_registration table, kindly enable the source first. By default, it is set to False. 
    • Below is the screenshot of the API tool.



    • Send the payload and check the response. If the response is 200 Ok which means the metric record is sent to the instance successfully.
  • Validating the result:

    • Open the "em_events" table and see if the event is generated as per the details sent in the payload.
    • Open the "sa_metric_map" table and see if the Metric to CI mapping is generated and validate if the configuration Item field is mapped to the valid CI.

  • Checking the metric details in Insight Explorer:

    • Once the metric is generated, Insight explorer will start displaying the same metric data.
    • Navigate to Operational Intelligence >> Insight Explorer.
    • Search for the CI under configuration item and it will display the details. Below is a sample screenshot.


 

 

 

Related Links

  • Event field format for event collection
  • Push API Metric

The world works with ServiceNow.

Sign in for more! There's more content available only to authenticated users Sign in for more!
Did this KB article help you?
Did this KB article help you?

How would you rate your Now Support digital experience?

*

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

What can we improve? Please select all that apply.

What are we doing well? Please select all that apply.

Tell us more

*

Do you expect a response from this feedback?

  • Terms and conditions
  • Privacy statement
  • GDPR
  • Cookie policy
  • © 2025 ServiceNow. All rights reserved.