# Stop Nickname and Picture Claims Being Displayed In Id Token

**URL:** <https://community.auth0.com/t/stop-nickname-and-picture-claims-being-displayed-in-id-token/109782>\
**Category:** Get Help\
**Tags:** users, management-api\
**Created:** [June 22, 2023, 3:52pm UTC](https://community.auth0.com/t/stop-nickname-and-picture-claims-being-displayed-in-id-token/109782 "2023-06-22T15:52:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![richard.sanigar](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/richard.sanigar/32/23147_2.png) [@richard.sanigar](https://community.auth0.com/u/richard.sanigar)\
**Post date:** [June 22, 2023, 3:52pm UTC](https://community.auth0.com/t/stop-nickname-and-picture-claims-being-displayed-in-id-token/109782/1 "2023-06-22T15:52:13Z")

</div>

Hi Auth0 Community

We’re using a custom database script to return user information.

We have created an api and added relevant permissions

When we are calling the /authorize endpoint, we are including the following scopes:

openid, profile, read:customer, update:customer in the scope query parameter and setting the audience query parameter to the audience value of the api.

The fact I have added the profile scope will give me access to name, nickname and picture in the ID token. If the JSON I return to Auth0, from the custom database script, has nickname and picture as blank or null, Auth0 is setting the nickname to the value of name and creating an picture based on the first characters of the firstname and lastname in the name field.

I only want to display the name attribute. Is this possible?

(I appreciate I could add a field to the app\_metadata add create a custom claim with a namespace, using an action script in the Login flow to add the custom claim to the ID Token)

---

<div class="post-metadata">

**Author:** ![richard.sanigar](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/richard.sanigar/32/23147_2.png) [@richard.sanigar](https://community.auth0.com/u/richard.sanigar)\
**Post date:** [June 22, 2023, 4:09pm UTC](https://community.auth0.com/t/stop-nickname-and-picture-claims-being-displayed-in-id-token/109782/2 "2023-06-22T16:09:56Z")

</div>

Hi

I’ve found a solution/work around

I’ve created a rule based on the **Remove attributes from user** template, so now the nickname and picture claims are removed from the ID token (Yes I know rules are being deprecated 😁)

Regards

Richard

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [July 6, 2023, 4:09pm UTC](https://community.auth0.com/t/stop-nickname-and-picture-claims-being-displayed-in-id-token/109782/3 "2023-07-06T16:09:59Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
