How to Add users to groups in the same flow designer?

Nilanjan1
Mega Sage

Hi guys,

Using flow designer, how can I automate the fulfilling of a catalog task that adds users to newly created group.

The request contains a list collector of all the user needs to be added in the new group. 

 

I am able to sucessfully create a new group but somehow I am unable to add the user to the newly created group.

Also I am able to generate the sys_ID of the user and I can see them being created, but adding to the group is not happening. 

I am seeing an error " Invalid table used". I am not sure what to do next ! 

Some screenshots attached for your reference. 

4 REPLIES 4

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

So you have 1 group and multiple users to be added to that group

This you want to achieve using flow designer

in the input to Subflow you should use User variable as type List->sys_user

Also you need to use lookup records to get all the records of sys_user and then use For Each Action to add user to that group

Regards
Ankur

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

Hi @Ankur Bawiskar ,

I have this exact scenario I am developing now. Do you have an example of this subflow to add users to a newly created group?

Thank you,

Mark

@Mark Nguyen 

check this link and enhance as per your requirement

Flow Designer - Add one user to multiple groups via variable "List Collector" 

 

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

Thank you @Ankur Bawiskar