GET
https://api.cryptohopper.com/v1/tournaments/{tournament_id}/leaderboard
Returns the top 100 players of one tournament, ordered by score.
OAuth scope:
read About scopes
player_id is the social profile ID of the player. The tournament is not checked for existence; an unknown ID returns an empty list.
Example request
curl "https://api.cryptohopper.com/v1/tournaments/TOURNAMENT_ID/leaderboard" \
-H "access-token: YOUR_ACCESS_TOKEN"
const response = await fetch('https://api.cryptohopper.com/v1/tournaments/TOURNAMENT_ID/leaderboard', {
method: 'GET',
headers: {
"access-token": "YOUR_ACCESS_TOKEN"
}
});
const data = await response.json();
import requests
response = requests.get(
"https://api.cryptohopper.com/v1/tournaments/TOURNAMENT_ID/leaderboard",
headers={
"access-token": "YOUR_ACCESS_TOKEN"
},
)
data = response.json()
$ch = curl_init('https://api.cryptohopper.com/v1/tournaments/TOURNAMENT_ID/leaderboard');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'access-token: YOUR_ACCESS_TOKEN',
],
]);
$data = json_decode(curl_exec($ch), true);
Parameters
Headers
| Name | Type | Required | Description |
|---|---|---|---|
access-token |
string | Required | The OAuth access token of the user. |
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
tournament_id |
string | Required | Numeric ID of the tournament. |
Response
{
"data": [
{
"score": "12.84",
"alias": "trader-jane",
"name": "Trader Jane",
"player_id": "4567",
"logo": "https://cdn.example.com/images/social/uploads/avatar_4567.jpg"
}
]
}