❔ Claim type of JwtRegisteredClaimNames.Name unrecognized as ClaimTypes.Name
Hello,
I'm working with an API that returns a token with below structure:
and using this:
When I try to access this.UserName = user.Identity.Name; it is always null. Am I doing something wrong here or is there a explicit conversion required?
2 Replies
I recommend using the debugger to see if the values you're expecting are getting populated.
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.