# Add user's email to accessToken using m2m login

**URL:** <https://community.auth0.com/t/add-users-email-to-accesstoken-using-m2m-login/90428>\
**Category:** Get Help\
**Tags:** email, token, hooks, login, auth0, machine-to-machine\
**Created:** [September 12, 2022, 12:29pm UTC](https://community.auth0.com/t/add-users-email-to-accesstoken-using-m2m-login/90428 "2022-09-12T12:29:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![barriaandradedaniel](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/barriaandradedaniel/32/33719_2.png) [@barriaandradedaniel](https://community.auth0.com/u/barriaandradedaniel)\
**Post date:** [September 12, 2022, 12:29pm UTC](https://community.auth0.com/t/add-users-email-to-accesstoken-using-m2m-login/90428/1 "2022-09-12T12:29:06Z")

</div>

Hi, im trying to insert the email into de accessToken. I’m using a m2m application.

I created a Client Credentials exchange hooks, but in the base script I can’t see a params that actually add the user’s email.

Please if someone can help me

Thank u

---

<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:** [September 21, 2022, 12:49am UTC](https://community.auth0.com/t/add-users-email-to-accesstoken-using-m2m-login/90428/3 "2022-09-21T00:49:07Z")

</div>

Hi there @barriaandradedaniel sorry for the delayed response, but welcome to the community!

> [@barriaandradedaniel](#):
>
> Hi, im trying to insert the email into de accessToken. I’m using a m2m application.

Given that this is an [m2m communication](https://auth0.com/blog/using-m2m-authorization/) (client credentials), there isn’t any user involved and therefore no email. You’ll want to look into using a different authentication/authorization flow and application type - These are outlined here:

> **[Applications in Auth0](https://auth0.com/docs/get-started/applications)**
>
> Learn the basics of registering and configuring your applications in Auth0.

Our documentation on common architecture scenarios could be helpful as well:

> **[Architecture Scenarios](https://auth0.com/docs/get-started/architecture-scenarios)**
>
> Learn about common Auth0 architecture scenarios that you can use to solve your authorization and authentication needs.

Hope this helps!

---

<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:** [October 5, 2022, 12:50am UTC](https://community.auth0.com/t/add-users-email-to-accesstoken-using-m2m-login/90428/4 "2022-10-05T00:50:02Z")

</div>

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