For AI agents: Find a documentation index at https://talkjs.com/llms.txt (full content at https://talkjs.com/llms-full.txt). Get a markdown version of any page by appending .md to its URL path.
UserData (legacy)
Legacy name for UserSnapshot in the React Native SDK.
A snapshot of a user's attributes at a given moment in time.
Users also have private information, such as email addresses and phone numbers, but these are only exposed on the REST API.
{
"id": "650d5ed0cae49",
"name": "Alice",
"welcomeMessage": null,
"photoUrl": null,
"role": "default",
"custom": {},
"availabilityText": null,
"locale": null,
}| Name | Type | Description |
|---|---|---|
| id | string | The unique ID which is used to identify the user in TalkJS |
| name | string | The user's name which will be displayed on the TalkJS UI |
| photoUrl | string | null | An optional URL to a photo which will be displayed as the user's avatar |
| welcomeMessage | string | null | The default message a user sees when starting a chat with that person |
| role | string | TalkJS supports multiple sets of settings, called "roles". Roles allow you to change the behavior of TalkJS for different users. You have full control over which user gets which configuration. |
| custom | CustomData | Custom metadata you have set on the user |
| locale | string | null | The locale field expects an IETF language tag. See the localization documentation. When locale is null, the app's default locale will be used |