Skip to main content
Version: 5.7.0

JoinDivision

Similar to JoinTournament, except that you specify the division set id instead of the leaderboard id.

Returns the division instance id (i.e. leaderboardId) upon success. If joining the tournament requires a fee, it is possible to fail (if the user doesn't have enough currency).

ServiceOperation
tournamentJOIN_DIVISION

Method Parameters

Method Parameters

ParameterDescription
divSetIdDivision set id.
tournamentCodeThe code for the tournament to join (eg. free vs. premium, etc.)
initialScoreThe initial score to give the player on the leaderboard.

Usage

http://localhost:3000
string divSetId = "exampleDivSetId";
string tournamentCode = "exampleTournamentCode1";
int initialScore = 0;
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.TournamentService.JoinDivision(divSetId, tournamentCode, initialScore, successCallback, failureCallback);
JSON Response
{
"data": {
"entryFee": {},
"createdAt": 1654717860000,
"balance": {
"currency": {
"coin": {
"consumed": 0,
"balance": 25000,
"purchased": 25000,
"awarded": 0
}
}
},
"leaderboardId": "^D^weekly^2",
"enrolled": true
},
"status": 200
}