Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

ServiceNow ITOM Connector and Elastic Kibana Integration

SNLearnAll
Tera Contributor

I have successfully integrated Kibana Alerts with ServiceNow ITOM connector and incidents are being triggered.
However, I need to set incident priority based on alert Severity. The alert severity levels comes to ServiceNow as Critical, Major, Minor and Warning and I want them mapped to P1, P2, P3 and P4 respectively.

 

Can anyone please help me how to achieve that through flow designer in alert management rule? I want to map the Urgency and Impact individually. Attached is a screenshot of my instance Priority Lookup Rules.

 

Thank you all for your support.

 

Below are the scripts I've written but not working.

 

For Impact:

function mapSeverityToImpact(severity) {
if (severity === 'Critical') {
return '1'; // P1
} else if (severity === 'Major') {
return '2'; // P2
} else if (severity === 'Minor') {
return '3'; // P3
} else if (severity === 'Warning') {
return '4'; // P4
} else {
return '4'; // Default to '4' if severity doesn't match
}
}

 

For Urgeny:

function mapSeverityToUrgency(severity) {
if (severity === 'Critical') {
return '1'; // P1
} else if (severity === 'Major') {
return '2'; // P2
} else if (severity === 'Minor') {
return '3'; // P3
} else if (severity === 'Warning') {
return '4'; // P4
} else {
return '4'; // Default to '4' if severity doesn't match
}
}

0 REPLIES 0