# Help - Azure AD OpenID Enterprise connection customized with Web Application in React

**URL:** <https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172>\
**Category:** Get Help\
**Tags:** configuration, application\
**Created:** [February 14, 2025, 1:30pm UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172 "2025-02-14T13:30:26Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![thiago.mouro](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/thiago.mouro/32/72792_2.png) [@thiago.mouro](https://community.auth0.com/u/thiago.mouro)\
**Post date:** [February 14, 2025, 1:30pm UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172/1 "2025-02-14T13:30:26Z")

</div>

I’m supporting a coworker where we integrated AUTH0 with the company’s Azure AD, using a custom openID.  
It is authenticating correctly, in the user’s attribute profile there is an attribute that comes from their Azure called role, when you go to the Users Menu in RAW JSON in their user the role attribute appears.

1- We need to know how we make the application react for it to appear, in scopes we have already placed roles there, we have also created a post login action forcing this without success.

2- The Access token returned after authenticating with its application seems like the access token is missing a part and cannot be decoded in JWT IO SITE, how do I make the access token appear complete?

3- the last question is that he created an api for his application in AUTH0 and when he tests it locally with this same token from question 2 it is unauthorized, because I understand that the token is not complete and because of this it gives an error.

Can anyone help please?

---

<div class="post-metadata">

**Author:** ![thiago.mouro](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/thiago.mouro/32/72792_2.png) [@thiago.mouro](https://community.auth0.com/u/thiago.mouro)\
**Post date:** [February 14, 2025, 1:32pm UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172/2 "2025-02-14T13:32:58Z")

</div>

To complement question 1, we need to make a user attribute that comes from Azure AD and is already listed in USERS, in the raw json appear within its react application.

ex: name: eduardo  
email: [eduardo.teste@empresa.com](mailto:eduardo.teste@empresa.com)  
role: readonly

---

<div class="post-metadata">

**Author:** ![thiago.mouro](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/thiago.mouro/32/72792_2.png) [@thiago.mouro](https://community.auth0.com/u/thiago.mouro)\
**Post date:** [February 14, 2025, 3:25pm UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172/3 "2025-02-14T15:25:23Z")

</div>

I can solve almot all questions.

Right now, my problem is about access token, it was incomplete.

1. I need to see complete access token in response for use em jwt io site.
2. I created a machine to machine api for my application and not being able to use my app’s access token for it, it is not authorized, I believe the two errors are linked.

---

<div class="post-metadata">

**Author:** ![nik.baleca](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nik.baleca/32/68749_2.png) [@nik.baleca](https://community.auth0.com/u/nik.baleca)\
**Post date:** [February 15, 2025, 12:08am UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172/5 "2025-02-15T00:08:54Z")

</div>

Hi @thiago.mouro

Welcome to the Auth0 Community!

Just to be sure that I am on track with your issue, regarding the integration with Azure AD, did you follow the steps provided in our [documentation](https://auth0.com/docs/authenticate/identity-providers/enterprise-identity-providers/azure-active-directory/v2)?

What do you mean that your access token is incomplete? Are you missing anything inside it specifically or is it malformed? Could you post the contents of a token in order for me to examine it?

Regarding your Machine to Machine application, did you approve the necessary permissions and do you have the necessary audience when you make the calls?  
You can review our [documentation](https://auth0.com/docs/get-started/auth0-overview/create-applications/machine-to-machine-apps) and this [blog post](https://auth0.com/blog/using-m2m-authorization/) regarding M2M authorization and registering M2M applications.

If you have any other questions or still require further assistance, please let me know!

Kind Regards,  
Nik

---

<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:** [March 1, 2025, 12:09am UTC](https://community.auth0.com/t/help-azure-ad-openid-enterprise-connection-customized-with-web-application-in-react/182172/6 "2025-03-01T00:09:22Z")

</div>

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