Integrating with third-party products by using the generic collector via webhook
As a tenant administrator or a user with the II Admin role, use the generic collector to collect events and metrics from a webhook-based third-party product for which an out-of-the-box connector is not available. The generic collector uses a webhook mechanism to collect data.
You can view the collected data in various BMC Helix applications and derive the following benefits:
| BMC Helix application | Type of data collected or viewed | Benefits |
|---|---|---|
| BMC Helix Operations Management | Events | Use a centralized event view to monitor, filter, and manage events, and perform event operations in one place. Process events to help identify actionable events quickly from a large volume of event data. For more information, see Monitoring events and reducing event noise. |
| BMC Helix Operations Management | Metrics | Use alarm and variate policies to detect anomalies and eliminate false positives for more accurate results while monitoring the health of your system. For more information, see Detecting anomalies by using static and dynamic thresholds. |
Before you begin
Make sure you perform the following actions before you configure a connection with a third-party product:
Third-party product requirements
- Make sure that the third-party product from which you want to collect data is able to send events and metrics in JSON format via a webhook. BMC Helix Intelligent Integrations receives events from devices in JSON format and applies the mapping defined in the JSLT to transform them into BMC Helix Operations Management understandable events (in JSON format).
- Prepare the event JSLT and event class JSON.
For information about the guidelines, see Guidelines to prepare the event JSLT and event class JSON. - Prepare the metric JSLT.
For information about the JSLT guidelines, see Guidelines to prepare the metric JSLT. Prepare the event class JSON if you plan to use a custom event class other than the existing classes in BMC Helix Operations Management.
Guidelines to prepare the event JSLT and event class JSON
Use the following guidelines to prepare the event JSLT:
Iterate over input events: If the input JSON is an array of events, always wrap the transformation in a for loop, as shown in the following example:
[
for (.)
{ ... mapped object ... }
]Generate unique identifiers: Use JSLT helper functions to ensure every outgoing event is unique, as shown in the following example:
let uuid = uuid()Construct External CI ID: Use a fixed prefix, CI type, and UUID, as shown in the following example:
let ciExternalId = string("TSOM_" + .ciType + "-" + $uuid)- Map source fields to target fields: Prepare a table that shows the mapping, as shown below:
Source JSON Target field .severity "severity" .msg "msg" .status "status" .mc_host "source_hostname" .class "class" Example:
"severity": .severity,
"msg": .msg,
"status": .status,
"source_hostname": .mc_host,
"class": .class - Use extras to handle any optional or custom attributes in the source JSON that cannot be mapped to any of the fields in the Target field column, as shown in the following example:
"extras": {
"sourceEventID": string(.extras.sourceEventID),
"sourceEventType": .extras.sourceEventType
}
If you are using any optional or custom attributes, include them in the custom event class JSON as shown in an example later.
Important: If you don't include the optional or custom attributes in extras, they are not passed to the event slots in BMC Helix Operations Management. - Build composite or derived fields if required: Build fields by using the additional logic. For example, if you want to modify the event message, use the following syntax:
"msg": .msg + string(floor(random() * 100)) + "%" Standardize source identification fields, as shown in the following example:
"_ci_id": $ciExternalId,
"source_identifier": $ciExternalId,
"source_attributes": {
"external_id": $ciExternalId
}Define unique event identifiers, as shown in the following example:
"source_unique_event_id": "TSOM_" + $uuidPreserve compatibility fields: Some fields are retained as-is even when not transformed, as shown in the following example:
"_identifier": .mc_host,
"ii_version": (.ii_version)
Guideline to prepare event class JSON
If you need to include mapping for any optional or custom attributes for which no mapping is available in the standard JSLT, include them in the event class JSON, as shown in the following example:
"attributes": [
{
"name": "sourceEventID",
"dataType": "INTEGER"
},
{
"name": "sourceEventType",
"dataType": "STRING"
}
]
The following files show a sample JSON, corresponding JSLT, and custom event class JSON. Update them as per your requirements.
Guidelines to prepare metric JSLT
Use the following guidelines to prepare the metric JSLT:
BMC Helix Intelligent Integrations requirements
- Choose the on-premises BMC Helix Intelligent Integrations deployment mode and review the corresponding port requirements. For information about various deployment modes and port requirements, see Deployment-scenarios.
- Make sure the on-premises gateway can reach the third-party product on the required port.
Task 2: To configure the connection with a third-party product via webhook
To access the BMC Helix Intelligent Integrations on-premises gateway, use the following URL:
https://<hostName>:<portNumber>/swpuiOn the CONNECTORS tab, click Add
in the SOURCES panel.Click the Generic Collector tile.
- Specify a unique instance name.
- Click VALIDATE AND CREATE.
- Make sure that the options for the data types for which you want to collect data are selected.
- To create collector streams for the selected data types, click CREATE COLLECTORS.
- To configure distributors for the selected data types, click the respective data type in the Distributors section.
- In the Distributors section, configure the JSLT mapping for events, metrics, and the event class JSON by performing the following steps:
- In the JSLT mapping field, enter the required JSLT mapping.
- In the Event Class JSON field, enter the required event class JSON and the event class policy for any custom classes.
See the Third-party product prerequisites section for sample events and metrics JSLT mapping and sample event class JSON. - Save the configuration.
- To create distributor streams for the selected data types, click CREATE DISTRIBUTORS.
- Click SAVE STREAM.
After you save the stream, the generic collector that you created is listed on the SOURCES panel. - On the SOURCES panel, click Configure Mediator
for the source connection that you created and then expand GENERIC EVENTS WEBHOOK. - Click copy
to copy the auto-generated webhook collector URL and save it in a temporary file.
For example, https://hostA/hii/api/mediator/v3/push/9mn-6c97-4c2e-8pc5-12c0asdf?token=API-KEY. - Depending on whether authentication is enabled or disabled for the on-premises gateway, perform one of the following steps:
- If you are using the on-premises gateway for which authentication is enabled, perform the following steps:
Log on to BMC Helix Portal and generate an access key.
For instructions, see Setting up access keys for programmatic access.- Copy the generated access key and save it in a temporary file.
The key is generated in the format: <accessKey>::<secretKey>::<tenantID>.
For example, Y40OSC49QZA11Q8A1H9H6::MnVLk69TNyCEponsthHJ1Hj1uKcjTB::385261281 - Change the format of the access key to <tenantID>::<accessKey>::<secretKey>.
For example, 385261281::Y40OSC49QZA11Q8A1H9H6::MnVLk69TNyCEponsthHJ1Hj1uKcjTB - In a temporary file, modify the auto-generated collector URL by replacing API-KEY with the access key that you formatted in the previous step.
For example, https://host.ab.com/hii/api/mediator/v3/push/9mn-6c97-4c2e-8pc5-12c0asdfd?token=385261281::Y40OSC49QZA11Q8A1H9H6::MnVLk69TNyCEponsthHJ1Hj1uKcjTB. - Configure the third-party product to send data to the on-premises gateway.
- If you are using the on-premises gateway for which authentication is disabled, perform the following steps:
- Save the URL in a temporary file.
- Remove the following string from the collector URL:?token=API-KEY
The updated collector URL looks like the following example:
https://hostA/hii/api/mediator/v3/push/9mn-6c97-4c2e-8pc5-12c0asdf - Configure the third-party product to send data to the on-premises gateway.
- If you are using the on-premises gateway for which authentication is enabled, perform the following steps:
On the SOURCES panel, click Configure Mediator
for the source connection that you created and then expand GENERIC METRICS WEBHOOK, and perform steps 13 and 14 for the webhook collector URL for metrics.On the SOURCES panel, move the slider to the right to start the data stream for the generic collector.
Task 3: To configure a third-party product to send data to BMC Helix Intelligent Integrations
- Log on to the third-party product.
- Copy the webhook collector URLs for both events and metrics that you modified in steps 14 and 15, and add them to the third-party webhook configuration.
- Log on to the BMC Helix Intelligent Integrations on-premises gateway.
- On the SOURCES panel, move the slider to the right to start the data stream for the generic collector.
Task 4: To verify the connection
From BMC Helix Intelligent Integrations, on the SOURCES panel, confirm that the data streams for the connection you created are running. Data streaming is indicated by moving colored arrows.

- A moving blue arrow (
) indicates that the event stream is running. Event data will be pushed as soon as events are available from the third-party product. - A moving red arrow (
) indicates that the metric stream is running. Metric data will be pushed as soon as metrics are available from the third-party product.
Task 5: To view data in BMC Helix applications
View data collected from the third-party product in multiple BMC Helix applications.
To view events in BMC Helix Operations Management
- In BMC Helix Operations Management, select Monitoring and then select Events.
- Filter the events by the class name that you have provided in the event class JSON.

For more information about events, see Monitoring and managing events.
To view metrics in BMC Helix Operations Management:
- In BMC Helix Operations Management, select Monitoring > Devices.
- Click the link for the device that has received metrics from the third-party product.
- On the Monitors tab, click the monitor that contains the received metrics.
The following figure shows the graph for a sample metric on the Performance Overview tab on the Monitor Details page: 
For information about metrics, see Viewing collected data.