# Account linking through Actions

**URL:** <https://community.auth0.com/t/account-linking-through-actions/68940>\
**Category:** Get Help\
**Tags:** actions\
**Created:** [September 1, 2021, 3:33pm UTC](https://community.auth0.com/t/account-linking-through-actions/68940 "2021-09-01T15:33:48Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![praveen.addepally](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/praveen.addepally/32/14314_2.png) [@praveen.addepally](https://community.auth0.com/u/praveen.addepally)\
**Post date:** [September 5, 2021, 4:59am UTC](https://community.auth0.com/t/account-linking-through-actions/68940/2 "2021-09-05T04:59:30Z")

</div>

Hello,  
It is important to set the **event.user** object to the primary user after the accounts have been linked in the action. Doing this should return the github user\_id as a sub claim in the id\_token/access token you receive to your application.

Below is a similar post that could be helpful.

> [@Account linking with Auth0 actions](https://community.auth0.com/t/account-linking-with-auth0-actions/60676/2):
>
> Thank you for sharing your solution with the Community @alexab! Quoting your solution here for others to see! slight_smile :

Let us know how it goes!

---

_[View the full topic](https://community.auth0.com/t/account-linking-through-actions/68940)._
