How to get User ID by Email in MS Flow (Power Automate) SharePoint

Its pretty straight forward when you know how to do. Going straight to the point.

  1. Create a new MS Flow and name it whatever you want.
  2. Create Get Items action. and fill the Site Adress, list name etc according to your environment.
  3. I am renaming my action to GetUserIDByEmail.
  4. Initialize a Variable and set its value to expression as mentioned below.
  5. Save and run the Flow.

Here is the schema of the returned JSON.

{
"d":{
"__metadata":{ },
"Alerts":{ },
"Groups":{ },
"Id":280,
"IsHiddenInUI":false,
"LoginName":"i:0#.f|membership|someone@example.com",
"Title":"Someone Name",
"PrincipalType":1,
"Email":"someone@exmaple.com",
"Expiration":"",
"IsEmailAuthenticationGuestUser":false,
"IsShareByEmailGuestUser":false,
"IsSiteAdmin":false,
"UserId":{ },
"UserPrincipalName":"someone@example.com"
}
}



You need to first check the output schema and only then your expression will work.

Comments

Popular Posts

GREYCstoration Oil Paint plugin for Photoshop

Service Bus Gateway service stuck at Starting

PowerApps SubmitForm not clearing People Picker value

Apple iPhone sending SMS automatically 00447786205094

Download file failed signature verification and may have been tampered with - Workflow Manger 1.0 Refresh (CU2)