MLB API endpoint
Returns the four anonymous per-swing detail arrays expanded from a batter or pitcher Swing Timing row. Pass the row_id uniqueId from mlb-statcast-swing-timing and repeat its type and table filters so split values can be mapped to the upstream detail query.
/mlb/statcast-swing-timing-detailsPass the uniqueId returned in rows[].uniqueId by
mlb-statcast-swing-timing. The service maps
the row's grouped values back to Baseball Savant's anonymous expansion request.
Only player rows of type batter or pitcher have detail expansions; team and
league rows do not.
row_id (required): a complete player-row uniqueId from the Swing Timing
endpoint, such as 666018_FF_2026. Preserve the entire value; the suffix
contains the selected split and year values.type (required): batter or pitcher.seasons (optional, repeatable): 2023, 2024, 2025, or 2026.game_types (optional, repeatable): R, A, F, D, L, or W.splits (optional, repeatable): api_pitch_type_group03,
api_pitch_type_group09, api_game_date_month_text, bat_contact_code,
game_type, is_hit_into_play_hardhit, is_best_speed,
timing_x_tiedupflail, timing_y_earlylate, timing_z_overunder,
pitch_hand, bat_side, is_pre_ball_count_3, is_pre_strike_count_2,
pitchzone_height_code, or is_starter_pitcher.min_swings (optional): q, 1, 5, 10, 25, 50, 100, 200,
500, or 1000; defaults to q.min_split (optional): 1, 5, 10, 25, 50, 100, 200, 500,
or 1000; defaults to 1.split_year (optional): 0 or 1; defaults to 1.teams (optional, repeatable): 108, 117, 133, 141, 144, 158,
138, 112, 109, 119, 137, 114, 136, 146, 121, 120,
110, 135, 143, 134, 113, 111, 115, 118, 116, 142,
145, or 147.date_start, date_end (optional): inclusive dates in YYYY-MM-DD form;
either bound can be used alone, and the start must not follow the end.bat_side (optional): L or R.contact_type (optional): 2, 4, or 9.attack_zone (optional): 0, 1, 1.1, 2, or 3.pitch_hand (optional): L or R.pitch_types (optional, repeatable): FF, SI, FC, CH, FS, FO,
SC, CU, SL, ST, SV, or KN.counts (optional, repeatable): 00, 01, 02, 10, 11, 12, 20,
21, 22, 30, 31, or 32.swing_timing_x (optional, repeatable): Tiedup, Centered, or Flail.swing_timing_y (optional, repeatable): Early, OnTime, or Late.swing_timing_z (optional, repeatable): Under, Linedup, or Over.flags, not_flags (optional, repeatable): is_timing_xyz_flawed or
is_timing_xyz_perfect.If the parent leaderboard was requested with non-default filters, repeat those
filters here. The selected row_id must have the same split dimensions and
year-splitting mode. Discovery values and meanings are also available from
mlb-discovery.
data.details contains four arrays: miss_distance, x, y, and z. Each
array contains per-swing rows with the game, pitcher/batter identities, pitch
type, play ID, miss distance, timing-axis measurements, and axis categories.
The arrays are separate upstream views and may refer to the same play; total
is their combined row count, not a distinct-play count. Four empty arrays are
a valid no-data result. Missing arrays or malformed rows are upstream errors.
| Field | Filled in, of 10 checked | Values in the sample |
|---|---|---|
| abs_ball_pos_above_plane | 10 | 2.47 to 7.79, median 5.42 |
| abs_delta_batball_late_neg_y2_msec | 10 | 3.97 to 18.46, median 8.75 |
| abs_delta_batball_tiedup_neg_x2 | 10 | 0.07 to 14.74, median 5.39 |
| b_name_display_first_last | 10 | Aranda, Jonathan in all 10 |
| ball_pos_above_plane | 10 | -7.79 to 6.28, median -2.47 |
| delta_batball_late_neg_y2_msec | 10 | -18.46 to 8.45, median -9.84 |
| delta_batball_tiedup_neg_x2 | 10 | -14.74 to 9.99, median -0.07 |
| game_date | 10 | 2026-04-29 to 2026-09-19 |
| game_pk | 10 | 822,787 to 824,871, median 822,930 |
| is_swing_sword | 10 | 0 to 1, median 0 |
| miss_distance_inches | 10 | 2.53 to 11.69, median 2.98 |
| p_name_display_first_last | 10 | “Williams, Gavin” and 9 other values |
| pitch_type | 10 | FC (5), FF (4), SI (1) |
| pitcher | 10 | 571,578 to 703,615, median 668,909 |
| play_id | 10 | |
| savant_batter_id | 10 | |
| timing_x_tiedupflail | 10 | |
| timing_y_earlylate | 10 | |
| timing_z_overunder | 10 | Under (5), Over (5) |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| row_id | string | Yes | Unique row id from mlb-statcast-swing-timing, including any selected split values | 666018_FF_2026 | |
| type | string | Yes | Player row type Allowed values: batter, pitcher. | batter | |
| seasons | array<string> | No | Season filters Allowed values: 2023, 2024, 2025, 2026. | ||
| game_types | array<string> | No | Game-type filters Allowed values: R, A, F, D, L, W. | ||
| splits | array<string> | No | Split dimensions Allowed values: api_pitch_type_group03, api_pitch_type_group09, api_game_date_month_text, bat_contact_code, game_type, is_hit_into_play_hardhit, is_best_speed, timing_x_tiedupflail, timing_y_earlylate, timing_z_overunder, pitch_hand, bat_side, is_pre_ball_count_3, is_pre_strike_count_2, pitchzone_height_code, is_starter_pitcher. | ||
| min_swings | string | No | Minimum swings Allowed values: q, 1, 5, 10, 25, 50, 100, 200, 500, 1000. | ||
| min_split | string | No | Minimum group swings Allowed values: 1, 5, 10, 25, 50, 100, 200, 500, 1000. | ||
| split_year | string | No | Include year in the row grouping Allowed values: 0, 1. | ||
| teams | array<string> | No | MLB team ids Allowed values: 108, 117, 133, 141, 144, 158, 138, 112, 109, 119, 137, 114, 136, 146, 121, 120, 110, 135, 143, 134, 113, 111, 115, 118, 116, 142, 145, 147. | ||
| date_start | string | No | Filter start date in YYYY-MM-DD format | ||
| date_end | string | No | Filter end date in YYYY-MM-DD format | ||
| bat_side | string | No | Batter side Allowed values: L, R. | ||
| contact_type | string | No | Contact type Allowed values: 2, 4, 9. | ||
| attack_zone | string | No | Attack zone Allowed values: 0, 1, 1.1, 2, 3. | ||
| pitch_hand | string | No | Pitcher hand Allowed values: L, R. | ||
| pitch_types | array<string> | No | Pitch type codes Allowed values: FF, SI, FC, CH, FS, FO, SC, CU, SL, ST, SV, KN. | ||
| counts | array<string> | No | Ball-strike counts Allowed values: 00, 01, 02, 10, 11, 12, 20, 21, 22, 30, 31, 32. | ||
| swing_timing_x | array<string> | No | Tied-up/flail axis values Allowed values: Tiedup, Centered, Flail. | ||
| swing_timing_y | array<string> | No | Early/late axis values Allowed values: Early, OnTime, Late. | ||
| swing_timing_z | array<string> | No | Over/under axis values Allowed values: Under, Linedup, Over. | ||
| flags | array<string> | No | Positive swing timing flags Allowed values: is_timing_xyz_flawed, is_timing_xyz_perfect. | ||
| not_flags | array<string> | No | Excluded swing timing flags Allowed values: is_timing_xyz_flawed, is_timing_xyz_perfect. | ||
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/mlb/statcast-swing-timing-details?row_id=666018_FF_2026&type=batter&seasons=2023&game_types=R&splits=api_pitch_type_group03&min_swings=q&min_split=1&split_year=0&teams=108&bat_side=L&contact_type=2&attack_zone=0&pitch_hand=L&pitch_types=FF&counts=00&swing_timing_x=Tiedup&swing_timing_y=Early&swing_timing_z=Under&flags=is_timing_xyz_flawed¬_flags=is_timing_xyz_flawed" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 0,
"data": {
"row_id": "666018_FF_2026",
"type": "batter",
"total": 4,
"source_url": "https://baseballsavant.mlb.com/leaderboard/services/swing-timing?...",
"fetched_at": "2026-09-30T00:00:00Z",
"details": {
"miss_distance": [
{
"play_id": "sample-play-id",
"game_date": "2026-08-01T00:00:00.000Z",
"pitch_type": "FF",
"miss_distance_inches": "8.2"
}
],
"x": [
{
"play_id": "sample-play-id",
"timing_x_tiedupflail": "Centered"
}
],
"y": [
{
"play_id": "sample-play-id",
"timing_y_earlylate": "OnTime"
}
],
"z": [
{
"play_id": "sample-play-id",
"timing_z_overunder": "Linedup"
}
]
}
}
}Request schema
No body schema
Response schema
#/definitions/mlb.statcastSwingTimingDetailsResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| details | object | No | ||||
| fetched_at | string | No | ||||
| row_id | string | No | ||||
| source_url | string | No | ||||
| total | integer | No | ||||
| type | string | No |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 404 | Not Found | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/mlb/statcast-swing-timing-details?row_id=666018_FF_2026&type=batter&seasons=2023&game_types=R&splits=api_pitch_type_group03&min_swings=q&min_split=1&split_year=0&teams=108&bat_side=L&contact_type=2&attack_zone=0&pitch_hand=L&pitch_types=FF&counts=00&swing_timing_x=Tiedup&swing_timing_y=Early&swing_timing_z=Under&flags=is_timing_xyz_flawed¬_flags=is_timing_xyz_flawed" \
-H "x-api-key: $CRAWLORA_API_KEY"