--- id: caf1f9fa-61cd-4b51-8d8a-840198cc5181 type: solution title: "Game metadata validation prevents null team data" tags: [strat-gameplay-webapp, python, fastapi, fix, validation] importance: 0.6 confidence: 0.8 created: "2026-01-25T00:19:29.151542+00:00" updated: "2026-01-25T00:19:29.151542+00:00" --- Fixed bug where games were created with null team metadata (names, colors, thumbnails). Root cause: sba_api_client.get_teams_by_ids() silently returned empty dict on API failures, and create_game()/quick_create_game() didn't validate. Solution: Added validation to raise HTTP 400 if teams not found, plus warning logs in get_teams_by_ids() when teams missing.