Skip to main content
Version: 5.7.0

PostScoreToGroupLeaderboard

Post the group score to the given group leaderboard. Optional parameters: data.

ServiceOperation
leaderboardPOST_GROUP_SCORE

Method Parameters

ParameterDescription
leaderboardIdThe id of the leaderboard.
groupIdThe id of the group.
scoreThe score to post.
dataOptional user-defined data to post with the score.

Usage

http://localhost:3000
string leaderboardId = "default";
string groupId = "actual_group_id";
int score = 10;
string data = "{\"nickname\":\"batman\"}";
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};

_bc.LeaderboardService.PostScoreToGroupLeaderboard(leaderboardId, groupId, score, data, successCallback, failureCallback);
JSON Response
{
"status": 200,
"data": null
}