web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Unanswered

What is the difference between https://login.microsoftonline.com/common/oauth2/authorize?resource=crmapiurl and https://login.microsoftonline.com/common/oauth2/v2.0/authorize?scope=crmapiurl/user_impersonation?

(0) ShareShare
ReportReport
Posted on by 15

I want to login to access dynamics 365 CRM but the condition is when I login with https://login.microsoftonline.com/common/oauth2/authorize?resource=crmapiurl&client_id&response_type=code&redirect_uri&response_mode=query, I can access the crm but not getting refresh_token when login. I can get access_token & refresh_token if I login with https://login.microsoftonline.com/common/oauth2/v2.0/authorize?scope=crmapiurl/user_impersonation offline_access&client_id&response_type=code&redirect_uri&response_mode=query, but I dont know why I cant access the CRM and getting error 401 Unauthorized. What url should I use to get access_token & refresh_token and the token can use to access the dynamics 365 CRM?

I have the same question (0)
  • Harikrishnan23 Profile Picture
    32 on at
    RE: What is the difference between https://login.microsoftonline.com/common/oauth2/authorize?resource=crmapiurl and https://login.microsoftonline.com/common/oauth2/v2.0/authorize?scope=crmapiurl/user_impersonation?

    The first URL is for the OAuth 2.0 authorize endpoint for Azure Active Directory, with the "resource" parameter set to "crmapiurl". This is used to request an access token for the specified resource.

    The second URL is also for the OAuth 2.0 authorize endpoint for Azure Active Directory, with the "scope" parameter set to "crmapiurl/user_impersonation". This is used to request an access token for the specified scope which allows the application to impersonate the signed-in user when making requests to the "crmapiurl" resource on behalf of the user.

    In summary, the first URL is for the general resource access while the second URL is for user impersonation access to the same resource.

    If I answer your question then please mark it as verified.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Rishabh Kanaskar Profile Picture

Rishabh Kanaskar 258

#2
MVP-Daniyal Khaleel Profile Picture

MVP-Daniyal Khaleel 182

#3
Tom_Gioielli Profile Picture

Tom_Gioielli 125 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans