Docs
Coverage MatrixDocumentationRelease LogLog In

Push Events

NBA G League Push Events retrieves detailed, real-time information on every game event.

Syntax

https://api.sportradar.us/nbdl/{access_level}/stream/{language_code}/events/subscribe?api_key={your_api_key}

Replace placeholders with the following query parameters:

ParameterDescription
access_levelDefines the access level of your API key as Production (production), or Trial (trial).
localeLocale expressed as 2 letter code: locale={language_code}
Example: locale=en
your_api_keyYour API key.

Optional Query String Parameters

In addition to the URL parameters listed above, you can filter the event information with one or more of the following optional query string parameters.

๐Ÿ“˜

Optional query string parameters must be added after your API key with an ampersand (&). If you are filtering for more than one result, separate the results with a comma (,) and no spaces.

Replace placeholders with the following query parameters:

ParameterDescription
event_categoryEvent category expressed as: {event_category}.
Example: event_category=shot
event_typeEvent type expressed as: {event_type}.
Example: event_type=stoppage
matchMatch id expressed as: sd:match:{match_id}.
Example: match=sd:match:76b2e680-7da7-461f-95ad-e7c34dbc4c56
playersPlayer id expressed as: sd:player:{player_id}.
Example: players=sd:player:c1ff3e58-266f-4183-9fa1-d7c914cf4886
statusStatus type expressed as: inprogress or created.
Example: status=inprogress
teamTeam id expressed as: sd:team:{team_id}.
Example: team=sd:team:583eca2f-fb46-11e1-82cb-f4ce4684ea4c

Code Samples

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/nbdl/trial/stream/en/events/subscribe?api_key={your_api_key}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/nbdl/trial/stream/en/events/subscribe",
    params = {'api_key': 'your_api_key'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/nbdl/trial/stream/en/events/subscribe?api_key={your_api_key}'

Samples with Query String Params

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/nbdl/trial/stream/en/events/subscribe?api_key={your_api_key}&status=inprogress&match=sd:match:76b2e680-7da7-461f-95ad-e7c34dbc4c56")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/nbdl/trial/stream/en/events/subscribe",
    params = {'api_key': 'your_api_key', 'status': 'inprogress', 'tester': 'test_this_thing'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/nbdl/trial/stream/en/events/subscribe?api_key={your_api_key}&status=inprogress&match=sd:match:76b2e680-7da7-461f-95ad-e7c34dbc4c56'

Response Sample

The above commands return json like this.



Data Points

Game:
AttributeParent ElementTypeDescription
coveragegameStringCoverage level of a game
full, extended_boxscore
idgameGUIDUnique ID of a game
ex. 1f730a9a-8221-48ff-a259-ac2103fb58b0
referencegameStringLeague reference ID of a game
ex. 1610612758
statusgameStringThe status of a game
scheduled, created, inprogress, halftime, complete, closed, cancelled, delayed, postponed, time-tbd, if-necessary, unnecessary

Please see our FAQ section for a list of game status definitions
titlegameStringTitle of a game
ex. Game 3
scheduledgamedateTimeScheduled date and time of a game
ex. 2022-09-25T20:10:00+00:00
awaygame - time_zonesStringTime zone of the away team
ex. US/Pacific
homegame - time_zonesStringTime zone of the home team
ex. US/Eastern
venuegame - time_zonesStringTime zone of the venue
ex. US/Eastern
Metadata:
AttributeParent ElementTypeDescription
event_categorymetadataStringCategory of an event
ex. lineupchange or shot
event_typemetadataStringType of an event
ex. threepointmiss or rebound
leaguemetadataStringAlias of a league
ex. NBDL
localemetadataStringLanguage code
ex. en (English)
matchmetadataGUIDUnique ID of a game
ex. sd:match:0c2d1f82-a3de-4754-987e-4c1158ba2969
operationmetadataStringOperation of an update
update, delete
playersmetadataGUIDUnique ID(s) of players associated with an event
ex. sd:player:,sd:player:7fb15c57-6024-4b0c-9493-8d52d3ef3c24,sd:player:09e2f4e8-4519-47a0-849b-10a257205e5a
statusmetadataStringThe status of a game
scheduled, created, inprogress, halftime, complete, closed, cancelled, delayed, postponed, time-tbd, if-necessary, unnecessary

Please see our FAQ section for a list of game status definitions
teammetadataGUIDUnique ID(s) of team(s) associated with an event
ex. sd:team:fb26de83-c7a1-44be-902a-9bf60f74f610
versionmetadataStringVersion of the API
ex. v7
Play-by-Play - Attribution & Possession:

Attribution is the team associated with the play-by-play event (i.e. the statistic associated with it). Possession is the team who currently has the possession of the ball as a result of that play-by-play event.

AttributeParent ElementTypeDescription
idevent - attributionGUIDUnique ID of a team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketevent - attributionStringMarket name of a team
ex. Delaware
nameevent - attributionStringTeam name
ex. Blue Coats
team_basketevent - attributionStringThe basket the offensive team is shooting at in the arena. Direction is based on the TV broadcast's perspective.
left, right
idevent - possessionGUIDUnique ID of a team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketevent - possessionStringMarket name of a team
ex. Delaware
nameevent - possessionStringTeam name
ex. Blue Coats
Play-by-Play - Home/Away Teams:
AttributeParent ElementTypeDescription
bonusgame - awayBooleanSignifies a team is in the bonus
pointsgame - awayIntegerTotal points for the away team
idgame - awayGUIDUnique ID of the away team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketgame - awayStringMarket name of the away team
ex. Delaware
namegame - awayStringAway team name
ex. Blue Coats
remaining_timeoutsgame - awayIntegerRemaining timeouts for the away team
bonusgame - homeBooleanSignifies a team is in the bonus
pointsgame - homeIntegerTotal points for the home team
idgame - homeGUIDUnique ID of the home team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketgame - homeStringMarket name of the home team
ex. Delaware
namegame - homeStringHome team name
ex. Blue Coats
remaining_timeoutsgame - homeIntegerRemaining timeouts for the home team
Play-by-Play - Event:
AttributeParent ElementTypeDescription
clock_decimaleventStringClock value in decimal form when the game clock is under 1:00. Otherwise it displays the same value as clock
ex. 00:21.70
createdeventdateTimeTimestamp of the creation of an event
ex. 2022-09-25T23:00:45+00:00
attempteventStringText description of a free throw attempt
ex. 1 of 2 or 2 of 2
away_pointseventIntegerTotal points for the away team after an event
clockeventStringClock value of an event
ex. 12:37
descriptioneventStringText description of an event
ex. Kevon Looney makes two point jump shot (Klay Thompson assists)
event_typeeventStringType of event
ex. turnover or rebound

See our FAQ for a complete list of types
home_pointseventIntegerTotal points for the home team after an event
ideventGUIDUnique ID of an event
ex. b9feda23-c03f-4304-afa4-06d7dc830651
action_areaevent - locationStringAction area of an event
underbasket, inthepaint, insiderightwing, insideright, insidecenter, insideleft, insideleftwing, outsideright, outsidecenter, outsideleft, outsideleftwing, backcourt

Please see our FAQ for detailed plot points of our action areas
coord_xevent - locationIntegerX coordinate of an event. The court we use is 1128 by 600; the scale is in inches.
coord_yevent - locationIntegerY coordinate of an event. The court we use is 1128 by 600; the scale is in inches.
numbereventIntegerSequential number of an event in a game
qualifierevents - qualifiers - qualifierStringAdditional descriptor of a play-by-play event type.
Appears only in JSON format
2ndchance, fastbreak, fromturnover, defensivegoaltending, pointsinthepaint, fastbreak, fromturnover, team, deadball, 1freethrow.2freethrow, mandatory
sequenceeventIntegerUNIX timestamp of the wall clock value. Use this value to help sequence play-by-play events (smallest to largest sequence number}.
ex. 1678835426293
turnover_typeeventStringType of turnover
ex. Traveling or Lane Violation

See our FAQ for a complete list of types
updatedeventdateTimeTimestamp of the last update to an event
ex. 2022-09-25T23:00:45+00:00
wall_clockeventdateTimeTimestamp in UTC when the on-venue statistician began entry of a play-by-play event.
ex. 2023-03-14T23:10:26Z
Play-by-Play - Play Participants & Stats:
AttributeParent ElementTypeDescription
idevent - statistics - teamGUIDUnique ID of a team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketevent - statistics - teamStringMarket name of a team
ex. Delaware
nameevent - statistics - teamStringTeam name
ex. Blue Coats
full_nameevent - statistics - playerStringFull name of a player
ex. Brandon Paul
idevent - statistics - playerGUIDUnique player ID
ex. 09e2f4e8-4519-47a0-849b-10a257205e5a
jersey_numberevent - statistics - playerIntegerNumber of a player's jersey
madeevent - statisticsBooleanSignifies a made basket
pointsevent - statisticsIntegerNumber of points scored for an event
rebound_typeevent - statistics - reboundStringRebound type
defensive, offensive
shot_distanceevent - statisticsDecimalShot distance in feet from the basket
ex. 2.37
shot_typeevent - statisticsStringShot type
jump shot, layup, dunk, hook, tip
shot_type_descevent - statisticsStringText description of a shot type
ex. driving or alley-oop

See our FAQ for a complete list of descriptions
three_point_shotevent - statisticsBooleanSignifies a 3-point attempt
madeevent - statistics - freethrowBooleanSignifies a made free throw
free_throw_typeevent - statistics - freethrowStringType of free throw
ex. regular, technical, flagrant, clear path
Play-by-Play - On Court Participants:
AttributeParent ElementTypeDescription
full_nameevent - on_court - home / away - playersStringFull name of a player
ex. Brandon Paul
idevent - on_court - home / away - playersGUIDUnique player ID
ex. 09e2f4e8-4519-47a0-849b-10a257205e5a"
jersey_numberevent - on_court - home / away - playersIntegerNumber of a player's jersey
idevent - on_court - home / awayGUIDUnique ID of a team
ex. 67a79348-041a-45f6-bb12-722d38dc8dbf
marketevent - on_court - home / awayStringMarket name of a team
ex. Delaware
nameevent - on_court - home / awayStringTeam name
ex. Blue Coats
Quarter:
AttributeParent ElementTypeDescription
idperiodGUIDUnique ID of a quarter
ex. fece1ac0-b703-4478-8a7c-3f27313dec97
numberperiodIntegerNumber of a quarter
sequenceperiodIntegerSequential number of a quarter
typeperiodGUIDType of period
ex. quarter