TKB Picks MCP
MCP server that wraps SportsGameOdds and BALLDONTLIE APIs to provide sports scheduling, odds, injuries, and team statistics tools for building TKB Picks threads.
README
TKB Picks MCP Server
Wraps SportsGameOdds (odds/schedule/stats) and BALLDONTLIE (injuries) into MCP tools for TKB Picks thread-building.
This round: response-size optimization (root-cause fix for the earlier OOM crash)
What changed: Every tool that fetches odds now requests the EXACT oddID(s) it needs directly from SGO's API, instead of pulling the full event (which can contain 1000+ markets) and filtering client-side afterward. Confirmed via SGO's own FAQ and docs that request-level filtering (oddIDs, playerID, bookmakerID params) is the correct, intended way to keep responses small - this was the real root cause of the earlier out-of-memory crash, more than raw traffic volume.
Files changed:
sgoClient.ts- addedbookmakerIDandincludeOpposingOddsto the request params (bookmakerID is wired through; includeOpposingOdds is available for future use but not yet used by any tool)odds.ts- rewritten sooddIDsare built BEFORE the event lookup and passed on the very first request, even in the teamName-lookup case (since statID/entity/side are deterministic ahead of time, we never need to guess-then-filter)yesNoProps.ts,periodOdds.ts- same fix: the already-knownoddIDis now passed via theoddIDsparam on the fetch instead of being filtered out of the full response after the facthitRateAggregator.ts,splitsAggregator.ts- these never needed odds data at all (onlyresults/teams.score), so they now pass a minimal single dummyoddIDsvalue to shrink the odds payload to near-zero instead of pulling the full odds object for every game in the lookback window
New param: tkb_get_odds now accepts optional preferredBookmakers (comma-separated, e.g. "fanduel,draftkings") to control which book's price is returned, instead of whatever happened to come back first.
Practical effect: faster responses, and this should meaningfully reduce (likely eliminate) the memory pressure that caused the earlier "Ran out of memory (used over 512MB)" crashes - independent of the Render instance upgrade, which was a workaround for the same underlying issue. Nothing about the tool names, parameters (aside from the one addition), or how threads get built has changed - this is purely a request-efficiency fix.
Tools (10)
tkb_get_schedule- game schedule, date/team/conference filteringtkb_get_odds- moneyline/spread/total, or an individual player's over/under prop (now requests exact oddIDs directly)tkb_get_player_hit_rate- real recent-game-log hit-rate check (now requests minimal odds payload)tkb_get_injuries- structured injury status from BALLDONTLIE (team field confirmed fixed:player.team.display_name)tkb_get_team_split- home/road/opponent-specific record (now requests minimal odds payload)tkb_get_team_record- overall record from SGO's standings datatkb_get_yes_no_prop- milestone-style bets (now requests exact oddID directly)tkb_get_period_odds- period-specific lines (now requests exact oddID directly)tkb_debug_raw_event- dumps raw SGO event JSONtkb_debug_raw_injuries- dumps raw BALLDONTLIE injuries JSON
Confirmed working / fixed across all prior rounds (still in effect)
- Start time field (
status.startsAt) - Schedule/odds teamName searches properly date-bounded
- Moneyline/spread odds correct with or without explicit
side - Hit-rate and team-split date bounding (no more stale/ancient data)
- BALLDONTLIE injuries team field (
player.team.display_name) - No
lineupsfield exists on SGO events - starting pitcher confirmation is a permanent live-search requirement, not something this API can provide
Still genuinely unverified
- Player
teamIDupdate speed after a real trade (though one real offseason trade - Semien to Mets - was confirmed correctly reflected) includeOpposingOddsbehavior (added to client, not yet used by any tool - worth adopting in a future round to cut requests further for two-sided markets)
Operational notes
Render instance: currently on Standard (2GB RAM). This round's fix targets the root cause of the earlier OOM crashes directly, so the bigger instance should now have even more headroom than before.
MCP connector caching: remove/re-add if new tools/behavior don't show up after redeploy.
Start Command must be exactly npm start.
Deploy to Render
- Upload this folder's contents to the GitHub repo (overwrite existing files)
- Render auto-redeploys
- Verify:
https://YOUR-SERVICE.onrender.com/health - Remove/re-add the MCP connector if tools seem stale
Adding NBA/NHL later
- Get a BALLDONTLIE subscription for that sport
- Add one entry to
SPORT_CONFIGinsrc/constants.ts - Push to GitHub
Local development
npm install
npm run build
SGO_API_KEY=xxx BDL_API_KEY=xxx npm start
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.