getPublicProfile
Note
Please contact Zalopay Team to be granted permission to use this functionality.Mô tả
To get public user profile. Please contact Zalopay Team.
Parameters
Param | Data type | Required | Description |
---|---|---|---|
appId | number | Yes | payment Id |
Return Value
Param | Data type | Description |
---|---|---|
userId | string | merchant user id (unique) |
userName | string | user name |
userAvatar | string | user avatar |
Error Code
Error Code | Description |
---|---|
030702 | getPublicProfile: Invalid Argument |
030703 | getPublicProfile: System Error |
030704 | getPublicProfile: Unauthenticated |
Sample Code and Sample Return Data
Sample Request:
window.zlpSdk.User.getPublicProfile({
appId: 999,
})
.then((response) => console.log(response))
.catch((error) => console.error(error.errorCode));
Sample Response:
{
"data": {
"userId": "YSgQtcUuBUyRhEPdE8slAIZfpaAM90oeKdcT_0o6QZQ",
"userName": "display name",
"userAvatar": "avatar"
},
"status": "success"
}