notification of aging incident ticket

vamshi2
Tera Contributor

Hi Team,

 

my requirement is to trigger a notification as below 

Frequency : Monthly twice, 1st &  3rd Monday of every month
Scope : Active aging IN tickets (Incident tickets older than 15 days after its created)
Recipients:- abc@test.com,xyz@test.com

4 REPLIES 4

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @vamshi2 

If you're in the Zurich release, then setting the frequency is much easier—it's almost out-of-the-box.
However, if you're on a lower version, you'll need to build custom logic to get, for example, the 1st and 3rd Monday.

For the rest (e.g., checking if something hasn't been updated in the last 15 days and then sending a notification), you can use a simple flow.

Suggested Flow Actions:

  1. Action: Look Up Records
    – Use this to find the records based on your condition (e.g., last updated before 15 days).

  2. Action: Send Notifications
    – Once records are found, use this to notify users accordingly.

Let me know your version if you need help customizing the date logic.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Rafael Batistot
Tera Sage

Hi @vamshi2 

 

you need combine 1. Schedule Job (find incident 15 older) + 2. Event Registry (to trigger notification) + 3. Email > Notification ( body msg content) 

 

Let know if you have one these created, if not may I guide you 

Ankur Bawiskar
Tera Patron
Tera Patron

@vamshi2 

You can easily do this minimal scripting

1) create a report with this condition Updated 15 days ago

2) then create a scheduled report and associated this report to it

3) in scheduled report make it run daily and in condition field check if it's 1st or 3rd Monday of month, if yes set answer=true

4) in recipients add the email address you want and the format you want either PDF, Excel etc

5) Set subject, email body etc

// your logic here
var now = new GlideDateTime();
var day = now.getDayOfWeek();  // 1 = Monday, 7 = Sunday
if (day != 1) {  // Run only if Monday
    answer = false;
} else {
    // Count how many Mondays have passed this month including today
    var currentDate = now.getDayOfMonth(); 
    
    // Calculate which Monday this is in the month
    var mondayCount = Math.floor((currentDate - 1) / 7) + 1;
    
    // Run only if 1st or 3rd Monday
    answer = (mondayCount == 1 || mondayCount == 3);
}

answer;

AnkurBawiskar_0-1756902847078.png

 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@vamshi2 

Hope you are doing good.

Did my reply answer your question?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader