Hi,
I'm working on a leave request workflow and I'd like to be able to pull the employee's ID. This data comes from AD. I looked in the "Get user profile" but there isn't an option to get the employee ID.
Any ideas?
Solved! Go to Solution.
It's easy š
Just use the Azure AD (Get User) passing the user email.
It's brings the ID as the first field
Hope this helps
Gustavo Moraes, o astronauta brasileiro do Flow!
Get user profile only fetches basic list of properties
Any custom properties(extension attributes) - graph api will be the option
Regards,
Reza Dorrani
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
@RezaDorraniThanks for your response. Do you happen to have any resources where i can find more information on that?
check comments on this idea
Regards,
Reza Dorrani
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
It's easy š
Just use the Azure AD (Get User) passing the user email.
It's brings the ID as the first field
Hope this helps
Gustavo Moraes, o astronauta brasileiro do Flow!
Hi @_sourcecod3_,
Has your problem been solved?
If your problem has been solved, You could go ahead and mark the post as solved by clicking āAccept as Solutionā so that this thread will be marked for other users to easily identify!
Best Regards,
Community Support Team _ Lin Tu
@gamoraesThanks and I apologize for the late response. What other attributes will this provide?
Thanks
Hi
The return have:
Id
|
id | string |
A unique identifer for the user. |
Business Phones
|
businessPhones | array of string | |
Display Name
|
displayName | string |
The name displayed in the address book for the user. |
Given Name
|
givenName | string |
The given name (first name) of the user. |
Job Title
|
jobTitle | string |
The userās job title. |
Mail
|
string |
The SMTP address for the user. |
|
Mobile Phone
|
mobilePhone | string |
The primary cellular telephone number for the user. |
Office Location
|
officeLocation | string |
The office location in the user's place of business. |
Preferred Language
|
preferredLanguage | string |
The preferred language for the user. Should follow ISO 639-1 Code; for example 'en-US'. |
Surname
|
surname | string |
The user's surname (family name or last name). |
User Principal Name
|
userPrincipalName | string |
The user principal name (UPN) of the user.
|
|
The full documentation is here
Gustavo Moraes, o astronauta brasileiro do Flow!
This took a lot of trial and error but I finally was able to get the employeeId from the Get User Profile (V2) connector.
Click "Show Advanced Options" on the Get User Profile connector. Enter the data elements you want returned in the Select Fields text box. (I don't know why it doesn't just return all of them.)
After the Get User Profile (V2) connector add compose and parse JSON data connectors.
You can find the JSON schema here: https://docs.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0#json-representation
From there you should be able to find the user profile data in the dynamic content in the connector where you need to use it.
Hope this helps!
@ToddAtLSUHSC I can't get the parse JSON to give me anything additional to what I get from the get user V2 action. Any pointers where I could be going wrong?
Can you post a screenshot of what you have? Thanks.
Here's what I've got, not sure if I got the JSON schema right but it didn't give me any errors š
@robofski My bad. I forgot to add an important part to my post. You need to click "Show Advanced Options" on the Get User Profile connector. Enter the data elements you want returned in the Select Fields text box. I don't know why it doesn't just return all of them. Hopefully that is it.
I wish I could double like this š That's it, perfect, **bleep** shame I have to select all the fields I want not just the additional ones, but for what I'm after this will be perfect. Thanks @ToddAtLSUHSC
I have updated my original post with the "missing" step. First mistake...since the last one. š
@ToddAtLSUHSC just looking at the output of the Get User Profile V2 and now I get the EmployeeID there so that would render the other steps unnecessary wouldn't it or am I missing something here?
Not sure what steps you are referring to. In my testing, before I figured it out, I could see the employeeId data in the run history, but I couldn't access it. It took who knows how many tests before I finally got it.
@ToddAtLSUHSC and that's why you're the master and I'm the student, you are of course right, while it shows in the run history, it's not available in subsequent steps as dynamic data from the Get User Profile action. Thanks again!
Hi @robofski @ToddAtLSUHSC I want to get the EmployeeID, I'm new to this, so don't know where even to start, Can I get help some help with this. Steps how to get this done
Join digitally, March 2ā4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!
User | Count |
---|---|
34 | |
15 | |
15 | |
13 | |
7 |
User | Count |
---|---|
41 | |
31 | |
25 | |
12 | |
12 |