# Unable to update user's email

**URL:** <https://community.auth0.com/t/unable-to-update-users-email/115906>\
**Category:** Get Help\
**Tags:** user-profile, user-management\
**Created:** [September 11, 2023, 1:07pm UTC](https://community.auth0.com/t/unable-to-update-users-email/115906 "2023-09-11T13:07:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![clement.poissonnier](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/clement.poissonnier/32/50722_2.png) [@clement.poissonnier](https://community.auth0.com/u/clement.poissonnier)\
**Post date:** [September 11, 2023, 1:07pm UTC](https://community.auth0.com/t/unable-to-update-users-email/115906/1 "2023-09-11T13:07:11Z")

</div>

Given a user that looks like this JSON

```json
{
    "created_at": "2023-09-07T09:08:01.738Z",
    "identities": [
        {
            "user_id": "64f992e0506de5e35c294e64",
            "provider": "sms",
            "connection": "sms",
            "isSocial": false
        }
    ],
    "name": "+336XXXXXXXX",
    "nickname": "+336XXXXXXXX",
    "phone_number": "+336XXXXXXXX",
    "phone_verified": true,
    "picture": "https://cdn.auth0.com/avatars/3.png",
    "updated_at": "2023-09-07T09:12:57.778Z",
    "user_id": "sms|64f992e0506de5e35c294e64",
    "user_metadata": {},
    "app_metadata": {},
    "last_ip": "ab87:2121:56c5:b512:1154:66d9:11a4:18fc",
    "last_login": "2023-09-07T09:12:55.951Z",
    "logins_count": 2
}

```

When I try to update the email address with this kind of request :

```bash
curl --location --request PATCH 'https://AUTH0_DOMAIN/api/v2/users/sms|64f992e0506de5e35c294e64' \
--header 'Content-Type: application/json' \
--data-raw '{
  "email": "some.valid.email.address@example.org"
}'

```

I get this error :

```json
{
    "statusCode": 400,
    "error": "Bad Request",
    "message": "Cannot update email for this user",
    "errorCode": "operation_not_supported"
}

```

I understand why updating an email address for a social connection is not ok, but an SMS account should allow it, right?

We need to link some email and SMS accounts (by linking the email account into the SMS one) and we are not able to do it because we cannot keep the email address.

I know that we can put the email address in the metadata, but we’d like to have something that makes sense.

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 11, 2023, 11:20pm UTC](https://community.auth0.com/t/unable-to-update-users-email/115906/3 "2023-09-11T23:20:49Z")

</div>

Hi @clement.poissonnier,

Welcome to the Auth0 Community!

It looks like the user’s profile is a Passwordless SMS user.

In this case, you will not be able to update the user’s email address, as it is not part of their profile.

One workaround to this would be to include it in the user’s metadata. This way, you can still set a `user_metadata.email` for the user.

Thanks,  
Rueben

---

<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:** [September 25, 2023, 11:21pm UTC](https://community.auth0.com/t/unable-to-update-users-email/115906/4 "2023-09-25T23:21:40Z")

</div>

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