How to use InboundClaimTypeMap for claim mapping?
<p>I have similar problem as here : <a href="https://github.com/IdentityServer/IdentityServer3.Samples/issues/9" rel="nofollow noreferrer">https://github.com/IdentityServer/IdentityServer3.Samples/issues/9</a></p>

<p>But solution is not helpful for me.</p>

<p>So lets explain in more details with pictures and code:</p>

<p><strong>I have this on client:</strong></p>

<p><a href="https://i.stack.imgur.com/rZP04.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rZP04.jpg" alt="enter image description here"></a></p>

<p>No need to map because NameClaimType(RoleClaimType) and Claim in list of claims are same</p>

<pre><code>JwtSecurityTokenHandler.InboundClaimTypeMap.Clear();
</code></pre>

<p><strong>On Api project I have:</strong></p>

<p><a href="https://i.stack.imgur.com/PaW2S.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PaW2S.jpg" alt="enter image description here"></a></p>

<p>In this case (if I understand correctly), I have to to map, because NameClaimType &amp; RoleClaimType are not same with claim values. </p>

<pre><code>    JwtSecurityTokenHandler.InboundClaimTypeMap = new Dictionary&lt;string, string&gt;
    {
        {"role", System.Security.Claims.ClaimTypes.Role},
        {"name",System.Security.Claims.ClaimTypes.Name }
    };
</code></pre>

<p>But still not working. What am I doing wrong?</p>