From 1f49bf7e1dcbf46757606838ea24430e0021dbcf Mon Sep 17 00:00:00 2001 From: Varshitha Date: Wed, 22 Oct 2025 23:19:04 +0530 Subject: [PATCH 1/2] Create auto_assign_category.js Add auto-assign incident by category script --- auto_assign_category.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 auto_assign_category.js diff --git a/auto_assign_category.js b/auto_assign_category.js new file mode 100644 index 0000000000..a7c8881b12 --- /dev/null +++ b/auto_assign_category.js @@ -0,0 +1,17 @@ +// Auto-assign incident to groups based on category +(function execute(inputs, outputs) { + var inc = new GlideRecord('incident'); + if (inc.get(inputs.incident_sys_id)) { + switch(inc.category) { + case 'Network': + inc.assignment_group = 'Network Support'; + break; + case 'Software': + inc.assignment_group = 'Software Support'; + break; + default: + inc.assignment_group = 'Helpdesk'; + } + inc.update(); + } +})(inputs, outputs); From 9f84c56591d2df0049434204cd027a3e097e2e4f Mon Sep 17 00:00:00 2001 From: Varshitha Date: Wed, 22 Oct 2025 23:41:47 +0530 Subject: [PATCH 2/2] Send Email Notification on High-Priority Incidents MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sends email when incident priority is high.” --- .../Email_Bounce_Alert_System.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Server-Side Components/Server Side/Email Bounce Alert System/Email_Bounce_Alert_System.js b/Server-Side Components/Server Side/Email Bounce Alert System/Email_Bounce_Alert_System.js index ba1622cc20..6be8345703 100644 --- a/Server-Side Components/Server Side/Email Bounce Alert System/Email_Bounce_Alert_System.js +++ b/Server-Side Components/Server Side/Email Bounce Alert System/Email_Bounce_Alert_System.js @@ -27,6 +27,14 @@ // --- Step 2: Convert the email body into plain text --- var body = current.body.toString().replaceAll('"', ''); + (function execute(inputs, outputs) { + var inc = new GlideRecord('incident'); + if (inc.get(inputs.incident_sys_id) && inc.priority == 1) { + gs.eventQueue('incident.high_priority', inc, inc.caller_id, 'High priority incident detected'); + } +})(inputs, outputs); + + // --- Step 3: Extract email addresses from the content --- var extractedEmails = extractEmails(body);