Dynamic Widget UI component/Dynamic Embedded Widget UI component described above.
Setup
Show the user’s profile based on whether they are logged in or not
How: Check if the user is logged in or not Hook/Component:useIsLoggedIn
Notes: We start here assuming you have signup/login implemented already
Profile Info
Show user profile information
How: Fetch info from user object on useDynamicContext Hook/Component:useDynamicContext
Notes: The format of the user can be found here: userProfile. For working with custom metadata fields and storing additional user data, see User Metadata.
Allow user to update their profile information
How:client.auth.updateUser and client.auth.verifyUserUpdateOtp
Method: client.auth.updateUser
Notes: updateUser returns flags to indicate whether OTP is required for the change (isEmailVerificationRequired and isSmsVerificationRequired). Available from v4.38.0.
Updating Email
React Native
Updating Phone
React Native
Updating Meta
React Native
Updating General
React Native
React Native
Socials
Show users linked social accounts, allow linking/unlinking
How: useSocialAccounts hook from sdk-react-core Hook/Component:useSocialAccounts
Notes: None
Working with User Metadata
User metadata provides a powerful way to store additional information beyond the standard profile fields. This is perfect for storing user preferences, application state, custom attributes, and integration data.What is Metadata?
Metadata is a flexible key-value storage system that allows you to:- Store user preferences (theme, language, notification settings)
- Track application state (onboarding progress, feature flags)
- Store business-specific data (subscription tiers, referral codes)
- Maintain integration data (external service IDs, webhook configs)
Metadata Examples
Best Practices
- Size limit: Metadata is limited to 2KB total
- Key naming: Use descriptive, lowercase keys with underscores
- Value types: Supports strings, numbers, booleans, and nested objects
- Validation: Always validate on your backend before storing
- Updated the “Allow user to update their profile information” section with distinct “Updating Email”, “Updating Phone”, “Updating Meta”, and “Updating General” subsections for both React and React Native, and used
isSmsVerificationRequiredfor phone updates.