App Only https://accounts.accesscontrol.windows.net/id/tokens/OAuth/2 with Rest

g h 716 Reputation points
2020-11-20T07:59:39.197+00:00

I want to call Rest API using App Only Credential.

I have create a app in AppRegNew.aspx and add into this request header:

https://accounts.accesscontrol.windows.net/id/tokens/OAuth/2

However, This id I don't know how to get, is this the SharePoint site Id ?

Can any one help me please ?

Microsoft 365 and Office | SharePoint Server | Development
0 comments No comments
{count} votes

Answer accepted by question author
  1. ZhengyuGuo 10,591 Reputation points Moderator
    2020-11-23T02:06:58.273+00:00

    Hi @g h ,

    This is Tenant Id.

    Please open browser window in Private mode, and type your SharePoint Online site like this:

    https://Tenantname.sharepoint.com

    In Browser address bar, there is the Tenant Id:

    41706-snipaste-2020-11-23-10-04-55.png


    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.