MLB Push Events provides detailed, real-time information on every game event.
Syntax
https://api.sportradar.com/mlb/{access_level}/stream/en/events/subscribe?api_key={your_api_key} |
Parameters
Parameter | Description |
---|---|
access_level | Defines the access level of your API keyproduction , trial |
your_api_key | Your API key |
Optional Query String Parameters
By default, a Push feed will provide all data available for all in progress games. If needed, you can filter the data returned by including query strings.
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.
Parameter | Description |
---|---|
event_category | Event categorystolenbase , runneradvancement , hit , single , double , triple , homerun , strikeout , walk , out , double_play , triple_play , atbatover , runscored , or halfover Example: event_category=hit |
event_type | Event typeatbat , pitch , steal , lineup , warmup , event_over Example: event_type=atbat_id |
inning_half | Inning half (top or bottom)T , B Example: inning_half=T |
inning | Inning expressed as an integer Example: inning=9 |
match | Game id Example: match=sd:match:7779b2fe-70ad-4823-8c6d-9e2453576e2a |
status | Game statusinprogress , created Example: status=inprogress |
team | Team id Example: team=sd:team:25507be1-6a68-4267-bd82-e097d94b359b |
Code Samples
require 'uri'
require 'net/http'
require 'openssl'
url = URI("https://api.sportradar.com/mlb/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/mlb/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.com/mlb/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.com/mlb/trial/stream/en/events/subscribe?api_key={your_api_key}&status=inprogress&match=sd:match:7779b2fe-70ad-4823-8c6d-9e2453576e2a")
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/mlb/trial/stream/en/events/subscribe",
params = {'api_key': 'your_api_key', 'status': 'inprogress', 'match': 'sd:match:7779b2fe-70ad-4823-8c6d-9e2453576e2a'},
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.com/mlb/trial/stream/en/events/subscribe?api_key={your_api_key}&status=inprogress&match=sd:match:7779b2fe-70ad-4823-8c6d-9e2453576e2a'
Response Samples
The above commands return json like this.
Enforced Strikes
See the below samples for behavior of enforced strikes or balls due to time clock violations.
{
"payload":{
"game":{
"id":"1506ae41-f6e1-4d94-bd5a-5adcf6a3a967",
"status":"closed",
"coverage":"full",
"game_number":1,
"double_header":false,
"entry_mode":"STOMP",
"mlb_id":"718777",
"day_night":"D",
"scheduled":"2023-03-30T18:20:00+00:00",
"home_team":"55714da8-fcaf-4574-8443-59bfb511a524",
"away_team":"dcfd5266-00ce-442c-bc09-264cd20cf455",
"home":{
"name":"Cubs",
"market":"Chicago",
"abbr":"CHC",
"id":"55714da8-fcaf-4574-8443-59bfb511a524",
"runs":4,
"hits":6,
"errors":1
},
"away":{
"name":"Brewers",
"market":"Milwaukee",
"abbr":"MIL",
"id":"dcfd5266-00ce-442c-bc09-264cd20cf455",
"runs":0,
"hits":4,
"errors":1
}
},
"event":{
"id":"40ce37f0-24fe-4abe-8d9c-bee4b6167102",
"type":"pitch",
"inning":3,
"inning_half":"T",
"sequence_number":98,
"sequence":1680202550928,
"hitter_id":"42cb5171-ffa3-4600-9c41-dbc3805206ea",
"atbat_id":"894a5399-585b-4966-93a1-8370a3c3e24f",
"outcome_id":"bAB",
"status":"official",
"created_at":"2023-03-30T18:55:50+00:00",
"updated_at":"2023-04-04T23:24:25+00:00",
"wall_clock":{
"start_time":"2023-03-30T18:55:38+00:00",
"end_time":"2023-03-30T18:55:45+00:00"
},
"flags":{
"is_ab_over":false,
"is_bunt":false,
"is_bunt_shown":false,
"is_hit":false,
"is_wild_pitch":false,
"is_passed_ball":false,
"is_double_play":false,
"is_triple_play":false
},
"count":{
"balls":2,
"strikes":2,
"outs":0,
"pitch_count":3
},
"pitcher":{
"id":"cc86d4d3-1618-415e-b7fc-a303f3b8dd6f",
"pitcher_hand":"R",
"hitter_hand":"L",
"pitch_count":39,
"last_name":"Stroman",
"first_name":"Marcus",
"preferred_name":"Marcus",
"jersey_number":"0"
},
"hitter":{
"last_name":"Yelich",
"first_name":"Christian",
"preferred_name":"Christian",
"jersey_number":"22",
"id":"42cb5171-ffa3-4600-9c41-dbc3805206ea"
},
"runners":[
"\\"{
"id":"45d9ee07-705d-4d91-8131-264ab0cc8af4",
"starting_base":2,
"ending_base":2,
"outcome_id":"",
"out":false,
"last_name":"Turang",
"first_name":"Brice",
"preferred_name":"Brice",
"jersey_number":"0"
}
]
}
},
"locale":"en",
"metadata":{
"league":"MLB",
"match":"sd:match:1506ae41-f6e1-4d94-bd5a-5adcf6a3a967",
"status":"closed",
"inning":3,
"inning_half":"T",
"event_type":"pitch",
"event_category":"pitch",
"locale":"en",
"operation":"update",
"version":"v6.5"
}
}{
"payload":{
"game":{
"id":"db073916-8fae-4672-a160-061b2892c17c",
"status":"inprogress",
"coverage":"full",
"game_number":1,
"double_header":false,
"entry_mode":"STOMP",
"mlb_id":"718710",
"day_night":"N",
"scheduled":"2023-04-04T23:05:00+00:00",
"home_team":"a09ec676-f887-43dc-bbb3-cf4bbaee9a18",
"away_team":"2142e1ba-3b40-445c-b8bb-f1f8b1054220",
"home":{
"name":"Yankees",
"market":"New York",
"abbr":"NYY",
"id":"a09ec676-f887-43dc-bbb3-cf4bbaee9a18",
"runs":0,
"hits":0,
"errors":0
},
"away":{
"name":"Phillies",
"market":"Philadelphia",
"abbr":"PHI",
"id":"2142e1ba-3b40-445c-b8bb-f1f8b1054220",
"runs":1,
"hits":1,
"errors":0
}
},
"event":{
"id":"3457862e-9483-4430-9a0e-b75e92dda03c",
"type":"pitch",
"inning":2,
"inning_half":"T",
"sequence_number":44,
"sequence":1680650663534,
"hitter_id":"169ed0b1-e34b-4f4b-925b-f3288f24a5e7",
"atbat_id":"6ae2a923-ca55-464e-ad8c-3b054cb2617d",
"outcome_id":"kKS",
"status":"official",
"created_at":"2023-04-04T23:24:23+00:00",
"updated_at":"2023-04-04T23:24:36+00:00",
"wall_clock":{
"start_time":"2023-04-04T23:24:16+00:00",
"end_time":"2023-04-04T23:24:30+00:00"
},
"flags":{
"is_ab_over":false,
"is_bunt":false,
"is_bunt_shown":false,
"is_hit":false,
"is_wild_pitch":false,
"is_passed_ball":false,
"is_double_play":false,
"is_triple_play":false
},
"count":{
"balls":0,
"strikes":2,
"outs":0,
"pitch_count":2
},
"pitcher":{
"pitch_type":"SI",
"pitch_speed":91.5,
"pitch_zone":12,
"pitch_x":17,
"pitch_y":-204,
"id":"f7967ff6-16ea-408f-aa90-7d4df691679f",
"pitcher_hand":"R",
"hitter_hand":"R",
"pitch_count":16,
"last_name":"Germán",
"first_name":"Domingo",
"preferred_name":"Domingo",
"jersey_number":"0"
},
"hitter":{
"last_name":"Castellanos",
"first_name":"Nicholas",
"preferred_name":"Nick",
"jersey_number":"8",
"id":"169ed0b1-e34b-4f4b-925b-f3288f24a5e7"
}
}
},
"locale":"en",
"metadata":{
"league":"MLB",
"match":"sd:match:db073916-8fae-4672-a160-061b2892c17c",
"status":"inprogress",
"inning":2,
"inning_half":"T",
"event_type":"pitch",
"event_category":"pitch",
"locale":"en",
"operation":"update",
"version":"v6.5"
}
}
{
"payload":{
"game":{
"id":"72c21aec-5c0f-49d6-b8c5-9037ab1bd8dd",
"status":"closed",
"coverage":"full",
"game_number":1,
"double_header":false,
"entry_mode":"STOMP",
"mlb_id":"718717",
"day_night":"D",
"scheduled":"2023-04-04T20:10:00+00:00",
"home_team":"d52d5339-cbdd-43f3-9dfa-a42fd588b9a3",
"away_team":"25507be1-6a68-4267-bd82-e097d94b359b",
"home":{
"name":"Padres",
"market":"San Diego",
"abbr":"SD",
"id":"d52d5339-cbdd-43f3-9dfa-a42fd588b9a3",
"runs":6,
"hits":10,
"errors":1
},
"away":{
"name":"Diamondbacks",
"market":"Arizona",
"abbr":"ARI",
"id":"25507be1-6a68-4267-bd82-e097d94b359b",
"runs":8,
"hits":9,
"errors":1
}
},
"event":{
"id":"fc41c294-4815-436d-bf6c-6f1d2a670c5a",
"type":"pitch",
"inning":1,
"inning_half":"B",
"sequence_number":38,
"sequence":1680639905014,
"hitter_id":"3bb4a60b-953e-4bef-8b25-c6f07d54eddf",
"atbat_id":"1e5c5ed6-4f6a-4b7f-9892-1523b476aed8",
"outcome_id":"kAK",
"status":"official",
"created_at":"2023-04-04T20:25:05+00:00",
"updated_at":"2023-04-04T23:30:19+00:00",
"wall_clock":{
"start_time":"2023-04-04T20:23:46+00:00",
"end_time":"2023-04-04T20:23:51+00:00"
},
"flags":{
"is_ab_over":true,
"is_bunt":false,
"is_bunt_shown":false,
"is_hit":false,
"is_wild_pitch":false,
"is_passed_ball":false,
"is_double_play":false,
"is_triple_play":false
},
"count":{
"balls":3,
"strikes":3,
"outs":3,
"pitch_count":5
},
"pitcher":{
"id":"e488a3a6-4673-4e5d-befe-6d5ab57b0b8e",
"pitcher_hand":"R",
"hitter_hand":"R",
"pitch_count":12,
"last_name":"Gallen",
"first_name":"Zachary",
"preferred_name":"Zac",
"jersey_number":"23"
},
"hitter":{
"last_name":"Machado",
"first_name":"Manuel",
"preferred_name":"Manny",
"jersey_number":"13",
"id":"3bb4a60b-953e-4bef-8b25-c6f07d54eddf"
},
"fielders":[
"\\"{
"id":"c5b9d056-d030-4640-9e4a-a83599984388",
"type":"putout",
"sequence":1,
"last_name":"Herrera",
"first_name":"Jose",
"preferred_name":"Jose",
"jersey_number":"11"
}
]
}
},
"locale":"en",
"metadata":{
"league":"MLB",
"match":"sd:match:72c21aec-5c0f-49d6-b8c5-9037ab1bd8dd",
"status":"closed",
"inning":1,
"inning_half":"B",
"event_type":"pitch",
"event_category":"pitch,strikeout,out,atbatover,halfover",
"locale":"en",
"operation":"update",
"version":"v6.5"
}
}
Data Points
Metadata:
Attribute | Parent Element | Type | Description |
---|---|---|---|
event_category | metadata | String | Category of an event ex. lineup,starters,pitching |
event_type | metadata | String | Type of an event ex. lineup |
league | metadata | String | Alias of a league ex. MLB |
locale | metadata | String | Language code ex. en (English) |
match | metadata | GUID | Unique ID of a game ex. sd:match:30ad883f-aeaf-4e6b-9fd9-a1cc0b6c4679 |
operation | metadata | String | Operation of an updatecreate , update , delete |
status | metadata | String | The status of a gamescheduled , inprogress , complete , closed , wdelay , fdelay , odelay , canceled , unnecessary , if-necessary , postponed , suspended , maintenance |
team | metadata | GUID | Unique ID of a team ex. sd:team:575c19b7-4052-41c2-9f0a-1c5813d02f99 |
version | metadata | String | Version of the API ex. v6.5 |
Boxscore:
Attribute | Parent Element | Type | Description |
---|---|---|---|
abbr | away | String | Abbreviation of the away team ex. MIN (Minnesota) |
errors | away | Integer | Number of errors for the away team |
hits | away | Integer | Number of hits for the away team |
id | away | GUID | Unique ID of the away team ex. 29dd9a87-5bcc-4774-80c3-7f50d985068b |
id | away -probable_pitcher | GUID | Unique ID of the away team's probable pitcher ex. 515af486-d938-4cb6-90e4-943323a5737c |
market | away | String | Market name of the away team ex. Colorado |
name | away | String | Team name of the away team ex. Rockies |
runs | away | Integer | Number of runs for the away team in the game |
abbr | home | String | Abbreviation of the home team ex. CLE (Cleveland) |
errors | home | Integer | Number of errors for the home team |
hits | home | Integer | Number of hits for the home team |
id | home | GUID | Unique ID of the home team ex. 29dd9a87-5bcc-4774-80c3-7f50d985068b |
id | home -probable_pitcher | GUID | Unique ID of the home team's probable pitcher ex. 515af486-d938-4cb6-90e4-943323a5737c |
market | home | String | Market name of the home team ex. Cleveland |
name | home | String | Team name of the home team ex. Guardians |
runs | home | Integer | Number of runs for the home team in the game |
abbr | team | String | Abbreviation of a team ex. TB (Tampa Bay) |
id | team | GUID | Unique ID of a team ex. bdc11650-6f74-49c4-875e-778aeb7632d9 |
market | team | String | Market name of a team ex. Tampa Bay |
name | team | String | Team name ex. Rays |
Game:
Attribute | Parent Element | Type | Description |
---|---|---|---|
away_team | game | GUID | Unique ID of the away team ex. 29dd9a87-5bcc-4774-80c3-7f50d985068b |
coverage | game | String | Coverage level of a gamefull , boxscore |
double_header | game | Boolean | Signifies whether a game is part of a double header |
day_night | game | String | Signifies a day or night gameD , N |
entry_mode | game | String | Signifies the type of data entrySTOMP , LDE |
home_team | game | GUID | Unique ID of the home team ex. ef64da7f-cfaf-4300-87b0-9313386b977c |
id | game | GUID | Unique ID of the game ex. 1b554f5e-d8b7-4268-95da-2f4191015c84 |
game_number | game | Integer | Number of the game |
reference | game | String | Unique MLBAM ID of a game |
scheduled | game | dateTime | Scheduled date and time of a game ex. 2022-09-25T20:10:00+00:00 |
split_squad | game | Boolean | Signifies a Spring Training split squad game |
status | game | String | The status of a gamescheduled , inprogress , complete , closed , wdelay , fdelay , odelay , canceled , unnecessary , if-necessary , postponed , suspended , maintenance |
Lineup:
Attribute | Parent Element | Type | Description |
---|---|---|---|
order | lineups | Integer | Batting order number in the lineup for a player (0-9). 0 is used for the pitcher |
description | lineup | String | Text description of a lineup change ex. Albert Pujols pinch-hitting for Corey Dickerson. |
position | lineup | Integer | Position number for a player (1-12). See our FAQ for a list of position definitions |
id | lineup | GUID | Unique ID of a lineup entry ex. 616d0907-26f1-4adf-875f-c0928d6d1b22 |
inning_half | lineup | String | Inning half of a player entering the gameT , B |
inning | lineups | Integer | Inning of a player entering the game |
first_name | lineup | String | First name of a player ex. Markus |
full_name | lineup | String | Full name of a player ex. Mookie Betts |
suffix | lineup | String | Name suffix of a player ex. Jr. |
player_id | lineup | GUID | Unique ID of a player ex. 084d2514-9ffb-414e-ae16-3bc690aaad51 |
jersey_number | lineup | Integer | Number of a player's jersey |
last_name | lineup | String | Last name of a player ex. Betts |
preferred_name | lineup | String | Preferred name of a player ex. Mookie |
sequence | lineup | Integer | Sequence number of a lineup event |
team_id | event | GUID | Unique ID of a player's team ex. ef64da7f-cfaf-4300-87b0-9313386b977c |
Play-By-Play - At Bat:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | hitter | String | First name of a hitter ex. Markus |
full_name | hitter | String | Full name of a hitter ex. Mookie Betts |
suffix | hitter | String | Name suffix of a hitter ex. Jr. |
hitter_hand | event | String | Handedness of a hitter |
hitter_id | event | GUID | Unique ID of a hitter ex. 084d2514-9ffb-414e-ae16-3bc690aaad51 |
jersey_number | hitter | Integer | Number of a hitter's jersey |
last_name | hitter | String | Last name of a hitter ex. Betts |
preferred_name | hitter | String | Preferred name of a hitter ex. Mookie |
atbat_id | event | GUID | Unique ID of an at bat entry ex. c1e69331-8909-4f1c-b132-5b33079355b4 |
first_name | pitcher | String | First name of a pitcher ex. Adam |
full_name | pitcher | String | Full name of a pitcher ex. Adam Wainwright |
suffix | pitcher | String | Name suffix of a pitcher ex. Jr. |
pitcher_hand | at_bat | String | Handedness of a pitcher |
pitcher_id | event | GUID | Unique ID of a pitcher ex. 084d2514-9ffb-414e-ae16-3bc690aaad51 |
jersey_number | pitcher | Integer | Number of a pitcher's jersey |
last_name | pitcher | String | Last name of a pitcher ex. Wainwright |
preferred_name | pitcher | String | Preferred name of a pitcher ex. Adam |
description | - | String | Text description of a play ex. Will Smith singles to center field. Freddie Freeman to third. |
sequence_number | at_bat | Integer | Sequence number of an event within a game |
sequence | event | UNIX | Sequence number of an event |
type | event | String | Type of an event ex. atbat |
created_at | event | dateTime | Timestamp of an event creation time ex. 2022-09-25T23:00:45+00:00 |
end_time | wall_clock | dateTime | Timestamp of an event end time ex. 2022-09-25T23:00:45+00:00 |
start_time | wall_clock | dateTime | Timestamp of an event start time ex. 2022-09-25T23:00:45+00:00 |
updated_at | event | dateTime | Timestamp of an event update time ex. 2022-09-25T23:00:45+00:00 |
Play-By-Play - Base Runner:
Attribute | Parent Element | Type | Description |
---|---|---|---|
ending_base | runner | Integer | Runner's base at the end of a play |
first_name | runner | String | First name of a runner ex. Markus |
full_name | runner | String | Full name of a runner ex. Mookie Betts |
suffix | runner | String | Name suffix of a runner ex. Jr. |
jersey_number | runner | Integer | Number of a runner's jersey |
last_name | runner | String | Last name of a runner ex. Betts |
out | runners | Boolean | Signifies the runner was out on a play |
outcome_id | runners | String | ID of a runner outcome on a play. Check our FAQ for a list of valid outcomes and their definitions |
description | - | String | Text description of a runner outcome ex. Will Smith to third. or Freddie Freeman scores. |
id | runners | GUID | Unique ID of a player of a runner ex. ea1a2111-44cc-4996-babb-9439465e6760 |
preferred_name | runners | String | Preferred name of a runner ex. Mookie |
starting_base | runners | Integer | Runner's base at the start of a play |
created_at | runner_placed | dateTime | Timestamp of a runner placed event ex. 2022-09-25T20:10:00+00:00 |
id | runner_placed | GUID | Unique ID of a runner placed event (Runner placed at 2nd base to start an inning) |
official | runner_placed | Boolean | Signifies whether the API is ingesting data directly from the league at the time of the event. For true , entry_mode =Ingest . For false , entry_mode =LDE . |
sequence_number | runner_placed | Integer | Sequential number of a runner placed event in a game |
status | runner_placed | String | Status of a runner placed event. Can be utilized to determine if a play is or was under reviewofficial , overturned , under review , upheld |
updated_at | runner_placed | dateTime | Timestamp of a runner placed event ex. 2022-09-25T20:25:14+00:00 |
Play-By-Play - Hitter:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | hitter | String | First name of a hitter ex. Markus |
full_name | hitter | String | Full name of a hitter ex. Mookie Betts |
suffix | hitter | String | Name suffix of a hitter ex. Jr. |
hitter_hand | pitcher | String | Handedness of a hitter |
id | hitter | GUID | Unique ID of a player of a hitter ex. ea1a2111-44cc-4996-babb-9439465e6760 |
jersey_number | hitter | Integer | Number of a hitter's jersey |
last_name | hitter | String | Last name of a hitter ex. Betts |
preferred_name | hitter | String | Preferred name of a hitter ex. Mookie |
Play-By-Play - Errors:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | errors | String | First name of a player committing an error ex. Gavin |
full_name | errors | String | Full name of a player committing an error ex. Gavin Lux |
suffix | errors | String | Name suffix of a player committing an error ex. Jr. |
id | errors | GUID | Unique ID of a player of a player committing an error ex. ea1a2111-44cc-4996-babb-9439465e6760 |
jersey_number | errors | Integer | Jersey number a player committing an error |
last_name | errors | String | Last name of a player committing an error ex. Lux |
preferred_name | errors | String | Preferred name of a player committing an error ex. Gavin |
type | errors | String | Type of fielding errorfielding , throwing , interference |
Play-By-Play - Fielding:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | fielders | String | First name of a player recording an assist ex. Gavin |
full_name | fielders | String | Full name of a player recording an assist ex. Gavin Lux |
suffix | fielders | String | Name suffix of a player recording an assist ex. Jr. |
id | fielders | GUID | Unique ID of a player of a player recording an assist ex. ea1a2111-44cc-4996-babb-9439465e6760 |
jersey_number | fielders | Integer | Jersey number a player recording an assist |
last_name | fielders | String | Last name of a player recording an assist ex. Lux |
preferred_name | fielders | String | Preferred name of a player recording an assist ex. Gavin |
sequence | fielders | Integer | Sequential number of an assist |
first_name | fielders | String | First name of a player recording a putout ex. Byron |
full_name | fielders | String | Full name of a player recording a putout ex. Byron Buxton |
suffix | fielders | String | Name suffix of a player recording a putout ex. Jr. |
id | fielders | GUID | Unique ID of a player recording a putout ex. ea1a2111-44cc-4996-babb-9439465e6760 |
jersey_number | fielders | Integer | Jersey number a player recording a putout |
last_name | fielders | String | Last name of a player recording a putout ex. Buxton |
preferred_name | fielders | String | Preferred name of a player recording a putout ex. Gavin |
sequence | fielders | Integer | Sequential number of a putout |
Play-By-Play - Hit Data:
Attribute | Parent Element | Type | Description |
---|---|---|---|
hit_location | event | Integer | Number code of hit ball location (1-35). Please see our FAQ for a diagram of our field and its corresponding hit location zones |
hit_type | event | String | Type of hitGB (Ground ball), FB (Fly ball), LD (Line drive), PU (Popup) |
Play-By-Play - Inning:
Attribute | Parent Element | Type | Description |
---|---|---|---|
inning_half | event / metadata | String | Indicates top or bottom inning halfT , B |
inning | event / lineup / metadata | Integer | Number of an inning |
sequence_number | event | Integer | Sequential number of an inning |
Play-By-Play - Pitch:
Attribute | Parent Element | Type | Description |
---|---|---|---|
id | pitch | GUID | Unique ID of a pitch ex. 37d94861-7ce4-4547-802c-f97f93e434b4 |
pitch_x | pitcher | Integer | Number as a percentage distance from the center of the strike zone, in positive or negative values from approximately -300% to positive 300% ex. 70 |
pitch_y | pitcher | Integer | Number as a percentage distance from the center of the strike zone, in positive or negative values from approximately -200% to positive 200% ex. -95 |
created_at | pitch | dateTime | Timestamp of a thrown pitch ex. 2022-09-25T20:10:00+00:00 |
pitch_count | pitcher | Integer | Number of pitches for a pitcher in a game |
official | pitch | Boolean | Signifies whether the API is ingesting data directly from the league at the time of the event. For true , entry_mode =Ingest . For false , entry_mode =LDE . |
outcome_id | pitch | String | ID of a pitch outcome on a play. Check our FAQ for a list of valid outcomes and their definitions |
reference | pitch | String | Unique MLBAM ID of a pitch Available with Statcast only |
sequence_number | pitch | Integer | Sequential number of a pitch in a game |
pitch_speed | pitcher | String | Speed of a pitch in MPH ex. 92.0 |
pitch_type | pitcher | String | Code for a type of pitchFA (Fastball), SI (Sinker), CT (Cutter), CU (Curveball), SL (Slider), CH (Changeup), KN (Knuckleball), SP (Splitter), SC (Screwball), FO (Forkball), IB (Intentional Ball), PI (Pitchout), Other |
pitch_zone | pitcher | Integer | Number corresponding to the pitch strike zone (1-13) See our FAQ for more detail and a graphic representation |
status | event | String | Status of a pitch. Can be utilized to determine if a play is or was under reviewofficial , overturned , under review , upheld |
updated_at | event | dateTime | Timestamp of a pitch update ex. 2022-09-25T20:25:14+00:00 |
Play-By-Play - Pitcher:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | pitcher | String | First name of a pitcher ex. Clayton |
full_name | pitcher | String | Full name of a pitcher ex. Clayton Kershaw |
suffix | pitcher | String | Name suffix of a pitcher ex. Jr. |
pitcher_hand | pitcher | String | Handedness of a pitcher |
id | pitcher | GUID | Unique ID of a player of a pitcher ex. ea1a2111-44cc-4996-babb-9439465e6760 |
jersey_number | pitcher | Integer | Number of a pitcher's jersey |
last_name | pitcher | String | Last name of a pitcher ex. Kershaw |
preferred_name | pitcher | String | Preferred name of a pitcher ex. Clayton |
Play-By-Play - Play Flags:
Attribute | Parent Element | Type | Description |
---|---|---|---|
is_ab_over | flags | Boolean | Indicates an at bat has ended on a pitch |
is_bunt | flags | Boolean | Indicates a bunt play |
is_double_play | flags | Boolean | Indicates a double play |
is_passed_ball | flags | Boolean | Indicates a passed ball |
is_hit | flags | Boolean | Indicates a hit |
is_triple_play | flags | Boolean | Indicates a triple play |
is_wild_pitch | flags | Boolean | Indicates a wild pitch |
Play-By-Play - Steal:
Attribute | Parent Element | Type | Description |
---|---|---|---|
created_at | steal | dateTime | Timestamp of a steal attempt ex. 2022-09-25T20:10:00+00:00 |
id | steal | GUID | Unique ID of a steal attempt ex. bebe4b5d-970a-40f4-bfa5-05a9a38eac4a |
official | steal | Boolean | Signifies whether the API is ingesting data directly from the league at the time of the event. For true , entry_mode =Ingest . For false , entry_mode =LDE . |
sequence_number | steal | Integer | Sequence number of an event within a game |
status | steal | String | Status of a pitch/play. Can be utilized to determine if a play is or was under reviewofficial , overturned , under review , upheld |
updated_at | steal | dateTime | Timestamp of a steal attempt update ex. 2022-09-25T20:25:14+00:00 |
Play-By-Play - Warming Up:
Attribute | Parent Element | Type | Description |
---|---|---|---|
first_name | warming_up / event | String | First name of a pitcher warming up in the bullpen ex. Brusdar |
full_name | warming_up / event | String | Full name of a pitcher warming up in the bullpen ex. Brusdar Graterol |
suffix | warming_up / event | String | Name suffix of a pitcher warming up in the bullpen ex. Jr. |
id | warming_up / event | GUID | Unique ID of a warming up event ex. ea1a2111-44cc-4996-babb-9439465e6760 |
player_id | warming_up / event | GUID | Unique ID of a player of a pitcher warming up in the bullpen ex. 43862b88-c119-4625-b138-f3c5ea1b8b06 |
jersey_number | warming_up / event | Integer | Number of a pitcher's jersey |
last_name | warming_up / event | String | Last name of a pitcher warming up in the bullpen ex. Graterol |
preferred_name | warming_up / event | String | Preferred name of a pitcher warming up in the bullpen ex. Brusdar |
team_id | warming_up / event | GUID | Unique team ID of a pitcher warming up in the bullpen ex. 75729d34-bca7-4a0f-b3df-6f26c6ad3719 |