Get the Bind List (getBindChannelsByUid)
The getBindChannelsByUid API is used to obtain a list of bound channels from the current channel's login information.For example, obtain a list of bound channels based on the authentication information from Facebook.
Request parameters
| Parameters | Type | Description | Note |
|---|---|---|---|
| channel_id | number | Player Network SDK-authorized channel ID For more information, see Login Channels and Channel ID Relationships. | Required |
| channel_info | object | Channel information of the current channel. For more information, see Channel Information. | Required |
Request sample
accountApi.getBindChannelsByUid({
channel_id: 4,
channel_info: {
access_token: "EAAI2lTrXAZBwBAEWdBW...LUdVblu9qPwZDZD"
}
}).then(
(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 |
| bind_list | array | Binding List |
| seq | string | Data Stream Message Serial Number |
bind_list
| Parameters | Type | Description |
|---|---|---|
| channel_info | object | Channel information for the bound channel. For more information, see Channel Information. |
| channelid | number | The channel ID of the bound channel. For more information, see Relationship Between Login Channels and Channel IDs. |
| picture_url | string | Profile picture link |
| user_name | string | Binding channel's username |
Response sample
{
ret: 0,
msg: "success",
bind_list: [
{
channel_info: {},
channelid: 28,
is_primary: 0,
picture_url: "https://www.google.com/Images/profileA.png",
user_name: "user"
},
{
channel_info: {},
channelid: 4,
is_primary: 0,
picture_url: "https://www.google.com/Images/profileB.png",
user_name: "user"
}
],
seq: "1639105985-1191493130-031434-0000571640",
}