Get a league with games and officials
curl --request GET \
--url https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"name": "<string>",
"currency": "<string>",
"source": "<string>",
"externalId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"games": [
{
"id": "<string>",
"leagueId": "<string>",
"sport": "<string>",
"startsAt": "2023-11-07T05:31:56Z",
"location": "<string>",
"latitude": 123,
"longitude": 123,
"source": "<string>",
"externalId": "<string>",
"positions": [
{
"id": "<string>",
"label": "<string>",
"payCents": 123,
"payDollars": 123
}
]
}
],
"officials": [
{
"membershipId": "<string>",
"userId": "<string>",
"name": "<string>",
"email": "<string>",
"joinedAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": "unauthorized"
}{
"error": "league_not_found"
}Leagues
Get a league with games and officials
League detail: games (ordered by startsAt ascending, positions included) and officials (memberships with role official in all statuses — filter on status yourself; pending and denied are included).
GET
/
leagues
/
{leagueId}
Get a league with games and officials
curl --request GET \
--url https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://whistle.huddleup-sports.com/api/v1/leagues/{leagueId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"name": "<string>",
"currency": "<string>",
"source": "<string>",
"externalId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"games": [
{
"id": "<string>",
"leagueId": "<string>",
"sport": "<string>",
"startsAt": "2023-11-07T05:31:56Z",
"location": "<string>",
"latitude": 123,
"longitude": 123,
"source": "<string>",
"externalId": "<string>",
"positions": [
{
"id": "<string>",
"label": "<string>",
"payCents": 123,
"payDollars": 123
}
]
}
],
"officials": [
{
"membershipId": "<string>",
"userId": "<string>",
"name": "<string>",
"email": "<string>",
"joinedAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": "unauthorized"
}{
"error": "league_not_found"
}Authorizations
Partner API key: Authorization: Bearer whk_…. Keys are issued by the Whistle team (email tommy@huddleup-sports.com), shown once at issuance, and bound to your source namespace — they access only your leagues (plus explicit grants) and your webhook endpoints. Any auth failure returns 401 {"error":"unauthorized"}; the API never returns 403 — out-of-scope resources answer 404 exactly like nonexistent ones.
Path Parameters
Whistle league id (id from league responses).
Response
League detail
Show child attributes
Show child attributes
Last modified on July 10, 2026
⌘I

