List galaxy
Returns every ranked org as a star, for a page to draw the community as a galaxy: each star holds its band in the reward program's level table, a coarse size (a factor of two), the star of the org that referred it, if any, and, only for the ranks the reader has earned a view of, its exact points and the name the standing shows for it.
GET /v1/leaderboard/galaxy
| Address | https://api.hanzo.ai/v1/leaderboard/galaxy |
| Method | GET |
| Operation | get_leaderboard_galaxy |
| Auth | Authorization: Bearer $HANZO_API_KEY |
Returns every ranked org as a star, for a page to draw the community as a galaxy: each
star holds its band in the reward program's level table, a coarse size (a factor of
two), the star of the org that referred it, if any, and, only for the ranks the reader
has earned a view of, its exact points and the name the standing shows for it. The
window is the standing's: a signed-in reader sees their own star, five ranks below it
and as many above as their points have earned; a reader who is not signed in sees the
last ranks, where a newcomer starts. Every other star has points of -1 and no name,
and is still drawn. The stars are columns of equal length, best first, and center is
the tokens used and the orgs active in the last 24 hours. A star's id is opaque: it is
the same wherever this answer mentions that star, names no org, and is replaced on the
next read, about a minute later. A signed-in reader gets self, the id of their own
star. Names are the standing's: masked in the middle, whole where the org listed
itself, empty where it withdrew. No org id, handle or email is sent. No credential is
needed to read it.
Request
GET /v1/leaderboard/galaxy takes no parameters and no body — the credential is the whole request.
Response
| Status | Body | Meaning |
|---|---|---|
200 | leaderboard.GalaxyView | ok |
default | problem-details | refused |
200 body — 13 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
available | body | boolean | — | Available is false when the warehouse is not connected or a source could not be read and none ever was: the stars are then empty because nothing could be read. |
bands | body | string[] | — | Bands are the band names of the reward program's level table, lowest first; a star's band indexes them. |
center | body | leaderboard.GalaxyCenter | — | |
center.activeOrgs24h | body | integer (int64) | — | ActiveOrgs24h is how many different orgs used any of them. |
center.tokens24h | body | integer (int64) | — | Tokens24h is the tokens used in the last 24 hours: the sum of the pulse's tokens by hour. |
self | body | string | — | Self is the id of the signed-in reader's own star; empty for a reader who is not signed in or whose org the board does not hold. |
stars | body | leaderboard.GalaxyStars | — | |
stars.band | body | integer (int64)[] | — | Band is each star's index in the response's bands. |
stars.id | body | string[] | — | ID is each star's opaque id, of no use after the next read. |
stars.mask | body | string[] | — | Mask is the name the standing shows for the org where the reader's reveal window holds it: masked in the middle, whole where it listed itself, empty where it withdrew. |
stars.points | body | integer (int64)[] | — | Points is each star's exact score where the reader's reveal window holds it, and -1 where it does not: a star the reader has not earned a view of. |
stars.size | body | integer (int64)[] | — | Size is each star's coarse size, from 0: the bit length of its points, a factor of two. |
stars.sponsor | body | string[] | — | Sponsor is the id of the star that referred this one; empty where none did. |
Failure carries the platform error shape — see Errors.
Examples
hanzo leaderboard galaxyimport { Configuration, LeaderboardApi } from 'hanzoai';
const api = new LeaderboardApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getLeaderboardGalaxy();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import LeaderboardApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = LeaderboardApi(client).get_leaderboard_galaxy()cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)
resp, _, err := client.LeaderboardAPI.GetLeaderboardGalaxy(context.Background()).Execute()
if err != nil {
return err
}use hanzo_client::apis::{configuration::Configuration, leaderboard_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = leaderboard_api::get_leaderboard_galaxy(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.LeaderboardApi;
ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));
var result = new LeaderboardApi(client).getLeaderboardGalaxy();The method above is the one at the current release of the document. [email protected] (npm) and [email protected] (PyPI) were generated from an earlier release, where this operation carried a different id, so it spells the method differently — regenerating the clients is what makes the two agree. SDKs →
curl https://api.hanzo.ai/v1/leaderboard/galaxy \
-H "Authorization: Bearer $HANZO_API_KEY"Tool leaderboard, op get_leaderboard_galaxy — POST the JSON-RPC envelope to https://api.hanzo.ai/v1/mcp.
curl -X POST https://api.hanzo.ai/v1/mcp \
-H "Authorization: Bearer $HANZO_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "leaderboard",
"arguments": {
"op": "get_leaderboard_galaxy",
"input": {}
}
}
}'