Automatically set a new user's domain using flow designer

cnharris1
Kilo Sage

Good morning developers,

I'm using Flow Designer to create new users in ServiceNow from a rest api call and that part is working fine. The only issue I'm having is setting the user's domain. For some reason I'm setting the domain in Flow Designer to "ServiceNow(testing domain)" but its not working. Is there something that I'm missing?

cnharris1_0-1701875379407.png

 

 

Any guidance will be greatly appreciated!

 

Best regards,

cnharris1

1 ACCEPTED SOLUTION

Hi @Dr Atul G- LNG , 

Thank you for your quick response. Yes, we are using the domain separation. I finally figured out what the issue was. In Flow Designer, instead of using the actual name of the domain, I used the sys_id of the domain and it worked perfectly. Not sure why the name didn't work but I was able to populate the user's domain.

Thank you again for your help!

 

Best regards,

cnharris1

View solution in original post

3 REPLIES 3

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @cnharris1 

 

Are you using the Domain separation or check in SN user table, what values, OOTB it is global domain. 

*************************************************************************************************************
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]

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

Hi @Dr Atul G- LNG , 

Thank you for your quick response. Yes, we are using the domain separation. I finally figured out what the issue was. In Flow Designer, instead of using the actual name of the domain, I used the sys_id of the domain and it worked perfectly. Not sure why the name didn't work but I was able to populate the user's domain.

Thank you again for your help!

 

Best regards,

cnharris1

Thanks @cnharris1  for sharing the update. Happy you got the solution.

*************************************************************************************************************
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]

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