I need to call the GRAPH API on a SharePoint Online page. Can anyone share an example JavaScript? The examples available on the GRAPH site are designed to invoke the GRAPH API from outside SharePoint Online.
I know that each request requires a token, and you must log in to get this token. However, if I call the GRAPH API from SharePoint Online, it means that I have already authenticated, so again it makes no sense to log in. The token must be available somewhere, and I don’t know how to get it (it is not available in the SharePoint URL).
source
share