Azure b2c - refresh token does not include custom claims

Sandeep Sagar 0 Reputation points
2024-07-03T01:10:22.43+00:00

When a user logs in, I hit a REST API that verifies the username and password and returns some properties like personId, comUsername, wcfToken, and organizationCode. These properties are then returned to the user as an access token.

This is how my Access token looks like on the initial login

enter image description here

but when I refresh token

const tokenRequest = {
  scopes: scopes,
  account: msalInstance.getActiveAccount(),
  forceRefresh: true,
} as SilentRequest;
console.log(await msalInstance.acquireTokenSilent(tokenRequest));

enter image description here

Why am I not receiving the expected claims? I heard something about persisted claims, but I'm not sure where exactly I have to write that code.

Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
6,131 questions
0 comments No comments
{count} votes