# Access token has two audiences?

**URL:** <https://community.auth0.com/t/access-token-has-two-audiences/71041>\
**Category:** Get Help\
**Created:** [October 8, 2021, 10:07pm UTC](https://community.auth0.com/t/access-token-has-two-audiences/71041 "2021-10-08T22:07:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![woeterman94](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/woeterman94/32/19316_2.png) [@woeterman94](https://community.auth0.com/u/woeterman94)\
**Post date:** [October 8, 2021, 10:07pm UTC](https://community.auth0.com/t/access-token-has-two-audiences/71041/1 "2021-10-08T22:07:15Z")

</div>

How to get rid of multiple audiences?  
[This](https://community.auth0.com/t/how-do-i-specify-multiple-audiences/10830) page says it is not supported

But somehow my token has an array of two audiences.

![image](https://global.discourse-cdn.com/auth0/original/3X/4/8/485d8d427ff7076fba5e477512ccb1ddce1dff3b.png)

My .NET 5 application is failing because of this.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/4/a/4a82935c740bef97aeccade37efce51c446cb07c.png)

 ![image](https://global.discourse-cdn.com/auth0/original/3X/d/4/d426ca64f75e07fca0ff5ed93b9372f92da113f0.png)

How can I make sure my token only contains one audience?

---

<div class="post-metadata">

**Author:** ![woeterman94](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/woeterman94/32/19316_2.png) [@woeterman94](https://community.auth0.com/u/woeterman94)\
**Post date:** [October 8, 2021, 10:10pm UTC](https://community.auth0.com/t/access-token-has-two-audiences/71041/2 "2021-10-08T22:10:14Z")

</div>

Btw I’m using angular and the oidc-client package for authentication in my front-end.  
I’m passing in my audience like this

 ![image](https://global.discourse-cdn.com/auth0/original/3X/c/f/cfefd8e86761fb27ad81dfade71bd7fc8c87cd66.png)

Because [it says](https://community.auth0.com/t/why-is-it-necessary-to-pass-the-audience-parameter-to-receive-a-jwt/11412) I have to pass an audience in to retrieve my token in JWT format.

---

<div class="post-metadata">

**Author:** ![Ale](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/ale/32/50860_2.png) [@Ale](https://community.auth0.com/u/Ale)\
**Post date:** [October 8, 2021, 11:54pm UTC](https://community.auth0.com/t/access-token-has-two-audiences/71041/3 "2021-10-08T23:54:36Z")

</div>

Hey @woeterman94 ,

You cannot remove the `/userinfo` audience. It is included by default for all issued Access Tokens.

If you specify an audience of your custom API identifier and a scope of **openid** , then the resulting access token’s `aud` claim will be an array rather than a string, and the access token will be valid for both your custom API and for the `/userinfo` endpoint. Other than in the use case of a single custom API as well as Auth0’s `/userinfo` endpoint, your access tokens will be unable to have two or more audiences.

I am not familiar with your application, but it seems like it is parsing the audience incorrectly. That’s what you should focus on.

More information about this topic can be read here: [Get Access Tokens](https://auth0.com/docs/security/tokens/access-tokens/get-access-tokens)

---

<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 23, 2023, 12:34am UTC](https://community.auth0.com/t/access-token-has-two-audiences/71041/4 "2023-03-23T00:34:55Z")

</div>

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