SportAPINBAGet SportAPI Key

Portland Trail Blazers

Coach
Micah Nori
Arena
Moda Center
Conference
Western
8-3Record
5thWestern
W2Streak

Roster

No.PlayerPosHtGPMinPtsRebAstFG%3P%
8Deni AvdijaF6-81132.523.06.16.547.433.9
0Damian LillardG6-21129.219.83.24.242.733.3
1Ja MorantG6-2426.015.82.55.554.240.0
5Jrue HolidayG6-41126.213.43.43.950.044.4
33Toumani CamaraF6-71128.513.13.51.550.043.2
23Donovan ClinganC7-21125.210.810.41.557.346.2
00Scoot HendersonG6-31122.28.42.11.531.522.7
91Sidy CissokoG6-61122.98.33.52.047.536.6
35Robert Williams IIIC6-9916.37.66.60.967.4–
11Chris YoungbloodG6-4613.56.01.31.037.034.8
2John TonjeF6-515.05.00.00.050.050.0
16Yang HansenC7-179.34.03.00.347.155.6
27Vit KrejciG6-8710.12.71.61.030.020.0
9Micah PotterC6-976.62.61.90.150.033.3
29Jayson KentG6-829.52.01.00.520.00.0
10Branden CarlsonC7-068.21.72.20.345.50.0
17Shaedon SharpeG6-50––––––

Per-game averages in the NBA regular season so far. Players without a game have dashes.

Get this team's data from the API

The team ID of the Portland Trail Blazers is 31 and the slug is portland-trail-blazers. /api/basketball/teams/slug/{slug} returns the coach, the arena, the standing and the latest and next games. The roster is at /api/basketball/teams/{id}/roster and every game of the team at /api/basketball/teams/{id}/games, newest first. The averages in the roster table on this page come from each player's profile at /api/basketball/players/slug/{slug}.

team.py
import requests

API_KEY = "YOUR_API_KEY"
session = requests.Session()
session.headers["X-API-Key"] = API_KEY
BASE = "https://sportapi.ai/api/basketball"

team = session.get(f"{BASE}/teams/slug/portland-trail-blazers", timeout=20).json()["data"]
print(team["name"], "- coach", team["coach_name"])

roster = session.get(f"{BASE}/teams/31/roster", timeout=20).json()["data"]
for p in roster:
    print(p["jersey"], p["name"], p["position"], p["height_cm"], "cm")

games = session.get(f"{BASE}/teams/31/games", params={"league": "nba", "limit": 5}, timeout=20).json()["data"]
for g in games:
    print(g["start"], g["away"]["abbreviation"], "@", g["home"]["abbreviation"], g["status"])

The API documentation lists every basketball endpoint. The same key works for the NBA, WNBA, EuroLeague, NCAA and the other leagues, and for football too.

Updated Nov 13, 11:58 AM ET