Skip to main content
Glama
fair.ts732 B
import { z } from "zod"; import { FastMCP } from "fastmcp"; import { buildMatchSnapshot } from "../services/matchSnapshot.js"; import { computeFairOddsFromSnapshot } from "../services/fairOddsEngine.js"; export const registerFairTool = (server: FastMCP) => { server.addTool({ name: "fair.compute", description: "Calcola probabilità e quote fair (Poisson semplice) per 1X2 / OU 2.5 / BTTS.", parameters: z.object({ match_id: z.number().describe("Fixture id da API-Football"), }), execute: async (args) => { const snapshot = await buildMatchSnapshot(args.match_id); const fair = computeFairOddsFromSnapshot(snapshot); return JSON.stringify({ snapshot, fair }, null, 2); }, }); };

Implementation Reference

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Valerio357/bet-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server