bet-mcp
MCP server (FastMCP + TypeScript) that focuses on Serie A pre-match analysis:
fixtures.list– next fixtures in a configurable windowmatch.snapshot– last 5 results, standings, GF/GA averagesodds.prematch– normalized odds for 1X2 / OU 2.5 / BTTS across bookmakersfair.compute– Poisson-lite probabilities + fair oddsvalue.detect– top value picks by comparing best odds vs fair model
Getting started
Install dependencies (Node 20+ recommended):
npm installCopy
.env.exampleto.envand provide your keys:cp .env.example .env # edit the file with APIFOOTBALL_KEY and ODDS_API_KEYRun locally:
# stdio (Claude Desktop / terminal) npm run dev # or HTTP transport for remote testing MCP_TRANSPORT=http PORT=8080 npm run devBuild for production:
npm run build npm startDeploy on glama.ai:
Glama uses the included
glama.yaml/glama.jsonfiles to runnpm install && npm run build, then starts the server withMCP_TRANSPORT=httpon port8080. ConfigureAPIFOOTBALL_KEYandODDS_API_KEY(others optional) in the Glama dashboard so inspections and tool detection can succeed.
Implementation notes
Stack – FastMCP + Axios + Zod, TypeScript strict mode.
API clients – API-Football for fixtures/stats; The Odds API for consolidated odds.
Modeling – Poisson using GF/GA averages + configurable home advantage, derived OU/BTTS probs.
Caching – In-memory TTL cache to reduce API calls (configurable via
CACHE_TTL_SECONDS).Value picks – Filters by
edge >= 5%andodds >= 1.50, returns rationale referencing λ/form.
Environment variables
key | description |
| API-Football key |
| Defaults to
(Serie A) |
| Defaults to current year |
| The Odds API key |
| Regions filter (default
) |
| Markets request list (default
) |
| Sport key (
) |
| Poisson λ multiplier for home team |
| Cache TTL (default 120) |
|
(default) or
|
| HTTP port when
|
Testing
Use npx fastmcp dev src/index.ts or npx fastmcp inspect src/index.ts after installing dependencies to interactively test the tools.