diff --git a/.github/workflows/build-and-test-mlbstatsapi-prd.yml b/.github/workflows/build-and-test-mlbstatsapi-prd.yml index 975e662f..eb880280 100644 --- a/.github/workflows/build-and-test-mlbstatsapi-prd.yml +++ b/.github/workflows/build-and-test-mlbstatsapi-prd.yml @@ -25,8 +25,6 @@ jobs: virtualenvs-in-project: true - name: Install dependencies run: poetry install --no-interaction - - name: Test with mocks with pytest - run: poetry run pytest tests/mock_tests/ - name: Test external tests with pytest run: poetry run pytest tests/external_tests/ - name: Build package diff --git a/.github/workflows/build-and-test-mlbstatsapi-test.yml b/.github/workflows/build-and-test-mlbstatsapi-test.yml index f54c6a91..0421b4e3 100644 --- a/.github/workflows/build-and-test-mlbstatsapi-test.yml +++ b/.github/workflows/build-and-test-mlbstatsapi-test.yml @@ -25,8 +25,6 @@ jobs: virtualenvs-in-project: true - name: Install dependencies run: poetry install --no-interaction - - name: Test with mocks with pytest - run: poetry run pytest tests/mock_tests/ - name: Test external tests with pytest run: poetry run pytest tests/external_tests/ - name: Build package diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml index 6a0dda83..c5d1fe00 100644 --- a/.github/workflows/build-and-test.yml +++ b/.github/workflows/build-and-test.yml @@ -26,8 +26,6 @@ jobs: virtualenvs-in-project: true - name: Install dependencies run: poetry install --no-interaction - - name: Test with mocks with pytest - run: poetry run pytest tests/mock_tests/ - name: Test external tests with pytest run: poetry run pytest tests/external_tests/ - name: Build package diff --git a/README.md b/README.md index 523e0199..50938f93 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ Ty France >>> groups = ['hitting'] >>> params = {'season': 2022} >>> mlb.get_player_stats(664034, stats, groups, **params) -{'hitting': {'season': Stat, 'seasonadvanced': Stat }} +{'hitting': {'season': Stat, 'seasonAdvanced': Stat }} >>> mlb.get_team_id("Seattle Mariners") [136] @@ -185,9 +185,6 @@ Contributions are welcome! Whether it's bug fixes, new features, or documentatio # Run tests poetry run pytest -# Run mock tests only (no external API calls) -poetry run pytest tests/mock_tests/ - # Run external tests (requires internet) poetry run pytest tests/external_tests/ ``` @@ -277,7 +274,7 @@ Use team id and the stat types and groups to return season hitting stats ```python >>> stats = mlb.get_team_stats(team_id, stats=stats, groups=groups, **params) >>> season_hitting = stats['hitting']['season'] ->>> advanced_hitting = stats['hitting']['seasonadvanced'] +>>> advanced_hitting = stats['hitting']['seasonAdvanced'] ``` Print stats as JSON @@ -301,7 +298,7 @@ Print stats as JSON >>> params = {'season': 2022} >>> stats = mlb.get_player_stats(player_id, stats=stats, groups=group, **params) ->>> expected = stats['hitting']['expectedstatistics'] +>>> expected = stats['hitting']['expectedStatistics'] >>> for split in expected.splits: ... print(f"Expected AVG: {split.stat.avg}") ... print(f"Expected SLG: {split.stat.slg}") @@ -326,7 +323,7 @@ Set stat type, stat groups, and params Get stats ```python >>> stats = mlb.get_player_stats(ty_france_id, stats=stats, groups=group, **params) ->>> vs_player = stats['hitting']['vsplayer'] +>>> vs_player = stats['hitting']['vsPlayer'] >>> for split in vs_player.splits: ... print(f"Games: {split.stat.games_played}, Hits: {split.stat.hits}") Games: 2, Hits: 2 @@ -340,7 +337,7 @@ Games: 2, Hits: 2 >>> params = {'season': 2022} >>> hotcoldzones = mlb.get_player_stats(ty_france_id, stats=stats, groups=hitting_group, **params) ->>> zones = hotcoldzones['stats']['hotcoldzones'] +>>> zones = hotcoldzones['stats']['hotColdZones'] >>> for split in zones.splits: ... print(f"Stat: {split.stat.name}") diff --git a/mlbstatsapi/mlb_api.py b/mlbstatsapi/mlb_api.py index ce70f540..40657ba5 100644 --- a/mlbstatsapi/mlb_api.py +++ b/mlbstatsapi/mlb_api.py @@ -193,7 +193,7 @@ def get_persons(self, person_ids: Union[str, List[int]], **params) -> List[Perso return person_list def get_people_id(self, fullname: str, sport_id: int = 1, - search_key: str = 'fullname', **params) -> List[int]: + search_key: str = 'fullName', **params) -> List[int]: """ Returns specific player information based on players fullname @@ -903,7 +903,7 @@ def get_game(self, game_id: int, **params) -> Union[Game, None]: if 400 <= mlb_data.status_code <= 499: return None - if 'gamepk' in mlb_data.data and mlb_data.data['gamepk'] == game_id: + if 'gamePk' in mlb_data.data and mlb_data.data['gamePk'] == game_id: return Game(**mlb_data.data) def get_game_play_by_play(self, game_id: int, **params) -> Union[Plays, None]: @@ -948,7 +948,7 @@ def get_game_play_by_play(self, game_id: int, **params) -> Union[Plays, None]: if 400 <= mlb_data.status_code <= 499: return None - if 'allplays' in mlb_data.data and mlb_data.data['allplays']: + if 'allPlays' in mlb_data.data and mlb_data.data['allPlays']: return Plays(**mlb_data.data) def get_game_line_score(self, game_id: int, **params) -> Union[Linescore, None]: @@ -1095,7 +1095,7 @@ def get_game_ids(self, date: str = None, if 'dates' in mlb_data.data and mlb_data.data['dates']: for date in mlb_data.data['dates']: for game in date['games']: - game_ids.append(game.gamepk) + game_ids.append(game['gamePk']) return game_ids @@ -2027,7 +2027,7 @@ def get_homerun_derby(self, game_id, **params) -> Union[HomeRunDerby, None]: Parameters ---------- game_id : int - Insert gamePk to return HomerunDerby data for a specific gamepk. + Insert gamePk to return HomerunDerby data for a specific gamePk. Other Parameters ---------------- @@ -2088,7 +2088,7 @@ def get_team_stats(self, team_id: int, stats: list, groups: list, **params) -> d >>> stats = ['season', 'seasonAdvanced'] >>> groups = ['pitching'] >>> mlb.get_team_stats(133, stats, groups) - {'pitching': {'season': [PitchingSeason], 'seasonadvanced': [PitchingSeasonAdvanced] }} + {'pitching': {'season': [PitchingSeason], 'seasonAdvanced': [PitchingSeasonAdvanced] }} """ params['stats'] = stats params['group'] = groups @@ -2134,8 +2134,8 @@ def get_players_stats_for_game(self, person_id: int, game_id: int, **params) -> >>> player_id = 663728 >>> game_id = 715757 >>> stats = mlb.get_player_stats_for_game(person_id=person_id, game_id=game_id) - >>> print(stats['stats']['gamelog']) - >>> print(stats['hitting']['playlog']) + >>> print(stats['stats']['gameLog']) + >>> print(stats['hitting']['playLog']) """ mlb_data = self._mlb_adapter_v1.get(endpoint=f'people/{person_id}/stats/game/{game_id}') if 400 <= mlb_data.status_code <= 499: @@ -2166,7 +2166,7 @@ def get_player_stats(self, person_id: int, stats: list, groups: list, **params) season : str Insert year to return team stats for a particular season, season=2018 eventType : str - Notes for individual events for playLog, playlog can be filered by individual events. + Notes for individual events for playLog, playLog can be filered by individual events. List of eventTypes can be found at https://statsapi.mlb.com/api/v1/eventTypes Returns @@ -2186,7 +2186,7 @@ def get_player_stats(self, person_id: int, stats: list, groups: list, **params) >>> stats = ['season', 'seasonAdvanced'] >>> groups = ['hitting'] >>> mlb.get_player_stats(647351, stats, groups) - {'hitting': {'season': [HittingSeason], 'seasonadvanced': [HittingSeasonAdvanced] }} + {'hitting': {'season': [HittingSeason], 'seasonAdvanced': [HittingSeasonAdvanced] }} """ params['stats'] = stats params['group'] = groups @@ -2262,4 +2262,3 @@ def get_stats(self, stats: list, groups: list, **params: dict) -> dict: return splits # This is to test pypi, please delete later - diff --git a/mlbstatsapi/mlb_dataadapter.py b/mlbstatsapi/mlb_dataadapter.py index d490ac77..8648fa6c 100644 --- a/mlbstatsapi/mlb_dataadapter.py +++ b/mlbstatsapi/mlb_dataadapter.py @@ -1,4 +1,4 @@ -from typing import Dict, List +from typing import Dict from .exceptions import TheMlbStatsApiException import requests import logging @@ -46,39 +46,6 @@ def __init__(self, hostname: str = 'statsapi.mlb.com', ver: str = 'v1', logger: self._logger = logger or logging.getLogger(__name__) self._logger.setLevel(logging.DEBUG) - def _transform_keys_in_data(self, data) -> dict: - """ - Recursivly transform all the keys in a dictionary to lowercase - - Parameters - ---------- - data : dict - MlbResult data dictionary - - Returns - ------- - dict - """ - - if isinstance(data, Dict): - lowered_dict = {} - - for key, value in data.items(): - lowered_dict[key.lower()] = self._transform_keys_in_data(value) - - return lowered_dict - - elif isinstance(data, List): - lowered_list = [] - - for item in data: - lowered_list.append(self._transform_keys_in_data(item)) - - return lowered_list - - else: - return data - def get(self, endpoint: str, ep_params: Dict = None, data: Dict = None) -> MlbResult: """ return a MlbResult from endpoint @@ -98,7 +65,6 @@ def get(self, endpoint: str, ep_params: Dict = None, data: Dict = None) -> MlbRe """ full_url = self.url + endpoint - print (full_url) logline_pre = f'url={full_url}' logline_post = " ,".join((logline_pre, 'success={}, status_code={}, message={}, url={}')) @@ -121,7 +87,6 @@ def get(self, endpoint: str, ep_params: Dict = None, data: Dict = None) -> MlbRe self._logger.debug(msg=logline_post.format('success', response.status_code, response.reason, response.url)) - data = self._transform_keys_in_data(data) return MlbResult(response.status_code, message=response.reason, data=data) elif response.status_code >= 400 and response.status_code <= 499: diff --git a/mlbstatsapi/mlb_module.py b/mlbstatsapi/mlb_module.py index 72f6877a..7b1c3193 100644 --- a/mlbstatsapi/mlb_module.py +++ b/mlbstatsapi/mlb_module.py @@ -114,14 +114,14 @@ def create_split_data(stat_data: dict) -> dict: if 'splits' in stat and stat['splits']: split_data = return_splits(stat['splits'], stat_type, stat_group) stat_object = Stat(group=stat_group, type=stat_type, - totalsplits=total_splits, splits=split_data) + totalSplits=total_splits, splits=split_data) else: continue if stat_group not in stats: stats[stat_group] = {} - stats[stat_group][stat_type.lower()] = stat_object + stats[stat_group][stat_type] = stat_object return stats @@ -137,14 +137,14 @@ def get_stat_attributes(stats) -> str: ------- (stat_type, stat_group) """ - if 'type' in stats and 'displayname' in stats['type']: - stat_type = stats['type']['displayname'] + if 'type' in stats and 'displayName' in stats['type']: + stat_type = stats['type']['displayName'] else: stat_type = 'gameLog' # default to stats if no group returned - if 'group' in stats and 'displayname' in stats['group']: - stat_group = stats['group']['displayname'] + if 'group' in stats and 'displayName' in stats['group']: + stat_group = stats['group']['displayName'] else: # if stat_type is None return None if stat_type: @@ -152,11 +152,10 @@ def get_stat_attributes(stats) -> str: else: stat_group = None - if 'totalsplits' in stats: - total_splits = stats['totalsplits'] + if 'totalSplits' in stats: + total_splits = stats['totalSplits'] else: total_splits = len(stats['splits']) return (stat_type, stat_group, total_splits) - diff --git a/mlbstatsapi/models/attendances/attendance.py b/mlbstatsapi/models/attendances/attendance.py index c611c9b8..f31f25b5 100644 --- a/mlbstatsapi/models/attendances/attendance.py +++ b/mlbstatsapi/models/attendances/attendance.py @@ -15,5 +15,5 @@ class Attendance(MLBBaseModel): aggregate_totals : AttendanceTotals Attendance aggregate total numbers for query. """ - aggregate_totals: AttendanceTotals = Field(alias="aggregatetotals") + aggregate_totals: AttendanceTotals = Field(alias="aggregateTotals") records: List[AttendanceRecords] = [] diff --git a/mlbstatsapi/models/attendances/attributes.py b/mlbstatsapi/models/attendances/attributes.py index bdc32510..c9fc9a17 100644 --- a/mlbstatsapi/models/attendances/attributes.py +++ b/mlbstatsapi/models/attendances/attributes.py @@ -31,10 +31,10 @@ class AttendanceHighLowGame(MLBBaseModel): day_night : str Time of day for game (day or night). """ - game_pk: int = Field(alias="gamepk") + game_pk: int = Field(alias="gamePk") link: str content: AttendanceHighLowGameContent - day_night: str = Field(alias="daynight") + day_night: str = Field(alias="dayNight") class AttendanceGameType(MLBBaseModel): @@ -105,29 +105,29 @@ class AttendanceRecords(MLBBaseModel): team : Team Team. """ - openings_total: int = Field(alias="openingstotal") - openings_total_away: int = Field(alias="openingstotalaway") - openings_total_home: int = Field(alias="openingstotalhome") - openings_total_lost: int = Field(alias="openingstotallost") - games_total: int = Field(alias="gamestotal") - games_away_total: int = Field(alias="gamesawaytotal") - games_home_total: int = Field(alias="gameshometotal") + openings_total: int = Field(alias="openingsTotal") + openings_total_away: int = Field(alias="openingsTotalAway") + openings_total_home: int = Field(alias="openingsTotalHome") + openings_total_lost: int = Field(alias="openingsTotalLost") + games_total: int = Field(alias="gamesTotal") + games_away_total: int = Field(alias="gamesAwayTotal") + games_home_total: int = Field(alias="gamesHomeTotal") year: str - attendance_average_ytd: int = Field(alias="attendanceaverageytd") - game_type: AttendanceGameType = Field(alias="gametype") + attendance_average_ytd: int = Field(alias="attendanceAverageYtd") + game_type: AttendanceGameType = Field(alias="gameType") team: Team - attendance_total: Optional[int] = Field(default=None, alias="attendancetotal") - attendance_average_away: Optional[int] = Field(default=None, alias="attendanceaverageaway") - attendance_average_home: Optional[int] = Field(default=None, alias="attendanceaveragehome") - attendance_high: Optional[int] = Field(default=None, alias="attendancehigh") - attendance_high_date: Optional[str] = Field(default=None, alias="attendancehighdate") - attendance_high_game: Optional[AttendanceHighLowGame] = Field(default=None, alias="attendancehighgame") - attendance_low: Optional[int] = Field(default=None, alias="attendancelow") - attendance_low_date: Optional[str] = Field(default=None, alias="attendancelowdate") - attendance_low_game: Optional[AttendanceHighLowGame] = Field(default=None, alias="attendancelowgame") - attendance_total_away: Optional[int] = Field(default=None, alias="attendancetotalaway") - attendance_total_home: Optional[int] = Field(default=None, alias="attendancetotalhome") - attendance_opening_average: Optional[int] = Field(default=None, alias="attendanceopeningaverage") + attendance_total: Optional[int] = Field(default=None, alias="attendanceTotal") + attendance_average_away: Optional[int] = Field(default=None, alias="attendanceAverageAway") + attendance_average_home: Optional[int] = Field(default=None, alias="attendanceAverageHome") + attendance_high: Optional[int] = Field(default=None, alias="attendanceHigh") + attendance_high_date: Optional[str] = Field(default=None, alias="attendanceHighDate") + attendance_high_game: Optional[AttendanceHighLowGame] = Field(default=None, alias="attendanceHighGame") + attendance_low: Optional[int] = Field(default=None, alias="attendanceLow") + attendance_low_date: Optional[str] = Field(default=None, alias="attendanceLowDate") + attendance_low_game: Optional[AttendanceHighLowGame] = Field(default=None, alias="attendanceLowGame") + attendance_total_away: Optional[int] = Field(default=None, alias="attendanceTotalAway") + attendance_total_home: Optional[int] = Field(default=None, alias="attendanceTotalHome") + attendance_opening_average: Optional[int] = Field(default=None, alias="attendanceOpeningAverage") class AttendanceTotals(MLBBaseModel): @@ -161,15 +161,15 @@ class AttendanceTotals(MLBBaseModel): attendance_total_home : int Attendance total home. """ - openings_total_away: int = Field(alias="openingstotalaway") - openings_total_home: int = Field(alias="openingstotalhome") - openings_total_lost: int = Field(alias="openingstotallost") - openings_total_ytd: int = Field(alias="openingstotalytd") - attendance_average_ytd: int = Field(alias="attendanceaverageytd") - attendance_high: int = Field(alias="attendancehigh") - attendance_high_date: str = Field(alias="attendancehighdate") - attendance_total: int = Field(alias="attendancetotal") - attendance_total_away: int = Field(alias="attendancetotalaway") - attendance_total_home: int = Field(alias="attendancetotalhome") - attendance_average_away: Optional[int] = Field(default=None, alias="attendanceaverageaway") - attendance_average_home: Optional[int] = Field(default=None, alias="attendanceaveragehome") + openings_total_away: int = Field(alias="openingsTotalAway") + openings_total_home: int = Field(alias="openingsTotalHome") + openings_total_lost: int = Field(alias="openingsTotalLost") + openings_total_ytd: int = Field(alias="openingsTotalYtd") + attendance_average_ytd: int = Field(alias="attendanceAverageYtd") + attendance_high: int = Field(alias="attendanceHigh") + attendance_high_date: str = Field(alias="attendanceHighDate") + attendance_total: int = Field(alias="attendanceTotal") + attendance_total_away: int = Field(alias="attendanceTotalAway") + attendance_total_home: int = Field(alias="attendanceTotalHome") + attendance_average_away: Optional[int] = Field(default=None, alias="attendanceAverageAway") + attendance_average_home: Optional[int] = Field(default=None, alias="attendanceAverageHome") diff --git a/mlbstatsapi/models/base.py b/mlbstatsapi/models/base.py index 171109dd..c438f9b9 100644 --- a/mlbstatsapi/models/base.py +++ b/mlbstatsapi/models/base.py @@ -1,6 +1,13 @@ from pydantic import BaseModel, ConfigDict +def to_camel_case(value: str) -> str: + parts = value.split("_") + if not parts: + return value + return parts[0] + "".join(part[:1].upper() + part[1:] for part in parts[1:]) + + class MLBBaseModel(BaseModel): """Common base for all MLB Stats API models. @@ -11,5 +18,6 @@ class MLBBaseModel(BaseModel): model_config = ConfigDict( extra="ignore", + alias_generator=to_camel_case, populate_by_name=True, ) diff --git a/mlbstatsapi/models/data/data.py b/mlbstatsapi/models/data/data.py index 6ca24987..53e94806 100644 --- a/mlbstatsapi/models/data/data.py +++ b/mlbstatsapi/models/data/data.py @@ -28,14 +28,14 @@ class PitchBreak(MLBBaseModel): spin_direction : float Pitch spin direction. """ - break_angle: Optional[float] = Field(default=None, alias="breakangle") - break_vertical: Optional[float] = Field(default=None, alias="breakvertical") - break_vertical_induced: Optional[float] = Field(default=None, alias="breakverticalinduced") - break_horizontal: Optional[float] = Field(default=None, alias="breakhorizontal") - spin_rate: Optional[float] = Field(default=None, alias="spinrate") - spin_direction: Optional[float] = Field(default=None, alias="spindirection") - break_length: Optional[float] = Field(default=None, alias="breaklength") - break_y: Optional[float] = Field(default=None, alias="breaky") + break_angle: Optional[float] = Field(default=None, alias="breakAngle") + break_vertical: Optional[float] = Field(default=None, alias="breakVertical") + break_vertical_induced: Optional[float] = Field(default=None, alias="breakVerticalInduced") + break_horizontal: Optional[float] = Field(default=None, alias="breakHorizontal") + spin_rate: Optional[float] = Field(default=None, alias="spinRate") + spin_direction: Optional[float] = Field(default=None, alias="spinDirection") + break_length: Optional[float] = Field(default=None, alias="breakLength") + break_y: Optional[float] = Field(default=None, alias="breakY") class PitchCoordinates(MLBBaseModel): @@ -79,13 +79,13 @@ class PitchCoordinates(MLBBaseModel): """ ay: Optional[float] = None az: Optional[float] = None - pfx_x: Optional[float] = Field(default=None, alias="pfxx") - pfx_z: Optional[float] = Field(default=None, alias="pfxz") - p_x: Optional[float] = Field(default=None, alias="px") - p_z: Optional[float] = Field(default=None, alias="pz") - v_x0: Optional[float] = Field(default=None, alias="vx0") - v_y0: Optional[float] = Field(default=None, alias="vy0") - v_z0: Optional[float] = Field(default=None, alias="vz0") + pfx_x: Optional[float] = Field(default=None, alias="pfxX") + pfx_z: Optional[float] = Field(default=None, alias="pfxZ") + p_x: Optional[float] = Field(default=None, alias="pX") + p_z: Optional[float] = Field(default=None, alias="pZ") + v_x0: Optional[float] = Field(default=None, alias="vX0") + v_y0: Optional[float] = Field(default=None, alias="vY0") + v_z0: Optional[float] = Field(default=None, alias="vZ0") x0: Optional[float] = None y0: Optional[float] = None z0: Optional[float] = None @@ -125,18 +125,18 @@ class PitchData(MLBBaseModel): strike_zone_depth : float The depth of the strike zone. """ - strike_zone_top: float = Field(alias="strikezonetop") - strike_zone_bottom: float = Field(alias="strikezonebottom") + strike_zone_top: float = Field(alias="strikeZoneTop") + strike_zone_bottom: float = Field(alias="strikeZoneBottom") breaks: PitchBreak coordinates: Optional[PitchCoordinates] = None extension: Optional[float] = None - start_speed: Optional[float] = Field(default=None, alias="startspeed") - end_speed: Optional[float] = Field(default=None, alias="endspeed") + start_speed: Optional[float] = Field(default=None, alias="startSpeed") + end_speed: Optional[float] = Field(default=None, alias="endSpeed") zone: Optional[float] = None - type_confidence: Optional[float] = Field(default=None, alias="typeconfidence") - plate_time: Optional[float] = Field(default=None, alias="platetime") - strike_zone_width: Optional[float] = Field(default=None, alias="strikezonewidth") - strike_zone_depth: Optional[float] = Field(default=None, alias="strikezonedepth") + type_confidence: Optional[float] = Field(default=None, alias="typeConfidence") + plate_time: Optional[float] = Field(default=None, alias="plateTime") + strike_zone_width: Optional[float] = Field(default=None, alias="strikeZoneWidth") + strike_zone_depth: Optional[float] = Field(default=None, alias="strikeZoneDepth") class HitCoordinates(MLBBaseModel): @@ -150,8 +150,8 @@ class HitCoordinates(MLBBaseModel): coord_y : float Y coordinate for hit. """ - coord_x: Optional[float] = Field(default=None, alias="coordx") - coord_y: Optional[float] = Field(default=None, alias="coordy") + coord_x: Optional[float] = Field(default=None, alias="coordX") + coord_y: Optional[float] = Field(default=None, alias="coordY") @property def x(self): @@ -187,9 +187,9 @@ class HitData(MLBBaseModel): trajectory: Optional[str] = None hardness: Optional[str] = None location: Optional[int] = None - launch_speed: Optional[float] = Field(default=None, alias="launchspeed") - launch_angle: Optional[float] = Field(default=None, alias="launchangle") - total_distance: Optional[float] = Field(default=None, alias="totaldistance") + launch_speed: Optional[float] = Field(default=None, alias="launchSpeed") + launch_angle: Optional[float] = Field(default=None, alias="launchAngle") + total_distance: Optional[float] = Field(default=None, alias="totalDistance") class CodeDesc(MLBBaseModel): @@ -252,10 +252,10 @@ class Count(MLBBaseModel): outs: int strikes: int inning: Optional[int] = None - runner_on_1b: Optional[bool] = Field(default=None, alias="runneron1b") - runner_on_2b: Optional[bool] = Field(default=None, alias="runneron2b") - runner_on_3b: Optional[bool] = Field(default=None, alias="runneron3b") - is_top_inning: Optional[bool] = Field(default=None, alias="istopinning") + runner_on_1b: Optional[bool] = Field(default=None, alias="runnerOn1b") + runner_on_2b: Optional[bool] = Field(default=None, alias="runnerOn2b") + runner_on_3b: Optional[bool] = Field(default=None, alias="runnerOn3b") + is_top_inning: Optional[bool] = Field(default=None, alias="isTopInning") class PlayDetails(MLBBaseModel): @@ -294,29 +294,29 @@ class PlayDetails(MLBBaseModel): From catcher flag. """ call: Optional[CodeDesc] = None - is_in_play: Optional[bool] = Field(default=None, alias="isinplay") - is_strike: Optional[bool] = Field(default=None, alias="isstrike") - is_scoring_play: Optional[bool] = Field(default=None, alias="isscoringplay") - is_out: Optional[bool] = Field(default=None, alias="isout") - runner_going: Optional[bool] = Field(default=None, alias="runnergoing") - is_ball: Optional[bool] = Field(default=None, alias="isball") - is_base_hit: Optional[bool] = Field(default=None, alias="isbasehit") - is_at_bat: Optional[bool] = Field(default=None, alias="isatbat") - is_plate_appearance: Optional[bool] = Field(default=None, alias="isplateappearance") - bat_side: Optional[CodeDesc] = Field(default=None, alias="batside") - pitch_hand: Optional[CodeDesc] = Field(default=None, alias="pitchhand") - event_type: Optional[str] = Field(default=None, alias="eventtype") + is_in_play: Optional[bool] = Field(default=None, alias="isInPlay") + is_strike: Optional[bool] = Field(default=None, alias="isStrike") + is_scoring_play: Optional[bool] = Field(default=None, alias="isScoringPlay") + is_out: Optional[bool] = Field(default=None, alias="isOut") + runner_going: Optional[bool] = Field(default=None, alias="runnerGoing") + is_ball: Optional[bool] = Field(default=None, alias="isBall") + is_base_hit: Optional[bool] = Field(default=None, alias="isBaseHit") + is_at_bat: Optional[bool] = Field(default=None, alias="isAtBat") + is_plate_appearance: Optional[bool] = Field(default=None, alias="isPlateAppearance") + bat_side: Optional[CodeDesc] = Field(default=None, alias="batSide") + pitch_hand: Optional[CodeDesc] = Field(default=None, alias="pitchHand") + event_type: Optional[str] = Field(default=None, alias="eventType") event: Optional[str] = None description: Optional[str] = None type: Optional[CodeDesc] = None - away_score: Optional[int] = Field(default=None, alias="awayscore") - home_score: Optional[int] = Field(default=None, alias="homescore") - has_review: Optional[bool] = Field(default=None, alias="hasreview") + away_score: Optional[int] = Field(default=None, alias="awayScore") + home_score: Optional[int] = Field(default=None, alias="homeScore") + has_review: Optional[bool] = Field(default=None, alias="hasReview") code: Optional[str] = None - ball_color: Optional[str] = Field(default=None, alias="ballcolor") - trail_color: Optional[str] = Field(default=None, alias="trailcolor") - from_catcher: Optional[bool] = Field(default=None, alias="fromcatcher") - disengagement_num: Optional[int] = Field(default=None, alias="disengagementnum") + ball_color: Optional[str] = Field(default=None, alias="ballColor") + trail_color: Optional[str] = Field(default=None, alias="trailColor") + from_catcher: Optional[bool] = Field(default=None, alias="fromCatcher") + disengagement_num: Optional[int] = Field(default=None, alias="disengagementNum") violation: Optional[Violation] = None @field_validator('bat_side', 'pitch_hand', 'type', 'call', 'violation', mode='before') diff --git a/mlbstatsapi/models/divisions/division.py b/mlbstatsapi/models/divisions/division.py index bedcd885..d05569f3 100644 --- a/mlbstatsapi/models/divisions/division.py +++ b/mlbstatsapi/models/divisions/division.py @@ -43,13 +43,13 @@ class Division(MLBBaseModel): link: str name: Optional[str] = None season: Optional[str] = None - name_short: Optional[str] = Field(default=None, alias="nameshort") + name_short: Optional[str] = Field(default=None, alias="nameShort") abbreviation: Optional[str] = None league: Optional[League] = None sport: Optional[Sport] = None - has_wildcard: Optional[bool] = Field(default=None, alias="haswildcard") - sort_order: Optional[int] = Field(default=None, alias="sortorder") - num_playoff_teams: Optional[int] = Field(default=None, alias="numplayoffteams") + has_wildcard: Optional[bool] = Field(default=None, alias="hasWildcard") + sort_order: Optional[int] = Field(default=None, alias="sortOrder") + num_playoff_teams: Optional[int] = Field(default=None, alias="numPlayoffTeams") active: Optional[bool] = None model_config = {"arbitrary_types_allowed": True} diff --git a/mlbstatsapi/models/drafts/attributes.py b/mlbstatsapi/models/drafts/attributes.py index 460bff0f..bba7f16b 100644 --- a/mlbstatsapi/models/drafts/attributes.py +++ b/mlbstatsapi/models/drafts/attributes.py @@ -41,5 +41,5 @@ class DraftSchool(MLBBaseModel): name: str country: str state: Optional[str] = None - school_class: Optional[str] = Field(default=None, alias="schoolclass") + school_class: Optional[str] = Field(default=None, alias="schoolClass") city: Optional[str] = None diff --git a/mlbstatsapi/models/drafts/rounds.py b/mlbstatsapi/models/drafts/rounds.py index 90b54ca6..3fdae987 100644 --- a/mlbstatsapi/models/drafts/rounds.py +++ b/mlbstatsapi/models/drafts/rounds.py @@ -53,23 +53,23 @@ class DraftPick(MLBBaseModel): A brief summary of the player's background and accomplishments. """ team: Team - draft_type: CodeDesc = Field(alias="drafttype") - is_drafted: bool = Field(alias="isdrafted") - is_pass: bool = Field(alias="ispass") + draft_type: CodeDesc = Field(alias="draftType") + is_drafted: bool = Field(alias="isDrafted") + is_pass: bool = Field(alias="isPass") year: str school: DraftSchool home: DraftHome - pick_round: str = Field(alias="pickround") - pick_number: int = Field(alias="picknumber") - display_pick_number: int = Field(alias="displaypicknumber") - round_pick_number: int = Field(alias="roundpicknumber") - headshot_link: Optional[str] = Field(default=None, alias="headshotlink") + pick_round: str = Field(alias="pickRound") + pick_number: int = Field(alias="pickNumber") + display_pick_number: int = Field(alias="displayPickNumber") + round_pick_number: int = Field(alias="roundPickNumber") + headshot_link: Optional[str] = Field(default=None, alias="headshotLink") person: Optional[Person] = None - bis_player_id: Optional[int] = Field(default=None, alias="bisplayerid") + bis_player_id: Optional[int] = Field(default=None, alias="bisPlayerId") rank: Optional[int] = None - pick_value: Optional[str] = Field(default=None, alias="pickvalue") - signing_bonus: Optional[str] = Field(default=None, alias="signingbonus") - scouting_report: Optional[str] = Field(default=None, alias="scoutingreport") + pick_value: Optional[str] = Field(default=None, alias="pickValue") + signing_bonus: Optional[str] = Field(default=None, alias="signingBonus") + scouting_report: Optional[str] = Field(default=None, alias="scoutingReport") blurb: Optional[str] = None diff --git a/mlbstatsapi/models/game/attributes.py b/mlbstatsapi/models/game/attributes.py index 26e45fcb..fb69d7d3 100644 --- a/mlbstatsapi/models/game/attributes.py +++ b/mlbstatsapi/models/game/attributes.py @@ -19,6 +19,6 @@ class MetaData(MLBBaseModel): Current logical events for this game. """ wait: int - timestamp: str - game_events: List[str] = Field(alias="gameevents") - logical_events: List[str] = Field(alias="logicalevents") + timestamp: str = Field(alias="timeStamp") + game_events: List[str] = Field(alias="gameEvents") + logical_events: List[str] = Field(alias="logicalEvents") diff --git a/mlbstatsapi/models/game/game.py b/mlbstatsapi/models/game/game.py index 73ba6cf1..f29580a3 100644 --- a/mlbstatsapi/models/game/game.py +++ b/mlbstatsapi/models/game/game.py @@ -23,11 +23,11 @@ class Game(MLBBaseModel): live_data : LiveData Live data of this game. """ - game_pk: int = Field(alias="gamepk") + game_pk: int = Field(alias="gamePk") link: str - metadata: Optional[MetaData] = None - game_data: Optional[GameData] = Field(default=None, alias="gamedata") - live_data: Optional[LiveData] = Field(default=None, alias="livedata") + metadata: Optional[MetaData] = Field(default=None, alias="metaData") + game_data: Optional[GameData] = Field(default=None, alias="gameData") + live_data: Optional[LiveData] = Field(default=None, alias="liveData") @property def id(self) -> int: diff --git a/mlbstatsapi/models/game/gamedata/attributes.py b/mlbstatsapi/models/game/gamedata/attributes.py index f3f81e13..8d0ea9e4 100644 --- a/mlbstatsapi/models/game/gamedata/attributes.py +++ b/mlbstatsapi/models/game/gamedata/attributes.py @@ -34,14 +34,14 @@ class GameDataGame(MLBBaseModel): """ pk: int type: str - double_header: str = Field(alias="doubleheader") + double_header: str = Field(alias="doubleHeader") id: str - gameday_type: str = Field(alias="gamedaytype") + gameday_type: str = Field(alias="gamedayType") tiebreaker: str - game_number: int = Field(alias="gamenumber") - calendar_event_id: str = Field(alias="calendareventid") + game_number: int = Field(alias="gameNumber") + calendar_event_id: Optional[str] = Field(default=None, alias="calendarEventId") season: str - season_display: str = Field(alias="seasondisplay") + season_display: str = Field(alias="seasonDisplay") class GameDatetime(MLBBaseModel): @@ -71,16 +71,16 @@ class GameDatetime(MLBBaseModel): resumed_from_datetime : str Resumed from datetime if applicable. """ - datetime: str - original_date: str = Field(alias="originaldate") - official_date: str = Field(alias="officialdate") - day_night: str = Field(alias="daynight") + datetime: str = Field(alias="dateTime") + original_date: str = Field(alias="originalDate") + official_date: str = Field(alias="officialDate") + day_night: str = Field(alias="dayNight") time: str ampm: str - resume_date: Optional[str] = Field(default=None, alias="resumedate") - resume_datetime: Optional[str] = Field(default=None, alias="resumedatetime") - resumed_from_date: Optional[str] = Field(default=None, alias="resumedfromdate") - resumed_from_datetime: Optional[str] = Field(default=None, alias="resumedfromdatetime") + resume_date: Optional[str] = Field(default=None, alias="resumeDate") + resume_datetime: Optional[str] = Field(default=None, alias="resumeDatetime") + resumed_from_date: Optional[str] = Field(default=None, alias="resumedFromDate") + resumed_from_datetime: Optional[str] = Field(default=None, alias="resumedFromDatetime") class GameStatus(MLBBaseModel): @@ -104,12 +104,12 @@ class GameStatus(MLBBaseModel): reason : str Reason for a state. Usually used for delays or cancellations. """ - abstract_game_state: str = Field(alias="abstractgamestate") - coded_game_state: str = Field(alias="codedgamestate") - detailed_state: str = Field(alias="detailedstate") - status_code: str = Field(alias="statuscode") - start_time_tbd: bool = Field(alias="starttimetbd") - abstract_game_code: str = Field(alias="abstractgamecode") + abstract_game_state: str = Field(alias="abstractGameState") + coded_game_state: str = Field(alias="codedGameState") + detailed_state: str = Field(alias="detailedState") + status_code: str = Field(alias="statusCode") + start_time_tbd: Optional[bool] = Field(default=None, alias="startTimeTbd") + abstract_game_code: str = Field(alias="abstractGameCode") reason: Optional[str] = None @@ -161,10 +161,10 @@ class GameInfo(MLBBaseModel): delay_duration_minutes : int The length of delay for the game in minutes. """ - first_pitch: str = Field(alias="firstpitch") + first_pitch: str = Field(alias="firstPitch") attendance: Optional[int] = None - game_duration_minutes: Optional[int] = Field(default=None, alias="gamedurationminutes") - delay_duration_minutes: Optional[int] = Field(default=None, alias="delaydurationminutes") + game_duration_minutes: Optional[int] = Field(default=None, alias="gameDurationMinutes") + delay_duration_minutes: Optional[int] = Field(default=None, alias="delayDurationMinutes") class ReviewInfo(MLBBaseModel): @@ -195,7 +195,7 @@ class GameReview(MLBBaseModel): home : ReviewInfo Home team review info. """ - has_challenges: bool = Field(alias="haschallenges") + has_challenges: bool = Field(alias="hasChallenges") away: ReviewInfo home: ReviewInfo @@ -219,12 +219,12 @@ class GameFlags(MLBBaseModel): home_team_perfect_game : bool If the home team has a perfect game. """ - no_hitter: bool = Field(alias="nohitter") - perfect_game: bool = Field(alias="perfectgame") - away_team_no_hitter: bool = Field(alias="awayteamnohitter") - away_team_perfect_game: bool = Field(alias="awayteamperfectgame") - home_team_no_hitter: bool = Field(alias="hometeamnohitter") - home_team_perfect_game: bool = Field(alias="hometeamperfectgame") + no_hitter: bool = Field(alias="noHitter") + perfect_game: bool = Field(alias="perfectGame") + away_team_no_hitter: bool = Field(alias="awayTeamNoHitter") + away_team_perfect_game: bool = Field(alias="awayTeamPerfectGame") + home_team_no_hitter: bool = Field(alias="homeTeamNoHitter") + home_team_perfect_game: bool = Field(alias="homeTeamPerfectGame") class GameProbablePitchers(MLBBaseModel): diff --git a/mlbstatsapi/models/game/gamedata/gamedata.py b/mlbstatsapi/models/game/gamedata/gamedata.py index 71e3b148..42753364 100644 --- a/mlbstatsapi/models/game/gamedata/gamedata.py +++ b/mlbstatsapi/models/game/gamedata/gamedata.py @@ -66,18 +66,18 @@ class GameData(MLBBaseModel): teams: GameTeams players: List[Person] = [] venue: Venue - official_venue: Venue = Field(alias="officialvenue") + official_venue: Venue = Field(alias="officialVenue") review: GameReview flags: GameFlags alerts: List = [] - probable_pitchers: GameProbablePitchers = Field(alias="probablepitchers") - mound_visits: Optional[MoundVisits] = Field(default=None, alias="moundvisits") - game_info: Optional[GameInfo] = Field(default=None, alias="gameinfo") + probable_pitchers: GameProbablePitchers = Field(alias="probablePitchers") + mound_visits: Optional[MoundVisits] = Field(default=None, alias="moundVisits") + game_info: Optional[GameInfo] = Field(default=None, alias="gameInfo") weather: Optional[GameWeather] = None - official_scorer: Optional[Person] = Field(default=None, alias="officialscorer") - primary_data_caster: Optional[Person] = Field(default=None, alias="primarydatacaster") - secondary_data_caster: Optional[Person] = Field(default=None, alias="secondarydatacaster") - abs_challenges: Optional[List[dict]] = Field(default=None, alias="abschallenges") + official_scorer: Optional[Person] = Field(default=None, alias="officialScorer") + primary_data_caster: Optional[Person] = Field(default=None, alias="primaryDataCaster") + secondary_data_caster: Optional[Person] = Field(default=None, alias="secondaryDataCaster") + abs_challenges: Optional[List[dict]] = Field(default=None, alias="absChallenges") @model_validator(mode='before') @classmethod diff --git a/mlbstatsapi/models/game/livedata/attributes.py b/mlbstatsapi/models/game/livedata/attributes.py index 88c22d30..3adab4e9 100644 --- a/mlbstatsapi/models/game/livedata/attributes.py +++ b/mlbstatsapi/models/game/livedata/attributes.py @@ -36,6 +36,6 @@ class GameLeaders(MLBBaseModel): pitch_speed : dict Pitch speed leaders. """ - hit_distance: dict = Field(alias="hitdistance") - hit_speed: dict = Field(alias="hitspeed") - pitch_speed: dict = Field(alias="pitchspeed") + hit_distance: dict = Field(alias="hitDistance") + hit_speed: dict = Field(alias="hitSpeed") + pitch_speed: dict = Field(alias="pitchSpeed") diff --git a/mlbstatsapi/models/game/livedata/boxscore/attributes.py b/mlbstatsapi/models/game/livedata/boxscore/attributes.py index 0806d7f7..ab943842 100644 --- a/mlbstatsapi/models/game/livedata/boxscore/attributes.py +++ b/mlbstatsapi/models/game/livedata/boxscore/attributes.py @@ -33,7 +33,7 @@ class BoxScoreTeamInfo(MLBBaseModel): List holding the info for this info type. """ title: str - field_list: List[BoxScoreVL] = Field(alias="fieldlist") + field_list: List[BoxScoreVL] = Field(alias="fieldList") class BoxScoreGameStatus(MLBBaseModel): @@ -51,10 +51,10 @@ class BoxScoreGameStatus(MLBBaseModel): is_substitute : bool Whether the player is a substitute. """ - is_current_batter: bool = Field(alias="iscurrentbatter") - is_current_pitcher: bool = Field(alias="iscurrentpitcher") - is_on_bench: bool = Field(alias="isonbench") - is_substitute: bool = Field(alias="issubstitute") + is_current_batter: bool = Field(alias="isCurrentBatter") + is_current_pitcher: bool = Field(alias="isCurrentPitcher") + is_on_bench: bool = Field(alias="isOnBench") + is_substitute: bool = Field(alias="isSubstitute") class PlayersDictPerson(MLBBaseModel): @@ -87,13 +87,13 @@ class PlayersDictPerson(MLBBaseModel): person: Person status: CodeDesc stats: dict - season_stats: dict = Field(alias="seasonstats") - game_status: BoxScoreGameStatus = Field(alias="gamestatus") + season_stats: dict = Field(alias="seasonStats") + game_status: BoxScoreGameStatus = Field(alias="gameStatus") position: Optional[Position] = None - batting_order: Optional[int] = Field(default=None, alias="battingorder") - jersey_number: Optional[str] = Field(default=None, alias="jerseynumber") - parent_team_id: Optional[int] = Field(default=None, alias="parentteamid") - all_positions: Optional[List[Position]] = Field(default=None, alias="allpositions") + batting_order: Optional[int] = Field(default=None, alias="battingOrder") + jersey_number: Optional[str] = Field(default=None, alias="jerseyNumber") + parent_team_id: Optional[int] = Field(default=None, alias="parentTeamId") + all_positions: Optional[List[Position]] = Field(default=None, alias="allPositions") class BoxScoreTeam(MLBBaseModel): @@ -124,13 +124,13 @@ class BoxScoreTeam(MLBBaseModel): Team notes. """ team: Team - team_stats: dict = Field(alias="teamstats") + team_stats: dict = Field(alias="teamStats") players: Dict[str, PlayersDictPerson] batters: List[int] pitchers: List[int] bench: List[int] bullpen: List[int] - batting_order: List[int] = Field(alias="battingorder") + batting_order: List[int] = Field(alias="battingOrder") info: List[BoxScoreTeamInfo] note: List[BoxScoreVL] = [] @@ -162,4 +162,4 @@ class BoxScoreOfficial(MLBBaseModel): What type of official this person is. """ official: Person - official_type: str = Field(alias="officialtype") + official_type: str = Field(alias="officialType") diff --git a/mlbstatsapi/models/game/livedata/boxscore/boxscore.py b/mlbstatsapi/models/game/livedata/boxscore/boxscore.py index c906852e..da964600 100644 --- a/mlbstatsapi/models/game/livedata/boxscore/boxscore.py +++ b/mlbstatsapi/models/game/livedata/boxscore/boxscore.py @@ -23,9 +23,9 @@ class TopPerformer(MLBBaseModel): """ player: PlayersDictPerson type: str - game_score: int = Field(alias="gamescore") - hitting_game_score: Optional[int] = Field(default=None, alias="hittinggamescore") - pitching_game_score: Optional[int] = Field(default=None, alias="pitchinggamescore") + game_score: int = Field(alias="gameScore") + hitting_game_score: Optional[int] = Field(default=None, alias="hittingGameScore") + pitching_game_score: Optional[int] = Field(default=None, alias="pitchingGameScore") class BoxScore(MLBBaseModel): @@ -48,5 +48,5 @@ class BoxScore(MLBBaseModel): teams: BoxScoreTeams officials: List[BoxScoreOfficial] = [] info: List[BoxScoreVL] = [] - pitching_notes: List[str] = Field(default=[], alias="pitchingnotes") - top_performers: List[TopPerformer] = Field(default=[], alias="topperformers") + pitching_notes: List[str] = Field(default=[], alias="pitchingNotes") + top_performers: List[TopPerformer] = Field(default=[], alias="topPerformers") diff --git a/mlbstatsapi/models/game/livedata/linescore/attributes.py b/mlbstatsapi/models/game/livedata/linescore/attributes.py index 429a3b99..68fbe7d6 100644 --- a/mlbstatsapi/models/game/livedata/linescore/attributes.py +++ b/mlbstatsapi/models/game/livedata/linescore/attributes.py @@ -24,9 +24,9 @@ class LinescoreTeamScoring(MLBBaseModel): """ hits: int errors: int - left_on_base: int = Field(alias="leftonbase") + left_on_base: int = Field(alias="leftOnBase") runs: Optional[int] = None - is_winner: Optional[bool] = Field(default=None, alias="iswinner") + is_winner: Optional[bool] = Field(default=None, alias="isWinner") class LinescoreInning(MLBBaseModel): @@ -45,7 +45,7 @@ class LinescoreInning(MLBBaseModel): Away team inning info. """ num: int - ordinal_num: str = Field(alias="ordinalnum") + ordinal_num: str = Field(alias="ordinalNum") home: Optional[LinescoreTeamScoring] = None away: Optional[LinescoreTeamScoring] = None @@ -108,10 +108,10 @@ class LinescoreOffense(MLBBaseModel): """ team: Team batter: Optional[Person] = None - on_deck: Optional[Person] = Field(default=None, alias="ondeck") - in_hole: Optional[Person] = Field(default=None, alias="inhole") + on_deck: Optional[Person] = Field(default=None, alias="onDeck") + in_hole: Optional[Person] = Field(default=None, alias="inHole") pitcher: Optional[Person] = None - batting_order: Optional[int] = Field(default=None, alias="battingorder") + batting_order: Optional[int] = Field(default=None, alias="battingOrder") first: Optional[str] = None second: Optional[str] = None third: Optional[str] = None @@ -171,9 +171,9 @@ class LinescoreDefense(MLBBaseModel): center: Optional[Person] = None right: Optional[Person] = None batter: Optional[Person] = None - on_deck: Optional[Person] = Field(default=None, alias="ondeck") - in_hole: Optional[Person] = Field(default=None, alias="inhole") - batting_order: Optional[int] = Field(default=None, alias="battingorder") + on_deck: Optional[Person] = Field(default=None, alias="onDeck") + in_hole: Optional[Person] = Field(default=None, alias="inHole") + batting_order: Optional[int] = Field(default=None, alias="battingOrder") @field_validator( 'pitcher', 'catcher', 'first', 'second', 'third', 'shortstop', diff --git a/mlbstatsapi/models/game/livedata/linescore/linescore.py b/mlbstatsapi/models/game/livedata/linescore/linescore.py index fba9dc38..5e400114 100644 --- a/mlbstatsapi/models/game/livedata/linescore/linescore.py +++ b/mlbstatsapi/models/game/livedata/linescore/linescore.py @@ -44,7 +44,7 @@ class Linescore(MLBBaseModel): note : str Any note for the linescore. """ - scheduled_innings: int = Field(alias="scheduledinnings") + scheduled_innings: int = Field(alias="scheduledInnings") innings: List[LinescoreInning] = [] teams: LinescoreTeams defense: LinescoreDefense @@ -53,8 +53,8 @@ class Linescore(MLBBaseModel): strikes: Optional[int] = None outs: Optional[int] = None note: Optional[str] = None - current_inning: Optional[int] = Field(default=None, alias="currentinning") - current_inning_ordinal: Optional[str] = Field(default=None, alias="currentinningordinal") - inning_state: Optional[str] = Field(default=None, alias="inningstate") - inning_half: Optional[str] = Field(default=None, alias="inninghalf") - is_top_inning: Optional[bool] = Field(default=None, alias="istopinning") + current_inning: Optional[int] = Field(default=None, alias="currentInning") + current_inning_ordinal: Optional[str] = Field(default=None, alias="currentInningOrdinal") + inning_state: Optional[str] = Field(default=None, alias="inningState") + inning_half: Optional[str] = Field(default=None, alias="inningHalf") + is_top_inning: Optional[bool] = Field(default=None, alias="isTopInning") diff --git a/mlbstatsapi/models/game/livedata/plays/play/attributes.py b/mlbstatsapi/models/game/livedata/plays/play/attributes.py index 16cc5acc..fda0cf26 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/attributes.py +++ b/mlbstatsapi/models/game/livedata/plays/play/attributes.py @@ -32,17 +32,17 @@ class PlayAbout(MLBBaseModel): captivating_index : int What is the captivating index for this play. """ - at_bat_index: int = Field(alias="atbatindex") - half_inning: str = Field(alias="halfinning") - is_top_inning: bool = Field(alias="istopinning") + at_bat_index: int = Field(alias="atBatIndex") + half_inning: str = Field(alias="halfInning") + is_top_inning: bool = Field(alias="isTopInning") inning: int - is_complete: bool = Field(alias="iscomplete") - is_scoring_play: bool = Field(alias="isscoringplay") - has_out: bool = Field(alias="hasout") - captivating_index: int = Field(alias="captivatingindex") - end_time: Optional[str] = Field(default=None, alias="endtime") - start_time: Optional[str] = Field(default=None, alias="starttime") - has_review: Optional[bool] = Field(default=None, alias="hasreview") + is_complete: bool = Field(alias="isComplete") + is_scoring_play: bool = Field(alias="isScoringPlay") + has_out: bool = Field(alias="hasOut") + captivating_index: int = Field(alias="captivatingIndex") + end_time: Optional[str] = Field(default=None, alias="endTime") + start_time: Optional[str] = Field(default=None, alias="startTime") + has_review: Optional[bool] = Field(default=None, alias="hasReview") class PlayResult(MLBBaseModel): @@ -69,13 +69,13 @@ class PlayResult(MLBBaseModel): If the play was an out. """ type: str - away_score: int = Field(alias="awayscore") - home_score: int = Field(alias="homescore") + away_score: int = Field(alias="awayScore") + home_score: int = Field(alias="homeScore") rbi: Optional[int] = None event: Optional[str] = None - event_type: Optional[str] = Field(default=None, alias="eventtype") + event_type: Optional[str] = Field(default=None, alias="eventType") description: Optional[str] = None - is_out: Optional[bool] = Field(default=None, alias="isout") + is_out: Optional[bool] = Field(default=None, alias="isOut") class PlayReviewDetails(MLBBaseModel): @@ -95,8 +95,8 @@ class PlayReviewDetails(MLBBaseModel): additional_reviews : str Additional reviews. """ - is_overturned: bool = Field(alias="isoverturned") - in_progress: bool = Field(alias="inprogress") - review_type: str = Field(alias="reviewtype") - challenge_team_id: Optional[int] = Field(default=None, alias="challengeteamid") - additional_reviews: Optional[str] = Field(default=None, alias="additionalreviews") + is_overturned: bool = Field(alias="isOverturned") + in_progress: bool = Field(alias="inProgress") + review_type: str = Field(alias="reviewType") + challenge_team_id: Optional[int] = Field(default=None, alias="challengeTeamId") + additional_reviews: Optional[str] = Field(default=None, alias="additionalReviews") diff --git a/mlbstatsapi/models/game/livedata/plays/play/matchup/attributes.py b/mlbstatsapi/models/game/livedata/plays/play/matchup/attributes.py index e9f27b76..16cd82fa 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/matchup/attributes.py +++ b/mlbstatsapi/models/game/livedata/plays/play/matchup/attributes.py @@ -17,4 +17,4 @@ class PlayMatchupSplits(MLBBaseModel): """ batter: str pitcher: str - men_on_base: str = Field(alias="menonbase") + men_on_base: str = Field(alias="menOnBase") diff --git a/mlbstatsapi/models/game/livedata/plays/play/matchup/matchup.py b/mlbstatsapi/models/game/livedata/plays/play/matchup/matchup.py index 0ca20a2f..58396688 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/matchup/matchup.py +++ b/mlbstatsapi/models/game/livedata/plays/play/matchup/matchup.py @@ -34,17 +34,17 @@ class PlayMatchup(MLBBaseModel): Runner on third. """ batter: Person - bat_side: CodeDesc = Field(alias="batside") + bat_side: CodeDesc = Field(alias="batSide") pitcher: Person - pitch_hand: CodeDesc = Field(alias="pitchhand") - batter_hot_cold_zones: List = Field(alias="batterhotcoldzones") - pitcher_hot_cold_zones: List = Field(alias="pitcherhotcoldzones") + pitch_hand: CodeDesc = Field(alias="pitchHand") + batter_hot_cold_zones: List = Field(alias="batterHotColdZones") + pitcher_hot_cold_zones: List = Field(alias="pitcherHotColdZones") splits: PlayMatchupSplits - batter_hot_cold_zone_stats: Optional[List] = Field(default=None, alias="batterhotcoldzonestats") - pitcher_hot_cold_zone_stats: Optional[List] = Field(default=None, alias="pitcherhotcoldzonestats") - post_on_first: Optional[Person] = Field(default=None, alias="postonfirst") - post_on_second: Optional[Person] = Field(default=None, alias="postonsecond") - post_on_third: Optional[Person] = Field(default=None, alias="postonthird") + batter_hot_cold_zone_stats: Optional[List] = Field(default=None, alias="batterHotColdZoneStats") + pitcher_hot_cold_zone_stats: Optional[List] = Field(default=None, alias="pitcherHotColdZoneStats") + post_on_first: Optional[Person] = Field(default=None, alias="postOnFirst") + post_on_second: Optional[Person] = Field(default=None, alias="postOnSecond") + post_on_third: Optional[Person] = Field(default=None, alias="postOnThird") @field_validator('batter_hot_cold_zone_stats', 'pitcher_hot_cold_zone_stats', mode='before') @classmethod diff --git a/mlbstatsapi/models/game/livedata/plays/play/play.py b/mlbstatsapi/models/game/livedata/plays/play/play.py index 999feedb..94d6db5f 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/play.py +++ b/mlbstatsapi/models/game/livedata/plays/play/play.py @@ -43,11 +43,11 @@ class Play(MLBBaseModel): about: PlayAbout count: Count matchup: PlayMatchup - pitch_index: List[int] = Field(alias="pitchindex") - action_index: List[int] = Field(alias="actionindex") - runner_index: List[int] = Field(alias="runnerindex") + pitch_index: List[int] = Field(alias="pitchIndex") + action_index: List[int] = Field(alias="actionIndex") + runner_index: List[int] = Field(alias="runnerIndex") runners: List[PlayRunner] = [] - play_events: List[PlayEvent] = Field(default=[], alias="playevents") - at_bat_index: int = Field(alias="atbatindex") - play_end_time: Optional[str] = Field(default=None, alias="playendtime") - review_details: Optional[PlayReviewDetails] = Field(default=None, alias="reviewdetails") + play_events: List[PlayEvent] = Field(default=[], alias="playEvents") + at_bat_index: int = Field(alias="atBatIndex") + play_end_time: Optional[str] = Field(default=None, alias="playEndTime") + review_details: Optional[PlayReviewDetails] = Field(default=None, alias="reviewDetails") diff --git a/mlbstatsapi/models/game/livedata/plays/play/playevent/playevent.py b/mlbstatsapi/models/game/livedata/plays/play/playevent/playevent.py index 2caf1812..10b44ab0 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/playevent/playevent.py +++ b/mlbstatsapi/models/game/livedata/plays/play/playevent/playevent.py @@ -50,24 +50,24 @@ class PlayEvent(MLBBaseModel): """ details: PlayDetails index: int - is_pitch: bool = Field(alias="ispitch") + is_pitch: bool = Field(alias="isPitch") type: str - pfx_id: Optional[str] = Field(default=None, alias="pfxid") - start_time: Optional[str] = Field(default=None, alias="starttime") - end_time: Optional[str] = Field(default=None, alias="endtime") + pfx_id: Optional[str] = Field(default=None, alias="pfxId") + start_time: Optional[str] = Field(default=None, alias="startTime") + end_time: Optional[str] = Field(default=None, alias="endTime") umpire: Optional[str] = None base: Optional[str] = None - play_id: Optional[str] = Field(default=None, alias="playid") - pitch_number: Optional[int] = Field(default=None, alias="pitchnumber") - action_play_id: Optional[str] = Field(default=None, alias="actionplayid") - is_base_running_play: Optional[bool] = Field(default=None, alias="isbaserunningplay") - is_substitution: Optional[bool] = Field(default=None, alias="issubstitution") - batting_order: Optional[str] = Field(default=None, alias="battingorder") + play_id: Optional[str] = Field(default=None, alias="playId") + pitch_number: Optional[int] = Field(default=None, alias="pitchNumber") + action_play_id: Optional[str] = Field(default=None, alias="actionPlayId") + is_base_running_play: Optional[bool] = Field(default=None, alias="isBaseRunningPlay") + is_substitution: Optional[bool] = Field(default=None, alias="isSubstitution") + batting_order: Optional[str] = Field(default=None, alias="battingOrder") count: Optional[Count] = None - pitch_data: Optional[PitchData] = Field(default=None, alias="pitchdata") - hit_data: Optional[HitData] = Field(default=None, alias="hitdata") + pitch_data: Optional[PitchData] = Field(default=None, alias="pitchData") + hit_data: Optional[HitData] = Field(default=None, alias="hitData") player: Optional[Person] = None position: Optional[Position] = None - replaced_player: Optional[Person] = Field(default=None, alias="replacedplayer") - review_details: Optional[dict] = Field(default=None, alias="reviewdetails") - injury_type: Optional[str] = Field(default=None, alias="injurytype") + replaced_player: Optional[Person] = Field(default=None, alias="replacedPlayer") + review_details: Optional[dict] = Field(default=None, alias="reviewDetails") + injury_type: Optional[str] = Field(default=None, alias="injuryType") diff --git a/mlbstatsapi/models/game/livedata/plays/play/playrunner/attributes.py b/mlbstatsapi/models/game/livedata/plays/play/playrunner/attributes.py index 18f21b3b..788afbc4 100644 --- a/mlbstatsapi/models/game/livedata/plays/play/playrunner/attributes.py +++ b/mlbstatsapi/models/game/livedata/plays/play/playrunner/attributes.py @@ -41,12 +41,12 @@ class RunnerMovement(MLBBaseModel): out_base : str Base runner was made out. """ - is_out: bool = Field(alias="isout") - out_number: Optional[int] = Field(default=None, alias="outnumber") - origin_base: Optional[str] = Field(default=None, alias="originbase") + is_out: bool = Field(alias="isOut") + out_number: Optional[int] = Field(default=None, alias="outNumber") + origin_base: Optional[str] = Field(default=None, alias="originBase") start: Optional[str] = None end: Optional[str] = None - out_base: Optional[str] = Field(default=None, alias="outbase") + out_base: Optional[str] = Field(default=None, alias="outBase") class RunnerDetails(MLBBaseModel): @@ -77,12 +77,12 @@ class RunnerDetails(MLBBaseModel): Who was the responsible pitcher. """ event: str - event_type: str = Field(alias="eventtype") + event_type: str = Field(alias="eventType") runner: Person - is_scoring_event: bool = Field(alias="isscoringevent") + is_scoring_event: bool = Field(alias="isScoringEvent") rbi: bool earned: bool - team_unearned: bool = Field(alias="teamunearned") - play_index: int = Field(alias="playindex") - movement_reason: Optional[str] = Field(default=None, alias="movementreason") - responsible_pitcher: Optional[Person] = Field(default=None, alias="responsiblepitcher") + team_unearned: bool = Field(alias="teamUnearned") + play_index: int = Field(alias="playIndex") + movement_reason: Optional[str] = Field(default=None, alias="movementReason") + responsible_pitcher: Optional[Person] = Field(default=None, alias="responsiblePitcher") diff --git a/mlbstatsapi/models/game/livedata/plays/playbyinning/playbyinning.py b/mlbstatsapi/models/game/livedata/plays/playbyinning/playbyinning.py index 883f9b41..97904759 100644 --- a/mlbstatsapi/models/game/livedata/plays/playbyinning/playbyinning.py +++ b/mlbstatsapi/models/game/livedata/plays/playbyinning/playbyinning.py @@ -21,8 +21,8 @@ class PlayByInning(MLBBaseModel): hits : PlayByInningHits Hits for the inning by home and away. """ - start_index: int = Field(alias="startindex") - end_index: int = Field(alias="endindex") + start_index: int = Field(alias="startIndex") + end_index: int = Field(alias="endIndex") top: List[int] bottom: List[int] hits: PlayByInningHits diff --git a/mlbstatsapi/models/game/livedata/plays/plays.py b/mlbstatsapi/models/game/livedata/plays/plays.py index 36e4064b..a4ca7504 100644 --- a/mlbstatsapi/models/game/livedata/plays/plays.py +++ b/mlbstatsapi/models/game/livedata/plays/plays.py @@ -20,10 +20,10 @@ class Plays(MLBBaseModel): plays_by_inning : List[PlayByInning] Plays by inning. """ - all_plays: List[Play] = Field(default=[], alias="allplays") - scoring_plays: List[int] = Field(alias="scoringplays") - plays_by_inning: List[PlayByInning] = Field(default=[], alias="playsbyinning") - current_play: Optional[Play] = Field(default=None, alias="currentplay") + all_plays: List[Play] = Field(default=[], alias="allPlays") + scoring_plays: List[int] = Field(alias="scoringPlays") + plays_by_inning: List[PlayByInning] = Field(default=[], alias="playsByInning") + current_play: Optional[Play] = Field(default=None, alias="currentPlay") @field_validator('current_play', mode='before') @classmethod diff --git a/mlbstatsapi/models/gamepace/attributes.py b/mlbstatsapi/models/gamepace/attributes.py index ca2097b2..d3910960 100644 --- a/mlbstatsapi/models/gamepace/attributes.py +++ b/mlbstatsapi/models/gamepace/attributes.py @@ -25,12 +25,12 @@ class PrPortalCalculatedFields(MLBBaseModel): time_per_extra_inn_game : str The average time per extra-inning game. """ - total_7_inn_games: Optional[int] = Field(default=None, alias="total7inngames") - total_9_inn_games: Optional[int] = Field(default=None, alias="total9inngames") - total_extra_inn_games: Optional[int] = Field(default=None, alias="totalextrainngames") - time_per_7_inn_game: Optional[str] = Field(default=None, alias="timeper7inngame") - time_per_9_inn_game: Optional[str] = Field(default=None, alias="timeper9inngame") - time_per_extra_inn_game: Optional[str] = Field(default=None, alias="timeperextrainngame") + total_7_inn_games: Optional[int] = Field(default=None, alias="total7InnGames") + total_9_inn_games: Optional[int] = Field(default=None, alias="total9InnGames") + total_extra_inn_games: Optional[int] = Field(default=None, alias="totalExtraInnGames") + time_per_7_inn_game: Optional[str] = Field(default=None, alias="timePer7InnGame") + time_per_9_inn_game: Optional[str] = Field(default=None, alias="timePer9InnGame") + time_per_extra_inn_game: Optional[str] = Field(default=None, alias="timePerExtraInnGame") class GamePaceData(MLBBaseModel): @@ -128,47 +128,47 @@ class GamePaceData(MLBBaseModel): pr_portal_calculated_fields : PrPortalCalculatedFields Calculated fields. """ - hits_per_9_inn: Optional[float] = Field(default=None, alias="hitsper9inn") - runs_per_9_inn: Optional[float] = Field(default=None, alias="runsper9inn") - pitches_per_9_inn: Optional[float] = Field(default=None, alias="pitchesper9inn") - plate_appearances_per_9_inn: Optional[float] = Field(default=None, alias="plateappearancesper9inn") - hits_per_game: Optional[float] = Field(default=None, alias="hitspergame") - runs_per_game: Optional[float] = Field(default=None, alias="runspergame") - innings_played_per_game: Optional[float] = Field(default=None, alias="inningsplayedpergame") - pitches_per_game: Optional[float] = Field(default=None, alias="pitchespergame") - pitchers_per_game: Optional[float] = Field(default=None, alias="pitcherspergame") - plate_appearances_per_game: Optional[float] = Field(default=None, alias="plateappearancespergame") - total_game_time: Optional[str] = Field(default=None, alias="totalgametime") - total_innings_played: Optional[float] = Field(default=None, alias="totalinningsplayed") - total_hits: Optional[int] = Field(default=None, alias="totalhits") - total_runs: Optional[int] = Field(default=None, alias="totalruns") - total_plate_appearances: Optional[int] = Field(default=None, alias="totalplateappearances") - total_pitchers: Optional[int] = Field(default=None, alias="totalpitchers") - total_pitches: Optional[int] = Field(default=None, alias="totalpitches") - total_games: Optional[int] = Field(default=None, alias="totalgames") - total_7_inn_games: Optional[int] = Field(default=None, alias="total7inngames") - total_9_inn_games: Optional[int] = Field(default=None, alias="total9inngames") - total_extra_inn_games: Optional[int] = Field(default=None, alias="totalextrainngames") - time_per_game: Optional[str] = Field(default=None, alias="timepergame") - time_per_pitch: Optional[str] = Field(default=None, alias="timeperpitch") - time_per_hit: Optional[str] = Field(default=None, alias="timeperhit") - time_per_run: Optional[str] = Field(default=None, alias="timeperrun") - time_per_plate_appearance: Optional[str] = Field(default=None, alias="timeperplateappearance") - time_per_9_inn: Optional[str] = Field(default=None, alias="timeper9inn") - time_per_77_plate_appearances: Optional[str] = Field(default=None, alias="timeper77plateappearances") - total_extra_inn_time: Optional[str] = Field(default=None, alias="totalextrainntime") - time_per_7_inn_game: Optional[str] = Field(default=None, alias="timeper7inngame") - total_7_inn_games_completed_early: Optional[int] = Field(default=None, alias="total7inngamescompletedearly") - time_per_7_inn_game_without_extra_inn: Optional[str] = Field(default=None, alias="timeper7inngamewithoutextrainn") - total_7_inn_games_scheduled: Optional[int] = Field(default=None, alias="total7inngamesscheduled") - total_7_inn_games_without_extra_inn: Optional[int] = Field(default=None, alias="total7inngameswithoutextrainn") - total_9_inn_games_completed_early: Optional[int] = Field(default=None, alias="total9inngamescompletedearly") - total_9_inn_games_without_extra_inn: Optional[int] = Field(default=None, alias="total9inngameswithoutextrainn") - total_9_inn_games_scheduled: Optional[int] = Field(default=None, alias="total9inngamesscheduled") - hits_per_run: Optional[float] = Field(default=None, alias="hitsperrun") - pitches_per_pitcher: Optional[float] = Field(default=None, alias="pitchesperpitcher") + hits_per_9_inn: Optional[float] = Field(default=None, alias="hitsPer9Inn") + runs_per_9_inn: Optional[float] = Field(default=None, alias="runsPer9Inn") + pitches_per_9_inn: Optional[float] = Field(default=None, alias="pitchesPer9Inn") + plate_appearances_per_9_inn: Optional[float] = Field(default=None, alias="plateAppearancesPer9Inn") + hits_per_game: Optional[float] = Field(default=None, alias="hitsPerGame") + runs_per_game: Optional[float] = Field(default=None, alias="runsPerGame") + innings_played_per_game: Optional[float] = Field(default=None, alias="inningsPlayedPerGame") + pitches_per_game: Optional[float] = Field(default=None, alias="pitchesPerGame") + pitchers_per_game: Optional[float] = Field(default=None, alias="pitchersPerGame") + plate_appearances_per_game: Optional[float] = Field(default=None, alias="plateAppearancesPerGame") + total_game_time: Optional[str] = Field(default=None, alias="totalGameTime") + total_innings_played: Optional[float] = Field(default=None, alias="totalInningsPlayed") + total_hits: Optional[int] = Field(default=None, alias="totalHits") + total_runs: Optional[int] = Field(default=None, alias="totalRuns") + total_plate_appearances: Optional[int] = Field(default=None, alias="totalPlateAppearances") + total_pitchers: Optional[int] = Field(default=None, alias="totalPitchers") + total_pitches: Optional[int] = Field(default=None, alias="totalPitches") + total_games: Optional[int] = Field(default=None, alias="totalGames") + total_7_inn_games: Optional[int] = Field(default=None, alias="total7InnGames") + total_9_inn_games: Optional[int] = Field(default=None, alias="total9InnGames") + total_extra_inn_games: Optional[int] = Field(default=None, alias="totalExtraInnGames") + time_per_game: Optional[str] = Field(default=None, alias="timePerGame") + time_per_pitch: Optional[str] = Field(default=None, alias="timePerPitch") + time_per_hit: Optional[str] = Field(default=None, alias="timePerHit") + time_per_run: Optional[str] = Field(default=None, alias="timePerRun") + time_per_plate_appearance: Optional[str] = Field(default=None, alias="timePerPlateAppearance") + time_per_9_inn: Optional[str] = Field(default=None, alias="timePer9Inn") + time_per_77_plate_appearances: Optional[str] = Field(default=None, alias="timePer77PlateAppearances") + total_extra_inn_time: Optional[str] = Field(default=None, alias="totalExtraInnTime") + time_per_7_inn_game: Optional[str] = Field(default=None, alias="timePer7InnGame") + total_7_inn_games_completed_early: Optional[int] = Field(default=None, alias="total7InnGamesCompletedEarly") + time_per_7_inn_game_without_extra_inn: Optional[str] = Field(default=None, alias="timePer7InnGameWithoutExtraInn") + total_7_inn_games_scheduled: Optional[int] = Field(default=None, alias="total7InnGamesScheduled") + total_7_inn_games_without_extra_inn: Optional[int] = Field(default=None, alias="total7InnGamesWithoutExtraInn") + total_9_inn_games_completed_early: Optional[int] = Field(default=None, alias="total9InnGamesCompletedEarly") + total_9_inn_games_without_extra_inn: Optional[int] = Field(default=None, alias="total9InnGamesWithoutExtraInn") + total_9_inn_games_scheduled: Optional[int] = Field(default=None, alias="total9InnGamesScheduled") + hits_per_run: Optional[float] = Field(default=None, alias="hitsPerRun") + pitches_per_pitcher: Optional[float] = Field(default=None, alias="pitchesPerPitcher") season: Optional[str] = None team: Optional[Team] = None league: Optional[League] = None sport: Optional[Sport] = None - pr_portal_calculated_fields: Optional[PrPortalCalculatedFields] = Field(default=None, alias="prportalcalculatedfields") + pr_portal_calculated_fields: Optional[PrPortalCalculatedFields] = Field(default=None, alias="prPortalCalculatedFields") diff --git a/mlbstatsapi/models/homerunderby/attributes.py b/mlbstatsapi/models/homerunderby/attributes.py index 1a1c2d4b..e44725a1 100644 --- a/mlbstatsapi/models/homerunderby/attributes.py +++ b/mlbstatsapi/models/homerunderby/attributes.py @@ -53,16 +53,16 @@ class Info(MLBBaseModel): The teams participating in the event. """ id: int - non_game_guid: str = Field(alias="nongameguid") + non_game_guid: str = Field(alias="nonGameGuid") name: str - event_type: EventType = Field(alias="eventtype") - event_date: str = Field(alias="eventdate") + event_type: EventType = Field(alias="eventType") + event_date: str = Field(alias="eventDate") venue: Venue - is_multi_day: bool = Field(alias="ismultiday") - is_primary_calendar: bool = Field(alias="isprimarycalendar") - file_code: str = Field(alias="filecode") - event_number: int = Field(alias="eventnumber") - public_facing: bool = Field(alias="publicfacing") + is_multi_day: bool = Field(alias="isMultiDay") + is_primary_calendar: bool = Field(alias="isPrimaryCalendar") + file_code: str = Field(alias="fileCode") + event_number: int = Field(alias="eventNumber") + public_facing: bool = Field(alias="publicFacing") teams: List[Team] = [] @@ -88,12 +88,12 @@ class Status(MLBBaseModel): Whether the round is currently in bonus time. """ state: str - current_round: int = Field(alias="currentround") - current_round_time_left: str = Field(alias="currentroundtimeleft") - in_tiebreaker: bool = Field(alias="intiebreaker") - tiebreaker_num: int = Field(alias="tiebreakernum") - clock_stopped: bool = Field(alias="clockstopped") - bonus_time: bool = Field(alias="bonustime") + current_round: int = Field(alias="currentRound") + current_round_time_left: str = Field(alias="currentRoundTimeLeft") + in_tiebreaker: bool = Field(alias="inTieBreaker") + tiebreaker_num: int = Field(alias="tieBreakerNum") + clock_stopped: bool = Field(alias="clockStopped") + bonus_time: bool = Field(alias="bonusTime") class Coordinates(MLBBaseModel): @@ -111,10 +111,10 @@ class Coordinates(MLBBaseModel): landing_pos_y : float The y-coordinate of the hit's landing position. """ - coord_x: Optional[float] = Field(default=None, alias="coordx") - coord_y: Optional[float] = Field(default=None, alias="coordy") - landing_pos_x: Optional[float] = Field(default=None, alias="landingposx") - landing_pos_y: Optional[float] = Field(default=None, alias="landingposy") + coord_x: Optional[float] = Field(default=None, alias="coordX") + coord_y: Optional[float] = Field(default=None, alias="coordY") + landing_pos_x: Optional[float] = Field(default=None, alias="landingPosX") + landing_pos_y: Optional[float] = Field(default=None, alias="landingPosY") class TrajectoryData(MLBBaseModel): @@ -134,11 +134,11 @@ class TrajectoryData(MLBBaseModel): measured_time_interval : List[float] Start and end times of the interval during which trajectory was measured. """ - trajectory_polynomial_x: List[float] = Field(alias="trajectorypolynomialx") - trajectory_polynomial_y: List[float] = Field(alias="trajectorypolynomialy") - trajectory_polynomial_z: List[float] = Field(alias="trajectorypolynomialz") - valid_time_interval: List[float] = Field(alias="validtimeinterval") - measured_time_interval: List[float] = Field(alias="measuredtimeinterval") + trajectory_polynomial_x: List[float] = Field(alias="trajectoryPolynomialX") + trajectory_polynomial_y: List[float] = Field(alias="trajectoryPolynomialY") + trajectory_polynomial_z: List[float] = Field(alias="trajectoryPolynomialZ") + valid_time_interval: List[float] = Field(alias="validTimeInterval") + measured_time_interval: List[float] = Field(alias="measuredTimeInterval") class HitData(MLBBaseModel): @@ -158,11 +158,11 @@ class HitData(MLBBaseModel): trajectory_data : TrajectoryData Trajectory data for the hit. """ - total_distance: int = Field(alias="totaldistance") - launch_speed: Optional[float] = Field(default=None, alias="launchspeed") - launch_angle: Optional[float] = Field(default=None, alias="launchangle") + total_distance: int = Field(alias="totalDistance") + launch_speed: Optional[float] = Field(default=None, alias="launchSpeed") + launch_angle: Optional[float] = Field(default=None, alias="launchAngle") coordinates: Optional[Coordinates] = None - trajectory_data: Optional[TrajectoryData] = Field(default=None, alias="trajectorydata") + trajectory_data: Optional[TrajectoryData] = Field(default=None, alias="trajectoryData") class Hits(MLBBaseModel): @@ -192,16 +192,16 @@ class Hits(MLBBaseModel): play_id : str The ID of the play in which the hit occurred. """ - bonus_time: bool = Field(alias="bonustime") - homerun: bool - tiebreaker: bool - hit_data: HitData = Field(alias="hitdata") - is_homerun: bool = Field(alias="ishomerun") - time_remaining: str = Field(alias="timeremaining") - is_bonus_time: bool = Field(alias="isbonustime") - is_tiebreaker: bool = Field(alias="istiebreaker") - time_remaining_seconds: Optional[int] = Field(default=None, alias="timeremainingseconds") - play_id: Optional[str] = Field(default=None, alias="playid") + bonus_time: bool = Field(alias="bonusTime") + homerun: bool = Field(alias="homeRun") + tiebreaker: bool = Field(alias="tieBreaker") + hit_data: HitData = Field(alias="hitData") + is_homerun: bool = Field(alias="isHomeRun") + time_remaining: str = Field(alias="timeRemaining") + is_bonus_time: bool = Field(alias="isBonusTime") + is_tiebreaker: bool = Field(alias="isTieBreaker") + time_remaining_seconds: Optional[int] = Field(default=None, alias="timeRemainingSeconds") + play_id: Optional[str] = Field(default=None, alias="playId") class Seed(MLBBaseModel): @@ -239,14 +239,14 @@ class Seed(MLBBaseModel): started: bool winner: bool player: Person - top_derby_hit_data: HitData = Field(alias="topderbyhitdata") + top_derby_hit_data: HitData = Field(alias="topDerbyHitData") hits: List[Hits] = [] seed: int order: int - is_winner: bool = Field(alias="iswinner") - is_complete: bool = Field(alias="iscomplete") - is_started: bool = Field(alias="isstarted") - num_homeruns: int = Field(alias="numhomeruns") + is_winner: bool = Field(alias="isWinner") + is_complete: bool = Field(alias="isComplete") + is_started: bool = Field(alias="isStarted") + num_homeruns: int = Field(alias="numHomeRuns") class Matchup(MLBBaseModel): @@ -260,8 +260,8 @@ class Matchup(MLBBaseModel): bottom_seed : Seed The bottom seed in the matchup. """ - top_seed: Seed = Field(alias="topseed") - bottom_seed: Seed = Field(alias="bottomseed") + top_seed: Seed = Field(alias="topSeed") + bottom_seed: Seed = Field(alias="bottomSeed") class Round(MLBBaseModel): @@ -279,4 +279,4 @@ class Round(MLBBaseModel): """ round: int matchups: List[Matchup] = [] - num_batters: Optional[int] = Field(default=None, alias="numbatters") + num_batters: Optional[int] = Field(default=None, alias="numBatters") diff --git a/mlbstatsapi/models/leagues/league.py b/mlbstatsapi/models/leagues/league.py index 508883fe..574030bd 100644 --- a/mlbstatsapi/models/leagues/league.py +++ b/mlbstatsapi/models/leagues/league.py @@ -77,19 +77,19 @@ class League(MLBBaseModel): link: str name: Optional[str] = None abbreviation: Optional[str] = None - name_short: Optional[str] = Field(default=None, alias="nameshort") - season_state: Optional[str] = Field(default=None, alias="seasonstate") - has_wildcard: Optional[bool] = Field(default=None, alias="haswildcard") - has_split_season: Optional[bool] = Field(default=None, alias="hassplitseason") - num_games: Optional[int] = Field(default=None, alias="numgames") - has_playoff_points: Optional[bool] = Field(default=None, alias="hasplayoffpoints") - num_teams: Optional[int] = Field(default=None, alias="numteams") - num_wildcard_teams: Optional[int] = Field(default=None, alias="numwildcardteams") - season_date_info: Optional[Season] = Field(default=None, alias="seasondateinfo") + name_short: Optional[str] = Field(default=None, alias="nameShort") + season_state: Optional[str] = Field(default=None, alias="seasonState") + has_wildcard: Optional[bool] = Field(default=None, alias="hasWildcard") + has_split_season: Optional[bool] = Field(default=None, alias="hasSplitSeason") + num_games: Optional[int] = Field(default=None, alias="numGames") + has_playoff_points: Optional[bool] = Field(default=None, alias="hasPlayoffPoints") + num_teams: Optional[int] = Field(default=None, alias="numTeams") + num_wildcard_teams: Optional[int] = Field(default=None, alias="numWildcardTeams") + season_date_info: Optional[Season] = Field(default=None, alias="seasonDateInfo") season: Optional[str] = None - org_code: Optional[str] = Field(default=None, alias="orgcode") - conferences_in_use: Optional[bool] = Field(default=None, alias="conferencesinuse") - divisions_in_use: Optional[bool] = Field(default=None, alias="divisionsinuse") + org_code: Optional[str] = Field(default=None, alias="orgCode") + conferences_in_use: Optional[bool] = Field(default=None, alias="conferencesInUse") + divisions_in_use: Optional[bool] = Field(default=None, alias="divisionsInUse") sport: Optional[Sport] = None - sort_order: Optional[int] = Field(default=None, alias="sortorder") + sort_order: Optional[int] = Field(default=None, alias="sortOrder") active: Optional[bool] = None diff --git a/mlbstatsapi/models/people/attributes.py b/mlbstatsapi/models/people/attributes.py index dcc7f2e3..18ed8d00 100644 --- a/mlbstatsapi/models/people/attributes.py +++ b/mlbstatsapi/models/people/attributes.py @@ -105,7 +105,7 @@ class School(MLBBaseModel): The state where the school is located. """ name: str - school_class: str = Field(alias="schoolclass") + school_class: str = Field(alias="schoolClass") city: str country: str state: str diff --git a/mlbstatsapi/models/people/people.py b/mlbstatsapi/models/people/people.py index 15c6ef06..8eb5d42e 100644 --- a/mlbstatsapi/models/people/people.py +++ b/mlbstatsapi/models/people/people.py @@ -110,51 +110,51 @@ class Person(MLBBaseModel): """ id: int link: str - primary_position: Optional[Position] = Field(default=None, alias="primaryposition") - pitch_hand: Optional[PitchHand] = Field(default=None, alias="pitchhand") - bat_side: Optional[BatSide] = Field(default=None, alias="batside") - full_name: Optional[str] = Field(default=None, alias="fullname") - first_name: Optional[str] = Field(default=None, alias="firstname") - last_name: Optional[str] = Field(default=None, alias="lastname") - primary_number: Optional[str] = Field(default=None, alias="primarynumber") - birth_date: Optional[str] = Field(default=None, alias="birthdate") - current_team: Optional[Team] = Field(default=None, alias="currentteam") - current_age: Optional[int] = Field(default=None, alias="currentage") - birth_city: Optional[str] = Field(default=None, alias="birthcity") - birth_state_province: Optional[str] = Field(default=None, alias="birthstateprovince") + primary_position: Optional[Position] = Field(default=None, alias="primaryPosition") + pitch_hand: Optional[PitchHand] = Field(default=None, alias="pitchHand") + bat_side: Optional[BatSide] = Field(default=None, alias="batSide") + full_name: Optional[str] = Field(default=None, alias="fullName") + first_name: Optional[str] = Field(default=None, alias="firstName") + last_name: Optional[str] = Field(default=None, alias="lastName") + primary_number: Optional[str] = Field(default=None, alias="primaryNumber") + birth_date: Optional[str] = Field(default=None, alias="birthDate") + current_team: Optional[Team] = Field(default=None, alias="currentTeam") + current_age: Optional[int] = Field(default=None, alias="currentAge") + birth_city: Optional[str] = Field(default=None, alias="birthCity") + birth_state_province: Optional[str] = Field(default=None, alias="birthStateProvince") height: Optional[str] = None weight: Optional[int] = None active: Optional[bool] = None - use_name: Optional[str] = Field(default=None, alias="usename") - middle_name: Optional[str] = Field(default=None, alias="middlename") - boxscore_name: Optional[str] = Field(default=None, alias="boxscorename") + use_name: Optional[str] = Field(default=None, alias="useName") + middle_name: Optional[str] = Field(default=None, alias="middleName") + boxscore_name: Optional[str] = Field(default=None, alias="boxscoreName") nickname: Optional[str] = None - draft_year: Optional[int] = Field(default=None, alias="draftyear") - mlb_debut_date: Optional[str] = Field(default=None, alias="mlbdebutdate") - name_first_last: Optional[str] = Field(default=None, alias="namefirstlast") - name_slug: Optional[str] = Field(default=None, alias="nameslug") - first_last_name: Optional[str] = Field(default=None, alias="firstlastname") - last_first_name: Optional[str] = Field(default=None, alias="lastfirstname") - last_init_name: Optional[str] = Field(default=None, alias="lastinitname") - init_last_name: Optional[str] = Field(default=None, alias="initlastname") - full_fml_name: Optional[str] = Field(default=None, alias="fullfmlname") - full_lfm_name: Optional[str] = Field(default=None, alias="fulllfmname") - birth_country: Optional[str] = Field(default=None, alias="birthcountry") + draft_year: Optional[int] = Field(default=None, alias="draftYear") + mlb_debut_date: Optional[str] = Field(default=None, alias="mlbDebutDate") + name_first_last: Optional[str] = Field(default=None, alias="nameFirstLast") + name_slug: Optional[str] = Field(default=None, alias="nameSlug") + first_last_name: Optional[str] = Field(default=None, alias="firstLastName") + last_first_name: Optional[str] = Field(default=None, alias="lastFirstName") + last_init_name: Optional[str] = Field(default=None, alias="lastInitName") + init_last_name: Optional[str] = Field(default=None, alias="initLastName") + full_fml_name: Optional[str] = Field(default=None, alias="fullFmlName") + full_lfm_name: Optional[str] = Field(default=None, alias="fullLfmName") + birth_country: Optional[str] = Field(default=None, alias="birthCountry") pronunciation: Optional[str] = None - strike_zone_top: Optional[float] = Field(default=None, alias="strikezonetop") - strike_zone_bottom: Optional[float] = Field(default=None, alias="strikezonebottom") - name_title: Optional[str] = Field(default=None, alias="nametitle") + strike_zone_top: Optional[float] = Field(default=None, alias="strikeZoneTop") + strike_zone_bottom: Optional[float] = Field(default=None, alias="strikeZoneBottom") + name_title: Optional[str] = Field(default=None, alias="nameTitle") gender: Optional[str] = None - is_player: Optional[bool] = Field(default=None, alias="isplayer") - is_verified: Optional[bool] = Field(default=None, alias="isverified") - name_matrilineal: Optional[str] = Field(default=None, alias="namematrilineal") - death_date: Optional[str] = Field(default=None, alias="deathdate") - death_city: Optional[str] = Field(default=None, alias="deathcity") - death_country: Optional[str] = Field(default=None, alias="deathcountry") - death_state_province: Optional[str] = Field(default=None, alias="deathstateprovince") - last_played_date: Optional[str] = Field(default=None, alias="lastplayeddate") - use_last_name: Optional[str] = Field(default=None, alias="uselastname") - name_suffix: Optional[str] = Field(default=None, alias="namesuffix") + is_player: Optional[bool] = Field(default=None, alias="isPlayer") + is_verified: Optional[bool] = Field(default=None, alias="isVerified") + name_matrilineal: Optional[str] = Field(default=None, alias="nameMatrilineal") + death_date: Optional[str] = Field(default=None, alias="deathDate") + death_city: Optional[str] = Field(default=None, alias="deathCity") + death_country: Optional[str] = Field(default=None, alias="deathCountry") + death_state_province: Optional[str] = Field(default=None, alias="deathStateProvince") + last_played_date: Optional[str] = Field(default=None, alias="lastPlayedDate") + use_last_name: Optional[str] = Field(default=None, alias="useLastName") + name_suffix: Optional[str] = Field(default=None, alias="nameSuffix") class Player(Person): @@ -174,9 +174,9 @@ class Player(Person): position : Position Position of the player (alias for primary_position). """ - jersey_number: str = Field(alias="jerseynumber") + jersey_number: str = Field(alias="jerseyNumber") status: Status - parent_team_id: Optional[int] = Field(default=None, alias="parentteamid") + parent_team_id: Optional[int] = Field(default=None, alias="parentTeamId") note: Optional[str] = None @model_validator(mode='before') @@ -203,9 +203,9 @@ class Coach(Person): title : str Title of the coach. """ - jersey_number: str = Field(alias="jerseynumber") + jersey_number: str = Field(alias="jerseyNumber") job: str - job_id: str = Field(alias="jobid") + job_id: str = Field(alias="jobId") title: str @@ -264,20 +264,20 @@ class DraftPick(Person): year : str The year in which the draft took place. """ - pick_round: str = Field(alias="pickround") - pick_number: int = Field(alias="picknumber") - round_pick_number: int = Field(alias="roundpicknumber") + pick_round: str = Field(alias="pickRound") + pick_number: int = Field(alias="pickNumber") + round_pick_number: int = Field(alias="roundPickNumber") home: Home school: School - headshot_link: str = Field(alias="headshotlink") + headshot_link: str = Field(alias="headshotLink") team: Team - draft_type: CodeDesc = Field(alias="drafttype") - is_drafted: bool = Field(alias="isdrafted") - is_pass: bool = Field(alias="ispass") + draft_type: CodeDesc = Field(alias="draftType") + is_drafted: bool = Field(alias="isDrafted") + is_pass: bool = Field(alias="isPass") year: str - bis_player_id: Optional[int] = Field(default=None, alias="bisplayerid") + bis_player_id: Optional[int] = Field(default=None, alias="bisPlayerId") rank: Optional[int] = None - pick_value: Optional[str] = Field(default=None, alias="pickvalue") - signing_bonus: Optional[str] = Field(default=None, alias="signingbonus") - scouting_report: Optional[str] = Field(default=None, alias="scoutingreport") + pick_value: Optional[str] = Field(default=None, alias="pickValue") + signing_bonus: Optional[str] = Field(default=None, alias="signingBonus") + scouting_report: Optional[str] = Field(default=None, alias="scoutingReport") blurb: Optional[str] = None diff --git a/mlbstatsapi/models/schedules/attributes.py b/mlbstatsapi/models/schedules/attributes.py index dbac859d..9d0bdcab 100644 --- a/mlbstatsapi/models/schedules/attributes.py +++ b/mlbstatsapi/models/schedules/attributes.py @@ -26,12 +26,12 @@ class ScheduleGameTeam(MLBBaseModel): is_winner : bool If this team is the winner of this game. """ - league_record: LeagueRecord = Field(alias="leaguerecord") + league_record: LeagueRecord = Field(alias="leagueRecord") team: Team - split_squad: bool = Field(alias="splitsquad") - series_number: Optional[int] = Field(default=None, alias="seriesnumber") + split_squad: bool = Field(alias="splitSquad") + series_number: Optional[int] = Field(default=None, alias="seriesNumber") score: Optional[int] = None - is_winner: Optional[bool] = Field(default=False, alias="iswinner") + is_winner: Optional[bool] = Field(default=False, alias="isWinner") class ScheduleHomeAndAway(MLBBaseModel): @@ -132,44 +132,44 @@ class ScheduleGames(MLBBaseModel): resumed_from_date : str Resumed from date. """ - game_pk: int = Field(alias="gamepk") + game_pk: int = Field(alias="gamePk") link: str - game_type: str = Field(alias="gametype") + game_type: str = Field(alias="gameType") season: str - game_date: str = Field(alias="gamedate") - official_date: str = Field(alias="officialdate") + game_date: str = Field(alias="gameDate") + official_date: str = Field(alias="officialDate") venue: Venue content: dict - game_number: int = Field(alias="gamenumber") - public_facing: bool = Field(alias="publicfacing") - double_header: str = Field(alias="doubleheader") - gameday_type: str = Field(alias="gamedaytype") + game_number: int = Field(alias="gameNumber") + public_facing: bool = Field(alias="publicFacing") + double_header: str = Field(alias="doubleHeader") + gameday_type: str = Field(alias="gamedayType") tiebreaker: str - calendar_event_id: str = Field(alias="calendareventid") - season_display: str = Field(alias="seasondisplay") - day_night: str = Field(alias="daynight") - scheduled_innings: int = Field(alias="scheduledinnings") - reverse_home_away_status: bool = Field(alias="reversehomeawaystatus") - series_description: str = Field(alias="seriesdescription") - record_source: str = Field(alias="recordsource") - if_necessary: str = Field(alias="ifnecessary") - if_necessary_description: str = Field(alias="ifnecessarydescription") + calendar_event_id: Optional[str] = Field(default=None, alias="calendarEventId") + season_display: str = Field(alias="seasonDisplay") + day_night: str = Field(alias="dayNight") + scheduled_innings: int = Field(alias="scheduledInnings") + reverse_home_away_status: bool = Field(alias="reverseHomeAwayStatus") + series_description: str = Field(alias="seriesDescription") + record_source: str = Field(alias="recordSource") + if_necessary: str = Field(alias="ifNecessary") + if_necessary_description: str = Field(alias="ifNecessaryDescription") status: Optional[GameStatus] = None teams: Optional[ScheduleHomeAndAway] = None - game_guid: Optional[str] = Field(default=None, alias="gameguid") + game_guid: Optional[str] = Field(default=None, alias="gameGuid") description: Optional[str] = None - inning_break_length: Optional[int] = Field(default=None, alias="inningbreaklength") - reschedule_date: Optional[str] = Field(default=None, alias="rescheduledate") - reschedule_game_date: Optional[str] = Field(default=None, alias="reschedulegamedate") - rescheduled_from: Optional[str] = Field(default=None, alias="rescheduledfrom") - rescheduled_from_date: Optional[str] = Field(default=None, alias="rescheduledfromdate") - is_tie: Optional[bool] = Field(default=None, alias="istie") - resume_date: Optional[str] = Field(default=None, alias="resumedate") - resume_game_date: Optional[str] = Field(default=None, alias="resumegamedate") - resumed_from: Optional[str] = Field(default=None, alias="resumedfrom") - resumed_from_date: Optional[str] = Field(default=None, alias="resumedfromdate") - series_game_number: Optional[int] = Field(default=None, alias="seriesgamenumber") - games_in_series: Optional[int] = Field(default=None, alias="gamesinseries") + inning_break_length: Optional[int] = Field(default=None, alias="inningBreakLength") + reschedule_date: Optional[str] = Field(default=None, alias="rescheduleDate") + reschedule_game_date: Optional[str] = Field(default=None, alias="rescheduleGameDate") + rescheduled_from: Optional[str] = Field(default=None, alias="rescheduledFrom") + rescheduled_from_date: Optional[str] = Field(default=None, alias="rescheduledFromDate") + is_tie: Optional[bool] = Field(default=None, alias="isTie") + resume_date: Optional[str] = Field(default=None, alias="resumeDate") + resume_game_date: Optional[str] = Field(default=None, alias="resumeGameDate") + resumed_from: Optional[str] = Field(default=None, alias="resumedFrom") + resumed_from_date: Optional[str] = Field(default=None, alias="resumedFromDate") + series_game_number: Optional[int] = Field(default=None, alias="seriesGameNumber") + games_in_series: Optional[int] = Field(default=None, alias="gamesInSeries") @field_validator('status', 'teams', mode='before') @classmethod @@ -202,9 +202,9 @@ class ScheduleDates(MLBBaseModel): A list of events for this date. """ date: str - total_items: int = Field(alias="totalitems") - total_events: int = Field(alias="totalevents") - total_games: int = Field(alias="totalgames") - total_games_in_progress: int = Field(alias="totalgamesinprogress") + total_items: int = Field(alias="totalItems") + total_events: int = Field(alias="totalEvents") + total_games: int = Field(alias="totalGames") + total_games_in_progress: int = Field(alias="totalGamesInProgress") events: List = [] games: List[ScheduleGames] = [] diff --git a/mlbstatsapi/models/schedules/schedule.py b/mlbstatsapi/models/schedules/schedule.py index 5f5b2f34..a444639c 100644 --- a/mlbstatsapi/models/schedules/schedule.py +++ b/mlbstatsapi/models/schedules/schedule.py @@ -21,8 +21,8 @@ class Schedule(MLBBaseModel): dates : List[ScheduleDates] List of dates with games in schedule. """ - total_items: int = Field(alias="totalitems") - total_events: int = Field(alias="totalevents") - total_games: int = Field(alias="totalgames") - total_games_in_progress: int = Field(alias="totalgamesinprogress") + total_items: int = Field(alias="totalItems") + total_events: int = Field(alias="totalEvents") + total_games: int = Field(alias="totalGames") + total_games_in_progress: int = Field(alias="totalGamesInProgress") dates: List[ScheduleDates] = [] diff --git a/mlbstatsapi/models/seasons/season.py b/mlbstatsapi/models/seasons/season.py index 2e90c2d5..da04dd61 100644 --- a/mlbstatsapi/models/seasons/season.py +++ b/mlbstatsapi/models/seasons/season.py @@ -52,24 +52,24 @@ class Season(MLBBaseModel): qualifier_outs_pitched : float Qualifier outs pitched. """ - season_id: str = Field(alias="seasonid") - has_wildcard: Optional[bool] = Field(default=None, alias="haswildcard") - preseason_start_date: Optional[str] = Field(default=None, alias="preseasonstartdate") - preseason_end_date: Optional[str] = Field(default=None, alias="preseasonenddate") - season_start_date: Optional[str] = Field(default=None, alias="seasonstartdate") - spring_start_date: Optional[str] = Field(default=None, alias="springstartdate") - spring_end_date: Optional[str] = Field(default=None, alias="springenddate") - regular_season_start_date: Optional[str] = Field(default=None, alias="regularseasonstartdate") - last_date_1st_half: Optional[str] = Field(default=None, alias="lastdate1sthalf") - all_star_date: Optional[str] = Field(default=None, alias="allstardate") - first_date_2nd_half: Optional[str] = Field(default=None, alias="firstdate2ndhalf") - regular_season_end_date: Optional[str] = Field(default=None, alias="regularseasonenddate") - postseason_start_date: Optional[str] = Field(default=None, alias="postseasonstartdate") - postseason_end_date: Optional[str] = Field(default=None, alias="postseasonenddate") - season_end_date: Optional[str] = Field(default=None, alias="seasonenddate") - offseason_start_date: Optional[str] = Field(default=None, alias="offseasonstartdate") - offseason_end_date: Optional[str] = Field(default=None, alias="offseasonenddate") - season_level_gameday_type: Optional[str] = Field(default=None, alias="seasonlevelgamedaytype") - game_level_gameday_type: Optional[str] = Field(default=None, alias="gamelevelgamedaytype") - qualifier_plate_appearances: Optional[float] = Field(default=None, alias="qualifierplateappearances") - qualifier_outs_pitched: Optional[float] = Field(default=None, alias="qualifieroutspitched") + season_id: str = Field(alias="seasonId") + has_wildcard: Optional[bool] = Field(default=None, alias="hasWildcard") + preseason_start_date: Optional[str] = Field(default=None, alias="preseasonStartDate") + preseason_end_date: Optional[str] = Field(default=None, alias="preseasonEndDate") + season_start_date: Optional[str] = Field(default=None, alias="seasonStartDate") + spring_start_date: Optional[str] = Field(default=None, alias="springStartDate") + spring_end_date: Optional[str] = Field(default=None, alias="springEndDate") + regular_season_start_date: Optional[str] = Field(default=None, alias="regularSeasonStartDate") + last_date_1st_half: Optional[str] = Field(default=None, alias="lastDate1stHalf") + all_star_date: Optional[str] = Field(default=None, alias="allStarDate") + first_date_2nd_half: Optional[str] = Field(default=None, alias="firstDate2ndHalf") + regular_season_end_date: Optional[str] = Field(default=None, alias="regularSeasonEndDate") + postseason_start_date: Optional[str] = Field(default=None, alias="postseasonStartDate") + postseason_end_date: Optional[str] = Field(default=None, alias="postseasonEndDate") + season_end_date: Optional[str] = Field(default=None, alias="seasonEndDate") + offseason_start_date: Optional[str] = Field(default=None, alias="offseasonStartDate") + offseason_end_date: Optional[str] = Field(default=None, alias="offseasonEndDate") + season_level_gameday_type: Optional[str] = Field(default=None, alias="seasonLevelGamedayType") + game_level_gameday_type: Optional[str] = Field(default=None, alias="gameLevelGamedayType") + qualifier_plate_appearances: Optional[float] = Field(default=None, alias="qualifierPlateAppearances") + qualifier_outs_pitched: Optional[float] = Field(default=None, alias="qualifierOutsPitched") diff --git a/mlbstatsapi/models/sports/sport.py b/mlbstatsapi/models/sports/sport.py index 4c0826af..4ef8f509 100644 --- a/mlbstatsapi/models/sports/sport.py +++ b/mlbstatsapi/models/sports/sport.py @@ -29,5 +29,5 @@ class Sport(MLBBaseModel): name: Optional[str] = None code: Optional[str] = None abbreviation: Optional[str] = None - sort_order: Optional[int] = Field(default=None, alias="sortorder") - active_status: Optional[bool] = Field(default=None, alias="activestatus") + sort_order: Optional[int] = Field(default=None, alias="sortOrder") + active_status: Optional[bool] = Field(default=None, alias="activeStatus") diff --git a/mlbstatsapi/models/standings/attributes.py b/mlbstatsapi/models/standings/attributes.py index ecf20bea..2df98444 100644 --- a/mlbstatsapi/models/standings/attributes.py +++ b/mlbstatsapi/models/standings/attributes.py @@ -18,9 +18,9 @@ class Streak(MLBBaseModel): streak_code : str Streak code. """ - streak_type: str = Field(alias="streaktype") - streak_number: int = Field(alias="streaknumber") - streak_code: str = Field(alias="streakcode") + streak_type: str = Field(alias="streakType") + streak_number: int = Field(alias="streakNumber") + streak_code: str = Field(alias="streakCode") class TeamRecords(TeamRecord): @@ -81,24 +81,24 @@ class TeamRecords(TeamRecord): team: Team season: int streak: Streak - division_rank: str = Field(alias="divisionrank") - league_rank: str = Field(alias="leaguerank") - sport_rank: str = Field(alias="sportrank") - games_back: str = Field(alias="gamesback") - last_updated: str = Field(alias="lastupdated") - runs_allowed: int = Field(alias="runsallowed") - runs_scored: int = Field(alias="runsscored") - division_champ: bool = Field(alias="divisionchamp") - has_wildcard: bool = Field(alias="haswildcard") + division_rank: str = Field(alias="divisionRank") + league_rank: str = Field(alias="leagueRank") + sport_rank: str = Field(alias="sportRank") + games_back: str = Field(alias="gamesBack") + last_updated: str = Field(alias="lastUpdated") + runs_allowed: int = Field(alias="runsAllowed") + runs_scored: int = Field(alias="runsScored") + division_champ: bool = Field(alias="divisionChamp") + has_wildcard: bool = Field(alias="hasWildcard") clinched: bool - elimination_number: str = Field(alias="eliminationnumber") - elimination_number_sport: str = Field(alias="eliminationnumbersport") - elimination_number_league: str = Field(alias="eliminationnumberleague") - elimination_number_division: str = Field(alias="eliminationnumberdivision") - elimination_number_conference: str = Field(alias="eliminationnumberconference") - wildcard_elimination_number: str = Field(alias="wildcardeliminationnumber") - run_differential: int = Field(alias="rundifferential") - wildcard_rank: Optional[str] = Field(default=None, alias="wildcardrank") - wildcard_leader: Optional[bool] = Field(default=None, alias="wildcardleader") - magic_number: Optional[str] = Field(default=None, alias="magicnumber") - clinch_indicator: Optional[str] = Field(default=None, alias="clinchindicator") + elimination_number: str = Field(alias="eliminationNumber") + elimination_number_sport: str = Field(alias="eliminationNumberSport") + elimination_number_league: str = Field(alias="eliminationNumberLeague") + elimination_number_division: str = Field(alias="eliminationNumberDivision") + elimination_number_conference: str = Field(alias="eliminationNumberConference") + wildcard_elimination_number: Optional[str] = Field(default=None, alias="wildcardEliminationNumber") + run_differential: int = Field(alias="runDifferential") + wildcard_rank: Optional[str] = Field(default=None, alias="wildcardRank") + wildcard_leader: Optional[bool] = Field(default=None, alias="wildcardLeader") + magic_number: Optional[str] = Field(default=None, alias="magicNumber") + clinch_indicator: Optional[str] = Field(default=None, alias="clinchIndicator") diff --git a/mlbstatsapi/models/standings/standings.py b/mlbstatsapi/models/standings/standings.py index d64c54c5..3dae0b56 100644 --- a/mlbstatsapi/models/standings/standings.py +++ b/mlbstatsapi/models/standings/standings.py @@ -28,10 +28,10 @@ class Standings(MLBBaseModel): roundrobin : dict Roundrobin data (if applicable). """ - standings_type: str = Field(alias="standingstype") + standings_type: str = Field(alias="standingsType") league: League division: Division - last_updated: str = Field(alias="lastupdated") - team_records: List[TeamRecords] = Field(alias="teamrecords") + last_updated: str = Field(alias="lastUpdated") + team_records: List[TeamRecords] = Field(alias="teamRecords") sport: Optional[Sport] = None roundrobin: Optional[dict] = None diff --git a/mlbstatsapi/models/stats/catching.py b/mlbstatsapi/models/stats/catching.py index c34a1f59..14769e68 100644 --- a/mlbstatsapi/models/stats/catching.py +++ b/mlbstatsapi/models/stats/catching.py @@ -76,36 +76,36 @@ class SimpleCatchingSplit(MLBBaseModel): The number of pickoff attempts. """ age: Optional[int] = None - games_played: Optional[int] = Field(default=None, alias="gamesplayed") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") runs: Optional[int] = None - home_runs: Optional[int] = Field(default=None, alias="homeruns") + home_runs: Optional[int] = Field(default=None, alias="homeRuns") strikeouts: Optional[int] = None - base_on_balls: Optional[int] = Field(default=None, alias="baseonballs") - intentional_walks: Optional[int] = Field(default=None, alias="intentionalwalks") + base_on_balls: Optional[int] = Field(default=None, alias="baseOnBalls") + intentional_walks: Optional[int] = Field(default=None, alias="intentionalWalks") hits: Optional[int] = None - hit_by_pitch: Optional[int] = Field(default=None, alias="hitbypitch") + hit_by_pitch: Optional[int] = Field(default=None, alias="hitByPitch") avg: Optional[str] = None - at_bats: Optional[int] = Field(default=None, alias="atbats") + at_bats: Optional[int] = Field(default=None, alias="atBats") obp: Optional[str] = None slg: Optional[str] = None ops: Optional[str] = None - caught_stealing: Optional[int] = Field(default=None, alias="caughtstealing") - caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtstealingpercentage") - stolen_bases: Optional[int] = Field(default=None, alias="stolenbases") - stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenbasepercentage") - earned_runs: Optional[int] = Field(default=None, alias="earnedruns") - batters_faced: Optional[int] = Field(default=None, alias="battersfaced") - games_pitched: Optional[int] = Field(default=None, alias="gamespitched") - hit_batsmen: Optional[int] = Field(default=None, alias="hitbatsmen") - wild_pitches: Optional[int] = Field(default=None, alias="wildpitches") + caught_stealing: Optional[int] = Field(default=None, alias="caughtStealing") + caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtStealingPercentage") + stolen_bases: Optional[int] = Field(default=None, alias="stolenBases") + stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenBasePercentage") + earned_runs: Optional[int] = Field(default=None, alias="earnedRuns") + batters_faced: Optional[int] = Field(default=None, alias="battersFaced") + games_pitched: Optional[int] = Field(default=None, alias="gamesPitched") + hit_batsmen: Optional[int] = Field(default=None, alias="hitBatsmen") + wild_pitches: Optional[int] = Field(default=None, alias="wildPitches") pickoffs: Optional[int] = None - total_bases: Optional[int] = Field(default=None, alias="totalbases") - strikeout_walk_ratio: Optional[str] = Field(default=None, alias="strikeoutwalkratio") - catchers_interference: Optional[int] = Field(default=None, alias="catchersinterference") - sac_bunts: Optional[int] = Field(default=None, alias="sacbunts") - sac_flies: Optional[int] = Field(default=None, alias="sacflies") - passed_ball: Optional[int] = Field(default=None, alias="passedball") - pickoff_attempts: Optional[int] = Field(default=None, alias="pickoffattempts") + total_bases: Optional[int] = Field(default=None, alias="totalBases") + strikeout_walk_ratio: Optional[str] = Field(default=None, alias="strikeoutWalkRatio") + catchers_interference: Optional[int] = Field(default=None, alias="catchersInterference") + sac_bunts: Optional[int] = Field(default=None, alias="sacBunts") + sac_flies: Optional[int] = Field(default=None, alias="sacFlies") + passed_ball: Optional[int] = Field(default=None, alias="passedBall") + pickoff_attempts: Optional[int] = Field(default=None, alias="pickoffAttempts") class CatchingSeason(Split): @@ -217,8 +217,8 @@ class CatchingGameLog(Split): The opponent. """ _stat: ClassVar[List[str]] = ['gameLog'] - is_home: bool = Field(alias="ishome") - is_win: bool = Field(alias="iswin") + is_home: bool = Field(alias="isHome") + is_win: bool = Field(alias="isWin") date: str game: Game opponent: Team @@ -262,7 +262,7 @@ class CatchingByDayOfWeek(Split): The catching split stat. """ _stat: ClassVar[List[str]] = ['byDayOfWeek'] - day_of_week: int = Field(alias="dayofweek") + day_of_week: int = Field(alias="dayOfWeek") stat: SimpleCatchingSplit @@ -278,7 +278,7 @@ class CatchingHomeAndAway(Split): The catching split stat. """ _stat: ClassVar[List[str]] = ['homeAndAway'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimpleCatchingSplit @@ -294,5 +294,5 @@ class CatchingWinLoss(Split): The catching split stat. """ _stat: ClassVar[List[str]] = ['winLoss'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimpleCatchingSplit diff --git a/mlbstatsapi/models/stats/fielding.py b/mlbstatsapi/models/stats/fielding.py index 6b392e7e..d13eeaf7 100644 --- a/mlbstatsapi/models/stats/fielding.py +++ b/mlbstatsapi/models/stats/fielding.py @@ -64,28 +64,28 @@ class SimpleFieldingSplit(MLBBaseModel): """ age: Optional[int] = None position: Optional[Position] = None - games_played: Optional[int] = Field(default=None, alias="gamesplayed") - games_started: Optional[int] = Field(default=None, alias="gamesstarted") - caught_stealing: Optional[int] = Field(default=None, alias="caughtstealing") - caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtstealingpercentage") - stolen_bases: Optional[int] = Field(default=None, alias="stolenbases") - stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenbasepercentage") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") + games_started: Optional[int] = Field(default=None, alias="gamesStarted") + caught_stealing: Optional[int] = Field(default=None, alias="caughtStealing") + caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtStealingPercentage") + stolen_bases: Optional[int] = Field(default=None, alias="stolenBases") + stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenBasePercentage") assists: Optional[int] = None putouts: Optional[int] = None errors: Optional[int] = None chances: Optional[int] = None fielding: Optional[str] = None - range_factor_per_game: Optional[str] = Field(default=None, alias="rangefactorpergame") - range_factor_per_9_inn: Optional[str] = Field(default=None, alias="rangefactorper9inn") + range_factor_per_game: Optional[str] = Field(default=None, alias="rangeFactorPerGame") + range_factor_per_9_inn: Optional[str] = Field(default=None, alias="rangeFactorPer9Inn") innings: Optional[str] = None games: Optional[int] = None - passed_ball: Optional[int] = Field(default=None, alias="passedball") - double_plays: Optional[int] = Field(default=None, alias="doubleplays") - triple_plays: Optional[int] = Field(default=None, alias="tripleplays") - catcher_era: Optional[str] = Field(default=None, alias="catcherera") - catchers_interference: Optional[int] = Field(default=None, alias="catchersinterference") - wild_pitches: Optional[int] = Field(default=None, alias="wildpitches") - throwing_errors: Optional[int] = Field(default=None, alias="throwingerrors") + passed_ball: Optional[int] = Field(default=None, alias="passedBall") + double_plays: Optional[int] = Field(default=None, alias="doublePlays") + triple_plays: Optional[int] = Field(default=None, alias="triplePlays") + catcher_era: Optional[str] = Field(default=None, alias="catcherEra") + catchers_interference: Optional[int] = Field(default=None, alias="catchersInterference") + wild_pitches: Optional[int] = Field(default=None, alias="wildPitches") + throwing_errors: Optional[int] = Field(default=None, alias="throwingErrors") pickoffs: Optional[int] = None @field_validator('position', mode='before') @@ -277,7 +277,7 @@ class FieldingHomeAndAway(Split): The fielding split stat. """ _stat: ClassVar[List[str]] = ['homeAndAway'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimpleFieldingSplit @@ -293,7 +293,7 @@ class FieldingHomeAndAwayPlayoffs(Split): The fielding split stat. """ _stat: ClassVar[List[str]] = ['homeAndAwayPlayoffs'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimpleFieldingSplit @@ -348,7 +348,7 @@ class FieldingWinLoss(Split): The fielding split stat. """ _stat: ClassVar[List[str]] = ['winLoss'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimpleFieldingSplit @@ -364,7 +364,7 @@ class FieldingWinLossPlayoffs(Split): The fielding split stat. """ _stat: ClassVar[List[str]] = ['winLossPlayoffs'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimpleFieldingSplit @@ -380,7 +380,7 @@ class FieldingByDayOfWeek(Split): The fielding split stat. """ _stat: ClassVar[List[str]] = ['byDayOfWeek'] - day_of_week: str = Field(alias="dayofweek") + day_of_week: str = Field(alias="dayOfWeek") stat: SimpleFieldingSplit @@ -476,8 +476,8 @@ class FieldingGameLog(Split): """ _stat: ClassVar[List[str]] = ['gameLog'] date: str - is_home: bool = Field(alias="ishome") - is_win: bool = Field(alias="iswin") + is_home: bool = Field(alias="isHome") + is_win: bool = Field(alias="isWin") stat: SimpleFieldingSplit opponent: Optional[Team] = None position: Optional[Position] = None diff --git a/mlbstatsapi/models/stats/game.py b/mlbstatsapi/models/stats/game.py index 47268e5c..9c4b9824 100644 --- a/mlbstatsapi/models/stats/game.py +++ b/mlbstatsapi/models/stats/game.py @@ -19,10 +19,10 @@ class SimpleGameStats(MLBBaseModel): last_date_played : str Last date of the game played. """ - first_date_played: str = Field(alias="firstdateplayed") - games_played: int = Field(alias="gamesplayed") - games_started: int = Field(alias="gamesstarted") - last_date_played: str = Field(alias="lastdateplayed") + first_date_played: str = Field(alias="firstDatePlayed") + games_played: int = Field(alias="gamesPlayed") + games_started: int = Field(alias="gamesStarted") + last_date_played: str = Field(alias="lastDatePlayed") class SeasonGame(Split): @@ -58,10 +58,10 @@ class CareerRegularSeasonGame(Split): Last date of the game played. """ _type: ClassVar[List[str]] = ['careerRegularSeason'] - first_date_played: Optional[str] = Field(default=None, alias="firstdateplayed") - games_played: Optional[int] = Field(default=None, alias="gamesplayed") - games_started: Optional[int] = Field(default=None, alias="gamesstarted") - last_date_played: Optional[str] = Field(default=None, alias="lastdateplayed") + first_date_played: Optional[str] = Field(default=None, alias="firstDatePlayed") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") + games_started: Optional[int] = Field(default=None, alias="gamesStarted") + last_date_played: Optional[str] = Field(default=None, alias="lastDatePlayed") class CareerPlayoffsGame(Split): @@ -80,7 +80,7 @@ class CareerPlayoffsGame(Split): Last date of the game played. """ _type: ClassVar[List[str]] = ['careerPlayoffs'] - first_date_played: Optional[str] = Field(default=None, alias="firstdateplayed") - games_played: Optional[int] = Field(default=None, alias="gamesplayed") - games_started: Optional[int] = Field(default=None, alias="gamesstarted") - last_date_played: Optional[str] = Field(default=None, alias="lastdateplayed") + first_date_played: Optional[str] = Field(default=None, alias="firstDatePlayed") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") + games_started: Optional[int] = Field(default=None, alias="gamesStarted") + last_date_played: Optional[str] = Field(default=None, alias="lastDatePlayed") diff --git a/mlbstatsapi/models/stats/hitting.py b/mlbstatsapi/models/stats/hitting.py index a7b822a4..a09d3412 100644 --- a/mlbstatsapi/models/stats/hitting.py +++ b/mlbstatsapi/models/stats/hitting.py @@ -78,36 +78,36 @@ class AdvancedHittingSplit(MLBBaseModel): The amount of line hits. """ age: Optional[int] = None - plate_appearances: Optional[int] = Field(default=None, alias="plateappearances") - total_bases: Optional[int] = Field(default=None, alias="totalbases") - left_on_base: Optional[int] = Field(default=None, alias="leftonbase") - sac_bunts: Optional[int] = Field(default=None, alias="sacbunts") - sac_flies: Optional[int] = Field(default=None, alias="sacflies") + plate_appearances: Optional[int] = Field(default=None, alias="plateAppearances") + total_bases: Optional[int] = Field(default=None, alias="totalBases") + left_on_base: Optional[int] = Field(default=None, alias="leftOnBase") + sac_bunts: Optional[int] = Field(default=None, alias="sacBunts") + sac_flies: Optional[int] = Field(default=None, alias="sacFlies") babip: Optional[str] = None - extra_base_hits: Optional[int] = Field(default=None, alias="extrabasehits") - hit_by_pitch: Optional[int] = Field(default=None, alias="hitbypitch") + extra_base_hits: Optional[int] = Field(default=None, alias="extraBaseHits") + hit_by_pitch: Optional[int] = Field(default=None, alias="hitByPitch") gidp: Optional[int] = None - gidp_opp: Optional[int] = Field(default=None, alias="gidpopp") - number_of_pitches: Optional[int] = Field(default=None, alias="numberofpitches") - pitches_per_plate_appearance: Optional[str] = Field(default=None, alias="pitchesperplateappearance") - walks_per_plate_appearance: Optional[str] = Field(default=None, alias="walksperplateappearance") - strikeouts_per_plate_appearance: Optional[str] = Field(default=None, alias="strikeoutsperplateappearance") - home_runs_per_plate_appearance: Optional[str] = Field(default=None, alias="homerunsperplateappearance") - walks_per_strikeout: Optional[str] = Field(default=None, alias="walksperstrikeout") + gidp_opp: Optional[int] = Field(default=None, alias="gidpOpp") + number_of_pitches: Optional[int] = Field(default=None, alias="numberOfPitches") + pitches_per_plate_appearance: Optional[str] = Field(default=None, alias="pitchesPerPlateAppearance") + walks_per_plate_appearance: Optional[str] = Field(default=None, alias="walksPerPlateAppearance") + strikeouts_per_plate_appearance: Optional[str] = Field(default=None, alias="strikeoutsPerPlateAppearance") + home_runs_per_plate_appearance: Optional[str] = Field(default=None, alias="homeRunsPerPlateAppearance") + walks_per_strikeout: Optional[str] = Field(default=None, alias="walksPerStrikeout") iso: Optional[str] = None - reached_on_error: Optional[int] = Field(default=None, alias="reachedonerror") + reached_on_error: Optional[int] = Field(default=None, alias="reachedOnError") walkoffs: Optional[int] = None flyouts: Optional[int] = None - total_swings: Optional[int] = Field(default=None, alias="totalswings") - swing_and_misses: Optional[int] = Field(default=None, alias="swingandmisses") - balls_in_play: Optional[int] = Field(default=None, alias="ballsinplay") + total_swings: Optional[int] = Field(default=None, alias="totalSwings") + swing_and_misses: Optional[int] = Field(default=None, alias="swingAndMisses") + balls_in_play: Optional[int] = Field(default=None, alias="ballsInPlay") popouts: Optional[int] = None lineouts: Optional[int] = None groundouts: Optional[int] = None - fly_hits: Optional[int] = Field(default=None, alias="flyhits") - pop_hits: Optional[int] = Field(default=None, alias="pophits") - ground_hits: Optional[int] = Field(default=None, alias="groundhits") - line_hits: Optional[int] = Field(default=None, alias="linehits") + fly_hits: Optional[int] = Field(default=None, alias="flyHits") + pop_hits: Optional[int] = Field(default=None, alias="popHits") + ground_hits: Optional[int] = Field(default=None, alias="groundHits") + line_hits: Optional[int] = Field(default=None, alias="lineHits") class SimpleHittingSplit(MLBBaseModel): @@ -190,41 +190,41 @@ class SimpleHittingSplit(MLBBaseModel): The number of at bats per home run of the batter. """ age: Optional[int] = None - games_played: Optional[int] = Field(default=None, alias="gamesplayed") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") flyouts: Optional[int] = None groundouts: Optional[int] = None airouts: Optional[int] = None runs: Optional[int] = None doubles: Optional[int] = None triples: Optional[int] = None - home_runs: Optional[int] = Field(default=None, alias="homeruns") + home_runs: Optional[int] = Field(default=None, alias="homeRuns") strikeouts: Optional[int] = None - base_on_balls: Optional[int] = Field(default=None, alias="baseonballs") - intentional_walks: Optional[int] = Field(default=None, alias="intentionalwalks") + base_on_balls: Optional[int] = Field(default=None, alias="baseOnBalls") + intentional_walks: Optional[int] = Field(default=None, alias="intentionalWalks") hits: Optional[int] = None - hit_by_pitch: Optional[int] = Field(default=None, alias="hitbypitch") + hit_by_pitch: Optional[int] = Field(default=None, alias="hitByPitch") avg: Optional[str] = None - at_bats: Optional[int] = Field(default=None, alias="atbats") + at_bats: Optional[int] = Field(default=None, alias="atBats") obp: Optional[str] = None slg: Optional[str] = None ops: Optional[str] = None - caught_stealing: Optional[int] = Field(default=None, alias="caughtstealing") - caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtstealingpercentage") - stolen_bases: Optional[int] = Field(default=None, alias="stolenbases") - stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenbasepercentage") - ground_into_double_play: Optional[int] = Field(default=None, alias="groundintodoubleplay") - ground_into_triple_play: Optional[int] = Field(default=None, alias="groundintotripleplay") - number_of_pitches: Optional[int] = Field(default=None, alias="numberofpitches") - plate_appearances: Optional[int] = Field(default=None, alias="plateappearances") - total_bases: Optional[int] = Field(default=None, alias="totalbases") + caught_stealing: Optional[int] = Field(default=None, alias="caughtStealing") + caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtStealingPercentage") + stolen_bases: Optional[int] = Field(default=None, alias="stolenBases") + stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenBasePercentage") + ground_into_double_play: Optional[int] = Field(default=None, alias="groundIntoDoublePlay") + ground_into_triple_play: Optional[int] = Field(default=None, alias="groundIntoTriplePlay") + number_of_pitches: Optional[int] = Field(default=None, alias="numberOfPitches") + plate_appearances: Optional[int] = Field(default=None, alias="plateAppearances") + total_bases: Optional[int] = Field(default=None, alias="totalBases") rbi: Optional[int] = None - left_on_base: Optional[int] = Field(default=None, alias="leftonbase") - sac_bunts: Optional[int] = Field(default=None, alias="sacbunts") - sac_flies: Optional[int] = Field(default=None, alias="sacflies") + left_on_base: Optional[int] = Field(default=None, alias="leftOnBase") + sac_bunts: Optional[int] = Field(default=None, alias="sacBunts") + sac_flies: Optional[int] = Field(default=None, alias="sacFlies") babip: Optional[str] = None - groundouts_to_airouts: Optional[str] = Field(default=None, alias="groundoutstoairouts") - catchers_interference: Optional[int] = Field(default=None, alias="catchersinterference") - at_bats_per_home_run: Optional[str] = Field(default=None, alias="atbatsperhomerun") + groundouts_to_airouts: Optional[str] = Field(default=None, alias="groundoutsToAirouts") + catchers_interference: Optional[int] = Field(default=None, alias="catchersInterference") + at_bats_per_home_run: Optional[str] = Field(default=None, alias="atBatsPerHomeRun") class HittingWinLoss(Split): @@ -239,7 +239,7 @@ class HittingWinLoss(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['winLoss'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimpleHittingSplit @@ -255,7 +255,7 @@ class HittingWinLossPlayoffs(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['winLossPlayoffs'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimpleHittingSplit @@ -271,7 +271,7 @@ class HittingHomeAndAway(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['homeAndAway'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimpleHittingSplit @@ -287,7 +287,7 @@ class HittingHomeAndAwayPlayoffs(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['homeAndAwayPlayoffs'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimpleHittingSplit @@ -400,7 +400,7 @@ class OpponentsFacedHitting(Split): _stat: ClassVar[List[str]] = ['opponentsFaced'] group: str batter: Batter - fielding_team: Team = Field(alias="fieldingteam") + fielding_team: Team = Field(alias="fieldingTeam") pitcher: Pitcher @@ -439,12 +439,12 @@ class HittingGameLog(Split): Team of the opponent. """ _stat: ClassVar[List[str]] = ['gameLog'] - is_home: bool = Field(alias="ishome") - is_win: bool = Field(alias="iswin") + is_home: bool = Field(alias="isHome") + is_win: bool = Field(alias="isWin") game: Game date: str opponent: Team - positions_played: Optional[List[Position]] = Field(default=[], alias="positionsplayed") + positions_played: Optional[List[Position]] = Field(default=[], alias="positionsPlayed") stat: Optional[SimpleHittingSplit] = None @field_validator('stat', mode='before') @@ -489,15 +489,15 @@ class HittingPlay(MLBBaseModel): """ details: PlayDetails count: Count - is_pitch: bool = Field(alias="ispitch") - pitch_number: Optional[int] = Field(default=None, alias="pitchnumber") - at_bat_number: Optional[int] = Field(default=None, alias="atbatnumber") + is_pitch: bool = Field(alias="isPitch") + pitch_number: Optional[int] = Field(default=None, alias="pitchNumber") + at_bat_number: Optional[int] = Field(default=None, alias="atBatNumber") index: Optional[int] = None - play_id: Optional[str] = Field(default=None, alias="playid") - pitch_data: Optional[PitchData] = Field(default=None, alias="pitchdata") - hit_data: Optional[HitData] = Field(default=None, alias="hitdata") - start_time: Optional[str] = Field(default=None, alias="starttime") - end_time: Optional[str] = Field(default=None, alias="endtime") + play_id: Optional[str] = Field(default=None, alias="playId") + pitch_data: Optional[PitchData] = Field(default=None, alias="pitchData") + hit_data: Optional[HitData] = Field(default=None, alias="hitData") + start_time: Optional[str] = Field(default=None, alias="startTime") + end_time: Optional[str] = Field(default=None, alias="endTime") type: Optional[str] = None @field_validator('pitch_data', 'hit_data', mode='before') @@ -534,7 +534,7 @@ class HittingPlayLog(Split): stat: HittingPlay opponent: Optional[Team] = None date: Optional[str] = None - is_home: Optional[bool] = Field(default=None, alias="ishome") + is_home: Optional[bool] = Field(default=None, alias="isHome") pitcher: Optional[Pitcher] = None batter: Optional[Batter] = None game: Optional[Game] = None @@ -583,11 +583,11 @@ class HittingPitchLog(Split): stat: HittingPlay opponent: Team date: str - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") pitcher: Pitcher batter: Batter game: Game - play_id: Optional[str] = Field(default=None, alias="playid") + play_id: Optional[str] = Field(default=None, alias="playId") @field_validator('stat', mode='before') @classmethod @@ -694,7 +694,7 @@ class HittingDayOfWeek(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['byDayOfWeek'] - day_of_week: int = Field(alias="dayofweek") + day_of_week: int = Field(alias="dayOfWeek") stat: SimpleHittingSplit @@ -710,7 +710,7 @@ class HittingDayOfWeekPlayoffs(Split): The hitting split stat. """ _stat: ClassVar[List[str]] = ['byDayOfWeekPlayoffs'] - day_of_week: int = Field(alias="dayofweek") + day_of_week: int = Field(alias="dayOfWeek") stat: SimpleHittingSplit diff --git a/mlbstatsapi/models/stats/pitching.py b/mlbstatsapi/models/stats/pitching.py index 92190fb7..48a5b1eb 100644 --- a/mlbstatsapi/models/stats/pitching.py +++ b/mlbstatsapi/models/stats/pitching.py @@ -146,70 +146,70 @@ class SimplePitchingSplit(MLBBaseModel): """ summary: Optional[str] = None age: Optional[int] = None - games_played: Optional[int] = Field(default=None, alias="gamesplayed") - games_started: Optional[int] = Field(default=None, alias="gamesstarted") + games_played: Optional[int] = Field(default=None, alias="gamesPlayed") + games_started: Optional[int] = Field(default=None, alias="gamesStarted") flyouts: Optional[int] = None groundouts: Optional[int] = None airouts: Optional[int] = None runs: Optional[int] = None doubles: Optional[int] = None triples: Optional[int] = None - home_runs: Optional[int] = Field(default=None, alias="homeruns") + home_runs: Optional[int] = Field(default=None, alias="homeRuns") strikeouts: Optional[int] = None - base_on_balls: Optional[int] = Field(default=None, alias="baseonballs") - intentional_walks: Optional[int] = Field(default=None, alias="intentionalwalks") + base_on_balls: Optional[int] = Field(default=None, alias="baseOnBalls") + intentional_walks: Optional[int] = Field(default=None, alias="intentionalWalks") hits: Optional[int] = None - hit_by_pitch: Optional[int] = Field(default=None, alias="hitbypitch") + hit_by_pitch: Optional[int] = Field(default=None, alias="hitByPitch") avg: Optional[str] = None - at_bats: Optional[int] = Field(default=None, alias="atbats") + at_bats: Optional[int] = Field(default=None, alias="atBats") obp: Optional[str] = None slg: Optional[str] = None ops: Optional[str] = None - caught_stealing: Optional[int] = Field(default=None, alias="caughtstealing") - caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtstealingpercentage") - stolen_bases: Optional[int] = Field(default=None, alias="stolenbases") - stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenbasepercentage") - ground_into_double_play: Optional[int] = Field(default=None, alias="groundintodoubleplay") - number_of_pitches: Optional[int] = Field(default=None, alias="numberofpitches") + caught_stealing: Optional[int] = Field(default=None, alias="caughtStealing") + caught_stealing_percentage: Optional[str] = Field(default=None, alias="caughtStealingPercentage") + stolen_bases: Optional[int] = Field(default=None, alias="stolenBases") + stolen_base_percentage: Optional[str] = Field(default=None, alias="stolenBasePercentage") + ground_into_double_play: Optional[int] = Field(default=None, alias="groundIntoDoublePlay") + number_of_pitches: Optional[int] = Field(default=None, alias="numberOfPitches") era: Optional[str] = None - innings_pitched: Optional[str] = Field(default=None, alias="inningspitched") + innings_pitched: Optional[str] = Field(default=None, alias="inningsPitched") wins: Optional[int] = None losses: Optional[int] = None saves: Optional[int] = None - save_opportunities: Optional[int] = Field(default=None, alias="saveopportunities") + save_opportunities: Optional[int] = Field(default=None, alias="saveOpportunities") holds: Optional[int] = None - blown_saves: Optional[int] = Field(default=None, alias="blownsaves") - earned_runs: Optional[int] = Field(default=None, alias="earnedruns") + blown_saves: Optional[int] = Field(default=None, alias="blownSaves") + earned_runs: Optional[int] = Field(default=None, alias="earnedRuns") whip: Optional[str] = None outs: Optional[int] = None - games_pitched: Optional[int] = Field(default=None, alias="gamespitched") - complete_games: Optional[int] = Field(default=None, alias="completegames") + games_pitched: Optional[int] = Field(default=None, alias="gamesPitched") + complete_games: Optional[int] = Field(default=None, alias="completeGames") shutouts: Optional[int] = None strikes: Optional[int] = None - strike_percentage: Optional[str] = Field(default=None, alias="strikepercentage") - hit_batsmen: Optional[int] = Field(default=None, alias="hitbatsmen") + strike_percentage: Optional[str] = Field(default=None, alias="strikePercentage") + hit_batsmen: Optional[int] = Field(default=None, alias="hitBatsmen") balks: Optional[int] = None - wild_pitches: Optional[int] = Field(default=None, alias="wildpitches") + wild_pitches: Optional[int] = Field(default=None, alias="wildPitches") pickoffs: Optional[int] = None - total_bases: Optional[int] = Field(default=None, alias="totalbases") - groundouts_to_airouts: Optional[str] = Field(default=None, alias="groundoutstoairouts") - win_percentage: Optional[str] = Field(default=None, alias="winpercentage") - pitches_per_inning: Optional[str] = Field(default=None, alias="pitchesperinning") - games_finished: Optional[int] = Field(default=None, alias="gamesfinished") - strikeout_walk_ratio: Optional[str] = Field(default=None, alias="strikeoutwalkratio") - strikeouts_per_9_inn: Optional[str] = Field(default=None, alias="strikeoutsper9inn") - walks_per_9_inn: Optional[str] = Field(default=None, alias="walksper9inn") - hits_per_9_inn: Optional[str] = Field(default=None, alias="hitsper9inn") - runs_scored_per_9: Optional[str] = Field(default=None, alias="runsscoredper9") - home_runs_per_9: Optional[str] = Field(default=None, alias="homerunsper9") - catchers_interference: Optional[int] = Field(default=None, alias="catchersinterference") - sac_bunts: Optional[int] = Field(default=None, alias="sacbunts") - sac_flies: Optional[int] = Field(default=None, alias="sacflies") - batters_faced: Optional[int] = Field(default=None, alias="battersfaced") - inherited_runners: Optional[int] = Field(default=None, alias="inheritedrunners") - inherited_runners_scored: Optional[int] = Field(default=None, alias="inheritedrunnersscored") + total_bases: Optional[int] = Field(default=None, alias="totalBases") + groundouts_to_airouts: Optional[str] = Field(default=None, alias="groundoutsToAirouts") + win_percentage: Optional[str] = Field(default=None, alias="winPercentage") + pitches_per_inning: Optional[str] = Field(default=None, alias="pitchesPerInning") + games_finished: Optional[int] = Field(default=None, alias="gamesFinished") + strikeout_walk_ratio: Optional[str] = Field(default=None, alias="strikeoutWalkRatio") + strikeouts_per_9_inn: Optional[str] = Field(default=None, alias="strikeoutsPer9Inn") + walks_per_9_inn: Optional[str] = Field(default=None, alias="walksPer9Inn") + hits_per_9_inn: Optional[str] = Field(default=None, alias="hitsPer9Inn") + runs_scored_per_9: Optional[str] = Field(default=None, alias="runsScoredPer9") + home_runs_per_9: Optional[str] = Field(default=None, alias="homeRunsPer9") + catchers_interference: Optional[int] = Field(default=None, alias="catchersInterference") + sac_bunts: Optional[int] = Field(default=None, alias="sacBunts") + sac_flies: Optional[int] = Field(default=None, alias="sacFlies") + batters_faced: Optional[int] = Field(default=None, alias="battersFaced") + inherited_runners: Optional[int] = Field(default=None, alias="inheritedRunners") + inherited_runners_scored: Optional[int] = Field(default=None, alias="inheritedRunnersScored") balls: Optional[int] = None - outs_pitched: Optional[int] = Field(default=None, alias="outspitched") + outs_pitched: Optional[int] = Field(default=None, alias="outsPitched") rbi: Optional[int] = None @@ -317,61 +317,61 @@ class AdvancedPitchingSplit(MLBBaseModel): The number of bequeathed runners scored. """ age: Optional[int] = None - winning_percentage: Optional[str] = Field(default=None, alias="winningpercentage") - runs_scored_per_9: Optional[str] = Field(default=None, alias="runsscoredper9") - batters_faced: Optional[int] = Field(default=None, alias="battersfaced") + winning_percentage: Optional[str] = Field(default=None, alias="winningPercentage") + runs_scored_per_9: Optional[str] = Field(default=None, alias="runsScoredPer9") + batters_faced: Optional[int] = Field(default=None, alias="battersFaced") babip: Optional[str] = None obp: Optional[str] = None slg: Optional[str] = None ops: Optional[str] = None - strikeouts_per_9: Optional[str] = Field(default=None, alias="strikeoutsper9") - base_on_balls_per_9: Optional[str] = Field(default=None, alias="baseonballsper9") - home_runs_per_9: Optional[str] = Field(default=None, alias="homerunsper9") - hits_per_9: Optional[str] = Field(default=None, alias="hitsper9") - strikeouts_to_walks: Optional[str] = Field(default=None, alias="strikesoutstowalks") - stolen_bases: Optional[int] = Field(default=None, alias="stolenbases") - caught_stealing: Optional[int] = Field(default=None, alias="caughtstealing") - quality_starts: Optional[int] = Field(default=None, alias="qualitystarts") - games_finished: Optional[int] = Field(default=None, alias="gamesfinished") + strikeouts_per_9: Optional[str] = Field(default=None, alias="strikeoutsPer9") + base_on_balls_per_9: Optional[str] = Field(default=None, alias="baseOnBallsPer9") + home_runs_per_9: Optional[str] = Field(default=None, alias="homeRunsPer9") + hits_per_9: Optional[str] = Field(default=None, alias="hitsPer9") + strikeouts_to_walks: Optional[str] = Field(default=None, alias="strikeoutsToWalks") + stolen_bases: Optional[int] = Field(default=None, alias="stolenBases") + caught_stealing: Optional[int] = Field(default=None, alias="caughtStealing") + quality_starts: Optional[int] = Field(default=None, alias="qualityStarts") + games_finished: Optional[int] = Field(default=None, alias="gamesFinished") doubles: Optional[int] = None triples: Optional[int] = None gidp: Optional[int] = None - gidp_opp: Optional[int] = Field(default=None, alias="gidpopp") - wild_pitches: Optional[int] = Field(default=None, alias="wildpitches") + gidp_opp: Optional[int] = Field(default=None, alias="gidpOpp") + wild_pitches: Optional[int] = Field(default=None, alias="wildPitches") balks: Optional[int] = None pickoffs: Optional[int] = None - total_swings: Optional[int] = Field(default=None, alias="totalswings") - swing_and_misses: Optional[int] = Field(default=None, alias="swingandmisses") - strikeouts_minus_walks_percentage: Optional[str] = Field(default=None, alias="strikeoutsminuswalkspercentage") - gidp_percentage: Optional[str] = Field(default=None, alias="gidppercentage") - batters_faced_per_game: Optional[str] = Field(default=None, alias="battersfacedpergame") - bunts_failed: Optional[int] = Field(default=None, alias="buntsfailed") - bunts_missed_tipped: Optional[int] = Field(default=None, alias="buntsmissedtipped") - whiff_percentage: Optional[str] = Field(default=None, alias="whiffpercentage") - balls_in_play: Optional[int] = Field(default=None, alias="ballsinplay") - run_support: Optional[int] = Field(default=None, alias="runsupport") - strike_percentage: Optional[str] = Field(default=None, alias="strikepercentage") - pitches_per_inning: Optional[str] = Field(default=None, alias="pitchesperinning") - pitches_per_plate_appearance: Optional[str] = Field(default=None, alias="pitchesperplateappearance") - walks_per_plate_appearance: Optional[str] = Field(default=None, alias="walksperplateappearance") - strikeouts_per_plate_appearance: Optional[str] = Field(default=None, alias="strikeoutsperplateappearance") - home_runs_per_plate_appearance: Optional[str] = Field(default=None, alias="homerunsperplateappearance") - walks_per_strikeout: Optional[str] = Field(default=None, alias="walksperstrikeout") + total_swings: Optional[int] = Field(default=None, alias="totalSwings") + swing_and_misses: Optional[int] = Field(default=None, alias="swingAndMisses") + strikeouts_minus_walks_percentage: Optional[str] = Field(default=None, alias="strikeoutsMinusWalksPercentage") + gidp_percentage: Optional[str] = Field(default=None, alias="gidpPercentage") + batters_faced_per_game: Optional[str] = Field(default=None, alias="battersFacedPerGame") + bunts_failed: Optional[int] = Field(default=None, alias="buntsFailed") + bunts_missed_tipped: Optional[int] = Field(default=None, alias="buntsMissedTipped") + whiff_percentage: Optional[str] = Field(default=None, alias="whiffPercentage") + balls_in_play: Optional[int] = Field(default=None, alias="ballsInPlay") + run_support: Optional[int] = Field(default=None, alias="runSupport") + strike_percentage: Optional[str] = Field(default=None, alias="strikePercentage") + pitches_per_inning: Optional[str] = Field(default=None, alias="pitchesPerInning") + pitches_per_plate_appearance: Optional[str] = Field(default=None, alias="pitchesPerPlateAppearance") + walks_per_plate_appearance: Optional[str] = Field(default=None, alias="walksPerPlateAppearance") + strikeouts_per_plate_appearance: Optional[str] = Field(default=None, alias="strikeoutsPerPlateAppearance") + home_runs_per_plate_appearance: Optional[str] = Field(default=None, alias="homeRunsPerPlateAppearance") + walks_per_strikeout: Optional[str] = Field(default=None, alias="walksPerStrikeout") iso: Optional[str] = None flyouts: Optional[int] = None popouts: Optional[int] = None lineouts: Optional[int] = None groundouts: Optional[int] = None - fly_hits: Optional[int] = Field(default=None, alias="flyhits") - pop_hits: Optional[int] = Field(default=None, alias="pophits") - line_hits: Optional[int] = Field(default=None, alias="linehits") - ground_hits: Optional[int] = Field(default=None, alias="groundhits") - inherited_runners: Optional[int] = Field(default=None, alias="inheritedrunners") - inherited_runners_scored: Optional[int] = Field(default=None, alias="inheritedrunnersscored") - bequeathed_runners: Optional[int] = Field(default=None, alias="bequeathedrunners") - bequeathed_runners_scored: Optional[int] = Field(default=None, alias="bequeathedrunnersscored") - innings_pitched_per_game: Optional[str] = Field(default=None, alias="inningspitchedpergame") - flyball_percentage: Optional[str] = Field(default=None, alias="flyballpercentage") + fly_hits: Optional[int] = Field(default=None, alias="flyHits") + pop_hits: Optional[int] = Field(default=None, alias="popHits") + line_hits: Optional[int] = Field(default=None, alias="lineHits") + ground_hits: Optional[int] = Field(default=None, alias="groundHits") + inherited_runners: Optional[int] = Field(default=None, alias="inheritedRunners") + inherited_runners_scored: Optional[int] = Field(default=None, alias="inheritedRunnersScored") + bequeathed_runners: Optional[int] = Field(default=None, alias="bequeathedRunners") + bequeathed_runners_scored: Optional[int] = Field(default=None, alias="bequeathedRunnersScored") + innings_pitched_per_game: Optional[str] = Field(default=None, alias="inningsPitchedPerGame") + flyball_percentage: Optional[str] = Field(default=None, alias="flyballPercentage") class PitchingSabermetrics(Split): @@ -511,8 +511,8 @@ class PitchingGameLog(Split): The pitching split stat. """ _stat: ClassVar[List[str]] = ['gameLog'] - is_home: bool = Field(alias="ishome") - is_win: bool = Field(alias="iswin") + is_home: bool = Field(alias="isHome") + is_win: bool = Field(alias="isWin") game: Game date: str opponent: Team @@ -540,10 +540,10 @@ class PitchingPlay(MLBBaseModel): """ details: PlayDetails count: Count - pitch_number: int = Field(alias="pitchnumber") - at_bat_number: int = Field(alias="atbatnumber") - is_pitch: bool = Field(alias="ispitch") - play_id: str = Field(alias="playid") + pitch_number: int = Field(alias="pitchNumber") + at_bat_number: int = Field(alias="atBatNumber") + is_pitch: bool = Field(alias="isPitch") + play_id: str = Field(alias="playId") class PitchingLog(Split): @@ -574,7 +574,7 @@ class PitchingLog(Split): season: str opponent: Team date: str - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") pitcher: Pitcher batter: Batter game: Game @@ -616,7 +616,7 @@ class PitchingPlayLog(Split): season: str opponent: Team date: str - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") pitcher: Pitcher batter: Batter game: Game @@ -643,7 +643,7 @@ class PitchingByDateRange(Split): """ _stat: ClassVar[List[str]] = ['byDateRange'] stat: SimplePitchingSplit - day_of_week: Optional[int] = Field(default=None, alias="dayofweek") + day_of_week: Optional[int] = Field(default=None, alias="dayOfWeek") class PitchingByDateRangeAdvanced(Split): @@ -659,7 +659,7 @@ class PitchingByDateRangeAdvanced(Split): """ _stat: ClassVar[List[str]] = ['byDateRangeAdvanced'] stat: AdvancedPitchingSplit - day_of_week: Optional[int] = Field(default=None, alias="dayofweek") + day_of_week: Optional[int] = Field(default=None, alias="dayOfWeek") class PitchingByMonth(Split): @@ -707,7 +707,7 @@ class PitchingByDayOfWeek(Split): """ _stat: ClassVar[List[str]] = ['byDayOfWeek'] stat: SimplePitchingSplit - day_of_week: Optional[int] = Field(default=None, alias="dayofweek") + day_of_week: Optional[int] = Field(default=None, alias="dayOfWeek") class PitchingByDayOfWeekPlayOffs(Split): @@ -723,7 +723,7 @@ class PitchingByDayOfWeekPlayOffs(Split): """ _stat: ClassVar[List[str]] = ['byDayOfWeekPlayoffs'] stat: SimplePitchingSplit - day_of_week: Optional[int] = Field(default=None, alias="dayofweek") + day_of_week: Optional[int] = Field(default=None, alias="dayOfWeek") class PitchingHomeAndAway(Split): @@ -738,7 +738,7 @@ class PitchingHomeAndAway(Split): The pitching split stat. """ _stat: ClassVar[List[str]] = ['homeAndAway'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimplePitchingSplit @@ -754,7 +754,7 @@ class PitchingHomeAndAwayPlayoffs(Split): The pitching split stat. """ _stat: ClassVar[List[str]] = ['homeAndAwayPlayoffs'] - is_home: bool = Field(alias="ishome") + is_home: bool = Field(alias="isHome") stat: SimplePitchingSplit @@ -770,7 +770,7 @@ class PitchingWinLoss(Split): The pitching split stat. """ _stat: ClassVar[List[str]] = ['winLoss'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimplePitchingSplit @@ -786,7 +786,7 @@ class PitchingWinLossPlayoffs(Split): The pitching split stat. """ _stat: ClassVar[List[str]] = ['winLossPlayoffs'] - is_win: bool = Field(alias="iswin") + is_win: bool = Field(alias="isWin") stat: SimplePitchingSplit @@ -803,7 +803,7 @@ class PitchingRankings(Split): """ _stat: ClassVar[List[str]] = ['rankingsByYear'] stat: SimplePitchingSplit - outs_pitched: Optional[int] = Field(default=None, alias="outspitched") + outs_pitched: Optional[int] = Field(default=None, alias="outsPitched") class PitchingOpponentsFaced(Split): @@ -825,7 +825,7 @@ class PitchingOpponentsFaced(Split): group: str pitcher: Pitcher batter: Batter - batting_team: Team = Field(alias="battingteam") + batting_team: Team = Field(alias="battingTeam") class PitchingExpectedStatistics(Split): diff --git a/mlbstatsapi/models/stats/stats.py b/mlbstatsapi/models/stats/stats.py index 56b5bd41..ce118c34 100644 --- a/mlbstatsapi/models/stats/stats.py +++ b/mlbstatsapi/models/stats/stats.py @@ -27,8 +27,8 @@ class PitchArsenalSplit(MLBBaseModel): """ percentage: float count: int - total_pitches: int = Field(alias="totalpitches") - average_speed: float = Field(alias="averagespeed") + total_pitches: int = Field(alias="totalPitches") + average_speed: float = Field(alias="averageSpeed") type: CodeDesc @@ -50,7 +50,7 @@ class ExpectedStatistics(MLBBaseModel): avg: str slg: str woba: str - wobacon: str + wobacon: str = Field(alias="wobaCon") class Sabermetrics(MLBBaseModel): @@ -95,19 +95,19 @@ class Sabermetrics(MLBBaseModel): woba: Optional[float] = None wraa: Optional[float] = None wrc: Optional[float] = None - wrc_plus: Optional[float] = Field(default=None, alias="wrcplus") + wrc_plus: Optional[float] = Field(default=None, alias="wrcPlus") rar: Optional[float] = None war: Optional[float] = None batting: Optional[float] = None fielding: Optional[float] = None - base_running: Optional[float] = Field(default=None, alias="baserunning") + base_running: Optional[float] = Field(default=None, alias="baseRunning") positional: Optional[float] = None - w_league: Optional[float] = Field(default=None, alias="wleague") + w_league: Optional[float] = Field(default=None, alias="wLeague") replacement: Optional[float] = None spd: Optional[float] = None ubr: Optional[float] = None - w_gdp: Optional[float] = Field(default=None, alias="wgdp") - w_sb: Optional[float] = Field(default=None, alias="wsb") + w_gdp: Optional[float] = Field(default=None, alias="wGdp") + w_sb: Optional[float] = Field(default=None, alias="wSb") class Split(MLBBaseModel): @@ -138,9 +138,9 @@ class Split(MLBBaseModel): The league. """ season: Optional[str] = None - num_teams: Optional[int] = Field(default=None, alias="numteams") - num_leagues: Optional[int] = Field(default=None, alias="numleagues") - game_type: Optional[str] = Field(default=None, alias="gametype") + num_teams: Optional[int] = Field(default=None, alias="numTeams") + num_leagues: Optional[int] = Field(default=None, alias="numLeagues") + game_type: Optional[str] = Field(default=None, alias="gameType") rank: Optional[int] = None position: Optional[Position] = None team: Optional[Team] = None @@ -176,7 +176,7 @@ class Stat(MLBBaseModel): """ group: str type: str - total_splits: int = Field(alias="totalsplits") + total_splits: int = Field(alias="totalSplits") exemptions: Optional[List] = [] splits: Optional[List] = [] @@ -260,11 +260,11 @@ class Chart(MLBBaseModel): right_field : int Right field percentage. """ - left_field: int = Field(alias="leftfield") - left_center_field: int = Field(alias="leftcenterfield") - center_field: int = Field(alias="centerfield") - right_center_field: int = Field(alias="rightcenterfield") - right_field: int = Field(alias="rightfield") + left_field: int = Field(alias="leftField") + left_center_field: int = Field(alias="leftCenterField") + center_field: int = Field(alias="centerField") + right_center_field: int = Field(alias="rightCenterField") + right_field: int = Field(alias="rightField") class SprayCharts(Split): @@ -299,24 +299,24 @@ class OutsAboveAverage(Split): """ _stat: ClassVar[List[str]] = ['outsAboveAverage'] attempts: int - total_outs_above_average_back: int = Field(alias="totaloutsaboveaverageback") - total_outs_above_average_back_unrounded: int = Field(alias="totaloutsaboveaveragebackunrounded") - outs_above_average_back_straight: int = Field(alias="outsaboveaveragebackstraight") - outs_above_average_back_straight_unrounded: int = Field(alias="outsaboveaveragebackstraightunrounded") - outs_above_average_back_left: int = Field(alias="outsaboveaveragebackleft") - outs_above_average_back_left_unrounded: int = Field(alias="outsaboveaveragebackleftunrounded") - outs_above_average_back_right: int = Field(alias="outsaboveaveragebackright") - outs_above_average_back_right_unrounded: int = Field(alias="outsaboveaveragebackrightunrounded") - total_outs_above_average_in: int = Field(alias="totaloutsaboveaveragein") - total_outs_above_average_in_unrounded: int = Field(alias="totaloutsaboveaverageinunrounded") - outs_above_average_in_straight: int = Field(alias="outsaboveaverageinstraight") - outs_above_average_in_straight_unrounded: int = Field(alias="outsaboveaverageinstraightunrounded") - outs_above_average_in_left: int = Field(alias="outsaboveaverageinleft") - outs_above_average_in_left_unrounded: int = Field(alias="outsaboveaverageinleftunrounded") - outs_above_average_in_right: int = Field(alias="outsaboveaverageinright") - outs_above_average_in_right_unrounded: int = Field(alias="outsaboveaverageinrightunrounded") + total_outs_above_average_back: int = Field(alias="totalOutsAboveAverageBack") + total_outs_above_average_back_unrounded: int = Field(alias="totalOutsAboveAverageBackUnrounded") + outs_above_average_back_straight: int = Field(alias="outsAboveAverageBackStraight") + outs_above_average_back_straight_unrounded: int = Field(alias="outsAboveAverageBackStraightUnrounded") + outs_above_average_back_left: int = Field(alias="outsAboveAverageBackLeft") + outs_above_average_back_left_unrounded: int = Field(alias="outsAboveAverageBackLeftUnrounded") + outs_above_average_back_right: int = Field(alias="outsAboveAverageBackRight") + outs_above_average_back_right_unrounded: int = Field(alias="outsAboveAverageBackRightUnrounded") + total_outs_above_average_in: int = Field(alias="totalOutsAboveAverageIn") + total_outs_above_average_in_unrounded: int = Field(alias="totalOutsAboveAverageInUnrounded") + outs_above_average_in_straight: int = Field(alias="outsAboveAverageInStraight") + outs_above_average_in_straight_unrounded: int = Field(alias="outsAboveAverageInStraightUnrounded") + outs_above_average_in_left: int = Field(alias="outsAboveAverageInLeft") + outs_above_average_in_left_unrounded: int = Field(alias="outsAboveAverageInLeftUnrounded") + outs_above_average_in_right: int = Field(alias="outsAboveAverageInRight") + outs_above_average_in_right_unrounded: int = Field(alias="outsAboveAverageInRightUnrounded") player: Person - game_type: str = Field(alias="gametype") + game_type: str = Field(alias="gameType") class PlayerGameLogStat(Split): diff --git a/mlbstatsapi/models/teams/attributes.py b/mlbstatsapi/models/teams/attributes.py index 81307666..ec2a44c5 100644 --- a/mlbstatsapi/models/teams/attributes.py +++ b/mlbstatsapi/models/teams/attributes.py @@ -112,11 +112,11 @@ class Records(MLBBaseModel): expected_records : List[TypeRecords] A list of expected records. """ - split_records: Optional[List[TypeRecords]] = Field(default=None, alias="splitrecords") - division_records: Optional[List[DivisionRecords]] = Field(default=None, alias="divisionrecords") - overall_records: Optional[List[TypeRecords]] = Field(default=None, alias="overallrecords") - league_records: Optional[List[LeagueRecords]] = Field(default=None, alias="leaguerecords") - expected_records: Optional[List[TypeRecords]] = Field(default=None, alias="expectedrecords") + split_records: Optional[List[TypeRecords]] = Field(default=None, alias="splitRecords") + division_records: Optional[List[DivisionRecords]] = Field(default=None, alias="divisionRecords") + overall_records: Optional[List[TypeRecords]] = Field(default=None, alias="overallRecords") + league_records: Optional[List[LeagueRecords]] = Field(default=None, alias="leagueRecords") + expected_records: Optional[List[TypeRecords]] = Field(default=None, alias="expectedRecords") class TeamRecord(MLBBaseModel): @@ -152,16 +152,16 @@ class TeamRecord(MLBBaseModel): winning_percentage : str The winning percentage of the team. """ - games_played: int = Field(alias="gamesplayed") - wildcard_games_back: str = Field(alias="wildcardgamesback") - league_games_back: str = Field(alias="leaguegamesback") - spring_league_games_back: str = Field(alias="springleaguegamesback") - sport_games_back: str = Field(alias="sportgamesback") - division_games_back: str = Field(alias="divisiongamesback") - conference_games_back: str = Field(alias="conferencegamesback") - league_record: OverallLeagueRecord = Field(alias="leaguerecord") - records: Records - division_leader: bool = Field(alias="divisionleader") + games_played: int = Field(alias="gamesPlayed") + wildcard_games_back: Optional[str] = Field(default=None, alias="wildcardGamesBack") + league_games_back: str = Field(alias="leagueGamesBack") + spring_league_games_back: Optional[str] = Field(default=None, alias="springLeagueGamesBack") + sport_games_back: str = Field(alias="sportGamesBack") + division_games_back: str = Field(alias="divisionGamesBack") + conference_games_back: Optional[str] = Field(default=None, alias="conferenceGamesBack") + league_record: OverallLeagueRecord = Field(alias="leagueRecord") + records: Optional[Records] = None + division_leader: bool = Field(alias="divisionLeader") wins: int losses: int - winning_percentage: str = Field(alias="winningpercentage") + winning_percentage: str = Field(alias="winningPercentage") diff --git a/mlbstatsapi/models/teams/team.py b/mlbstatsapi/models/teams/team.py index c16063fb..ebe3d687 100644 --- a/mlbstatsapi/models/teams/team.py +++ b/mlbstatsapi/models/teams/team.py @@ -66,24 +66,24 @@ class Team(MLBBaseModel): id: int link: str name: Optional[str] = None - spring_league: Optional[League] = Field(default=None, alias="springleague") - all_star_status: Optional[str] = Field(default=None, alias="allstarstatus") + spring_league: Optional[League] = Field(default=None, alias="springLeague") + all_star_status: Optional[str] = Field(default=None, alias="allStarStatus") season: Optional[int] = None venue: Optional[Venue] = None - spring_venue: Optional[Venue] = Field(default=None, alias="springvenue") - team_code: Optional[str] = Field(default=None, alias="teamcode") - file_code: Optional[str] = Field(default=None, alias="filecode") + spring_venue: Optional[Venue] = Field(default=None, alias="springVenue") + team_code: Optional[str] = Field(default=None, alias="teamCode") + file_code: Optional[str] = Field(default=None, alias="fileCode") abbreviation: Optional[str] = None - team_name: Optional[str] = Field(default=None, alias="teamname") - location_name: Optional[str] = Field(default=None, alias="locationname") - first_year_of_play: Optional[str] = Field(default=None, alias="firstyearofplay") + team_name: Optional[str] = Field(default=None, alias="teamName") + location_name: Optional[str] = Field(default=None, alias="locationName") + first_year_of_play: Optional[str] = Field(default=None, alias="firstYearOfPlay") league: Optional[League] = None division: Optional[Division] = None sport: Optional[Sport] = None - short_name: Optional[str] = Field(default=None, alias="shortname") + short_name: Optional[str] = Field(default=None, alias="shortName") record: Optional[TeamRecord] = None - franchise_name: Optional[str] = Field(default=None, alias="franchisename") - club_name: Optional[str] = Field(default=None, alias="clubname") + franchise_name: Optional[str] = Field(default=None, alias="franchiseName") + club_name: Optional[str] = Field(default=None, alias="clubName") active: Optional[bool] = None - parent_org_name: Optional[str] = Field(default=None, alias="parentorgname") - parent_org_id: Optional[int] = Field(default=None, alias="parentorgid") + parent_org_name: Optional[str] = Field(default=None, alias="parentOrgName") + parent_org_id: Optional[int] = Field(default=None, alias="parentOrgId") diff --git a/mlbstatsapi/models/venues/attributes.py b/mlbstatsapi/models/venues/attributes.py index 5e8a9531..c4de5386 100644 --- a/mlbstatsapi/models/venues/attributes.py +++ b/mlbstatsapi/models/venues/attributes.py @@ -51,16 +51,16 @@ class Location(MLBBaseModel): """ city: str country: str - state_abbrev: Optional[str] = Field(default=None, alias="stateabbrev") + state_abbrev: Optional[str] = Field(default=None, alias="stateAbbrev") address1: Optional[str] = None state: Optional[str] = None - postal_code: Optional[str] = Field(default=None, alias="postalcode") + postal_code: Optional[str] = Field(default=None, alias="postalCode") phone: Optional[str] = None address2: Optional[str] = None address3: Optional[str] = None - azimuth_angle: Optional[float] = Field(default=None, alias="azimuthangle") + azimuth_angle: Optional[float] = Field(default=None, alias="azimuthAngle") elevation: Optional[int] = None - default_coordinates: Optional[VenueDefaultCoordinates] = Field(default=None, alias="defaultcoordinates") + default_coordinates: Optional[VenueDefaultCoordinates] = Field(default=None, alias="defaultCoordinates") class TimeZone(MLBBaseModel): @@ -81,7 +81,7 @@ class TimeZone(MLBBaseModel): id: str offset: int tz: str - offset_at_game_time: Optional[int] = Field(default=None, alias="offsetatgametime") + offset_at_game_time: Optional[int] = Field(default=None, alias="offsetAtGameTime") class FieldInfo(MLBBaseModel): @@ -112,12 +112,12 @@ class FieldInfo(MLBBaseModel): Distance to right line. """ capacity: Optional[int] = None - turf_type: Optional[str] = Field(default=None, alias="turftype") - roof_type: Optional[str] = Field(default=None, alias="rooftype") - left_line: Optional[int] = Field(default=None, alias="leftline") + turf_type: Optional[str] = Field(default=None, alias="turfType") + roof_type: Optional[str] = Field(default=None, alias="roofType") + left_line: Optional[int] = Field(default=None, alias="leftLine") left: Optional[int] = None - left_center: Optional[int] = Field(default=None, alias="leftcenter") + left_center: Optional[int] = Field(default=None, alias="leftCenter") center: Optional[int] = None - right_center: Optional[int] = Field(default=None, alias="rightcenter") + right_center: Optional[int] = Field(default=None, alias="rightCenter") right: Optional[int] = None - right_line: Optional[int] = Field(default=None, alias="rightline") + right_line: Optional[int] = Field(default=None, alias="rightLine") diff --git a/mlbstatsapi/models/venues/venue.py b/mlbstatsapi/models/venues/venue.py index e8ea7929..b43f669c 100644 --- a/mlbstatsapi/models/venues/venue.py +++ b/mlbstatsapi/models/venues/venue.py @@ -32,6 +32,6 @@ class Venue(MLBBaseModel): name: Optional[str] = None location: Optional[Location] = None timezone: Optional[TimeZone] = None - field_info: Optional[FieldInfo] = Field(default=None, alias="fieldinfo") + field_info: Optional[FieldInfo] = Field(default=None, alias="fieldInfo") active: Optional[bool] = None season: Optional[str] = None diff --git a/tests/external_tests/mlbdataadapter/test_mlbadapter.py b/tests/external_tests/mlbdataadapter/test_mlbadapter.py index 15d9aa77..225fa46f 100644 --- a/tests/external_tests/mlbdataadapter/test_mlbadapter.py +++ b/tests/external_tests/mlbdataadapter/test_mlbadapter.py @@ -1,7 +1,6 @@ import unittest import requests from unittest.mock import patch -from typing import List, Dict from mlbstatsapi import MlbDataAdapter, TheMlbStatsApiException @@ -14,16 +13,6 @@ def setUpClass(cls) -> None: def tearDownClass(cls) -> None: pass - # I don't know if this is best practice - def lower_keys_in_response(self, data): - if isinstance(data, Dict): - for key, value in data.items(): - self.assertTrue(key.islower()) - self.lower_keys_in_response(value) - - elif isinstance(data, List): - for item in data: - self.lower_keys_in_response(item) def test_mlbadapter_get_200(self): """mlbadapter should return 200 and data for sports endpoint""" @@ -72,22 +61,6 @@ def test_mlbadapter_get_params(self): # result should have data self.assertTrue(result.data) - def test_mlbadapter_transform_keys_in_data(self): - """mlbadapter transform keys should make all keys lowercase""" - - # pretty stable external - result = self.mlb_adapter.get(endpoint="sports") - - # status code should be 200 - self.assertEqual(result.status_code, 200) - - # data should not be None - self.assertTrue(result.data) - - # data should all be lowercase - self.lower_keys_in_response(result.data) - - class MlbAdapterMockTesting(unittest.TestCase): @classmethod def setUpClass(cls) -> None: @@ -149,4 +122,4 @@ def test_mlbadapter_mock_500_json(self): # mlb_adapter should raise exception due to 500 status code with self.assertRaises(TheMlbStatsApiException): - result = self.mlb_adapter.get(endpoint="teams/133/stats", ep_params=self.params) \ No newline at end of file + result = self.mlb_adapter.get(endpoint="teams/133/stats", ep_params=self.params) diff --git a/tests/external_tests/stats/test_fielding.py b/tests/external_tests/stats/test_fielding.py index 85b019b6..f1e6b6f2 100644 --- a/tests/external_tests/stats/test_fielding.py +++ b/tests/external_tests/stats/test_fielding.py @@ -71,13 +71,13 @@ def test_fielding_stat_attributes_team(self): # check for split objects self.assertTrue(stats['fielding']['season']) self.assertTrue(stats['fielding']['career']) - self.assertTrue(stats['fielding']['seasonadvanced']) - self.assertTrue(stats['fielding']['careeradvanced']) + self.assertTrue(stats['fielding']['seasonAdvanced']) + self.assertTrue(stats['fielding']['careerAdvanced']) season = stats['fielding']['season'] career = stats['fielding']['career'] - season_advanced = stats['fielding']['seasonadvanced'] - career_advanced = stats['fielding']['careeradvanced'] + season_advanced = stats['fielding']['seasonAdvanced'] + career_advanced = stats['fielding']['careerAdvanced'] self.assertEqual(season.total_splits, len(season.splits)) self.assertEqual(season.group, 'fielding') diff --git a/tests/external_tests/stats/test_hitting.py b/tests/external_tests/stats/test_hitting.py index a198423b..d567a8a4 100644 --- a/tests/external_tests/stats/test_hitting.py +++ b/tests/external_tests/stats/test_hitting.py @@ -39,14 +39,14 @@ def test_hitting_stat_attributes_player(self): # check for split objects self.assertTrue(stats['hitting']['season']) self.assertTrue(stats['hitting']['career']) - self.assertTrue(stats['hitting']['seasonadvanced']) - self.assertTrue(stats['hitting']['careeradvanced']) + self.assertTrue(stats['hitting']['seasonAdvanced']) + self.assertTrue(stats['hitting']['careerAdvanced']) # let's pull out a object and test it season = stats['hitting']['season'] career = stats['hitting']['career'] - season_advanced = stats['hitting']['seasonadvanced'] - career_advanced = stats['hitting']['careeradvanced'] + season_advanced = stats['hitting']['seasonAdvanced'] + career_advanced = stats['hitting']['careerAdvanced'] # check that attrs exist and contain data self.assertEqual(season.total_splits, len(season.splits)) @@ -85,14 +85,14 @@ def test_hitting_stat_attributes_team(self): # check for split objects self.assertTrue(stats['hitting']['season']) self.assertTrue(stats['hitting']['career']) - self.assertTrue(stats['hitting']['seasonadvanced']) - self.assertTrue(stats['hitting']['careeradvanced']) + self.assertTrue(stats['hitting']['seasonAdvanced']) + self.assertTrue(stats['hitting']['careerAdvanced']) # let's pull out a object and test it season = stats['hitting']['season'] career = stats['hitting']['career'] - season_advanced = stats['hitting']['seasonadvanced'] - career_advanced = stats['hitting']['careeradvanced'] + season_advanced = stats['hitting']['seasonAdvanced'] + career_advanced = stats['hitting']['careerAdvanced'] self.assertEqual(season.total_splits, len(season.splits)) self.assertEqual(season.group, 'hitting') @@ -146,7 +146,7 @@ def test_hitting_excepected_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['expectedstatistics']) + self.assertTrue(stats['hitting']['expectedStatistics']) def test_hitting_bydate_stats_player(self): """mlb get stats should return pitching stats""" @@ -163,10 +163,10 @@ def test_hitting_bydate_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['bydaterange']) - self.assertTrue(stats['hitting']['bydaterangeadvanced']) + self.assertTrue(stats['hitting']['byDateRange']) + self.assertTrue(stats['hitting']['byDateRangeAdvanced']) - def test_hitting_bymonth_stats_player(self): + def test_hitting_byMonth_stats_player(self): """mlb get stats should return pitching stats""" self.stats = ['byMonth'] self.group = ['hitting'] @@ -182,9 +182,9 @@ def test_hitting_bymonth_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['bymonth']) + self.assertTrue(stats['hitting']['byMonth']) - def test_hitting_bydayofweek_stats_player(self): + def test_hitting_byDayOfWeek_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['byDayOfWeek'] self.group = ['hitting'] @@ -199,9 +199,9 @@ def test_hitting_bydayofweek_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['bydayofweek']) + self.assertTrue(stats['hitting']['byDayOfWeek']) - def test_hitting_vsplayer_stats_player(self): + def test_hitting_vsPlayer_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['vsPlayer'] self.group = ['hitting'] @@ -216,7 +216,7 @@ def test_hitting_vsplayer_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['vsplayer']) + self.assertTrue(stats['hitting']['vsPlayer']) def test_hitting_vsteam_stats_player(self): """mlb get stats should return hitting stats""" @@ -234,7 +234,7 @@ def test_hitting_vsteam_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['vsteam']) + self.assertTrue(stats['hitting']['vsTeam']) def test_hitting_vsteam_stats_team(self): """mlb get stats should return hitting stats""" @@ -252,9 +252,9 @@ def test_hitting_vsteam_stats_team(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['vsteam']) + self.assertTrue(stats['hitting']['vsTeam']) - def test_hitting_pitchlog_stats_player(self): + def test_hitting_pitchLog_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['pitchLog'] self.group = ['hitting'] @@ -270,14 +270,14 @@ def test_hitting_pitchlog_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['pitchlog']) + self.assertTrue(stats['hitting']['pitchLog']) - pitchlog = stats['hitting']['pitchlog'] - self.assertTrue(len(pitchlog.splits) > 1) - self.assertEqual(pitchlog.total_splits, len(pitchlog.splits)) + pitchLog = stats['hitting']['pitchLog'] + self.assertTrue(len(pitchLog.splits) > 1) + self.assertEqual(pitchLog.total_splits, len(pitchLog.splits)) - def test_hitting_pitchlog_stats_player(self): + def test_hitting_pitchLog_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['playLog'] self.group = ['hitting'] @@ -293,12 +293,12 @@ def test_hitting_pitchlog_stats_player(self): self.assertTrue('hitting' in stats) # check for split objects - self.assertTrue(stats['hitting']['playlog']) + self.assertTrue(stats['hitting']['playLog']) - # playlogs should return multiple splits - playlogs = stats['hitting']['playlog'] - self.assertTrue(len(playlogs.splits) > 1) - self.assertEqual(playlogs.total_splits, len(playlogs.splits)) + # playLogs should return multiple splits + playLogs = stats['hitting']['playLog'] + self.assertTrue(len(playLogs.splits) > 1) + self.assertEqual(playLogs.total_splits, len(playLogs.splits)) def test_hitting_pitchArsenal_stats_player(self): @@ -317,13 +317,13 @@ def test_hitting_pitchArsenal_stats_player(self): self.assertTrue('stats' in stats) # check for split objects - self.assertTrue(stats['stats']['pitcharsenal']) + self.assertTrue(stats['stats']['pitchArsenal']) - pitcharsenal = stats['stats']['pitcharsenal'] + pitcharsenal = stats['stats']['pitchArsenal'] self.assertTrue(len(pitcharsenal.splits) > 1) self.assertEqual(pitcharsenal.total_splits, len(pitcharsenal.splits)) - def test_hitting_hotcoldzones_stats_player(self): + def test_hitting_hotColdZones_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['hotColdZones'] self.group = ['hitting'] @@ -339,9 +339,9 @@ def test_hitting_hotcoldzones_stats_player(self): self.assertTrue('stats' in stats) # check for split objects - self.assertTrue(stats['stats']['hotcoldzones']) + self.assertTrue(stats['stats']['hotColdZones']) # hotcoldzone should return 5 splits - hotcoldzone = stats['stats']['hotcoldzones'] + hotcoldzone = stats['stats']['hotColdZones'] self.assertEqual(len(hotcoldzone.splits), 5) self.assertEqual(hotcoldzone.total_splits, len(hotcoldzone.splits)) diff --git a/tests/external_tests/stats/test_pitching.py b/tests/external_tests/stats/test_pitching.py index 768a5670..f665f6cc 100644 --- a/tests/external_tests/stats/test_pitching.py +++ b/tests/external_tests/stats/test_pitching.py @@ -37,13 +37,13 @@ def test_pitching_stat_attributes_player(self): # check for split objects self.assertTrue(stats['pitching']['season']) self.assertTrue(stats['pitching']['career']) - self.assertTrue(stats['pitching']['seasonadvanced']) - self.assertTrue(stats['pitching']['careeradvanced']) + self.assertTrue(stats['pitching']['seasonAdvanced']) + self.assertTrue(stats['pitching']['careerAdvanced']) season = stats['pitching']['season'] career = stats['pitching']['career'] - season_advanced = stats['pitching']['seasonadvanced'] - career_advanced = stats['pitching']['careeradvanced'] + season_advanced = stats['pitching']['seasonAdvanced'] + career_advanced = stats['pitching']['careerAdvanced'] self.assertEqual(season.total_splits, len(season.splits)) self.assertEqual(season.group, 'pitching') @@ -81,13 +81,13 @@ def test_pitching_stat_attributes_team(self): # check for split objects self.assertTrue(stats['pitching']['season']) self.assertTrue(stats['pitching']['career']) - self.assertTrue(stats['pitching']['seasonadvanced']) - self.assertTrue(stats['pitching']['careeradvanced']) + self.assertTrue(stats['pitching']['seasonAdvanced']) + self.assertTrue(stats['pitching']['careerAdvanced']) season = stats['pitching']['season'] career = stats['pitching']['career'] - season_advanced = stats['pitching']['seasonadvanced'] - career_advanced = stats['pitching']['careeradvanced'] + season_advanced = stats['pitching']['seasonAdvanced'] + career_advanced = stats['pitching']['careerAdvanced'] self.assertEqual(season.total_splits, len(season.splits)) self.assertEqual(season.group, 'pitching') @@ -121,7 +121,7 @@ def test_pitching_excepected_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['expectedstatistics']) + self.assertTrue(stats['pitching']['expectedStatistics']) def test_pitching_bydate_stats_player(self): @@ -140,10 +140,10 @@ def test_pitching_bydate_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['bydaterange']) - self.assertTrue(stats['pitching']['bydaterangeadvanced']) + self.assertTrue(stats['pitching']['byDateRange']) + self.assertTrue(stats['pitching']['byDateRangeAdvanced']) - def test_pitching_bymonth_stats_player(self): + def test_pitching_byMonth_stats_player(self): """mlb get stats should return pitching stats""" self.stats = ['byMonth'] self.group = ['pitching'] @@ -158,9 +158,9 @@ def test_pitching_bymonth_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['bymonth']) + self.assertTrue(stats['pitching']['byMonth']) - def test_pitching_bydayofweek_stats_player(self): + def test_pitching_byDayOfWeek_stats_player(self): """mlb get stats should return pitching stats""" self.stats = ['byDayOfWeek'] self.group = ['pitching'] @@ -175,9 +175,9 @@ def test_pitching_bydayofweek_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['bydayofweek']) + self.assertTrue(stats['pitching']['byDayOfWeek']) - def test_pitching_vsplayer_stats_player(self): + def test_pitching_vsPlayer_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['vsPlayer'] self.group = ['pitching'] @@ -192,9 +192,9 @@ def test_pitching_vsplayer_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['vsplayer']) + self.assertTrue(stats['pitching']['vsPlayer']) - def test_pitching_pitchlog_stats_player(self): + def test_pitching_pitchLog_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['pitchLog'] self.group = ['pitching'] @@ -209,9 +209,9 @@ def test_pitching_pitchlog_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['pitchlog']) + self.assertTrue(stats['pitching']['pitchLog']) - def test_pitching_playlog_stats_player(self): + def test_pitching_playLog_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['playLog'] self.group = ['pitching'] @@ -226,7 +226,7 @@ def test_pitching_playlog_stats_player(self): self.assertTrue('pitching' in stats) # check for split objects - self.assertTrue(stats['pitching']['playlog']) + self.assertTrue(stats['pitching']['playLog']) def test_pitching_pitchArsenal_stats_player(self): """mlb get stats should return hitting stats""" @@ -243,9 +243,9 @@ def test_pitching_pitchArsenal_stats_player(self): self.assertTrue('stats' in stats) # check for split objects - self.assertTrue(stats['stats']['pitcharsenal']) + self.assertTrue(stats['stats']['pitchArsenal']) - def test_pitching_hotcoldzones_stats_player(self): + def test_pitching_hotColdZones_stats_player(self): """mlb get stats should return hitting stats""" self.stats = ['hotColdZones'] self.group = ['pitching'] @@ -260,4 +260,4 @@ def test_pitching_hotcoldzones_stats_player(self): self.assertTrue('stats' in stats) # check for split objects - self.assertTrue(stats['stats']['hotcoldzones']) \ No newline at end of file + self.assertTrue(stats['stats']['hotColdZones']) \ No newline at end of file diff --git a/tests/external_tests/stats/test_player_game_stats.py b/tests/external_tests/stats/test_player_game_stats.py index bde7f54b..796225ec 100644 --- a/tests/external_tests/stats/test_player_game_stats.py +++ b/tests/external_tests/stats/test_player_game_stats.py @@ -34,12 +34,12 @@ def test_get_players_stats_for_ty_france(self): # game_stats should have hitting stats self.assertTrue(game_stats['hitting']) - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['hitting']['vsplayer5y']) - self.assertTrue(game_stats['hitting']['playlog']) - self.assertTrue(game_stats['stats']['gamelog']) + # game_stats should have vsPlayer5Y and playLog stats + self.assertTrue(game_stats['hitting']['vsPlayer5Y']) + self.assertTrue(game_stats['hitting']['playLog']) + self.assertTrue(game_stats['stats']['gameLog']) - stat = game_stats['hitting']['vsplayer5y'] + stat = game_stats['hitting']['vsPlayer5Y'] for split in stat.splits: self.assertTrue(split.team) @@ -60,10 +60,10 @@ def test_get_players_stats_for_cal_r(self): # game_stats should have hitting stats self.assertTrue(game_stats['hitting']) - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['hitting']['vsplayer5y']) - self.assertTrue(game_stats['hitting']['playlog']) - self.assertTrue(game_stats['stats']['gamelog']) + # game_stats should have vsPlayer5Y and playLog stats + self.assertTrue(game_stats['hitting']['vsPlayer5Y']) + self.assertTrue(game_stats['hitting']['playLog']) + self.assertTrue(game_stats['stats']['gameLog']) diff --git a/tests/mock_tests/awards/test_awards_mock.py b/tests/mock_tests/awards/test_awards_mock.py deleted file mode 100644 index 456ba067..00000000 --- a/tests/mock_tests/awards/test_awards_mock.py +++ /dev/null @@ -1,56 +0,0 @@ -from typing import Dict, List -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - - -from mlbstatsapi import Mlb -from mlbstatsapi.models.awards import Award - - -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_awards = os.path.join(current_directory, "../mock_json/awards/awards.json") -AWARDS_JSON_FILE = open(path_to_awards, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestAwardsMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.awards_mock = json.loads(AWARDS_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_awards(self, m): - """This test should return a 200 and Round""" - m.get('https://statsapi.mlb.com/api/v1/awards/RETIREDUNI_108/recipients?', json=self.awards_mock, - status_code=200) - - # set draft id - award_id = "RETIREDUNI_108" - - # call get_draft return list - awards = self.mlb.get_awards(award_id) - - # draft should not be None - self.assertIsNotNone(awards) - - # list should not be empty - self.assertNotEqual(awards, []) - - # items in list should be an award - self.assertIsInstance(awards[0], Award) - - award = awards[0] - - # award should not be none - self.assertIsNotNone(award) - - # award should have attrs set - self.assertTrue(award.id) - self.assertTrue(award.name) \ No newline at end of file diff --git a/tests/mock_tests/drafts/test_draft_mock.py b/tests/mock_tests/drafts/test_draft_mock.py deleted file mode 100644 index d56065da..00000000 --- a/tests/mock_tests/drafts/test_draft_mock.py +++ /dev/null @@ -1,61 +0,0 @@ -from typing import Dict, List -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - - -from mlbstatsapi import Mlb -from mlbstatsapi import MlbResult -from mlbstatsapi import TheMlbStatsApiException -from mlbstatsapi.models.drafts import Round - - -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_drafts = os.path.join(current_directory, "../mock_json/drafts/draft.json") -DRAFTS = open(path_to_drafts, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestDraftMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.drafts_mock = json.loads(DRAFTS) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_draft_by_year_id(self, m): - """This test should return a 200 and Round""" - m.get('https://statsapi.mlb.com/api/v1/draft/2018', json=self.drafts_mock, - status_code=200) - # set draft id - draft_id = "2018" - - # call get_draft return list - draft = self.mlb.get_draft(draft_id) - - # draft should not be None - self.assertIsNotNone(draft) - - # list should not be empty - self.assertNotEqual(draft, []) - - # items in list should be Round - self.assertIsInstance(draft[0], Round) - - draftpicks = draft[0].picks - - # draftpicks should not be none - self.assertIsNotNone(draftpicks) - - # list should not be empty - self.assertNotEqual(draftpicks, []) - - draftpick = draftpicks[0] - - # draft pick should have attrs set (using Pythonic field name) - self.assertTrue(draftpick.pick_round) \ No newline at end of file diff --git a/tests/mock_tests/gamepace/test_gamepace_mock.py b/tests/mock_tests/gamepace/test_gamepace_mock.py deleted file mode 100644 index 99e935b4..00000000 --- a/tests/mock_tests/gamepace/test_gamepace_mock.py +++ /dev/null @@ -1,58 +0,0 @@ -from typing import Dict, List -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - - -from mlbstatsapi import Mlb -from mlbstatsapi.models.gamepace import GamePace, GamePaceData - - -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_gamepace = os.path.join(current_directory, "../mock_json/gamepace/gamepace.json") -GAMEPACE_JSON_FILE = open(path_to_gamepace, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestGamepaceMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.gamepace_mock = json.loads(GAMEPACE_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_gamepace(self, m): - """This test should return a 200 and Round""" - m.get('https://statsapi.mlb.com/api/v1/gamePace?season=2021', json=self.gamepace_mock, - status_code=200) - - # set draft id - season_id = 2021 - - # call get_gamepace return GamePace object - gamepace = self.mlb.get_gamepace(season_id) - - # GamePace should not be None - self.assertIsNotNone(gamepace) - - self.assertIsInstance(gamepace, GamePace) - - # list should not be empty - self.assertNotEqual(gamepace.sports, []) - - # items in list should be gamepace data - self.assertIsInstance(gamepace.sports[0], GamePaceData) - - sportgamepace = gamepace.sports[0] - - # sportgamepace should not be none - self.assertIsNotNone(sportgamepace) - - # sportgamepace should have attrs set (using Pythonic names) - self.assertTrue(sportgamepace.hits_per_game) - self.assertTrue(sportgamepace.total_games) diff --git a/tests/mock_tests/homerunderby/test_homerunderby_mock.py b/tests/mock_tests/homerunderby/test_homerunderby_mock.py deleted file mode 100644 index a1fcf3dd..00000000 --- a/tests/mock_tests/homerunderby/test_homerunderby_mock.py +++ /dev/null @@ -1,49 +0,0 @@ -from typing import Dict, List -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - - -from mlbstatsapi import Mlb -from mlbstatsapi.models.homerunderby import HomeRunDerby, Round - - -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_homerunderby = os.path.join(current_directory, "../mock_json/homerunderby/homerunderby.json") -HOMERUNDERBY_JSON_FILE = open(path_to_homerunderby, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestHomerunderbyMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.homerunderby_mock = json.loads(HOMERUNDERBY_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_homerunderby(self, m): - """This test should return a 200 and Round""" - m.get('https://statsapi.mlb.com/api/v1/homeRunDerby/511101', json=self.homerunderby_mock, - status_code=200) - - # set game id - game_id = 511101 - - # call get_homerun_derby return HomeRunDerby object - derby = self.mlb.get_homerun_derby(game_id) - - # HomeRunDerby should not be None - self.assertIsNotNone(derby) - - self.assertIsInstance(derby, HomeRunDerby) - - # list should not be empty - self.assertNotEqual(derby.rounds, []) - - # items in list should be Round - self.assertIsInstance(derby.rounds[0], Round) diff --git a/tests/mock_tests/mlb/test_mlb_mock.py b/tests/mock_tests/mlb/test_mlb_mock.py deleted file mode 100644 index 9100a242..00000000 --- a/tests/mock_tests/mlb/test_mlb_mock.py +++ /dev/null @@ -1,453 +0,0 @@ -from typing import Dict, List -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - -from mlbstatsapi.models.people import Person -from mlbstatsapi.models.teams import Team -from mlbstatsapi.models.game import Game, Plays, Linescore, BoxScore -from mlbstatsapi.models.venues import Venue -from mlbstatsapi.models.sports import Sport -from mlbstatsapi.models.leagues import League -from mlbstatsapi.models.divisions import Division -from mlbstatsapi.models.schedules import Schedule - -from mlbstatsapi import Mlb -from mlbstatsapi import MlbResult -from mlbstatsapi import TheMlbStatsApiException - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_teams_file = os.path.join(current_directory, "../mock_json/teams/teams.json") -path_to_oakland_file = os.path.join(current_directory, "../mock_json/teams/team.json") -path_to_players_file = os.path.join(current_directory, "../mock_json/people/players.json") -path_to_person_file = os.path.join(current_directory, "../mock_json/people/person.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") -path_to_divisions = os.path.join(current_directory, "../mock_json/divisions/divisions.json") -path_to_division = os.path.join(current_directory, "../mock_json/divisions/division.json") -path_to_sports = os.path.join(current_directory, "../mock_json/sports/sports.json") -path_to_sports = os.path.join(current_directory, "../mock_json/sports/sport.json") -path_to_leagues = os.path.join(current_directory, "../mock_json/leagues/leagues.json") -path_to_league = os.path.join(current_directory, "../mock_json/leagues/league.json") -path_to_venues = os.path.join(current_directory, "../mock_json/venues/venues.json") -path_to_venue = os.path.join(current_directory, "../mock_json/venues/venue.json") -path_to_game = os.path.join(current_directory, "../mock_json/games/game.json") - - -LEAGUES_JSON_FILE = open(path_to_leagues, "r", encoding="utf-8-sig").read() -LEAGUE_JSON_FILE = open(path_to_league, "r", encoding="utf-8-sig").read() -SPORTS_JSON_FILE = open(path_to_sports, "r", encoding="utf-8-sig").read() -SPORT_JSON_FILE = open(path_to_sports, "r", encoding="utf-8-sig").read() -TEAMS_JSON_FILE = open(path_to_teams_file, "r", encoding="utf-8-sig").read() -TEAM_JSON_FILE = open(path_to_oakland_file, "r", encoding="utf-8-sig").read() -PEOPLE_JSON_FILE = open(path_to_players_file, "r", encoding="utf-8-sig").read() -PERSON_JSON_FILE = open(path_to_person_file, "r", encoding="utf-8-sig").read() -DIVISIONS_JSON_FILE = open(path_to_divisions, "r", encoding="utf-8-sig").read() -DIVISION_JSON_FILE = open(path_to_division, "r", encoding="utf-8-sig").read() -VENUES_JSON_FILE = open(path_to_venues, "r", encoding="utf-8-sig").read() -VENUE_JSON_FILE = open(path_to_venue, "r", encoding="utf-8-sig").read() -GAME_JSON_FILE = open(path_to_game, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() - - -@requests_mock.Mocker() -class TestMlbDataApiMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_divisions = json.loads(DIVISIONS_JSON_FILE) - cls.error_500 = json.loads(ERROR_500) - cls.mock_not_found = json.loads(NOT_FOUND_404) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_mlb_adapter_200(self, m): - m.get('https://statsapi.mlb.com/api/v1/divisions', json=self.mock_divisions, - status_code=200) - - mlbdata = self.mlb._mlb_adapter_v1.get("divisions") - self.assertIsInstance(mlbdata, MlbResult) - self.assertEqual(mlbdata.status_code, 200) - self.assertIsInstance(mlbdata.data, Dict) - - def test_mlb_adapter_500(self, m): - """mlb should raise a exception when adapter returns a 500""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/stats?stats=vsPlayer&group=catching', - json=self.mock_divisions, status_code=500) - with self.assertRaises(TheMlbStatsApiException): - self.mlb._mlb_adapter_v1.get(endpoint="teams/133/stats?stats=vsPlayer&group=catching") - - def test_mlb_adapter_400(self, m): - """mlb should return a MlbResult object with a empty data, and a status code""" - m.get('https://statsapi.mlb.com/api/v1/teams/19990', json=self.mock_not_found, - status_code=404) - # invalid endpoint - mlbdata = self.mlb._mlb_adapter_v1.get(endpoint="teams/19990") - - # result.status_code should be 404 - self.assertEqual(mlbdata.status_code, 404) - - # result.data should be None - self.assertEqual(mlbdata.data, {}) - - -@requests_mock.Mocker() -class TestMlbGetPeopleMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_people = json.loads(PEOPLE_JSON_FILE) - cls.mock_person = json.loads(PERSON_JSON_FILE) - cls.mock_not_found = json.loads(NOT_FOUND_404) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_mlbdataapi_get_people(self, m): - """mlb get_people should return a list of all sport 1 people""" - m.get('https://statsapi.mlb.com/api/v1/sports/1/players', json=self.mock_people, - status_code=200) - mlbdata = self.mlb.get_people() - self.assertIsInstance(mlbdata, List) - self.assertIsInstance(mlbdata[0], Person) - - def test_mlbdataapi_get_people_with_sportid(self, m): - """mlb get_people should return a list of all sport 1 people""" - m.get('https://statsapi.mlb.com/api/v1/sports/11/players', json=self.mock_people, - status_code=200) - mlbdata = self.mlb.get_people(sport_id=11) - self.assertIsInstance(mlbdata, List) - self.assertIsInstance(mlbdata[0], Person) - - def test_mlb_get_person(self, m): - """mlb get_person should return a Person object""" - m.get('https://statsapi.mlb.com/api/v1/people/676265', json=self.mock_people, - status_code=200) - person = self.mlb.get_person('676265') - self.assertIsInstance(person, Person) - self.assertEqual(person.id, 676265) - - def test_mlb_failed_get_person(self, m): - """mlb get_person should return None and 404 for invalid id""" - m.get('https://statsapi.mlb.com/api/v1/people/664', json=self.mock_not_found, - status_code=404) - person = self.mlb.get_person('664') - self.assertIsNone(person) - - def test_mlb_get_person_id(self, m): - """mlb get_person_id should return a person id""" - m.get('https://statsapi.mlb.com/api/v1/sports/1/players', json=self.mock_people, - status_code=200) - id = self.mlb.get_people_id('CJ Abrams') - self.assertEqual(id, [682928]) - - def test_mlb_get_person_id_with_sportid(self, m): - """mlb get_person_id should return a person id""" - m.get('https://statsapi.mlb.com/api/v1/sports/11/players', json=self.mock_people, - status_code=200) - id = self.mlb.get_people_id('Albert Abreu', sport_id=11) - self.assertEqual(id, [656061]) - - def test_mlb_get_invalid_person_id(self, m): - m.get('https://statsapi.mlb.com/api/v1/sports/1/players', json=self.mock_people, - status_code=200) - """mlb get_person_id should return empty list for invalid name""" - id = self.mlb.get_people_id('Joe Blow') - self.assertEqual(id, []) - - -@requests_mock.Mocker() -class TestMlbGetTeamMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_teams = json.loads(TEAMS_JSON_FILE) - cls.mock_team = json.loads(TEAM_JSON_FILE) - cls.mock_not_found = json.loads(NOT_FOUND_404) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_mlb_get_team(self, m): - """mlb get_team should return Team object""" - m.get('https://statsapi.mlb.com/api/v1/teams/133', json=self.mock_team, - status_code=200) - - team = self.mlb.get_team('133') - self.assertIsInstance(team, Team) - self.assertEqual(team.id, 133) - - def test_mlbdataapi_get_teams(self, m): - """mlb get_teams should return a list of Teams""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams) - - mlbdata = self.mlb.get_teams() - self.assertIsInstance(mlbdata, List) - self.assertIsInstance(mlbdata[0], Team) - - def test_mlbdataapi_get_teams_with_sportid(self, m): - """mlb get_teams should return a list of Teams""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams) - mlbdata = self.mlb.get_teams(sport_id=16) - self.assertIsInstance(mlbdata, List) - self.assertIsInstance(mlbdata[0], Team) - - def test_mlb_failed_get_team(self, m): - """mlb get_team should return None for invalid team id""" - m.get('https://statsapi.mlb.com/api/v1/teams/19999', json=self.mock_not_found, - status_code=404) - team = self.mlb.get_team('19999') - self.assertIsNone(team) - - def test_mlb_get_team_id(self, m): - """mlb get_team_id should return a list of matching team id's""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams, - status_code=200) - - id = self.mlb.get_team_id('Seattle Mariners') - self.assertEqual(id, [136]) - - def test_mlb_get_team_minor_id(self, m): - """mlb get_team_id should return a list of matching team id's""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams, - status_code=200) - - id = self.mlb.get_team_id('DSL Brewers 2') - self.assertEqual(id, [2101]) - - def test_mlb_get_bad_team_id(self, m): - """mlb get_team_id should return a empty list for invalid team name""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams, - status_code=200) - id = self.mlb.get_team_id('Banananananana') - self.assertEqual(id, []) - - -@requests_mock.Mocker() -class TestMlbGetSport(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_sports = json.loads(SPORTS_JSON_FILE) - cls.mock_sport = json.loads(SPORT_JSON_FILE) - cls.mock_not_found = json.loads(NOT_FOUND_404) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_sport(self, m): - """mlb get_sport should return a Sport Object""" - m.get('https://statsapi.mlb.com/api/v1/sports/1', json=self.mock_sport, - status_code=200) - sport = self.mlb.get_sport(1) - self.assertIsInstance(sport, Sport) - self.assertEqual(sport.id, 1) - - def test_get_sports(self, m): - """mlb get_sports should return a list of sport objects""" - m.get('https://statsapi.mlb.com/api/v1/sports', json=self.mock_sports, - status_code=200) - sports = self.mlb.get_sports() - self.assertIsInstance(sports, List) - self.assertIsInstance(sports[0], Sport) - - def test_get_sport_id(self, m): - """mlb get_sport id should return a sport id""" - m.get('https://statsapi.mlb.com/api/v1/sports', json=self.mock_sports, - status_code=200) - id = self.mlb.get_sport_id('Major League Baseball') - self.assertEqual(id, [1]) - - def test_get_sport_invalid_name(self, m): - """mlb get_sport should return a empty list for invalid sport name""" - m.get('https://statsapi.mlb.com/api/v1/sports', json=self.mock_sports, - status_code=200) - id = self.mlb.get_sport_id('NFL') - self.assertEqual(id, []) - - -@requests_mock.Mocker() -class TestMlbGetLeagueMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_leagues = json.loads(LEAGUES_JSON_FILE) - cls.mock_league = json.loads(LEAGUE_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_league(self, m): - """mlb get_league should return a League object""" - m.get('https://statsapi.mlb.com/api/v1/leagues/103', json=self.mock_league, - status_code=200) - league = self.mlb.get_league(103) - self.assertIsInstance(league, League) - self.assertEqual(league.id, 103) - - def test_get_leagues(self, m): - """mlb get_leagues should return a list of Leagues""" - m.get('https://statsapi.mlb.com/api/v1/leagues', json=self.mock_leagues, - status_code=200) - leagues = self.mlb.get_leagues() - self.assertIsInstance(leagues, List) - self.assertIsInstance(leagues[0], League) - - def test_get_league_id(self, m): - """mlb get_league_id should return a league id""" - m.get('https://statsapi.mlb.com/api/v1/leagues', json=self.mock_leagues, - status_code=200) - id = self.mlb.get_league_id('American League') - self.assertEqual(id, [103]) - - def test_get_invalid_league_id(self, m): - """mlb get_league_id should return a empty list with invalid league name""" - m.get('https://statsapi.mlb.com/api/v1/leagues', json=self.mock_leagues, - status_code=200) - id = self.mlb.get_league_id('Russian League') - self.assertEqual(id, []) - - -@requests_mock.Mocker() -class TestMlbGetDivision(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_divisions = json.loads(DIVISIONS_JSON_FILE) - cls.mock_division = json.loads(DIVISION_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_division(self, m): - """mlb get_division should return a Division object""" - m.get('https://statsapi.mlb.com/api/v1/divisions/200', json=self.mock_division, - status_code=200) - division = self.mlb.get_division(200) - self.assertIsInstance(division, Division) - self.assertEqual(division.id, 200) - - def test_get_divisions(self, m): - """mlb get_divisions should return a list of Divisions""" - m.get('https://statsapi.mlb.com/api/v1/divisions', json=self.mock_divisions, - status_code=200) - divisions = self.mlb.get_divisions() - self.assertIsInstance(divisions, List) - self.assertIsInstance(divisions[0], Division) - - def test_get_division_id(self, m): - """mlb get_division_id should return a division id""" - m.get('https://statsapi.mlb.com/api/v1/divisions', json=self.mock_divisions, - status_code=200) - id = self.mlb.get_division_id('American League West') - self.assertEqual(id, [200]) - - def test_get_division_fail_id(self, m): - m.get('https://statsapi.mlb.com/api/v1/divisions', json=self.mock_divisions, - status_code=200) - """mlb get_division_id should return a empty list for invalid division name""" - id = self.mlb.get_division_id('Canada West') - self.assertEqual(id, []) - - -@requests_mock.Mocker() -class TestMlbGetVenue(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_venues = json.loads(VENUES_JSON_FILE) - cls.mock_venue = json.loads(VENUE_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_mlb_get_venue(self, m): - """mlb get_division should return a Division object""" - m.get('https://statsapi.mlb.com/api/v1/venues/31', json=self.mock_venue, - status_code=200) - venue = self.mlb.get_venue(31) - self.assertIsInstance(venue, Venue) - self.assertEqual(venue.id, 31) - - def test_get_venues(self, m): - """mlb get_divisions should return a list of Divisions""" - m.get('https://statsapi.mlb.com/api/v1/venues', json=self.mock_venues, - status_code=200) - venues = self.mlb.get_venues() - self.assertIsInstance(venues, List) - self.assertIsInstance(venues[0], Venue) - - def test_mlb_get_venue_id(self, m): - """mlb get_division_id should return a division id""" - """mlb get_divisions should return a list of Divisions""" - m.get('https://statsapi.mlb.com/api/v1/venues', json=self.mock_venues, - status_code=200) - id = self.mlb.get_venue_id('PNC Park') - self.assertEqual(id, [31]) - - def test_get_venue_id(self, m): - """mlb get_division_id should return a empty list for invalid venue name""" - """mlb get_divisions should return a list of Divisions""" - m.get('https://statsapi.mlb.com/api/v1/venues', json=self.mock_venues, - status_code=200) - id = self.mlb.get_venue_id('Highschool Park') - self.assertEqual(id, []) - -@requests_mock.Mocker() -class TestMlbGetGame(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_game = json.loads(GAME_JSON_FILE) - pass - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_mlb_get_game(self, m): - """mlb get_game should return a Game object""" - m.get('https://statsapi.mlb.com/api/v1.1/game/715720/feed/live', json=self.mock_game, - status_code=200) - game = self.mlb.get_game(715720) - self.assertIsInstance(game, Game) - self.assertEqual(game.id, 715720) - - # def test_get_game_playByPlay(self): - # playbyplay = self.mlb.get_game_play_by_play(662242) - # self.assertIsInstance(playbyplay, Plays) - - # def test_get_game_linescore(self): - # linescore = self.mlb.get_game_line_score(662242) - # self.assertIsInstance(linescore, Linescore) - - # def test_get_game_boxscore(self): - # boxscore = self.mlb.get_game_box_score(662242) - # self.assertIsInstance(boxscore, BoxScore) - - # def test_get_todays_games_id(self): - # todaysGames = self.mlb.get_todays_game_ids() - # self.assertIsInstance(todaysGames, List) - - # def test_get_attendance(self): - # params = {'season': 2022} - # attendance_team_away = self.mlb.get_attendance(team_id=113) - # attendance_team_home = self.mlb.get_attendance(team_id=134) - # attendance_season = self.mlb.get_attendance(team_id=113, params=params) - # self.assertEqual(attendance_team_away.records[0].team.id, 113) - # self.assertEqual(attendance_team_home.records[0].team.id, 134) - # self.assertEqual(attendance_season.records[0].team.id, 113) \ No newline at end of file diff --git a/tests/mock_tests/mock_json/awards/awards.json b/tests/mock_tests/mock_json/awards/awards.json deleted file mode 100644 index 79dee61d..00000000 --- a/tests/mock_tests/mock_json/awards/awards.json +++ /dev/null @@ -1,137 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "awards": [ - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1998-01-01", - "season": "1998", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 114414, - "link": "/api/v1/people/114414", - "primaryPosition": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "nameFirstLast": "Jim Fregosi" - }, - "notes": "11" - }, - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1997-04-15", - "season": "1997", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 121314, - "link": "/api/v1/people/121314", - "primaryPosition": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "nameFirstLast": "Jackie Robinson" - }, - "notes": "42" - }, - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1995-08-02", - "season": "1995", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 121011, - "link": "/api/v1/people/121011", - "primaryPosition": { - "code": "X", - "name": "Unknown", - "type": "Unknown", - "abbreviation": "X" - }, - "nameFirstLast": "Jimmie Reese" - }, - "notes": "50" - }, - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1992-06-16", - "season": "1992", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 121597, - "link": "/api/v1/people/121597", - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "nameFirstLast": "Nolan Ryan" - }, - "notes": "30" - }, - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1991-08-06", - "season": "1991", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 111986, - "link": "/api/v1/people/111986", - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "nameFirstLast": "Rod Carew" - }, - "notes": "29" - }, - { - "id": "RETIREDUNI_108", - "name": "Uniform number retired", - "date": "1982-01-01", - "season": "1982", - "team": { - "id": 108, - "link": "/api/v1/teams/108" - }, - "player": { - "id": 476405, - "link": "/api/v1/people/476405", - "primaryPosition": { - "code": "X", - "name": "Unknown", - "type": "Unknown", - "abbreviation": "X" - }, - "nameFirstLast": "Gene Autry" - }, - "notes": "26" - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/divisions/division.json b/tests/mock_tests/mock_json/divisions/division.json deleted file mode 100644 index 86648928..00000000 --- a/tests/mock_tests/mock_json/divisions/division.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "divisions": [ - { - "id": 200, - "name": "American League West", - "season": "2022", - "nameShort": "AL West", - "link": "/api/v1/divisions/200", - "abbreviation": "ALW", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "hasWildcard": false, - "sortOrder": 24, - "numPlayoffTeams": 1, - "active": true - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/divisions/divisions.json b/tests/mock_tests/mock_json/divisions/divisions.json deleted file mode 100644 index 416ff7b8..00000000 --- a/tests/mock_tests/mock_json/divisions/divisions.json +++ /dev/null @@ -1,105 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "divisions": [ - { - "id": 205, - "name": "National League Central", - "season": "2022", - "nameShort": "NL Central", - "link": "/api/v1/divisions/205", - "abbreviation": "NLC", - "league": { - "id": 104, - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "hasWildcard": false, - "sortOrder": 33, - "numPlayoffTeams": 1, - "active": true - }, - { - "id": 200, - "name": "American League West", - "season": "2022", - "nameShort": "AL West", - "link": "/api/v1/divisions/200", - "abbreviation": "ALW", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "hasWildcard": false, - "sortOrder": 24, - "numPlayoffTeams": 1, - "active": true - }, - { - "id": 233, - "name": "Pacific Coast League East", - "season": "2022", - "nameShort": "PCL East", - "link": "/api/v1/divisions/233", - "abbreviation": "PCLE", - "league": { - "id": 112, - "link": "/api/v1/league/112" - }, - "sport": { - "id": 11, - "link": "/api/v1/sports/11" - }, - "hasWildcard": false, - "sortOrder": 122, - "numPlayoffTeams": 1, - "active": true - }, - { - "id": 212, - "name": "Eastern League Northeast", - "season": "2022", - "nameShort": "EAS Northeast", - "link": "/api/v1/divisions/212", - "abbreviation": "EASNE", - "league": { - "id": 113, - "link": "/api/v1/league/113" - }, - "sport": { - "id": 12, - "link": "/api/v1/sports/12" - }, - "hasWildcard": false, - "sortOrder": 213, - "numPlayoffTeams": 1, - "active": true - }, - { - "id": 201, - "name": "American League East", - "season": "2022", - "nameShort": "AL East", - "link": "/api/v1/divisions/201", - "abbreviation": "ALE", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "hasWildcard": false, - "sortOrder": 22, - "numPlayoffTeams": 1, - "active": true - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/drafts/draft.json b/tests/mock_tests/mock_json/drafts/draft.json deleted file mode 100644 index 696af76e..00000000 --- a/tests/mock_tests/mock_json/drafts/draft.json +++ /dev/null @@ -1,384 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "drafts": { - "draftYear": 2018, - "rounds": [ - { - "round": "1", - "picks": [ - { - "bisPlayerId": 759143, - "pickRound": "1", - "pickNumber": 1, - "displayPickNumber": 1, - "roundPickNumber": 1, - "rank": 1, - "pickValue": "8096300", - "signingBonus": "7500000", - "home": { - "city": "Springville", - "state": "AL", - "country": "USA" - }, - "scoutingReport": "http://m.mlb.com/video/topic/262722544/v1868819183", - "school": { - "name": "Auburn", - "schoolClass": "JR", - "city": "Auburn", - "country": "USA", - "state": "AL" - }, - "blurb": "Raw and undrafted out of an Alabama high school three years ago, Mize has blossomed at Auburn and not only is a lock to join Gregg Olson (1988) and Frank Thomas (1989) as Tigers selected in the top 10 picks, but he's also the prohibitive favorite to go No. 1 overall. He has the best combination of stuff and control among college pitchers in the 2018 Draft, and he has proven he can stay healthy. Shut down last spring at Auburn and again during the summer with Team USA with a tired arm and a flexor strain in his forearm, he has had no issues this year. Mize can get swings and misses with three different pitches, the best of which is a mid-80s splitter that dives at the plate. He sets it up with a 92-97 mph fastball that he commands exceptionally well despite its running life. His mid-80s slider has taken a step forward this spring, consistently grading as a plus offering. Mize has an athletic frame and a clean delivery, so there's no glaring flaw that can be blamed for his health concerns. He pounds the strike zone, ranking first in NCAA Division I in K/BB ratio (12.1) and fourth in walks per nine innings (1.0) as a sophomore and posting similar numbers as a junior. Scouts also love the way he competes on the mound.", - "headshotLink": "https://img.mlbstatic.com/mlb-photos/image/upload/d_people:generic:headshot:silo:current.png/w_120,q_auto:best/v1/people/663554/headshot/draft/current", - "person": { - "id": 663554, - "fullName": "Casey Mize", - "link": "/api/v1/people/663554", - "firstName": "Casey", - "lastName": "Mize", - "primaryNumber": "12", - "birthDate": "1997-05-01", - "currentAge": 25, - "birthCity": "Springville", - "birthStateProvince": "AL", - "birthCountry": "USA", - "height": "6' 3\"", - "weight": 212, - "active": true, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Casey", - "useLastName": "Mize", - "middleName": "A.", - "boxscoreName": "Mize", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2018, - "mlbDebutDate": "2020-08-19", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Casey Mize", - "nameSlug": "casey-mize-663554", - "firstLastName": "Casey Mize", - "lastFirstName": "Mize, Casey", - "lastInitName": "Mize, C", - "initLastName": "C Mize", - "fullFMLName": "Casey A. Mize", - "fullLFMName": "Mize, Casey A.", - "strikeZoneTop": 3.49, - "strikeZoneBottom": 1.601 - }, - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 116, - "name": "Detroit Tigers", - "link": "/api/v1/teams/116" - }, - "draftType": { - "code": "JR", - "description": "June Amateur Draft" - }, - "isDrafted": true, - "isPass": false, - "year": "2018" - }, - { - "bisPlayerId": 390858, - "pickRound": "1", - "pickNumber": 2, - "displayPickNumber": 2, - "roundPickNumber": 2, - "rank": 6, - "pickValue": "7494600", - "signingBonus": "7025000", - "home": { - "city": "Buford", - "state": "GA", - "country": "USA" - }, - "scoutingReport": "http://m.mlb.com/video/topic/262722544/v1868827883", - "school": { - "name": "Georgia Tech", - "schoolClass": "JR", - "city": "Atlanta", - "country": "USA", - "state": "GA" - }, - "blurb": "Bart's power potential could have gotten him selected in the first five rounds of the Draft after he led Buford High to the 2015 Georgia 4-A state championship, but he dropped to the Rays in the 27th round because he was committed to Georgia Tech. His development at the plate and improvement behind it has him positioned as the top college catcher available in 2018. He's poised to join Jason Varitek and Matt Wieters as Yellow Jackets backstops popped in the first round, and he's even been linked to the Giants as a possible No. 2 overall pick. Bart's bat speed, strength and leverage give him power to all fields from the right side of the plate. He has the swing and the feel to hit for a solid average, and he has made huge strides with his plate discipline this spring. He has enough natural pop that he doesn't need to sell out for home runs, and he's not falling into that trap as much as he did in the past. There were questions about Bart's long-term catching ability when he arrived at Georgia Tech, but he has cleaned up his receiving enough that there no longer are doubts that he'll stay behind the plate. His strong arm never has been in question and he threw out 40 percent of basestealers in his first two college seasons. Though he's a well-below-average runner, he's relatively athletic for a catcher.", - "headshotLink": "https://img.mlbstatic.com/mlb-photos/image/upload/d_people:generic:headshot:silo:current.png/w_120,q_auto:best/v1/people/663698/headshot/draft/current", - "person": { - "id": 663698, - "fullName": "Joey Bart", - "link": "/api/v1/people/663698", - "firstName": "Joey", - "lastName": "Bart", - "primaryNumber": "21", - "birthDate": "1996-12-15", - "currentAge": 25, - "birthCity": "Buford", - "birthStateProvince": "GA", - "birthCountry": "USA", - "height": "6' 2\"", - "weight": 238, - "active": true, - "primaryPosition": { - "code": "2", - "name": "Catcher", - "type": "Catcher", - "abbreviation": "C" - }, - "useName": "Joey", - "useLastName": "Bart", - "middleName": "Andrew", - "boxscoreName": "Bart", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2018, - "mlbDebutDate": "2020-08-20", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Joey Bart", - "nameSlug": "joey-bart-663698", - "firstLastName": "Joey Bart", - "lastFirstName": "Bart, Joey", - "lastInitName": "Bart, J", - "initLastName": "J Bart", - "fullFMLName": "Joseph Andrew Bart", - "fullLFMName": "Bart, Joseph Andrew", - "strikeZoneTop": 3.34, - "strikeZoneBottom": 1.49 - }, - "team": { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 137, - "name": "San Francisco Giants", - "link": "/api/v1/teams/137" - }, - "draftType": { - "code": "JR", - "description": "June Amateur Draft" - }, - "isDrafted": true, - "isPass": false, - "year": "2018" - }, - { - "bisPlayerId": 764614, - "pickRound": "1", - "pickNumber": 3, - "displayPickNumber": 3, - "roundPickNumber": 3, - "rank": 7, - "pickValue": "6947500", - "signingBonus": "5850000", - "home": { - "city": "Omaha", - "state": "NE", - "country": "USA" - }, - "scoutingReport": "http://m.mlb.com/video/topic/262722544/v1868832683", - "school": { - "name": "Wichita State", - "schoolClass": "JR", - "city": "Wichita", - "country": "USA", - "state": "KS" - }, - "blurb": "Coming into 2018, scouts were divided as to which of Wichita State's two potential first-round position players was better. Greyson Jenista has more all-around ability and won the Cape Cod League MVP award last summer, but Bohm posted better numbers there and does a better job of tapping into his considerable power potential. Though Jenista has had a good junior season, Bohm has been great and settled the argument, thrusting himself into consideration as a top-five-overall pick. Bohm manages the strike zone very well and makes consistent hard contact from the right side of the plate. He doesn't strike out as much as Jenista, has an edge in bat speed and his stroke is more geared to generate power at this point. He understands that he doesn't have to sell out to hit home runs, so he doesn't. Bohm doesn't offer much when he's outside of the batter's box, however. Though he has worked diligently to improve at third base, he lacks quickness and range, his hands are just fair and his arm is only average. He'll probably wind up at first base but has the offensive upside to profile there.", - "headshotLink": "https://img.mlbstatic.com/mlb-photos/image/upload/d_people:generic:headshot:silo:current.png/w_120,q_auto:best/v1/people/664761/headshot/draft/current", - "person": { - "id": 664761, - "fullName": "Alec Bohm", - "link": "/api/v1/people/664761", - "firstName": "Alec", - "lastName": "Bohm", - "primaryNumber": "28", - "birthDate": "1996-08-03", - "currentAge": 26, - "birthCity": "Omaha", - "birthStateProvince": "NE", - "birthCountry": "USA", - "height": "6' 5\"", - "weight": 218, - "active": true, - "primaryPosition": { - "code": "5", - "name": "Third Base", - "type": "Infielder", - "abbreviation": "3B" - }, - "useName": "Alec", - "useLastName": "Bohm", - "middleName": "Daniel", - "boxscoreName": "Bohm", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2018, - "pronunciation": "bome; like home", - "mlbDebutDate": "2020-08-13", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Alec Bohm", - "nameSlug": "alec-bohm-664761", - "firstLastName": "Alec Bohm", - "lastFirstName": "Bohm, Alec", - "lastInitName": "Bohm, A", - "initLastName": "A Bohm", - "fullFMLName": "Alec Daniel Bohm", - "fullLFMName": "Bohm, Alec Daniel", - "strikeZoneTop": 3.45, - "strikeZoneBottom": 1.55 - }, - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "draftType": { - "code": "JR", - "description": "June Amateur Draft" - }, - "isDrafted": true, - "isPass": false, - "year": "2018" - }, - { - "bisPlayerId": 400315, - "pickRound": "1", - "pickNumber": 4, - "displayPickNumber": 4, - "roundPickNumber": 4, - "rank": 3, - "pickValue": "6411400", - "signingBonus": "6411400", - "home": { - "city": "Elk Grove", - "state": "CA", - "country": "USA" - }, - "scoutingReport": "http://m.mlb.com/video/topic/262722544/v1868818883", - "school": { - "name": "Oregon State", - "schoolClass": "JR", - "city": "Corvallis", - "country": "USA", - "state": "OR" - }, - "blurb": "In the not-too-distant past, a player like Madrigal would have been overlooked by many teams because of his size. The combination of more organizations embracing analytics and the success of players like Jose Altuve, not to mention the superb performance of the 5-foot-7 infielder, had Madrigal poised to perhaps be the top college position player taken in the 2018 Draft. A broken wrist at the start of the season slowed him down, but he returned in April swinging a hot bat. While Madrigal might have been more of a gut feel kind of player for scouts, he now has track record on top of being a scout favorite. Analytics departments love him because of his approach at the plate that led to more walks than strikeouts in 2017, and while he doesn't have a ton of over-the-fence power, he makes consistent hard contact and is a legitimate extra-base threat. His speed and instincts should allow him to continue to be a base stealer. While Madrigal has played mostly second base in deference to Cadyn Grenier at Oregon State, some feel he could handle shortstop if need be. If not, he has the chance to be a Gold Glove caliber second baseman in the future. Even with the injury, he should land squarely in the top 10 in June.", - "headshotLink": "https://img.mlbstatic.com/mlb-photos/image/upload/d_people:generic:headshot:silo:current.png/w_120,q_auto:best/v1/people/663611/headshot/draft/current", - "person": { - "id": 663611, - "fullName": "Nick Madrigal", - "link": "/api/v1/people/663611", - "firstName": "Nick", - "lastName": "Madrigal", - "primaryNumber": "1", - "birthDate": "1997-03-05", - "currentAge": 25, - "birthCity": "Sacramento", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "5' 8\"", - "weight": 175, - "active": true, - "primaryPosition": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "useName": "Nick", - "useLastName": "Madrigal", - "middleName": "M.", - "boxscoreName": "Madrigal", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2018, - "mlbDebutDate": "2020-07-31", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Nick Madrigal", - "nameSlug": "nick-madrigal-663611", - "firstLastName": "Nick Madrigal", - "lastFirstName": "Madrigal, Nick", - "lastInitName": "Madrigal, N", - "initLastName": "N Madrigal", - "fullFMLName": "Nicklaus M. Madrigal", - "fullLFMName": "Madrigal, Nicklaus M.", - "strikeZoneTop": 2.98, - "strikeZoneBottom": 1.31 - }, - "team": { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 145, - "name": "Chicago White Sox", - "link": "/api/v1/teams/145" - }, - "draftType": { - "code": "JR", - "description": "June Amateur Draft" - }, - "isDrafted": true, - "isPass": false, - "year": "2018" - } ] - } ] - } -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/gamepace/gamepace.json b/tests/mock_tests/mock_json/gamepace/gamepace.json deleted file mode 100644 index 0de13123..00000000 --- a/tests/mock_tests/mock_json/gamepace/gamepace.json +++ /dev/null @@ -1,594 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "teams": [], - "leagues": [], - "sports": [ - { - "hitsPer9Inn": 16.68, - "runsPer9Inn": 9.3, - "pitchesPer9Inn": 299.83, - "plateAppearancesPer9Inn": 76.8, - "hitsPerGame": 16.26, - "runsPerGame": 9.06, - "inningsPlayedPerGame": 8.8, - "pitchesPerGame": 292.24, - "pitchersPerGame": 8.87, - "plateAppearancesPerGame": 74.85, - "totalGameTime": "7749:55:59", - "totalInningsPlayed": 21379.5, - "totalHits": 39484, - "totalRuns": 22010, - "totalPlateAppearances": 181818, - "totalPitchers": 21545, - "totalPitches": 709851, - "totalGames": 2429, - "total7InnGames": 118, - "total9InnGames": 2095, - "totalExtraInnGames": 231, - "timePerGame": "03:11:26", - "timePerPitch": "00:00:39", - "timePerHit": "00:11:46", - "timePerRun": "00:21:07", - "timePerPlateAppearance": "00:02:33", - "timePer9Inn": "03:16:24", - "timePer77PlateAppearances": "03:16:55", - "totalExtraInnTime": "871:52:00", - "timePer7InnGame": "02:24:52", - "timePer7InnGameWithoutExtraInn": "253:31:59", - "total7InnGamesScheduled": 121, - "total7InnGamesWithoutExtraInn": 105, - "total9InnGamesCompletedEarly": 7, - "total9InnGamesWithoutExtraInn": 2086, - "total9InnGamesScheduled": 2308, - "hitsPerRun": 1.794, - "pitchesPerPitcher": 32.947, - "season": "2021", - "sport": { - "id": 1, - "code": "mlb", - "link": "/api/v1/sports/1" - }, - "prPortalCalculatedFields": { - "total7InnGames": 118, - "total9InnGames": 2095, - "totalExtraInnGames": 216, - "timePer7InnGame": "02:25:50", - "timePer9InnGame": "03:10:04", - "timePerExtraInnGame": "03:49:32" - } - }, - { - "hitsPer9Inn": 17.59, - "runsPer9Inn": 10.64, - "pitchesPer9Inn": 309.67, - "plateAppearancesPer9Inn": 78.96, - "hitsPerGame": 16.89, - "runsPerGame": 10.22, - "inningsPlayedPerGame": 8.68, - "pitchesPerGame": 297.43, - "pitchersPerGame": 8.66, - "plateAppearancesPerGame": 75.84, - "totalGameTime": "5835:27:59", - "totalInningsPlayed": 16704, - "totalHits": 32518, - "totalRuns": 19679, - "totalPlateAppearances": 145997, - "totalPitchers": 16679, - "totalPitches": 572552, - "totalGames": 1925, - "total7InnGames": 202, - "total9InnGames": 1579, - "totalExtraInnGames": 158, - "timePerGame": "03:01:53", - "timePerPitch": "00:00:36", - "timePerHit": "00:10:46", - "timePerRun": "00:17:47", - "timePerPlateAppearance": "00:02:23", - "timePer9Inn": "03:09:22", - "timePer77PlateAppearances": "03:04:39", - "totalExtraInnTime": "555:33:00", - "timePer7InnGame": "02:19:38", - "timePer7InnGameWithoutExtraInn": "386:21:00", - "total7InnGamesScheduled": 184, - "total7InnGamesCompletedEarly": 3, - "total7InnGamesWithoutExtraInn": 166, - "total9InnGamesCompletedEarly": 27, - "total9InnGamesWithoutExtraInn": 1571, - "total9InnGamesScheduled": 1741, - "hitsPerRun": 1.652, - "pitchesPerPitcher": 34.328, - "season": "2021", - "sport": { - "id": 11, - "code": "aaa", - "link": "/api/v1/sports/11" - }, - "prPortalCalculatedFields": { - "total7InnGames": 202, - "total9InnGames": 1579, - "totalExtraInnGames": 144, - "timePer7InnGame": "02:19:38", - "timePer9InnGame": "03:04:11", - "timePerExtraInnGame": "03:35:53" - } - }, - { - "hitsPer9Inn": 16.68, - "runsPer9Inn": 9.87, - "pitchesPer9Inn": 304.21, - "plateAppearancesPer9Inn": 77.79, - "hitsPerGame": 15.95, - "runsPerGame": 9.43, - "inningsPlayedPerGame": 8.63, - "pitchesPerGame": 290.88, - "pitchersPerGame": 7.47, - "plateAppearancesPerGame": 74.38, - "totalGameTime": "5075:12:59", - "totalInningsPlayed": 15027.5, - "totalHits": 27764, - "totalRuns": 16423, - "totalPlateAppearances": 129504, - "totalPitchers": 13001, - "totalPitches": 506430, - "totalGames": 1741, - "total7InnGames": 212, - "total9InnGames": 1403, - "totalExtraInnGames": 138, - "timePerGame": "02:54:54", - "timePerPitch": "00:00:36", - "timePerHit": "00:10:58", - "timePerRun": "00:18:32", - "timePerPlateAppearance": "00:02:21", - "timePer9Inn": "03:02:55", - "timePer77PlateAppearances": "03:01:03", - "totalExtraInnTime": "479:41:00", - "timePer7InnGame": "02:13:22", - "timePer7InnGameWithoutExtraInn": "400:07:59", - "total7InnGamesScheduled": 196, - "total7InnGamesCompletedEarly": 2, - "total7InnGamesWithoutExtraInn": 180, - "total9InnGamesCompletedEarly": 24, - "total9InnGamesWithoutExtraInn": 1397, - "total9InnGamesScheduled": 1545, - "hitsPerRun": 1.691, - "pitchesPerPitcher": 38.953, - "season": "2021", - "sport": { - "id": 12, - "code": "aax", - "link": "/api/v1/sports/12" - }, - "prPortalCalculatedFields": { - "total7InnGames": 212, - "total9InnGames": 1403, - "totalExtraInnGames": 126, - "timePer7InnGame": "02:13:53", - "timePer9InnGame": "02:57:40", - "timePerExtraInnGame": "03:33:03" - } - }, - { - "hitsPer9Inn": 16.67, - "runsPer9Inn": 10.51, - "pitchesPer9Inn": 306.75, - "plateAppearancesPer9Inn": 78.5, - "hitsPerGame": 16.05, - "runsPerGame": 10.12, - "inningsPlayedPerGame": 8.69, - "pitchesPerGame": 295.21, - "pitchersPerGame": 7.39, - "plateAppearancesPerGame": 75.55, - "totalGameTime": "5398:07:00", - "totalInningsPlayed": 15398.5, - "totalHits": 28433, - "totalRuns": 17926, - "totalPlateAppearances": 133872, - "totalPitchers": 13087, - "totalPitches": 523119, - "totalGames": 1772, - "total7InnGames": 169, - "total9InnGames": 1476, - "totalExtraInnGames": 142, - "timePerGame": "03:02:46", - "timePerPitch": "00:00:37", - "timePerHit": "00:11:23", - "timePerRun": "00:18:04", - "timePerPlateAppearance": "00:02:25", - "timePer9Inn": "03:09:55", - "timePer77PlateAppearances": "03:06:17", - "totalExtraInnTime": "498:22:59", - "timePer7InnGame": "02:19:31", - "timePer7InnGameWithoutExtraInn": "346:29:00", - "total7InnGamesScheduled": 166, - "total7InnGamesWithoutExtraInn": 149, - "total9InnGamesCompletedEarly": 16, - "total9InnGamesWithoutExtraInn": 1465, - "total9InnGamesScheduled": 1606, - "hitsPerRun": 1.586, - "pitchesPerPitcher": 39.972, - "season": "2021", - "sport": { - "id": 13, - "code": "afa", - "link": "/api/v1/sports/13" - }, - "prPortalCalculatedFields": { - "total7InnGames": 169, - "total9InnGames": 1476, - "totalExtraInnGames": 127, - "timePer7InnGame": "02:21:38", - "timePer9InnGame": "03:04:36", - "timePerExtraInnGame": "03:36:11" - } - }, - { - "hitsPer9Inn": 16.88, - "runsPer9Inn": 11.05, - "pitchesPer9Inn": 311.92, - "plateAppearancesPer9Inn": 80.16, - "hitsPerGame": 16.1, - "runsPerGame": 10.54, - "inningsPlayedPerGame": 8.61, - "pitchesPerGame": 297.49, - "pitchersPerGame": 7.31, - "plateAppearancesPerGame": 76.45, - "totalGameTime": "5265:45:00", - "totalInningsPlayed": 15308.5, - "totalHits": 28605, - "totalRuns": 18729, - "totalPlateAppearances": 135845, - "totalPitchers": 12988, - "totalPitches": 528642, - "totalGames": 1777, - "total7InnGames": 224, - "total9InnGames": 1432, - "totalExtraInnGames": 139, - "timePerGame": "02:57:47", - "timePerPitch": "00:00:35", - "timePerHit": "00:11:02", - "timePerRun": "00:16:52", - "timePerPlateAppearance": "00:02:19", - "timePer9Inn": "03:06:25", - "timePer77PlateAppearances": "02:59:05", - "totalExtraInnTime": "465:30:00", - "timePer7InnGame": "02:24:00", - "timePer7InnGameWithoutExtraInn": "465:37:59", - "total7InnGamesScheduled": 215, - "total7InnGamesCompletedEarly": 2, - "total7InnGamesWithoutExtraInn": 194, - "total9InnGamesCompletedEarly": 20, - "total9InnGamesWithoutExtraInn": 1422, - "total9InnGamesScheduled": 1562, - "hitsPerRun": 1.527, - "pitchesPerPitcher": 40.702, - "season": "2021", - "sport": { - "id": 14, - "code": "afx", - "link": "/api/v1/sports/14" - }, - "prPortalCalculatedFields": { - "total7InnGames": 224, - "total9InnGames": 1432, - "totalExtraInnGames": 121, - "timePer7InnGame": "02:24:27", - "timePer9InnGame": "03:00:34", - "timePerExtraInnGame": "03:26:42" - } - }, - { - "hitsPer9Inn": 16.3, - "runsPer9Inn": 11.47, - "pitchesPer9Inn": 159.19, - "plateAppearancesPer9Inn": 80.6, - "hitsPerGame": 13.98, - "runsPerGame": 9.83, - "inningsPlayedPerGame": 7.76, - "pitchesPerGame": 136.48, - "pitchersPerGame": 7.67, - "plateAppearancesPerGame": 69.1, - "totalGameTime": "6650:29:00", - "totalInningsPlayed": 17870, - "totalHits": 32192, - "totalRuns": 22642, - "totalPlateAppearances": 159142, - "totalPitchers": 17658, - "totalPitches": 314302, - "totalGames": 2303, - "total7InnGames": 1140, - "total9InnGames": 1060, - "totalExtraInnGames": 191, - "timePerGame": "02:53:15", - "timePerPitch": "00:01:16", - "timePerHit": "00:12:23", - "timePerRun": "00:17:37", - "timePerPlateAppearance": "00:02:30", - "timePer9Inn": "03:22:05", - "timePer77PlateAppearances": "03:13:04", - "totalExtraInnTime": "645:43:00", - "timePer7InnGame": "02:32:04", - "timePer7InnGameWithoutExtraInn": "2329:22:59", - "total7InnGamesScheduled": 1061, - "total7InnGamesCompletedEarly": 19, - "total7InnGamesWithoutExtraInn": 919, - "total9InnGamesCompletedEarly": 155, - "total9InnGamesWithoutExtraInn": 1000, - "total9InnGamesScheduled": 1242, - "hitsPerRun": 1.422, - "pitchesPerPitcher": 17.799, - "season": "2021", - "sport": { - "id": 16, - "code": "rok", - "link": "/api/v1/sports/16" - }, - "prPortalCalculatedFields": { - "total7InnGames": 1140, - "total9InnGames": 1060, - "totalExtraInnGames": 84, - "timePer7InnGame": "02:33:42", - "timePer9InnGame": "03:12:28", - "timePerExtraInnGame": "03:55:22" - } - }, - { - "hitsPer9Inn": 17.93, - "runsPer9Inn": 9.58, - "pitchesPer9Inn": 282.55, - "plateAppearancesPer9Inn": 78.78, - "hitsPerGame": 17.49, - "runsPerGame": 9.34, - "inningsPlayedPerGame": 8.81, - "pitchesPerGame": 275.56, - "pitchersPerGame": 10.79, - "plateAppearancesPerGame": 76.84, - "totalGameTime": "2944:27:00", - "totalInningsPlayed": 7425.5, - "totalHits": 14742, - "totalRuns": 7876, - "totalPlateAppearances": 64772, - "totalPitchers": 9097, - "totalPitches": 232298, - "totalGames": 843, - "total7InnGames": 47, - "total9InnGames": 725, - "totalExtraInnGames": 73, - "timePerGame": "03:29:34", - "timePerPitch": "00:00:45", - "timePerHit": "00:11:59", - "timePerRun": "00:22:25", - "timePerPlateAppearance": "00:02:43", - "timePer9Inn": "03:34:53", - "timePer77PlateAppearances": "03:30:01", - "totalExtraInnTime": "314:00:00", - "timePer7InnGame": "02:23:05", - "timePer7InnGameWithoutExtraInn": "97:46:59", - "total7InnGamesScheduled": 43, - "total7InnGamesWithoutExtraInn": 41, - "total9InnGamesCompletedEarly": 4, - "total9InnGamesWithoutExtraInn": 725, - "total9InnGamesScheduled": 800, - "hitsPerRun": 1.872, - "pitchesPerPitcher": 25.536, - "season": "2021", - "sport": { - "id": 17, - "code": "win", - "link": "/api/v1/sports/17" - }, - "prPortalCalculatedFields": { - "total7InnGames": 47, - "total9InnGames": 725, - "totalExtraInnGames": 71, - "timePer7InnGame": "02:27:29", - "timePer9InnGame": "03:28:37", - "timePerExtraInnGame": "04:20:17" - } - }, - { - "hitsPer9Inn": 17.25, - "runsPer9Inn": 12.7, - "pitchesPer9Inn": 319.42, - "plateAppearancesPer9Inn": 81.67, - "hitsPerGame": 16.2, - "runsPerGame": 11.92, - "inningsPlayedPerGame": 8.47, - "pitchesPerGame": 299.9, - "pitchersPerGame": 8.06, - "plateAppearancesPerGame": 76.68, - "totalGameTime": "154:03:00", - "totalInningsPlayed": 423.5, - "totalHits": 810, - "totalRuns": 596, - "totalPlateAppearances": 3834, - "totalPitchers": 403, - "totalPitches": 14995, - "totalGames": 50, - "total7InnGames": 8, - "total9InnGames": 41, - "totalExtraInnGames": 1, - "timePerGame": "03:04:51", - "timePerPitch": "00:00:36", - "timePerHit": "00:11:24", - "timePerRun": "00:15:30", - "timePerPlateAppearance": "00:02:24", - "timePer9Inn": "03:16:53", - "timePer77PlateAppearances": "03:05:37", - "totalExtraInnTime": "03:19:00", - "timePer7InnGameWithoutExtraInn": "00:00:00", - "total9InnGamesCompletedEarly": 10, - "total9InnGamesWithoutExtraInn": 39, - "total9InnGamesScheduled": 50, - "hitsPerRun": 1.359, - "pitchesPerPitcher": 37.208, - "season": "2021", - "sport": { - "id": 22, - "code": "bbc", - "link": "/api/v1/sports/22" - }, - "prPortalCalculatedFields": { - "total7InnGames": 8, - "total9InnGames": 41, - "totalExtraInnGames": 1, - "timePer7InnGame": "02:38:37", - "timePer9InnGame": "03:09:38", - "timePerExtraInnGame": "03:19:00" - } - }, - { - "hitsPer9Inn": 20.34, - "runsPer9Inn": 12.36, - "pitchesPer9Inn": 310.01, - "plateAppearancesPer9Inn": 82.08, - "hitsPerGame": 19.25, - "runsPerGame": 11.7, - "inningsPlayedPerGame": 8.55, - "pitchesPerGame": 293.52, - "pitchersPerGame": 8.84, - "plateAppearancesPerGame": 77.72, - "totalGameTime": "3434:27:00", - "totalInningsPlayed": 9072.5, - "totalHits": 20429, - "totalRuns": 12413, - "totalPlateAppearances": 82457, - "totalPitchers": 9383, - "totalPitches": 311427, - "totalGames": 1061, - "total7InnGames": 170, - "total9InnGames": 820, - "totalExtraInnGames": 87, - "timePerGame": "03:14:13", - "timePerPitch": "00:00:39", - "timePerHit": "00:10:05", - "timePerRun": "00:16:36", - "timePerPlateAppearance": "00:02:29", - "timePer9Inn": "03:25:07", - "timePer77PlateAppearances": "03:12:25", - "totalExtraInnTime": "330:42:59", - "timePer7InnGame": "02:33:04", - "timePer7InnGameWithoutExtraInn": "392:54:00", - "total7InnGamesScheduled": 173, - "total7InnGamesCompletedEarly": 1, - "total7InnGamesWithoutExtraInn": 154, - "total9InnGamesCompletedEarly": 14, - "total9InnGamesWithoutExtraInn": 805, - "total9InnGamesScheduled": 888, - "hitsPerRun": 1.646, - "pitchesPerPitcher": 33.191, - "season": "2021", - "sport": { - "id": 23, - "code": "ind", - "link": "/api/v1/sports/23" - }, - "prPortalCalculatedFields": { - "total7InnGames": 170, - "total9InnGames": 820, - "totalExtraInnGames": 71, - "timePer7InnGame": "02:32:55", - "timePer9InnGame": "03:19:05", - "timePerExtraInnGame": "03:56:50" - } - }, - { - "hitsPer9Inn": 18.56, - "runsPer9Inn": 9.91, - "pitchesPer9Inn": 311.55, - "plateAppearancesPer9Inn": 81.63, - "hitsPerGame": 17.6, - "runsPerGame": 9.4, - "inningsPlayedPerGame": 8.7, - "pitchesPerGame": 295.4, - "pitchersPerGame": 10.2, - "plateAppearancesPerGame": 77.4, - "totalGameTime": "15:39:59", - "totalInningsPlayed": 43.5, - "totalHits": 88, - "totalRuns": 47, - "totalPlateAppearances": 387, - "totalPitchers": 51, - "totalPitches": 1477, - "totalGames": 5, - "total9InnGames": 5, - "timePerGame": "03:07:59", - "timePerPitch": "00:00:38", - "timePerHit": "00:10:40", - "timePerRun": "00:19:59", - "timePerPlateAppearance": "00:02:25", - "timePer9Inn": "03:18:16", - "timePer77PlateAppearances": "03:07:01", - "totalExtraInnTime": "00:00:00", - "timePer7InnGameWithoutExtraInn": "00:00:00", - "total9InnGamesCompletedEarly": 1, - "total9InnGamesWithoutExtraInn": 4, - "total9InnGamesScheduled": 5, - "hitsPerRun": 1.872, - "pitchesPerPitcher": 28.961, - "season": "2021", - "sport": { - "id": 51, - "code": "int", - "link": "/api/v1/sports/51" - }, - "prPortalCalculatedFields": { - "total7InnGames": null, - "total9InnGames": 5, - "totalExtraInnGames": null, - "timePer7InnGame": null, - "timePer9InnGame": "03:07:59", - "timePerExtraInnGame": null - } - }, - { - "hitsPer9Inn": 11.82, - "runsPer9Inn": 8.76, - "pitchesPer9Inn": 316.06, - "plateAppearancesPer9Inn": 70.16, - "hitsPerGame": 12.33, - "runsPerGame": 9.14, - "inningsPlayedPerGame": 9.5, - "pitchesPerGame": 329.71, - "pitchersPerGame": 11.38, - "plateAppearancesPerGame": 73.19, - "totalGameTime": "59:37:00", - "totalInningsPlayed": 199.5, - "totalHits": 259, - "totalRuns": 192, - "totalPlateAppearances": 1537, - "totalPitchers": 239, - "totalPitches": 6924, - "totalGames": 21, - "total7InnGames": 1, - "total9InnGames": 9, - "timePerGame": "02:50:20", - "timePerPitch": "00:00:30", - "timePerHit": "00:13:48", - "timePerRun": "00:18:37", - "timePerPlateAppearance": "00:02:19", - "timePer9Inn": "02:43:16", - "timePer77PlateAppearances": "02:59:11", - "totalExtraInnTime": "00:00:00", - "timePer7InnGameWithoutExtraInn": "00:00:00", - "total9InnGamesCompletedEarly": 1, - "total9InnGamesWithoutExtraInn": 9, - "total9InnGamesScheduled": 10, - "hitsPerRun": 1.349, - "pitchesPerPitcher": 28.971, - "season": "2021", - "sport": { - "id": 586, - "code": "hsb", - "link": "/api/v1/sports/586" - }, - "prPortalCalculatedFields": { - "total7InnGames": 1, - "total9InnGames": 9, - "totalExtraInnGames": 11, - "timePer7InnGame": "02:00:00", - "timePer9InnGame": "02:57:06", - "timePerExtraInnGame": "02:49:21" - } - } - ] - } \ No newline at end of file diff --git a/tests/mock_tests/mock_json/games/game.json b/tests/mock_tests/mock_json/games/game.json deleted file mode 100644 index 24e0b633..00000000 --- a/tests/mock_tests/mock_json/games/game.json +++ /dev/null @@ -1,3345 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "gamePk": 715720, - "link": "/api/v1.1/game/715720/feed/live", - "metaData": { - "wait": 10, - "timeStamp": "20221104_040316", - "gameEvents": [ - "field_out", - "game_finished" - ], - "logicalEvents": [ - "midInning", - "countChange", - "count32", - "newRightHandedHit", - "basesEmpty", - "gameStateChangeToGameOver" - ] - }, - "gameData": { - "game": { - "pk": 715720, - "type": "W", - "doubleHeader": "N", - "id": "2022/11/03/houmlb-phimlb-1", - "gamedayType": "P", - "tiebreaker": "N", - "gameNumber": 1, - "calendarEventID": "14-715720-2022-11-03", - "season": "2022", - "seasonDisplay": "2022" - }, - "datetime": { - "dateTime": "2022-11-04T00:03:00Z", - "originalDate": "2022-11-03", - "officialDate": "2022-11-03", - "dayNight": "night", - "time": "8:03", - "ampm": "PM" - }, - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117", - "season": 2022, - "venue": { - "id": 2392, - "name": "Minute Maid Park", - "link": "/api/v1/venues/2392" - }, - "springVenue": { - "id": 5000, - "link": "/api/v1/venues/5000" - }, - "teamCode": "hou", - "fileCode": "hou", - "abbreviation": "HOU", - "teamName": "Astros", - "locationName": "Houston", - "firstYearOfPlay": "1962", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Houston", - "record": { - "gamesPlayed": 5, - "wildCardGamesBack": "-", - "leagueGamesBack": "-", - "springLeagueGamesBack": "-", - "sportGamesBack": "-", - "divisionGamesBack": "-", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 3, - "losses": 2, - "ties": 0, - "pct": ".600" - }, - "records": {}, - "divisionLeader": false, - "wins": 3, - "losses": 2, - "winningPercentage": ".600" - }, - "franchiseName": "Houston", - "clubName": "Astros", - "active": true - }, - "home": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143", - "season": 2022, - "venue": { - "id": 2681, - "name": "Citizens Bank Park", - "link": "/api/v1/venues/2681" - }, - "springVenue": { - "id": 2700, - "link": "/api/v1/venues/2700" - }, - "teamCode": "phi", - "fileCode": "phi", - "abbreviation": "PHI", - "teamName": "Phillies", - "locationName": "Philadelphia", - "firstYearOfPlay": "1883", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "division": { - "id": 204, - "name": "National League East", - "link": "/api/v1/divisions/204" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Philadelphia", - "record": { - "gamesPlayed": 5, - "wildCardGamesBack": "-", - "leagueGamesBack": "-", - "springLeagueGamesBack": "-", - "sportGamesBack": "-", - "divisionGamesBack": "-", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 2, - "losses": 3, - "ties": 0, - "pct": ".400" - }, - "records": {}, - "divisionLeader": false, - "wins": 2, - "losses": 3, - "winningPercentage": ".400" - }, - "franchiseName": "Philadelphia", - "clubName": "Phillies", - "active": true - } - }, - "players": { - "ID669016": { - "id": 669016, - "fullName": "Brandon Marsh", - "link": "/api/v1/people/669016", - "firstName": "Brandon", - "lastName": "Marsh", - "primaryNumber": "16", - "birthDate": "1997-12-18", - "currentAge": 24, - "birthCity": "Buford", - "birthStateProvince": "GA", - "birthCountry": "USA", - "height": "6' 4\"", - "weight": 215, - "active": true, - "primaryPosition": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "useName": "Brandon", - "middleName": "Chase", - "boxscoreName": "Marsh", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2016, - "mlbDebutDate": "2021-07-18", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Brandon Marsh", - "nameSlug": "brandon-marsh-669016", - "firstLastName": "Brandon Marsh", - "lastFirstName": "Marsh, Brandon", - "lastInitName": "Marsh, B", - "initLastName": "B Marsh", - "fullFMLName": "Brandon Chase Marsh", - "fullLFMName": "Marsh, Brandon Chase", - "strikeZoneTop": 3.11, - "strikeZoneBottom": 1.46 - }, - "ID664285": { - "id": 664285, - "fullName": "Framber Valdez", - "link": "/api/v1/people/664285", - "firstName": "Framber", - "lastName": "Valdez", - "primaryNumber": "59", - "birthDate": "1993-11-19", - "currentAge": 29, - "birthCity": "Palenque", - "birthCountry": "Dominican Republic", - "height": "5' 11\"", - "weight": 239, - "active": true, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Framber", - "boxscoreName": "Valdez, F", - "gender": "M", - "nameMatrilineal": "Pinales", - "isPlayer": true, - "isVerified": true, - "pronunciation": "FRAHM-burr", - "mlbDebutDate": "2018-08-21", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "L", - "description": "Left" - }, - "nameFirstLast": "Framber Valdez", - "nameSlug": "framber-valdez-664285", - "firstLastName": "Framber Valdez", - "lastFirstName": "Valdez, Framber", - "lastInitName": "Valdez, F", - "initLastName": "F Valdez", - "fullFMLName": "Framber Valdez", - "fullLFMName": "Valdez, Framber", - "strikeZoneTop": 3.319, - "strikeZoneBottom": 1.513 - } - }, - "venue": { - "id": 2681, - "name": "Citizens Bank Park", - "link": "/api/v1/venues/2681", - "location": { - "address1": "One Citizens Bank Way", - "city": "Philadelphia", - "state": "Pennsylvania", - "stateAbbrev": "PA", - "postalCode": "19148", - "defaultCoordinates": { - "latitude": 39.90539086, - "longitude": -75.16716957 - }, - "country": "USA", - "phone": "(215) 463-6000" - }, - "timeZone": { - "id": "America/New_York", - "offset": -5, - "tz": "EST" - }, - "fieldInfo": { - "capacity": 42901, - "turfType": "Grass", - "roofType": "Open", - "leftLine": 329, - "left": 369, - "leftCenter": 381, - "center": 401, - "rightCenter": 398, - "right": 369, - "rightLine": 330 - }, - "active": true - }, - "officialVenue": { - "id": 2681, - "link": "/api/v1/venues/2681" - }, - "weather": { - "condition": "Clear", - "temp": "59", - "wind": "2 mph, Out To CF" - }, - "gameInfo": { - "attendance": 45693, - "firstPitch": "2022-11-04T00:06:00.000Z", - "gameDurationMinutes": 237 - }, - "review": { - "hasChallenges": true, - "away": { - "used": 0, - "remaining": 2 - }, - "home": { - "used": 0, - "remaining": 2 - } - }, - "flags": { - "noHitter": false, - "perfectGame": false, - "awayTeamNoHitter": false, - "awayTeamPerfectGame": false, - "homeTeamNoHitter": false, - "homeTeamPerfectGame": false - }, - "alerts": [], - "probablePitchers": { - "away": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "home": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - } - }, - "officialScorer": { - "id": 433437, - "fullName": "Mike Maconi", - "link": "/api/v1/people/433437" - }, - "primaryDatacaster": { - "id": 427544, - "fullName": "Hank Widmer", - "link": "/api/v1/people/427544" - } - }, - "liveData": { - "plays": { - "allPlays": [ - { - "result": { - "type": "atBat", - "event": "Double", - "eventType": "double", - "description": "Jose Altuve doubles (3) on a sharp fly ball to center fielder Brandon Marsh. Jose Altuve to 3rd. Jose Altuve advances to 3rd, on a fielding error by center fielder Brandon Marsh.", - "rbi": 0, - "awayScore": 0, - "homeScore": 0 - }, - "about": { - "atBatIndex": 0, - "halfInning": "top", - "isTopInning": true, - "inning": 1, - "startTime": "2022-11-04T00:06:04.539Z", - "endTime": "2022-11-04T00:06:40.700Z", - "isComplete": true, - "isScoringPlay": false, - "hasReview": false, - "hasOut": false, - "captivatingIndex": 34 - }, - "count": { - "balls": 1, - "strikes": 0, - "outs": 0 - }, - "matchup": { - "batter": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitcher": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "postOnThird": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "batterHotColdZones": [], - "pitcherHotColdZones": [], - "splits": { - "batter": "vs_RHP", - "pitcher": "vs_RHB", - "menOnBase": "RISP" - } - }, - "pitchIndex": [ - 3, - 4 - ], - "actionIndex": [ - 0, - 1, - 2 - ], - "runnerIndex": [ - 0, - 1 - ], - "runners": [ - { - "movement": { - "originBase": null, - "start": null, - "end": "2B", - "outBase": null, - "isOut": false, - "outNumber": null - }, - "details": { - "event": "Double", - "eventType": "double", - "movementReason": null, - "runner": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "responsiblePitcher": null, - "isScoringEvent": false, - "rbi": false, - "earned": false, - "teamUnearned": false, - "playIndex": 4 - }, - "credits": [ - { - "player": { - "id": 669016, - "link": "/api/v1/people/669016" - }, - "position": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "credit": "f_fielded_ball" - } - ] - }, - { - "movement": { - "originBase": null, - "start": "2B", - "end": "3B", - "outBase": null, - "isOut": false, - "outNumber": null - }, - "details": { - "event": "Error", - "eventType": "error", - "movementReason": "r_adv_play", - "runner": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "responsiblePitcher": null, - "isScoringEvent": false, - "rbi": false, - "earned": false, - "teamUnearned": false, - "playIndex": 4 - }, - "credits": [ - { - "player": { - "id": 669016, - "link": "/api/v1/people/669016" - }, - "position": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "credit": "f_fielding_error" - } - ] - } - ], - "playEvents": [ - { - "details": { - "description": "Status Change - Pre-Game", - "event": "Game Advisory", - "eventType": "game_advisory", - "awayScore": 0, - "homeScore": 0, - "isScoringPlay": false, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 0 - }, - "index": 0, - "startTime": "2022-11-03T20:27:06.286Z", - "endTime": "2022-11-03T23:40:33.028Z", - "isPitch": false, - "type": "action", - "player": { - "id": 514888, - "link": "/api/v1/people/514888" - } - }, - { - "details": { - "description": "Status Change - Warmup", - "event": "Game Advisory", - "eventType": "game_advisory", - "awayScore": 0, - "homeScore": 0, - "isScoringPlay": false, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 0 - }, - "index": 1, - "startTime": "2022-11-03T23:40:33.028Z", - "endTime": "2022-11-04T00:05:45.901Z", - "isPitch": false, - "type": "action", - "player": { - "id": 514888, - "link": "/api/v1/people/514888" - } - }, - { - "details": { - "description": "Status Change - In Progress", - "event": "Game Advisory", - "eventType": "game_advisory", - "awayScore": 0, - "homeScore": 0, - "isScoringPlay": false, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 0 - }, - "index": 2, - "startTime": "2022-11-04T00:05:45.901Z", - "endTime": "2022-11-04T00:06:06.873Z", - "isPitch": false, - "type": "action", - "player": { - "id": 514888, - "link": "/api/v1/people/514888" - } - }, - { - "details": { - "call": { - "code": "B", - "description": "Ball" - }, - "description": "Ball", - "code": "B", - "ballColor": "rgba(39, 161, 39, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "type": { - "code": "SI", - "description": "Sinker" - }, - "hasReview": false - }, - "count": { - "balls": 1, - "strikes": 0, - "outs": 0 - }, - "pitchData": { - "startSpeed": 94.6, - "endSpeed": 86.6, - "strikeZoneTop": 2.93, - "strikeZoneBottom": 1.35, - "coordinates": { - "aY": 30.82, - "aZ": -18.55, - "pfxX": -6.53, - "pfxZ": 7.13, - "pX": 1.07, - "pZ": 2.11, - "vX0": 7.72, - "vY0": -137.49, - "vZ0": -7.23, - "x": 76.12, - "y": 181.81, - "x0": -0.93, - "y0": 50, - "z0": 6.04, - "aX": -12.49 - }, - "breaks": { - "breakAngle": 28.8, - "breakLength": 4.8, - "breakY": 24, - "breakVertical": -19.2, - "breakVerticalInduced": 11.5, - "breakHorizontal": 10.2, - "spinRate": 2120, - "spinDirection": 216 - }, - "zone": 14, - "typeConfidence": 0.84, - "plateTime": 0.4, - "extension": 6.65 - }, - "index": 3, - "playId": "01d0b33f-b99e-477a-92c5-280a1b4bda0a", - "pitchNumber": 1, - "startTime": "2022-11-04T00:06:06.873Z", - "endTime": "2022-11-04T00:06:10.638Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "D", - "description": "In play, no out" - }, - "description": "In play, no out", - "code": "D", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "hasReview": false - }, - "count": { - "balls": 1, - "strikes": 0, - "outs": 0 - }, - "pitchData": { - "startSpeed": 93.9, - "endSpeed": 85.8, - "strikeZoneTop": 2.85, - "strikeZoneBottom": 1.3, - "coordinates": { - "aY": 30.77, - "aZ": -17.31, - "pfxX": -7.5, - "pfxZ": 7.9, - "pX": 0.44, - "pZ": 2.33, - "vX0": 6.17, - "vY0": -136.51, - "vZ0": -6.87, - "x": 100.33, - "y": 175.86, - "x0": -0.88, - "y0": 50, - "z0": 6.08, - "aX": -14.11 - }, - "breaks": { - "breakAngle": 33.6, - "breakLength": 4.8, - "breakY": 24, - "breakVertical": -18.1, - "breakVerticalInduced": 13, - "breakHorizontal": 12.2, - "spinRate": 2238, - "spinDirection": 214 - }, - "zone": 6, - "typeConfidence": 0.91, - "plateTime": 0.4, - "extension": 6.69 - }, - "hitData": { - "launchSpeed": 104.9, - "launchAngle": 26, - "totalDistance": 399, - "trajectory": "fly_ball", - "hardness": "hard", - "location": "8", - "coordinates": { - "coordX": 162.78, - "coordY": 41.75 - } - }, - "index": 4, - "playId": "cfd9887e-d9a1-41d9-9eab-8f8610185f31", - "pitchNumber": 2, - "startTime": "2022-11-04T00:06:23.669Z", - "endTime": "2022-11-04T00:06:40.700Z", - "isPitch": true, - "type": "pitch" - } - ], - "playEndTime": "2022-11-04T00:06:40.700Z", - "atBatIndex": 0 - }, - { - "result": { - "type": "atBat", - "event": "Single", - "eventType": "single", - "description": "Jeremy Pena singles on a ground ball to center fielder Brandon Marsh. Jose Altuve scores.", - "rbi": 1, - "awayScore": 1, - "homeScore": 0 - }, - "about": { - "atBatIndex": 1, - "halfInning": "top", - "isTopInning": true, - "inning": 1, - "startTime": "2022-11-04T00:07:07.446Z", - "endTime": "2022-11-04T00:07:54.663Z", - "isComplete": true, - "isScoringPlay": true, - "hasReview": false, - "hasOut": false, - "captivatingIndex": 33 - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 0 - }, - "matchup": { - "batter": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitcher": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "postOnFirst": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "batterHotColdZones": [], - "pitcherHotColdZones": [], - "splits": { - "batter": "vs_RHP", - "pitcher": "vs_RHB", - "menOnBase": "Men_On" - } - }, - "pitchIndex": [ - 0, - 1 - ], - "actionIndex": [], - "runnerIndex": [ - 0, - 1 - ], - "runners": [ - { - "movement": { - "originBase": null, - "start": null, - "end": "1B", - "outBase": null, - "isOut": false, - "outNumber": null - }, - "details": { - "event": "Single", - "eventType": "single", - "movementReason": null, - "runner": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "responsiblePitcher": null, - "isScoringEvent": false, - "rbi": false, - "earned": false, - "teamUnearned": false, - "playIndex": 1 - }, - "credits": [ - { - "player": { - "id": 669016, - "link": "/api/v1/people/669016" - }, - "position": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "credit": "f_fielded_ball" - } - ] - }, - { - "movement": { - "originBase": "3B", - "start": "3B", - "end": "score", - "outBase": null, - "isOut": false, - "outNumber": null - }, - "details": { - "event": "Single", - "eventType": "single", - "movementReason": "r_adv_play", - "runner": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "responsiblePitcher": { - "id": 592789, - "link": "/api/v1/people/592789" - }, - "isScoringEvent": true, - "rbi": true, - "earned": true, - "teamUnearned": false, - "playIndex": 1 - }, - "credits": [] - } - ], - "playEvents": [ - { - "details": { - "call": { - "code": "S", - "description": "Swinging Strike" - }, - "description": "Swinging Strike", - "code": "S", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(0, 34, 255, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "CU", - "description": "Curveball" - }, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 0 - }, - "pitchData": { - "startSpeed": 78.5, - "endSpeed": 72.9, - "strikeZoneTop": 3.63, - "strikeZoneBottom": 1.75, - "coordinates": { - "aY": 19.67, - "aZ": -26.82, - "pfxX": 6, - "pfxZ": 4.01, - "pX": 1.39, - "pZ": 2.19, - "vX0": 3.32, - "vY0": -114.33, - "vZ0": -3.07, - "x": 64.01, - "y": 179.76, - "x0": -0.86, - "y0": 50, - "z0": 6.16, - "aX": 8 - }, - "breaks": { - "breakAngle": 16.8, - "breakLength": 8.4, - "breakY": 24, - "breakVertical": -37.2, - "breakVerticalInduced": 6.8, - "breakHorizontal": -11.6, - "spinRate": 2136, - "spinDirection": 64 - }, - "zone": 14, - "typeConfidence": 0.9, - "plateTime": 0.48, - "extension": 6.8 - }, - "index": 0, - "playId": "8767a33e-bd4d-4e7e-bf31-85bcd6f5e8ff", - "pitchNumber": 1, - "startTime": "2022-11-04T00:07:19.109Z", - "endTime": "2022-11-04T00:07:24.013Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "E", - "description": "In play, run(s)" - }, - "description": "In play, run(s)", - "code": "E", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 0 - }, - "pitchData": { - "startSpeed": 95.4, - "endSpeed": 87.1, - "strikeZoneTop": 3.63, - "strikeZoneBottom": 1.75, - "coordinates": { - "aY": 32.39, - "aZ": -18.18, - "pfxX": -8.13, - "pfxZ": 7.2, - "pX": -0.77, - "pZ": 2.47, - "vX0": 3, - "vY0": -138.78, - "vZ0": -6.81, - "x": 146.42, - "y": 172.19, - "x0": -0.82, - "y0": 50, - "z0": 6.17, - "aX": -15.78 - }, - "breaks": { - "breakAngle": 37.2, - "breakLength": 4.8, - "breakY": 24, - "breakVertical": -18.5, - "breakVerticalInduced": 11.8, - "breakHorizontal": 14, - "spinRate": 2257, - "spinDirection": 218 - }, - "zone": 13, - "typeConfidence": 0.91, - "plateTime": 0.4, - "extension": 6.56 - }, - "hitData": { - "launchSpeed": 84.1, - "launchAngle": 5, - "totalDistance": 80, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "8", - "coordinates": { - "coordX": 119.07, - "coordY": 91.76 - } - }, - "index": 1, - "playId": "b8b5e484-a190-4411-a4da-cf888a80960d", - "pitchNumber": 2, - "startTime": "2022-11-04T00:07:41.564Z", - "endTime": "2022-11-04T00:07:54.663Z", - "isPitch": true, - "type": "pitch" - } - ], - "playEndTime": "2022-11-04T00:07:54.663Z", - "atBatIndex": 1 - } - ], - - "currentPlay": { - "result": { - "type": "atBat", - "event": "Groundout", - "eventType": "field_out", - "description": "Nick Castellanos grounds out, shortstop Jeremy Pena to first baseman Trey Mancini.", - "rbi": 0, - "awayScore": 3, - "homeScore": 2 - }, - "about": { - "atBatIndex": 77, - "halfInning": "bottom", - "isTopInning": false, - "inning": 9, - "startTime": "2022-11-04T03:59:56.824Z", - "endTime": "2022-11-04T04:03:16.716Z", - "isComplete": true, - "isScoringPlay": false, - "hasReview": false, - "hasOut": true, - "captivatingIndex": 0 - }, - "count": { - "balls": 3, - "strikes": 2, - "outs": 3 - }, - "matchup": { - "batter": { - "id": 592206, - "fullName": "Nick Castellanos", - "link": "/api/v1/people/592206" - }, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitcher": { - "id": 519151, - "fullName": "Ryan Pressly", - "link": "/api/v1/people/519151" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "batterHotColdZoneStats": { - "stats": [ - { - "type": { - "displayName": "hotColdZones" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "name": "onBasePlusSlugging", - "zones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "02", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "03", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.000" - }, - { - "zone": "04", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "05", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "06", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "07", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "08", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "09", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "11", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.000" - }, - { - "zone": "12", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "13", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".750" - }, - { - "zone": "14", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".286" - } - ] - } - }, - { - "stat": { - "name": "battingAverage", - "zones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "02", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "03", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".500" - }, - { - "zone": "04", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "05", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "06", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "07", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "08", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "09", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "11", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "12", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "13", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".250" - }, - { - "zone": "14", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".143" - } - ] - } - }, - { - "stat": { - "name": "exitVelocity", - "zones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "02", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "90.53" - }, - { - "zone": "03", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "96.72" - }, - { - "zone": "04", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "05", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "06", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "79.97" - }, - { - "zone": "07", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "08", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "62.05" - }, - { - "zone": "09", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "85.83" - }, - { - "zone": "11", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "12", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "89.32" - }, - { - "zone": "13", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "104.92" - }, - { - "zone": "14", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "83.11" - } - ] - } - } - ] - } - ] - }, - "batterHotColdZones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "02", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "03", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.000" - }, - { - "zone": "04", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "05", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "06", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "07", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": "-" - }, - { - "zone": "08", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "09", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "11", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.000" - }, - { - "zone": "12", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".000" - }, - { - "zone": "13", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".750" - }, - { - "zone": "14", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".286" - } - ], - "pitcherHotColdZones": [], - "splits": { - "batter": "vs_RHP", - "pitcher": "vs_RHB", - "menOnBase": "Empty" - } - }, - "pitchIndex": [ - 0, - 1, - 2, - 3, - 4, - 5 - ], - "actionIndex": [], - "runnerIndex": [ - 0 - ], - "runners": [ - { - "movement": { - "originBase": null, - "start": null, - "end": null, - "outBase": "1B", - "isOut": true, - "outNumber": 3 - }, - "details": { - "event": "Groundout", - "eventType": "field_out", - "movementReason": null, - "runner": { - "id": 592206, - "fullName": "Nick Castellanos", - "link": "/api/v1/people/592206" - }, - "responsiblePitcher": null, - "isScoringEvent": false, - "rbi": false, - "earned": false, - "teamUnearned": false, - "playIndex": 5 - }, - "credits": [ - { - "player": { - "id": 665161, - "link": "/api/v1/people/665161" - }, - "position": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "credit": "f_assist" - }, - { - "player": { - "id": 641820, - "link": "/api/v1/people/641820" - }, - "position": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "credit": "f_putout" - } - ] - } - ], - "playEvents": [ - { - "details": { - "call": { - "code": "S", - "description": "Swinging Strike" - }, - "description": "Swinging Strike", - "code": "S", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(0, 0, 254, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "SL", - "description": "Slider" - }, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 2 - }, - "pitchData": { - "startSpeed": 88.1, - "endSpeed": 81.8, - "strikeZoneTop": 3.67, - "strikeZoneBottom": 1.76, - "coordinates": { - "aY": 24.26, - "aZ": -26.98, - "pfxX": 2.26, - "pfxZ": 3.09, - "pX": 0.78, - "pZ": 0.96, - "vX0": 1.78, - "vY0": -128.22, - "vZ0": -6.87, - "x": 87.29, - "y": 212.97, - "x0": -0.21, - "y0": 50.01, - "z0": 5.75, - "aX": 3.8 - }, - "breaks": { - "breakAngle": 8.4, - "breakLength": 7.2, - "breakY": 24, - "breakVertical": -30.6, - "breakVerticalInduced": 4.4, - "breakHorizontal": -4.4, - "spinRate": 2637, - "spinDirection": 150 - }, - "zone": 14, - "typeConfidence": 0.9, - "plateTime": 0.43, - "extension": 6.33 - }, - "index": 0, - "playId": "2df1b100-bc69-4863-96bf-40b78ab7c051", - "pitchNumber": 1, - "startTime": "2022-11-04T04:00:01.915Z", - "endTime": "2022-11-04T04:00:04.915Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "F", - "description": "Foul" - }, - "description": "Foul", - "code": "F", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(0, 0, 254, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "SL", - "description": "Slider" - }, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 2, - "outs": 2 - }, - "pitchData": { - "startSpeed": 88.7, - "endSpeed": 82.1, - "strikeZoneTop": 3.67, - "strikeZoneBottom": 1.76, - "coordinates": { - "aY": 24.99, - "aZ": -29.08, - "pfxX": 4.28, - "pfxZ": 1.81, - "pX": 0.2, - "pZ": 2.66, - "vX0": -0.05, - "vY0": -129.36, - "vZ0": -2.62, - "x": 109.23, - "y": 166.93, - "x0": -0.33, - "y0": 50, - "z0": 5.9, - "aX": 7.32 - }, - "breaks": { - "breakAngle": 14.4, - "breakLength": 7.2, - "breakY": 24, - "breakVertical": -31.4, - "breakVerticalInduced": 3, - "breakHorizontal": -7.8, - "spinRate": 2686, - "spinDirection": 135 - }, - "zone": 5, - "typeConfidence": 0.91, - "plateTime": 0.42, - "extension": 6.25 - }, - "index": 1, - "playId": "a639e5b6-621e-4efc-b4dc-2cbf02c7e907", - "pitchNumber": 2, - "startTime": "2022-11-04T04:00:31.181Z", - "endTime": "2022-11-04T04:00:39.186Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "B", - "description": "Ball" - }, - "description": "Ball", - "code": "B", - "ballColor": "rgba(39, 161, 39, 1.0)", - "trailColor": "rgba(0, 0, 254, 1.0)", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "type": { - "code": "SL", - "description": "Slider" - }, - "hasReview": false - }, - "count": { - "balls": 1, - "strikes": 2, - "outs": 2 - }, - "pitchData": { - "startSpeed": 89.6, - "endSpeed": 82.9, - "strikeZoneTop": 3.55, - "strikeZoneBottom": 1.79, - "coordinates": { - "aY": 26.05, - "aZ": -27.47, - "pfxX": 2.32, - "pfxZ": 2.72, - "pX": 1.33, - "pZ": 1.22, - "vX0": 3.24, - "vY0": -130.44, - "vZ0": -6.35, - "x": 66.19, - "y": 205.92, - "x0": -0.23, - "y0": 50, - "z0": 5.74, - "aX": 4.02 - }, - "breaks": { - "breakAngle": 9.6, - "breakLength": 7.2, - "breakY": 24, - "breakVertical": -30.1, - "breakVerticalInduced": 3.8, - "breakHorizontal": -4.9, - "spinRate": 2728, - "spinDirection": 128 - }, - "zone": 14, - "typeConfidence": 0.9, - "plateTime": 0.42, - "extension": 6.38 - }, - "index": 2, - "playId": "6c3a3fba-5070-441c-8746-a0b37f77d39d", - "pitchNumber": 3, - "startTime": "2022-11-04T04:01:22.328Z", - "endTime": "2022-11-04T04:01:26.880Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "*B", - "description": "Ball In Dirt" - }, - "description": "Ball In Dirt", - "code": "*B", - "ballColor": "rgba(39, 161, 39, 1.0)", - "trailColor": "rgba(0, 34, 255, 1.0)", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "type": { - "code": "CU", - "description": "Curveball" - }, - "hasReview": false - }, - "count": { - "balls": 2, - "strikes": 2, - "outs": 2 - }, - "pitchData": { - "startSpeed": 82.3, - "endSpeed": 75.7, - "strikeZoneTop": 3.5, - "strikeZoneBottom": 1.71, - "coordinates": { - "aY": 26.01, - "aZ": -39.49, - "pfxX": 7.54, - "pfxZ": -5.1, - "pX": 1.41, - "pZ": 0.24, - "vX0": 1.51, - "vY0": -119.82, - "vZ0": -4.64, - "x": 63.25, - "y": 232.21, - "x0": -0.21, - "y0": 50, - "z0": 5.78, - "aX": 10.82 - }, - "breaks": { - "breakAngle": 15.6, - "breakLength": 12, - "breakY": 24, - "breakVertical": -50.9, - "breakVerticalInduced": -10.2, - "breakHorizontal": -14, - "spinRate": 3064, - "spinDirection": 26 - }, - "zone": 14, - "typeConfidence": 0.88, - "plateTime": 0.46, - "extension": 6.3 - }, - "index": 3, - "playId": "ea104c1d-c5c5-4f60-920c-38e73c35ac15", - "pitchNumber": 4, - "startTime": "2022-11-04T04:01:49.179Z", - "endTime": "2022-11-04T04:01:52.708Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "*B", - "description": "Ball In Dirt" - }, - "description": "Ball In Dirt", - "code": "*B", - "ballColor": "rgba(39, 161, 39, 1.0)", - "trailColor": "rgba(0, 85, 254, 1.0)", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "type": { - "code": "CH", - "description": "Changeup" - }, - "hasReview": false - }, - "count": { - "balls": 3, - "strikes": 2, - "outs": 2 - }, - "pitchData": { - "startSpeed": 89.5, - "endSpeed": 81.3, - "strikeZoneTop": 3.55, - "strikeZoneBottom": 1.74, - "coordinates": { - "aY": 31.14, - "aZ": -26.19, - "pfxX": -10.68, - "pfxZ": 3.55, - "pX": 0.43, - "pZ": -0.15, - "vX0": 5.62, - "vY0": -129.91, - "vZ0": -9.08, - "x": 100.46, - "y": 242.71, - "x0": -0.39, - "y0": 50, - "z0": 5.43, - "aX": -17.98 - }, - "breaks": { - "breakAngle": 31.2, - "breakLength": 8.4, - "breakY": 24, - "breakVertical": -30.5, - "breakVerticalInduced": 4.3, - "breakHorizontal": 17.8, - "spinRate": 1942, - "spinDirection": 223 - }, - "zone": 14, - "typeConfidence": 0.93, - "plateTime": 0.42, - "extension": 6.55 - }, - "index": 4, - "playId": "8a911aa3-4381-4f4b-83ec-23f14a661444", - "pitchNumber": 5, - "startTime": "2022-11-04T04:02:24.112Z", - "endTime": "2022-11-04T04:02:27.562Z", - "isPitch": true, - "type": "pitch" - }, - { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(0, 0, 254, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SL", - "description": "Slider" - }, - "hasReview": false, - "runnerGoing": true - }, - "count": { - "balls": 3, - "strikes": 2, - "outs": 2 - }, - "pitchData": { - "startSpeed": 88.3, - "endSpeed": 82, - "strikeZoneTop": 3.67, - "strikeZoneBottom": 1.76, - "coordinates": { - "aY": 23.48, - "aZ": -30.77, - "pfxX": 3.99, - "pfxZ": 0.82, - "pX": 0.1, - "pZ": 3.31, - "vX0": 0.05, - "vY0": -128.81, - "vZ0": -0.7, - "x": 113.21, - "y": 149.43, - "x0": -0.44, - "y0": 50, - "z0": 5.94, - "aX": 6.79 - }, - "breaks": { - "breakAngle": 12, - "breakLength": 7.2, - "breakY": 24, - "breakVertical": -33, - "breakVerticalInduced": 1.6, - "breakHorizontal": -7.3, - "spinRate": 2683, - "spinDirection": 134 - }, - "zone": 2, - "typeConfidence": 0.91, - "plateTime": 0.42, - "extension": 6.3 - }, - "hitData": { - "launchSpeed": 90.5, - "launchAngle": -17, - "totalDistance": 12, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "6", - "coordinates": { - "coordX": 109.94, - "coordY": 149.05 - } - }, - "index": 5, - "playId": "6e9a9c6d-3163-4575-893d-61df462e9b88", - "pitchNumber": 6, - "startTime": "2022-11-04T04:03:07.728Z", - "endTime": "2022-11-04T04:03:16.716Z", - "isPitch": true, - "type": "pitch" - } - ], - "playEndTime": "2022-11-04T04:03:16.716Z", - "atBatIndex": 77 - }, - "scoringPlays": [ - 1, - 4, - 26, - 60, - 67 - ], - "playsByInning": [ - { - "startIndex": 0, - "endIndex": 8, - "top": [ - 0, - 1, - 2, - 3 - ], - "bottom": [ - 4, - 5, - 6, - 7, - 8 - ], - "hits": { - "away": [ - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "inning": 1, - "pitcher": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - }, - "batter": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "coordinates": { - "x": 162.78, - "y": 41.75 - }, - "type": "H", - "description": "Double" - }, - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "inning": 1, - "pitcher": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - }, - "batter": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "coordinates": { - "x": 119.07, - "y": 91.76 - }, - "type": "H", - "description": "Single" - } - ], - "home": [ - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "inning": 1, - "pitcher": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "batter": { - "id": 656941, - "fullName": "Kyle Schwarber", - "link": "/api/v1/people/656941" - }, - "coordinates": { - "x": 221.12, - "y": 83.65 - }, - "type": "H", - "description": "Home Run" - }, - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "inning": 1, - "pitcher": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "batter": { - "id": 656555, - "fullName": "Rhys Hoskins", - "link": "/api/v1/people/656555" - }, - "coordinates": { - "x": 82.58, - "y": 90.81 - }, - "type": "O", - "description": "Lineout" - }, - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "inning": 1, - "pitcher": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "batter": { - "id": 592663, - "fullName": "J.T. Realmuto", - "link": "/api/v1/people/592663" - }, - "coordinates": { - "x": 154.14, - "y": 133.8 - }, - "type": "O", - "description": "Pop Out" - }, - { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "inning": 1, - "pitcher": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "batter": { - "id": 592206, - "fullName": "Nick Castellanos", - "link": "/api/v1/people/592206" - }, - "coordinates": { - "x": 100.82, - "y": 105.95 - }, - "type": "O", - "description": "Flyout" - } - ] - } - } - ] - }, - "linescore": { - "currentInning": 9, - "currentInningOrdinal": "9th", - "inningState": "Bottom", - "inningHalf": "Bottom", - "isTopInning": false, - "scheduledInnings": 9, - "innings": [ - { - "num": 1, - "ordinalNum": "1st", - "home": { - "runs": 1, - "hits": 1, - "errors": 1, - "leftOnBase": 1 - }, - "away": { - "runs": 1, - "hits": 2, - "errors": 0, - "leftOnBase": 0 - } - }, - { - "num": 2, - "ordinalNum": "2nd", - "home": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 3 - }, - "away": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 0 - } - }, - { - "num": 3, - "ordinalNum": "3rd", - "home": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 2 - }, - "away": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 0 - } - }, - { - "num": 4, - "ordinalNum": "4th", - "home": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 0 - }, - "away": { - "runs": 1, - "hits": 2, - "errors": 0, - "leftOnBase": 1 - } - }, - { - "num": 5, - "ordinalNum": "5th", - "home": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 1 - }, - "away": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 0 - } - }, - { - "num": 6, - "ordinalNum": "6th", - "home": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 2 - }, - "away": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 2 - } - }, - { - "num": 7, - "ordinalNum": "7th", - "home": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 0 - }, - "away": { - "runs": 0, - "hits": 1, - "errors": 0, - "leftOnBase": 1 - } - }, - { - "num": 8, - "ordinalNum": "8th", - "home": { - "runs": 1, - "hits": 1, - "errors": 0, - "leftOnBase": 2 - }, - "away": { - "runs": 1, - "hits": 1, - "errors": 0, - "leftOnBase": 2 - } - }, - { - "num": 9, - "ordinalNum": "9th", - "home": { - "runs": 0, - "hits": 0, - "errors": 0, - "leftOnBase": 1 - }, - "away": { - "runs": 0, - "hits": 2, - "errors": 0, - "leftOnBase": 1 - } - } - ], - "teams": { - "home": { - "runs": 2, - "hits": 6, - "errors": 1, - "leftOnBase": 12 - }, - "away": { - "runs": 3, - "hits": 9, - "errors": 0, - "leftOnBase": 7 - } - }, - "defense": { - "pitcher": { - "id": 519151, - "fullName": "Ryan Pressly", - "link": "/api/v1/people/519151" - }, - "catcher": { - "id": 455117, - "fullName": "Martin Maldonado", - "link": "/api/v1/people/455117" - }, - "first": { - "id": 641820, - "fullName": "Trey Mancini", - "link": "/api/v1/people/641820" - }, - "second": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "third": { - "id": 608324, - "fullName": "Alex Bregman", - "link": "/api/v1/people/608324" - }, - "shortstop": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "left": { - "id": 670541, - "fullName": "Yordan Alvarez", - "link": "/api/v1/people/670541" - }, - "center": { - "id": 676801, - "fullName": "Chas McCormick", - "link": "/api/v1/people/676801" - }, - "right": { - "id": 663656, - "fullName": "Kyle Tucker", - "link": "/api/v1/people/663656" - }, - "batter": { - "id": 665161, - "fullName": "Jeremy Pena", - "link": "/api/v1/people/665161" - }, - "onDeck": { - "id": 670541, - "fullName": "Yordan Alvarez", - "link": "/api/v1/people/670541" - }, - "inHole": { - "id": 608324, - "fullName": "Alex Bregman", - "link": "/api/v1/people/608324" - }, - "battingOrder": 2, - "team": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - } - }, - "offense": { - "batter": { - "id": 592206, - "fullName": "Nick Castellanos", - "link": "/api/v1/people/592206" - }, - "onDeck": { - "id": 664761, - "fullName": "Alec Bohm", - "link": "/api/v1/people/664761" - }, - "inHole": { - "id": 681082, - "fullName": "Bryson Stott", - "link": "/api/v1/people/681082" - }, - "pitcher": { - "id": 621107, - "fullName": "Zach Eflin", - "link": "/api/v1/people/621107" - }, - "battingOrder": 5, - "team": { - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - } - }, - "balls": 3, - "strikes": 2, - "outs": 3 - }, - - "boxscore": { - "teams": { - "away": { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "teamStats": { - "batting": { - "flyOuts": 3, - "groundOuts": 8, - "runs": 3, - "doubles": 3, - "triples": 0, - "homeRuns": 1, - "strikeOuts": 12, - "baseOnBalls": 2, - "intentionalWalks": 0, - "hits": 9, - "hitByPitch": 1, - "avg": ".240", - "atBats": 34, - "obp": ".303", - "slg": ".368", - "ops": ".671", - "caughtStealing": 1, - "stolenBases": 1, - "stolenBasePercentage": ".500", - "groundIntoDoublePlay": 1, - "groundIntoTriplePlay": 0, - "plateAppearances": 37, - "totalBases": 15, - "rbi": 3, - "leftOnBase": 18, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "34.00" - }, - "pitching": { - "groundOuts": 0, - "airOuts": 0, - "runs": 2, - "doubles": 0, - "triples": 0, - "homeRuns": 1, - "strikeOuts": 12, - "baseOnBalls": 6, - "intentionalWalks": 0, - "hits": 6, - "hitByPitch": 2, - "atBats": 33, - "obp": ".341", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "numberOfPitches": 165, - "era": "3.20", - "inningsPitched": "9.0", - "saveOpportunities": 0, - "earnedRuns": 2, - "whip": "1.07", - "battersFaced": 41, - "outs": 27, - "completeGames": 0, - "shutouts": 0, - "pitchesThrown": 165, - "balls": 63, - "strikes": 102, - "strikePercentage": ".620", - "hitBatsmen": 2, - "balks": 0, - "wildPitches": 0, - "pickoffs": 0, - "groundOutsToAirouts": "-.--", - "rbi": 2, - "pitchesPerInning": "18.33", - "runsScoredPer9": "2.00", - "homeRunsPer9": "1.00", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0, - "passedBall": 0 - }, - "fielding": { - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 3, - "putOuts": 27, - "errors": 0, - "chances": 30, - "passedBall": 0, - "pickoffs": 0 - } - }, - "players": { - "ID664285": { - "person": { - "id": 664285, - "fullName": "Framber Valdez", - "link": "/api/v1/people/664285" - }, - "jerseyNumber": "59", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 117, - "stats": { - "batting": {}, - "pitching": {}, - "fielding": {} - }, - "seasonStats": { - "batting": { - "gamesPlayed": 0, - "flyOuts": 0, - "groundOuts": 0, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "avg": ".000", - "atBats": 0, - "obp": ".000", - "slg": ".000", - "ops": ".000", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 0, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 0, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".---", - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "pitching": { - "gamesPlayed": 3, - "gamesStarted": 3, - "groundOuts": 24, - "airOuts": 8, - "runs": 5, - "doubles": 5, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 24, - "baseOnBalls": 6, - "intentionalWalks": 0, - "hits": 12, - "hitByPitch": 0, - "atBats": 68, - "obp": ".243", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "numberOfPitches": 297, - "era": "1.42", - "inningsPitched": "19.0", - "wins": 2, - "losses": 0, - "saves": 0, - "saveOpportunities": 0, - "holds": 0, - "blownSaves": 0, - "earnedRuns": 3, - "whip": "0.95", - "battersFaced": 74, - "outs": 57, - "gamesPitched": 3, - "completeGames": 0, - "shutouts": 0, - "pitchesThrown": 297, - "balls": 99, - "strikes": 198, - "strikePercentage": ".670", - "hitBatsmen": 0, - "balks": 0, - "wildPitches": 0, - "pickoffs": 0, - "groundOutsToAirouts": "3.00", - "rbi": 0, - "winPercentage": "1.000", - "pitchesPerInning": "15.63", - "gamesFinished": 0, - "strikeoutWalkRatio": "4.00", - "strikeoutsPer9Inn": "11.37", - "walksPer9Inn": "2.84", - "hitsPer9Inn": "5.68", - "runsScoredPer9": "2.37", - "homeRunsPer9": "0.00", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0, - "passedBall": 0 - }, - "fielding": { - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 1, - "putOuts": 0, - "errors": 2, - "chances": 3, - "fielding": ".333", - "passedBall": 0, - "pickoffs": 0 - } - }, - "gameStatus": { - "isCurrentBatter": false, - "isCurrentPitcher": false, - "isOnBench": true, - "isSubstitute": false - } - } - }, - "batters": [ - 514888, - 665161, - 670541, - 608324, - 663656, - 493329, - 641820, - 682073, - 676801, - 455117, - 434378, - 593576, - 650556, - 606160, - 519151 - ], - "pitchers": [ - 434378, - 593576, - 650556, - 606160, - 519151 - ], - "bench": [ - 649557, - 643289, - 543877 - ], - "bullpen": [ - 686613, - 677651, - 664299, - 621121, - 519293, - 592773, - 664353, - 664285 - ], - "battingOrder": [ - 514888, - 665161, - 670541, - 608324, - 663656, - 641820, - 682073, - 676801, - 455117 - ], - "info": [ - { - "title": "BATTING", - "fieldList": [ - { - "label": "2B", - "value": "Altuve (3, Syndergaard); Bregman (5, Brogdon); Gurriel (1, Domínguez)." - }, - { - "label": "HR", - "value": "Peña (4, 4th inning off Syndergaard, 0 on, 0 out)." - }, - { - "label": "TB", - "value": "Altuve 3; Bregman 2; Gurriel 2; Hensley; Maldonado; Peña 6." - }, - { - "label": "RBI", - "value": "Alvarez, Y (11); Peña 2 (8)." - }, - { - "label": "Runners left in scoring position, 2 out", - "value": "Tucker; Mancini 2; Gurriel; Maldonado." - }, - { - "label": "GIDP", - "value": "Altuve." - }, - { - "label": "Team RISP", - "value": "1-for-11." - }, - { - "label": "Team LOB", - "value": "7." - } - ] - }, - { - "title": "BASERUNNING", - "fieldList": [ - { - "label": "SB", - "value": "Bregman (1, 2nd base off Robertson/Realmuto)." - }, - { - "label": "CS", - "value": "Peña (1, 2nd base by Syndergaard/Realmuto)." - } - ] - } - ], - "note": [ - { - "label": "a", - "value": "Struck out for Gurriel in the 8th." - } - ] - }, - "home": { - "team": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "teamStats": { - "batting": { - "flyOuts": 5, - "groundOuts": 4, - "runs": 2, - "doubles": 1, - "triples": 0, - "homeRuns": 1, - "strikeOuts": 12, - "baseOnBalls": 6, - "intentionalWalks": 0, - "hits": 6, - "hitByPitch": 2, - "avg": ".174", - "atBats": 33, - "obp": ".272", - "slg": ".342", - "ops": ".614", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 41, - "totalBases": 10, - "rbi": 2, - "leftOnBase": 18, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "33.00" - }, - "pitching": { - "groundOuts": 0, - "airOuts": 0, - "runs": 3, - "doubles": 0, - "triples": 0, - "homeRuns": 1, - "strikeOuts": 12, - "baseOnBalls": 2, - "intentionalWalks": 0, - "hits": 9, - "hitByPitch": 1, - "atBats": 34, - "obp": ".324", - "caughtStealing": 1, - "stolenBases": 1, - "stolenBasePercentage": ".500", - "numberOfPitches": 149, - "era": "3.40", - "inningsPitched": "9.0", - "saveOpportunities": 0, - "earnedRuns": 3, - "whip": "1.20", - "battersFaced": 37, - "outs": 27, - "completeGames": 0, - "shutouts": 0, - "pitchesThrown": 149, - "balls": 49, - "strikes": 100, - "strikePercentage": ".670", - "hitBatsmen": 1, - "balks": 0, - "wildPitches": 1, - "pickoffs": 0, - "groundOutsToAirouts": "-.--", - "rbi": 3, - "pitchesPerInning": "16.56", - "runsScoredPer9": "3.00", - "homeRunsPer9": "1.00", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0, - "passedBall": 0 - }, - "fielding": { - "caughtStealing": 1, - "stolenBases": 1, - "stolenBasePercentage": ".500", - "assists": 9, - "putOuts": 27, - "errors": 1, - "chances": 37, - "passedBall": 0, - "pickoffs": 0 - } - }, - "players": { - "ID516416": { - "person": { - "id": 516416, - "fullName": "Jean Segura", - "link": "/api/v1/people/516416" - }, - "jerseyNumber": "2", - "position": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 143, - "battingOrder": "800", - "stats": { - "batting": { - "gamesPlayed": 1, - "flyOuts": 0, - "groundOuts": 1, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 1, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 2, - "hitByPitch": 0, - "atBats": 4, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 4, - "totalBases": 2, - "rbi": 1, - "leftOnBase": 1, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "pitching": {}, - "fielding": { - "gamesStarted": 1, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 0, - "putOuts": 0, - "errors": 0, - "chances": 0, - "fielding": ".000", - "passedBall": 0, - "pickoffs": 0 - } - }, - "seasonStats": { - "batting": { - "gamesPlayed": 16, - "flyOuts": 0, - "groundOuts": 14, - "runs": 4, - "doubles": 2, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 12, - "baseOnBalls": 2, - "intentionalWalks": 0, - "hits": 12, - "hitByPitch": 1, - "avg": ".226", - "atBats": 53, - "obp": ".263", - "slg": ".264", - "ops": ".527", - "caughtStealing": 0, - "stolenBases": 1, - "stolenBasePercentage": "1.000", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 58, - "totalBases": 14, - "rbi": 7, - "leftOnBase": 21, - "sacBunts": 1, - "sacFlies": 1, - "babip": ".286", - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "pitching": { - "gamesPlayed": 0, - "gamesStarted": 0, - "groundOuts": 0, - "airOuts": 0, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "atBats": 0, - "obp": ".000", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "numberOfPitches": 0, - "era": "-.--", - "inningsPitched": "0.0", - "wins": 0, - "losses": 0, - "saves": 0, - "saveOpportunities": 0, - "holds": 0, - "blownSaves": 0, - "earnedRuns": 0, - "whip": "-", - "battersFaced": 0, - "outs": 0, - "gamesPitched": 0, - "completeGames": 0, - "shutouts": 0, - "balls": 0, - "strikes": 0, - "strikePercentage": "-.--", - "hitBatsmen": 0, - "balks": 0, - "wildPitches": 0, - "pickoffs": 0, - "groundOutsToAirouts": "-.--", - "rbi": 0, - "winPercentage": ".---", - "pitchesPerInning": "-.--", - "gamesFinished": 0, - "strikeoutWalkRatio": "-.--", - "strikeoutsPer9Inn": "-.--", - "walksPer9Inn": "-.--", - "hitsPer9Inn": "-.--", - "runsScoredPer9": "-.--", - "homeRunsPer9": "-.--", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0, - "passedBall": 0 - }, - "fielding": { - "gamesStarted": 1, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 36, - "putOuts": 15, - "errors": 1, - "chances": 52, - "fielding": ".981", - "passedBall": 0, - "pickoffs": 0 - } - }, - "gameStatus": { - "isCurrentBatter": false, - "isCurrentPitcher": false, - "isOnBench": false, - "isSubstitute": false - }, - "allPositions": [ - { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - } - ] - } - }, - "batters": [ - 656941, - 656555, - 592663, - 547180, - 592206, - 664761, - 681082, - 516416, - 669016, - 592789, - 641401, - 621237, - 622554, - 502085, - 621107 - ], - "pitchers": [ - 592789, - 641401, - 621237, - 622554, - 502085, - 621107 - ], - "bench": [ - 665155, - 624641, - 596117, - 663837 - ], - "bullpen": [ - 571479, - 502043, - 543272, - 656793, - 605400, - 624133, - 554430 - ], - "battingOrder": [ - 656941, - 656555, - 592663, - 547180, - 592206, - 664761, - 681082, - 516416, - 669016 - ], - "info": [ - { - "title": "BATTING", - "fieldList": [ - { - "label": "2B", - "value": "Harper (7, Verlander)." - }, - { - "label": "HR", - "value": "Schwarber (5, 1st inning off Verlander, 0 on, 0 out)." - }, - { - "label": "TB", - "value": "Bohm 2; Harper 2; Schwarber 4; Segura 2." - }, - { - "label": "RBI", - "value": "Schwarber (9); Segura (7)." - }, - { - "label": "Runners left in scoring position, 2 out", - "value": "Stott; Hoskins 2; Castellanos, N; Schwarber 2." - }, - { - "label": "Team RISP", - "value": "1-for-7." - }, - { - "label": "Team LOB", - "value": "12." - } - ] - }, - { - "title": "FIELDING", - "fieldList": [ - { - "label": "E", - "value": "Marsh (1, fielding)." - }, - { - "label": "DP", - "value": "2 (Realmuto-Stott; Bohm-Hoskins)." - } - ] - } - ], - "note": [] - } - }, - "officials": [ - { - "official": { - "id": 490319, - "fullName": "Jordan Baker", - "link": "/api/v1/people/490319" - }, - "officialType": "Home Plate" - }, - { - "official": { - "id": 484198, - "fullName": "Alan Porter", - "link": "/api/v1/people/484198" - }, - "officialType": "First Base" - }, - { - "official": { - "id": 428442, - "fullName": "James Hoye", - "link": "/api/v1/people/428442" - }, - "officialType": "Second Base" - }, - { - "official": { - "id": 573596, - "fullName": "Pat Hoberg", - "link": "/api/v1/people/573596" - }, - "officialType": "Third Base" - }, - { - "official": { - "id": 427248, - "fullName": "Dan Iassogna", - "link": "/api/v1/people/427248" - }, - "officialType": "Left Field" - }, - { - "official": { - "id": 503586, - "fullName": "Tripp Gibson", - "link": "/api/v1/people/503586" - }, - "officialType": "Right Field" - } - ], - "info": [ - { - "label": "WP", - "value": "Domínguez." - }, - { - "label": "HBP", - "value": "Bregman (by Alvarado); Marsh (by Abreu, B); Harper (by Pressly)." - }, - { - "label": "Pitches-strikes", - "value": "Verlander 94-58; Neris 11-7; Abreu, B 17-12; Montero 17-8; Pressly 26-17; Syndergaard 44-31; Brogdon 26-18; Alvarado 20-14; Domínguez 26-16; Robertson 20-11; Eflin 13-10." - }, - { - "label": "Groundouts-flyouts", - "value": "Verlander 1-3; Neris 0-1; Abreu, B 1-0; Montero 0-0; Pressly 2-1; Syndergaard 1-2; Brogdon 1-0; Alvarado 1-0; Domínguez 3-0; Robertson 1-1; Eflin 1-0." - }, - { - "label": "Batters faced", - "value": "Verlander 23; Neris 3; Abreu, B 5; Montero 4; Pressly 6; Syndergaard 11; Brogdon 7; Alvarado 5; Domínguez 6; Robertson 4; Eflin 4." - }, - { - "label": "Inherited runners-scored", - "value": "Abreu, B 1-0; Pressly 2-0; Robertson 2-1." - }, - { - "label": "Umpires", - "value": "HP: Jordan Baker. 1B: Alan Porter. 2B: James Hoye. 3B: Pat Hoberg. LF: Dan Iassogna. RF: Tripp Gibson. " - }, - { - "label": "Weather", - "value": "59 degrees, Clear." - }, - { - "label": "Wind", - "value": "2 mph, Out To CF." - }, - { - "label": "First pitch", - "value": "8:06 PM." - }, - { - "label": "T", - "value": "3:57." - }, - { - "label": "Att", - "value": "45,693." - }, - { - "label": "Venue", - "value": "Citizens Bank Park." - }, - { - "label": "November 3, 2022" - } - ], - "pitchingNotes": [ - "Syndergaard pitched to 1 batter in the 4th.", - "Domínguez pitched to 2 batters in the 8th." - ] - }, - "decisions": { - "winner": { - "id": 434378, - "fullName": "Justin Verlander", - "link": "/api/v1/people/434378" - }, - "loser": { - "id": 592789, - "fullName": "Noah Syndergaard", - "link": "/api/v1/people/592789" - }, - "save": { - "id": 519151, - "fullName": "Ryan Pressly", - "link": "/api/v1/people/519151" - } - }, - "leaders": { - "hitDistance": {}, - "hitSpeed": {}, - "pitchSpeed": {} - } - } -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/homerunderby/homerunderby.json b/tests/mock_tests/mock_json/homerunderby/homerunderby.json deleted file mode 100644 index 12816728..00000000 --- a/tests/mock_tests/mock_json/homerunderby/homerunderby.json +++ /dev/null @@ -1,6845 +0,0 @@ -{ - "info": { - "id": 511101, - "nonGameGuid": "79bfc387-9889-45e0-b135-6517e16f4565", - "name": "All-Star Workout Day: Home Run Derby", - "eventType": { - "code": "O", - "name": "Other" - }, - "eventDate": "2017-07-11T00:00:00Z", - "venue": { - "id": 4169, - "name": "Marlins Park", - "link": "/api/v1/venues/4169" - }, - "isMultiDay": false, - "isPrimaryCalendar": true, - "fileCode": "2017/07/10/mlb-112", - "eventNumber": 103, - "publicFacing": true, - "teams": [ - { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - { - "id": 109, - "name": "Arizona Diamondbacks", - "link": "/api/v1/teams/109" - }, - { - "id": 110, - "name": "Baltimore Orioles", - "link": "/api/v1/teams/110" - }, - { - "id": 111, - "name": "Boston Red Sox", - "link": "/api/v1/teams/111" - }, - { - "id": 112, - "name": "Chicago Cubs", - "link": "/api/v1/teams/112" - }, - { - "id": 113, - "name": "Cincinnati Reds", - "link": "/api/v1/teams/113" - }, - { - "id": 114, - "name": "Cleveland Indians", - "link": "/api/v1/teams/114" - }, - { - "id": 115, - "name": "Colorado Rockies", - "link": "/api/v1/teams/115" - }, - { - "id": 116, - "name": "Detroit Tigers", - "link": "/api/v1/teams/116" - }, - { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - { - "id": 118, - "name": "Kansas City Royals", - "link": "/api/v1/teams/118" - }, - { - "id": 119, - "name": "Los Angeles Dodgers", - "link": "/api/v1/teams/119" - }, - { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - { - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133" - }, - { - "id": 134, - "name": "Pittsburgh Pirates", - "link": "/api/v1/teams/134" - }, - { - "id": 135, - "name": "San Diego Padres", - "link": "/api/v1/teams/135" - }, - { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - { - "id": 137, - "name": "San Francisco Giants", - "link": "/api/v1/teams/137" - }, - { - "id": 138, - "name": "St. Louis Cardinals", - "link": "/api/v1/teams/138" - }, - { - "id": 139, - "name": "Tampa Bay Rays", - "link": "/api/v1/teams/139" - }, - { - "id": 140, - "name": "Texas Rangers", - "link": "/api/v1/teams/140" - }, - { - "id": 141, - "name": "Toronto Blue Jays", - "link": "/api/v1/teams/141" - }, - { - "id": 142, - "name": "Minnesota Twins", - "link": "/api/v1/teams/142" - }, - { - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - { - "id": 144, - "name": "Atlanta Braves", - "link": "/api/v1/teams/144" - }, - { - "id": 145, - "name": "Chicago White Sox", - "link": "/api/v1/teams/145" - }, - { - "id": 146, - "name": "Miami Marlins", - "link": "/api/v1/teams/146" - }, - { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - { - "id": 158, - "name": "Milwaukee Brewers", - "link": "/api/v1/teams/158" - } - ] - }, - "status": { - "state": "Final", - "currentRound": 3, - "currentRoundTimeLeft": "4:00", - "inTieBreaker": false, - "tieBreakerNum": 0, - "clockStopped": true, - "bonusTime": true - }, - "rounds": [ - { - "round": 1, - "numBatters": 8, - "matchups": [ - { - "topSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 519317, - "fullName": "Giancarlo Stanton", - "link": "/api/v1/people/519317" - }, - "topDerbyHitData": { - "launchSpeed": 121.000001, - "totalDistance": 496, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 121.000001, - "launchAngle": 6.000001, - "totalDistance": 182, - "coordinates": { - "coordX": 88.7243330720901, - "coordY": 134.31028486245282, - "landingPosX": -85.23144067224341, - "landingPosY": 160.48996663472863 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 32.133364421674685, - -66.68177828357233, - 2.070769956391603, - -13.891723119049406, - 21.300870928230722, - -18.428821964292624, - 9.64726412341314, - -2.80468269768424, - 0.3461559726713602 - ], - "trajectoryPolynomialY": [ - -80.38511483794548, - 183.60708999717554, - 1.9398590566955645, - -83.24744161880986, - 107.46699935411986, - -75.8437972027841, - 30.500597357307203, - -6.266237646386986, - 0.46574753944250435 - ], - "trajectoryPolynomialZ": [ - -16.945359890152943, - 61.2831761801478, - -59.31602043808958, - 71.38011443572952, - -103.76044739306225, - 98.04201598716374, - -55.94896536745857, - 17.555738441394, - -2.32074310023237 - ], - "validTimeInterval": [ - 0.4759656710027564, - 1.6986445040105695 - ], - "measuredTimeInterval": [ - 0.4759656710027564, - 1.6940913467558407 - ] - } - }, - "isHomeRun": false, - "playId": "0e88a3d5-4a16-4937-bf14-3ecc00dc9f9c", - "timeRemaining": "3:48", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 106.000001, - "launchAngle": 30.000001, - "totalDistance": 429, - "coordinates": { - "coordX": 110.58006036082529, - "coordY": 17.54192101425582, - "landingPosX": -35.2579518715961, - "landingPosY": 427.48279857976337 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 17.953641853805618, - -47.785715529449035, - 19.42977276671014, - -3.398978193204823, - -0.7845600359480832, - 0.5648372220325301, - -0.12491478842188641, - 0.012787884173502963, - -0.0005116782848867642 - ], - "trajectoryPolynomialY": [ - -66.31634863346272, - 160.5211813028262, - -36.11032539848496, - 9.681963294491283, - -2.516707210792061, - 0.5691870257391934, - -0.08869025651715008, - 0.00782796474781931, - -0.00029018914747536324 - ], - "trajectoryPolynomialZ": [ - -36.393471357507615, - 91.5299905886195, - -15.65007934327053, - 0.2973915221293711, - 0.08933182403782632, - -0.05388748620348726, - 0.01194164933460883, - -0.0011875818416647143, - 0.000045182991279599504 - ], - "validTimeInterval": [ - 0.4714241300024811, - 6.162768734494625 - ], - "measuredTimeInterval": [ - 0.4714241300024811, - 3.463147770437759 - ] - } - }, - "isHomeRun": true, - "playId": "0c455416-98ce-426e-bce9-d5fbfa6eeb8c", - "timeRemaining": "3:37", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 97.000001, - "launchAngle": 42.000001, - "totalDistance": 327, - "coordinates": { - "coordX": 123.6711850261219, - "coordY": 61.53667970251183, - "landingPosX": -5.324874687462839, - "landingPosY": 326.888041354369 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 11.442830519559907, - -32.714179112103515, - 19.70100611581722, - -9.73760203297563, - 3.7895069913206543, - -0.9628104019413473, - 0.14543777378795839, - -0.011806365049053717, - 0.0003962286759741023 - ], - "trajectoryPolynomialY": [ - -51.52449369027318, - 128.41242917627702, - -30.717925302147954, - 6.321989954375865, - -1.0487046334597734, - 0.19197996920603916, - -0.031105424454408108, - 0.002965537296096508, - -0.00011511837013536847 - ], - "trajectoryPolynomialZ": [ - -45.82764801754007, - 115.92112594476804, - -23.08365080730633, - 2.533793242606385, - -0.5082814756006739, - 0.07513239460160473, - -0.009138363968517723, - 0.0009282840894892433, - -0.00004468450492824837 - ], - "validTimeInterval": [ - 0.4676550828285342, - 6.717715507633166 - ], - "measuredTimeInterval": [ - 0.4676550828285342, - 3.463395813743793 - ] - } - }, - "isHomeRun": false, - "playId": "bfb7f1ca-0243-4ff8-99e8-6b5c2bcaec01", - "timeRemaining": "3:31", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 108.000001, - "launchAngle": 37.000001, - "totalDistance": 407, - "coordinates": { - "coordX": 103.63887521682382, - "coordY": 27.712815929136184, - "landingPosX": -51.129088689621945, - "landingPosY": 404.22687593731223 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 22.11777352814273, - -64.82683008883255, - 43.729144962070485, - -23.484888465357976, - 8.260301239898004, - -1.7900460914595002, - 0.23044614413603823, - -0.016144190152150892, - 0.00047342155140281427 - ], - "trajectoryPolynomialY": [ - -59.48529051309239, - 150.67648353491663, - -39.45504873030753, - 11.827020884150974, - -3.497711817184801, - 0.8439234131657698, - -0.13069790135381584, - 0.01105152105388803, - -0.0003855397713096895 - ], - "trajectoryPolynomialZ": [ - -41.37211950440423, - 99.69395343010652, - -2.2063495096027896, - -11.88325005012371, - 5.425383921428397, - -1.3660144698858492, - 0.195036267377348, - -0.014726005619849776, - 0.0004575291407745803 - ], - "validTimeInterval": [ - 0.4609681786426706, - 6.949481972587923 - ], - "measuredTimeInterval": [ - 0.4609681786426706, - 3.4589575640625956 - ] - } - }, - "isHomeRun": false, - "playId": "f3f52161-3420-490f-9fca-c3fae8abe790", - "timeRemaining": "3:25", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 1, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 16 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142" - }, - "topDerbyHitData": { - "launchSpeed": 116.000001, - "totalDistance": 483, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 102.000001, - "launchAngle": 17.000001, - "totalDistance": 362, - "coordinates": { - "coordX": 128.06783905459645, - "coordY": 46.173862836932216, - "landingPosX": 4.728148849554798, - "landingPosY": 362.01538104139655 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 13.094878554833674, - -37.49084726856301, - 31.314510126056227, - -21.433535249341062, - 13.098849669769185, - -5.504980293162981, - 1.3858770002872753, - -0.1867196181016621, - 0.01034853052468345 - ], - "trajectoryPolynomialY": [ - -72.10282216713524, - 166.69978721524342, - -31.238858108712254, - 11.264964805199053, - -4.806233237870712, - 1.5817631627214666, - -0.33333496968736576, - 0.039703566914027676, - -0.002030856684404277 - ], - "trajectoryPolynomialZ": [ - -21.718079188331732, - 58.05426407617164, - -20.113440517975853, - 10.610115158981998, - -7.581842515491339, - 3.122960688699821, - -0.7504642631697852, - 0.09755216809938365, - -0.005283914335952961 - ], - "validTimeInterval": [ - 0.48341292457954527, - 4.063265829852958 - ], - "measuredTimeInterval": [ - 0.48341292457954527, - 3.4770070652472453 - ] - } - }, - "isHomeRun": false, - "playId": "1bfc5d7b-2106-4b06-8e70-0e776ae85ebb", - "timeRemaining": "3:47", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 108.000001, - "launchAngle": 41.000001, - "totalDistance": 386, - "coordinates": { - "coordX": 56.93756901879006, - "coordY": 50.54517213524309, - "landingPosX": -157.91241241209238, - "landingPosY": 352.0203086570565 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 19.915803161961918, - -63.119169077402276, - 28.605163569572035, - -12.450888250791204, - 3.6563363185650277, - -0.7041858970605714, - 0.08426342013500406, - -0.005665233301506127, - 0.0001633606289764684 - ], - "trajectoryPolynomialY": [ - -42.251542289543, - 131.33769279796806, - -35.990168695616916, - 10.529272554881022, - -2.9835324798867218, - 0.7080047847122113, - -0.10884130186474762, - 0.009110677748630603, - -0.0003135589506138113 - ], - "trajectoryPolynomialZ": [ - -37.21739353355734, - 113.54770164571433, - -14.284747071921403, - -3.40221314094148, - 1.6930316490522417, - -0.4032943503369199, - 0.05259642901919969, - -0.0035496216188313947, - 0.0000969579050803057 - ], - "validTimeInterval": [ - 0.3782047406712765, - 7.012902616647778 - ], - "measuredTimeInterval": [ - 0.3782047406712765, - 3.291140964666276 - ] - } - }, - "isHomeRun": false, - "playId": "57e58a07-a7bd-404f-a999-f4d0378d1f5e", - "timeRemaining": "3:40", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 109.000001, - "launchAngle": 28.000001, - "totalDistance": 460, - "coordinates": { - "coordX": 3.1774312294387244, - "coordY": 45.00794583354539, - "landingPosX": -280.83587353718224, - "landingPosY": 364.6812699199271 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 36.81101840126961, - -87.40607599264676, - 13.613092175613067, - 2.051386750158945, - -3.123085862041744, - 1.1201187989278287, - -0.20153938464594462, - 0.018548747719822747, - -0.0006943362605052715 - ], - "trajectoryPolynomialY": [ - -60.05814327506049, - 156.21866945616242, - -52.68422471362074, - 24.150369307312708, - -9.401529631341143, - 2.440429669344176, - -0.3777853769246343, - 0.031508949173452004, - -0.0010907387943752285 - ], - "trajectoryPolynomialZ": [ - -36.67474670118904, - 95.48908071967205, - -21.429969216464336, - 6.1839275572501045, - -3.1135558899957987, - 0.9306889839661944, - -0.15879318379116808, - 0.014380899606614818, - -0.000535915718511479 - ], - "validTimeInterval": [ - 0.462729503784802, - 6.2825665399175685 - ], - "measuredTimeInterval": [ - 0.462729503784802, - 3.4597287764248192 - ] - } - }, - "isHomeRun": true, - "playId": "2c444c33-312d-4347-84ff-dfcc28821fc9", - "timeRemaining": "3:32", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 108.000001, - "launchAngle": 24.000001, - "totalDistance": 427, - "coordinates": { - "coordX": 170.6700993838187, - "coordY": 23.007052018788784, - "landingPosX": 102.13893510794496, - "landingPosY": 414.9866844289492 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 1.6133522241794302, - -9.923144982133365, - 16.0060621318061, - -3.4707404924169416, - 0.1040047569689039, - 0.09893432207097931, - -0.01681121862668346, - 0.0007237390267797789, - 0.00001759109699769518 - ], - "trajectoryPolynomialY": [ - -71.08568241746529, - 168.63259021348915, - -27.508701869348553, - 1.6410182252459942, - 1.4480957892686084, - -0.6346922827753753, - 0.12829566625866887, - -0.013373751441837846, - 0.0005742229682095629 - ], - "trajectoryPolynomialZ": [ - -30.2703993367465, - 78.76702274298165, - -20.200830731134534, - 5.593902316576526, - -3.128283430001512, - 1.0873295126468225, - -0.21533501141429548, - 0.022505087565565053, - -0.0009638802634657251 - ], - "validTimeInterval": [ - 0.4692779353693911, - 5.339882793767803 - ], - "measuredTimeInterval": [ - 0.4692779353693911, - 3.4551229225039353 - ] - } - }, - "isHomeRun": true, - "playId": "4bb9141f-8a7b-48d9-9581-677143300243", - "timeRemaining": "3:25", - "isBonusTime": true, - "isTieBreaker": false - } - ], - "seed": 8, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 17 - } - }, - { - "topSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450" - }, - "topDerbyHitData": { - "launchSpeed": 119.000001, - "totalDistance": 501, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 116.000001, - "launchAngle": 24.000001, - "totalDistance": 432, - "coordinates": { - "coordX": 152.23431192095995, - "coordY": 17.462108974907352, - "landingPosX": 59.985196358599474, - "landingPosY": 427.66529015288035 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 11.666719589595703, - -41.7910733270962, - 48.358572718678055, - -29.103145377994732, - 13.058353753397284, - -3.8797053765046394, - 0.6944605549191295, - -0.06729114339108329, - 0.0027080929729614935 - ], - "trajectoryPolynomialY": [ - -74.6131683172858, - 172.3620587808619, - -13.989495035859655, - -12.978193162208749, - 10.490492195976332, - -3.9051537559143914, - 0.8097473417622155, - -0.08929191008616807, - 0.004080715536188254 - ], - "trajectoryPolynomialZ": [ - -33.125121824857416, - 87.97028797099065, - -21.338316765821652, - -0.4605431055713959, - 1.649972819529468, - -0.7046383230201017, - 0.1471887415108612, - -0.015556715874453012, - 0.0006684593025411387 - ], - "validTimeInterval": [ - 0.4629489192172733, - 4.839530340115688 - ], - "measuredTimeInterval": [ - 0.4629489192172733, - 3.458821731735707 - ] - } - }, - "isHomeRun": true, - "playId": "60b3223d-cfda-4560-b392-b8265870ce94", - "timeRemaining": "3:51", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 111.000001, - "launchAngle": 34.000001, - "totalDistance": 421, - "coordinates": { - "coordX": 202.1633443543779, - "coordY": 36.96874713020469, - "landingPosX": 174.1487705181562, - "landingPosY": 383.0630332472286 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -6.437009736252265, - 13.785214225341754, - 0.9593226532014192, - 3.4589905768537115, - -1.6936509484109121, - 0.3776596639408269, - -0.045292302668318296, - 0.0028430861022843536, - -0.0000732579862301883 - ], - "trajectoryPolynomialY": [ - -66.67279001126805, - 165.23501136659493, - -39.56587763703457, - 8.372479143455651, - -0.9534079397776531, - -0.05016899458112834, - 0.033301980068176966, - -0.004222952324420904, - 0.00018618766512724818 - ], - "trajectoryPolynomialZ": [ - -41.88120363123631, - 107.67598109490727, - -20.731693549878667, - 1.7374697871595632, - -0.6592160045870228, - 0.23537202873807556, - -0.04781398370269039, - 0.004998615991160244, - -0.00020804897857718287 - ], - "validTimeInterval": [ - 0.45660916261481743, - 6.427680329606956 - ], - "measuredTimeInterval": [ - 0.45660916261481743, - 3.4549267507598485 - ] - } - }, - "isHomeRun": true, - "playId": "03dca4fd-1ad2-45d0-86f9-aa3033d5d4bd", - "timeRemaining": "3:44", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 110.000001, - "launchAngle": 35.000001, - "totalDistance": 440, - "coordinates": { - "coordX": 47.1346598089731, - "coordY": 29.141419255404287, - "landingPosX": -180.32692953790982, - "landingPosY": 400.960350354216 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 26.091785209967494, - -73.67140933790292, - 42.311943669428224, - -29.59203079169257, - 12.53092651909764, - -3.1107998741345484, - 0.4483640774188864, - -0.0348166246689891, - 0.0011271670992178192 - ], - "trajectoryPolynomialY": [ - -55.17798594364114, - 137.3980289573027, - -17.97705016805673, - -6.623587324095905, - 5.85562635885081, - -1.8496722448928549, - 0.3056981485182808, - -0.026157224634322483, - 0.0009145937090574275 - ], - "trajectoryPolynomialZ": [ - -40.72738357579742, - 105.56382100867425, - -12.682497597210547, - -4.5458769288088785, - 2.179620808229748, - -0.5265862303769482, - 0.07172210354627225, - -0.005167277730695544, - 0.00015308345699558182 - ], - "validTimeInterval": [ - 0.44467454653677113, - 6.5772667096226565 - ], - "measuredTimeInterval": [ - 0.44467454653677113, - 3.4389224781742422 - ] - } - }, - "isHomeRun": true, - "playId": "51daf290-1fc7-43c3-8581-52e2bdf751e3", - "timeRemaining": "3:37", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 97.000001, - "launchAngle": 45.000001, - "totalDistance": 308, - "coordinates": { - "coordX": 218.05494004481167, - "coordY": 106.03442254935189, - "landingPosX": 210.48517190021545, - "landingPosY": 225.14320237311114 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -12.686948515360747, - 24.156711214291974, - 10.903001765769803, - -3.0724074533341805, - -0.3888356763138595, - 0.44589921740715344, - -0.1116595564562452, - 0.012431031642490147, - -0.000531273675374895 - ], - "trajectoryPolynomialY": [ - -47.8136000390016, - 121.17681612757613, - -33.44109119134633, - 6.3009227609716225, - 0.12451267481227246, - -0.45673485166931643, - 0.12095327377423312, - -0.013908940891734231, - 0.0006107605180383515 - ], - "trajectoryPolynomialZ": [ - -46.41767394327658, - 119.12787317785329, - -19.51127701139883, - -5.068901809880354, - 3.259822226040015, - -0.8512678444382307, - 0.11351972157432706, - -0.00725903824030832, - 0.00016369571235410715 - ], - "validTimeInterval": [ - 0.4543121912046953, - 6.216240291790588 - ], - "measuredTimeInterval": [ - 0.4543121912046953, - 3.4478668905937604 - ] - } - }, - "isHomeRun": false, - "playId": "0b268062-4c0c-468e-aa96-2dde270036b2", - "timeRemaining": "3:30", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 88.000001, - "launchAngle": 41.000001, - "totalDistance": 288, - "coordinates": { - "coordX": 239.57047959151865, - "coordY": 150.186113414085, - "landingPosX": 259.680815695214, - "landingPosY": 124.18961708127755 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -28.30709101734004, - 64.0407676426009, - -4.0810265729195505, - 9.218728425454083, - -8.041779619903997, - 3.244559938684504, - -0.6904411312298475, - 0.0754756031885284, - -0.003350117146177953 - ], - "trajectoryPolynomialY": [ - -33.773357995895466, - 75.71867438950726, - 13.158754785235576, - -37.36818470064655, - 24.563357225321766, - -8.618688989726811, - 1.714101582001203, - -0.18161786158852716, - 0.007958125685852458 - ], - "trajectoryPolynomialZ": [ - -42.28678534430751, - 115.27111515717725, - -44.52500487513918, - 21.931875143147607, - -11.855797837019626, - 3.90030244457828, - -0.7399232601832968, - 0.07492273758510339, - -0.003140240237894658 - ], - "validTimeInterval": [ - 0.4534699598430477, - 5.095041615116463 - ], - "measuredTimeInterval": [ - 0.4534699598430477, - 3.457074493262007 - ] - } - }, - "isHomeRun": false, - "playId": "4afee44c-2173-4381-ad27-be096f370bcb", - "timeRemaining": "3:22", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 2, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 23 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 571506, - "fullName": "Justin Bour", - "link": "/api/v1/people/571506" - }, - "topDerbyHitData": { - "launchSpeed": 113.000001, - "totalDistance": 464, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 14.000001, - "totalDistance": 267, - "coordinates": { - "coordX": 186.10493232753385, - "coordY": 104.44852932417032, - "landingPosX": 137.43094077138355, - "landingPosY": 228.76937396102628 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -31.23035290106623, - 50.99406884526712, - 23.35491957681605, - -29.278282790312918, - 26.06614568320225, - -15.018133411493485, - 5.181729689711075, - -0.9899707833741286, - 0.08106834366250408 - ], - "trajectoryPolynomialY": [ - -76.55126229043516, - 175.3898567042789, - -67.09472859911139, - 67.79732372846777, - -59.29031644226867, - 31.389596133258266, - -9.552377920611114, - 1.5459051177383853, - -0.10304989068282713 - ], - "trajectoryPolynomialZ": [ - -23.730954728052666, - 66.43599388544577, - -37.012031288438386, - 18.128840513810644, - -12.558148666679381, - 6.369812531220422, - -2.004024466995714, - 0.34310452761008686, - -0.02419095511579621 - ], - "validTimeInterval": [ - 0.5272339287578544, - 2.808716472703157 - ], - "measuredTimeInterval": [ - 0.5272339287578544, - 2.7869821910115675 - ] - } - }, - "isHomeRun": false, - "playId": "8595b82a-7857-4fb4-8539-42ff2a554ddb", - "timeRemaining": "3:48", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 103.000001, - "launchAngle": 28.000001, - "totalDistance": 405, - "coordinates": { - "coordX": 208.1449890862914, - "coordY": 47.37250362941657, - "landingPosX": 187.82590201191346, - "landingPosY": 359.27466866757 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -35.69359631863675, - 81.47170358972899, - -30.649741198922403, - 12.897839343343184, - -3.172873133356951, - 0.33976744537420134, - 0.011506177318740327, - -0.0057466883565445255, - 0.0003580160850880116 - ], - "trajectoryPolynomialY": [ - -63.70450884400308, - 147.21822148136735, - -35.7851503103105, - 12.547926996821445, - -4.666091962902631, - 1.317721577168986, - -0.22878625936288963, - 0.021411575880373037, - -0.0008270643322902749 - ], - "trajectoryPolynomialZ": [ - -37.54043662491953, - 85.82157958100018, - -12.09271227860325, - -6.5130708910672706, - 5.269297729654644, - -1.9597127409357482, - 0.3819314244620591, - -0.037934654793021966, - 0.0015222795090048253 - ], - "validTimeInterval": [ - 0.5144426533324121, - 5.741727199230815 - ], - "measuredTimeInterval": [ - 0.5144426533324121, - 3.508160513967526 - ] - } - }, - "isHomeRun": true, - "playId": "bd8ce204-45ab-4fc9-9889-91349755a837", - "timeRemaining": "3:42", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 103.000001, - "launchAngle": 32.000001, - "totalDistance": 401, - "coordinates": { - "coordX": 194.3807787443953, - "coordY": 42.99543031509171, - "landingPosX": 156.35380308409486, - "landingPosY": 369.2829205716723 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -31.11341437123758, - 80.1535213860467, - -38.43540169253998, - 21.84871885203033, - -8.77534724242268, - 2.183008920652544, - -0.3202336424078933, - 0.02541380709633881, - -0.0008416614752553332 - ], - "trajectoryPolynomialY": [ - -58.918929717117095, - 140.54867300150858, - -26.6867930599358, - 0.5409972763436257, - 2.2228978380588518, - -0.7995729770689544, - 0.13525338678228083, - -0.011622378605211769, - 0.0004073949765718861 - ], - "trajectoryPolynomialZ": [ - -40.74128844864424, - 97.81799693013534, - -21.14889665737596, - 5.155614879921873, - -2.1093100578336115, - 0.523612204173907, - -0.07735142963613062, - 0.006359068045264049, - -0.0002223971519483935 - ], - "validTimeInterval": [ - 0.49069404652818294, - 6.5371521764109435 - ], - "measuredTimeInterval": [ - 0.49069404652818294, - 3.4866788977917995 - ] - } - }, - "isHomeRun": true, - "playId": "e9d6f1e3-b623-44e5-9307-df1dc64f410b", - "timeRemaining": "3:35", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 107.000001, - "launchAngle": 29.000001, - "totalDistance": 433, - "coordinates": { - "coordX": 231.20788835542209, - "coordY": 47.194387679581894, - "landingPosX": 240.5596098913303, - "landingPosY": 359.6819337888212 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -36.01595145784577, - 77.05556573228971, - -16.473435257158414, - 9.527466823633508, - -4.231519036537629, - 1.0709546790006612, - -0.15210984932351893, - 0.01138851332139564, - -0.0003509901568323753 - ], - "trajectoryPolynomialY": [ - -62.594114382536915, - 142.00470797204326, - -19.99111394260506, - -4.434806213691169, - 3.9636110493630303, - -1.1279034770973149, - 0.16724258940356654, - -0.012917233728691267, - 0.0004101719681518532 - ], - "trajectoryPolynomialZ": [ - -41.24007884183484, - 99.87866212600721, - -28.316133891727322, - 8.111770858293568, - -2.3973394103582826, - 0.378295947495194, - -0.026930603749520006, - 0.0002180879565900203, - 0.0000470429613898708 - ], - "validTimeInterval": [ - 0.5086920309443367, - 6.139364028014606 - ], - "measuredTimeInterval": [ - 0.5086920309443367, - 3.5022326031406443 - ] - } - }, - "isHomeRun": true, - "playId": "66889ca5-3a97-4fbb-b0f7-5414e4b9a98f", - "timeRemaining": "3:19", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 100.000001, - "launchAngle": 40.000001, - "totalDistance": 357, - "coordinates": { - "coordX": 209.2265973702912, - "coordY": 72.15264607622888, - "landingPosX": 190.29901758263205, - "landingPosY": 302.61445532008344 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -30.68732986339886, - 73.72111192740626, - -29.194453833526804, - 14.74641516833107, - -5.500483829633695, - 1.3153646775904297, - -0.18792380204001752, - 0.014601865699121223, - -0.000474466962923361 - ], - "trajectoryPolynomialY": [ - -52.2733777426132, - 131.39207403947782, - -39.56204664342587, - 11.835386182359988, - -2.961155897172239, - 0.570648408524814, - -0.07338071692501669, - 0.005420299586330446, - -0.00017205407551289608 - ], - "trajectoryPolynomialZ": [ - -45.42050856102751, - 105.93325790684773, - -9.66046944371198, - -6.562285430515487, - 3.157916946732596, - -0.8045026979207762, - 0.11503679425893694, - -0.008628025222542366, - 0.00026470286778908946 - ], - "validTimeInterval": [ - 0.4892412635245745, - 6.837277762547954 - ], - "measuredTimeInterval": [ - 0.4892412635245745, - 3.484939742739366 - ] - } - }, - "isHomeRun": false, - "playId": "62dbe2d2-2925-4e6f-bfe6-e839a77c0595", - "timeRemaining": "3:12", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 7, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 22 - } - }, - { - "topSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355" - }, - "topDerbyHitData": { - "launchSpeed": 107.000001, - "totalDistance": 446, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 101.000001, - "launchAngle": 25.000001, - "totalDistance": 393, - "coordinates": { - "coordX": 200.90661953539495, - "coordY": 49.835146119285895, - "landingPosX": 171.27524803879635, - "landingPosY": 353.64379510927324 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -26.579599215084748, - 55.804824648764814, - -14.490598663429482, - 11.20034915227204, - -5.095857843653617, - 1.3471487530483164, - -0.21839552870189136, - 0.020585371989835607, - -0.0008661230177144835 - ], - "trajectoryPolynomialY": [ - -69.73925715956119, - 142.98592780330162, - -13.885283828399086, - -9.005927481296641, - 7.898280594664914, - -3.0560010553923735, - 0.6621765097640518, - -0.07646137134051677, - 0.0036475151392283307 - ], - "trajectoryPolynomialZ": [ - -34.66224899817344, - 77.76838285777907, - -16.07150067382376, - -0.18048921180303681, - -0.1476112928849612, - 0.30623723643890544, - -0.1099959894855787, - 0.016187165992406865, - -0.0008781911040318562 - ], - "validTimeInterval": [ - 0.5359713197318186, - 4.952248785552106 - ], - "measuredTimeInterval": [ - 0.5359713197318186, - 3.542482311806344 - ] - } - }, - "isHomeRun": true, - "playId": "b39d1888-60f8-4153-8eca-c3057050beb4", - "timeRemaining": "3:51", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 91.000001, - "launchAngle": 33.000001, - "totalDistance": 347, - "coordinates": { - "coordX": 229.03603171082676, - "coordY": 92.87441727227215, - "landingPosX": 235.59362306913755, - "landingPosY": 255.23377623699568 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -31.07606079762967, - 58.710127324631316, - 13.236442682148663, - -14.978007013486316, - 7.6166852453942955, - -2.288987415658921, - 0.4009351552285837, - -0.03774032450457298, - 0.001476252880168941 - ], - "trajectoryPolynomialY": [ - -51.90908013643929, - 123.98693409753247, - -46.9844646329148, - 27.56781159565868, - -13.669429755736424, - 4.367488064796727, - -0.8161555989218521, - 0.0813005082347954, - -0.0033382869647823566 - ], - "trajectoryPolynomialZ": [ - -42.31943718042757, - 100.98006597307436, - -33.948147666942404, - 10.972249422966796, - -3.531868313787294, - 0.6539871222571757, - -0.06454275605821126, - 0.0027484906181256645, - -0.0000099662509988667 - ], - "validTimeInterval": [ - 0.5171462446299829, - 5.415612431153393 - ], - "measuredTimeInterval": [ - 0.5171462446299829, - 3.514134884028505 - ] - } - }, - "isHomeRun": true, - "playId": "a88eaa69-d284-4b79-9bdb-e58b69ed7740", - "timeRemaining": "3:44", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 31.000001, - "totalDistance": 441, - "coordinates": { - "coordX": 244.01843258990493, - "coordY": 51.93101269935917, - "landingPosX": 269.85113519152424, - "landingPosY": 348.8515608503417 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -37.263976002667825, - 77.73020476854634, - -15.673013045204488, - 8.437842484011968, - -3.3958268443293336, - 0.8052354038967259, - -0.10917485277807198, - 0.007888299210184264, - -0.00023625991461409757 - ], - "trajectoryPolynomialY": [ - -66.08096518926104, - 141.90653592966112, - -26.280639372255465, - 0.8639004071592885, - 1.6282495372483052, - -0.5469460455597928, - 0.08782127277844042, - -0.0074524346238281245, - 0.00026776239269868434 - ], - "trajectoryPolynomialZ": [ - -44.84514816483656, - 102.56576018265066, - -29.194336680028844, - 12.380074010123124, - -6.230312066229839, - 1.8408221579740118, - -0.31095328890870144, - 0.027945071799641525, - -0.0010365154580103824 - ], - "validTimeInterval": [ - 0.5322035910307238, - 6.107865822475993 - ], - "measuredTimeInterval": [ - 0.5322035910307238, - 3.5291948954269596 - ] - } - }, - "isHomeRun": true, - "playId": "f453cf1e-01a8-47fd-a761-7c5d510df5bd", - "timeRemaining": "3:32", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 107.000001, - "launchAngle": 22.000001, - "totalDistance": 320, - "coordinates": { - "coordX": 245.30133481596658, - "coordY": 131.14657200722252, - "landingPosX": 272.78451275336175, - "landingPosY": 167.72384939921596 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -53.215051217915516, - 104.58498545148383, - 1.2253765099486953, - -5.890543484570903, - 3.7299975125118077, - -1.1671958907193416, - 0.12686263463750758, - 0.013878573689619552, - -0.003039649503679142 - ], - "trajectoryPolynomialY": [ - -57.704085767843175, - 135.8199674474336, - -52.6576019560711, - 37.38215596970105, - -26.32145784777265, - 12.13542296116971, - -3.3518842348124376, - 0.5056055047222483, - -0.03205816855832465 - ], - "trajectoryPolynomialZ": [ - -35.40070783399069, - 87.99333279622972, - -28.396549431431406, - -3.084117879255543, - 6.0551229776345386, - -3.337787633399517, - 1.0039791459171188, - -0.1613351268783602, - 0.010769198345137197 - ], - "validTimeInterval": [ - 0.5222630202129205, - 3.4606706129863465 - ], - "measuredTimeInterval": [ - 0.5222630202129205, - 2.8764594894990765 - ] - } - }, - "isHomeRun": false, - "playId": "4bac67d7-1605-47f7-89e4-a7efd4ba2596", - "timeRemaining": "3:25", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 14.000001, - "totalDistance": 224, - "coordinates": { - "coordX": 186.65825675813358, - "coordY": 127.51745760663445, - "landingPosX": 138.6961264076425, - "landingPosY": 176.02188064101 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -38.49511246877996, - 70.16107667811086, - 12.445319166281477, - -10.407453562418649, - 7.456917974368746, - -4.511583731872339, - 1.7003052177838296, - -0.34712641942193506, - 0.029479944988539387 - ], - "trajectoryPolynomialY": [ - -72.05540188287905, - 158.5517529382944, - -41.73783545558252, - 27.072656692129694, - -23.61308950252806, - 14.60700236901937, - -5.498375633059084, - 1.1243698349900366, - -0.09595473237709627 - ], - "trajectoryPolynomialZ": [ - -24.660971297554422, - 71.01936825320178, - -36.00137331147121, - 7.585824067041697, - -3.021659080189109, - 1.5806906201702438, - -0.6571162153614677, - 0.15165517990615385, - -0.014302022963821727 - ], - "validTimeInterval": [ - 0.5226203977522114, - 2.3241816770490806 - ], - "measuredTimeInterval": [ - 0.5226203977522114, - 2.341359043008405 - ] - } - }, - "isHomeRun": false, - "playId": "0f3b52e9-a884-4e18-b949-a51bf1c60314", - "timeRemaining": "3:13", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 3, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 15 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 453568, - "fullName": "Charlie Blackmon", - "link": "/api/v1/people/453568" - }, - "topDerbyHitData": { - "launchSpeed": 109.000001, - "totalDistance": 434, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 102.000001, - "launchAngle": 25.000001, - "totalDistance": 385, - "coordinates": { - "coordX": 207.40417666448155, - "coordY": 57.346671924531165, - "landingPosX": 186.13202192384261, - "landingPosY": 336.4685647568304 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -20.09258833392705, - 45.0716275642169, - 2.734268776261993, - -0.5598739707927305, - 0.22207890554230705, - -0.1050985658994884, - 0.0003034182912983427, - 0.005458516155649751, - -0.0006158327251677256 - ], - "trajectoryPolynomialY": [ - -57.14855066667697, - 144.70894693760857, - -23.076043997512468, - 1.3368662428762343, - 2.6610714739279624, - -1.6761222397289415, - 0.4812829244984773, - -0.06829852587973946, - 0.0038467935893331806 - ], - "trajectoryPolynomialZ": [ - -30.39294170584981, - 87.07626359206391, - -29.15770771394138, - 9.651017496426512, - -5.1952443270233, - 1.694565977834303, - -0.2963979781917054, - 0.025139923209351694, - -0.0007531666021533598 - ], - "validTimeInterval": [ - 0.4415779340473463, - 4.4736073529926355 - ], - "measuredTimeInterval": [ - 0.4415779340473463, - 3.4352146265964265 - ] - } - }, - "isHomeRun": true, - "playId": "01f94263-cf4d-4c41-92eb-c6591cf01b70", - "timeRemaining": "3:49", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 101.000001, - "launchAngle": 34.000001, - "totalDistance": 411, - "coordinates": { - "coordX": 184.94535000098531, - "coordY": 34.785765821493754, - "landingPosX": 134.77953623820798, - "landingPosY": 388.05445680141594 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -12.974042279603063, - 29.560208759035312, - -0.7499011069588813, - 2.037695916166788, - -2.055503891976323, - 0.7944159800451738, - -0.15269581249832773, - 0.014710990920982351, - -0.000568161636002049 - ], - "trajectoryPolynomialY": [ - -53.60205450084968, - 135.7112737343806, - -18.721906946303168, - -3.1873043563048538, - 3.589727331603172, - -1.1606571158282575, - 0.19482357783363394, - -0.01701353863692126, - 0.0006108488777741818 - ], - "trajectoryPolynomialZ": [ - -37.457921403759826, - 103.12092309302182, - -27.44135271916074, - 8.119298256213499, - -3.2796196717324437, - 0.844131486455707, - -0.13006070054287108, - 0.011001264675775302, - -0.00039200701322375015 - ], - "validTimeInterval": [ - 0.43809388213984446, - 6.203399668272613 - ], - "measuredTimeInterval": [ - 0.43809388213984446, - 3.43338287814944 - ] - } - }, - "isHomeRun": true, - "playId": "250cf6ad-8b63-494b-af5b-75e5dcc9820f", - "timeRemaining": "3:35", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 103.000001, - "launchAngle": 27.000001, - "totalDistance": 406, - "coordinates": { - "coordX": 156.37720966638165, - "coordY": 29.60607390982338, - "landingPosX": 69.45800187762543, - "landingPosY": 399.89790965562855 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -11.766319200699806, - 27.56182225559978, - 0.47884769624598744, - -5.596369216623072, - 3.3688005303832287, - -0.9918697548036913, - 0.1574935209936433, - -0.012724478323509236, - 0.0004015193540906218 - ], - "trajectoryPolynomialY": [ - -60.784759915137684, - 156.08448307453446, - -30.6454460132598, - 7.100676035262571, - -0.8317493241849683, - -0.14537254408613104, - 0.07234058755715471, - -0.010510388636588089, - 0.000548044347307581 - ], - "trajectoryPolynomialZ": [ - -29.508787181317814, - 83.79002084076465, - -20.389327980832284, - 5.7462103243772695, - -3.8750200325037105, - 1.4473857175923257, - -0.29309306619722136, - 0.03077871118276801, - -0.0013182722607114306 - ], - "validTimeInterval": [ - 0.43729390107160515, - 5.158450517282521 - ], - "measuredTimeInterval": [ - 0.43729390107160515, - 3.433935412057264 - ] - } - }, - "isHomeRun": false, - "playId": "dac8eed1-039d-49e0-999f-c6cb0532acc3", - "timeRemaining": "3:26", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 107.000001, - "launchAngle": 28.000001, - "totalDistance": 392, - "coordinates": { - "coordX": 254, - "coordY": 94.73929268754718, - "landingPosX": 300.65014042761356, - "landingPosY": 250.96970716948482 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -33.22047914296476, - 75.12926254530787, - 6.456842190276966, - -3.600351903205897, - -0.4480893417339568, - 0.9474936400281875, - -0.34442497017938334, - 0.05391301077767671, - -0.0031860521621225567 - ], - "trajectoryPolynomialY": [ - -49.251773536165366, - 125.24707935590347, - -1.5002333853222658, - -33.332775607875476, - 27.078727870147226, - -11.242704229255358, - 2.6175555113948796, - -0.3217458745839063, - 0.016223805420503796 - ], - "trajectoryPolynomialZ": [ - -33.68003616146317, - 97.5379305947529, - -31.709750543280474, - 10.665210513486068, - -5.816814072348198, - 1.9916927657545527, - -0.3879246749255409, - 0.03979128433119829, - -0.0016715583579501037 - ], - "validTimeInterval": [ - 0.4310430340739074, - 4.658249454972322 - ], - "measuredTimeInterval": [ - 0.4310430340739074, - 3.4442551697690686 - ] - } - }, - "isHomeRun": false, - "playId": "06736afd-ad61-4b63-8ad5-527795726b8e", - "timeRemaining": "3:17", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 104.000001, - "launchAngle": 35.000001, - "totalDistance": 427, - "coordinates": { - "coordX": 235.37139987905886, - "coordY": 53.25777150345223, - "landingPosX": 250.0795491616683, - "landingPosY": 345.81790448367946 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -22.385633885708355, - 52.43271371665016, - -2.020297472413774, - 3.2559801885719666, - -2.319533877110467, - 0.7446158621217059, - -0.1265285894782041, - 0.011142843454764476, - -0.0004012691489904721 - ], - "trajectoryPolynomialY": [ - -50.696857986975715, - 129.90587534008637, - -17.11226489245102, - -4.601168591193699, - 4.115577173657373, - -1.2408113272350774, - 0.19522699371954721, - -0.01597648324453924, - 0.0005383870774914361 - ], - "trajectoryPolynomialZ": [ - -40.66239056382674, - 112.16339527924049, - -32.711979366901026, - 9.32529412074285, - -2.9908875889517197, - 0.5769616039685144, - -0.06288708490547469, - 0.0034760192473285013, - -0.00006891150970503498 - ], - "validTimeInterval": [ - 0.4380486357040005, - 6.034079519493022 - ], - "measuredTimeInterval": [ - 0.4380486357040005, - 3.433791886585291 - ] - } - }, - "isHomeRun": true, - "playId": "21f1980c-38ac-426e-87f5-3c29b86909ed", - "timeRemaining": "3:08", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 95.000001, - "launchAngle": 35.000001, - "totalDistance": 380, - "coordinates": { - "coordX": 150.58910677025906, - "coordY": 40.30828221691212, - "landingPosX": 56.22340705334517, - "landingPosY": 375.42712998717286 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -10.769992524037647, - 25.530444538407586, - 3.736437833041462, - -8.239551279550529, - 4.317222091710564, - -1.2095471912045102, - 0.1924811994660623, - -0.016372776525334542, - 0.0005788642169509761 - ], - "trajectoryPolynomialY": [ - -49.655974540089474, - 128.85652057903522, - -21.86141850601539, - 2.4255422893712875, - 0.4391660647134536, - -0.21650911773381923, - 0.03602763988944109, - -0.0028878698323616964, - 0.00009320204235900607 - ], - "trajectoryPolynomialZ": [ - -34.69364778177862, - 95.93726058257033, - -21.134995761828957, - 3.593283125552127, - -1.2329677929122027, - 0.27347347818613327, - -0.03660665914963555, - 0.0027850467095116315, - -0.00009285087740814056 - ], - "validTimeInterval": [ - 0.43286712486264284, - 6.00826690513604 - ], - "measuredTimeInterval": [ - 0.43286712486264284, - 3.425972778749777 - ] - } - }, - "isHomeRun": false, - "playId": "18fbe610-ed18-4bf6-87f6-7b84b4b6023f", - "timeRemaining": "3:00", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 6, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 14 - } - }, - { - "topSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 519058, - "fullName": "Mike Moustakas", - "link": "/api/v1/people/519058" - }, - "topDerbyHitData": { - "launchSpeed": 114.000001, - "totalDistance": 442, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 93.000001, - "launchAngle": 34.000001, - "totalDistance": 371, - "coordinates": { - "coordX": 236.27924865253675, - "coordY": 85.20253641780303, - "landingPosX": 252.15536068304752, - "landingPosY": 272.77566111210206 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -34.66422641603215, - 76.1800778643161, - -16.447233214816087, - 9.339285775599501, - -4.005576631564804, - 1.0231010866896426, - -0.15089624722097242, - 0.011994035220394847, - -0.0004001007685951225 - ], - "trajectoryPolynomialY": [ - -45.63697631395248, - 103.57547711234518, - -2.6776353035797285, - -15.420317374454466, - 9.059611525650796, - -2.622817774532146, - 0.4296402187686882, - -0.03794297897382419, - 0.0014046698191999389 - ], - "trajectoryPolynomialZ": [ - -40.96231022110542, - 105.48585666255184, - -42.153796618369654, - 23.897490871858608, - -11.852742900120534, - 3.4404450436542535, - -0.5764993324652243, - 0.051884253556380176, - -0.001943733743007319 - ], - "validTimeInterval": [ - 0.49022772061043784, - 5.861607725493213 - ], - "measuredTimeInterval": [ - 0.49022772061043784, - 3.482705256168998 - ] - } - }, - "isHomeRun": true, - "playId": "0588db57-7b85-4e03-84bd-114f6fb7a18f", - "timeRemaining": "3:55", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 84.000001, - "launchAngle": 57.000001, - "totalDistance": 196, - "coordinates": { - "coordX": 99.77259252210048, - "coordY": 122.90037363317398, - "landingPosX": -59.969409233174744, - "landingPosY": 186.57892096234937 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -0.5596477021534753, - 3.620539154497677, - -7.883434652787471, - 1.109332553270047, - 1.400770514239467, - -0.9062422982907359, - 0.22586314489718312, - -0.025928432453453852, - 0.0011408179717921653 - ], - "trajectoryPolynomialY": [ - -37.59427001194602, - 93.22568172108535, - -33.521216093195946, - 14.160147005906172, - -5.175262049192635, - 1.3294900203622255, - -0.20559922660712385, - 0.016849948961809424, - -0.0005623232726033056 - ], - "trajectoryPolynomialZ": [ - -53.69726705898439, - 124.52188086659, - -21.574920313111345, - -2.913021783377937, - 2.528979705516365, - -0.7618567126654989, - 0.11409041538345442, - -0.008439019394053506, - 0.00024458286546404735 - ], - "validTimeInterval": [ - 0.4973632298846754, - 6.139553781642444 - ], - "measuredTimeInterval": [ - 0.4973632298846754, - 3.4182863338057303 - ] - } - }, - "isHomeRun": false, - "playId": "4b8c0864-a8e8-4006-9a4b-20c835fcd926", - "timeRemaining": "3:48", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 86.000001, - "launchAngle": 55.000001, - "totalDistance": 193, - "coordinates": { - "coordX": 131.434698289419, - "coordY": 120.30868230517883, - "landingPosX": 12.426529234795144, - "landingPosY": 192.5048668640012 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -5.385900236100319, - 8.774382514265763, - 5.095911747745187, - -7.497900989575934, - 3.58346231141905, - -0.9039041329187226, - 0.1290675825990657, - -0.009885415460852741, - 0.0003162884566954511 - ], - "trajectoryPolynomialY": [ - -38.85431499565069, - 101.79192110208079, - -43.75315941476822, - 22.398768791910808, - -9.559087180844024, - 2.746297664918818, - -0.4676786306595311, - 0.042298576685728145, - -0.0015677867819416532 - ], - "trajectoryPolynomialZ": [ - -49.98730262067688, - 114.25693379735674, - -2.516667733264242, - -20.533462565274966, - 11.474451166487924, - -3.350465030543145, - 0.5417506989856162, - -0.04604470628212461, - 0.001611249692792185 - ], - "validTimeInterval": [ - 0.4882744884163292, - 6.230109815564722 - ], - "measuredTimeInterval": [ - 0.4882744884163292, - 3.1553965360612026 - ] - } - }, - "isHomeRun": false, - "playId": "2174ce51-2c4b-486c-8d8d-a364834338b7", - "timeRemaining": "3:36", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 102.000001, - "launchAngle": 41.000001, - "totalDistance": 356, - "coordinates": { - "coordX": 196.0377408510617, - "coordY": 65.31755813109254, - "landingPosX": 160.14247486731526, - "landingPosY": 318.24299910474906 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -30.890832095892662, - 73.09528724256187, - -30.16582833305708, - 16.58274993031512, - -6.357118742936324, - 1.4769423642269255, - -0.20085303436481206, - 0.01476597185322518, - -0.00045381748885773524 - ], - "trajectoryPolynomialY": [ - -55.23868437971997, - 138.04561443256125, - -51.35381528237902, - 22.017659910388975, - -7.828024629184009, - 1.9420776061084308, - -0.29599041515132113, - 0.024622401959679113, - -0.0008527686485277423 - ], - "trajectoryPolynomialZ": [ - -47.75404011162212, - 110.48820106536957, - -14.869267224183936, - -4.047590432831183, - 2.6240753459123574, - -0.7941265850478363, - 0.12904016758775622, - -0.010749754997509724, - 0.000361803697916375 - ], - "validTimeInterval": [ - 0.496325370696401, - 6.707597953704158 - ], - "measuredTimeInterval": [ - 0.496325370696401, - 3.474710300492077 - ] - } - }, - "isHomeRun": false, - "playId": "d8f97062-0a22-4526-95bc-38b91a47737b", - "timeRemaining": "3:28", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 16.000001, - "totalDistance": 361, - "coordinates": { - "coordX": 102.60916525685693, - "coordY": 48.253093340111775, - "landingPosX": -53.48353786774849, - "landingPosY": 357.26118545266576 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 0.9401881171495963, - -2.179780992239855, - -1.2082247728025135, - -7.628411336512196, - 7.471174852846773, - -3.458583339667764, - 0.8642626288371651, - -0.11252127213235223, - 0.006011471392666945 - ], - "trajectoryPolynomialY": [ - -76.48518347022264, - 171.0271048045091, - -26.860456623714324, - 1.2646956483722882, - 3.4459226729290804, - -2.0668010793560714, - 0.5714990946553604, - -0.07897574815715078, - 0.0043806569537130175 - ], - "trajectoryPolynomialZ": [ - -21.948858601551606, - 55.8792050457388, - -8.803531915626522, - -6.932562633342842, - 5.4612826479449295, - -2.266834374024247, - 0.5101726754506377, - -0.05857824969410412, - 0.002676747020049578 - ], - "validTimeInterval": [ - 0.49259109406247475, - 3.9822877493358875 - ], - "measuredTimeInterval": [ - 0.49259109406247475, - 3.4927096893112326 - ] - } - }, - "isHomeRun": false, - "playId": "8d2424ea-f816-4168-8d04-29e6374306b6", - "timeRemaining": "3:17", - "isBonusTime": true, - "isTieBreaker": false - } - ], - "seed": 4, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 10 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934" - }, - "topDerbyHitData": { - "launchSpeed": 112.000001, - "totalDistance": 470, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 110.000001, - "launchAngle": 17.000001, - "totalDistance": 378, - "coordinates": { - "coordX": 83.25111595400686, - "coordY": 44.952072310285075, - "landingPosX": -97.74604385797306, - "landingPosY": 364.80902567255043 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 29.980714830946457, - -60.96103373977202, - 20.58549096633612, - -5.478407723425202, - -0.25871090086089504, - 0.8351167347571943, - -0.3027596295835288, - 0.04786521754859341, - -0.0028866147718369563 - ], - "trajectoryPolynomialY": [ - -97.01267463356734, - 190.55160122679814, - -47.594006825118285, - 18.090251520672307, - -6.253374410085835, - 1.5344156828950053, - -0.24095816587022997, - 0.02173763420404064, - -0.0008596973820318606 - ], - "trajectoryPolynomialZ": [ - -29.87046506827852, - 57.55281009886572, - 0.4602797422028197, - -17.074321086608098, - 12.851323998950852, - -5.662131522844612, - 1.4114795497050159, - -0.1842224074587854, - 0.009805327456035543 - ], - "validTimeInterval": [ - 0.5897908432238708, - 4.287487986778531 - ], - "measuredTimeInterval": [ - 0.5897908432238708, - 3.588242281905554 - ] - } - }, - "isHomeRun": false, - "playId": "1c00950b-1211-4d3f-9642-22c57779b38a", - "timeRemaining": "3:56", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 99.000001, - "launchAngle": 39.000001, - "totalDistance": 355, - "coordinates": { - "coordX": 70.88942884942998, - "coordY": 59.52665896846892, - "landingPosX": -126.01124976562923, - "landingPosY": 331.48398763951207 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 40.24174077183768, - -99.0523174670937, - 67.87159816165781, - -37.22126158931539, - 12.707351367291748, - -2.6373481624077693, - 0.32414389729631915, - -0.021685186946740893, - 0.0006078921530673204 - ], - "trajectoryPolynomialY": [ - -65.42577868042935, - 139.16946658098286, - -46.01987787716469, - 17.669161015881528, - -5.955804347668018, - 1.4549018288084106, - -0.21982708105890636, - 0.018098567440086682, - -0.0006188474610375352 - ], - "trajectoryPolynomialZ": [ - -54.0173822803722, - 103.39017576518098, - -3.178057265815599, - -11.011261421290115, - 4.781029865623327, - -1.1439241379986267, - 0.15565693444350034, - -0.011223850288208154, - 0.0003334456747877558 - ], - "validTimeInterval": [ - 0.581173763770995, - 6.7798120694350015 - ], - "measuredTimeInterval": [ - 0.581173763770995, - 3.5446935263257613 - ] - } - }, - "isHomeRun": false, - "playId": "10013712-a268-4da1-bbe0-b1c29d69bfad", - "timeRemaining": "3:44", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 106.000001, - "launchAngle": 28.000001, - "totalDistance": 446, - "coordinates": { - "coordX": 30.78716176330454, - "coordY": 34.290429706453125, - "landingPosX": -217.70575933896097, - "landingPosY": 389.1870511768179 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 36.883817893267775, - -63.471139889753495, - -11.675740342584115, - 21.701360680992106, - -10.990025531808117, - 2.9009938960297807, - -0.4319376196336247, - 0.03438994290584651, - -0.0011411744775014874 - ], - "trajectoryPolynomialY": [ - -80.24305682027735, - 177.05572984954676, - -72.28533407994173, - 36.83094065342342, - -13.849404192394578, - 3.326708355561376, - -0.4778506725609609, - 0.03740845557566621, - -0.001228455066634081 - ], - "trajectoryPolynomialZ": [ - -49.60605652592098, - 105.95047162533196, - -31.135291523126284, - 13.649625800768742, - -6.47889833651492, - 1.8125194640195659, - -0.2912909833874237, - 0.024994047314098797, - -0.0008874824079523265 - ], - "validTimeInterval": [ - 0.5701045384971246, - 6.405940109786139 - ], - "measuredTimeInterval": [ - 0.5701045384971246, - 3.564538319051005 - ] - } - }, - "isHomeRun": true, - "playId": "bfb5b178-4084-40c5-8275-aae336acd21e", - "timeRemaining": "3:34", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 91.000001, - "launchAngle": 22.000001, - "totalDistance": 347, - "coordinates": { - "coordX": 76.38638456943244, - "coordY": 61.14615250370565, - "landingPosX": -113.44236786652247, - "landingPosY": 327.78098837635844 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 26.72908740237709, - -55.9866797628736, - 25.54480748734103, - -11.116327491201304, - 1.904115869153572, - 0.2877268966091262, - -0.18196893870370032, - 0.029159655546379448, - -0.001633634144757712 - ], - "trajectoryPolynomialY": [ - -71.56522452918561, - 139.6982470336282, - -22.410729028773183, - 2.4882594119252976, - 0.41921186505903774, - -0.20044054930031624, - 0.025326089718677277, - -0.0005561539951099525, - -0.0000709406463799938 - ], - "trajectoryPolynomialZ": [ - -35.13040304295472, - 73.81214012049566, - -20.862611900680125, - 6.390063881319498, - -2.8333435110679197, - 0.6533994649196762, - -0.06586261070832519, - 0.0005349757051701804, - 0.0002449240643566047 - ], - "validTimeInterval": [ - 0.5833708993407125, - 4.818266529223499 - ], - "measuredTimeInterval": [ - 0.5833708993407125, - 3.5754489662655593 - ] - } - }, - "isHomeRun": false, - "playId": "c33fe3c1-963b-4581-a714-3ad2ac2746d8", - "timeRemaining": "3:25", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 111.000001, - "launchAngle": 14.000001, - "totalDistance": 334, - "coordinates": { - "coordX": 125.92088460727861, - "coordY": 58.630013924889454, - "landingPosX": -0.1808986788629484, - "landingPosY": 333.5341816436516 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 19.062719373728566, - -45.309463287968526, - 29.864520883697104, - -11.685851070109804, - 4.319459925221751, - -1.6334772896350884, - 0.44748180118678466, - -0.06669612768758428, - 0.0040127457279616075 - ], - "trajectoryPolynomialY": [ - -102.08797046921893, - 189.5351201312341, - -34.0620879795393, - 11.515773397259924, - -7.350901785315273, - 3.875522730886514, - -1.1894544419068007, - 0.18997320045079566, - -0.012299852177967545 - ], - "trajectoryPolynomialZ": [ - -28.25635526848967, - 58.572860962526775, - -11.89429981475477, - -1.2805214072478, - 0.3765172566953986, - -0.22622317196327082, - 0.09176468052052415, - -0.015889794105854612, - 0.000978817602493996 - ], - "validTimeInterval": [ - 0.6038278719112877, - 3.5545920320675055 - ], - "measuredTimeInterval": [ - 0.6038278719112877, - 3.5577095301488963 - ] - } - }, - "isHomeRun": false, - "playId": "50220d38-e751-4f7a-a948-84f911f28be7", - "timeRemaining": "3:18", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 5, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 11 - } - } - ] - }, - { - "round": 2, - "numBatters": 4, - "matchups": [ - { - "topSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142" - }, - "topDerbyHitData": { - "launchSpeed": 115.000001, - "totalDistance": 485, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 103.000001, - "launchAngle": 40.000001, - "totalDistance": 361, - "coordinates": { - "coordX": 121.81982293611986, - "coordY": 46.749182703652934, - "landingPosX": -9.558045308984367, - "landingPosY": 360.69990246973737 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 14.976359446935366, - -48.127177334390794, - 39.20292262592414, - -21.470551620073824, - 7.552523858767389, - -1.642605135497605, - 0.21318667942174058, - -0.015108452080860686, - 0.0004494311011173917 - ], - "trajectoryPolynomialY": [ - -54.69480442683808, - 144.94498719240005, - -42.543235304238394, - 13.235340298046005, - -3.7438655041690647, - 0.8431213599390969, - -0.12393315130822442, - 0.010116744113117372, - -0.00034429244335784333 - ], - "trajectoryPolynomialZ": [ - -42.01432165129799, - 106.61535535098156, - -6.029137635166186, - -9.98415142458621, - 4.70961453498431, - -1.1975706666057804, - 0.17162583406419912, - -0.012968563444773972, - 0.00040257841330889704 - ], - "validTimeInterval": [ - 0.4414880930249713, - 6.959762629157723 - ], - "measuredTimeInterval": [ - 0.4414880930249713, - 3.4335012890313656 - ] - } - }, - "isHomeRun": false, - "playId": "bca263d0-b69f-419c-9348-e63ee1787a2a", - "timeRemaining": "--", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 112.000001, - "launchAngle": 15.000001, - "totalDistance": 295, - "coordinates": { - "coordX": 57.09079199856133, - "coordY": 95.51985100314039, - "landingPosX": -157.5620654864356, - "landingPosY": 249.18494742540372 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 28.781746405972132, - -65.99706035773615, - -4.915702325764032, - 2.821568537107654, - -0.9345116748190848, - 0.8962418914144035, - -0.5031689197671917, - 0.12207557099870835, - -0.010892100785461802 - ], - "trajectoryPolynomialY": [ - -64.8782255280748, - 169.86806365681576, - -39.4585196113056, - 17.726385462935475, - -11.709256082058507, - 6.30573424571123, - -2.1063095805158825, - 0.3783322710625158, - -0.02802957071550386 - ], - "trajectoryPolynomialZ": [ - -18.595298565115534, - 61.867095755824664, - -25.681869271216925, - 3.175634084625781, - -0.25225652889069977, - 0.03295931784110042, - -0.08274816220399091, - 0.03057837889358533, - -0.003358461815889666 - ], - "validTimeInterval": [ - 0.4323275565529837, - 2.848279704990467 - ], - "measuredTimeInterval": [ - 0.4323275565529837, - 2.8678611452653113 - ] - } - }, - "isHomeRun": false, - "playId": "79bfad89-ad49-45d5-bb6a-79e8216d127d", - "timeRemaining": "--", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 100.000001, - "launchAngle": 37.000001, - "totalDistance": 372, - "coordinates": { - "coordX": 69.28199628211595, - "coordY": 52.00227671049802, - "landingPosX": -129.68667142235284, - "landingPosY": 348.68861448779387 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 22.015334487659754, - -62.617124884778974, - 24.404718018173284, - -8.56977176567059, - 1.9309019890636432, - -0.2440862560307587, - 0.011786761809046942, - 0.0005156071548967865, - -0.00005603421029159757 - ], - "trajectoryPolynomialY": [ - -49.55767500329447, - 138.3375636926565, - -46.547405667107185, - 20.293310564359622, - -7.3930464926729424, - 1.8428397224908046, - -0.27915440852093054, - 0.02300275932449161, - -0.0007895966757189137 - ], - "trajectoryPolynomialZ": [ - -36.82644080323529, - 98.27568139224688, - -9.809467228308465, - -4.459129272888759, - 1.7386221306234508, - -0.36520636568149534, - 0.04346485665594207, - -0.002684773333150168, - 0.00006583431923263926 - ], - "validTimeInterval": [ - 0.4276812641688056, - 6.509442128426567 - ], - "measuredTimeInterval": [ - 0.4276812641688056, - 3.4248261851156796 - ] - } - }, - "isHomeRun": false, - "playId": "3b4c4f13-aef5-4785-a651-b55abd0b066a", - "timeRemaining": "--", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 95.000001, - "launchAngle": 38.000001, - "totalDistance": 327, - "coordinates": { - "coordX": 192.9389834695009, - "coordY": 78.17815525019783, - "landingPosX": 153.05711388812844, - "landingPosY": 288.837027040278 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -6.328884728969067, - 12.542473268460471, - 7.833346908942505, - 1.7739539174755432, - -3.624899070444327, - 1.5826454304019726, - -0.3284693527194393, - 0.03377072405207541, - -0.0013823526649285136 - ], - "trajectoryPolynomialY": [ - -49.625897098251116, - 133.25806959269445, - -30.42764633135783, - 1.919822519132417, - 2.3785575941744184, - -1.0635313885320419, - 0.21264606829554292, - -0.021302082393202294, - 0.000860650495172911 - ], - "trajectoryPolynomialZ": [ - -37.01965765599853, - 100.78463291341501, - -18.757686970484162, - 3.0232125257206244, - -2.418320083395869, - 1.0045969526739464, - -0.21443548764634307, - 0.022988042301175644, - -0.000979709322596537 - ], - "validTimeInterval": [ - 0.4269932669361625, - 6.114158183928308 - ], - "measuredTimeInterval": [ - 0.4269932669361625, - 3.4245228895979434 - ] - } - }, - "isHomeRun": false, - "playId": "15c49e22-e812-44fc-80e6-de9a84da2e4e", - "timeRemaining": "--", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 26.000001, - "totalDistance": 423, - "coordinates": { - "coordX": 170.7016565848818, - "coordY": 25.146058488231603, - "landingPosX": 102.21109118003874, - "landingPosY": 410.0958100858974 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 2.4012905719927122, - -11.168791536111362, - 14.882228101997603, - -1.662115748960572, - -1.4629502261610638, - 0.7546479394610287, - -0.15895975381881727, - 0.01627163446970633, - -0.0006635899974544095 - ], - "trajectoryPolynomialY": [ - -63.455716514023514, - 165.28877656205165, - -36.368434278222814, - 8.851606650465618, - -1.9379317583479188, - 0.3720172986535091, - -0.05384886296473011, - 0.0047397740768216285, - -0.00018129065814753766 - ], - "trajectoryPolynomialZ": [ - -29.44904348622181, - 79.35393065147848, - -11.38173311215865, - -0.8383579187802321, - -0.17079479924889895, - 0.18747608532544185, - -0.04802789057821141, - 0.005492606129044943, - -0.0002406743949191693 - ], - "validTimeInterval": [ - 0.43121842491788687, - 5.764115763785039 - ], - "measuredTimeInterval": [ - 0.43121842491788687, - 3.4289521197804573 - ] - } - }, - "isHomeRun": true, - "playId": "6638a4f4-c7b3-48db-9b7d-e661e47d4cbf", - "timeRemaining": "--", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 8, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 10 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934" - }, - "topDerbyHitData": { - "launchSpeed": 113.000001, - "totalDistance": 491, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 113.000001, - "launchAngle": 18.000001, - "totalDistance": 386, - "coordinates": { - "coordX": 89.43077221312979, - "coordY": 39.50363268360081, - "landingPosX": -83.61615566997853, - "landingPosY": 377.26697470659815 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 18.544935782097347, - -36.902739564844445, - 4.554875083665141, - 2.31263663556803, - -4.632964049035132, - 2.820442540524032, - -0.8208158372065597, - 0.11740114854115741, - -0.006654581124376167 - ], - "trajectoryPolynomialY": [ - -86.03935164823672, - 179.59754035526635, - -26.5472277673295, - 2.35927201553885, - 0.013970542663697802, - 0.2388891419039921, - -0.13798781282366498, - 0.027033240573162746, - -0.0018590040409965558 - ], - "trajectoryPolynomialZ": [ - -27.82207977995202, - 65.31564552155137, - -9.767004339026938, - -9.032282815536798, - 7.331671713103125, - -3.1486356753149116, - 0.7541880896884382, - -0.0946541209487221, - 0.004864940532694616 - ], - "validTimeInterval": [ - 0.5278844489337585, - 4.201832813191546 - ], - "measuredTimeInterval": [ - 0.5278844489337585, - 3.5227900679788817 - ] - } - }, - "isHomeRun": false, - "playId": "0bc09647-b5e6-4f05-8b29-49f568fd4e19", - "timeRemaining": "3:55", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 107.000001, - "launchAngle": 27.000001, - "totalDistance": 440, - "coordinates": { - "coordX": 36.23748983558308, - "coordY": 34.30344160852721, - "landingPosX": -205.2434923422342, - "landingPosY": 389.1572992434237 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 30.285226470714523, - -60.854522542285814, - 1.9475011043744848, - 1.9323414136398858, - 0.18090774579638824, - -0.47166472932212405, - 0.14224504662087617, - -0.01770524999545679, - 0.0008227127888492934 - ], - "trajectoryPolynomialY": [ - -72.63738309645412, - 164.23847995340063, - -46.850740997788165, - 19.843921898329906, - -6.793108447150615, - 1.5009785332865861, - -0.1937987634876677, - 0.012923440111212041, - -0.0003254770265698043 - ], - "trajectoryPolynomialZ": [ - -34.44271641224456, - 78.27756092734884, - -6.384213525425606, - -5.99753648104556, - 3.02924301019549, - -0.9422566761550659, - 0.17081385432116314, - -0.016420738346083093, - 0.0006495911866962578 - ], - "validTimeInterval": [ - 0.5175968763999134, - 5.608399488704569 - ], - "measuredTimeInterval": [ - 0.5175968763999134, - 3.5133391673309218 - ] - } - }, - "isHomeRun": true, - "playId": "5385e926-fc17-4b6a-9b4c-38613777a906", - "timeRemaining": "3:49", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 90.000001, - "launchAngle": 49.000001, - "totalDistance": 278, - "coordinates": { - "coordX": 143.2727149447031, - "coordY": 84.12603561223001, - "landingPosX": 39.494353834236854, - "landingPosY": 275.23709834731676 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 6.803614378339348, - -23.589980114766902, - 27.275363748006715, - -15.200781294623393, - 5.073559245367791, - -1.0041051490297426, - 0.11464687331502917, - -0.006853550489365684, - 0.00016145075373294874 - ], - "trajectoryPolynomialY": [ - -50.53549688124736, - 116.68411688106016, - -38.226587876844846, - 15.017084038645008, - -5.12126049495556, - 1.2464414214882196, - -0.18779716590893622, - 0.015502362016703419, - -0.0005338803620378575 - ], - "trajectoryPolynomialZ": [ - -54.00743626304775, - 120.9341580229415, - -20.39176485589176, - -2.392665292025555, - 2.1453554633307874, - -0.6634409245866258, - 0.1049016737865642, - -0.008383021114236017, - 0.0002694074349601797 - ], - "validTimeInterval": [ - 0.5223993150237409, - 6.5714953843596255 - ], - "measuredTimeInterval": [ - 0.5223993150237409, - 3.5198131329815823 - ] - } - }, - "isHomeRun": false, - "playId": "012697f7-5dba-4368-8673-dad1791ee3b9", - "timeRemaining": "3:43", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 106.000001, - "launchAngle": 32.000001, - "totalDistance": 424, - "coordinates": { - "coordX": 101.64663683994279, - "coordY": 20.789229741168015, - "landingPosX": -55.68437531541172, - "landingPosY": 420.05777244575626 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 19.93532849917222, - -48.38048772106888, - 28.523025338263977, - -12.557300498955135, - 3.2975599693169495, - -0.4833493333225733, - 0.03474764311954307, - -0.0006521538074993353, - -0.0000299581071338366 - ], - "trajectoryPolynomialY": [ - -75.65454953916127, - 161.10489869401164, - -33.890849398705825, - 4.72444110164491, - 0.22814006557059766, - -0.22229715174756132, - 0.03973692192289123, - -0.0032673405687452693, - 0.0001074539333277809 - ], - "trajectoryPolynomialZ": [ - -42.86588871069974, - 91.53186078488001, - -6.349034546897743, - -5.050422622154502, - 1.838706150298507, - -0.3770114111586068, - 0.043533857010270655, - -0.00253109351885596, - 0.00005546933813554817 - ], - "validTimeInterval": [ - 0.5362853259616839, - 6.855877000766313 - ], - "measuredTimeInterval": [ - 0.5362853259616839, - 3.5341016850287796 - ] - } - }, - "isHomeRun": true, - "playId": "e705de1a-8d5d-448c-8d5b-deff4c400bb8", - "timeRemaining": "3:27", - "isBonusTime": true, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 110.000001, - "launchAngle": 24.000001, - "totalDistance": 459, - "coordinates": { - "coordX": 64.63239559474923, - "coordY": 13.364763515709853, - "landingPosX": -140.31806175807338, - "landingPosY": 437.03393960171957 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 25.126398813422025, - -57.3598953970818, - 26.066043427919823, - -15.33746588603168, - 6.491269211909898, - -1.7855860037996547, - 0.2959664672581608, - -0.026720097045544587, - 0.001007660675636039 - ], - "trajectoryPolynomialY": [ - -78.72762414049646, - 167.5253572491674, - -23.83845576774435, - -2.719656836607042, - 3.914448776424236, - -1.3706401515445608, - 0.24734700922937736, - -0.02316588988368158, - 0.0008902408504869375 - ], - "trajectoryPolynomialZ": [ - -35.98612627445274, - 85.26134221463931, - -25.635837045263813, - 10.758115036302318, - -5.026017032390686, - 1.3938648584923334, - -0.22655356022612197, - 0.020025035070269735, - -0.0007426418102900153 - ], - "validTimeInterval": [ - 0.522176444135453, - 5.834434134565104 - ], - "measuredTimeInterval": [ - 0.522176444135453, - 3.516312222003153 - ] - } - }, - "isHomeRun": true, - "playId": "095e7376-2383-47af-ac6d-004b6fda89a0", - "timeRemaining": "3:16", - "isBonusTime": true, - "isTieBreaker": false - } - ], - "seed": 5, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 11 - } - }, - { - "topSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355" - }, - "topDerbyHitData": { - "launchSpeed": 107.000001, - "totalDistance": 433, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 101.000001, - "launchAngle": 17.000001, - "totalDistance": 270, - "coordinates": { - "coordX": 206.88794085167578, - "coordY": 118.62115638418805, - "landingPosX": 184.95164003725867, - "landingPosY": 196.36342332379473 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -40.8190128553703, - 78.67306934582832, - 2.762157150547489, - -2.190828122355813, - 1.2330231579884212, - -1.1322162870397356, - 0.54974588374982, - -0.12093408161204001, - 0.010015463351315168 - ], - "trajectoryPolynomialY": [ - -63.559336437006976, - 142.59333952385683, - -33.08693350221554, - 14.91377529916888, - -10.83093401973676, - 5.94742384464642, - -1.9513691046850774, - 0.339926661027046, - -0.02432882320540786 - ], - "trajectoryPolynomialZ": [ - -25.85711082996454, - 70.09095407046244, - -27.562988837925598, - 3.613249292244837, - -0.43692809103446634, - -0.09100625466670875, - 0.04985642789480291, - -0.007637297611794613, - 0.00036275868782898363 - ], - "validTimeInterval": [ - 0.5130773549534475, - 2.961704063937803 - ], - "measuredTimeInterval": [ - 0.5130773549534475, - 2.9838121042693047 - ] - } - }, - "isHomeRun": false, - "playId": "cac8f9d5-5a03-46ea-b24d-9b37a8bdfaed", - "timeRemaining": "3:55", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 23.000001, - "totalDistance": 391, - "coordinates": { - "coordX": 218.14709385484053, - "coordY": 60.32548302802883, - "landingPosX": 210.69588314000055, - "landingPosY": 329.6574629640015 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -31.79215210694984, - 64.28359515393032, - -5.43092638027875, - 2.1533645160199373, - -0.5595616086001185, - 0.015502864920676623, - 0.019178144614616848, - -0.003121727201612788, - 0.00013771709169596317 - ], - "trajectoryPolynomialY": [ - -69.4513319670641, - 150.18127091379904, - -23.403402357457605, - 0.887214315318721, - 1.5692991803151484, - -0.7007660638294355, - 0.1627790202998397, - -0.02075888968230361, - 0.001114586398384869 - ], - "trajectoryPolynomialZ": [ - -32.60782759527875, - 79.62008468514179, - -19.238375960999093, - -0.7260555675932485, - 2.250168860834686, - -1.1913757145489183, - 0.3009739742231531, - -0.03767022914015348, - 0.0018829832296735347 - ], - "validTimeInterval": [ - 0.5133374391793983, - 4.544478186249687 - ], - "measuredTimeInterval": [ - 0.5133374391793983, - 3.509694585419487 - ] - } - }, - "isHomeRun": true, - "playId": "96ac5f12-7ac4-40ab-8f51-51f7f990b47d", - "timeRemaining": "3:49", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 100.000001, - "launchAngle": 30.000001, - "totalDistance": 410, - "coordinates": { - "coordX": 152.29862338021172, - "coordY": 27.216961051960652, - "landingPosX": 60.132245594079606, - "landingPosY": 405.3606564710787 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -15.329104262191844, - 32.61753623349301, - -4.180736777960404, - -1.4816277576703234, - 0.9951552835570848, - -0.26973077455901395, - 0.04029170142125263, - -0.0032428531656441156, - 0.0001106738584745044 - ], - "trajectoryPolynomialY": [ - -66.55946204830573, - 148.41359023222694, - -30.865990098698774, - 8.844279187794513, - -2.657836102115152, - 0.6528030183541458, - -0.10375084359398133, - 0.009110823165756742, - -0.00033382712647849155 - ], - "trajectoryPolynomialZ": [ - -37.578392875146314, - 87.6522053130862, - -11.186657658240673, - -4.973616405353353, - 2.98240522540992, - -0.8965711326037518, - 0.14875956104181395, - -0.01293172575025189, - 0.0004623069384151862 - ], - "validTimeInterval": [ - 0.5058817313821967, - 6.027002947202469 - ], - "measuredTimeInterval": [ - 0.5058817313821967, - 3.482428497282754 - ] - } - }, - "isHomeRun": true, - "playId": "2f9b75ca-b012-4c07-bdd3-c5124b4a4f49", - "timeRemaining": "3:38", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 104.000001, - "launchAngle": 20.000001, - "totalDistance": 324, - "coordinates": { - "coordX": 204.07012816665423, - "coordY": 86.2607704150284, - "landingPosX": 178.5086638417319, - "landingPosY": 270.3559912420418 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -33.40542862639973, - 63.0645143024393, - 6.705902459075797, - -7.6144302574519624, - 5.954271146664167, - -3.375795314097079, - 1.0742899356837983, - -0.1732076614764447, - 0.011135769057698218 - ], - "trajectoryPolynomialY": [ - -69.8468269732927, - 155.59592034763602, - -38.52120181497758, - 21.702452255934457, - -15.039435626211082, - 7.2623580963993435, - -2.053979316871558, - 0.30586077945566725, - -0.018540996004047933 - ], - "trajectoryPolynomialZ": [ - -29.560532182701607, - 76.7618369795854, - -26.98794870448559, - 4.487347535364083, - -1.1393649895070936, - 0.13050433275335716, - 0.017274609671037236, - -0.004934279981081517, - 0.0002227502475406742 - ], - "validTimeInterval": [ - 0.5116060767175139, - 3.5802211890221782 - ], - "measuredTimeInterval": [ - 0.5116060767175139, - 3.41316260316396 - ] - } - }, - "isHomeRun": false, - "playId": "29bb5f73-d5b1-4982-8baf-c123b6ffb97d", - "timeRemaining": "3:30", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 104.000001, - "launchAngle": 28.000001, - "totalDistance": 429, - "coordinates": { - "coordX": 225.38657523829522, - "coordY": 45.615278570871055, - "landingPosX": 227.24907933700086, - "landingPosY": 363.29259338008694 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -33.438553192052304, - 77.77416845661237, - -30.51875381614577, - 20.60709673786185, - -8.92597137213046, - 2.315065552102488, - -0.3518413430864127, - 0.02897305423345071, - -0.0009989755721794107 - ], - "trajectoryPolynomialY": [ - -62.65017938181469, - 134.15557405271954, - -5.40991372768868, - -17.12023424436271, - 11.175300719857756, - -3.5088908664700353, - 0.6083907223926055, - -0.0557349751993809, - 0.0021105749722792277 - ], - "trajectoryPolynomialZ": [ - -37.93166825134946, - 96.15579433992954, - -33.9341477792921, - 15.726720543043394, - -7.161831989839775, - 1.9555135115781082, - -0.31364020465505094, - 0.027364256069585164, - -0.001001942006080205 - ], - "validTimeInterval": [ - 0.5022235450314637, - 5.739487338976742 - ], - "measuredTimeInterval": [ - 0.5022235450314637, - 3.5152882710893385 - ] - } - }, - "isHomeRun": true, - "playId": "8f543a5c-4199-46bd-8293-be593450423e", - "timeRemaining": "3:24", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 3, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 12 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450" - }, - "topDerbyHitData": { - "launchSpeed": 119.000001, - "totalDistance": 513, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 105.000001, - "launchAngle": 29.000001, - "totalDistance": 426, - "coordinates": { - "coordX": 139.62631679478628, - "coordY": 18.527888379226795, - "landingPosX": 31.156803008303463, - "landingPosY": 425.2283675823297 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 13.114372814218697, - -43.444697720097544, - 41.04281071707479, - -19.281288475529447, - 5.224710500898421, - -0.734147074990245, - 0.03220416334052289, - 0.0033149569931678145, - -0.00031195147915253436 - ], - "trajectoryPolynomialY": [ - -62.4968612222692, - 152.101832169985, - -22.994940121767154, - 2.176688806741588, - 0.26132131980247536, - -0.09618306126583642, - 0.009526259481177435, - -0.00028690383523730193, - -0.0000033091475564405693 - ], - "trajectoryPolynomialZ": [ - -34.210074100346326, - 89.16388683389233, - -14.127901307620766, - -3.9514207943716997, - 3.000800443873732, - -1.0436482650304022, - 0.19450219465478338, - -0.018724165352765453, - 0.000735088315379683 - ], - "validTimeInterval": [ - 0.4510657591674721, - 5.711741418347126 - ], - "measuredTimeInterval": [ - 0.4510657591674721, - 3.430509963967531 - ] - } - }, - "isHomeRun": true, - "playId": "63b64622-2e0f-4da5-aa4d-e70a13849c81", - "timeRemaining": "3:55", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 110.000001, - "launchAngle": 30.000001, - "totalDistance": 414, - "coordinates": { - "coordX": 212.91401267227303, - "coordY": 45.89856878879212, - "landingPosX": 198.73035481806247, - "landingPosY": 362.6448455222562 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -6.438855985392583, - 0.37589203693297446, - 41.69433022951377, - -27.98935313163366, - 12.342443935505866, - -3.4325441624616033, - 0.5715150583912776, - -0.051859009797316176, - 0.001970599877546748 - ], - "trajectoryPolynomialY": [ - -67.11854651757018, - 169.19192555857487, - -42.584990400364006, - 13.435857096040555, - -4.409316048078815, - 1.1330751877601835, - -0.18612816500255583, - 0.016840281198274524, - -0.0006359925461689747 - ], - "trajectoryPolynomialZ": [ - -37.35413753521982, - 97.9140927536823, - -14.962470782956732, - -8.302383328428974, - 6.157675715328853, - -2.1132574754308466, - 0.3912066688981782, - -0.03757436952313326, - 0.0014739575082893504 - ], - "validTimeInterval": [ - 0.44627776378546885, - 5.637018120230749 - ], - "measuredTimeInterval": [ - 0.44627776378546885, - 3.4320086373869487 - ] - } - }, - "isHomeRun": true, - "playId": "0433e579-c8a7-4a08-b111-8abb558a0096", - "timeRemaining": "3:48", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 92.000001, - "launchAngle": 13.000001, - "totalDistance": 149, - "coordinates": { - "coordX": 75.78950191284498, - "coordY": 162.78696338414517, - "landingPosX": -114.80715012062973, - "landingPosY": 95.37756125085912 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 42.29157883125268, - -106.88514041038634, - 18.186202619040753, - -7.539912690312315, - 2.5443131365144556, - -1.011290069848018, - 0.329714696244378, - -0.06120013163934752, - 0.004442378878443006 - ], - "trajectoryPolynomialY": [ - -40.214606950293344, - 105.19483957459741, - -15.599248033457702, - -1.1429001341136806, - 0.973119885493981, - 0.6132123078123569, - -1.1009226584179632, - 0.49341254056566813, - -0.07503491784566829 - ], - "trajectoryPolynomialZ": [ - -14.916572685437222, - 57.413958473195045, - -34.94605371971769, - 5.962700042143592, - -1.9865484060587468, - 0.883173178311394, - -0.34759015190404613, - 0.0820176244124309, - -0.008323069616269082 - ], - "validTimeInterval": [ - 0.43163348048400535, - 1.7426307949371314 - ], - "measuredTimeInterval": [ - 0.43163348048400535, - 1.749253382617091 - ] - } - }, - "isHomeRun": false, - "playId": "e7138220-7af4-4807-b7a9-69899b42bfcf", - "timeRemaining": "3:43", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 109.000001, - "launchAngle": 35.000001, - "totalDistance": 419, - "coordinates": { - "coordX": 196.37091122591642, - "coordY": 35.43603827947621, - "landingPosX": 160.90427454465157, - "landingPosY": 386.5675978665909 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 0.9790565133274507, - -13.53652840102802, - 31.331119432322886, - -15.904136606663243, - 5.129699379225958, - -1.0173575816402805, - 0.1192538028928924, - -0.00749019918343824, - 0.0001924910186830438 - ], - "trajectoryPolynomialY": [ - -63.35691544027855, - 163.5749425930474, - -43.097508007624775, - 12.227503696820799, - -3.155682839084055, - 0.6553377658524232, - -0.09187917538931856, - 0.007317466631983394, - -0.0002457509563505309 - ], - "trajectoryPolynomialZ": [ - -39.79767383047185, - 101.05182024599426, - -7.070532102072456, - -8.50709788806141, - 3.8468083354227214, - -0.9446445494564603, - 0.13236689166385687, - -0.009844833791588296, - 0.00030216896665271134 - ], - "validTimeInterval": [ - 0.4422332068671005, - 6.60776360237486 - ], - "measuredTimeInterval": [ - 0.4422332068671005, - 3.4364255572972167 - ] - } - }, - "isHomeRun": true, - "playId": "b82727ea-1d7d-42ff-8fe7-fc56a9168747", - "timeRemaining": "3:29", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 115.000001, - "launchAngle": 14.000001, - "totalDistance": 289, - "coordinates": { - "coordX": 100.55972634042085, - "coordY": 80.61932440507358, - "landingPosX": -58.169614491284904, - "landingPosY": 283.2552526243542 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 12.752649074583585, - -28.51370070124987, - -1.35176747545074, - 3.6452735274208568, - -3.4150357796796444, - 1.7479129116686578, - -0.4629433206005379, - 0.0603126409937334, - -0.0029385100093522005 - ], - "trajectoryPolynomialY": [ - -75.32148777407228, - 184.3639967683167, - -28.529338019152906, - 5.334031915401769, - -1.0294391899353115, - 0.14628273948186218, - -0.032660954795757084, - 0.011250832370799267, - -0.001543651467191683 - ], - "trajectoryPolynomialZ": [ - -20.695816413796496, - 64.62986920916164, - -32.84107641594626, - 9.491763021243619, - -4.737590071789781, - 2.146467533355032, - -0.6193037933078935, - 0.09643464725216874, - -0.0061828992722838885 - ], - "validTimeInterval": [ - 0.44255098217070477, - 2.729228228264441 - ], - "measuredTimeInterval": [ - 0.44255098217070477, - 2.7306028345375735 - ] - } - }, - "isHomeRun": false, - "playId": "3b4eb848-a7da-4656-a1fa-13bd3ed9c407", - "timeRemaining": "3:22", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 2, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 13 - } - } - ] - }, - { - "round": 3, - "numBatters": 2, - "matchups": [ - { - "topSeed": { - "started": true, - "complete": true, - "winner": false, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934" - }, - "topDerbyHitData": { - "launchSpeed": 113.000001, - "totalDistance": 449, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 111.000001, - "launchAngle": 15.000001, - "totalDistance": 342, - "coordinates": { - "coordX": 78.21541596703884, - "coordY": 62.785548362510895, - "landingPosX": -109.26025674952353, - "landingPosY": 324.0324821149329 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 21.569312725891503, - -44.28930723807719, - 2.992429067100087, - -1.4322166146013893, - 1.5232981729341364, - -0.7851033014437894, - 0.19118508565688194, - -0.01928745024335872, - 0.0003768791307942121 - ], - "trajectoryPolynomialY": [ - -84.11807827725237, - 186.55901572140127, - -45.59430017431631, - 19.75639475638647, - -8.727426045498722, - 2.6698566526624363, - -0.47495055530605823, - 0.04103735261367299, - -0.0010936526470922297 - ], - "trajectoryPolynomialZ": [ - -22.725560143629494, - 60.42276928173766, - -17.697362475584168, - -2.3295802378774755, - 4.218015080010268, - -2.1965766519444774, - 0.5652216118994227, - -0.07396264178004631, - 0.003984454081644443 - ], - "validTimeInterval": [ - 0.5120402573065941, - 3.6046458481268813 - ], - "measuredTimeInterval": [ - 0.5120402573065941, - 3.5094496946721296 - ] - } - }, - "isHomeRun": false, - "playId": "2aec0aaa-c1ad-4a43-8238-8218aeda9ca9", - "timeRemaining": "3:47", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 95.000001, - "launchAngle": 35.000001, - "totalDistance": 326, - "coordinates": { - "coordX": 229.65514717515006, - "coordY": 106.56017024826282, - "landingPosX": 237.00924101284312, - "landingPosY": 223.941071398635 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -31.045410872653886, - 68.82074719996643, - -27.05639718286903, - 25.174307073558026, - -13.41424831631921, - 4.080527676067807, - -0.7120168881266281, - 0.0665610984936645, - -0.0025884792240084636 - ], - "trajectoryPolynomialY": [ - -56.486848722397234, - 113.15667409366762, - -0.3650590148986456, - -23.284117803458585, - 14.38747764937783, - -4.539143567709174, - 0.8139375182255342, - -0.07852235856655666, - 0.0031603068921493525 - ], - "trajectoryPolynomialZ": [ - -46.37322285208518, - 109.66965025557872, - -36.39549279881304, - 12.86857773352833, - -4.885281022020754, - 1.1423893011496355, - -0.15990388913334452, - 0.012528582185623404, - -0.00042489602151074145 - ], - "validTimeInterval": [ - 0.5282275047137731, - 5.520494960768431 - ], - "measuredTimeInterval": [ - 0.5282275047137731, - 3.52245668296241 - ] - } - }, - "isHomeRun": false, - "playId": "1eb5bf37-9ab1-4e06-a7af-8d45e38db724", - "timeRemaining": "3:38", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 93.000001, - "launchAngle": 36.000001, - "totalDistance": 326, - "coordinates": { - "coordX": 207.7167852726785, - "coordY": 87.78757600252399, - "landingPosX": 186.84680677516937, - "landingPosY": 266.8649245335547 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -14.55049098594951, - 15.05510911564787, - 39.33025107441131, - -33.20105411785453, - 16.838696072511883, - -5.122919996122397, - 0.9031364771445184, - -0.08505601556735895, - 0.0033128468748060574 - ], - "trajectoryPolynomialY": [ - -64.52342099159665, - 152.39074383507565, - -67.99904110382224, - 37.511684495754274, - -15.702476611273926, - 4.1085717924304435, - -0.6206562681105672, - 0.04919379930601188, - -0.0015680518766405431 - ], - "trajectoryPolynomialZ": [ - -44.55888224764817, - 98.31949204519825, - -13.40682857306249, - -7.862054941050579, - 5.198415031114488, - -1.6791573556817514, - 0.2978031883573686, - -0.027607797370613172, - 0.0010487083734722973 - ], - "validTimeInterval": [ - 0.5247829872191551, - 5.604558988195686 - ], - "measuredTimeInterval": [ - 0.5247829872191551, - 3.5196236364101714 - ] - } - }, - "isHomeRun": false, - "playId": "c7a3868f-939a-4779-adde-ed4c08865649", - "timeRemaining": "3:26", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 110.000001, - "launchAngle": 30.000001, - "totalDistance": 447, - "coordinates": { - "coordX": 61.1888412481877, - "coordY": 20.110550269815207, - "landingPosX": -148.19180680891913, - "landingPosY": 421.60958449542255 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 33.43123943130334, - -84.41314920946047, - 47.773030307153746, - -25.17489803031014, - 8.302854438822024, - -1.643426434784565, - 0.1897874277677307, - -0.011731425441735888, - 0.0002977457485332889 - ], - "trajectoryPolynomialY": [ - -73.82895328460468, - 162.9913472212023, - -35.31917760943145, - 5.852460334041308, - 0.054257073647128735, - -0.27260647584558817, - 0.059833809255140244, - -0.005727066475093282, - 0.000212486556909828 - ], - "trajectoryPolynomialZ": [ - -40.83143553447391, - 89.09641036387673, - -4.157053212132953, - -7.48928186416655, - 2.900678666428183, - -0.6311632659098046, - 0.07915791874693695, - -0.005256479715904793, - 0.00014234911268320752 - ], - "validTimeInterval": [ - 0.518026068220682, - 6.606182196150316 - ], - "measuredTimeInterval": [ - 0.518026068220682, - 3.522800510494309 - ] - } - }, - "isHomeRun": true, - "playId": "938e3485-de61-4650-8360-f043de2f3459", - "timeRemaining": "3:11", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 112.000001, - "launchAngle": 19.000001, - "totalDistance": 344, - "coordinates": { - "coordX": 19.051340444521443, - "coordY": 98.49763533598991, - "landingPosX": -244.53991257909985, - "landingPosY": 242.37619336096688 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 49.09495524454299, - -106.88984143802463, - 26.505160506244756, - -23.4490066906286, - 16.257924693042757, - -7.680966744825794, - 2.254042469346377, - -0.35902560862441374, - 0.023461276516289514 - ], - "trajectoryPolynomialY": [ - -72.02170920508509, - 176.4456061241803, - -78.71403475448616, - 54.612782529153655, - -30.432621011594996, - 10.580688105984567, - -2.122531931882594, - 0.22410988283871597, - -0.009588988950233171 - ], - "trajectoryPolynomialZ": [ - -29.597812903823755, - 75.25868405531716, - -19.701189288855907, - -6.051376321887132, - 7.692727484247774, - -4.160057520789649, - 1.2179175271108111, - -0.18654454480101465, - 0.01170007384019499 - ], - "validTimeInterval": [ - 0.5077242054340556, - 3.593974815785598 - ], - "measuredTimeInterval": [ - 0.5077242054340556, - 3.280987674749438 - ] - } - }, - "isHomeRun": false, - "playId": "6f669167-aa90-419b-a440-1b450a56e186", - "timeRemaining": "3:00", - "isBonusTime": false, - "isTieBreaker": false - } - ], - "seed": 5, - "order": 0, - "isWinner": false, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 10 - }, - "bottomSeed": { - "started": true, - "complete": true, - "winner": true, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450" - }, - "topDerbyHitData": { - "launchSpeed": 118.000001, - "totalDistance": 480, - "coordinates": {} - }, - "hits": [ - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 118.000001, - "launchAngle": 21.000001, - "totalDistance": 410, - "coordinates": { - "coordX": 74.23757268589279, - "coordY": 32.66805245626361, - "landingPosX": -118.35566245416648, - "landingPosY": 392.89664410281296 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 19.4242277699165, - -46.404448922973955, - 10.133775376428236, - -9.380708117781566, - 6.850654247870971, - -3.1264094806255547, - 0.8451594376852418, - -0.12110845123925051, - 0.007041066762064662 - ], - "trajectoryPolynomialY": [ - -73.51820501141869, - 177.74831829890547, - -25.523700379760733, - -0.08925178625769137, - 2.8335518109098943, - -1.2951575144048826, - 0.29766062022413053, - -0.03561592050811395, - 0.001756664972866099 - ], - "trajectoryPolynomialZ": [ - -31.0051790885736, - 87.41613522822057, - -31.329336964566124, - 8.390287710419672, - -3.6326016704211272, - 1.0245066849583844, - -0.13361500689641695, - 0.0032096212148709623, - 0.0005037385228506815 - ], - "validTimeInterval": [ - 0.45279257926684924, - 4.265768043134013 - ], - "measuredTimeInterval": [ - 0.45279257926684924, - 3.4469477301675226 - ] - } - }, - "isHomeRun": true, - "playId": "654465cb-c7bc-4360-b0e4-4011828535e8", - "timeRemaining": "3:55", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 111.000001, - "launchAngle": 23.000001, - "totalDistance": 423, - "coordinates": { - "coordX": 131.010860943197, - "coordY": 19.455433265965468, - "landingPosX": 11.457417999332497, - "landingPosY": 423.10752056602274 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 7.868806380764921, - -21.795054876094166, - 8.95461543328153, - 2.004963760385575, - -2.873107767010992, - 1.093811820894821, - -0.20618324370215094, - 0.019553876893899664, - -0.0007408624102870518 - ], - "trajectoryPolynomialY": [ - -65.81205122037488, - 161.29914512709615, - -12.305349112277502, - -10.569380286847016, - 8.286383334026029, - -2.9777510627268002, - 0.5947067006237734, - -0.06315327951499684, - 0.002781242685638246 - ], - "trajectoryPolynomialZ": [ - -28.964481044467657, - 80.55979785805135, - -23.95423531102023, - 7.101469718408654, - -2.9066134819786495, - 0.656447293106385, - -0.0737564986729184, - 0.002926303148162511, - 0.00005125260005260649 - ], - "validTimeInterval": [ - 0.4368456012811172, - 4.890280049523282 - ], - "measuredTimeInterval": [ - 0.4368456012811172, - 3.4318774689634086 - ] - } - }, - "isHomeRun": true, - "playId": "5a4e3c8e-6bfa-4bde-8684-322cd66060ab", - "timeRemaining": "3:49", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 116.000001, - "launchAngle": 28.000001, - "totalDistance": 469, - "coordinates": { - "coordX": 163.43857312418197, - "coordY": 2.639889332153359, - "landingPosX": 85.60392843562953, - "landingPosY": 461.556545178728 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 6.606117093866811, - -25.766921679022627, - 31.323940309404275, - -15.543211419515147, - 5.753512609922286, - -1.4725135106498477, - 0.23629356341251417, - -0.021028124426031664, - 0.0007870615889771895 - ], - "trajectoryPolynomialY": [ - -70.72755083654583, - 179.43763322868938, - -40.67417960684654, - 11.407051242162195, - -2.6541885547731923, - 0.4131003341257032, - -0.033747465626928215, - 0.0006544996438802701, - 0.0000496497489235886 - ], - "trajectoryPolynomialZ": [ - -35.10082046765578, - 91.3695683895675, - -8.895559667413947, - -6.809483617404781, - 3.027901099317654, - -0.7194684353680533, - 0.09812493258014676, - -0.007142709529208724, - 0.00021391958905203504 - ], - "validTimeInterval": [ - 0.43934767832264826, - 5.851981345314799 - ], - "measuredTimeInterval": [ - 0.43934767832264826, - 3.4333123139337074 - ] - } - }, - "isHomeRun": true, - "playId": "479d26e2-a91e-458a-b439-84bfb04cdb65", - "timeRemaining": "3:44", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": false, - "homeRun": true, - "tieBreaker": false, - "hitData": { - "launchSpeed": 117.000001, - "launchAngle": 33.000001, - "totalDistance": 480, - "coordinates": { - "coordX": 73.29065621392812, - "coordY": 1.4189004601377633, - "landingPosX": -120.52080292658009, - "landingPosY": 464.3483568130558 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - 19.151318263161805, - -52.46827135810376, - 23.25035833434663, - -12.881714022399846, - 5.288703989249963, - -1.3676511450106135, - 0.20759594730502928, - -0.01686962299996336, - 0.000565907368623422 - ], - "trajectoryPolynomialY": [ - -65.0793398759805, - 170.01539996692455, - -42.85035010986528, - 11.581351786739114, - -2.450231710986242, - 0.3774328660903918, - -0.0383516641121727, - 0.0022638085578647426, - -0.00005891426365712123 - ], - "trajectoryPolynomialZ": [ - -40.02028761539298, - 103.89800329942541, - -8.55203835120496, - -6.468941745945446, - 2.7195556614322642, - -0.6110409732082622, - 0.0782053210815663, - -0.005310080537717338, - 0.00014786258166029026 - ], - "validTimeInterval": [ - 0.4348515227139094, - 6.870367269784164 - ], - "measuredTimeInterval": [ - 0.4348515227139094, - 3.4292042932013174 - ] - } - }, - "isHomeRun": true, - "playId": "585cb708-be3c-4679-9613-5d9ad0e7e977", - "timeRemaining": "3:32", - "isBonusTime": false, - "isTieBreaker": false - }, - { - "bonusTime": true, - "homeRun": false, - "tieBreaker": false, - "hitData": { - "launchSpeed": 106.000001, - "launchAngle": 48.000001, - "totalDistance": 335, - "coordinates": { - "coordX": 204.01521189706668, - "coordY": 80.29556231367057, - "landingPosX": 178.38309686576483, - "landingPosY": 283.99554010301165 - }, - "trajectoryData": { - "trajectoryPolynomialX": [ - -3.459879268708907, - -0.9948691939823067, - 25.828916968366187, - -14.716332105938545, - 5.266150167614627, - -1.1624916644007834, - 0.15301821154749992, - -0.010965189348958638, - 0.0003288199448217296 - ], - "trajectoryPolynomialY": [ - -49.076783010434625, - 133.06680062328073, - -42.40319061257053, - 14.200827982322712, - -4.416224725363385, - 1.0658924510124095, - -0.16300813389304003, - 0.013520162828939914, - -0.00046095015810008306 - ], - "trajectoryPolynomialZ": [ - -51.52732149990005, - 139.3101353157459, - -30.467024927785186, - 4.216909217777, - -0.739240856180158, - 0.07450957428771196, - -0.0033906125557465992, - 0.00004446349663711111, - -1.3578211171350838e-8 - ], - "validTimeInterval": [ - 0.4306836094678908, - 6.914337784272519 - ], - "measuredTimeInterval": [ - 0.4306836094678908, - 3.3647260826094287 - ] - } - }, - "isHomeRun": false, - "playId": "b5de7584-c87a-4ca9-9e17-377119e1eb01", - "timeRemaining": "3:25", - "isBonusTime": true, - "isTieBreaker": false - } - ], - "seed": 2, - "order": 0, - "isWinner": true, - "isComplete": true, - "isStarted": true, - "numHomeRuns": 11 - } - } - ] - } - ], - "players": [ - { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355", - "firstName": "Cody", - "lastName": "Bellinger", - "primaryNumber": "35", - "birthDate": "1995-07-13", - "currentAge": 27, - "birthCity": "Scottsdale", - "birthStateProvince": "AZ", - "birthCountry": "USA", - "height": "6' 4\"", - "weight": 203, - "active": true, - "currentTeam": { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 119, - "name": "Los Angeles Dodgers", - "link": "/api/v1/teams/119", - "season": 2022, - "venue": { - "id": 22, - "name": "Dodger Stadium", - "link": "/api/v1/venues/22" - }, - "springVenue": { - "id": 3809, - "link": "/api/v1/venues/3809" - }, - "teamCode": "lan", - "fileCode": "la", - "abbreviation": "LAD", - "teamName": "Dodgers", - "locationName": "Los Angeles", - "firstYearOfPlay": "1884", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "division": { - "id": 203, - "name": "National League West", - "link": "/api/v1/divisions/203" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "LA Dodgers", - "franchiseName": "Los Angeles", - "clubName": "Dodgers", - "active": true - }, - "primaryPosition": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "useName": "Cody", - "useLastName": "Bellinger", - "middleName": "James", - "boxscoreName": "Bellinger", - "nickName": "Belli", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2013, - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 89.6, - "minValue": 34.5, - "maxValue": 112.8, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355", - "firstName": "Cody", - "lastName": "Bellinger", - "primaryPosition": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - } - }, - "gameType": "R", - "numOccurrences": 336 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 404, - "minValue": 351, - "maxValue": 447, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355", - "firstName": "Cody", - "lastName": "Bellinger", - "primaryPosition": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - } - }, - "gameType": "R", - "numOccurrences": 38 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 132, - "groundOuts": 84, - "airOuts": 125, - "runs": 87, - "doubles": 26, - "triples": 4, - "homeRuns": 39, - "strikeOuts": 146, - "baseOnBalls": 64, - "intentionalWalks": 13, - "hits": 128, - "hitByPitch": 1, - "avg": ".267", - "atBats": 480, - "obp": ".352", - "slg": ".581", - "ops": ".933", - "caughtStealing": 3, - "stolenBases": 10, - "stolenBasePercentage": ".769", - "groundIntoDoublePlay": 5, - "numberOfPitches": 2205, - "plateAppearances": 548, - "totalBases": 279, - "rbi": 97, - "leftOnBase": 224, - "sacBunts": 0, - "sacFlies": 3, - "babip": ".299", - "groundOutsToAirouts": "0.67", - "catchersInterference": 0, - "atBatsPerHomeRun": "12.31" - }, - "team": { - "id": 119, - "name": "Los Angeles Dodgers", - "link": "/api/v1/teams/119" - }, - "player": { - "id": 641355, - "fullName": "Cody Bellinger", - "link": "/api/v1/people/641355" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2017-04-25", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "L", - "description": "Left" - }, - "nameFirstLast": "Cody Bellinger", - "nameSlug": "cody-bellinger-641355", - "firstLastName": "Cody Bellinger", - "lastFirstName": "Bellinger, Cody", - "lastInitName": "Bellinger, C", - "initLastName": "C Bellinger", - "fullFMLName": "Cody James Bellinger", - "fullLFMName": "Bellinger, Cody James", - "strikeZoneTop": 3.86, - "strikeZoneBottom": 1.77 - }, - { - "id": 519317, - "fullName": "Giancarlo Stanton", - "link": "/api/v1/people/519317", - "firstName": "Giancarlo", - "lastName": "Stanton", - "primaryNumber": "27", - "birthDate": "1989-11-08", - "currentAge": 33, - "birthCity": "Panorama", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "6' 6\"", - "weight": 245, - "active": true, - "currentTeam": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147", - "season": 2022, - "venue": { - "id": 3313, - "name": "Yankee Stadium", - "link": "/api/v1/venues/3313" - }, - "springVenue": { - "id": 2523, - "link": "/api/v1/venues/2523" - }, - "teamCode": "nya", - "fileCode": "nyy", - "abbreviation": "NYY", - "teamName": "Yankees", - "locationName": "Bronx", - "firstYearOfPlay": "1903", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "NY Yankees", - "franchiseName": "New York", - "clubName": "Yankees", - "active": true - }, - "primaryPosition": { - "code": "O", - "name": "Outfield", - "type": "Outfielder", - "abbreviation": "OF" - }, - "useName": "Giancarlo", - "useLastName": "Stanton", - "middleName": "Cruz-Michael", - "boxscoreName": "Stanton", - "nickName": "Parmigiancarlo", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2007, - "pronunciation": "Zhon-car-lo", - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 91.9, - "minValue": 41.1, - "maxValue": 122.2, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 519317, - "fullName": "Giancarlo Stanton", - "link": "/api/v1/people/519317", - "firstName": "Giancarlo", - "lastName": "Stanton", - "primaryPosition": { - "code": "O", - "name": "Outfield", - "type": "Outfielder", - "abbreviation": "OF" - } - }, - "gameType": "R", - "numOccurrences": 436 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 418, - "minValue": 346, - "maxValue": 468, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 519317, - "fullName": "Giancarlo Stanton", - "link": "/api/v1/people/519317", - "firstName": "Giancarlo", - "lastName": "Stanton", - "primaryPosition": { - "code": "O", - "name": "Outfield", - "type": "Outfielder", - "abbreviation": "OF" - } - }, - "gameType": "R", - "numOccurrences": 59 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 159, - "groundOuts": 152, - "airOuts": 117, - "runs": 123, - "doubles": 32, - "triples": 0, - "homeRuns": 59, - "strikeOuts": 163, - "baseOnBalls": 85, - "intentionalWalks": 13, - "hits": 168, - "hitByPitch": 7, - "avg": ".281", - "atBats": 597, - "obp": ".376", - "slg": ".631", - "ops": "1.007", - "caughtStealing": 2, - "stolenBases": 2, - "stolenBasePercentage": ".500", - "groundIntoDoublePlay": 13, - "numberOfPitches": 2736, - "plateAppearances": 692, - "totalBases": 377, - "rbi": 132, - "leftOnBase": 239, - "sacBunts": 0, - "sacFlies": 3, - "babip": ".288", - "groundOutsToAirouts": "1.30", - "catchersInterference": 0, - "atBatsPerHomeRun": "10.12" - }, - "team": { - "id": 146, - "name": "Miami Marlins", - "link": "/api/v1/teams/146" - }, - "player": { - "id": 519317, - "fullName": "Giancarlo Stanton", - "link": "/api/v1/people/519317" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2010-06-08", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Giancarlo Stanton", - "nameSlug": "giancarlo-stanton-519317", - "firstLastName": "Giancarlo Stanton", - "lastFirstName": "Stanton, Giancarlo", - "lastInitName": "Stanton, G", - "initLastName": "G Stanton", - "fullFMLName": "Giancarlo Cruz-Michael Stanton", - "fullLFMName": "Stanton, Giancarlo Cruz-Michael", - "strikeZoneTop": 3.62, - "strikeZoneBottom": 1.75 - }, - { - "id": 519058, - "fullName": "Mike Moustakas", - "link": "/api/v1/people/519058", - "firstName": "Michael", - "lastName": "Moustakas", - "primaryNumber": "9", - "birthDate": "1988-09-11", - "currentAge": 34, - "birthCity": "Los Angeles", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "6' 0\"", - "weight": 225, - "active": true, - "currentTeam": { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 113, - "name": "Cincinnati Reds", - "link": "/api/v1/teams/113", - "season": 2022, - "venue": { - "id": 2602, - "name": "Great American Ball Park", - "link": "/api/v1/venues/2602" - }, - "springVenue": { - "id": 3834, - "link": "/api/v1/venues/3834" - }, - "teamCode": "cin", - "fileCode": "cin", - "abbreviation": "CIN", - "teamName": "Reds", - "locationName": "Cincinnati", - "firstYearOfPlay": "1882", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "division": { - "id": 205, - "name": "National League Central", - "link": "/api/v1/divisions/205" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Cincinnati", - "franchiseName": "Cincinnati", - "clubName": "Reds", - "active": true - }, - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - }, - "useName": "Mike", - "useLastName": "Moustakas", - "middleName": "Christopher", - "boxscoreName": "Moustakas", - "nickName": "Moose", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2007, - "pronunciation": "moo-STOCK-us", - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 87.2, - "minValue": 36.8, - "maxValue": 112.9, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 519058, - "fullName": "Mike Moustakas", - "link": "/api/v1/people/519058", - "firstName": "Mike", - "lastName": "Moustakas", - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - } - }, - "gameType": "R", - "numOccurrences": 466 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 397, - "minValue": 345, - "maxValue": 440, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 519058, - "fullName": "Mike Moustakas", - "link": "/api/v1/people/519058", - "firstName": "Mike", - "lastName": "Moustakas", - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - } - }, - "gameType": "R", - "numOccurrences": 38 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 148, - "groundOuts": 124, - "airOuts": 192, - "runs": 75, - "doubles": 24, - "triples": 0, - "homeRuns": 38, - "strikeOuts": 94, - "baseOnBalls": 34, - "intentionalWalks": 7, - "hits": 151, - "hitByPitch": 3, - "avg": ".272", - "atBats": 555, - "obp": ".314", - "slg": ".521", - "ops": ".835", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 18, - "numberOfPitches": 2240, - "plateAppearances": 598, - "totalBases": 289, - "rbi": 85, - "leftOnBase": 191, - "sacBunts": 0, - "sacFlies": 6, - "babip": ".263", - "groundOutsToAirouts": "0.65", - "catchersInterference": 0, - "atBatsPerHomeRun": "14.60" - }, - "team": { - "id": 118, - "name": "Kansas City Royals", - "link": "/api/v1/teams/118" - }, - "player": { - "id": 519058, - "fullName": "Mike Moustakas", - "link": "/api/v1/people/519058" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2011-06-10", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Mike Moustakas", - "nameSlug": "mike-moustakas-519058", - "firstLastName": "Mike Moustakas", - "lastFirstName": "Moustakas, Mike", - "lastInitName": "Moustakas, M", - "initLastName": "M Moustakas", - "fullFMLName": "Michael Christopher Moustakas", - "fullLFMName": "Moustakas, Michael Christopher", - "strikeZoneTop": 3.4, - "strikeZoneBottom": 1.6 - }, - { - "id": 453568, - "fullName": "Charlie Blackmon", - "link": "/api/v1/people/453568", - "firstName": "Charles", - "lastName": "Blackmon", - "primaryNumber": "19", - "birthDate": "1986-07-01", - "currentAge": 36, - "birthCity": "Dallas", - "birthStateProvince": "TX", - "birthCountry": "USA", - "height": "6' 3\"", - "weight": 221, - "active": true, - "currentTeam": { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 115, - "name": "Colorado Rockies", - "link": "/api/v1/teams/115", - "season": 2022, - "venue": { - "id": 19, - "name": "Coors Field", - "link": "/api/v1/venues/19" - }, - "springVenue": { - "id": 4249, - "link": "/api/v1/venues/4249" - }, - "teamCode": "col", - "fileCode": "col", - "abbreviation": "COL", - "teamName": "Rockies", - "locationName": "Denver", - "firstYearOfPlay": "1992", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "division": { - "id": 203, - "name": "National League West", - "link": "/api/v1/divisions/203" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Colorado", - "franchiseName": "Colorado", - "clubName": "Rockies", - "active": true - }, - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - }, - "useName": "Charlie", - "useLastName": "Blackmon", - "middleName": "Cobb", - "boxscoreName": "Blackmon", - "nickName": "Chuck Nazty", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2008, - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 87.2, - "minValue": 33.6, - "maxValue": 110.8, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 453568, - "fullName": "Charlie Blackmon", - "link": "/api/v1/people/453568", - "firstName": "Charlie", - "lastName": "Blackmon", - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - } - }, - "gameType": "R", - "numOccurrences": 510 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 408, - "minValue": 312, - "maxValue": 477, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 453568, - "fullName": "Charlie Blackmon", - "link": "/api/v1/people/453568", - "firstName": "Charlie", - "lastName": "Blackmon", - "primaryPosition": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - } - }, - "gameType": "R", - "numOccurrences": 34 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 159, - "groundOuts": 149, - "airOuts": 153, - "runs": 137, - "doubles": 35, - "triples": 14, - "homeRuns": 37, - "strikeOuts": 135, - "baseOnBalls": 65, - "intentionalWalks": 9, - "hits": 213, - "hitByPitch": 10, - "avg": ".331", - "atBats": 644, - "obp": ".399", - "slg": ".601", - "ops": "1.000", - "caughtStealing": 10, - "stolenBases": 14, - "stolenBasePercentage": ".583", - "groundIntoDoublePlay": 4, - "numberOfPitches": 2884, - "plateAppearances": 725, - "totalBases": 387, - "rbi": 104, - "leftOnBase": 150, - "sacBunts": 3, - "sacFlies": 3, - "babip": ".371", - "groundOutsToAirouts": "0.97", - "catchersInterference": 0, - "atBatsPerHomeRun": "17.40" - }, - "team": { - "id": 115, - "name": "Colorado Rockies", - "link": "/api/v1/teams/115" - }, - "player": { - "id": 453568, - "fullName": "Charlie Blackmon", - "link": "/api/v1/people/453568" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2011-06-07", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "L", - "description": "Left" - }, - "nameFirstLast": "Charlie Blackmon", - "nameSlug": "charlie-blackmon-453568", - "firstLastName": "Charlie Blackmon", - "lastFirstName": "Blackmon, Charlie", - "lastInitName": "Blackmon, C", - "initLastName": "C Blackmon", - "fullFMLName": "Charles Cobb Blackmon", - "fullLFMName": "Blackmon, Charles Cobb", - "strikeZoneTop": 3.67, - "strikeZoneBottom": 1.69 - }, - { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142", - "firstName": "Gary", - "lastName": "Sanchez", - "primaryNumber": "24", - "birthDate": "1992-12-02", - "currentAge": 30, - "birthCity": "Santo Domingo", - "birthCountry": "Dominican Republic", - "height": "6' 2\"", - "weight": 230, - "active": true, - "currentTeam": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 142, - "name": "Minnesota Twins", - "link": "/api/v1/teams/142", - "season": 2022, - "venue": { - "id": 3312, - "name": "Target Field", - "link": "/api/v1/venues/3312" - }, - "springVenue": { - "id": 2862, - "link": "/api/v1/venues/2862" - }, - "teamCode": "min", - "fileCode": "min", - "abbreviation": "MIN", - "teamName": "Twins", - "locationName": "Minneapolis", - "firstYearOfPlay": "1901", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Minnesota", - "franchiseName": "Minnesota", - "clubName": "Twins", - "active": true - }, - "primaryPosition": { - "code": "2", - "name": "Catcher", - "type": "Catcher", - "abbreviation": "C" - }, - "useName": "Gary", - "useLastName": "Sanchez", - "boxscoreName": "Sanchez", - "nickName": "Kraken", - "gender": "M", - "nameMatrilineal": "Herrera", - "isPlayer": true, - "isVerified": true, - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 90.5, - "minValue": 20.8, - "maxValue": 115.7, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142", - "firstName": "Gary", - "lastName": "Sanchez", - "primaryPosition": { - "code": "2", - "name": "Catcher", - "type": "Catcher", - "abbreviation": "C" - } - }, - "gameType": "R", - "numOccurrences": 356 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 416, - "minValue": 357, - "maxValue": 493, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142", - "firstName": "Gary", - "lastName": "Sanchez", - "primaryPosition": { - "code": "2", - "name": "Catcher", - "type": "Catcher", - "abbreviation": "C" - } - }, - "gameType": "R", - "numOccurrences": 32 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 122, - "groundOuts": 115, - "airOuts": 109, - "runs": 79, - "doubles": 20, - "triples": 0, - "homeRuns": 33, - "strikeOuts": 120, - "baseOnBalls": 40, - "intentionalWalks": 1, - "hits": 131, - "hitByPitch": 10, - "avg": ".278", - "atBats": 471, - "obp": ".345", - "slg": ".531", - "ops": ".876", - "caughtStealing": 1, - "stolenBases": 2, - "stolenBasePercentage": ".667", - "groundIntoDoublePlay": 9, - "numberOfPitches": 2031, - "plateAppearances": 525, - "totalBases": 250, - "rbi": 90, - "leftOnBase": 224, - "sacBunts": 0, - "sacFlies": 4, - "babip": ".304", - "groundOutsToAirouts": "1.06", - "catchersInterference": 0, - "atBatsPerHomeRun": "14.27" - }, - "team": { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - "player": { - "id": 596142, - "fullName": "Gary Sanchez", - "link": "/api/v1/people/596142" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2015-10-03", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Gary Sanchez", - "nameSlug": "gary-sanchez-596142", - "firstLastName": "Gary Sanchez", - "lastFirstName": "Sanchez, Gary", - "lastInitName": "Sanchez, G", - "initLastName": "G Sanchez", - "fullFMLName": "Gary Sanchez", - "fullLFMName": "Sanchez, Gary", - "strikeZoneTop": 3.18, - "strikeZoneBottom": 1.55 - }, - { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934", - "firstName": "Miguel", - "lastName": "Sano", - "primaryNumber": "22", - "birthDate": "1993-05-11", - "currentAge": 29, - "birthCity": "San Pedro de Macoris", - "birthCountry": "Dominican Republic", - "height": "6' 4\"", - "weight": 272, - "active": true, - "currentTeam": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 142, - "name": "Minnesota Twins", - "link": "/api/v1/teams/142", - "season": 2022, - "venue": { - "id": 3312, - "name": "Target Field", - "link": "/api/v1/venues/3312" - }, - "springVenue": { - "id": 2862, - "link": "/api/v1/venues/2862" - }, - "teamCode": "min", - "fileCode": "min", - "abbreviation": "MIN", - "teamName": "Twins", - "locationName": "Minneapolis", - "firstYearOfPlay": "1901", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Minnesota", - "franchiseName": "Minnesota", - "clubName": "Twins", - "active": true - }, - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "useName": "Miguel", - "useLastName": "Sanó", - "middleName": "Angel", - "boxscoreName": "Sanó", - "nickName": "Boqueton", - "gender": "M", - "nameMatrilineal": "Jean", - "isPlayer": true, - "isVerified": true, - "pronunciation": "sa-NO", - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 91.7, - "minValue": 31.2, - "maxValue": 114.6, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934", - "firstName": "Miguel", - "lastName": "Sano", - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - } - }, - "gameType": "R", - "numOccurrences": 254 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 413, - "minValue": 362, - "maxValue": 469, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934", - "firstName": "Miguel", - "lastName": "Sano", - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - } - }, - "gameType": "R", - "numOccurrences": 26 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 114, - "groundOuts": 69, - "airOuts": 71, - "runs": 75, - "doubles": 15, - "triples": 2, - "homeRuns": 28, - "strikeOuts": 173, - "baseOnBalls": 54, - "intentionalWalks": 5, - "hits": 112, - "hitByPitch": 4, - "avg": ".264", - "atBats": 424, - "obp": ".352", - "slg": ".507", - "ops": ".859", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 12, - "numberOfPitches": 1974, - "plateAppearances": 483, - "totalBases": 215, - "rbi": 77, - "leftOnBase": 216, - "sacBunts": 0, - "sacFlies": 1, - "babip": ".375", - "groundOutsToAirouts": "0.97", - "catchersInterference": 0, - "atBatsPerHomeRun": "15.14" - }, - "team": { - "id": 142, - "name": "Minnesota Twins", - "link": "/api/v1/teams/142" - }, - "player": { - "id": 593934, - "fullName": "Miguel Sano", - "link": "/api/v1/people/593934" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2015-07-02", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Miguel Sano", - "nameSlug": "miguel-sano-593934", - "firstLastName": "Miguel Sanó", - "lastFirstName": "Sanó, Miguel", - "lastInitName": "Sanó, M", - "initLastName": "M Sanó", - "fullFMLName": "Miguel Angel Sanó", - "fullLFMName": "Sanó, Miguel Angel", - "strikeZoneTop": 3.66, - "strikeZoneBottom": 1.79 - }, - { - "id": 571506, - "fullName": "Justin Bour", - "link": "/api/v1/people/571506", - "firstName": "Justin", - "lastName": "Bour", - "primaryNumber": "35", - "birthDate": "1988-05-28", - "currentAge": 34, - "birthCity": "Washington", - "birthStateProvince": "DC", - "birthCountry": "USA", - "height": "6' 4\"", - "weight": 270, - "active": true, - "currentTeam": { - "allStarStatus": "N", - "id": 532, - "name": "Diablos Rojos del Mexico", - "link": "/api/v1/teams/532", - "season": 2022, - "venue": { - "id": 5340, - "name": "Estadio Alfredo Harp Helu", - "link": "/api/v1/venues/5340" - }, - "teamCode": "mxo", - "fileCode": "t532", - "abbreviation": "MEX", - "teamName": "Diablos Rojos", - "locationName": "Mexico City", - "firstYearOfPlay": "1940", - "league": { - "id": 125, - "name": "Mexican League", - "link": "/api/v1/league/125" - }, - "division": { - "id": 223, - "name": "Mexican League Sur", - "link": "/api/v1/divisions/223" - }, - "sport": { - "id": 23, - "link": "/api/v1/sports/23", - "name": "Independent Leagues" - }, - "shortName": "Mexico", - "parentOrgName": "Office of the Commissioner", - "parentOrgId": 11, - "franchiseName": "Mexico", - "clubName": "Diablos Rojos", - "active": true - }, - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "useName": "Justin", - "useLastName": "Bour", - "middleName": "James", - "boxscoreName": "Bour", - "nickName": "JB", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2009, - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 89.2, - "minValue": 43.7, - "maxValue": 114.8, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 571506, - "fullName": "Justin Bour", - "link": "/api/v1/people/571506", - "firstName": "Justin", - "lastName": "Bour", - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - } - }, - "gameType": "R", - "numOccurrences": 285 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 399, - "minValue": 345, - "maxValue": 446, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 571506, - "fullName": "Justin Bour", - "link": "/api/v1/people/571506", - "firstName": "Justin", - "lastName": "Bour", - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - } - }, - "gameType": "R", - "numOccurrences": 23 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 108, - "groundOuts": 99, - "airOuts": 78, - "runs": 52, - "doubles": 18, - "triples": 0, - "homeRuns": 25, - "strikeOuts": 95, - "baseOnBalls": 47, - "intentionalWalks": 7, - "hits": 109, - "hitByPitch": 1, - "avg": ".289", - "atBats": 377, - "obp": ".366", - "slg": ".536", - "ops": ".902", - "caughtStealing": 0, - "stolenBases": 1, - "stolenBasePercentage": "1.000", - "groundIntoDoublePlay": 10, - "numberOfPitches": 1744, - "plateAppearances": 429, - "totalBases": 202, - "rbi": 83, - "leftOnBase": 171, - "sacBunts": 0, - "sacFlies": 4, - "babip": ".322", - "groundOutsToAirouts": "1.27", - "catchersInterference": 0, - "atBatsPerHomeRun": "15.08" - }, - "team": { - "id": 146, - "name": "Miami Marlins", - "link": "/api/v1/teams/146" - }, - "player": { - "id": 571506, - "fullName": "Justin Bour", - "link": "/api/v1/people/571506" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2014-06-05", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Justin Bour", - "nameSlug": "justin-bour-571506", - "firstLastName": "Justin Bour", - "lastFirstName": "Bour, Justin", - "lastInitName": "Bour, J", - "initLastName": "J Bour", - "fullFMLName": "Justin James Bour", - "fullLFMName": "Bour, Justin James", - "strikeZoneTop": 3.549, - "strikeZoneBottom": 1.627 - }, - { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450", - "firstName": "Aaron", - "lastName": "Judge", - "primaryNumber": "99", - "birthDate": "1992-04-26", - "currentAge": 30, - "birthCity": "Linden", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "6' 7\"", - "weight": 282, - "active": true, - "currentTeam": { - "springLeague": { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL" - }, - "allStarStatus": "N", - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147", - "season": 2022, - "venue": { - "id": 3313, - "name": "Yankee Stadium", - "link": "/api/v1/venues/3313" - }, - "springVenue": { - "id": 2523, - "link": "/api/v1/venues/2523" - }, - "teamCode": "nya", - "fileCode": "nyy", - "abbreviation": "NYY", - "teamName": "Yankees", - "locationName": "Bronx", - "firstYearOfPlay": "1903", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "NY Yankees", - "franchiseName": "New York", - "clubName": "Yankees", - "active": true - }, - "primaryPosition": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - }, - "useName": "Aaron", - "useLastName": "Judge", - "middleName": "James", - "boxscoreName": "Judge", - "nickName": "Baj", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2013, - "stats": [ - { - "type": { - "displayName": "metricAverages" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "launchSpeed", - "averageValue": 94.8, - "minValue": 33.7, - "maxValue": 121.1, - "unit": "MPH", - "metricId": 1003 - } - }, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450", - "firstName": "Aaron", - "lastName": "Judge", - "primaryPosition": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - } - }, - "gameType": "R", - "numOccurrences": 338 - }, - { - "season": "2017", - "stat": { - "metric": { - "group": "hitting", - "name": "hrDistance", - "averageValue": 412, - "minValue": 337, - "maxValue": 496, - "unit": "FT", - "metricId": 1031 - } - }, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450", - "firstName": "Aaron", - "lastName": "Judge", - "primaryPosition": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - } - }, - "gameType": "R", - "numOccurrences": 50 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2017", - "stat": { - "gamesPlayed": 155, - "groundOuts": 85, - "airOuts": 99, - "runs": 128, - "doubles": 24, - "triples": 3, - "homeRuns": 52, - "strikeOuts": 208, - "baseOnBalls": 127, - "intentionalWalks": 11, - "hits": 154, - "hitByPitch": 5, - "avg": ".284", - "atBats": 542, - "obp": ".422", - "slg": ".627", - "ops": "1.049", - "caughtStealing": 4, - "stolenBases": 9, - "stolenBasePercentage": ".692", - "groundIntoDoublePlay": 15, - "numberOfPitches": 2989, - "plateAppearances": 678, - "totalBases": 340, - "rbi": 114, - "leftOnBase": 248, - "sacBunts": 0, - "sacFlies": 4, - "babip": ".357", - "groundOutsToAirouts": "0.86", - "catchersInterference": 0, - "atBatsPerHomeRun": "10.42" - }, - "team": { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - "player": { - "id": 592450, - "fullName": "Aaron Judge", - "link": "/api/v1/people/592450" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - } - ], - "mlbDebutDate": "2016-08-13", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Aaron Judge", - "nameSlug": "aaron-judge-592450", - "firstLastName": "Aaron Judge", - "lastFirstName": "Judge, Aaron", - "lastInitName": "Judge, A", - "initLastName": "A Judge", - "fullFMLName": "Aaron James Judge", - "fullLFMName": "Judge, Aaron James", - "strikeZoneTop": 3.93, - "strikeZoneBottom": 1.84 - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/leagues/league.json b/tests/mock_tests/mock_json/leagues/league.json deleted file mode 100644 index 133458f9..00000000 --- a/tests/mock_tests/mock_json/leagues/league.json +++ /dev/null @@ -1,50 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "leagues": [ - { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103", - "abbreviation": "AL", - "nameShort": "American", - "seasonState": "offseason", - "hasWildCard": true, - "hasSplitSeason": false, - "numGames": 162, - "hasPlayoffPoints": false, - "numTeams": 15, - "numWildcardTeams": 3, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-01-01", - "preSeasonEndDate": "2022-03-16", - "seasonStartDate": "2022-03-17", - "springStartDate": "2022-03-17", - "springEndDate": "2022-04-06", - "regularSeasonStartDate": "2022-04-07", - "lastDate1stHalf": "2022-07-17", - "allStarDate": "2022-07-19", - "firstDate2ndHalf": "2022-07-21", - "regularSeasonEndDate": "2022-10-05", - "postSeasonStartDate": "2022-10-07", - "postSeasonEndDate": "2022-11-05", - "seasonEndDate": "2022-11-05", - "offseasonStartDate": "2022-11-06", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "P", - "gameLevelGamedayType": "P", - "qualifierPlateAppearances": 3.1, - "qualifierOutsPitched": 3 - }, - "season": "2022", - "orgCode": "AL", - "conferencesInUse": false, - "divisionsInUse": true, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "sortOrder": 21, - "active": true - }] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/leagues/leagues.json b/tests/mock_tests/mock_json/leagues/leagues.json deleted file mode 100644 index 1f7d0382..00000000 --- a/tests/mock_tests/mock_json/leagues/leagues.json +++ /dev/null @@ -1,193 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "leagues": [ - { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103", - "abbreviation": "AL", - "nameShort": "American", - "seasonState": "offseason", - "hasWildCard": true, - "hasSplitSeason": false, - "numGames": 162, - "hasPlayoffPoints": false, - "numTeams": 15, - "numWildcardTeams": 3, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-01-01", - "preSeasonEndDate": "2022-03-16", - "seasonStartDate": "2022-03-17", - "springStartDate": "2022-03-17", - "springEndDate": "2022-04-06", - "regularSeasonStartDate": "2022-04-07", - "lastDate1stHalf": "2022-07-17", - "allStarDate": "2022-07-19", - "firstDate2ndHalf": "2022-07-21", - "regularSeasonEndDate": "2022-10-05", - "postSeasonStartDate": "2022-10-07", - "postSeasonEndDate": "2022-11-05", - "seasonEndDate": "2022-11-05", - "offseasonStartDate": "2022-11-06", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "P", - "gameLevelGamedayType": "P", - "qualifierPlateAppearances": 3.1, - "qualifierOutsPitched": 3 - }, - "season": "2022", - "orgCode": "AL", - "conferencesInUse": false, - "divisionsInUse": true, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "sortOrder": 21, - "active": true - }, - { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104", - "abbreviation": "NL", - "nameShort": "National", - "seasonState": "offseason", - "hasWildCard": true, - "hasSplitSeason": false, - "numGames": 162, - "hasPlayoffPoints": false, - "numTeams": 15, - "numWildcardTeams": 3, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-01-01", - "preSeasonEndDate": "2022-03-16", - "seasonStartDate": "2022-03-17", - "springStartDate": "2022-03-17", - "springEndDate": "2022-04-06", - "regularSeasonStartDate": "2022-04-07", - "lastDate1stHalf": "2022-07-17", - "allStarDate": "2022-07-19", - "firstDate2ndHalf": "2022-07-21", - "regularSeasonEndDate": "2022-10-05", - "postSeasonStartDate": "2022-10-07", - "postSeasonEndDate": "2022-11-05", - "seasonEndDate": "2022-11-05", - "offseasonStartDate": "2022-11-06", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "P", - "gameLevelGamedayType": "P", - "qualifierPlateAppearances": 3.1, - "qualifierOutsPitched": 3 - }, - "season": "2022", - "orgCode": "NL", - "conferencesInUse": false, - "divisionsInUse": true, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "sortOrder": 31, - "active": true - }, - { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL", - "nameShort": "Cactus", - "seasonState": "offseason", - "hasWildCard": false, - "hasSplitSeason": false, - "hasPlayoffPoints": false, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-03-17", - "preSeasonEndDate": "2022-04-06", - "seasonStartDate": "2022-03-17", - "springStartDate": "2022-03-17", - "springEndDate": "2022-04-06", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "F", - "gameLevelGamedayType": "F" - }, - "season": "2022", - "orgCode": "CL", - "conferencesInUse": false, - "divisionsInUse": false, - "sortOrder": 51, - "active": true - }, - { - "id": 115, - "name": "Grapefruit League", - "link": "/api/v1/league/115", - "abbreviation": "GL", - "nameShort": "Grapefruit", - "seasonState": "offseason", - "hasWildCard": false, - "hasSplitSeason": false, - "hasPlayoffPoints": false, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-03-17", - "preSeasonEndDate": "2022-04-06", - "seasonStartDate": "2022-03-17", - "springStartDate": "2022-03-17", - "springEndDate": "2022-04-06", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "F", - "gameLevelGamedayType": "F" - }, - "season": "2022", - "orgCode": "GL", - "conferencesInUse": false, - "divisionsInUse": false, - "sortOrder": 52, - "active": true - }, - { - "id": 117, - "name": "International League", - "link": "/api/v1/league/117", - "abbreviation": "INT", - "nameShort": "International", - "seasonState": "offseason", - "hasWildCard": false, - "hasSplitSeason": false, - "numGames": 150, - "hasPlayoffPoints": false, - "numTeams": 20, - "seasonDateInfo": { - "seasonId": "2022", - "preSeasonStartDate": "2022-01-01", - "preSeasonEndDate": "2022-03-15", - "seasonStartDate": "2022-04-05", - "regularSeasonStartDate": "2022-04-05", - "regularSeasonEndDate": "2022-09-28", - "postSeasonStartDate": "2022-09-30", - "postSeasonEndDate": "2022-10-01", - "seasonEndDate": "2022-10-01", - "offseasonStartDate": "2022-10-02", - "offSeasonEndDate": "2022-12-31", - "seasonLevelGamedayType": "Y", - "gameLevelGamedayType": "Y", - "qualifierPlateAppearances": 2.7, - "qualifierOutsPitched": 2.4 - }, - "season": "2022", - "orgCode": "INT", - "conferencesInUse": false, - "divisionsInUse": true, - "sport": { - "id": 11, - "link": "/api/v1/sports/11" - }, - "sortOrder": 111, - "active": true - } -] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/people/person.json b/tests/mock_tests/mock_json/people/person.json deleted file mode 100644 index adc68840..00000000 --- a/tests/mock_tests/mock_json/people/person.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "people": [ - { - "id": 676265, - "fullName": "Cory Abbott", - "link": "/api/v1/people/676265", - "firstName": "Cory", - "lastName": "Abbott", - "primaryNumber": "77", - "birthDate": "1995-09-20", - "currentAge": 27, - "birthCity": "San Diego", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "6' 1\"", - "weight": 210, - "active": true, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Cory", - "middleName": "James", - "boxscoreName": "Abbott", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2017, - "mlbDebutDate": "2021-06-05", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Cory Abbott", - "nameSlug": "cory-abbott-676265", - "firstLastName": "Cory Abbott", - "lastFirstName": "Abbott, Cory", - "lastInitName": "Abbott, C", - "initLastName": "C Abbott", - "fullFMLName": "Cory James Abbott", - "fullLFMName": "Abbott, Cory James", - "strikeZoneTop": 3.411, - "strikeZoneBottom": 1.565 - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/people/players.json b/tests/mock_tests/mock_json/people/players.json deleted file mode 100644 index deddac1f..00000000 --- a/tests/mock_tests/mock_json/people/players.json +++ /dev/null @@ -1,573 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "people": [ - { - "id": 676265, - "fullName": "Cory Abbott", - "link": "/api/v1/people/676265", - "firstName": "Cory", - "lastName": "Abbott", - "primaryNumber": "77", - "birthDate": "1995-09-20", - "currentAge": 27, - "birthCity": "San Diego", - "birthStateProvince": "CA", - "birthCountry": "USA", - "height": "6' 1\"", - "weight": 210, - "active": true, - "currentTeam": { - "id": 120, - "link": "/api/v1/teams/120" - }, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Cory", - "middleName": "James", - "boxscoreName": "Abbott", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2017, - "mlbDebutDate": "2021-06-05", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Cory Abbott", - "nameSlug": "cory-abbott-676265", - "firstLastName": "Cory Abbott", - "lastFirstName": "Abbott, Cory", - "lastInitName": "Abbott, C", - "initLastName": "C Abbott", - "fullFMLName": "Cory James Abbott", - "fullLFMName": "Abbott, Cory James", - "strikeZoneTop": 3.411, - "strikeZoneBottom": 1.565 - }, - { - "id": 682928, - "fullName": "CJ Abrams", - "link": "/api/v1/people/682928", - "firstName": "Paul", - "lastName": "Abrams", - "primaryNumber": "5", - "birthDate": "2000-10-03", - "currentAge": 22, - "birthCity": "Alpharetta", - "birthStateProvince": "GA", - "birthCountry": "USA", - "height": "6' 2\"", - "weight": 185, - "active": true, - "currentTeam": { - "id": 120, - "link": "/api/v1/teams/120" - }, - "primaryPosition": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "useName": "CJ", - "middleName": "Christopher", - "boxscoreName": "Abrams", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2019, - "mlbDebutDate": "2022-04-08", - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "CJ Abrams", - "nameSlug": "cj-abrams-682928", - "firstLastName": "CJ Abrams", - "lastFirstName": "Abrams, CJ", - "lastInitName": "Abrams, C", - "initLastName": "C Abrams", - "fullFMLName": "Paul Christopher Abrams", - "fullLFMName": "Abrams, Paul Christopher", - "strikeZoneTop": 3.53, - "strikeZoneBottom": 1.62 - }, - { - "id": 656061, - "fullName": "Albert Abreu", - "link": "/api/v1/people/656061", - "firstName": "Albert", - "lastName": "Abreu", - "primaryNumber": "84", - "birthDate": "1995-09-26", - "currentAge": 27, - "birthCity": "Guayubin", - "birthCountry": "Dominican Republic", - "height": "6' 2\"", - "weight": 190, - "active": true, - "currentTeam": { - "id": 147, - "link": "/api/v1/teams/147" - }, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Albert", - "middleName": "Enmanuel", - "boxscoreName": "Abreu, A", - "gender": "M", - "nameMatrilineal": "Dias", - "isPlayer": true, - "isVerified": true, - "mlbDebutDate": "2020-08-08", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Albert Abreu", - "nameSlug": "albert-abreu-656061", - "firstLastName": "Albert Abreu", - "lastFirstName": "Abreu, Albert", - "lastInitName": "Abreu, A", - "initLastName": "A Abreu", - "fullFMLName": "Albert Enmanuel Abreu", - "fullLFMName": "Abreu, Albert Enmanuel", - "strikeZoneTop": 3.467, - "strikeZoneBottom": 1.589 - }, - { - "id": 650556, - "fullName": "Bryan Abreu", - "link": "/api/v1/people/650556", - "firstName": "Bryan", - "lastName": "Abreu", - "primaryNumber": "52", - "birthDate": "1997-04-22", - "currentAge": 25, - "birthCity": "Santo Domingo Centro", - "birthCountry": "Dominican Republic", - "height": "6' 1\"", - "weight": 225, - "active": true, - "currentTeam": { - "id": 117, - "link": "/api/v1/teams/117" - }, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Bryan", - "middleName": "Enrique", - "boxscoreName": "Abreu, B", - "gender": "M", - "nameMatrilineal": "Jimenez", - "isPlayer": true, - "isVerified": true, - "mlbDebutDate": "2019-07-31", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Bryan Abreu", - "nameSlug": "bryan-abreu-650556", - "firstLastName": "Bryan Abreu", - "lastFirstName": "Abreu, Bryan", - "lastInitName": "Abreu, B", - "initLastName": "B Abreu", - "fullFMLName": "Bryan Enrique Abreu", - "fullLFMName": "Abreu, Bryan Enrique", - "strikeZoneTop": 3.411, - "strikeZoneBottom": 1.565 - }, - { - "id": 547989, - "fullName": "Jose Abreu", - "link": "/api/v1/people/547989", - "firstName": "Jose", - "lastName": "Abreu", - "primaryNumber": "79", - "birthDate": "1987-01-29", - "currentAge": 35, - "birthCity": "Cienfuegos", - "birthCountry": "Cuba", - "height": "6' 3\"", - "weight": 235, - "active": true, - "currentTeam": { - "id": 145, - "name": "Chicago White Sox", - "link": "/api/v1/teams/145" - }, - "primaryPosition": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "useName": "Jose", - "middleName": "Dariel", - "boxscoreName": "Abreu, J", - "nickName": "Mal Tiempo", - "gender": "M", - "nameMatrilineal": "Correa", - "isPlayer": true, - "isVerified": true, - "pronunciation": "uh-BRAY-you", - "mlbDebutDate": "2014-03-31", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Jose Abreu", - "nameSlug": "jose-abreu-547989", - "firstLastName": "José Abreu", - "lastFirstName": "Abreu, José", - "lastInitName": "Abreu, J", - "initLastName": "J Abreu", - "fullFMLName": "José Dariel Abreu", - "fullLFMName": "Abreu, José Dariel", - "strikeZoneTop": 3.43, - "strikeZoneBottom": 1.57 - }, - { - "id": 677800, - "fullName": "Wilyer Abreu", - "link": "/api/v1/people/677800", - "firstName": "Wilyer", - "lastName": "Abreu", - "birthDate": "1999-06-24", - "currentAge": 23, - "birthCity": "Maracaibo", - "birthCountry": "Venezuela", - "height": "6' 0\"", - "weight": 217, - "active": true, - "currentTeam": { - "id": 111, - "link": "/api/v1/teams/111" - }, - "primaryPosition": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - }, - "useName": "Wilyer", - "middleName": "David", - "boxscoreName": "Abreu", - "gender": "M", - "nameMatrilineal": "Villalobos", - "isPlayer": true, - "isVerified": true, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "L", - "description": "Left" - }, - "nameFirstLast": "Wilyer Abreu", - "nameSlug": "wilyer-abreu-677800", - "firstLastName": "Wilyer Abreu", - "lastFirstName": "Abreu, Wilyer", - "lastInitName": "Abreu, W", - "initLastName": "W Abreu", - "fullFMLName": "Wilyer David Abreu", - "fullLFMName": "Abreu, Wilyer David", - "strikeZoneTop": 3.371, - "strikeZoneBottom": 1.535 - }, - { - "id": 642758, - "fullName": "Domingo Acevedo", - "link": "/api/v1/people/642758", - "firstName": "Domingo", - "lastName": "Acevedo", - "primaryNumber": "68", - "birthDate": "1994-03-06", - "currentAge": 28, - "birthCity": "Villa Los Almacigos", - "birthCountry": "Dominican Republic", - "height": "6' 7\"", - "weight": 240, - "active": true, - "currentTeam": { - "id": 133, - "link": "/api/v1/teams/133" - }, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Domingo", - "middleName": "Antonio", - "boxscoreName": "Acevedo", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "mlbDebutDate": "2021-06-21", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Domingo Acevedo", - "nameSlug": "domingo-acevedo-642758", - "firstLastName": "Domingo Acevedo", - "lastFirstName": "Acevedo, Domingo", - "lastInitName": "Acevedo, D", - "initLastName": "D Acevedo", - "fullFMLName": "Domingo Antonio Acevedo", - "fullLFMName": "Acevedo, Domingo Antonio", - "strikeZoneTop": 3.756, - "strikeZoneBottom": 1.746 - }, - { - "id": 682668, - "fullName": "Luisangel Acuna", - "link": "/api/v1/people/682668", - "firstName": "Luisangel", - "lastName": "Acuna", - "birthDate": "2002-03-12", - "currentAge": 20, - "birthCity": "Caracas", - "birthCountry": "Venezuela", - "height": "5' 10\"", - "weight": 181, - "active": true, - "currentTeam": { - "id": 140, - "link": "/api/v1/teams/140" - }, - "primaryPosition": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "useName": "Luisangel", - "middleName": "Jose", - "boxscoreName": "Acuña", - "nickName": "Jose", - "gender": "M", - "nameMatrilineal": "Cartaya", - "isPlayer": true, - "isVerified": false, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Luisangel Acuna", - "nameSlug": "luisangel-acuna-682668", - "firstLastName": "Luisangel Acuña", - "lastFirstName": "Acuña, Luisangel", - "lastInitName": "Acuña, L", - "initLastName": "Acuña", - "fullFMLName": "Luisangel Jose Acuña", - "fullLFMName": "Acuña, Luisangel Jose", - "strikeZoneTop": 3.301, - "strikeZoneBottom": 1.504 - }, - { - "id": 660670, - "fullName": "Ronald Acuna Jr.", - "link": "/api/v1/people/660670", - "firstName": "Ronald", - "lastName": "Acuna", - "primaryNumber": "13", - "birthDate": "1997-12-18", - "currentAge": 24, - "birthCity": "La Guaira", - "birthCountry": "Venezuela", - "height": "6' 0\"", - "weight": 205, - "active": true, - "currentTeam": { - "id": 144, - "link": "/api/v1/teams/144" - }, - "primaryPosition": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - }, - "useName": "Ronald", - "middleName": "Jose", - "boxscoreName": "Acuña Jr.", - "nickName": "El De La Sabana", - "gender": "M", - "nameMatrilineal": "Blanco", - "isPlayer": true, - "isVerified": true, - "pronunciation": "ah-cuhn-YA", - "mlbDebutDate": "2018-04-25", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Ronald Acuna Jr.", - "nameTitle": "Jr.", - "nameSlug": "ronald-acuna-jr-660670", - "firstLastName": "Ronald Acuña Jr.", - "lastFirstName": "Acuña Jr., Ronald", - "lastInitName": "Acuña Jr., R", - "initLastName": "R Acuña", - "fullFMLName": "Ronald Jose Acuña Jr.", - "fullLFMName": "Acuña Jr., Ronald Jose", - "strikeZoneTop": 3.47, - "strikeZoneBottom": 1.57 - }, - { - "id": 592094, - "fullName": "Jason Adam", - "link": "/api/v1/people/592094", - "firstName": "Jason", - "lastName": "Adam", - "primaryNumber": "47", - "birthDate": "1991-08-04", - "currentAge": 31, - "birthCity": "Omaha", - "birthStateProvince": "NE", - "birthCountry": "USA", - "height": "6' 3\"", - "weight": 229, - "active": true, - "currentTeam": { - "id": 139, - "link": "/api/v1/teams/139" - }, - "primaryPosition": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "useName": "Jason", - "middleName": "Kendall", - "boxscoreName": "Adam", - "gender": "M", - "isPlayer": true, - "isVerified": true, - "draftYear": 2010, - "mlbDebutDate": "2018-05-05", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Jason Adam", - "nameSlug": "jason-adam-592094", - "firstLastName": "Jason Adam", - "lastFirstName": "Adam, Jason", - "lastInitName": "Adam, J", - "initLastName": "J Adam", - "fullFMLName": "Jason Kendall Adam", - "fullLFMName": "Adam, Jason Kendall", - "strikeZoneTop": 3.49, - "strikeZoneBottom": 1.601 - }, - { - "id": 642715, - "fullName": "Willy Adames", - "link": "/api/v1/people/642715", - "firstName": "Willy", - "lastName": "Adames", - "primaryNumber": "27", - "birthDate": "1995-09-02", - "currentAge": 27, - "birthCity": "Santiago", - "birthCountry": "Dominican Republic", - "height": "6' 0\"", - "weight": 210, - "active": true, - "currentTeam": { - "id": 158, - "link": "/api/v1/teams/158" - }, - "primaryPosition": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "useName": "Willy", - "middleName": "Rafael", - "boxscoreName": "Adames", - "nickName": "The Kid", - "gender": "M", - "nameMatrilineal": "Luna", - "isPlayer": true, - "isVerified": true, - "pronunciation": "ah-DAH-mes", - "mlbDebutDate": "2018-05-22", - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - }, - "nameFirstLast": "Willy Adames", - "nameSlug": "willy-adames-642715", - "firstLastName": "Willy Adames", - "lastFirstName": "Adames, Willy", - "lastInitName": "Adames, W", - "initLastName": "W Adames", - "fullFMLName": "Willy Rafael Adames", - "fullLFMName": "Adames, Willy Rafael", - "strikeZoneTop": 3.36, - "strikeZoneBottom": 1.67 - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/response/error_500.json b/tests/mock_tests/mock_json/response/error_500.json deleted file mode 100644 index 6bda141a..00000000 --- a/tests/mock_tests/mock_json/response/error_500.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "messageNumber": 1, - "message": "Internal error occurred", - "timestamp": "2022-11-22T19:11:54.301267Z", - "traceId": "c0587282e9dc12cf7d65306edc0adc08" -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/response/not_found_404.json b/tests/mock_tests/mock_json/response/not_found_404.json deleted file mode 100644 index 1cce98dd..00000000 --- a/tests/mock_tests/mock_json/response/not_found_404.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "messageNumber": 10, - "message": "Object not found", - "timestamp": "2022-11-22T19:02:30.879507Z", - "traceId": null -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/schedule/schedule_date.json b/tests/mock_tests/mock_json/schedule/schedule_date.json deleted file mode 100644 index 4b91e73b..00000000 --- a/tests/mock_tests/mock_json/schedule/schedule_date.json +++ /dev/null @@ -1,716 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "totalItems": 9, - "totalEvents": 0, - "totalGames": 9, - "totalGamesInProgress": 0, - "dates": [ - { - "date": "2022-04-07", - "totalItems": 9, - "totalEvents": 0, - "totalGames": 9, - "totalGamesInProgress": 0, - "games": [ - { - "gamePk": 663178, - "gameGuid": "e1c7256b-9de3-480c-88d5-8673b0d5eb74", - "link": "/api/v1.1/game/663178/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T18:20:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 4, - "team": { - "id": 158, - "name": "Milwaukee Brewers", - "link": "/api/v1/teams/158" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 5, - "team": { - "id": 112, - "name": "Chicago Cubs", - "link": "/api/v1/teams/112" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 17, - "name": "Wrigley Field", - "link": "/api/v1/venues/17" - }, - "content": { - "link": "/api/v1/game/663178/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-663178-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "Cubs home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 3, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 662766, - "gameGuid": "fcbd5b9f-eb52-4749-8f7b-54c46baaea1b", - "link": "/api/v1.1/game/662766/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T20:10:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 1, - "team": { - "id": 114, - "name": "Cleveland Guardians", - "link": "/api/v1/teams/114" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 3, - "team": { - "id": 118, - "name": "Kansas City Royals", - "link": "/api/v1/teams/118" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 7, - "name": "Kauffman Stadium", - "link": "/api/v1/venues/7" - }, - "content": { - "link": "/api/v1/game/662766/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-662766-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "Royals home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 662021, - "gameGuid": "df03848b-0be3-4603-ba86-79784c1af8f7", - "link": "/api/v1.1/game/662021/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T20:15:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 0, - "team": { - "id": 134, - "name": "Pittsburgh Pirates", - "link": "/api/v1/teams/134" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 9, - "team": { - "id": 138, - "name": "St. Louis Cardinals", - "link": "/api/v1/teams/138" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 2889, - "name": "Busch Stadium", - "link": "/api/v1/venues/2889" - }, - "content": { - "link": "/api/v1/game/662021/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-662021-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "Cardinals home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 3, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 662571, - "gameGuid": "dd48d2a0-4fe2-40da-bcc4-f07c2bc1c71a", - "link": "/api/v1.1/game/662571/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T23:05:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 5, - "team": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 1, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 3309, - "name": "Nationals Park", - "link": "/api/v1/venues/3309" - }, - "content": { - "link": "/api/v1/game/662571/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-662571-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "Nationals home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 661577, - "gameGuid": "860c3b83-234e-4f18-af14-e795c614d119", - "link": "/api/v1.1/game/661577/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-08T00:08:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 6, - "team": { - "id": 113, - "name": "Cincinnati Reds", - "link": "/api/v1/teams/113" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 3, - "team": { - "id": 144, - "name": "Atlanta Braves", - "link": "/api/v1/teams/144" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 4705, - "name": "Truist Park", - "link": "/api/v1/venues/4705" - }, - "content": { - "link": "/api/v1/game/661577/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-661577-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "Braves home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 145, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 661042, - "gameGuid": "b46b7db5-07f0-46ce-a1e4-da2d0a56265b", - "link": "/api/v1.1/game/661042/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-08T01:38:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 3, - "team": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 1, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 1, - "name": "Angel Stadium", - "link": "/api/v1/venues/1" - }, - "content": { - "link": "/api/v1/game/661042/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-661042-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "Angels home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 663418, - "gameGuid": "ed1fea37-28d4-42ae-9159-7aad6d102f58", - "link": "/api/v1.1/game/663418/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-08T01:40:00Z", - "officialDate": "2022-04-07", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 2, - "team": { - "id": 135, - "name": "San Diego Padres", - "link": "/api/v1/teams/135" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 4, - "team": { - "id": 109, - "name": "Arizona Diamondbacks", - "link": "/api/v1/teams/109" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 15, - "name": "Chase Field", - "link": "/api/v1/venues/15" - }, - "content": { - "link": "/api/v1/game/663418/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-663418-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "D-backs home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 661333, - "gameGuid": "dc6871a5-fd58-4963-8935-ec89005aa944", - "link": "/api/v1.1/game/661333/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T17:05:00Z", - "officialDate": "2022-04-08", - "rescheduleDate": "2022-04-08T17:05:00Z", - "rescheduleGameDate": "2022-04-08", - "status": { - "abstractGameState": "Final", - "codedGameState": "D", - "detailedState": "Postponed", - "statusCode": "DI", - "startTimeTBD": false, - "reason": "Inclement Weather", - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "team": { - "id": 111, - "name": "Boston Red Sox", - "link": "/api/v1/teams/111" - }, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "team": { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 3313, - "name": "Yankee Stadium", - "link": "/api/v1/venues/3313" - }, - "content": { - "link": "/api/v1/game/661333/content" - }, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-661333-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "Yankees home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 145, - "gamesInSeries": 3, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 661750, - "gameGuid": "2978feca-91cc-44b7-bfd9-7bd6cbf154e7", - "link": "/api/v1.1/game/661750/feed/live", - "gameType": "R", - "season": "2022", - "gameDate": "2022-04-07T20:10:00Z", - "officialDate": "2022-04-08", - "rescheduleDate": "2022-04-08T20:10:00Z", - "rescheduleGameDate": "2022-04-08", - "status": { - "abstractGameState": "Final", - "codedGameState": "D", - "detailedState": "Postponed", - "statusCode": "DI", - "startTimeTBD": false, - "reason": "Inclement Weather", - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "team": { - "id": 142, - "name": "Minnesota Twins", - "link": "/api/v1/teams/142" - }, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 3312, - "name": "Target Field", - "link": "/api/v1/venues/3312" - }, - "content": { - "link": "/api/v1/game/661750/content" - }, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-661750-2022-04-07", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "Twins home opener", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 4, - "seriesGameNumber": 1, - "seriesDescription": "Regular Season", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - } - ], - "events": [] - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/schedule/schedule_start_end_date.json b/tests/mock_tests/mock_json/schedule/schedule_start_end_date.json deleted file mode 100644 index 7e44a823..00000000 --- a/tests/mock_tests/mock_json/schedule/schedule_start_end_date.json +++ /dev/null @@ -1,595 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "totalItems": 8, - "totalEvents": 0, - "totalGames": 8, - "totalGamesInProgress": 0, - "dates": [ - { - "date": "2022-10-11", - "totalItems": 4, - "totalEvents": 0, - "totalGames": 4, - "totalGamesInProgress": 0, - "games": [ - { - "gamePk": 715743, - "gameGuid": "90cf981f-455a-4660-9804-9de34e1b75cd", - "link": "/api/v1.1/game/715743/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-11T17:07:00Z", - "officialDate": "2022-10-11", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 7, - "team": { - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 4 - }, - "home": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 6, - "team": { - "id": 144, - "name": "Atlanta Braves", - "link": "/api/v1/teams/144" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 4 - } - }, - "venue": { - "id": 4705, - "name": "Truist Park", - "link": "/api/v1/venues/4705" - }, - "content": { - "link": "/api/v1/game/715743/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715743-2022-10-11", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "NLDS Game 1", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 1, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 715758, - "gameGuid": "5be485bd-6156-4d5d-9779-fbd474e537ab", - "link": "/api/v1.1/game/715758/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-11T19:37:00Z", - "officialDate": "2022-10-11", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 1, - "pct": ".000" - }, - "score": 7, - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 0, - "pct": "1.000" - }, - "score": 8, - "team": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 2392, - "name": "Minute Maid Park", - "link": "/api/v1/venues/2392" - }, - "content": { - "link": "/api/v1/game/715758/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715758-2022-10-11", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "ALDS Game 1", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 1, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 715753, - "gameGuid": "534f1f6a-ff13-47c7-82ec-7a7f857281dd", - "link": "/api/v1.1/game/715753/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-11T23:37:00Z", - "officialDate": "2022-10-11", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": {}, - "venue": { - "id": 3313, - "name": "Yankee Stadium", - "link": "/api/v1/venues/3313" - }, - "content": { - "link": "/api/v1/game/715753/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715753-2022-10-11", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "ALDS Game 1", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 1, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 715748, - "gameGuid": "0c5bdcc8-f9f3-4e30-95b1-c5990f06fd1d", - "link": "/api/v1.1/game/715748/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-12T01:37:00Z", - "officialDate": "2022-10-11", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": {}, - "venue": { - "id": 22, - "name": "Dodger Stadium", - "link": "/api/v1/venues/22" - }, - "content": { - "link": "/api/v1/game/715748/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715748-2022-10-11", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "NLDS Game 1", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 1, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - } - ], - "events": [] - }, - { - "date": "2022-10-12", - "totalItems": 2, - "totalEvents": 0, - "totalGames": 2, - "totalGamesInProgress": 0, - "games": [ - { - "gamePk": 715742, - "gameGuid": "dd8141c3-1ab1-4e4c-aa6c-01b756d147b6", - "link": "/api/v1.1/game/715742/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-12T20:35:00Z", - "officialDate": "2022-10-12", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "score": 0, - "team": { - "id": 143, - "name": "Philadelphia Phillies", - "link": "/api/v1/teams/143" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 4 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "score": 3, - "team": { - "id": 144, - "name": "Atlanta Braves", - "link": "/api/v1/teams/144" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 4 - } - }, - "venue": { - "id": 4705, - "name": "Truist Park", - "link": "/api/v1/venues/4705" - }, - "content": { - "link": "/api/v1/game/715742/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715742-2022-10-12", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "NLDS Game 2", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 2, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 715747, - "gameGuid": "02a068a6-a08f-434f-ad41-f79d1ad20086", - "link": "/api/v1.1/game/715747/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-13T00:37:00Z", - "officialDate": "2022-10-12", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "score": 5, - "team": { - "id": 135, - "name": "San Diego Padres", - "link": "/api/v1/teams/135" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 3 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "score": 3, - "team": { - "id": 119, - "name": "Los Angeles Dodgers", - "link": "/api/v1/teams/119" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 3 - } - }, - "venue": { - "id": 22, - "name": "Dodger Stadium", - "link": "/api/v1/venues/22" - }, - "content": { - "link": "/api/v1/game/715747/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715747-2022-10-12", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "NLDS Game 2", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 2, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - } - ], - "events": [] - }, - { - "date": "2022-10-13", - "totalItems": 2, - "totalEvents": 0, - "totalGames": 2, - "totalGamesInProgress": 0, - "games": [ - { - "gamePk": 715757, - "gameGuid": "d344c53c-9e37-4c4b-86ae-f20e769115fc", - "link": "/api/v1.1/game/715757/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-13T19:37:00Z", - "officialDate": "2022-10-13", - "status": { - "abstractGameState": "Final", - "codedGameState": "F", - "detailedState": "Final", - "statusCode": "F", - "startTimeTBD": false, - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 0, - "losses": 2, - "pct": ".000" - }, - "score": 2, - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "isWinner": false, - "splitSquad": false, - "seriesNumber": 1 - }, - "home": { - "leagueRecord": { - "wins": 2, - "losses": 0, - "pct": "1.000" - }, - "score": 4, - "team": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "isWinner": true, - "splitSquad": false, - "seriesNumber": 1 - } - }, - "venue": { - "id": 2392, - "name": "Minute Maid Park", - "link": "/api/v1/venues/2392" - }, - "content": { - "link": "/api/v1/game/715757/content" - }, - "isTie": false, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715757-2022-10-13", - "seasonDisplay": "2022", - "dayNight": "day", - "description": "ALDS Game 2", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 2, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - }, - { - "gamePk": 715752, - "gameGuid": "1aff41c9-117d-41ae-aa0c-11dbb0749955", - "link": "/api/v1.1/game/715752/feed/live", - "gameType": "D", - "season": "2022", - "gameDate": "2022-10-13T23:37:00Z", - "officialDate": "2022-10-14", - "rescheduleDate": "2022-10-14T17:07:00Z", - "rescheduleGameDate": "2022-10-14", - "status": { - "abstractGameState": "Final", - "codedGameState": "D", - "detailedState": "Postponed", - "statusCode": "DI", - "startTimeTBD": false, - "reason": "Inclement Weather", - "abstractGameCode": "F" - }, - "teams": { - "away": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "team": { - "id": 114, - "name": "Cleveland Guardians", - "link": "/api/v1/teams/114" - }, - "splitSquad": false, - "seriesNumber": 2 - }, - "home": { - "leagueRecord": { - "wins": 1, - "losses": 1, - "pct": ".500" - }, - "team": { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - "splitSquad": false, - "seriesNumber": 2 - } - }, - "venue": { - "id": 3313, - "name": "Yankee Stadium", - "link": "/api/v1/venues/3313" - }, - "content": { - "link": "/api/v1/game/715752/content" - }, - "gameNumber": 1, - "publicFacing": true, - "doubleHeader": "N", - "gamedayType": "P", - "tiebreaker": "N", - "calendarEventID": "14-715752-2022-10-13", - "seasonDisplay": "2022", - "dayNight": "night", - "description": "ALDS Game 2", - "scheduledInnings": 9, - "reverseHomeAwayStatus": false, - "inningBreakLength": 120, - "gamesInSeries": 5, - "seriesGameNumber": 2, - "seriesDescription": "Division Series", - "recordSource": "S", - "ifNecessary": "N", - "ifNecessaryDescription": "Normal Game" - } - ], - "events": [] - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/sports/sport.json b/tests/mock_tests/mock_json/sports/sport.json deleted file mode 100644 index 18bac257..00000000 --- a/tests/mock_tests/mock_json/sports/sport.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "sports": [ - { - "id": 1, - "code": "mlb", - "link": "/api/v1/sports/1", - "name": "Major League Baseball", - "abbreviation": "MLB", - "sortOrder": 11, - "activeStatus": true - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/sports/sports.json b/tests/mock_tests/mock_json/sports/sports.json deleted file mode 100644 index b12b6262..00000000 --- a/tests/mock_tests/mock_json/sports/sports.json +++ /dev/null @@ -1,50 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "sports": [ - { - "id": 1, - "code": "mlb", - "link": "/api/v1/sports/1", - "name": "Major League Baseball", - "abbreviation": "MLB", - "sortOrder": 11, - "activeStatus": true - }, - { - "id": 11, - "code": "aaa", - "link": "/api/v1/sports/11", - "name": "Triple-A", - "abbreviation": "AAA", - "sortOrder": 101, - "activeStatus": true - }, - { - "id": 12, - "code": "aax", - "link": "/api/v1/sports/12", - "name": "Double-A", - "abbreviation": "AA", - "sortOrder": 201, - "activeStatus": true - }, - { - "id": 13, - "code": "afa", - "link": "/api/v1/sports/13", - "name": "High-A", - "abbreviation": "A+", - "sortOrder": 301, - "activeStatus": true - }, - { - "id": 14, - "code": "afx", - "link": "/api/v1/sports/14", - "name": "Single-A", - "abbreviation": "A", - "sortOrder": 401, - "activeStatus": true - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/standings/standings.json b/tests/mock_tests/mock_json/standings/standings.json deleted file mode 100644 index beccd357..00000000 --- a/tests/mock_tests/mock_json/standings/standings.json +++ /dev/null @@ -1,1446 +0,0 @@ -{ - "copyright": "Copyright 2023 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "records": [ - { - "standingsType": "regularSeason", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "division": { - "id": 201, - "link": "/api/v1/divisions/201" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "lastUpdated": "2023-06-03T15:24:33.307Z", - "teamRecords": [ - { - "team": { - "id": 147, - "name": "New York Yankees", - "link": "/api/v1/teams/147" - }, - "season": "2022", - "streak": { - "streakType": "losses", - "streakNumber": 2, - "streakCode": "L2" - }, - "clinchIndicator": "y", - "divisionRank": "1", - "leagueRank": "2", - "sportRank": "2", - "gamesPlayed": 162, - "gamesBack": "-", - "wildCardGamesBack": "-", - "leagueGamesBack": "7.0", - "springLeagueGamesBack": "-", - "sportGamesBack": "7.0", - "divisionGamesBack": "-", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 99, - "losses": 63, - "ties": 0, - "pct": ".611" - }, - "lastUpdated": "2023-06-03T15:24:33Z", - "records": { - "splitRecords": [ - { - "wins": 57, - "losses": 24, - "type": "home", - "pct": ".704" - }, - { - "wins": 42, - "losses": 39, - "type": "away", - "pct": ".519" - }, - { - "wins": 26, - "losses": 15, - "type": "left", - "pct": ".634" - }, - { - "wins": 16, - "losses": 2, - "type": "leftHome", - "pct": ".889" - }, - { - "wins": 10, - "losses": 13, - "type": "leftAway", - "pct": ".435" - }, - { - "wins": 41, - "losses": 22, - "type": "rightHome", - "pct": ".651" - }, - { - "wins": 32, - "losses": 26, - "type": "rightAway", - "pct": ".552" - }, - { - "wins": 73, - "losses": 48, - "type": "right", - "pct": ".603" - }, - { - "wins": 5, - "losses": 5, - "type": "lastTen", - "pct": ".500" - }, - { - "wins": 10, - "losses": 8, - "type": "extraInning", - "pct": ".556" - }, - { - "wins": 31, - "losses": 27, - "type": "oneRun", - "pct": ".534" - }, - { - "wins": 50, - "losses": 43, - "type": "winners", - "pct": ".538" - }, - { - "wins": 33, - "losses": 19, - "type": "day", - "pct": ".635" - }, - { - "wins": 66, - "losses": 44, - "type": "night", - "pct": ".600" - }, - { - "wins": 86, - "losses": 53, - "type": "grass", - "pct": ".619" - }, - { - "wins": 13, - "losses": 10, - "type": "turf", - "pct": ".565" - } - ], - "divisionRecords": [ - { - "wins": 17, - "losses": 16, - "pct": ".515", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 47, - "losses": 29, - "pct": ".618", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 25, - "losses": 8, - "pct": ".758", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 57, - "losses": 24, - "type": "home", - "pct": ".704" - }, - { - "wins": 42, - "losses": 39, - "type": "away", - "pct": ".519" - } - ], - "leagueRecords": [ - { - "wins": 89, - "losses": 53, - "pct": ".627", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 10, - "losses": 10, - "pct": ".500", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 106, - "losses": 56, - "type": "xWinLoss", - "pct": ".654" - }, - { - "wins": 106, - "losses": 56, - "type": "xWinLossSeason", - "pct": ".654" - } - ] - }, - "runsAllowed": 567, - "runsScored": 807, - "divisionChamp": true, - "divisionLeader": true, - "hasWildcard": true, - "clinched": true, - "eliminationNumber": "-", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "E", - "eliminationNumberDivision": "-", - "eliminationNumberConference": "97", - "wildCardEliminationNumber": "-", - "magicNumber": "-", - "wins": 99, - "losses": 63, - "runDifferential": 240, - "winningPercentage": ".611" - }, - { - "team": { - "id": 141, - "name": "Toronto Blue Jays", - "link": "/api/v1/teams/141" - }, - "season": "2022", - "streak": { - "streakType": "wins", - "streakNumber": 1, - "streakCode": "W1" - }, - "clinchIndicator": "w", - "divisionRank": "2", - "leagueRank": "4", - "wildCardRank": "1", - "sportRank": "4", - "gamesPlayed": 162, - "gamesBack": "7.0", - "wildCardGamesBack": "+6.0", - "leagueGamesBack": "14.0", - "springLeagueGamesBack": "-", - "sportGamesBack": "14.0", - "divisionGamesBack": "7.0", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 92, - "losses": 70, - "ties": 0, - "pct": ".568" - }, - "lastUpdated": "2023-05-31T21:40:50Z", - "records": { - "splitRecords": [ - { - "wins": 47, - "losses": 34, - "type": "home", - "pct": ".580" - }, - { - "wins": 45, - "losses": 36, - "type": "away", - "pct": ".556" - }, - { - "wins": 12, - "losses": 20, - "type": "left", - "pct": ".375" - }, - { - "wins": 6, - "losses": 10, - "type": "leftHome", - "pct": ".375" - }, - { - "wins": 6, - "losses": 10, - "type": "leftAway", - "pct": ".375" - }, - { - "wins": 41, - "losses": 24, - "type": "rightHome", - "pct": ".631" - }, - { - "wins": 39, - "losses": 26, - "type": "rightAway", - "pct": ".600" - }, - { - "wins": 80, - "losses": 50, - "type": "right", - "pct": ".615" - }, - { - "wins": 7, - "losses": 3, - "type": "lastTen", - "pct": ".700" - }, - { - "wins": 8, - "losses": 7, - "type": "extraInning", - "pct": ".533" - }, - { - "wins": 30, - "losses": 20, - "type": "oneRun", - "pct": ".600" - }, - { - "wins": 45, - "losses": 49, - "type": "winners", - "pct": ".479" - }, - { - "wins": 35, - "losses": 28, - "type": "day", - "pct": ".556" - }, - { - "wins": 57, - "losses": 42, - "type": "night", - "pct": ".576" - }, - { - "wins": 39, - "losses": 30, - "type": "grass", - "pct": ".565" - }, - { - "wins": 53, - "losses": 40, - "type": "turf", - "pct": ".570" - } - ], - "divisionRecords": [ - { - "wins": 17, - "losses": 15, - "pct": ".531", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 43, - "losses": 33, - "pct": ".566", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 19, - "losses": 15, - "pct": ".559", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 47, - "losses": 34, - "type": "home", - "pct": ".580" - }, - { - "wins": 45, - "losses": 36, - "type": "away", - "pct": ".556" - } - ], - "leagueRecords": [ - { - "wins": 79, - "losses": 63, - "pct": ".556", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 13, - "losses": 7, - "pct": ".650", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 91, - "losses": 71, - "type": "xWinLoss", - "pct": ".562" - }, - { - "wins": 91, - "losses": 71, - "type": "xWinLossSeason", - "pct": ".562" - } - ] - }, - "runsAllowed": 679, - "runsScored": 775, - "divisionChamp": false, - "divisionLeader": false, - "wildCardLeader": true, - "hasWildcard": true, - "clinched": true, - "eliminationNumber": "E", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "E", - "eliminationNumberDivision": "E", - "eliminationNumberConference": "90", - "wildCardEliminationNumber": "-", - "wins": 92, - "losses": 70, - "runDifferential": 96, - "winningPercentage": ".568" - } - ] - }, - { - "standingsType": "regularSeason", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "division": { - "id": 202, - "link": "/api/v1/divisions/202" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "lastUpdated": "2023-06-03T16:19:43.302Z", - "teamRecords": [ - { - "team": { - "id": 114, - "name": "Cleveland Guardians", - "link": "/api/v1/teams/114" - }, - "season": "2022", - "streak": { - "streakType": "wins", - "streakNumber": 2, - "streakCode": "W2" - }, - "clinchIndicator": "y", - "divisionRank": "1", - "leagueRank": "3", - "sportRank": "3", - "gamesPlayed": 162, - "gamesBack": "-", - "wildCardGamesBack": "-", - "leagueGamesBack": "14.0", - "springLeagueGamesBack": "-", - "sportGamesBack": "14.0", - "divisionGamesBack": "-", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 92, - "losses": 70, - "ties": 0, - "pct": ".568" - }, - "lastUpdated": "2023-06-03T16:19:43Z", - "records": { - "splitRecords": [ - { - "wins": 46, - "losses": 35, - "type": "home", - "pct": ".568" - }, - { - "wins": 46, - "losses": 35, - "type": "away", - "pct": ".568" - }, - { - "wins": 28, - "losses": 17, - "type": "left", - "pct": ".622" - }, - { - "wins": 14, - "losses": 8, - "type": "leftHome", - "pct": ".636" - }, - { - "wins": 14, - "losses": 9, - "type": "leftAway", - "pct": ".609" - }, - { - "wins": 32, - "losses": 27, - "type": "rightHome", - "pct": ".542" - }, - { - "wins": 32, - "losses": 26, - "type": "rightAway", - "pct": ".552" - }, - { - "wins": 64, - "losses": 53, - "type": "right", - "pct": ".547" - }, - { - "wins": 7, - "losses": 3, - "type": "lastTen", - "pct": ".700" - }, - { - "wins": 13, - "losses": 6, - "type": "extraInning", - "pct": ".684" - }, - { - "wins": 28, - "losses": 17, - "type": "oneRun", - "pct": ".622" - }, - { - "wins": 34, - "losses": 34, - "type": "winners", - "pct": ".500" - }, - { - "wins": 40, - "losses": 31, - "type": "day", - "pct": ".563" - }, - { - "wins": 52, - "losses": 39, - "type": "night", - "pct": ".571" - }, - { - "wins": 85, - "losses": 68, - "type": "grass", - "pct": ".556" - }, - { - "wins": 7, - "losses": 2, - "type": "turf", - "pct": ".778" - } - ], - "divisionRecords": [ - { - "wins": 18, - "losses": 16, - "pct": ".529", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 15, - "losses": 17, - "pct": ".469", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 47, - "losses": 29, - "pct": ".618", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 46, - "losses": 35, - "type": "home", - "pct": ".568" - }, - { - "wins": 46, - "losses": 35, - "type": "away", - "pct": ".568" - } - ], - "leagueRecords": [ - { - "wins": 80, - "losses": 62, - "pct": ".563", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 12, - "losses": 8, - "pct": ".600", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 88, - "losses": 74, - "type": "xWinLoss", - "pct": ".543" - }, - { - "wins": 88, - "losses": 74, - "type": "xWinLossSeason", - "pct": ".543" - } - ] - }, - "runsAllowed": 634, - "runsScored": 698, - "divisionChamp": true, - "divisionLeader": true, - "hasWildcard": true, - "clinched": true, - "eliminationNumber": "-", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "E", - "eliminationNumberDivision": "-", - "eliminationNumberConference": "90", - "wildCardEliminationNumber": "-", - "magicNumber": "-", - "wins": 92, - "losses": 70, - "runDifferential": 64, - "winningPercentage": ".568" - }, - { - "team": { - "id": 145, - "name": "Chicago White Sox", - "link": "/api/v1/teams/145" - }, - "season": "2022", - "streak": { - "streakType": "losses", - "streakNumber": 1, - "streakCode": "L1" - }, - "divisionRank": "2", - "leagueRank": "8", - "wildCardRank": "5", - "sportRank": "8", - "gamesPlayed": 162, - "gamesBack": "11.0", - "wildCardGamesBack": "5.0", - "leagueGamesBack": "25.0", - "springLeagueGamesBack": "-", - "sportGamesBack": "25.0", - "divisionGamesBack": "11.0", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 81, - "losses": 81, - "ties": 0, - "pct": ".500" - }, - "lastUpdated": "2023-06-03T15:52:38Z", - "records": { - "splitRecords": [ - { - "wins": 37, - "losses": 44, - "type": "home", - "pct": ".457" - }, - { - "wins": 44, - "losses": 37, - "type": "away", - "pct": ".543" - }, - { - "wins": 17, - "losses": 20, - "type": "left", - "pct": ".459" - }, - { - "wins": 9, - "losses": 11, - "type": "leftHome", - "pct": ".450" - }, - { - "wins": 8, - "losses": 9, - "type": "leftAway", - "pct": ".471" - }, - { - "wins": 28, - "losses": 33, - "type": "rightHome", - "pct": ".459" - }, - { - "wins": 36, - "losses": 28, - "type": "rightAway", - "pct": ".563" - }, - { - "wins": 64, - "losses": 61, - "type": "right", - "pct": ".512" - }, - { - "wins": 5, - "losses": 5, - "type": "lastTen", - "pct": ".500" - }, - { - "wins": 6, - "losses": 9, - "type": "extraInning", - "pct": ".400" - }, - { - "wins": 27, - "losses": 16, - "type": "oneRun", - "pct": ".628" - }, - { - "wins": 31, - "losses": 36, - "type": "winners", - "pct": ".463" - }, - { - "wins": 38, - "losses": 32, - "type": "day", - "pct": ".543" - }, - { - "wins": 43, - "losses": 49, - "type": "night", - "pct": ".467" - }, - { - "wins": 77, - "losses": 75, - "type": "grass", - "pct": ".507" - }, - { - "wins": 4, - "losses": 6, - "type": "turf", - "pct": ".400" - } - ], - "divisionRecords": [ - { - "wins": 18, - "losses": 16, - "pct": ".529", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 15, - "losses": 17, - "pct": ".469", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 37, - "losses": 39, - "pct": ".487", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 37, - "losses": 44, - "type": "home", - "pct": ".457" - }, - { - "wins": 44, - "losses": 37, - "type": "away", - "pct": ".543" - } - ], - "leagueRecords": [ - { - "wins": 70, - "losses": 72, - "pct": ".493", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 11, - "losses": 9, - "pct": ".550", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 78, - "losses": 84, - "type": "xWinLoss", - "pct": ".481" - }, - { - "wins": 78, - "losses": 84, - "type": "xWinLossSeason", - "pct": ".481" - } - ] - }, - "runsAllowed": 717, - "runsScored": 686, - "divisionChamp": false, - "divisionLeader": false, - "hasWildcard": true, - "clinched": false, - "eliminationNumber": "E", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "E", - "eliminationNumberDivision": "E", - "eliminationNumberConference": "79", - "wildCardEliminationNumber": "E", - "wins": 81, - "losses": 81, - "runDifferential": -31, - "winningPercentage": ".500" - } - ] - }, - { - "standingsType": "regularSeason", - "league": { - "id": 103, - "link": "/api/v1/league/103" - }, - "division": { - "id": 200, - "link": "/api/v1/divisions/200" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1" - }, - "lastUpdated": "2023-06-03T16:19:40.069Z", - "teamRecords": [ - { - "team": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "season": "2022", - "streak": { - "streakType": "wins", - "streakNumber": 2, - "streakCode": "W2" - }, - "clinchIndicator": "z", - "divisionRank": "1", - "leagueRank": "1", - "sportRank": "1", - "gamesPlayed": 162, - "gamesBack": "-", - "wildCardGamesBack": "-", - "leagueGamesBack": "-", - "springLeagueGamesBack": "-", - "sportGamesBack": "-", - "divisionGamesBack": "-", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 106, - "losses": 56, - "ties": 0, - "pct": ".654" - }, - "lastUpdated": "2023-06-03T15:41:25Z", - "records": { - "splitRecords": [ - { - "wins": 55, - "losses": 26, - "type": "home", - "pct": ".679" - }, - { - "wins": 51, - "losses": 30, - "type": "away", - "pct": ".630" - }, - { - "wins": 42, - "losses": 12, - "type": "left", - "pct": ".778" - }, - { - "wins": 23, - "losses": 6, - "type": "leftHome", - "pct": ".793" - }, - { - "wins": 19, - "losses": 6, - "type": "leftAway", - "pct": ".760" - }, - { - "wins": 32, - "losses": 20, - "type": "rightHome", - "pct": ".615" - }, - { - "wins": 32, - "losses": 24, - "type": "rightAway", - "pct": ".571" - }, - { - "wins": 64, - "losses": 44, - "type": "right", - "pct": ".593" - }, - { - "wins": 7, - "losses": 3, - "type": "lastTen", - "pct": ".700" - }, - { - "wins": 5, - "losses": 6, - "type": "extraInning", - "pct": ".455" - }, - { - "wins": 28, - "losses": 16, - "type": "oneRun", - "pct": ".636" - }, - { - "wins": 42, - "losses": 27, - "type": "winners", - "pct": ".609" - }, - { - "wins": 42, - "losses": 13, - "type": "day", - "pct": ".764" - }, - { - "wins": 64, - "losses": 43, - "type": "night", - "pct": ".598" - }, - { - "wins": 94, - "losses": 51, - "type": "grass", - "pct": ".648" - }, - { - "wins": 12, - "losses": 5, - "type": "turf", - "pct": ".706" - } - ], - "divisionRecords": [ - { - "wins": 51, - "losses": 25, - "pct": ".671", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 17, - "losses": 15, - "pct": ".531", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 26, - "losses": 8, - "pct": ".765", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 55, - "losses": 26, - "type": "home", - "pct": ".679" - }, - { - "wins": 51, - "losses": 30, - "type": "away", - "pct": ".630" - } - ], - "leagueRecords": [ - { - "wins": 94, - "losses": 48, - "pct": ".662", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 12, - "losses": 8, - "pct": ".600", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 106, - "losses": 56, - "type": "xWinLoss", - "pct": ".654" - }, - { - "wins": 106, - "losses": 56, - "type": "xWinLossSeason", - "pct": ".654" - } - ] - }, - "runsAllowed": 518, - "runsScored": 737, - "divisionChamp": true, - "divisionLeader": true, - "hasWildcard": true, - "clinched": true, - "eliminationNumber": "-", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "-", - "eliminationNumberDivision": "-", - "eliminationNumberConference": "104", - "wildCardEliminationNumber": "-", - "magicNumber": "-", - "wins": 106, - "losses": 56, - "runDifferential": 219, - "winningPercentage": ".654" - }, - { - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "season": "2022", - "streak": { - "streakType": "wins", - "streakNumber": 3, - "streakCode": "W3" - }, - "clinchIndicator": "w", - "divisionRank": "2", - "leagueRank": "5", - "wildCardRank": "2", - "sportRank": "5", - "gamesPlayed": 162, - "gamesBack": "16.0", - "wildCardGamesBack": "+4.0", - "leagueGamesBack": "16.0", - "springLeagueGamesBack": "-", - "sportGamesBack": "16.0", - "divisionGamesBack": "16.0", - "conferenceGamesBack": "-", - "leagueRecord": { - "wins": 90, - "losses": 72, - "ties": 0, - "pct": ".556" - }, - "lastUpdated": "2023-06-03T15:44:15Z", - "records": { - "splitRecords": [ - { - "wins": 46, - "losses": 35, - "type": "home", - "pct": ".568" - }, - { - "wins": 44, - "losses": 37, - "type": "away", - "pct": ".543" - }, - { - "wins": 22, - "losses": 20, - "type": "left", - "pct": ".524" - }, - { - "wins": 11, - "losses": 11, - "type": "leftHome", - "pct": ".500" - }, - { - "wins": 11, - "losses": 9, - "type": "leftAway", - "pct": ".550" - }, - { - "wins": 35, - "losses": 24, - "type": "rightHome", - "pct": ".593" - }, - { - "wins": 33, - "losses": 28, - "type": "rightAway", - "pct": ".541" - }, - { - "wins": 68, - "losses": 52, - "type": "right", - "pct": ".567" - }, - { - "wins": 7, - "losses": 3, - "type": "lastTen", - "pct": ".700" - }, - { - "wins": 11, - "losses": 5, - "type": "extraInning", - "pct": ".688" - }, - { - "wins": 34, - "losses": 22, - "type": "oneRun", - "pct": ".607" - }, - { - "wins": 38, - "losses": 33, - "type": "winners", - "pct": ".535" - }, - { - "wins": 37, - "losses": 27, - "type": "day", - "pct": ".578" - }, - { - "wins": 53, - "losses": 45, - "type": "night", - "pct": ".541" - }, - { - "wins": 80, - "losses": 63, - "type": "grass", - "pct": ".559" - }, - { - "wins": 10, - "losses": 9, - "type": "turf", - "pct": ".526" - } - ], - "divisionRecords": [ - { - "wins": 41, - "losses": 35, - "pct": ".539", - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - } - }, - { - "wins": 16, - "losses": 17, - "pct": ".485", - "division": { - "id": 201, - "name": "American League East", - "link": "/api/v1/divisions/201" - } - }, - { - "wins": 21, - "losses": 12, - "pct": ".636", - "division": { - "id": 202, - "name": "American League Central", - "link": "/api/v1/divisions/202" - } - } - ], - "overallRecords": [ - { - "wins": 46, - "losses": 35, - "type": "home", - "pct": ".568" - }, - { - "wins": 44, - "losses": 37, - "type": "away", - "pct": ".543" - } - ], - "leagueRecords": [ - { - "wins": 78, - "losses": 64, - "pct": ".549", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - } - }, - { - "wins": 12, - "losses": 8, - "pct": ".600", - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - } - } - ], - "expectedRecords": [ - { - "wins": 89, - "losses": 73, - "type": "xWinLoss", - "pct": ".549" - }, - { - "wins": 89, - "losses": 73, - "type": "xWinLossSeason", - "pct": ".549" - } - ] - }, - "runsAllowed": 623, - "runsScored": 690, - "divisionChamp": false, - "divisionLeader": false, - "wildCardLeader": true, - "hasWildcard": true, - "clinched": true, - "eliminationNumber": "E", - "eliminationNumberSport": "E", - "eliminationNumberLeague": "E", - "eliminationNumberDivision": "E", - "eliminationNumberConference": "88", - "wildCardEliminationNumber": "-", - "wins": 90, - "losses": 72, - "runDifferential": 67, - "winningPercentage": ".556" - } - ] - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/game_stats_player_archie.json b/tests/mock_tests/mock_json/stats/person/game_stats_player_archie.json deleted file mode 100644 index db57b71e..00000000 --- a/tests/mock_tests/mock_json/stats/person/game_stats_player_archie.json +++ /dev/null @@ -1,219 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "exemptions": [], - "splits": [ - { - "stat": { - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 0, - "putOuts": 0, - "errors": 0, - "chances": 0, - "fielding": ".000", - "passedBall": 0, - "pickoffs": 0 - }, - "type": "gameLog", - "group": "fielding" - }, - { - "stat": { - "gamesPlayed": 1, - "gamesStarted": 0, - "flyOuts": 1, - "groundOuts": 2, - "airOuts": 1, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "atBats": 3, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "numberOfPitches": 8, - "inningsPitched": "1.0", - "wins": 0, - "losses": 0, - "saves": 0, - "saveOpportunities": 0, - "holds": 0, - "blownSaves": 0, - "earnedRuns": 0, - "battersFaced": 3, - "outs": 3, - "gamesPitched": 1, - "completeGames": 0, - "shutouts": 0, - "pitchesThrown": 8, - "balls": 2, - "strikes": 6, - "strikePercentage": ".750", - "hitBatsmen": 0, - "balks": 0, - "wildPitches": 0, - "pickoffs": 0, - "rbi": 0, - "gamesFinished": 0, - "runsScoredPer9": "0.00", - "homeRunsPer9": "0.00", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0, - "passedBall": 0 - }, - "type": "gameLog", - "group": "pitching" - }, - { - "stat": { - "gamesPlayed": 1, - "flyOuts": 0, - "groundOuts": 0, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "atBats": 0, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 0, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 0, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "type": "gameLog", - "group": "hitting" - } - ] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "hitting" - }, - "totalSplits": 0, - "exemptions": [], - "splits": [] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "pitching" - }, - "totalSplits": 1, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 1, - "groundOuts": 1, - "airOuts": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "avg": ".000", - "atBats": 1, - "obp": ".000", - "slg": ".000", - "ops": ".000", - "groundIntoDoublePlay": 0, - "numberOfPitches": 2, - "inningsPitched": "0.1", - "outsPitched": 1, - "whip": "0.00", - "battersFaced": 1, - "outs": 1, - "gamesPitched": 1, - "balls": 0, - "strikes": 2, - "strikePercentage": "1.000", - "hitBatsmen": 0, - "balks": 0, - "wildPitches": 0, - "totalBases": 0, - "groundOutsToAirouts": "1.00", - "rbi": 0, - "pitchesPerInning": "6.00", - "strikeoutWalkRatio": "-.--", - "strikeoutsPer9Inn": "0.00", - "walksPer9Inn": "0.00", - "hitsPer9Inn": "0.00", - "homeRunsPer9": "0.00", - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0 - }, - "team": { - "id": 109, - "name": "Arizona Diamondbacks", - "link": "/api/v1/teams/109" - }, - "opponent": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "gameType": "R", - "numTeams": 1, - "pitcher": { - "id": 605151, - "fullName": "Archie Bradley", - "link": "/api/v1/people/605151", - "firstName": "Archie", - "lastName": "Bradley" - }, - "batter": { - "id": 429664, - "fullName": "Robinson Cano", - "link": "/api/v1/people/429664", - "firstName": "Robinson", - "lastName": "Cano" - } - } - ] - }, - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [] - } ] - } \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/game_stats_player_cal.json b/tests/mock_tests/mock_json/stats/person/game_stats_player_cal.json deleted file mode 100644 index 1b1ca322..00000000 --- a/tests/mock_tests/mock_json/stats/person/game_stats_player_cal.json +++ /dev/null @@ -1,489 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "exemptions": [], - "splits": [ - { - "stat": { - "gamesStarted": 1, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 0, - "putOuts": 9, - "errors": 0, - "chances": 9, - "fielding": ".000", - "passedBall": 0, - "pickoffs": 0 - }, - "type": "gameLog", - "group": "fielding" - }, - { - "stat": {}, - "type": "gameLog", - "group": "pitching" - }, - { - "stat": { - "gamesPlayed": 1, - "flyOuts": 0, - "groundOuts": 2, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 1, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "atBats": 4, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 4, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 5, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "type": "gameLog", - "group": "hitting" - } - ] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "hitting" - }, - "totalSplits": 1, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 1, - "groundOuts": 1, - "airOuts": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "avg": ".000", - "atBats": 1, - "obp": ".000", - "slg": ".000", - "ops": ".000", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "numberOfPitches": 2, - "plateAppearances": 1, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 1, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".000", - "groundOutsToAirouts": "1.00", - "catchersInterference": 0, - "atBatsPerHomeRun": "-.--" - }, - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "gameType": "D", - "numTeams": 1, - "pitcher": { - "id": 519151, - "fullName": "Ryan Pressly", - "link": "/api/v1/people/519151", - "firstName": "Ryan", - "lastName": "Pressly" - }, - "batter": { - "id": 663728, - "fullName": "Cal Raleigh", - "link": "/api/v1/people/663728", - "firstName": "Cal", - "lastName": "Raleigh" - } - } - ] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "pitching" - }, - "totalSplits": 0, - "exemptions": [], - "splits": [] - }, - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "awayScore": 0, - "homeScore": 1, - "isOut": true, - "hasReview": false - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 1, - "inning": 3 - }, - "pitchData": { - "startSpeed": 95.1, - "endSpeed": 86.8, - "strikeZoneTop": 3.51, - "strikeZoneBottom": 1.68, - "coordinates": { - "aY": 32.2, - "aZ": -21.2, - "pfxX": 6.91, - "pfxZ": 5.7, - "pX": 0.24, - "pZ": 1.93, - "vX0": -3.83, - "vY0": -138.23, - "vZ0": -7.23, - "x": 107.73, - "y": 186.69, - "x0": 0.75, - "y0": 50.01, - "z0": 6.01, - "aX": 13.31 - }, - "breaks": { - "breakAngle": 28.8, - "breakLength": 6, - "breakY": 24, - "spinRate": 2182, - "spinDirection": 149 - }, - "zone": 9, - "typeConfidence": 2, - "plateTime": 0.4, - "extension": 5.68 - }, - "hitData": { - "launchSpeed": 95.3, - "launchAngle": -14, - "totalDistance": 9, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "6", - "coordinates": { - "coordX": 115.68, - "coordY": 157.25 - } - }, - "index": 0, - "playId": "20aa507d-fad7-4386-a095-927440fa458a", - "pitchNumber": 1, - "startTime": "2022-10-13T20:12:55.414Z", - "endTime": "2022-10-13T20:13:03.006Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "awayScore": 2, - "homeScore": 1, - "isOut": true, - "hasReview": false, - "runnerGoing": true - }, - "count": { - "balls": 2, - "strikes": 1, - "outs": 3, - "inning": 4 - }, - "pitchData": { - "startSpeed": 95.6, - "endSpeed": 87.2, - "strikeZoneTop": 3.51, - "strikeZoneBottom": 1.68, - "coordinates": { - "aY": 32.62, - "aZ": -18.67, - "pfxX": 9.33, - "pfxZ": 6.94, - "pX": 0.18, - "pZ": 1.7, - "vX0": -4.59, - "vY0": -138.91, - "vZ0": -8.15, - "x": 110.31, - "y": 192.95, - "x0": 0.64, - "y0": 50, - "z0": 5.92, - "aX": 18.14 - }, - "breaks": { - "breakAngle": 39.6, - "breakLength": 6, - "breakY": 24, - "spinRate": 2174, - "spinDirection": 142 - }, - "zone": 8, - "typeConfidence": 2, - "plateTime": 0.4, - "extension": 5.76 - }, - "hitData": { - "launchSpeed": 107.2, - "launchAngle": 13, - "totalDistance": 334, - "trajectory": "line_drive", - "hardness": "medium", - "location": "8", - "coordinates": { - "coordX": 122.27, - "coordY": 92.16 - } - }, - "index": 6, - "playId": "6e0a125c-72e3-48b6-8748-c3fac153e673", - "pitchNumber": 4, - "startTime": "2022-10-13T20:44:19.661Z", - "endTime": "2022-10-13T20:44:26.045Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(119, 0, 152, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "FS", - "description": "Splitter" - }, - "awayScore": 2, - "homeScore": 1, - "isOut": true, - "hasReview": false - }, - "count": { - "balls": 1, - "strikes": 2, - "outs": 3, - "inning": 6 - }, - "pitchData": { - "startSpeed": 85.7, - "endSpeed": 78, - "strikeZoneTop": 3.51, - "strikeZoneBottom": 1.68, - "coordinates": { - "aY": 28.14, - "aZ": -32.75, - "pfxX": -6.85, - "pfxZ": -0.37, - "pX": 0.96, - "pZ": 1.28, - "vX0": 7.59, - "vY0": -124.41, - "vZ0": -4.81, - "x": 80.35, - "y": 204.26, - "x0": -1.26, - "y0": 50.01, - "z0": 5.99, - "aX": -10.59 - }, - "breaks": { - "breakAngle": 14.4, - "breakLength": 9.6, - "breakY": 24, - "spinRate": 1204, - "spinDirection": 249 - }, - "zone": 14, - "typeConfidence": 0.92, - "plateTime": 0.44, - "extension": 6.29 - }, - "hitData": { - "launchSpeed": 70.7, - "launchAngle": -5, - "totalDistance": 17, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "6", - "coordinates": { - "coordX": 139.53, - "coordY": 163.02 - } - }, - "index": 5, - "playId": "ed9db705-9f3f-4944-b035-4a0a2b579de7", - "pitchNumber": 4, - "startTime": "2022-10-13T21:28:55.099Z", - "endTime": "2022-10-13T21:29:02.520Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Called Strike" - }, - "description": "Called Strike", - "code": "C", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(0, 85, 254, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "CH", - "description": "Changeup" - }, - "awayScore": 2, - "homeScore": 3, - "isOut": true, - "hasReview": false - }, - "count": { - "balls": 2, - "strikes": 3, - "outs": 3, - "inning": 8 - }, - "pitchData": { - "startSpeed": 90.9, - "endSpeed": 82.9, - "strikeZoneTop": 3.49, - "strikeZoneBottom": 1.65, - "coordinates": { - "aY": 29.91, - "aZ": -26.31, - "pfxX": -9.85, - "pfxZ": 3.33, - "pX": -0.58, - "pZ": 1.46, - "vX0": 5.09, - "vY0": -132.26, - "vZ0": -3.44, - "x": 139.06, - "y": 199.34, - "x0": -1.25, - "y0": 50, - "z0": 4.72, - "aX": -17.34 - }, - "breaks": { - "breakAngle": 31.2, - "breakLength": 7.2, - "breakY": 24, - "spinRate": 2093, - "spinDirection": 241 - }, - "zone": 13, - "typeConfidence": 0.9, - "plateTime": 0.42, - "extension": 6.08 - }, - "index": 4, - "playId": "69a72dee-3fdb-4790-845e-bdb7f01bf71a", - "pitchNumber": 5, - "startTime": "2022-10-13T22:28:07.930Z", - "endTime": "2022-10-13T22:28:12.844Z", - "isPitch": true, - "type": "pitch" - } - } - } ] - } ] - } \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/game_stats_player_shoei_ohtani.json b/tests/mock_tests/mock_json/stats/person/game_stats_player_shoei_ohtani.json deleted file mode 100644 index 68d621e1..00000000 --- a/tests/mock_tests/mock_json/stats/person/game_stats_player_shoei_ohtani.json +++ /dev/null @@ -1,109 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "hitting" - }, - "totalSplits": 0, - "exemptions": [], - "splits": [] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "pitching" - }, - "totalSplits": 1, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 1, - "groundOuts": 0, - "airOuts": 3, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 0, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "avg": ".000", - "atBats": 3, - "obp": ".000", - "slg": ".000", - "ops": ".000", - "groundIntoDoublePlay": 0, - "numberOfPitches": 7, - "inningsPitched": "1.0", - "outsPitched": 3, - "whip": "0.00", - "battersFaced": 3, - "outs": 3, - "gamesPitched": 1, - "balls": 2, - "strikes": 5, - "strikePercentage": ".710", - "hitBatsmen": 0, - "balks": 0, - "wildPitches": 0, - "totalBases": 0, - "groundOutsToAirouts": "0.00", - "rbi": 0, - "pitchesPerInning": "7.00", - "strikeoutWalkRatio": "-.--", - "strikeoutsPer9Inn": "0.00", - "walksPer9Inn": "0.00", - "hitsPer9Inn": "0.00", - "homeRunsPer9": "0.00", - "catchersInterference": 0, - "sacBunts": 0, - "sacFlies": 0 - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "opponent": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "gameType": "R", - "numTeams": 1, - "pitcher": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271", - "firstName": "Shohei", - "lastName": "Ohtani" - }, - "batter": { - "id": 429664, - "fullName": "Robinson Cano", - "link": "/api/v1/people/429664", - "firstName": "Robinson", - "lastName": "Cano" - } - } - ] - }, - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [] - } ] - } \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/game_stats_player_ty_france.json b/tests/mock_tests/mock_json/stats/person/game_stats_player_ty_france.json deleted file mode 100644 index 8b4747b3..00000000 --- a/tests/mock_tests/mock_json/stats/person/game_stats_player_ty_france.json +++ /dev/null @@ -1,523 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "exemptions": [], - "splits": [ - { - "stat": { - "gamesStarted": 1, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "assists": 1, - "putOuts": 5, - "errors": 0, - "chances": 6, - "fielding": ".000", - "passedBall": 0, - "pickoffs": 0 - }, - "type": "gameLog", - "group": "fielding" - }, - { - "stat": {}, - "type": "gameLog", - "group": "pitching" - }, - { - "stat": { - "gamesPlayed": 1, - "flyOuts": 0, - "groundOuts": 2, - "runs": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 2, - "baseOnBalls": 1, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "atBats": 4, - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "plateAppearances": 5, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 1, - "sacBunts": 0, - "sacFlies": 0, - "catchersInterference": 0, - "pickoffs": 0, - "atBatsPerHomeRun": "-.--" - }, - "type": "gameLog", - "group": "hitting" - } - ] - }, - { - "type": { - "displayName": "vsPlayer5Y" - }, - "group": { - "displayName": "hitting" - }, - "totalSplits": 1, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 1, - "groundOuts": 0, - "airOuts": 0, - "doubles": 0, - "triples": 0, - "homeRuns": 0, - "strikeOuts": 1, - "baseOnBalls": 0, - "intentionalWalks": 0, - "hits": 0, - "hitByPitch": 0, - "avg": ".000", - "atBats": 1, - "obp": ".000", - "slg": ".000", - "ops": ".000", - "groundIntoDoublePlay": 0, - "groundIntoTriplePlay": 0, - "numberOfPitches": 5, - "plateAppearances": 1, - "totalBases": 0, - "rbi": 0, - "leftOnBase": 1, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".---", - "groundOutsToAirouts": "-.--", - "catchersInterference": 0, - "atBatsPerHomeRun": "-.--" - }, - "team": { - "id": 136, - "name": "Seattle Mariners", - "link": "/api/v1/teams/136" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "gameType": "D", - "numTeams": 1, - "pitcher": {}, - "batter": {} - } - ] - }, - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Called Strike" - }, - "description": "Called Strike", - "code": "C", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "awayScore": 0, - "homeScore": 0, - "hasReview": false - }, - "count": { - "balls": 3, - "strikes": 3, - "outs": 2, - "inning": 1 - }, - "pitchData": { - "startSpeed": 94.8, - "endSpeed": 85.4, - "strikeZoneTop": 3.24, - "strikeZoneBottom": 1.48, - "coordinates": { - "aY": 36.27, - "aZ": -23.82, - "pfxX": 9.76, - "pfxZ": 4.43, - "pX": -0.27, - "pZ": 1.87, - "vX0": -5.9, - "vY0": -137.7, - "vZ0": -6.7, - "x": 127.18, - "y": 188.25, - "x0": 0.66, - "y0": 50, - "z0": 6, - "aX": 18.37 - }, - "breaks": { - "breakAngle": 33.6, - "breakLength": 7.2, - "breakY": 24, - "spinRate": 2124, - "spinDirection": 144 - }, - "zone": 7, - "typeConfidence": 2, - "plateTime": 0.4, - "extension": 5.82 - }, - "index": 6, - "playId": "6255ee72-8097-4c96-aacb-519483e13666", - "pitchNumber": 7, - "startTime": "2022-10-13T19:43:02.900Z", - "endTime": "2022-10-13T19:43:07.299Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "awayScore": 0, - "homeScore": 1, - "hasReview": false - }, - "count": { - "balls": 2, - "strikes": 2, - "outs": 1, - "inning": 4 - }, - "pitchData": { - "startSpeed": 96, - "endSpeed": 88.3, - "strikeZoneTop": 3.15, - "strikeZoneBottom": 1.45, - "coordinates": { - "aY": 30.26, - "aZ": -22.53, - "pfxX": 6.75, - "pfxZ": 4.85, - "pX": -0.04, - "pZ": 3.06, - "vX0": -3.81, - "vY0": -139.81, - "vZ0": -4.33, - "x": 118.34, - "y": 156.23, - "x0": 0.47, - "y0": 50, - "z0": 6.1, - "aX": 13.42 - }, - "breaks": { - "breakAngle": 28.8, - "breakLength": 6, - "breakY": 24, - "spinRate": 2165, - "spinDirection": 152 - }, - "zone": 2, - "typeConfidence": 2, - "plateTime": 0.39, - "extension": 5.86 - }, - "hitData": { - "launchSpeed": 96.5, - "launchAngle": -19, - "totalDistance": 10, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "4", - "coordinates": { - "coordX": 126.47, - "coordY": 139.76 - } - }, - "index": 4, - "playId": "04096939-df60-4c28-b2d3-b38a3a7b7b12", - "pitchNumber": 5, - "startTime": "2022-10-13T20:29:34.256Z", - "endTime": "2022-10-13T20:29:41.789Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "In play, out(s)" - }, - "description": "In play, out(s)", - "code": "X", - "ballColor": "rgba(26, 86, 190, 1.0)", - "trailColor": "rgba(50, 0, 221, 1.0)", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "type": { - "code": "SI", - "description": "Sinker" - }, - "awayScore": 2, - "homeScore": 1, - "hasReview": false - }, - "count": { - "balls": 1, - "strikes": 0, - "outs": 1, - "inning": 6 - }, - "pitchData": { - "startSpeed": 94.2, - "endSpeed": 86.2, - "strikeZoneTop": 3.15, - "strikeZoneBottom": 1.45, - "coordinates": { - "aY": 31.03, - "aZ": -25.02, - "pfxX": 9.7, - "pfxZ": 3.77, - "pX": 0.18, - "pZ": 1.99, - "vX0": -4.66, - "vY0": -136.98, - "vZ0": -6.26, - "x": 110.32, - "y": 185.12, - "x0": 0.64, - "y0": 50, - "z0": 6.02, - "aX": 18.38 - }, - "breaks": { - "breakAngle": 33.6, - "breakLength": 7.2, - "breakY": 24, - "spinRate": 2280, - "spinDirection": 143 - }, - "zone": 8, - "typeConfidence": 2, - "plateTime": 0.4, - "extension": 5.77 - }, - "hitData": { - "launchSpeed": 91.1, - "launchAngle": -5, - "totalDistance": 21, - "trajectory": "ground_ball", - "hardness": "medium", - "location": "6", - "coordinates": { - "coordX": 110.09, - "coordY": 155.21 - } - }, - "index": 1, - "playId": "f72c09df-338d-4d57-bd78-7aba9840c162", - "pitchNumber": 2, - "startTime": "2022-10-13T21:12:34.175Z", - "endTime": "2022-10-13T21:12:42.037Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "B", - "description": "Ball" - }, - "description": "Ball", - "code": "B", - "ballColor": "rgba(39, 161, 39, 1.0)", - "trailColor": "rgba(188, 0, 33, 1.0)", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "type": { - "code": "FF", - "description": "Four-Seam Fastball" - }, - "awayScore": 2, - "homeScore": 3, - "hasReview": false, - "runnerGoing": true - }, - "count": { - "balls": 4, - "strikes": 2, - "outs": 2, - "inning": 7 - }, - "pitchData": { - "startSpeed": 97, - "endSpeed": 87.3, - "strikeZoneTop": 3.22, - "strikeZoneBottom": 1.45, - "coordinates": { - "aY": 36.15, - "aZ": -12.18, - "pfxX": -5.21, - "pfxZ": 10.08, - "pX": 1.81, - "pZ": 3.73, - "vX0": 9.29, - "vY0": -140.92, - "vZ0": -1.33, - "x": 47.84, - "y": 137.96, - "x0": -0.87, - "y0": 50, - "z0": 5.01, - "aX": -10.33 - }, - "breaks": { - "breakAngle": 32.4, - "breakLength": 3.6, - "breakY": 24, - "spinRate": 2487, - "spinDirection": 221 - }, - "zone": 12, - "typeConfidence": 0.92, - "plateTime": 0.39, - "extension": 6.08 - }, - "index": 7, - "playId": "457ababc-dbd8-4177-869f-d3805ae02e94", - "pitchNumber": 6, - "startTime": "2022-10-13T21:56:46.455Z", - "endTime": "2022-10-13T21:56:54.799Z", - "isPitch": true, - "type": "pitch" - } - } - }, - { - "stat": { - "play": { - "details": { - "call": { - "code": "W", - "description": "Swinging Strike (Blocked)" - }, - "description": "Swinging Strike (Blocked)", - "code": "W", - "ballColor": "rgba(170, 21, 11, 1.0)", - "trailColor": "rgba(0, 34, 255, 1.0)", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "type": { - "code": "CU", - "description": "Curveball" - }, - "awayScore": 2, - "homeScore": 4, - "hasReview": false - }, - "count": { - "balls": 2, - "strikes": 3, - "outs": 3, - "inning": 9 - }, - "pitchData": { - "startSpeed": 82.8, - "endSpeed": 75.1, - "strikeZoneTop": 3.15, - "strikeZoneBottom": 1.45, - "coordinates": { - "aY": 29.92, - "aZ": -42.99, - "pfxX": 8.09, - "pfxZ": -7.61, - "pX": 1.18, - "pZ": -0.1, - "vX0": 0.63, - "vY0": -120.31, - "vZ0": -4.62, - "x": 72.09, - "y": 241.54, - "x0": -0.14, - "y0": 50, - "z0": 5.78, - "aX": 11.49 - }, - "breaks": { - "breakAngle": 14.4, - "breakLength": 13.2, - "breakY": 24, - "spinRate": 3386, - "spinDirection": 23 - }, - "zone": 14, - "typeConfidence": 0.9, - "plateTime": 0.46, - "extension": 6.17 - }, - "index": 4, - "playId": "68c2997f-095d-4239-acc4-3c6252afaf68", - "pitchNumber": 5, - "startTime": "2022-10-13T22:54:33.690Z", - "endTime": "2022-10-13T22:54:42.383Z", - "isPitch": true, - "type": "pitch" - } - } - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/hitting_player_pitchlog.json b/tests/mock_tests/mock_json/stats/person/hitting_player_pitchlog.json deleted file mode 100644 index d7ceafed..00000000 --- a/tests/mock_tests/mock_json/stats/person/hitting_player_pitchlog.json +++ /dev/null @@ -1,519 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "pitchLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Strike - Called" - }, - "event": "called_strike", - "eventType": "called_strike", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 1, - "inning": 1, - "isTopInning": false, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "80ead676-b428-4993-b28a-c6a9b286fe3a", - "pitchNumber": 1, - "atBatNumber": 6, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "B", - "description": "Ball - Called" - }, - "event": "ball", - "eventType": "ball", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 1, - "inning": 1, - "isTopInning": false, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "0d7be5e9-8de3-4613-b1cb-8385f5b382c0", - "pitchNumber": 2, - "atBatNumber": 6, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "B", - "description": "Ball - Called" - }, - "event": "ball", - "eventType": "ball", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "CH", - "description": "Changeup" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 1, - "strikes": 1, - "outs": 1, - "inning": 1, - "isTopInning": false, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "d8c81931-04a6-4427-90de-b6ab7a5dc6ac", - "pitchNumber": 3, - "atBatNumber": 6, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "Hit Into Play - Out(s)" - }, - "description": "Juan Soto grounds out, second baseman Robinson Cano to first baseman Pete Alonso. ", - "event": "field_out", - "eventType": "field_out", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "isBaseHit": false, - "isAtBat": true, - "isPlateAppearance": true, - "type": { - "code": "CH", - "description": "Changeup" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 2, - "strikes": 1, - "outs": 1, - "inning": 1, - "isTopInning": false, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "11ecdb59-e9f1-4d83-9d2a-5501e1411539", - "pitchNumber": 4, - "atBatNumber": 6, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Strike - Called" - }, - "event": "called_strike", - "eventType": "called_strike", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "CH", - "description": "Changeup" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 1, - "inning": 3, - "isTopInning": false, - "runnerOn1b": true, - "runnerOn2b": false, - "runnerOn3b": true - }, - "playId": "6e2ef485-b459-4703-89d2-7faae059199c", - "pitchNumber": 1, - "atBatNumber": 21, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "B", - "description": "Ball - Called" - }, - "event": "ball", - "eventType": "ball", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "CH", - "description": "Changeup" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 1, - "outs": 1, - "inning": 3, - "isTopInning": false, - "runnerOn1b": true, - "runnerOn2b": false, - "runnerOn3b": true - }, - "playId": "7108025e-7980-4571-bf7e-dba9eb0909af", - "pitchNumber": 2, - "atBatNumber": 21, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - } ] - } ] - } \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/hitting_player_playlog.json b/tests/mock_tests/mock_json/stats/person/hitting_player_playlog.json deleted file mode 100644 index 809a64a9..00000000 --- a/tests/mock_tests/mock_json/stats/person/hitting_player_playlog.json +++ /dev/null @@ -1,184 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "X", - "description": "Hit Into Play - Out(s)" - }, - "description": "Juan Soto grounds out, second baseman Robinson Cano to first baseman Pete Alonso. ", - "event": "field_out", - "eventType": "field_out", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "isBaseHit": false, - "isAtBat": true, - "isPlateAppearance": true, - "type": { - "code": "CH", - "description": "Changeup" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 2, - "strikes": 1, - "outs": 1, - "inning": 1, - "isTopInning": false, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "11ecdb59-e9f1-4d83-9d2a-5501e1411539", - "pitchNumber": 4, - "atBatNumber": 6, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "S", - "description": "Strike - Swinging" - }, - "description": "Juan Soto strikes out swinging. ", - "event": "strikeout", - "eventType": "strikeout", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "isBaseHit": false, - "isAtBat": true, - "isPlateAppearance": true, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 2, - "strikes": 2, - "outs": 1, - "inning": 3, - "isTopInning": false, - "runnerOn1b": true, - "runnerOn2b": false, - "runnerOn3b": true - }, - "playId": "af4ab082-2308-4320-9445-7d40a4947bcf", - "pitchNumber": 5, - "atBatNumber": 21, - "isPitch": true - } - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "opponent": { - "id": 121, - "name": "New York Mets", - "link": "/api/v1/teams/121" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 656731, - "fullName": "Tylor Megill", - "link": "/api/v1/people/656731" - }, - "batter": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "game": { - "gamePk": 662571, - "link": "/api/v1.1/game/662571/feed/live", - "content": { - "link": "/api/v1/game/662571/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }] -}] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/hitting_player_stats.json b/tests/mock_tests/mock_json/stats/person/hitting_player_stats.json deleted file mode 100644 index d5e6edce..00000000 --- a/tests/mock_tests/mock_json/stats/person/hitting_player_stats.json +++ /dev/null @@ -1,465 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "career" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 617, - "groundOuts": 627, - "airOuts": 461, - "runs": 430, - "doubles": 116, - "triples": 10, - "homeRuns": 125, - "strikeOuts": 448, - "baseOnBalls": 508, - "intentionalWalks": 54, - "hits": 612, - "hitByPitch": 10, - "avg": ".287", - "atBats": 2136, - "obp": ".424", - "slg": ".526", - "ops": ".950", - "caughtStealing": 14, - "stolenBases": 38, - "stolenBasePercentage": ".731", - "groundIntoDoublePlay": 56, - "numberOfPitches": 11012, - "plateAppearances": 2667, - "totalBases": 1123, - "rbi": 374, - "leftOnBase": 898, - "sacBunts": 1, - "sacFlies": 11, - "babip": ".309", - "groundOutsToAirouts": "1.36", - "catchersInterference": 1, - "atBatsPerHomeRun": "17.09" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R", - "numTeams": 2 - } - ] - }, - { - "type": { - "displayName": "careerAdvanced" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "plateAppearances": 2667, - "totalBases": 1123, - "leftOnBase": 898, - "sacBunts": 1, - "sacFlies": 11, - "babip": ".309", - "extraBaseHits": 251, - "hitByPitch": 10, - "gidp": 56, - "gidpOpp": 383, - "numberOfPitches": 11012, - "pitchesPerPlateAppearance": "4.129", - "walksPerPlateAppearance": ".190", - "strikeoutsPerPlateAppearance": ".168", - "homeRunsPerPlateAppearance": ".047", - "walksPerStrikeout": "1.134", - "iso": ".239", - "reachedOnError": 16, - "walkOffs": 1, - "flyOuts": 262, - "totalSwings": 4109, - "swingAndMisses": 881, - "ballsInPlay": 1700, - "popOuts": 76, - "lineOuts": 123, - "groundOuts": 627, - "flyHits": 139, - "popHits": 1, - "lineHits": 259, - "groundHits": 213 - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R", - "numTeams": 2 - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "gamesPlayed": 153, - "groundOuts": 162, - "airOuts": 139, - "runs": 93, - "doubles": 25, - "triples": 2, - "homeRuns": 27, - "strikeOuts": 96, - "baseOnBalls": 135, - "intentionalWalks": 6, - "hits": 127, - "hitByPitch": 4, - "avg": ".242", - "atBats": 524, - "obp": ".401", - "slg": ".452", - "ops": ".853", - "caughtStealing": 2, - "stolenBases": 6, - "stolenBasePercentage": ".750", - "groundIntoDoublePlay": 12, - "numberOfPitches": 2765, - "plateAppearances": 664, - "totalBases": 237, - "rbi": 62, - "leftOnBase": 203, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".249", - "groundOutsToAirouts": "1.17", - "catchersInterference": 1, - "atBatsPerHomeRun": "19.41" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R", - "numTeams": 2 - }, - { - "season": "2022", - "stat": { - "gamesPlayed": 101, - "groundOuts": 109, - "airOuts": 87, - "runs": 62, - "doubles": 17, - "triples": 1, - "homeRuns": 21, - "strikeOuts": 62, - "baseOnBalls": 91, - "intentionalWalks": 4, - "hits": 84, - "hitByPitch": 3, - "avg": ".246", - "atBats": 342, - "obp": ".408", - "slg": ".485", - "ops": ".893", - "caughtStealing": 2, - "stolenBases": 6, - "stolenBasePercentage": ".750", - "groundIntoDoublePlay": 11, - "numberOfPitches": 1819, - "plateAppearances": 436, - "totalBases": 166, - "rbi": 46, - "leftOnBase": 137, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".243", - "groundOutsToAirouts": "1.25", - "catchersInterference": 0, - "atBatsPerHomeRun": "16.29" - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - }, - { - "season": "2022", - "stat": { - "gamesPlayed": 52, - "groundOuts": 53, - "airOuts": 52, - "runs": 31, - "doubles": 8, - "triples": 1, - "homeRuns": 6, - "strikeOuts": 34, - "baseOnBalls": 44, - "intentionalWalks": 2, - "hits": 43, - "hitByPitch": 1, - "avg": ".236", - "atBats": 182, - "obp": ".388", - "slg": ".390", - "ops": ".778", - "caughtStealing": 0, - "stolenBases": 0, - "stolenBasePercentage": ".---", - "groundIntoDoublePlay": 1, - "numberOfPitches": 946, - "plateAppearances": 228, - "totalBases": 71, - "rbi": 16, - "leftOnBase": 66, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".261", - "groundOutsToAirouts": "1.02", - "catchersInterference": 1, - "atBatsPerHomeRun": "30.33" - }, - "team": { - "id": 135, - "name": "San Diego Padres", - "link": "/api/v1/teams/135" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - }, - { - "type": { - "displayName": "seasonAdvanced" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "plateAppearances": 664, - "totalBases": 237, - "leftOnBase": 203, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".249", - "extraBaseHits": 54, - "hitByPitch": 4, - "gidp": 12, - "gidpOpp": 86, - "numberOfPitches": 2765, - "pitchesPerPlateAppearance": "4.164", - "walksPerPlateAppearance": ".203", - "strikeoutsPerPlateAppearance": ".145", - "homeRunsPerPlateAppearance": ".041", - "walksPerStrikeout": "1.406", - "iso": ".210", - "reachedOnError": 6, - "walkOffs": 0, - "flyOuts": 82, - "totalSwings": 976, - "swingAndMisses": 187, - "ballsInPlay": 428, - "popOuts": 26, - "lineOuts": 31, - "groundOuts": 162, - "flyHits": 34, - "popHits": 1, - "lineHits": 51, - "groundHits": 41 - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R", - "numTeams": 2 - }, - { - "season": "2022", - "stat": { - "plateAppearances": 436, - "totalBases": 166, - "leftOnBase": 137, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".243", - "extraBaseHits": 39, - "hitByPitch": 3, - "gidp": 11, - "gidpOpp": 59, - "numberOfPitches": 1819, - "pitchesPerPlateAppearance": "4.172", - "walksPerPlateAppearance": ".209", - "strikeoutsPerPlateAppearance": ".142", - "homeRunsPerPlateAppearance": ".048", - "walksPerStrikeout": "1.468", - "iso": ".240", - "reachedOnError": 3, - "walkOffs": 0, - "flyOuts": 50, - "totalSwings": 645, - "swingAndMisses": 130, - "ballsInPlay": 280, - "popOuts": 16, - "lineOuts": 21, - "groundOuts": 109, - "flyHits": 27, - "popHits": 1, - "lineHits": 33, - "groundHits": 23 - }, - "team": { - "id": 120, - "name": "Washington Nationals", - "link": "/api/v1/teams/120" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - }, - { - "season": "2022", - "stat": { - "plateAppearances": 228, - "totalBases": 71, - "leftOnBase": 66, - "sacBunts": 0, - "sacFlies": 0, - "babip": ".261", - "extraBaseHits": 15, - "hitByPitch": 1, - "gidp": 1, - "gidpOpp": 27, - "numberOfPitches": 946, - "pitchesPerPlateAppearance": "4.149", - "walksPerPlateAppearance": ".193", - "strikeoutsPerPlateAppearance": ".149", - "homeRunsPerPlateAppearance": ".026", - "walksPerStrikeout": "1.294", - "iso": ".154", - "reachedOnError": 3, - "walkOffs": 0, - "flyOuts": 32, - "totalSwings": 331, - "swingAndMisses": 57, - "ballsInPlay": 148, - "popOuts": 10, - "lineOuts": 10, - "groundOuts": 53, - "flyHits": 7, - "popHits": 0, - "lineHits": 18, - "groundHits": 18 - }, - "team": { - "id": 135, - "name": "San Diego Padres", - "link": "/api/v1/teams/135" - }, - "player": { - "id": 665742, - "fullName": "Juan Soto", - "link": "/api/v1/people/665742" - }, - "league": { - "id": 104, - "name": "National League", - "link": "/api/v1/league/104" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/hotcoldzone.json b/tests/mock_tests/mock_json/stats/person/hotcoldzone.json deleted file mode 100644 index 87727b37..00000000 --- a/tests/mock_tests/mock_json/stats/person/hotcoldzone.json +++ /dev/null @@ -1,438 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "hotColdZones" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "name": "battingAverage", - "zones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".278" - }, - { - "zone": "02", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".462" - }, - { - "zone": "03", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".435" - }, - { - "zone": "04", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".304" - }, - { - "zone": "05", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".345" - }, - { - "zone": "06", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".308" - }, - { - "zone": "07", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".224" - }, - { - "zone": "08", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".415" - }, - { - "zone": "09", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".367" - }, - { - "zone": "11", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".184" - }, - { - "zone": "12", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".263" - }, - { - "zone": "13", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".144" - }, - { - "zone": "14", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".212" - } - ] - } - }, - { - "stat": { - "name": "onBasePlusSlugging", - "zones": [ - { - "zone": "01", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".611" - }, - { - "zone": "02", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "1.769" - }, - { - "zone": "03", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "1.208" - }, - { - "zone": "04", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".875" - }, - { - "zone": "05", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.068" - }, - { - "zone": "06", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.075" - }, - { - "zone": "07", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".633" - }, - { - "zone": "08", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "1.317" - }, - { - "zone": "09", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "1.033" - }, - { - "zone": "11", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".607" - }, - { - "zone": "12", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".696" - }, - { - "zone": "13", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".420" - }, - { - "zone": "14", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".667" - } - ] - } - }, - { - "stat": { - "name": "onBasePercentage", - "zones": [ - { - "zone": "01", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".278" - }, - { - "zone": "02", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".462" - }, - { - "zone": "03", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".458" - }, - { - "zone": "04", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".304" - }, - { - "zone": "05", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".339" - }, - { - "zone": "06", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".300" - }, - { - "zone": "07", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".224" - }, - { - "zone": "08", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".415" - }, - { - "zone": "09", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".367" - }, - { - "zone": "11", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".446" - }, - { - "zone": "12", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".391" - }, - { - "zone": "13", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".261" - }, - { - "zone": "14", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".406" - } - ] - } - }, - { - "stat": { - "name": "sluggingPercentage", - "zones": [ - { - "zone": "01", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".333" - }, - { - "zone": "02", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "1.308" - }, - { - "zone": "03", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".750" - }, - { - "zone": "04", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".571" - }, - { - "zone": "05", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".729" - }, - { - "zone": "06", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".775" - }, - { - "zone": "07", - "color": "rgba(255, 255, 255, 0.55)", - "temp": "lukewarm", - "value": ".408" - }, - { - "zone": "08", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": ".902" - }, - { - "zone": "09", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": ".667" - }, - { - "zone": "11", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".161" - }, - { - "zone": "12", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".304" - }, - { - "zone": "13", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": ".159" - }, - { - "zone": "14", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": ".261" - } - ] - } - }, - { - "stat": { - "name": "exitVelocity", - "zones": [ - { - "zone": "01", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "96.84" - }, - { - "zone": "02", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "93.93" - }, - { - "zone": "03", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": "88.65" - }, - { - "zone": "04", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "97.78" - }, - { - "zone": "05", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "97.09" - }, - { - "zone": "06", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "97.97" - }, - { - "zone": "07", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "95.06" - }, - { - "zone": "08", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "97.49" - }, - { - "zone": "09", - "color": "rgba(214, 41, 52, .55)", - "temp": "hot", - "value": "100.90" - }, - { - "zone": "11", - "color": "rgba(150, 188, 255, .55)", - "temp": "cool", - "value": "87.63" - }, - { - "zone": "12", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "85.65" - }, - { - "zone": "13", - "color": "rgba(6, 90, 238, .55)", - "temp": "cold", - "value": "82.70" - }, - { - "zone": "14", - "color": "rgba(234, 147, 153, .55)", - "temp": "warm", - "value": "91.63" - } - ] - } - } - ] - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/pitching_player_pitchlog.json b/tests/mock_tests/mock_json/stats/person/pitching_player_pitchlog.json deleted file mode 100644 index 673ad08e..00000000 --- a/tests/mock_tests/mock_json/stats/person/pitching_player_pitchlog.json +++ /dev/null @@ -1,182 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "pitchLog" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "B", - "description": "Ball - Called" - }, - "event": "ball", - "eventType": "ball", - "isInPlay": false, - "isStrike": false, - "isBall": true, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 0, - "inning": 1, - "isTopInning": true, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "223aeedc-89db-49cf-8d29-43745ea41933", - "pitchNumber": 1, - "atBatNumber": 1, - "isPitch": true - } - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "batter": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "game": { - "gamePk": 661042, - "link": "/api/v1.1/game/661042/feed/live", - "content": { - "link": "/api/v1/game/661042/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Strike - Called" - }, - "event": "called_strike", - "eventType": "called_strike", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "isBaseHit": false, - "isAtBat": false, - "isPlateAppearance": false, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "R", - "description": "Right" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 1, - "strikes": 0, - "outs": 0, - "inning": 1, - "isTopInning": true, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "3f4c48c9-19ad-40a8-946b-273183106e69", - "pitchNumber": 2, - "atBatNumber": 1, - "isPitch": true - } - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "batter": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "game": { - "gamePk": 661042, - "link": "/api/v1.1/game/661042/feed/live", - "content": { - "link": "/api/v1/game/661042/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/pitching_player_playlog.json b/tests/mock_tests/mock_json/stats/person/pitching_player_playlog.json deleted file mode 100644 index 5ee1fe3a..00000000 --- a/tests/mock_tests/mock_json/stats/person/pitching_player_playlog.json +++ /dev/null @@ -1,175 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "playLog" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "C", - "description": "Strike - Called" - }, - "description": "Jose Altuve called out on strikes. ", - "event": "strikeout", - "eventType": "strikeout", - "isInPlay": false, - "isStrike": true, - "isBall": false, - "isBaseHit": false, - "isAtBat": true, - "isPlateAppearance": true, - "type": {}, - "batSide": {}, - "pitchHand": {} - }, - "count": { - "balls": 2, - "strikes": 2, - "outs": 0, - "inning": 1, - "isTopInning": true, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "e32d8b81-ceac-4131-8870-a4ac6d018800", - "pitchNumber": 5, - "atBatNumber": 1, - "isPitch": true - } - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "batter": { - "id": 514888, - "fullName": "Jose Altuve", - "link": "/api/v1/people/514888" - }, - "game": { - "gamePk": 661042, - "link": "/api/v1.1/game/661042/feed/live", - "content": { - "link": "/api/v1/game/661042/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }, - { - "season": "2022", - "stat": { - "play": { - "details": { - "call": { - "code": "D", - "description": "Hit Into Play - No Out(s)" - }, - "description": "Michael Brantley singles on a line drive to left fielder Jo Adell. ", - "event": "single", - "eventType": "single", - "isInPlay": true, - "isStrike": false, - "isBall": false, - "isBaseHit": true, - "isAtBat": true, - "isPlateAppearance": true, - "type": { - "code": "FF", - "description": "Four-seam FB" - }, - "batSide": { - "code": "L", - "description": "Left" - }, - "pitchHand": { - "code": "R", - "description": "Right" - } - }, - "count": { - "balls": 0, - "strikes": 0, - "outs": 1, - "inning": 1, - "isTopInning": true, - "runnerOn1b": false, - "runnerOn2b": false, - "runnerOn3b": false - }, - "playId": "42e26427-2f9d-4ad5-b70e-e0d3bac4e772", - "pitchNumber": 1, - "atBatNumber": 2, - "isPitch": true - } - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "opponent": { - "id": 117, - "name": "Houston Astros", - "link": "/api/v1/teams/117" - }, - "date": "2022-04-07", - "gameType": "R", - "isHome": true, - "pitcher": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "batter": { - "id": 488726, - "fullName": "Michael Brantley", - "link": "/api/v1/people/488726" - }, - "game": { - "gamePk": 661042, - "link": "/api/v1.1/game/661042/feed/live", - "content": { - "link": "/api/v1/game/661042/content" - }, - "gameNumber": 1, - "dayNight": "day" - } - }] - }] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/pitching_player_stats.json b/tests/mock_tests/mock_json/stats/person/pitching_player_stats.json deleted file mode 100644 index d883a4bd..00000000 --- a/tests/mock_tests/mock_json/stats/person/pitching_player_stats.json +++ /dev/null @@ -1,363 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "career" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 63, - "gamesStarted": 63, - "groundOuts": 279, - "airOuts": 305, - "runs": 119, - "doubles": 52, - "triples": 2, - "homeRuns": 35, - "strikeOuts": 441, - "baseOnBalls": 118, - "intentionalWalks": 2, - "hits": 263, - "hitByPitch": 13, - "avg": ".206", - "atBats": 1278, - "obp": ".278", - "slg": ".332", - "ops": ".610", - "caughtStealing": 4, - "stolenBases": 7, - "stolenBasePercentage": ".636", - "groundIntoDoublePlay": 20, - "numberOfPitches": 5589, - "era": "2.96", - "inningsPitched": "349.2", - "wins": 28, - "losses": 14, - "saves": 0, - "saveOpportunities": 0, - "holds": 0, - "blownSaves": 0, - "earnedRuns": 115, - "whip": "1.09", - "battersFaced": 1420, - "outs": 1049, - "gamesPitched": 63, - "completeGames": 0, - "shutouts": 0, - "strikes": 3585, - "strikePercentage": ".640", - "hitBatsmen": 13, - "balks": 2, - "wildPitches": 30, - "pickoffs": 0, - "totalBases": 424, - "groundOutsToAirouts": "0.91", - "winPercentage": ".667", - "pitchesPerInning": "15.98", - "gamesFinished": 0, - "strikeoutWalkRatio": "3.74", - "strikeoutsPer9Inn": "11.35", - "walksPer9Inn": "3.04", - "hitsPer9Inn": "6.77", - "runsScoredPer9": "3.06", - "homeRunsPer9": "0.90", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 1, - "sacBunts": 2, - "sacFlies": 8 - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - }, - { - "type": { - "displayName": "careerAdvanced" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "winningPercentage": ".667", - "runsScoredPer9": "3.06", - "battersFaced": 1420, - "babip": ".281", - "obp": ".278", - "slg": ".332", - "ops": ".610", - "strikeoutsPer9": "11.35", - "baseOnBallsPer9": "3.04", - "homeRunsPer9": "0.90", - "hitsPer9": "6.77", - "strikesoutsToWalks": "3.74", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "bequeathedRunners": 30, - "bequeathedRunnersScored": 11, - "stolenBases": 7, - "caughtStealing": 4, - "qualityStarts": 35, - "gamesFinished": 0, - "doubles": 52, - "triples": 2, - "gidp": 20, - "gidpOpp": 150, - "wildPitches": 30, - "balks": 2, - "pickoffs": 0, - "totalSwings": 2656, - "swingAndMisses": 844, - "ballsInPlay": 847, - "runSupport": 172, - "strikePercentage": ".640", - "pitchesPerInning": "15.98", - "pitchesPerPlateAppearance": "3.936", - "walksPerPlateAppearance": ".083", - "strikeoutsPerPlateAppearance": ".311", - "homeRunsPerPlateAppearance": ".025", - "walksPerStrikeout": ".268", - "iso": ".126", - "flyOuts": 163, - "popOuts": 71, - "lineOuts": 71, - "groundOuts": 279, - "flyHits": 50, - "popHits": 1, - "lineHits": 124, - "groundHits": 88 - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "gamesPlayed": 28, - "gamesStarted": 28, - "groundOuts": 129, - "airOuts": 141, - "runs": 45, - "doubles": 23, - "triples": 2, - "homeRuns": 14, - "strikeOuts": 219, - "baseOnBalls": 44, - "intentionalWalks": 0, - "hits": 124, - "hitByPitch": 2, - "avg": ".203", - "atBats": 610, - "obp": ".258", - "slg": ".316", - "ops": ".574", - "caughtStealing": 1, - "stolenBases": 4, - "stolenBasePercentage": ".800", - "groundIntoDoublePlay": 10, - "numberOfPitches": 2629, - "era": "2.33", - "inningsPitched": "166.0", - "wins": 15, - "losses": 9, - "saves": 0, - "saveOpportunities": 0, - "holds": 0, - "blownSaves": 0, - "earnedRuns": 43, - "whip": "1.01", - "battersFaced": 660, - "outs": 498, - "gamesPitched": 28, - "completeGames": 0, - "shutouts": 0, - "strikes": 1724, - "strikePercentage": ".660", - "hitBatsmen": 2, - "balks": 0, - "wildPitches": 14, - "pickoffs": 0, - "totalBases": 193, - "groundOutsToAirouts": "0.91", - "winPercentage": ".625", - "pitchesPerInning": "15.84", - "gamesFinished": 0, - "strikeoutWalkRatio": "4.98", - "strikeoutsPer9Inn": "11.87", - "walksPer9Inn": "2.39", - "hitsPer9Inn": "6.72", - "runsScoredPer9": "2.44", - "homeRunsPer9": "0.76", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "catchersInterference": 1, - "sacBunts": 0, - "sacFlies": 3 - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } - ] - }, - { - "type": { - "displayName": "seasonAdvanced" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "winningPercentage": ".625", - "runsScoredPer9": "2.44", - "battersFaced": 660, - "babip": ".289", - "obp": ".258", - "slg": ".316", - "ops": ".574", - "strikeoutsPer9": "11.87", - "baseOnBallsPer9": "2.39", - "homeRunsPer9": "0.76", - "hitsPer9": "6.72", - "strikesoutsToWalks": "4.98", - "inheritedRunners": 0, - "inheritedRunnersScored": 0, - "bequeathedRunners": 10, - "bequeathedRunnersScored": 2, - "stolenBases": 4, - "caughtStealing": 1, - "qualityStarts": 16, - "gamesFinished": 0, - "doubles": 23, - "triples": 2, - "gidp": 10, - "gidpOpp": 69, - "wildPitches": 14, - "balks": 0, - "pickoffs": 0, - "totalSwings": 1282, - "swingAndMisses": 425, - "ballsInPlay": 394, - "runSupport": 79, - "strikePercentage": ".660", - "pitchesPerInning": "15.84", - "pitchesPerPlateAppearance": "3.983", - "walksPerPlateAppearance": ".067", - "strikeoutsPerPlateAppearance": ".332", - "homeRunsPerPlateAppearance": ".021", - "walksPerStrikeout": ".201", - "iso": ".113", - "flyOuts": 81, - "popOuts": 33, - "lineOuts": 27, - "groundOuts": 129, - "flyHits": 24, - "popHits": 1, - "lineHits": 63, - "groundHits": 36 - }, - "team": { - "id": 108, - "name": "Los Angeles Angels", - "link": "/api/v1/teams/108" - }, - "player": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - }, - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "abbreviation": "MLB" - }, - "gameType": "R" - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/person/spraychart.json b/tests/mock_tests/mock_json/stats/person/spraychart.json deleted file mode 100644 index 69c6ed75..00000000 --- a/tests/mock_tests/mock_json/stats/person/spraychart.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "sprayChart" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "leftField": 3, - "leftCenterField": 11, - "centerField": 18, - "rightCenterField": 35, - "rightField": 33 - }, - "gameType": "R", - "batter": { - "id": 660271, - "fullName": "Shohei Ohtani", - "link": "/api/v1/people/660271" - } - } - ] - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/team/hitting_team_stats.json b/tests/mock_tests/mock_json/stats/team/hitting_team_stats.json deleted file mode 100644 index 7ac3593c..00000000 --- a/tests/mock_tests/mock_json/stats/team/hitting_team_stats.json +++ /dev/null @@ -1,207 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "career" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 18951, - "groundOuts": 55579, - "airOuts": 60176, - "runs": 83856, - "doubles": 28656, - "triples": 5286, - "homeRuns": 13714, - "strikeOuts": 89222, - "baseOnBalls": 63371, - "intentionalWalks": 2245, - "hits": 165714, - "hitByPitch": 4586, - "avg": ".258", - "atBats": 642577, - "obp": ".327", - "slg": ".383", - "ops": ".710", - "caughtStealing": 4795, - "stolenBases": 11834, - "stolenBasePercentage": ".712", - "groundIntoDoublePlay": 10338, - "numberOfPitches": 943087, - "plateAppearances": 724217, - "totalBases": 246088, - "rbi": 77208, - "leftOnBase": 120358, - "sacBunts": 10633, - "sacFlies": 3020, - "babip": ".280", - "groundOutsToAirouts": "0.92", - "catchersInterference": 30, - "atBatsPerHomeRun": "46.86" - }, - "team": { - "id": 133, - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "careerAdvanced" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "plateAppearances": 724217, - "totalBases": 246088, - "leftOnBase": 120358, - "sacBunts": 10633, - "sacFlies": 3020, - "babip": ".280", - "extraBaseHits": 47656, - "hitByPitch": 4586, - "gidp": 10338, - "gidpOpp": 42607, - "numberOfPitches": 943087, - "pitchesPerPlateAppearance": "1.302", - "walksPerPlateAppearance": ".088", - "strikeoutsPerPlateAppearance": ".123", - "homeRunsPerPlateAppearance": ".019", - "walksPerStrikeout": ".710", - "iso": ".125", - "reachedOnError": 3019, - "walkOffs": 731, - "flyOuts": 34906, - "totalSwings": 455234, - "swingAndMisses": -240895, - "ballsInPlay": 567008, - "popOuts": 13180, - "lineOuts": 12090, - "groundOuts": 55579, - "flyHits": 8504, - "popHits": 428, - "lineHits": 21512, - "groundHits": 14797 - }, - "team": { - "id": 133, - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "gamesPlayed": 162, - "groundOuts": 1439, - "airOuts": 1394, - "runs": 568, - "doubles": 249, - "triples": 15, - "homeRuns": 137, - "strikeOuts": 1389, - "baseOnBalls": 433, - "intentionalWalks": 7, - "hits": 1147, - "hitByPitch": 59, - "avg": ".216", - "atBats": 5314, - "obp": ".281", - "slg": ".346", - "ops": ".627", - "caughtStealing": 23, - "stolenBases": 78, - "stolenBasePercentage": ".772", - "groundIntoDoublePlay": 109, - "numberOfPitches": 22568, - "plateAppearances": 5863, - "totalBases": 1837, - "rbi": 537, - "leftOnBase": 969, - "sacBunts": 22, - "sacFlies": 33, - "babip": ".264", - "groundOutsToAirouts": "1.03", - "catchersInterference": 2, - "atBatsPerHomeRun": "38.79" - }, - "team": { - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "seasonAdvanced" - }, - "group": { - "displayName": "hitting" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "plateAppearances": 5863, - "totalBases": 1837, - "leftOnBase": 969, - "sacBunts": 22, - "sacFlies": 33, - "babip": ".264", - "extraBaseHits": 401, - "hitByPitch": 59, - "gidp": 109, - "gidpOpp": 670, - "numberOfPitches": 22568, - "pitchesPerPlateAppearance": "3.849", - "walksPerPlateAppearance": ".074", - "strikeoutsPerPlateAppearance": ".237", - "homeRunsPerPlateAppearance": ".023", - "walksPerStrikeout": ".312", - "iso": ".130", - "reachedOnError": 32, - "walkOffs": 14, - "flyOuts": 758, - "totalSwings": 11013, - "swingAndMisses": 2992, - "ballsInPlay": 3980, - "popOuts": 272, - "lineOuts": 364, - "groundOuts": 1439, - "flyHits": 213, - "popHits": 7, - "lineHits": 546, - "groundHits": 381 - }, - "team": { - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133" - } - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/stats/team/pitching_team_stats.json b/tests/mock_tests/mock_json/stats/team/pitching_team_stats.json deleted file mode 100644 index 5241b37d..00000000 --- a/tests/mock_tests/mock_json/stats/team/pitching_team_stats.json +++ /dev/null @@ -1,285 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "stats": [ - { - "type": { - "displayName": "career" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "gamesPlayed": 18951, - "gamesStarted": 18951, - "groundOuts": 58724, - "airOuts": 59285, - "runs": 86416, - "doubles": 12148, - "triples": 1413, - "homeRuns": 13786, - "strikeOuts": 91707, - "baseOnBalls": 65298, - "intentionalWalks": 2602, - "hits": 168140, - "hitByPitch": 4742, - "avg": ".261", - "atBats": 644309, - "obp": ".332", - "slg": ".162", - "ops": ".494", - "caughtStealing": 2344, - "stolenBases": 4686, - "stolenBasePercentage": ".667", - "groundIntoDoublePlay": 5834, - "numberOfPitches": 917731, - "era": "3.98", - "inningsPitched": "168935.1", - "wins": 9210, - "losses": 9654, - "saves": 3010, - "saveOpportunities": 3557, - "holds": 1686, - "blownSaves": 547, - "earnedRuns": 74762, - "whip": "1.38", - "battersFaced": 725026, - "outs": 506806, - "gamesPitched": 18951, - "completeGames": 5701, - "shutouts": 1210, - "strikes": 590187, - "strikePercentage": ".640", - "hitBatsmen": 4742, - "balks": 590, - "wildPitches": 5187, - "pickoffs": 544, - "totalBases": 104641, - "groundOutsToAirouts": "0.99", - "winPercentage": ".488", - "pitchesPerInning": "5.43", - "gamesFinished": 13245, - "strikeoutWalkRatio": "1.40", - "strikeoutsPer9Inn": "4.89", - "walksPer9Inn": "3.48", - "hitsPer9Inn": "8.96", - "runsScoredPer9": "4.60", - "homeRunsPer9": "0.73", - "catchersInterference": 47, - "sacBunts": 7482, - "sacFlies": 3147 - }, - "team": { - "id": 133, - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "careerAdvanced" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "stat": { - "winningPercentage": ".488", - "runsScoredPer9": "4.60", - "battersFaced": 725026, - "babip": ".285", - "obp": ".332", - "slg": ".162", - "ops": ".494", - "strikeoutsPer9": "4.89", - "baseOnBallsPer9": "3.48", - "homeRunsPer9": "0.73", - "hitsPer9": "8.96", - "strikesoutsToWalks": "1.40", - "stolenBases": 4686, - "caughtStealing": 2344, - "qualityStarts": 3735, - "gamesFinished": 13245, - "doubles": 12148, - "triples": 1413, - "gidp": 5834, - "gidpOpp": 43743, - "wildPitches": 5187, - "balks": 590, - "pickoffs": 544, - "totalSwings": 455720, - "swingAndMisses": 106239, - "ballsInPlay": 220814, - "runSupport": 35211, - "strikePercentage": ".640", - "pitchesPerInning": "5.43", - "pitchesPerPlateAppearance": "1.266", - "walksPerPlateAppearance": ".090", - "strikeoutsPerPlateAppearance": ".126", - "homeRunsPerPlateAppearance": ".019", - "walksPerStrikeout": ".712", - "iso": "-.099", - "flyOuts": 33922, - "popOuts": 12919, - "lineOuts": 12444, - "groundOuts": 58724, - "flyHits": 8396, - "popHits": 353, - "lineHits": 21696, - "groundHits": 15605 - }, - "team": { - "id": 133, - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "season" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "gamesPlayed": 162, - "gamesStarted": 162, - "groundOuts": 1384, - "airOuts": 1563, - "runs": 770, - "doubles": 313, - "triples": 28, - "homeRuns": 195, - "strikeOuts": 1203, - "baseOnBalls": 503, - "intentionalWalks": 37, - "hits": 1394, - "hitByPitch": 72, - "avg": ".254", - "atBats": 5491, - "obp": ".323", - "slg": ".428", - "ops": ".751", - "caughtStealing": 29, - "stolenBases": 77, - "stolenBasePercentage": ".726", - "groundIntoDoublePlay": 118, - "numberOfPitches": 23324, - "era": "4.52", - "inningsPitched": "1426.1", - "wins": 60, - "losses": 102, - "saves": 34, - "saveOpportunities": 59, - "holds": 105, - "blownSaves": 25, - "earnedRuns": 717, - "whip": "1.33", - "battersFaced": 6121, - "outs": 4279, - "gamesPitched": 162, - "completeGames": 0, - "shutouts": 7, - "strikes": 14834, - "strikePercentage": ".640", - "hitBatsmen": 72, - "balks": 5, - "wildPitches": 62, - "pickoffs": 13, - "totalBases": 2348, - "groundOutsToAirouts": "0.89", - "winPercentage": ".370", - "pitchesPerInning": "16.35", - "gamesFinished": 162, - "strikeoutWalkRatio": "2.39", - "strikeoutsPer9Inn": "7.59", - "walksPer9Inn": "3.17", - "hitsPer9Inn": "8.80", - "runsScoredPer9": "4.86", - "homeRunsPer9": "1.23", - "catchersInterference": 2, - "sacBunts": 15, - "sacFlies": 38 - }, - "team": { - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133" - } - } - ] - }, - { - "type": { - "displayName": "seasonAdvanced" - }, - "group": { - "displayName": "pitching" - }, - "exemptions": [], - "splits": [ - { - "season": "2022", - "stat": { - "winningPercentage": ".488", - "runsScoredPer9": "4.86", - "battersFaced": 6121, - "babip": ".290", - "obp": ".323", - "slg": ".428", - "ops": ".751", - "strikeoutsPer9": "7.59", - "baseOnBallsPer9": "3.17", - "homeRunsPer9": "1.23", - "hitsPer9": "8.80", - "strikesoutsToWalks": "2.39", - "stolenBases": 77, - "caughtStealing": 29, - "qualityStarts": 47, - "gamesFinished": 162, - "doubles": 313, - "triples": 28, - "gidp": 118, - "gidpOpp": 860, - "wildPitches": 62, - "balks": 5, - "pickoffs": 13, - "totalSwings": 11106, - "swingAndMisses": 2639, - "ballsInPlay": 4342, - "runSupport": 568, - "strikePercentage": ".640", - "pitchesPerInning": "16.35", - "pitchesPerPlateAppearance": "3.810", - "walksPerPlateAppearance": ".082", - "strikeoutsPerPlateAppearance": ".197", - "homeRunsPerPlateAppearance": ".032", - "walksPerStrikeout": ".418", - "iso": ".174", - "flyOuts": 864, - "popOuts": 325, - "lineOuts": 374, - "groundOuts": 1384, - "flyHits": 325, - "popHits": 6, - "lineHits": 621, - "groundHits": 442 - }, - "team": { - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133" - } - } ] - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/teams/team.json b/tests/mock_tests/mock_json/teams/team.json deleted file mode 100644 index 751ffe3a..00000000 --- a/tests/mock_tests/mock_json/teams/team.json +++ /dev/null @@ -1,51 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "teams": [ - { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133", - "season": 2022, - "venue": { - "id": 10, - "name": "Oakland Coliseum", - "link": "/api/v1/venues/10" - }, - "springVenue": { - "id": 2507, - "link": "/api/v1/venues/2507" - }, - "teamCode": "oak", - "fileCode": "oak", - "abbreviation": "OAK", - "teamName": "Athletics", - "locationName": "Oakland", - "firstYearOfPlay": "1901", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Oakland", - "franchiseName": "Oakland", - "clubName": "Athletics", - "active": true - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/teams/team_coaches.json b/tests/mock_tests/mock_json/teams/team_coaches.json deleted file mode 100644 index 6032b224..00000000 --- a/tests/mock_tests/mock_json/teams/team_coaches.json +++ /dev/null @@ -1,151 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "roster": [ - { - "person": { - "id": 117276, - "fullName": "Mark Kotsay", - "link": "/api/v1/people/117276" - }, - "jerseyNumber": "7", - "job": "Manager", - "jobId": "MNGR", - "title": "Manager" - }, - { - "person": { - "id": 470252, - "fullName": "Darren Bush", - "link": "/api/v1/people/470252" - }, - "jerseyNumber": "51", - "job": "Bench Coach", - "jobId": "COAB", - "title": "Bench Coach" - }, - { - "person": { - "id": 452784, - "fullName": "Tommy Everidge", - "link": "/api/v1/people/452784" - }, - "jerseyNumber": "52", - "job": "Hitting Coach", - "jobId": "COAT", - "title": "Hitting Coach" - }, - { - "person": { - "id": 112849, - "fullName": "Chris Cron", - "link": "/api/v1/people/112849" - }, - "jerseyNumber": "41", - "job": "Assistant Hitting Coach", - "jobId": "COAA", - "title": "Assistant Hitting Coach" - }, - { - "person": { - "id": 491913, - "fullName": "Scott Emerson", - "link": "/api/v1/people/491913" - }, - "jerseyNumber": "14", - "job": "Pitching Coach", - "jobId": "COAP", - "title": "Pitching Coach" - }, - { - "person": { - "id": 110119, - "fullName": "Mike Aldrete", - "link": "/api/v1/people/110119" - }, - "jerseyNumber": "18", - "job": "First Base Coach", - "jobId": "COA1", - "title": "First Base Coach" - }, - { - "person": { - "id": 440009, - "fullName": "Eric Martins", - "link": "/api/v1/people/440009" - }, - "jerseyNumber": "3", - "job": "Third Base Coach", - "jobId": "COA3", - "title": "Third Base Coach" - }, - { - "person": { - "id": 592543, - "fullName": "Mike McCarthy", - "link": "/api/v1/people/592543" - }, - "jerseyNumber": "", - "job": "Bullpen Coach", - "jobId": "COAU", - "title": "Bullpen Coach" - }, - { - "person": { - "id": 116534, - "fullName": "Marcus Jensen", - "link": "/api/v1/people/116534" - }, - "jerseyNumber": "", - "job": "Quality Control Coach", - "jobId": "QUAC", - "title": "Quality Control Coach" - }, - { - "person": { - "id": 458031, - "fullName": "Dustin Hughes", - "link": "/api/v1/people/458031" - }, - "jerseyNumber": "91", - "job": "Bullpen Catcher", - "jobId": "BCAT", - "title": "Bullpen Catcher" - }, - { - "person": { - "id": 470795, - "fullName": "Scott Steinmann", - "link": "/api/v1/people/470795" - }, - "jerseyNumber": "", - "job": "Performance Coach", - "jobId": "PERF", - "title": "Hitting Performance Coach" - }, - { - "person": { - "id": 120288, - "fullName": "Gil Patterson", - "link": "/api/v1/people/120288" - }, - "jerseyNumber": "", - "job": "Mental Performance Coordinator", - "jobId": "MPCO", - "title": "Minor League Pitching Coordinator" - }, - { - "person": { - "id": 460183, - "fullName": "Lloyd Turner", - "link": "/api/v1/people/460183" - }, - "jerseyNumber": "", - "job": "Hitting Analytics Instructor", - "jobId": "HANI", - "title": "Hitting Technology Coach" - } - ], - "link": "/api/v1/teams/133/coaches", - "teamId": 133, - "rosterType": "coach" -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/teams/team_roster_coaches.json b/tests/mock_tests/mock_json/teams/team_roster_coaches.json deleted file mode 100644 index 66a427a9..00000000 --- a/tests/mock_tests/mock_json/teams/team_roster_coaches.json +++ /dev/null @@ -1,150 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "roster": [ - { - "person": { - "id": 117276, - "fullName": "Mark Kotsay", - "link": "/api/v1/people/117276" - }, - "jerseyNumber": "7", - "job": "Manager", - "jobId": "MNGR", - "title": "Manager" - }, - { - "person": { - "id": 470252, - "fullName": "Darren Bush", - "link": "/api/v1/people/470252" - }, - "jerseyNumber": "51", - "job": "Bench Coach", - "jobId": "COAB", - "title": "Bench Coach" - }, - { - "person": { - "id": 452784, - "fullName": "Tommy Everidge", - "link": "/api/v1/people/452784" - }, - "jerseyNumber": "52", - "job": "Hitting Coach", - "jobId": "COAT", - "title": "Hitting Coach" - }, - { - "person": { - "id": 112849, - "fullName": "Chris Cron", - "link": "/api/v1/people/112849" - }, - "jerseyNumber": "41", - "job": "Assistant Hitting Coach", - "jobId": "COAA", - "title": "Assistant Hitting Coach" - }, - { - "person": { - "id": 491913, - "fullName": "Scott Emerson", - "link": "/api/v1/people/491913" - }, - "jerseyNumber": "14", - "job": "Pitching Coach", - "jobId": "COAP", - "title": "Pitching Coach" - }, - { - "person": { - "id": 110119, - "fullName": "Mike Aldrete", - "link": "/api/v1/people/110119" - }, - "jerseyNumber": "18", - "job": "First Base Coach", - "jobId": "COA1", - "title": "First Base Coach" - }, - { - "person": { - "id": 440009, - "fullName": "Eric Martins", - "link": "/api/v1/people/440009" - }, - "jerseyNumber": "3", - "job": "Third Base Coach", - "jobId": "COA3", - "title": "Third Base Coach" - }, - { - "person": { - "id": 592543, - "fullName": "Mike McCarthy", - "link": "/api/v1/people/592543" - }, - "jerseyNumber": "", - "job": "Bullpen Coach", - "jobId": "COAU", - "title": "Bullpen Coach" - }, - { - "person": { - "id": 116534, - "fullName": "Marcus Jensen", - "link": "/api/v1/people/116534" - }, - "jerseyNumber": "", - "job": "Quality Control Coach", - "jobId": "QUAC", - "title": "Quality Control Coach" - }, - { - "person": { - "id": 458031, - "fullName": "Dustin Hughes", - "link": "/api/v1/people/458031" - }, - "jerseyNumber": "91", - "job": "Bullpen Catcher", - "jobId": "BCAT", - "title": "Bullpen Catcher" - }, - { - "person": { - "id": 470795, - "fullName": "Scott Steinmann", - "link": "/api/v1/people/470795" - }, - "jerseyNumber": "", - "job": "Performance Coach", - "jobId": "PERF", - "title": "Hitting Performance Coach" - }, - { - "person": { - "id": 120288, - "fullName": "Gil Patterson", - "link": "/api/v1/people/120288" - }, - "jerseyNumber": "", - "job": "Mental Performance Coordinator", - "jobId": "MPCO", - "title": "Minor League Pitching Coordinator" - }, - { - "person": { - "id": 460183, - "fullName": "Lloyd Turner", - "link": "/api/v1/people/460183" - }, - "jerseyNumber": "", - "job": "Hitting Analytics Instructor", - "jobId": "HANI", - "title": "Hitting Technology Coach" - } ], - "link": "/api/v1/teams/133/coaches", - "teamId": 133, - "rosterType": "coach" -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/teams/team_roster_players.json b/tests/mock_tests/mock_json/teams/team_roster_players.json deleted file mode 100644 index bd544dd6..00000000 --- a/tests/mock_tests/mock_json/teams/team_roster_players.json +++ /dev/null @@ -1,710 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "roster": [ - { - "person": { - "id": 640462, - "fullName": "A.J. Puk", - "link": "/api/v1/people/640462" - }, - "jerseyNumber": "33", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 670124, - "fullName": "Adam Oller", - "link": "/api/v1/people/670124" - }, - "jerseyNumber": "36", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 661309, - "fullName": "Adrian Martinez", - "link": "/api/v1/people/661309" - }, - "jerseyNumber": "55", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 667670, - "fullName": "Brent Rooker", - "link": "/api/v1/people/667670" - }, - "jerseyNumber": "", - "position": { - "code": "7", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "LF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 670276, - "fullName": "Cal Stevenson", - "link": "/api/v1/people/670276" - }, - "jerseyNumber": "37", - "position": { - "code": "7", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "LF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 642137, - "fullName": "Cody Thomas", - "link": "/api/v1/people/642137" - }, - "jerseyNumber": "48", - "position": { - "code": "7", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "LF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 608344, - "fullName": "Cole Irvin", - "link": "/api/v1/people/608344" - }, - "jerseyNumber": "19", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 668843, - "fullName": "Conner Capel", - "link": "/api/v1/people/668843" - }, - "jerseyNumber": "72", - "position": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 665506, - "fullName": "Cristian Pache", - "link": "/api/v1/people/665506" - }, - "jerseyNumber": "20", - "position": { - "code": "8", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "CF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 666204, - "fullName": "Dany Jimenez", - "link": "/api/v1/people/666204" - }, - "jerseyNumber": "56", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 660650, - "fullName": "Dermis Garcia", - "link": "/api/v1/people/660650" - }, - "jerseyNumber": "76", - "position": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 642758, - "fullName": "Domingo Acevedo", - "link": "/api/v1/people/642758" - }, - "jerseyNumber": "68", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 676391, - "fullName": "Ernie Clement", - "link": "/api/v1/people/676391" - }, - "jerseyNumber": "44", - "position": { - "code": "5", - "name": "Third Base", - "type": "Infielder", - "abbreviation": "3B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 663687, - "fullName": "Hogan Harris", - "link": "/api/v1/people/663687" - }, - "jerseyNumber": "", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 676664, - "fullName": "JP Sears", - "link": "/api/v1/people/676664" - }, - "jerseyNumber": "38", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 621076, - "fullName": "James Kaprielian", - "link": "/api/v1/people/621076" - }, - "jerseyNumber": "32", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 606303, - "fullName": "Joel Payamps", - "link": "/api/v1/people/606303" - }, - "jerseyNumber": "30", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 681146, - "fullName": "Jonah Bride", - "link": "/api/v1/people/681146" - }, - "jerseyNumber": "77", - "position": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 672478, - "fullName": "Jordan Diaz", - "link": "/api/v1/people/672478" - }, - "jerseyNumber": "75", - "position": { - "code": "5", - "name": "Third Base", - "type": "Infielder", - "abbreviation": "3B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 686610, - "fullName": "Ken Waldichuk", - "link": "/api/v1/people/686610" - }, - "jerseyNumber": "64", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 675656, - "fullName": "Kevin Smith", - "link": "/api/v1/people/675656" - }, - "jerseyNumber": "1", - "position": { - "code": "6", - "name": "Shortstop", - "type": "Infielder", - "abbreviation": "SS" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 669912, - "fullName": "Kirby Snead", - "link": "/api/v1/people/669912" - }, - "jerseyNumber": "54", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 671732, - "fullName": "Lawrence Butler", - "link": "/api/v1/people/671732" - }, - "jerseyNumber": "", - "position": { - "code": "O", - "name": "Outfield", - "type": "Outfielder", - "abbreviation": "OF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 665622, - "fullName": "Luis Medina", - "link": "/api/v1/people/665622" - }, - "jerseyNumber": "", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 669397, - "fullName": "Nick Allen", - "link": "/api/v1/people/669397" - }, - "jerseyNumber": "2", - "position": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 621112, - "fullName": "Paul Blackburn", - "link": "/api/v1/people/621112" - }, - "jerseyNumber": "58", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 657656, - "fullName": "Ramon Laureano", - "link": "/api/v1/people/657656" - }, - "jerseyNumber": "22", - "position": { - "code": "9", - "name": "Outfielder", - "type": "Outfielder", - "abbreviation": "RF" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 594580, - "fullName": "Sam Moll", - "link": "/api/v1/people/594580" - }, - "jerseyNumber": "60", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 669221, - "fullName": "Sean Murphy", - "link": "/api/v1/people/669221" - }, - "jerseyNumber": "12", - "position": { - "code": "2", - "name": "Catcher", - "type": "Catcher", - "abbreviation": "C" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 664913, - "fullName": "Seth Brown", - "link": "/api/v1/people/664913" - }, - "jerseyNumber": "15", - "position": { - "code": "3", - "name": "First Base", - "type": "Infielder", - "abbreviation": "1B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 669127, - "fullName": "Shea Langeliers", - "link": "/api/v1/people/669127" - }, - "jerseyNumber": "23", - "position": { - "code": "10", - "name": "Designated Hitter", - "type": "Hitter", - "abbreviation": "DH" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 643393, - "fullName": "Tony Kemp", - "link": "/api/v1/people/643393" - }, - "jerseyNumber": "5", - "position": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 664202, - "fullName": "Tyler Cyr", - "link": "/api/v1/people/664202" - }, - "jerseyNumber": "57", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 605353, - "fullName": "Vimael Machin", - "link": "/api/v1/people/605353" - }, - "jerseyNumber": "31", - "position": { - "code": "4", - "name": "Second Base", - "type": "Infielder", - "abbreviation": "2B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 660634, - "fullName": "Yonny Hernandez", - "link": "/api/v1/people/660634" - }, - "jerseyNumber": "", - "position": { - "code": "5", - "name": "Third Base", - "type": "Infielder", - "abbreviation": "3B" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 667427, - "fullName": "Zach Jackson", - "link": "/api/v1/people/667427" - }, - "jerseyNumber": "61", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - }, - { - "person": { - "id": 656657, - "fullName": "Zach Logue", - "link": "/api/v1/people/656657" - }, - "jerseyNumber": "67", - "position": { - "code": "1", - "name": "Pitcher", - "type": "Pitcher", - "abbreviation": "P" - }, - "status": { - "code": "A", - "description": "Active" - }, - "parentTeamId": 133 - } ], - "link": "/api/v1/teams/133/roster", - "teamId": 133, - "rosterType": "active" -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/teams/teams.json b/tests/mock_tests/mock_json/teams/teams.json deleted file mode 100644 index 6dc99366..00000000 --- a/tests/mock_tests/mock_json/teams/teams.json +++ /dev/null @@ -1,215 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "teams": [ { - "allStarStatus": "N", - "id": 4124, - "name": "Pensacola Blue Wahoos", - "link": "/api/v1/teams/4124", - "season": 2022, - "venue": { - "id": 4329, - "name": "Blue Wahoos Stadium", - "link": "/api/v1/venues/4329" - }, - "teamCode": "pen", - "fileCode": "t4124", - "abbreviation": "PNS", - "teamName": "Blue Wahoos", - "locationName": "Pensacola", - "firstYearOfPlay": "2012", - "league": { - "id": 111, - "name": "Southern League", - "link": "/api/v1/league/111" - }, - "division": { - "id": 240, - "name": "Southern League South", - "link": "/api/v1/divisions/240" - }, - "sport": { - "id": 12, - "link": "/api/v1/sports/12", - "name": "Double-A" - }, - "shortName": "Pensacola", - "parentOrgName": "Miami Marlins", - "parentOrgId": 146, - "franchiseName": "Pensacola", - "clubName": "Blue Wahoos", - "active": true - }, - { - "allStarStatus": "N", - "id": 2101, - "name": "DSL Brewers 2", - "link": "/api/v1/teams/2101", - "season": 2022, - "venue": { - "id": 401, - "name": "TBD", - "link": "/api/v1/venues/401" - }, - "teamCode": "brc", - "fileCode": "t2101", - "abbreviation": "DSL BRW2", - "teamName": "DSL Brewers 2", - "locationName": "United States", - "firstYearOfPlay": "1990", - "league": { - "id": 130, - "name": "Dominican Summer League", - "link": "/api/v1/league/130" - }, - "division": { - "id": 246, - "name": "Dominican Summer League San Pedro", - "link": "/api/v1/divisions/246" - }, - "sport": { - "id": 16, - "link": "/api/v1/sports/16", - "name": "Rookie" - }, - "shortName": "DSL Brewers 2", - "parentOrgName": "Milwaukee Brewers", - "parentOrgId": 158, - "franchiseName": "DSL Brewers 2", - "clubName": "DSL Brewers 2", - "active": true - }, - { - "allStarStatus": "N", - "id": 3130, - "name": "DSL BAL Orange", - "link": "/api/v1/teams/3130", - "season": 2022, - "venue": { - "id": 401, - "name": "TBD", - "link": "/api/v1/venues/401" - }, - "teamCode": "dba", - "fileCode": "t3130", - "abbreviation": "DSL BALO", - "teamName": "DSL BAL Orange", - "locationName": "United States", - "firstYearOfPlay": "2009", - "league": { - "id": 130, - "name": "Dominican Summer League", - "link": "/api/v1/league/130" - }, - "division": { - "id": 250, - "name": "Dominican Summer League Baseball City", - "link": "/api/v1/divisions/250" - }, - "sport": { - "id": 16, - "link": "/api/v1/sports/16", - "name": "Rookie" - }, - "shortName": "DSL BAL Orange", - "parentOrgName": "Baltimore Orioles", - "parentOrgId": 110, - "franchiseName": "DSL BAL Orange", - "clubName": "DSL BAL Orange", - "active": true - }, - { - "springLeague" : { - "id" : 114, - "name" : "Cactus League", - "link" : "/api/v1/league/114", - "abbreviation" : "CL" - }, - "allStarStatus" : "N", - "id" : 136, - "name" : "Seattle Mariners", - "link" : "/api/v1/teams/136", - "season" : 2022, - "venue" : { - "id" : 680, - "name" : "T-Mobile Park", - "link" : "/api/v1/venues/680" - }, - "springVenue" : { - "id" : 2530, - "link" : "/api/v1/venues/2530" - }, - "teamCode" : "sea", - "fileCode" : "sea", - "abbreviation" : "SEA", - "teamName" : "Mariners", - "locationName" : "Seattle", - "firstYearOfPlay" : "1977", - "league" : { - "id" : 103, - "name" : "American League", - "link" : "/api/v1/league/103" - }, - "division" : { - "id" : 200, - "name" : "American League West", - "link" : "/api/v1/divisions/200" - }, - "sport" : { - "id" : 1, - "link" : "/api/v1/sports/1", - "name" : "Major League Baseball" - }, - "shortName" : "Seattle", - "franchiseName" : "Seattle", - "clubName" : "Mariners", - "active" : true - }, - { - "springLeague": { - "id": 114, - "name": "Cactus League", - "link": "/api/v1/league/114", - "abbreviation": "CL" - }, - "allStarStatus": "N", - "id": 133, - "name": "Oakland Athletics", - "link": "/api/v1/teams/133", - "season": 2022, - "venue": { - "id": 10, - "name": "Oakland Coliseum", - "link": "/api/v1/venues/10" - }, - "springVenue": { - "id": 2507, - "link": "/api/v1/venues/2507" - }, - "teamCode": "oak", - "fileCode": "oak", - "abbreviation": "OAK", - "teamName": "Athletics", - "locationName": "Oakland", - "firstYearOfPlay": "1901", - "league": { - "id": 103, - "name": "American League", - "link": "/api/v1/league/103" - }, - "division": { - "id": 200, - "name": "American League West", - "link": "/api/v1/divisions/200" - }, - "sport": { - "id": 1, - "link": "/api/v1/sports/1", - "name": "Major League Baseball" - }, - "shortName": "Oakland", - "franchiseName": "Oakland", - "clubName": "Athletics", - "active": true - } - ] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/venues/venue.json b/tests/mock_tests/mock_json/venues/venue.json deleted file mode 100644 index 8eaff74b..00000000 --- a/tests/mock_tests/mock_json/venues/venue.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "venues": [ - { - "id": 31, - "name": "PNC Park", - "link": "/api/v1/venues/31", - "active": true - }] -} \ No newline at end of file diff --git a/tests/mock_tests/mock_json/venues/venues.json b/tests/mock_tests/mock_json/venues/venues.json deleted file mode 100644 index 57bfafab..00000000 --- a/tests/mock_tests/mock_json/venues/venues.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "copyright": "Copyright 2022 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", - "venues": [ - { - "id": 5515, - "name": "Colorado Convention Center", - "link": "/api/v1/venues/5515", - "active": true - }, - { - "id": 5520, - "name": "Virginia Credit Union Stadium", - "link": "/api/v1/venues/5520", - "active": true - }, - { - "id": 5525, - "name": "ABC Supply Stadium", - "link": "/api/v1/venues/5525", - "active": true - }, - { - "id": 4009, - "name": "Miyagi Baseball Stadium", - "link": "/api/v1/venues/4009", - "active": false - }, - { - "id": 4010, - "name": "Tsuruoka Dream Stadium", - "link": "/api/v1/venues/4010", - "active": false - }, - { - "id": 4011, - "name": "Meiji Jingu Stadium", - "link": "/api/v1/venues/4011", - "active": false - }, - { - "id": 31, - "name": "PNC Park", - "link": "/api/v1/venues/31", - "active": true - } ] -} \ No newline at end of file diff --git a/tests/mock_tests/schedules/test_schedule_mock.py b/tests/mock_tests/schedules/test_schedule_mock.py deleted file mode 100644 index 7a1bf7f7..00000000 --- a/tests/mock_tests/schedules/test_schedule_mock.py +++ /dev/null @@ -1,91 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb -from mlbstatsapi.models.schedules import Schedule, ScheduleGames - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_schedule_date = os.path.join(current_directory, "../mock_json/schedule/schedule_date.json") -path_to_schedule_start_end_dates = os.path.join(current_directory, "../mock_json/schedule/schedule_start_end_date.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") - -SCHEDULES = open(path_to_schedule_date, "r", encoding="utf-8-sig").read() -SCHEDULE = open(path_to_schedule_start_end_dates, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestScheduleMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.al_team = 133 - - cls.mock_schedule = json.loads(SCHEDULE) - cls.mock_schedules = json.loads(SCHEDULE) - - cls.error_500 = json.loads(ERROR_500) - cls.mock_not_found = json.loads(NOT_FOUND_404) - - - @classmethod - def tearDownClass(cls) -> None: - pass - - - def test_get_schedule(self, m ): - """get_schedule should return schedules for date, starDate, endDate""" - m.get('https://statsapi.mlb.com/api/v1/schedule?date=04/07/2022&sportId=1', json=self.mock_schedule, - status_code=200) - self.date = '04/07/2022' - self.sport_id = 1 - schedule = self.mlb.get_schedule(date=self.date) - - # get_schedule should return Schedule object - self.assertIsInstance(schedule, Schedule) - # get_schedule should return dates - self.assertTrue(schedule.dates) - - def test_get_schedule_start_end_dates(self, m): - """get_schedule should return a schedule object with start_date, end_date""" - m.get('https://statsapi.mlb.com/api/v1/schedule?sportId=1&startDate=10/10/2022&endDate=10/13/2022', json=self.mock_schedules, - status_code=200) - self.sport_id = 1 - self.start_date = '10/10/2022' - self.end_date = '10/13/2022' - schedule = self.mlb.get_schedule(start_date=self.start_date, end_date=self.end_date, sport_id=self.sport_id) - - # get_schedule should return Schedule object - self.assertIsInstance(schedule, Schedule) - - # list should contain more than 1 object - self.assertTrue(len(schedule.dates) > 1) - - - def test_get_scheduled_games_by_date(self, m): - """get_schedule should return a ScheduledGames object with start_date, end_date""" - m.get('https://statsapi.mlb.com/api/v1/schedule?sportId=1&startDate=10/10/2022&endDate=10/13/2022', json=self.mock_schedules, - status_code=200) - self.sport_id = 1 - self.start_date = '10/10/2022' - self.end_date = '10/13/2022' - - scheduled_games = self.mlb.get_scheduled_games_by_date(start_date=self.start_date, end_date=self.end_date, sport_id=1) - - # scheduled games should not be none - self.assertIsNotNone(scheduled_games) - - self.assertIsInstance(scheduled_games, list) - - # scheduled games should not be empty list - self.assertNotEqual(scheduled_games, []) - - scheduled_game = scheduled_games[0] - - self.assertIsInstance(scheduled_game, ScheduleGames) \ No newline at end of file diff --git a/tests/mock_tests/standings/test_standings_mock.py b/tests/mock_tests/standings/test_standings_mock.py deleted file mode 100644 index f546c98d..00000000 --- a/tests/mock_tests/standings/test_standings_mock.py +++ /dev/null @@ -1,56 +0,0 @@ -from unittest.mock import patch -import unittest -import requests_mock -import json -import os - -from mlbstatsapi.models.standings import Standings -from mlbstatsapi import Mlb - -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_standings = os.path.join(current_directory, "../mock_json/standings/standings.json") -STANDINGS_JSON_FILE = open(path_to_standings, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestStandingsMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.standings_mock = json.loads(STANDINGS_JSON_FILE) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_get_standings(self, m): - """This test should return a 200 and Round""" - - m.get('https://statsapi.mlb.com/api/v1/standings?leagueId=103&season=2018', json=self.standings_mock, - status_code=200) - - # set league id - league_id = 103 - # set season - season = 2018 - - # call get_standings return list of standings - standings = self.mlb.get_standings(league_id, season) - - # Gamepace should not be None - self.assertIsNotNone(standings) - - # list should not be empty - self.assertNotEqual(standings, []) - - # items in list should be standings - self.assertIsInstance(standings[0], Standings) - - standing = standings[0] - - # sportgamepace should not be none - self.assertIsNotNone(standing) - - # standings should have attrs set - self.assertTrue(standing.standings_type) - self.assertTrue(standing.last_updated) \ No newline at end of file diff --git a/tests/mock_tests/stats/test_game_player_stats_for_game.py b/tests/mock_tests/stats/test_game_player_stats_for_game.py deleted file mode 100644 index 528dcdd7..00000000 --- a/tests/mock_tests/stats/test_game_player_stats_for_game.py +++ /dev/null @@ -1,165 +0,0 @@ -import unittest -import time - -from mlbstatsapi.mlb_api import Mlb - -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb - - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") -path_to_hotcoldzone_file = os.path.join(current_directory, "../mock_json/stats/person/hotcoldzone.json") -path_to_hitting_playlog_file = os.path.join(current_directory, "../mock_json/stats/person/hitting_player_playlog.json") -path_to_shoei_ohtani = os.path.join(current_directory, "../mock_json/stats/person/game_stats_player_shoei_ohtani.json") -path_to_ty_france = os.path.join(current_directory, "../mock_json/stats/person/game_stats_player_ty_france.json") -path_to_cal = os.path.join(current_directory, "../mock_json/stats/person/game_stats_player_cal.json") -path_to_archie = os.path.join(current_directory, "../mock_json/stats/person/game_stats_player_archie.json") -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() -SHOEI_ENDPOINT = open(path_to_shoei_ohtani, "r", encoding="utf-8-sig").read() -TY_ENDPOINT = open(path_to_ty_france, "r", encoding="utf-8-sig").read() -CAL_ENDPOINT = open(path_to_cal, "r", encoding="utf-8-sig").read() -ARCHIE_ENDPOINT = open(path_to_archie, "r", encoding="utf-8-sig").read() - - -@requests_mock.Mocker() -class TestHittingStats(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.al_team = 133 - cls.shoei_ohtani = 660271 - cls.ty_france = 664034 - cls.shoei_game_id = 531368 - cls.ty_game_id = 715757 - cls.cal_realeigh = 663728 - cls.cal_game_id = 715757 - cls.archie_bradley = 605151 - cls.archie_game_id = 531368 - cls.mock_ty_france_stats = json.loads(TY_ENDPOINT) - cls.mock_shoei_stats = json.loads(SHOEI_ENDPOINT) - cls.mock_cal_stats = json.loads(CAL_ENDPOINT) - cls.mock_archie_stats = json.loads(ARCHIE_ENDPOINT) - - @classmethod - def tearDownClass(cls) -> None: - pass - - - def test_get_players_stats_for_shoei_ohtana(self, m): - """return player stat objects""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats/game/531368', json=self.mock_shoei_stats, - status_code=200) - game_stats = self.mlb.get_players_stats_for_game(person_id=self.shoei_ohtani, - game_id=self.shoei_game_id) - - # game stats should not be None - self.assertIsNotNone(game_stats) - - # game_stats should be a dict - self.assertIsInstance(game_stats, dict) - - # game_stats should have hitting stats - self.assertTrue(game_stats['pitching']) - - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['pitching']['vsplayer5y']) - - splits = game_stats['pitching']['vsplayer5y'] - - for split in splits.splits: - self.assertTrue(split.team) - self.assertTrue(split.stat) - - def test_get_players_stats_for_ty_france(self, m): - """return player stat objects""" - m.get('https://statsapi.mlb.com/api/v1/people/664034/stats/game/715757', json=self.mock_ty_france_stats, - status_code=200) - game_stats = self.mlb.get_players_stats_for_game(person_id=self.ty_france, - game_id=self.ty_game_id) - - # game stats should not be None - self.assertIsNotNone(game_stats) - - # game_stats should be a dict - self.assertIsInstance(game_stats, dict) - - # game_stats should have hitting stats - self.assertTrue(game_stats['hitting']) - - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['hitting']['vsplayer5y']) - self.assertTrue(game_stats['hitting']['playlog']) - self.assertTrue(game_stats['stats']['gamelog']) - - splits = game_stats['hitting']['vsplayer5y'] - - for split in splits.splits: - self.assertTrue(split.team) - self.assertTrue(split.stat) - - def test_get_players_stats_for_cal_r(self, m): - """return player stat objects""" - m.get('https://statsapi.mlb.com/api/v1/people/663728/stats/game/715757', json=self.mock_cal_stats, - status_code=200) - game_stats = self.mlb.get_players_stats_for_game(person_id=self.cal_realeigh, - game_id=self.cal_game_id) - - # game stats should not be None - self.assertIsNotNone(game_stats) - - # game_stats should be a dict - self.assertIsInstance(game_stats, dict) - - # game_stats should have hitting stats - self.assertTrue(game_stats['hitting']) - - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['hitting']['vsplayer5y']) - self.assertTrue(game_stats['hitting']['playlog']) - self.assertTrue(game_stats['stats']['gamelog']) - - splits = game_stats['hitting']['vsplayer5y'] - - for split in splits.splits: - self.assertTrue(split.team) - self.assertTrue(split.stat) - - def test_get_players_stats_for_archie(self, m): - """return player stat objects""" - m.get('https://statsapi.mlb.com/api/v1/people/605151/stats/game/531368', json=self.mock_archie_stats, - status_code=200) - game_stats = self.mlb.get_players_stats_for_game(person_id=self.archie_bradley, - game_id=self.archie_game_id) - - # game stats should not be None - self.assertIsNotNone(game_stats) - - # game_stats should be a dict - self.assertIsInstance(game_stats, dict) - - # game_stats should have hitting stats - self.assertTrue(game_stats['pitching']) - - # game_stats should have vsplayer5y and playlog stats - self.assertTrue(game_stats['pitching']['vsplayer5y']) - self.assertTrue(game_stats['stats']['gamelog']) - - gamelogs = game_stats['stats']['gamelog'] - self.assertEqual(len(gamelogs.splits), 3) - self.assertEqual(gamelogs.total_splits, len(gamelogs.splits)) - - vsplayer5y = game_stats['pitching']['vsplayer5y'] - - for split in vsplayer5y.splits: - self.assertTrue(split.team) - self.assertTrue(split.stat) \ No newline at end of file diff --git a/tests/mock_tests/stats/test_hitting_stats_mock.py b/tests/mock_tests/stats/test_hitting_stats_mock.py deleted file mode 100644 index f78d510f..00000000 --- a/tests/mock_tests/stats/test_hitting_stats_mock.py +++ /dev/null @@ -1,244 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb - - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_player_stats = os.path.join(current_directory, "../mock_json/stats/person/hitting_player_stats.json") -path_to_team_stats = os.path.join(current_directory, "../mock_json/stats/team/hitting_team_stats.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") -path_to_hotcoldzone_file = os.path.join(current_directory, "../mock_json/stats/person/hotcoldzone.json") -path_to_hitting_playlog_file = os.path.join(current_directory, "../mock_json/stats/person/hitting_player_playlog.json") -path_to_hitting_pitchlog_file = os.path.join(current_directory, "../mock_json/stats/person/hitting_player_pitchlog.json") -path_to_spraychart_file = os.path.join(current_directory, "../mock_json/stats/person/spraychart.json") - -SPRAYCHART = open(path_to_spraychart_file, "r", encoding="utf-8-sig").read() -HOTCOLDZONE = open(path_to_hotcoldzone_file, "r", encoding="utf-8-sig").read() -PLAYERSTATS = open(path_to_player_stats, "r", encoding="utf-8-sig").read() -TEAMSTATS = open(path_to_team_stats, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() -HITTING_PLAY_LOG = open(path_to_hitting_playlog_file, "r", encoding="utf-8-sig").read() -HITTING_PITCH_LOG = open(path_to_hitting_pitchlog_file, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestHittingStatsMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.player = cls.mlb.get_person(665742) - cls.team = cls.mlb.get_team(133) - cls.mock_player_stats = json.loads(PLAYERSTATS) - cls.mock_team_stats = json.loads(TEAMSTATS) - cls.mock_hotcoldzone = json.loads(HOTCOLDZONE) - cls.error_500 = json.loads(ERROR_500) - cls.mock_not_found = json.loads(NOT_FOUND_404) - cls.mock_hitting_playlog = json.loads(HITTING_PLAY_LOG) - cls.mock_hitting_pitchlog = json.loads(HITTING_PITCH_LOG) - cls.mock_spraycharts = json.loads(SPRAYCHART) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_hitting_stat_attributes_player(self, m): - """mlb get stats should return pitching stats""" - m.get('https://statsapi.mlb.com/api/v1/people/665742/stats?stats=season&stats=career&stats=seasonAdvanced&stats=careerAdvanced&group=hitting', json=self.mock_player_stats, - status_code=200) - self.stats = ['season', 'career','seasonAdvanced', 'careerAdvanced'] - self.group = ['hitting'] - # let's get some stats - stats = self.mlb.get_player_stats(self.player.id, stats=self.stats, groups=self.group) - - # check for empty dict - self.assertNotEqual(stats, {}) - - # the end point should give us 2 hitting - self.assertTrue('hitting' in stats) - self.assertFalse('pitching' in stats) - self.assertEqual(len(stats['hitting']), 4) - - # check for split objects - self.assertTrue(stats['hitting']['season']) - self.assertTrue(stats['hitting']['career']) - self.assertTrue(stats['hitting']['seasonadvanced']) - self.assertTrue(stats['hitting']['careeradvanced']) - - # let's pull out a object and test it - season = stats['hitting']['season'] - career = stats['hitting']['career'] - season_advanced = stats['hitting']['seasonadvanced'] - career_advanced = stats['hitting']['careeradvanced'] - # check that attrs exist and contain data - - self.assertEqual(season.total_splits, len(season.splits)) - self.assertEqual(season.group, 'hitting') - self.assertEqual(season.type, 'season') - - self.assertEqual(career.total_splits, len(career.splits)) - self.assertEqual(career.group, 'hitting') - self.assertEqual(career.type, 'career') - - self.assertEqual(season_advanced.total_splits, len(season_advanced.splits)) - self.assertEqual(season_advanced.group, 'hitting') - self.assertEqual(season_advanced.type, 'seasonAdvanced') - - self.assertEqual(career_advanced.total_splits, len(career_advanced.splits)) - self.assertEqual(career_advanced.group, 'hitting') - self.assertEqual(career_advanced.type, 'careerAdvanced') - - def test_pitching_stat_attributes_team(self, m): - """mlb get stats should return pitching stats""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/stats?stats=season&stats=career&stats=seasonAdvanced&stats=careerAdvanced&group=hitting', json=self.mock_team_stats, - status_code=200) - self.stats = ['season', 'career', 'seasonAdvanced', 'careerAdvanced'] - self.group = ['hitting'] - # let's get some stats - stats = self.mlb.get_team_stats(self.team.id, stats=self.stats, groups=self.group) - - # check for empty dict - self.assertNotEqual(stats, {}) - - # the end point should give us 2 hitting - self.assertTrue('hitting' in stats) - self.assertFalse('pitching' in stats) - self.assertEqual(len(stats['hitting']), 4) - - # check for split objects - self.assertTrue(stats['hitting']['season']) - self.assertTrue(stats['hitting']['career']) - self.assertTrue(stats['hitting']['seasonadvanced']) - self.assertTrue(stats['hitting']['careeradvanced']) - - # let's pull out a object and test it - season = stats['hitting']['season'] - career = stats['hitting']['career'] - season_advanced = stats['hitting']['seasonadvanced'] - career_advanced = stats['hitting']['careeradvanced'] - # check that attrs exist and contain data - - self.assertEqual(season.total_splits, len(season.splits)) - self.assertEqual(season.group, 'hitting') - self.assertEqual(season.type, 'season') - - self.assertEqual(career.total_splits, len(career.splits)) - self.assertEqual(career.group, 'hitting') - self.assertEqual(career.type, 'career') - - self.assertEqual(season_advanced.total_splits, len(season_advanced.splits)) - self.assertEqual(season_advanced.group, 'hitting') - self.assertEqual(season_advanced.type, 'seasonAdvanced') - - self.assertEqual(career_advanced.total_splits, len(career_advanced.splits)) - self.assertEqual(career_advanced.group, 'hitting') - self.assertEqual(career_advanced.type, 'careerAdvanced') - - def test_hitting_hotcoldzones_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/665742/stats?stats=hotColdZones&group=hitting', json=self.mock_hotcoldzone, - status_code=200) - self.stats = ['hotColdZones'] - self.groups = ['hitting'] - stats = self.mlb.get_player_stats(self.player.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - self.assertTrue(stats['stats']['hotcoldzones']) - - # hotcoldzone should return 5 splits - hotcoldzone = stats['stats']['hotcoldzones'] - self.assertEqual(len(hotcoldzone.splits), 5) - self.assertEqual(hotcoldzone.total_splits, len(hotcoldzone.splits)) - - # hot cold zone should have 13 zones for each zone type - for split in hotcoldzone.splits: - self.assertTrue(split.stat.name) - self.assertEqual(len(split.stat.zones), 13) - - def test_hitting_pitchlog_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/665742/stats?stats=pitchLog&group=hitting', json=self.mock_hitting_pitchlog, - status_code=200) - self.stats = ['pitchLog'] - self.groups = ['hitting'] - stats = self.mlb.get_player_stats(self.player.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - # playlog key should be populated - self.assertTrue('hitting' in stats) - self.assertTrue(stats['hitting']['pitchlog']) - - # pitchlog should have 2 splits from mock - pitchlogs = stats['hitting']['pitchlog'] - self.assertEqual(len(pitchlogs.splits), 6) - self.assertEqual(pitchlogs.total_splits, len(pitchlogs.splits)) - - for pitchlog in pitchlogs.splits: - self.assertTrue(pitchlog.stat.details) - self.assertTrue(pitchlog.stat.count) - - - def test_hitting_playlog_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/665742/stats?stats=playLog&group=hitting', json=self.mock_hitting_playlog, - status_code=200) - self.stats = ['playLog'] - self.groups = ['hitting'] - stats = self.mlb.get_player_stats(self.player.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - # playlog key should be populated - self.assertTrue('hitting' in stats) - self.assertTrue(stats['hitting']['playlog']) - - # pitchlog items should have 2 splits - pitchlogs = stats['hitting']['playlog'] - self.assertEqual(len(pitchlogs.splits), 2) - self.assertEqual(pitchlogs.total_splits, len(pitchlogs.splits)) - - for pitchlog in pitchlogs.splits: - self.assertTrue(pitchlog.stat) - - def test_hitting_spraychart_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/665742/stats?stats=sprayChart&group=hitting', json=self.mock_spraycharts, - status_code=200) - self.stats = ['sprayChart'] - self.groups = ['hitting'] - spraychart = self.mlb.get_player_stats(self.player.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(spraychart) - - # game_stats should not be empty dic - self.assertNotEqual(spraychart, {}) - - self.assertTrue(spraychart['stats']['spraychart']) - - spraychart = spraychart['stats']['spraychart'] - self.assertEqual(len(spraychart.splits), 1) - self.assertEqual(spraychart.total_splits, len(spraychart.splits)) - - for pitchlog in spraychart.splits: - self.assertTrue(pitchlog.stat) \ No newline at end of file diff --git a/tests/mock_tests/stats/test_pitching_stats_mock.py b/tests/mock_tests/stats/test_pitching_stats_mock.py deleted file mode 100644 index 0e66493d..00000000 --- a/tests/mock_tests/stats/test_pitching_stats_mock.py +++ /dev/null @@ -1,249 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb - - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_hotcoldzone_file = os.path.join(current_directory, "../mock_json/stats/person/hotcoldzone.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") -path_to_player_stats = os.path.join(current_directory, "../mock_json/stats/person/pitching_player_stats.json") -path_to_team_stats = os.path.join(current_directory, "../mock_json/stats/team/pitching_team_stats.json") -path_to_pitching_playlog_file = os.path.join(current_directory, "../mock_json/stats/person/pitching_player_playlog.json") -path_to_pitching_pitchlog_file = os.path.join(current_directory, "../mock_json/stats/person/pitching_player_pitchlog.json") -path_to_spraychart_file = os.path.join(current_directory, "../mock_json/stats/person/spraychart.json") - -HOTCOLDZONE = open(path_to_hotcoldzone_file, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() -PLAYERSTATS = open(path_to_player_stats, "r", encoding="utf-8-sig").read() -TEAMSTATS = open(path_to_team_stats, "r", encoding="utf-8-sig").read() -PITCHING_PLAY_LOG = open(path_to_pitching_playlog_file, "r", encoding="utf-8-sig").read() -PITCHING_PITCH_LOG = open(path_to_pitching_pitchlog_file, "r", encoding="utf-8-sig").read() -SPRAYCHART = open(path_to_spraychart_file, "r", encoding="utf-8-sig").read() - - -@requests_mock.Mocker() -class TestPitchingStatsMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.pitcher = cls.mlb.get_person(660271) - cls.al_team = cls.mlb.get_team(133) - cls.mock_hotcoldzone = json.loads(HOTCOLDZONE) - cls.error_500 = json.loads(ERROR_500) - cls.mock_not_found = json.loads(NOT_FOUND_404) - cls.mock_player_stats = json.loads(PLAYERSTATS) - cls.mock_team_stats = json.loads(TEAMSTATS) - cls.mock_pitching_playlog = json.loads(PITCHING_PLAY_LOG) - cls.mock_pitching_pitchlog = json.loads(PITCHING_PITCH_LOG) - cls.mock_spraycharts = json.loads(SPRAYCHART) - - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_pitching_stat_attributes_player(self, m): - """mlb get stats should return pitching stats""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats?stats=season&stats=career&stats=seasonAdvanced&stats=careerAdvanced&group=pitching', json=self.mock_player_stats, - status_code=200) - self.stats = ['season', 'career', 'seasonAdvanced', 'careerAdvanced'] - self.group = ['pitching'] - # let's get some stats - stats = self.mlb.get_player_stats(self.pitcher.id, stats=self.stats, groups=self.group) - - # check for empty dict - self.assertNotEqual(stats, {}) - - # the end point should give us 2 hitting - self.assertTrue('pitching' in stats) - self.assertFalse('hitting' in stats) - self.assertEqual(len(stats['pitching']), 4) - - # check for split objects - self.assertTrue(stats['pitching']['season']) - self.assertTrue(stats['pitching']['career']) - self.assertTrue(stats['pitching']['seasonadvanced']) - self.assertTrue(stats['pitching']['careeradvanced']) - - season = stats['pitching']['season'] - career = stats['pitching']['career'] - season_advanced = stats['pitching']['seasonadvanced'] - career_advanced = stats['pitching']['careeradvanced'] - - self.assertEqual(season.total_splits, len(season.splits)) - self.assertEqual(season.group, 'pitching') - self.assertEqual(season.type, 'season') - - self.assertEqual(career.total_splits, len(career.splits)) - self.assertEqual(career.group, 'pitching') - self.assertEqual(career.type, 'career') - - self.assertEqual(season_advanced.total_splits, len(season_advanced.splits)) - self.assertEqual(season_advanced.group, 'pitching') - self.assertEqual(season_advanced.type, 'seasonAdvanced') - - self.assertEqual(career_advanced.total_splits, len(career_advanced.splits)) - self.assertEqual(career_advanced.group, 'pitching') - self.assertEqual(career_advanced.type, 'careerAdvanced') - - def test_pitching_stat_attributes_team(self, m): - """mlb get stats should return pitching stats""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/stats?stats=season&stats=career&stats=seasonAdvanced&stats=careerAdvanced&group=pitching', json=self.mock_team_stats, - status_code=200) - self.stats = ['season', 'career','seasonAdvanced', 'careerAdvanced'] - self.group = ['pitching'] - # let's get some stats - stats = self.mlb.get_team_stats(self.al_team.id, stats=self.stats, groups=self.group) - - # check for empty dict - self.assertNotEqual(stats, {}) - - # the end point should give us 2 hitting - self.assertTrue('pitching' in stats) - self.assertFalse('hitting' in stats) - self.assertEqual(len(stats['pitching']), 4) - - # check for split objects - self.assertTrue(stats['pitching']['season']) - self.assertTrue(stats['pitching']['career']) - self.assertTrue(stats['pitching']['seasonadvanced']) - self.assertTrue(stats['pitching']['careeradvanced']) - - season = stats['pitching']['season'] - career = stats['pitching']['career'] - season_advanced = stats['pitching']['seasonadvanced'] - career_advanced = stats['pitching']['careeradvanced'] - - self.assertEqual(season.total_splits, len(season.splits)) - self.assertEqual(season.group, 'pitching') - self.assertEqual(season.type, 'season') - - self.assertEqual(career.total_splits, len(career.splits)) - self.assertEqual(career.group, 'pitching') - self.assertEqual(career.type, 'career') - - self.assertEqual(season_advanced.total_splits, len(season_advanced.splits)) - self.assertEqual(season_advanced.group, 'pitching') - self.assertEqual(season_advanced.type, 'seasonAdvanced') - - self.assertEqual(career_advanced.total_splits, len(career_advanced.splits)) - self.assertEqual(career_advanced.group, 'pitching') - self.assertEqual(career_advanced.type, 'careerAdvanced') - - def test_pitching_play_log_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats?stats=hotColdZones&group=pitching', json=self.mock_hotcoldzone, - status_code=200) - self.stats = ['hotColdZones'] - self.groups = ['pitching'] - stats = self.mlb.get_player_stats(self.pitcher.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - # should not be empty - self.assertTrue(stats['stats']['hotcoldzones']) - - hotcoldzone = stats['stats']['hotcoldzones'] - - # check for split objects - self.assertTrue(stats['stats']['hotcoldzones']) - - # hotcoldzone should return 5 splits - hotcoldzone = stats['stats']['hotcoldzones'] - self.assertEqual(len(hotcoldzone.splits), 5) - self.assertEqual(hotcoldzone.total_splits, len(hotcoldzone.splits)) - - # hot cold zone should have 13 zones for each zone type - for split in hotcoldzone.splits: - self.assertTrue(split.stat.name) - self.assertEqual(len(split.stat.zones), 13) - - def test_pitching_pitchlog_for_pitcher(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats?stats=pitchLog&group=pitching', json=self.mock_pitching_pitchlog, - status_code=200) - self.stats = ['pitchLog'] - self.groups = ['pitching'] - stats = self.mlb.get_player_stats(self.pitcher.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - # playlog key should be populated - self.assertTrue('pitching' in stats) - self.assertTrue(stats['pitching']['pitchlog']) - - # pitchlog should have 2 splits from mock - pitchlogs = stats['pitching']['pitchlog'] - self.assertEqual(len(pitchlogs.splits), 2) - self.assertEqual(pitchlogs.total_splits, len(pitchlogs.splits)) - - for pitchlog in pitchlogs.splits: - self.assertTrue(pitchlog.stat.details) - self.assertTrue(pitchlog.stat.count) - - - def test_pitching_playlog_for_pitcher(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats?stats=playLog&group=pitching', json=self.mock_pitching_playlog, - status_code=200) - self.stats = ['playLog'] - self.groups = ['pitching'] - stats = self.mlb.get_player_stats(self.pitcher.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(stats) - - # game_stats should not be empty dic - self.assertNotEqual(stats, {}) - - # playlog key should be populated - self.assertTrue('pitching' in stats) - self.assertTrue(stats['pitching']['playlog']) - - # pitchlog items should have 2 splits - pitchlogs = stats['pitching']['playlog'] - self.assertEqual(len(pitchlogs.splits), 2) - self.assertEqual(pitchlogs.total_splits, len(pitchlogs.splits)) - - for pitchlog in pitchlogs.splits: - self.assertTrue(pitchlog.stat) - - def test_pitching_play_log_for_player(self, m): - """get_player_game_stats should return a dict with stats""" - m.get('https://statsapi.mlb.com/api/v1/people/660271/stats?stats=sprayChart&group=pitching', json=self.mock_spraycharts, - status_code=200) - self.stats = ['sprayChart'] - self.groups = ['pitching'] - spraychart = self.mlb.get_player_stats(self.pitcher.id, stats=self.stats, groups=self.groups) - - # game_stats should not be None - self.assertIsNotNone(spraychart) - - # game_stats should not be empty dic - self.assertNotEqual(spraychart, {}) - - self.assertTrue(spraychart['stats']['spraychart']) - - - spraychart = spraychart['stats']['spraychart'] - self.assertEqual(len(spraychart.splits), 1) - self.assertEqual(spraychart.total_splits, len(spraychart.splits)) - - for pitchlog in spraychart.splits: - self.assertTrue(pitchlog.stat) \ No newline at end of file diff --git a/tests/mock_tests/teams/test_roster_mock.py b/tests/mock_tests/teams/test_roster_mock.py deleted file mode 100644 index e93c5160..00000000 --- a/tests/mock_tests/teams/test_roster_mock.py +++ /dev/null @@ -1,66 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb -from mlbstatsapi.models.teams import Team - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_player_roster = os.path.join(current_directory, "../mock_json/teams/team_roster_players.json") -path_to_coaches_roster = os.path.join(current_directory, "../mock_json/teams/team_coaches.json") - - -PLAYERS = open(path_to_player_roster, "r", encoding="utf-8-sig").read() -COACHES = open(path_to_coaches_roster, "r", encoding="utf-8-sig").read() - - - - - -@requests_mock.Mocker() -class TestTeamRoster(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.mock_players = json.loads(PLAYERS) - cls.mock_coaches = json.loads(COACHES) - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_team_roster_list_of_player_objects(self, m): - """Default Team Roster should return a list of players""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/roster', json=self.mock_players, - status_code=200) - - roster = self.mlb.get_team_roster(133) - - # roster should not be None - self.assertIsNotNone(roster) - - # roster should be a list - self.assertIsInstance(roster, list) - - # roster should not be a empty list - self.assertNotEqual(roster, []) - - def test_team_roster_list_of_coach_objects(self, m): - """Default Team Roster should return a list of players""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/coaches', json=self.mock_coaches, - status_code=200) - - roster = self.mlb.get_team_coaches(133) - - # roster should not be None - self.assertIsNotNone(roster) - - # roster should be a list - self.assertIsInstance(roster, list) - - # roster should not be a empty list - self.assertNotEqual(roster, []) \ No newline at end of file diff --git a/tests/mock_tests/teams/test_team_mock.py b/tests/mock_tests/teams/test_team_mock.py deleted file mode 100644 index 236c141e..00000000 --- a/tests/mock_tests/teams/test_team_mock.py +++ /dev/null @@ -1,78 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb -from mlbstatsapi.models.teams import Team - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_teams = os.path.join(current_directory, "../mock_json/teams/team.json") -path_to_team = os.path.join(current_directory, "../mock_json/teams/teams.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") - -TEAMS = open(path_to_teams, "r", encoding="utf-8-sig").read() -TEAM = open(path_to_team, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestScheduleMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.al_team = 133 - cls.mock_team = json.loads(TEAMS) - cls.mock_teams = json.loads(TEAMS) - - - - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_team_instance_id_instance_success(self, m): - """get_team should return a Team object""" - m.get('https://statsapi.mlb.com/api/v1/teams/133', json=self.mock_team, - status_code=200) - self.team = self.mlb.get_team(133) - - # team should not be None - self.assertIsNotNone(self.team) - - # Team object should have attrs set - self.assertEqual(self.team.id, 133) - self.assertIsInstance(self.team, Team) - self.assertEqual(self.team.name, "Oakland Athletics") - self.assertEqual(self.team.link, "/api/v1/teams/133") - - - def test_get_teams_for_sport(self, m): - """get_teams should return a list of teams""" - m.get('https://statsapi.mlb.com/api/v1/teams', json=self.mock_teams, - status_code=200) - self.teams = self.mlb.get_teams(sport_id=1) - - # teams should not be none - self.assertIsNotNone(self.teams) - - # teams should be a list - self.assertIsInstance(self.teams, list) - - # teams should not be empty list - self.assertNotEqual(self.teams, []) - - self.teams = self.mlb.get_teams(sport_id=11) - - # teams should not be none - self.assertIsNotNone(self.teams) - - # teams should be a list - self.assertIsInstance(self.teams, list) - - # teams should not be empty list - self.assertNotEqual(self.teams, []) \ No newline at end of file diff --git a/tests/mock_tests/teams/test_team_roster_mock.py b/tests/mock_tests/teams/test_team_roster_mock.py deleted file mode 100644 index 1f9bac1f..00000000 --- a/tests/mock_tests/teams/test_team_roster_mock.py +++ /dev/null @@ -1,63 +0,0 @@ -import unittest -import requests_mock -import json -import os - -from mlbstatsapi import Mlb -from mlbstatsapi.models.teams import Team -from mlbstatsapi.models.people import Coach, Player - -# Mocked JSON directory -# TODO Find a better way to structure and handle this :) -path_to_current_file = os.path.realpath(__file__) -current_directory = os.path.dirname(path_to_current_file) -path_to_team_coaches = os.path.join(current_directory, "../mock_json/teams/team_roster_coaches.json") -path_to_team_players = os.path.join(current_directory, "../mock_json/teams/team_roster_players.json") -path_to_not_found = os.path.join(current_directory, "../mock_json/response/not_found_404.json") -path_to_error = os.path.join(current_directory, "../mock_json/response/error_500.json") - -COACHES = open(path_to_team_coaches, "r", encoding="utf-8-sig").read() -PLAYERS = open(path_to_team_players, "r", encoding="utf-8-sig").read() -NOT_FOUND_404 = open(path_to_not_found, "r", encoding="utf-8-sig").read() -ERROR_500 = open(path_to_error, "r", encoding="utf-8-sig").read() - -@requests_mock.Mocker() -class TestTeamRosterMock(unittest.TestCase): - @classmethod - def setUpClass(cls) -> None: - cls.mlb = Mlb() - cls.al_team_id = 133 - cls.mock_coaches = json.loads(COACHES) - cls.mock_players = json.loads(PLAYERS) - @classmethod - def tearDownClass(cls) -> None: - pass - - def test_team_roster_list_of_player_objects(self, m): - """Default Team Roster should return a list of players""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/roster', json=self.mock_players, - status_code=200) - self.roster = self.mlb.get_team_roster(team_id=self.al_team_id) - self.assertIsInstance(self.roster, list) - # Roster should return a list - self.assertIsInstance(self.roster, list) - - # Roster should not return a empty list - self.assertNotEqual(self.roster, []) - for player in self.roster: - self.assertIsInstance(player, Player) - - def test_team_roster_list_of_coach_objects(self, m): - """Default Team Roster should return a list of coaches""" - m.get('https://statsapi.mlb.com/api/v1/teams/133/coaches', json=self.mock_coaches, - status_code=200) - self.roster = self.mlb.get_team_coaches(team_id=self.al_team_id) - # Roster should return a list - self.assertIsInstance(self.roster, list) - - # Roster should not return a empty list - self.assertNotEqual(self.roster, []) - - # Roster should return a list of Coaches - for player in self.roster: - self.assertIsInstance(player, Coach) \ No newline at end of file