Skip to main content
Version: 5.7.0

ListAllLeaderboards

{
"packetId": 1,
"messages": [
{
"service": "leaderboard",
"operation": "LIST_ALL_LEADERBOARDS",
"data": { }
}
]
}

Method returns list of all the leaderboards from the server based on gameId of the user.

ServiceOperation
leaderboardLIST_ALL_LEADERBOARDS

Usage

http://localhost:3000
// S2S call: to view example, switch to the Cloud Code or Raw tab.
JSON Response
{
"packetId": 1,
"messageResponses": [
{
"status": 200,
"data": {
"leaderboardListCount": 3,
"leaderboardList": [
{
"leaderboardId": "default",
"leaderboardType": "HIGH_VALUE",
"resetAt": 1473793200000,
"rotationType": "WEEKLY",
"currentVersionId": 1,
"maxRetainedCount": 5,
"retainedVersionsCount": 1,
"data": {}
},
{
"leaderboardId": "default1",
"leaderboardType": "HIGH_VALUE",
"resetAt": 1517428800000,
"rotationType": "WEEKLY",
"currentVersionId": 1,
"maxRetainedCount": 2,
"retainedVersionsCount": 1,
"data": {
"retainedCount": 7
}
}
]
}
}
]
}