Get Binding 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 Relationship. | Mandatory |
| channel_info | object | Channel information for 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 sequence number |
bind_list
| Parameters | Type | Description |
|---|---|---|
| channel_info | object | Binding channel's channel information. For more information, see Channel Information. |
| channelid | number | Bound channel's channel ID. For more information, see Login Channels and Channel ID Relationship. |
| picture_url | string | Profile picture link |
| user_name | string | Binding channel's username |
Return 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",
}