The updateUser() method updates attributes for a user that has already been identified with usertour.identify() since the last page load.

Parameters

attributes
object

User attributes to update. See Attributes for details. These attributes can be used in flow content and conditions to personalize the user experience.

Returns

A Promise that resolves when the update is complete.

Example

// Update user attributes
usertour.updateUser({
  last_login: '2024-03-20T08:30:00.000Z',
  subscription_tier: 'premium'
});

Notes

  • This method only works for users identified with usertour.identify()
  • Attributes are merged with existing values
  • Does not affect the user’s identification status
  • Can be called multiple times to update different attributes