getBindChannelsByUid
The getBindChannelsByUid API is used to get the list of linked channels from the login information of the current channel. For example, get the list of linked channels based on Facebook authentication information.
Request Parameter
| Parameter | Type | Description | Remark |
|---|---|---|---|
| channel_id | number | Player Network SDK authorized channel ID For more information, see Login Channel and ChannelID Relationship. | 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 Parameter
| Parameter | Type | Description |
|---|---|---|
| ret | number | Return code 0: Request success !=0: Request failure, see msg for detailed return message |
| msg | string | Return message |
| bind_list | array | List of linked channels |
| seq | string | Sequence number of the message in the data stream |
bind_list
| Parameter | Type | Description |
|---|---|---|
| channel_info | object | Channel information of the linked channel. For more information, see Channel Information. |
| channelid | number | Channel ID of the linked channel. For more information, see Login Channel and ChannelID Relationship. |
| picture_url | string | URL of the avatar |
| user_name | string | User name of the linked channel |
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",
}