# Updating User Profile from Actions

**URL:** <https://community.auth0.com/t/updating-user-profile-from-actions/85206>\
**Category:** Get Help\
**Created:** [June 16, 2022, 1:47am UTC](https://community.auth0.com/t/updating-user-profile-from-actions/85206 "2022-06-16T01:47:05Z")\
**Posts on this page:** 1\
**Showing post:** 3

<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:** [June 16, 2022, 6:16pm UTC](https://community.auth0.com/t/updating-user-profile-from-actions/85206/3 "2022-06-16T18:16:52Z")

</div>

Hi @igelu,

Welcome to the Auth0 Community!

I understand you have questions about updating the user’s profile `family_name` and `given_name` properties using Actions.

In this situation, I recommend [using the Management API in Actions](https://community.auth0.com/t/how-can-i-use-the-management-api-in-actions/64947) to call the [updateUser()](https://auth0.github.io/node-auth0/ManagementClient.html#updateUser) method and passing the `family_name` and `given_name` properties to be updated in the user profile. I have attached the corresponding code snippet below:

```auto
exports.onExecutePostLogin = async (event, api) => {

  const ManagementClient = require('auth0').ManagementClient;

  const management = new ManagementClient({
      domain: event.secrets.domain,
      clientId: event.secrets.clientId,
      clientSecret: event.secrets.clientSecret
  });

  const params = { id: event.user.user_id};

  const data = {
    "family_name" : "kenobi",
    "given_name" : "obiwan"
  }

  try {
    const res = await management.updateUser(params, data) 
  } catch (e) {
    console.log(e)
    // Handle error
  }
};

```

Moreover, I have tested this Action script and confirm that it will update the user’s `family_name` and `given_name` properties on their user profile.

I hope this helps!

Please let me know if there is anything else I can do to help.

Thank you.

---

_[View the full topic](https://community.auth0.com/t/updating-user-profile-from-actions/85206)._
