Get team season stats (NBA only)
curl --request GET \
--url https://api.sportquanta.com/v1/{league}/team-stats \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sportquanta.com/v1/{league}/team-stats"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sportquanta.com/v1/{league}/team-stats', 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://api.sportquanta.com/v1/{league}/team-stats",
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://api.sportquanta.com/v1/{league}/team-stats"
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://api.sportquanta.com/v1/{league}/team-stats")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sportquanta.com/v1/{league}/team-stats")
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": {
"season": 123,
"teams": [
{
"teamId": "<string>",
"stats": {
"season": 123,
"id": "<string>",
"canonical_id": "<string>",
"external_ids": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"team_id": "<string>",
"games_played": 123,
"off_rating": 123,
"def_rating": 123,
"net_rating": 123,
"pace": 123,
"points_for": 123,
"three_pointers_made": 123,
"three_pointers_attempted": 123,
"free_throws_made": 123,
"free_throws_attempted": 123,
"rebounds_offensive": 123,
"rebounds_defensive": 123,
"rebounds": 123,
"points_in_paint": 123,
"opp_points_in_paint": 123,
"points_against": 123,
"opp_three_pointers_made": 123,
"opp_three_pointers_attempted": 123,
"opp_free_throws_made": 123,
"opp_free_throws_attempted": 123,
"opp_rebounds_offensive": 123,
"opp_rebounds_defensive": 123,
"opp_rebounds": 123
},
"offenseRanks": {
"rating": 123,
"pace": 123,
"paintScoring": 123,
"threePtScoring": 123,
"freeThrows": 123,
"rebounding": 123
},
"defenseRanks": {
"rating": 123,
"pace": 123,
"paintScoring": 123,
"threePtScoring": 123,
"freeThrows": 123,
"rebounding": 123
},
"gamesPlayed": 123
}
]
},
"_meta": {
"request_id": "<string>",
"served_from": "live",
"cache_ttl_seconds": 123,
"provenance": {},
"availability": {}
}
}Season Stats & Analytics
Team season statistics
Returns the league-wide NBA team season aggregate set for the requested season,
including offense/defense ranks computed at read time. Other leagues return
404 endpoint_not_for_sport.
Requires the stats entitlement (a paid plan). See Responses & Errors for the success envelope and availability rules.
GET
/
v1
/
{league}
/
team-stats
Get team season stats (NBA only)
curl --request GET \
--url https://api.sportquanta.com/v1/{league}/team-stats \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sportquanta.com/v1/{league}/team-stats"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sportquanta.com/v1/{league}/team-stats', 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://api.sportquanta.com/v1/{league}/team-stats",
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://api.sportquanta.com/v1/{league}/team-stats"
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://api.sportquanta.com/v1/{league}/team-stats")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sportquanta.com/v1/{league}/team-stats")
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": {
"season": 123,
"teams": [
{
"teamId": "<string>",
"stats": {
"season": 123,
"id": "<string>",
"canonical_id": "<string>",
"external_ids": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"team_id": "<string>",
"games_played": 123,
"off_rating": 123,
"def_rating": 123,
"net_rating": 123,
"pace": 123,
"points_for": 123,
"three_pointers_made": 123,
"three_pointers_attempted": 123,
"free_throws_made": 123,
"free_throws_attempted": 123,
"rebounds_offensive": 123,
"rebounds_defensive": 123,
"rebounds": 123,
"points_in_paint": 123,
"opp_points_in_paint": 123,
"points_against": 123,
"opp_three_pointers_made": 123,
"opp_three_pointers_attempted": 123,
"opp_free_throws_made": 123,
"opp_free_throws_attempted": 123,
"opp_rebounds_offensive": 123,
"opp_rebounds_defensive": 123,
"opp_rebounds": 123
},
"offenseRanks": {
"rating": 123,
"pace": 123,
"paintScoring": 123,
"threePtScoring": 123,
"freeThrows": 123,
"rebounding": 123
},
"defenseRanks": {
"rating": 123,
"pace": 123,
"paintScoring": 123,
"threePtScoring": 123,
"freeThrows": 123,
"rebounding": 123
},
"gamesPlayed": 123
}
]
},
"_meta": {
"request_id": "<string>",
"served_from": "live",
"cache_ttl_seconds": 123,
"provenance": {},
"availability": {}
}
}Reference context: KBL.
Overview · Response conventions
Authorizations
Send a workspace API token in the Authorization: Bearer <token> header.
Path Parameters
League for this reference section: kbl.
Available options:
kbl Query Parameters
Required range:
1946 <= x <= 2100Response
Team season stats response for the requested NBA season.
Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Available options:
live, cache Response cache TTL; independent of source freshness. Omitted when zero.
Endpoint-specific availability context, including soccer roster coverage.