Retrieve User Information
POST /v2/profile/userinfo
This interface allows the game to obtain detailed information of a specific user.
Request Parameters
For the query parameters for interface calls, see Query Parameters.
| Parameters | Type | Description | Notes |
|---|---|---|---|
| openid | string | Player Network SDK user identification | Required |
| token | string | access token | Required |
Request example
curl -sS -X POST -H 'Content-Type: application/json' 'https://test.intlgame.com/v2/profile/userinfo?channelid=4&gameid=28017&os=1&seq=&source=0&ts=1609863578&sdk_version=2.0&sig=da4486973cd80766fefe824809c025ec' -d '{"openid":"1465825845797363630","token":"e14611f2bf01811bfeac1bce0addfa2ddf32d5aa"}'
Return Parameters
| Parameters | Type | Description |
|---|---|---|
| ret | int | Return code 0: Success Others: Failure |
| msg | string | Detailed information of the result |
| user_name | string | User nickname |
| gender | int | Gender 0: Undefined 1: Male 2: Female |
| birthday | string | Birth date Format: "YYYY-MM-DD" |
| picture_url | string | Avatar URL |
| bind_list | array | Binding relationship list |
The bind_list array contains bound channel accounts, each with the following parameters:
| Parameters | Type | Description |
|---|---|---|
| channelid | int | Channel number |
| user_name | string | Username or Nickname |
| picture_url | string | Avatar URL |
| openid | string | Player Network SDK unique user identifier |
Return Sample
{
"ret": 0,
"msg": "success",
"bind_list": [
{
"channelid": 4,
"user_name": "xxx",
"picture_url": "https://graph.facebook.com/v3.0/2333514436748433/picture?width=160&height=160"
}
],
"user_name": "xxx",
"picture_url": "https://graph.facebook.com/v3.0/2333514436748433/picture?width=160&height=160",
"gender": 0,
"birthday": "",
"seq": "xxxxxxxxxx-xxxxxxxxxx-xxxxxx-xxxxxxxxxx"
}