cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tejal23
Frequent Visitor

Get group name using Graph API

Hello,

I need help getting user's group name. I have tried creating graph api using command 

 

Get https://graph.microsoft.com/v1.0/me/memberOf

 

it works but i need help getting group name with dynamic user selection. 

I have dropdown box with user selection and on change event if i can pull group name for selected user. 

Any idea??? 

Thank you,

-T

 

 

3 REPLIES 3
v-qiaqi-msft
Community Support
Community Support

Hi@tejal23,

Do you want to list all the group where the selected user is in?

Could you please share a bit more about the scenario?

I have a test on my side, please take a try as below.

Please make sure that you have connected AzureAD and Office365Users to your app.

Add a Combo Box and set the Items as below:

Office365Users.SearchUser({searchTerm:ComboBox1.SearchText})

Notice that you'd better make the primary text and search text as below:2021-02-25-02.png

Set the OnChange property of the Combo Box as below:

ClearCollect(
    AllGroups,
    AddColumns(
        AzureAD.GetMemberGroups(ComboBox1.Selected.Mail,false).Value,
        "GroupName",
        AzureAD.GetGroup(Value).mail
    )
)

Add a Gallery and Set the Items property as below:

AllGroups
    

Hope it could help you.

Regards,

Qi

Best Regards,
Qi

Qi,

 

Thank you for reply, I am using Graph API not Azure AD. I am not able to use Azure AD connector. Here is my scenario as below.

I have SharePoint list with column name USER, It's property set to people/group. It is associate to combo box with following Item set to Choices([@list].User).

I need to sent user info to Graph API and get user group information.

 

I hope i am able to explain my issue.

 

Tejal

 

tejal23
Frequent Visitor

Qi,

 

Thank you for reply, I am using Graph API not Azure AD. I am not able to use Azure AD connector. Here is my scenario as below.

I have SharePoint list with column name USER, It's property set to people/group. It is associate to combo box with following Item set to Choices([@list].User).

I need to sent user info to Graph API and get user group information.

 

I hope i am able to explain my issue.

 

Tejal

 

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Power Apps Community Call Jan. 2022 768x460.png

Power Apps Community Call

Please join us on Wednesday, January 19th, at 8a PDT. Come and learn from our amazing speakers!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,949)