Customize the token in Azure AD B2C

Mostafa Nagy 1 Reputation point
2022-03-14T06:39:29.187+00:00

I have registered a new web application under Azure Active Directory B2C tenant ..

My target is to customize the access token to include some customize attributes :

At a first try I used below steps to create extension property
https://graph.microsoft.com/v1.0/applications/{APP ID}/extensionProperties

I have switched to use extensionProperties , https://graph.microsoft.com/beta/{App ID}/applications/{B2C object ID}/extensionProperties , But not able to create mapping policy by the created extension ID.

How can we customize the access token ?

I get the (Access/ID)token from:
https://login.microsoftonline.com/{Tenant Id}/oauth2/v2.0/token
scope: https://graph.microsoft.com/.default offline_access openid

Microsoft Security | Microsoft Entra | Microsoft Entra ID
Microsoft Security | Microsoft Graph
{count} votes

1 answer

Sort by: Most helpful
  1. CarlZhao-MSFT 46,376 Reputation points
    2022-03-14T09:29:42.627+00:00

    Hi @Mostafa Nagy

    I see what you mean, but as far as I know there is no way to customize the Azure b2c graph token. I recommend that you open a support ticket for assistance from the Azure b2c product support team.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    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.

Your answer

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