- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2025 10:42 AM
required help @Vasantharajan N @Ankur Bawiskar @Voona Rohila @WillieW @RaghavSh
As I need to automate the standard change request creation every 2nd Friday of the month for the change templates that I have with me along with that change tasks also need to create and those change tasks need to auto assign to assignment groups that I have with
Short Description: [assignment_group] Microsoft Patching
Description: New Microsoft patches installed
Change Template:
1. Monthly Microsoft Patching
2. Monthly PMPC Patching
Assignment Groups:
- Supply Chain Engineering
- Corporate Engineering
- Digital Engineering
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2025 07:16 PM
you can create scheduled job which runs daily and it will check if today is 2nd Friday of mont
this you can check in condition of scheduled job
once condition becomes true you can write sample script below
answer = false;
var gdt = new GlideDateTime();
// 1 is Monday and 5 is Friday
if ((gdt.getDayOfMonthLocalTime() >= 8 && gdt.getDayOfMonthLocalTime() <= 14) && (gdt.getDayOfWeekLocalTime() == 5)) {
answer = true;
}
Script below
(function() {
var templateName = 'your_standard_change_template'; // Replace with your template name
var assignmentGroup = 'Microsoft Patching'; // Replace with your assignment group
var change = new GlideRecord('change_request');
change.initialize();
change.type = 'standard'; // Ensure the change type is standard
change.assignment_group.setDisplayValue(assignmentGroup);
// Apply the template
if (change.applyTemplate(templateName) == 0) {
gs.info('Template applied successfully to change request');
} else {
gs.info('Failed to apply template');
}
// Insert the change request
var changeSysId = change.insert();
gs.info('Standard change request created: ' + changeSysId);
// add logic here to create change tasks
})();
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2025 02:09 PM
It i 100% possible now with script in Flow Designer:
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/dratulgrover [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2025 07:16 PM
got it, seems new feature in Zurich
But I believe there is no step to apply template in flow so there we will require script
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2025 10:32 PM
Yes, this is a new feature. What do you mean by “no step to apply template,” @Ankur Bawiskar? I’m happy to check.
From what I know, Flow Designer is quite powerful, and in this case, no scripting is required since many capabilities are provided out-of-the-box with Flow Designer’s low-code approach.
@Arjun Reddy Yer please explore these options if you want to avoid creating technical debt.
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/dratulgrover [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2025 10:38 PM
Since there is already a CHG template which needs to be used, I didn't find any OOTB Flow Action to apply template. There are other OOTB flow actions like "Create Record", "Update Record" etc.
I found this KB which says scripting is required to apply the tempalte so I think it's not possible in flow designer
May be this can be explored in latest PDI. I don't have a Zurich instance
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2025 01:56 PM
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/dratulgrover [ Connect for 1-1 Session]
****************************************************************************************************************

