Prediction Router
API Reference

Sports

Sports games and their markets on a platform

Fetch sports games (contests) and their associated markets, normalized to a single schema. Scoped to one platform.

All endpoints require Authorization: Bearer <key>.

Base URL: https://prediction-router-api.kalashshah47.workers.dev

Platform support: kalshi. Other platforms return 405 UNSUPPORTED_OPERATION.

Leagues: NFL NBA MLB NHL NCAAF EPL (case-insensitive). An unknown league returns 400 VALIDATION_ERROR.


GET /v1/sports/games

List upcoming games for a league.

Query parameters

ParameterTypeRequiredDescription
platformstring✓kalshi
leaguestring✓One of the supported leagues
limitintegerMax results. Default 50, max 100

Example

curl "https://prediction-router-api.kalashshah47.workers.dev/v1/sports/games?platform=kalshi&league=NFL" \
  -H "Authorization: Bearer pr_..."

Response

{
  "games": [
    {
      "id": "KXNFLGAME-24DEC01CHIEAG",
      "platform": "kalshi",
      "league": "NFL",
      "title": "Chiefs vs Eagles",
      "homeTeam": "Chiefs",
      "awayTeam": "Eagles",
      "startTime": "2024-12-01T18:00:00Z",
      "status": "open",
      "markets": [
        {
          "id": "KXNFLGAME-24DEC01CHIEAG-CHI",
          "platform": "kalshi",
          "title": "Chiefs win",
          "outcomes": [
            { "id": "yes", "label": "Yes", "probability": 0.55, "price": 0.55 },
            { "id": "no",  "label": "No",  "probability": 0.45, "price": 0.45 }
          ],
          "volume": 100,
          "liquidity": 50,
          "status": "open",
          "resolution": null,
          "closeTime": "2024-12-01T18:00:00Z",
          "url": "https://kalshi.com/markets/KXNFLGAME-24DEC01CHIEAG-CHI"
        }
      ]
    }
  ]
}

GET /v1/sports/games/:id

Fetch a single game by its event ID. The league is inferred from the event's series.

Query parameters

ParameterTypeRequiredDescription
platformstring✓kalshi

Errors

StatusCodeMeaning
400VALIDATION_ERRORplatform / league missing, or unknown league
405UNSUPPORTED_OPERATIONPlatform does not expose sports