User Object
This document explains the user object.
See the example of the user object.
id
type | description |
---|---|
string | The id of a user. |
memberId
To create a member user, you have to use
memberId
.
type | description |
---|---|
string | The id used for identifying a member user. If you set memberId in the boot option, the user is regarded as a member user. |
name
type | description |
---|---|
string | undefined | The name of a user. Set by updateUser. |
avatarUrl
type | description |
---|---|
string | The avatar image URL of a user. |
alert
type | description |
---|---|
number | The number of messages the user has not yet read. |
profile
type | description |
---|---|
object | undefined | A user’s profile information. Set by updateUser or profile of boot option. |
onFollowUpChanged registers a callback invoked when the user changes his profile.
unsubscribeEmail
type | description |
---|---|
boolean | Whether to unsubscribe the marketing email. Set by updateUser or unsubscribeEmail of boot option. |
unsubscribeTexting
type | description |
---|---|
boolean | Whether to unsubscribe the marketing email. Set by updateUser or unsubscribeTexting of boot option. |
tags
type | description |
---|---|
string[] | The tags of a user. Always lowercase. Set by updateUser, addTags, and removeTags. |
language
type | description |
---|---|
string | The language of a user. Used for translation. Set by updateUser and language of boot option. Following 32 languages supported. : 'de'(German), 'hi'(Hindi), 'no'(Norwegian), 'ru'(Russian), 'fi'(Finnish), 'pt'(Portuguese), 'hr'(Croatian), 'fr'(French), 'hu'(Hungarian), 'uk'(Ukrainian), 'sk'(Slovak), 'ca'(Catalan), 'sv'(Swedish), 'ko'(Korean), 'id'(Indonesian), 'ms'(Malay), 'el'(Greek), 'en'(English), 'it'(Italian), 'es'(Spanish), 'he'(Hebrew), 'zh'(Chinese), 'cs'(Czech), 'ar'(Arabic), 'vi'(Vietnamese),'th'(Thai), 'ja'(Japanese), 'pl'(Polish), 'ro'(Romanian), 'da'(Danish), 'nl'(Dutch), 'tr'(Turkish) |
Example
{
"id": "USER_ID",
"memberId": "MEMBER_ID",
"name": "USER_NAME",
"avatarUrl": "AVATAR_URL",
"alert": 0,
"profile": {
"name": "USER_NAME",
"email": "USER_EMAIL",
"mobileNumber": "+821012345678",
"CUSTOM_VALUE_1": "VALUE_1",
"CUSTOM_VALUE_2": "VALUE_2"
},
"unsubscribeEmail": true,
"unsubscribeTexting": true,
"tags": ["TAG_1", "TAG_2"],
"language": "ko"
}
Updated 4 months ago