question

WataruUmeda-8571 avatar image
0 Votes"
WataruUmeda-8571 asked ·

How to get an access token using b2clogin.com instead of using login.microsoftonline.com without user authentication?

I use Microsoft Graph API to manage Azure AD B2C users.

In order to get access without user authentication, I use the following API to get an access token.

 https://login.microsoftonline.com/<my-tenant-id>/oauth2/v2.0/token
 grant_type=client_credentials
 scope=https://graph.microsoft.com/.default
 client_id=<my-client-id>
 client_secret=<my-client-secret>

I found that login.microsoftonline.com was deprecated as described in the article below.

https://azure.microsoft.com/en-us/updates/b2c-deprecate-msol/

I should use b2clogin.com, but I still use login.microsoftonline.com.
I couldn't find any documentation on how to get an access token using b2clogin.com instead of using login.microsoftonline.com without user authentication.

Where is the documentation?

Or can I use login.microsoftonline.com to get an access token without user authentication?

Thank you.






azure-ad-b2c
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

amanpreetsingh-msft avatar image
0 Votes"
amanpreetsingh-msft answered ·

Hi @WataruUmeda-8571,


I see that you are using client_credentials flow. This flow is not yet supported with b2clogin.com.


You can vote for it and view the status here: https://feedback.azure.com/forums/169401-azure-active-directory/suggestions/18431254-b2c-support-for-client-credential-flow.




Please do not forget to "Accept the answer" wherever the information provided helps you. This will help others in the community as well.


· 3 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @amanpreetsingh-msft


Thank you for your reply.


I confirmed the link you shared. It says:


This is not planned for the next 6 months, but is on the roadmap.


Do you know if b2clogin.com will be supported by December 4th, 2020 when login.microsoftonline.com will be deprecated?


Thank you


0 Votes 0 ·

@WataruUmeda-8571 login.microsoftonline.com will be deprecated only for the application federation with B2C. It will still be available to access Standard Azure AD functionality of the B2C directory. An update should be posted at the feedback link after 6 months regarding support for client_credentials flow. As of now there is no timeline defined for this feature.

1 Vote 1 ·

@amanpreetsingh-msft I understand. Thank you.


0 Votes 0 ·