Get SharePoint user ID and profile of an SP site with MS graph api

て烟熏妆下的殇ゞ 提交于 2020-01-06 06:50:24

问题


Is there a way to get user ID inside a SharePoint site with Microsoft Graph API ?

I get a guid id with /me endpoint but in my SP site the current user has id 033.

I know there is a way with SP rest api with currentspcontext. But i want to query with ms graph


回答1:


I believe the Microsoft Graph currently only lets you query SharePoint sites, lists, and list items. Have you tried using the Microsoft Graph to query the User Information list?

Here is a sample of the service call that you need. You'll need to provide your user information list's guid and the Display name of the user. //graph.microsoft.com/v1.0/sites/root/lists/{user info list guid}/items?$select=Fields&$filter=Fields/Title eq 'Alex Wilber'&$expand=Fields



来源:https://stackoverflow.com/questions/47443247/get-sharepoint-user-id-and-profile-of-an-sp-site-with-ms-graph-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!