Use Access token to save comment on SharePoint news

%3CLINGO-SUB%20id%3D%22lingo-sub-1782958%22%20slang%3D%22en-US%22%3EUse%20Access%20token%20to%20save%20comment%20on%20SharePoint%20news%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1782958%22%20slang%3D%22en-US%22%3E%3CP%3EI%20want%20to%20use%20access%20token%20from%20Graph%20API%20into%20SharePoint%20REST%20API%20to%20save%20comment%20on%20SharePoint%20News%3C%2FP%3E%3CP%3EI%20have%20tried%20to%20get%20the%20access%20token%20using%20Azure%20Active%20Directory%20Sign%20In%20then%20after%20I%20have%20used%20that%20token%20in%20SharePoint%20REST%20API.%20But%20it%20throws%20an%20error%20with%20Status%20Code%20401%3A%20Unauthorized.%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FP%3E%3CP%3ECan%20anyone%20please%20let%20me%20know%20that%20can%20we%20use%20graph%20API%20access%20token%20in%20SharePoint%20REST%20API%3F%3CBR%20%2F%3EIf%20yes%20then%20how%20can%20we%20use%20and%20if%20not%20then%20any%20alternative%20way%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1782958%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAzure%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EGraph%20API%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Highlighted
New Contributor

I want to use access token from Graph API into SharePoint REST API to save comment on SharePoint News

I have tried to get the access token using Azure Active Directory Sign In then after I have used that token in SharePoint REST API. But it throws an error with Status Code 401: Unauthorized.

Can anyone please let me know that can we use graph API access token in SharePoint REST API?
If yes then how can we use and if not then any alternative way?

 

Thanks

0 Replies