- Print
API - Common
- Print
AccessKey Setting
Set the issued Access Key.
User Authentication
Simple Authentication
ShopLiveCommon.setUser(user: ShopLiveCommonUser)
ShopLiveCommon.setUser(user: ShopLiveCommonUser, accessKey:String?)
Store user information. Please refer to the User Authentication Guide for details
When user information is saved, a userJWT is automatically created and stored using the userβs information.
ShopLiveCommon.setuser(user : ShopLiveCommonUser,accessKey:String?)
ShopLiveCommonUser
field
type
description
userId
String
User ID
name
String?
User Name
(Used in the chat window)
age
Int?
User age
gender
ShopliveCommonUserGender
User gender
userScore
Int?
User rating
custom
[String: Any]
Custom data
In the Objective-C environment, please use the ShopLiveCommonUserObjc object.
JWT Authentication
ShopLiveCommon.setAuthToken(authToken : String)
Authenticate ShopLive JWT.
Clear Authentication Information
Reset the configured authentication information.
Logged-in Check
Determine if JWT login has occurred.
Set Utm Tag
ShopLiveCommon.setUtmSource(utmSource: String)
ShopLiveCommon.setUtmMedium(utmMedium: String)
ShopLiveCommon.setUtmCampaign(utmCampaign: String)
ShopLiveCommon.setUtmContent(utmContent: String)
You can track UTM Source/Medium/Campaign/Content. The data can be reviewed in the Data Insights.
field | type | description |
---|---|---|
utmSource | String? | It provides information on where the incoming traffic originated. |
utmMedium | String? | It conveys how the incoming traffic was generated. Google recommends setting the medium parameter to denote the marketing method through which the traffic was induced, such as CPC, banner, email, blog, social, etc. |
utmCampaign | String? | It communicates which advertising campaign the incoming traffic originated from. This can be divided into Campaign Name, Term, and Content. |
utmContent | String? | It informs about the posting/advertisement that led to the incoming traffic, often utilized as a subcategory under the campaign parameter. |
Sample code