cancel
Showing results for 
Search instead for 
Did you mean: 
Workflow Hero

Office 365 Query User Profile Action guide

Jump to solution

Has anyone successfully used the O365 Query User Profile Action with User Column in a SharePoint list and get proper data back?

I am trying to get the manager for a particular user assigned in the form. When passed in the User Email, it kept throwing an error .  When i dump the user data into the history it looked like i:0#.f|membership|firstname.lastname@trial.onmicrosoft.com. Is this an overlook by the Nintex team that the user column would contain claims?

So far I could only use it properly if I use the action with the Workflow Context for Initiator and Manager but can't be used for any other users.

Any ideas?

Labels: (1)
0 Kudos
Reply
10 Replies
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

That still looks like the user's account login, not their email address. Did you use the Format This Value feature on the User Column to return just the email address? If not, it is returning the account login and will not be able to find the user.

More details here on Format this Value: Using the Format this Value Feature

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

Andrew , you are right on using the the format value. The placeholder values are very misleading as you can't see what you actually choose to show.

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

But is there any way of getting the phone number or any other useful info in the profile?

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

Yes, in the Property setting you set with the name of the property you need back, such as Phone. http://help.nintex.com/en-US/O365/#O365WorkFlow/Workflow Actions - INT/Office 365 Query User Profile...

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

But this needs a password. Users opening forms or running workflows have already been authenticated. They should already be able to look up info such as a phone number. Why should a password be necessary? Can I query the user profile without a password. If I setup my password and ID here, will I need to change it on the workflow everytime I reset my password... it would seem so...which would make this a real bother (when everytime my password is changed, workflows break). Is there a way around setting a password. I really do not want to ask our security folks to create a bespoke account for this. Like a SharePoint App Step, there should be a way of running it with publisher's permissions - Is there?

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

That's a great suggestion to not require credentials if used within an App Step. I would post that  here 3 - Nintex Workflow for Office 365: Hot (141 ideas) – Customer Feedback for Nintex

But you may be able to use a rest call within an App Step to do the same thing.

Get all properties of Specific User

http://siteurl/_api/SP.UserProfiles.PeopleManager/GetPropertiesFor(accountName=@v)?@v='i:0%23.f|memb...0%23.f|membership|username@siteurl.onmicrosoft.com'

Get Specific UserProfile Property of Specific User

http://siteurl/_api/SP.UserProfiles.PeopleManager/GetUserProfilePropertyFor(accountName=@v,propertyN...0%23.f|membership|username@siteurl.onmicrosoft.com'

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution
0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

https://tenant.sharepoint.com/_spi/SP.UserProfiles.PeopleManager/GetPropertiesFor(accountName=@v)?@v...

I get a 404 error when I test against my actual tenant using Postman.  Note, I have run the interceptor to login into the tenant.

Anybody else attempted this?

0 Kudos
Reply
Workflow Hero

Re: Office 365 Query User Profile Action guide

Jump to solution

As aside, looking at the (sparse) documentation, if I use the alternative Office 365 Query Profile Action, then I have a configure each one per property.  It works ok tho with what ever email format I have entered for the test user.

0 Kudos
Reply