From 8733fd45adfd3b8b05c45dd1aae6503ab778bccd Mon Sep 17 00:00:00 2001 From: Cal Corum Date: Thu, 19 Mar 2026 13:20:57 -0500 Subject: [PATCH] docs: update list_team_evolutions docstring for player_name and Player join Co-Authored-By: Claude Opus 4.6 (1M context) --- app/routers_v2/teams.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/app/routers_v2/teams.py b/app/routers_v2/teams.py index 0a8f017..74956ca 100644 --- a/app/routers_v2/teams.py +++ b/app/routers_v2/teams.py @@ -1541,9 +1541,11 @@ async def list_team_evolutions( ): """List all EvolutionCardState rows for a team, with optional filters. - Joins EvolutionCardState to EvolutionTrack so that card_type filtering - works without a second query. Results are paginated via page/per_page - (1-indexed pages); items are ordered by player_id for stable ordering. + Joins EvolutionCardState → EvolutionTrack (for card_type filtering and + threshold context) and EvolutionCardState → Player (for player_name), + both eager-loaded in a single query. Results are paginated via + page/per_page (1-indexed pages); items are ordered by player_id for + stable ordering. Query parameters: card_type -- filter to states whose track.card_type matches (e.g. 'batter', 'sp') @@ -1554,7 +1556,8 @@ async def list_team_evolutions( Response shape: {"count": N, "items": [card_state_with_threshold_context, ...]} - Each item in 'items' has the same shape as GET /evolution/cards/{card_id}. + Each item in 'items' has the same shape as GET /evolution/cards/{card_id}, + plus a ``player_name`` field sourced from the Player table. """ if not valid_token(token): logging.warning("Bad Token: [REDACTED]")