Flow Designer Notification Issue – Dynamic RITM Link Not Working & List Collector Users Not Displayi

Sirri
Tera Guru

Hi Team,

I am working on a Flow Designer (Application Access Request Flow) where a notification is triggered after fulfillment of a Requested Item (RITM).

The notification is triggering successfully, but I am facing two issues in the email content.

Issue 1: Dynamic RITM Link Not Working

I am trying to include a clickable link in the notification that redirects to the specific RITM.

Current Behavior:

  • The email is sent successfully
  • However, the link appears with an incorrect or empty sys_id (sometimes null)
  • As a result, it does not open the expected RITM record

Requirement:

What I Tried:

var url = gs.getProperty("glide.servlet.uri") +
          fd_data.trigger.table_name + ".do?sys_id=" +
          fd_data.trigger.current.sys_id;

 

var link = '<a href="' + url + '">here</a>';

 

return link;

Issue:

  • fd_data.trigger.table_name and fd_data.trigger.current.sys_id are not resolving correctly in Flow Designer context
Issue 2: List Collector (list_of_members) Not Showing User Names

I am using a catalog variable:

  • Name: list_of_members
  • Type: List Collector (reference → sys_user)

Current Behavior:

  • Notification does not display selected users
  • Since it stores sys_ids, nothing meaningful is shown

Requirement:

  • Display user names in notification

Expected Output:

Users granted access: User1, User2, User3

Note:
For link I have used the SetFlowVariables.
In Flow for Notification I have used the Send Email & That flow variable I have called in notification for link.
1 ACCEPTED SOLUTION

yashkamde
Mega Sage

Hello @Sirri ,

 

can you share me the screenshot of the flow?

 

Also, try adding a log action to check what values are coming through:

gs.log("Table Name: " + fd_data.trigger.table_name);
gs.log("Sys ID: " + fd_data.trigger.current.sys_id);

 

For the list collector, once we see the flow setup, we can adjust the script to resolve sys_ids into user names before sending them in the notification.

View solution in original post

5 REPLIES 5

yashkamde
Mega Sage

Hello @Sirri ,

 

can you share me the screenshot of the flow?

 

Also, try adding a log action to check what values are coming through:

gs.log("Table Name: " + fd_data.trigger.table_name);
gs.log("Sys ID: " + fd_data.trigger.current.sys_id);

 

For the list collector, once we see the flow setup, we can adjust the script to resolve sys_ids into user names before sending them in the notification.

@yashkamde ,

Please find the below snip.

Sirri_0-1782464923574.pngSirri_1-1782464939272.png


Thank you

Try this in your toggle script :

var url = '<a href="' + '/' + fd_data.trigger.table_name + '.do?sys_id=' + fd_data.trigger.request_item.sys_id + '">' + fd_data.trigger.request_item.number + '</a>';

return '[code]' + url + '[/code]';

 

In your script fd_data.trigger.sys_id might be fetching different sys_id !

I tried this in work notes and its working :

Screenshot 2026-06-26 155122.png

 

If my response helped mark as helpful and accept the solution.

 

Tanushree Maiti
Tera Patron

Hi @Sirri 

 

Since List Collector variables store an array of comma-separated sys_ids, using Email Script, you can extract and display them by building a helper loop .

 

  1. Create a Notification Email Script
    Go to System Notification > Email > Notification Email Scripts and click New.

Name: display_list_collector_users

 

(function runMailScript(current, template, email, email_action, event) {

    var members = current.variables.list_of_members;

        if (members) {

        var userNames = [];

        var userGr = new GlideRecord('sys_user');

        userGr.addQuery('sys_id', 'IN', members);

        userGr.query();

        while (userGr.next()) {

            userNames.push(userGr.getDisplayValue());

        }

        if (userNames.length > 0) {

            template.print('Users granted access: ' + userNames.join(', '));

        } else {

            template.print('Users granted access: None');

        }

    } else {

        template.print('Users granted access: None');

    }

})(current, template, email, email_action, event);

 

  1. Add Script to Notification
    Go to Notification record>  Advanced view > add

 ${mail_script:display_list_collector_users} in the Message body

 where you want the names to appear.

This approach ensures your list dynamically prints out nicely as: Users granted access: User1, User2, User3.

 

 

Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti