Created
March 16, 2020 10:40
-
-
Save ktskumar/06402a7c274e2884f04483bd458fd51d to your computer and use it in GitHub Desktop.
Get Grah User using SharePoint RRST API
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//getRequest method reference | |
//https://gist.github.com/ktskumar/a9e9df497673e9fd26ead8532b9ff425 | |
//Returns the profile and ms graph related user information | |
getRequest("https://domain.sharepoint.com/sites/webname/_api/SP.Directory.DirectorySession/GetGraphUser(principalName='[email protected]')") | |
.then(function(output){ | |
console.log(JSON.parse(output.response)); | |
}); | |
//Returned Properties | |
//aboutMe, alias, birthday, displayName, hireDate, id, Interests, mail, mySite, pastProjects, | |
//pointPulishingPersonalSiteUrl, preferredName, principalName, responsibilities, schoools, skilss, tags |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment