cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
beckyjc
Level: Power Up

List users in Dynamics 365 field security profile

Hi,

 

Does anybody have a way of listing users (i.e. in order to send them an SMS and email) who are members of a particular Dynamics 365 field security profile? I'm new to flow and struggling to see any obvious way to do this but it feels like it should be possible. 

 

Thanks,

Becky

3 REPLIES 3
Super User
Super User

Re: List users in Dynamics 365 field security profile

Hi @beckyjc 

 

See below steps will explain how to retrive users from a specified field security level. 

 

Here I am using a manual trigger. Then intialised a variable called SecurityProfile. This is used later for storing the GUID of specified field level security group. Here my group is called 'Special Group'. Next step we need to use the List records. Here I am using the filter query. Please see below steps.

 

sec1.png

 

Next step we need a loop to extract the value of the 'Special Group' Id (GUID). See below.

 

sec2.png

 

Next we need to retrieve all the users falls under the above field security group. Here I am using FetchXML query and I am mapping the above GUID for the filter. You can use ODATA for the filter as well. I am taking the easy route here 🙂

 

sec3.png

 

Next we need to pass the results. Here I am using Parse JSON.

 

sec4.png

 

Below is the JSON Schema.

{
"type": "object",
"properties": {
"@@odata.context": {
"type": "string"
},
"value": {
"type": "array",
"items": {
"type": "object",
"properties": {
"@@odata.etag": {
"type": "string"
},
"fullname": {
"type": "string"
},
"_businessunitid_value": {
"type": "string"
},
"systemuserid": {
"type": "string"
},
"ownerid": {
"type": "string"
}
},
"required": [
"@@odata.etag",
"fullname",
"_businessunitid_value",
"systemuserid",
"ownerid"
]
}
}
}
}
 
sec5.png

Next we need another loop to extract the user details. Here I am using a compose step to display Fullname of the users. In your case you need to find the email and add another step called email. Another method is collect all the emails of the users and send one email to all users.

 

Hope it make sense. If you need any more help please let me know.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



beckyjc
Level: Power Up

Re: List users in Dynamics 365 field security profile

Hi @abm ,

 

Thank you for the detailed response, this looks to be exactly what I needed.  Will try it ASAP and report back!

 

Thanks again,

Becky

Super User
Super User

Re: List users in Dynamics 365 field security profile

Hi @beckyjc 

 

If you need any further help in this please let me know.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors (Last 30 Days)
Users online (5,497)