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

How can I get an Azure AD object ID using Flow? Deleting guest user accounts using graph API + Flow

Hello,

 

I'm trying to configure a Flow to delete guest user account. To do this, I need to pass a HTTP request to the Microsoft Graph API. My flow gets the user-to-be-deleted's account from a SharePoint list which contains other things such as the user's date-to-be-deleted etc. This works fine for regular, licensed accounts because I can just pass the user's account username (john.doe@ourdomain.com) into the HTTP request. However, this does not work for guest accounts. I have found the only solution to be passing in the guest user's object ID but I do not know how to automate getting it.

 

One solution would be to have the workflow user retrieve the Object ID from Azure AD but I would like to find a more automated approach to this.

 

I appreciate any feedback!

2 REPLIES 2
Community Support Team
Community Support Team

Re: How can I get an Azure AD object ID using Flow? Deleting guest user accounts using graph API + F

Hi @brendonts,

 

It's maybe difficult to find another more automated approach to achieve your requirement.

 

Best regards,

Alice

brendonts
Level: Power Up

Re: How can I get an Azure AD object ID using Flow? Deleting guest user accounts using graph API + F

I don't expect it to be anything but difficult, that's what makes it challenging....

 

Still looking for any input on this.

Helpful resources

Announcements
firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

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 Solution Authors
Top Kudoed Authors (Last 30 Days)
Users online (5,473)