Set user login status information and configuration information (SetUserProfile)
The setUserProfile API is used to set the user's login information and configuration settings.Please call the setUserProfile API before invoking other compliance APIs.
Request parameters
| Parameters | Type | Description |
|---|---|---|
| gameID | Number | Game ID available in iTOP/MSDKV5/Player Network SDK configurations |
| openID | string | Player Network SDK unique user identifier Defaults to a 64-bit unsigned integer string, but can also support 32-bit. |
| token | string | User token generated by Player Network SDK length:40 bytes, see Token for details |
| channelID | number | Login channel ID See Channel ID explanation |
| region | string | Numeric codes of countries or regions as per ISO 3166-1 For example, 156 represents China, and 040 represents Austria. |
Request sample
complianceApi.setUserProfile(
{
gameID: 11,
openID: "xxx",
token: "xxx",
channelID: 52,
region: "156",
},
(res) => {
console.log(res);
}
);
Response parameters
| Parameters | Type | Description |
|---|---|---|
| ret | Number | Return code 0: Request successful !=0: Request failed, refer to msg for detailed results |
| msg | string | Result Explanation |
Response sample
{
msg: "success",
ret: 0
}