Monthly trends by response
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2023 05:22 AM
I need to build a SLA dashboard - trending by month on when the response and resolution times have been meet
How can I do this in PEFORMANCE Analytics?
- Labels:
-
Performance Analytics
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2023 05:48 AM
HI @Casey4 ,
I trust you are doing fine.
To build an SLA dashboard in Performance Analytics, you'll need to follow these steps:
Define your SLAs: Before you can track your SLA performance, you need to define your SLAs in ServiceNow. This involves setting target response and resolution times for each service, as well as defining the conditions under which SLAs should be triggered.
Create indicators: Next, you'll need to create Performance Analytics indicators to track your SLA performance. You can create indicators for response time, resolution time, and SLA compliance. These indicators will measure how well you're meeting your SLAs over time.
var sla = new GlideRecord('contract_sla');
sla.addQuery('name', 'My SLA');
sla.query();
if (sla.next()) {
var pa = new GlideRecord('pa_indicator');
pa.name = 'My SLA Compliance';
pa.aggregation = 'sum';
pa.table = 'incident';
pa.filter = 'active=true^incident_state!=6';
pa.formula = 'SUM(IF(response_time_breach=false AND resolution_time_breach=false, 1, 0)) / COUNT(*)';
pa.pa_source = sla.sys_id;
pa.insert();
}
This code creates a PA indicator for an SLA named "My SLA". It measures SLA compliance for incidents, excluding those that are closed. The formula calculates the percentage of incidents that met the SLA based on the response and resolution time breaches.
- Create a dashboard: Once you have your indicators, you can create a Performance Analytics dashboard to visualize your SLA performance over time. You can use widgets like line charts and scorecards to display your SLA trends by month.
Here's
var dashboard = new GlideRecord('pa_dashboards');
dashboard.name = 'SLA Dashboard';
dashboard.type = 'standard';
dashboard.insert();
var widget = new GlideRecord('pa_widgets');
widget.dashboard = dashboard.sys_id;
widget.type = 'line_chart';
widget.filter = 'name=My SLA Compliance^duration=month^sysparm_pa_widget_query=';
widget.insert();
Was this answer helpful?
Please consider marking it correct or helpful.
Your feedback helps us improve!
Thank you!
Regards,
Amit Gujrathi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2023 07:53 AM
You also might want to check and see if you can use these, we do have some SLA indicators OOTB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2023 08:44 AM
thanks Tsura
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2023 03:33 PM
How do I get a list of all these within the instance?