# Pass Active Drectory group to JWT as custom claim

**URL:** <https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705>\
**Category:** Get Help\
**Tags:** oidc-enterprise-connection, connections\
**Created:** [July 20, 2023, 5:36pm UTC](https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705 "2023-07-20T17:36:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![v.samodelkin](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/v.samodelkin/32/49088_2.png) [@v.samodelkin](https://community.auth0.com/u/v.samodelkin)\
**Post date:** [July 20, 2023, 5:36pm UTC](https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705/1 "2023-07-20T17:36:16Z")

</div>

I’m trying to pass Active Directory group name to JWT claim. I’ve setup ADFS connection and I see that group name is coming to Auth0  
[This is how it looks like](https://yourimageshare.com/ib/CdkS0ke8vq)  
groupsid is the group name on the screenshot  
How can I access this claim in Actions:

```auto
 api.accessToken.setCustomClaim("MyClaim", event.user.??????);

```

---

<div class="post-metadata">

**Author:** ![ty.frith](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/ty.frith/32/58484_2.png) [@ty.frith](https://community.auth0.com/u/ty.frith)\
**Post date:** [July 20, 2023, 7:03pm UTC](https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705/3 "2023-07-20T19:03:30Z")

</div>

Hey there @v.samodelkin welcome to the community!

Unfortunately, root level user attributes are currently not available through Actions:

> [@Checking Azure AD groups with actions](https://community.auth0.com/t/checking-azure-ad-groups-with-actions/82940/2):
>
> Hi there @adriennel! I apologize for the delayed response here, but I’m combing through our backlog and wanted to be sure and share the following FAQ here: Unfortunately, event.user.groups is not currently accessible via Actions as mentioned in [Actions limitations](https://auth0.com/docs/customize/actions/limitations). It’s acceptable to leave your rule in place to handle this. Stay tuned as I know this is definitely something on our radar!

This is something we are currently working on and expect to be included in a release in the near future - Stay tuned!

---

<div class="post-metadata">

**Author:** ![v.samodelkin](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/v.samodelkin/32/49088_2.png) [@v.samodelkin](https://community.auth0.com/u/v.samodelkin)\
**Post date:** [July 21, 2023, 12:33pm UTC](https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705/4 "2023-07-21T12:33:35Z")

</div>

I managed to send a custom claim using Nickname property. But this is clear misuse.

---

<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 4, 2023, 12:34pm UTC](https://community.auth0.com/t/pass-active-drectory-group-to-jwt-as-custom-claim/111705/5 "2023-08-04T12:34:04Z")

</div>

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