# Authorization Extension roles & permissions is not syncing with the user profile

**URL:** <https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920>\
**Category:** Get Help\
**Tags:** auth0-authorization, extensions\
**Created:** [July 24, 2023, 9:36am UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920 "2023-07-24T09:36:08Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![AbdYashar07](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@AbdYashar07](https://community.auth0.com/u/AbdYashar07)\
**Post date:** [July 24, 2023, 9:36am UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920/1 "2023-07-24T09:36:08Z")

</div>

I’m using authorization extension to assign my users with roles, permissions as well as groups.

I’m also assigning the user profile to my id token by adding a custom claims to id token.

**api.idToken.setCustomClaim(“user\_profile”,event.user.app\_metadata);**

but when I decode my actual **idToken** it is showing only the groups that the current user linked with but I’ve assigned roles & permissions to the same user along with the groups.

This is how the user profile looks like

![image](https://global.discourse-cdn.com/auth0/original/3X/1/e/1efceed53e5e923a0c9928e662cada22d0568ccc.png)

How do I sync up the authorization extension with the user profile using my idToken whenever the user getting logged-in?

#auth0 #auth0-react #authorization #extension #id-token #user-metadata #app-metadata #login #JWT.io #login #authorization #management-api

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [July 24, 2023, 7:04pm UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920/3 "2023-07-24T19:04:12Z")

</div>

Hi @AbdYashar07,

Welcome to the Auth0 Community!

I have taken a look at your Authorization Extension configuration and it appears that your user hasn’t been assigned any permissions or roles just yet.

To address this, you’ll want to navigate to the _Authorization Extension \> Users \> Your User_ and click on the Roles tab. From there, you can assign the role or roles to the user.

Once you have completed this step, the next time your user logs in, the Groups, Permissions, and Roles will be included in the user’s app\_metadata and set as a custom claim in the ID Token.

If you have any questions or need further assistance, feel free to reach out.

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![AbdYashar07](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@AbdYashar07](https://community.auth0.com/u/AbdYashar07)\
**Post date:** [July 25, 2023, 10:29am UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920/4 "2023-07-25T10:29:23Z")

</div>

Hi @rueben.tiow,

I just saw your comments regarding the authorization extension roles & permissions. I’ve checked all the scenarios you’ve said. Still I got the same issue

Later on, I realized that we’ve to login via the application that we’re giving roles to the app when we’re creating the roles once all done well ultimately we’re getting the roles & permissions to the id token that we’re giving.

Anyway thanks for helping.

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [July 25, 2023, 5:10pm UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920/5 "2023-07-25T17:10:06Z")

</div>

Hi @AbdYashar07,

Thanks for following up.

Ah yes, that is correct. You will need to log in to the respective app that the user was granted the roles and permissions for it to update in the `app_metadata` and add it to the ID token.

I’m glad everything is working now!

Please let us know if there’s anything else we can do to help.

Thanks,  
Rueben

---

<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:** [August 8, 2023, 5:10pm UTC](https://community.auth0.com/t/authorization-extension-roles-permissions-is-not-syncing-with-the-user-profile/111920/6 "2023-08-08T17:10:27Z")

</div>

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