Skip to main content

Query Friend Request List

Queries information on players with pending friend requests.

Call Information

FriendReady(String friendCode, PlayNANOODelegate callback) {}

Call Information Details

ParameterDescriptionType
friendCodeFriend table identification codestring
callbackCommunication resultPlayNANOODelegate

Source Code

using PlayNANOO;

public class PlayNANOOExample : MonoBehaviour
{
Plugin plugin;

void Awake()
{
plugin = Plugin.GetInstance();

string friendCode = "string";
plugin.FriendReady(friendCode, (state, message, rawData, dictionary) => {
if(state.Equals(Configure.PN_API_STATE_SUCCESS)) {
foreach (Dictionary<string, object> value in (ArrayList)dictionary["friends"])
{
Debug.Log(value["relationship_code"]);
Debug.Log(value["uuid"]);
Debug.Log(value["nickname"]);
Debug.Log(value["access_timezone"]);
Debug.Log(value["access_diff"]);
Debug.Log(value["access_timestamp"]);
}
} else {
Debug.Log("Fail");
}
});
}
}

Communication Result

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
{
"code" : 200,
"message" : 0,
"value" : [
{
"relationship_code" : "String"
"uuid" : "String",
"nickname" : "String",
"access_timezone" : "String",
"access_diff" : "Integer",
"access_timestamp" : "Integer"
}
]
}

Communication Result

Data KeyDescriptionType
relationship_codeFriend relationship identification codestring
uuidPlayer's unique IDstring
nicknamePlayer's nicknamestring
access_timezonePlayer's access timezonestring
access_diffTime elapsed in seconds since last logininteger
access_timestampPlayer's last login Unix Timestampinteger