Public API

Fantasy Pundit API

Queue AI commentary for public Fantasy Premier League leagues, poll generation jobs, and retrieve generated recaps or audio.

Agent Discovery

Agents can start from the API catalog or the OpenAPI description. The catalog follows the RFC 9727 Linkset format and points to docs, service description, and health status.

Base URL

https://api.fantasypundit.lol

The API currently does not require OAuth. Public endpoints support CORS and return JSON unless audio is requested.

MCP Connector For Claude

Use the remote MCP server when you want Claude or another MCP-capable client to write text commentary itself. Fantasy Pundit supplies public FPL facts, season receipts, roast style guidance, and prompt-safety instructions; the client model writes the final roast.

https://api.fantasypundit.lol/mcp

For non-technical setup instructions, use the guided page: Fantasy Pundit MCP connector for Claude.

1. Add the connector

In Claude, add a custom connector using the public MCP URL.

2. Ask normally

Users should be able to ask for an FPL roast in natural language. The connector metadata tells the client to ask for a league URL, league ID, or league name when one is missing.

3. Let the client write

Users can provide a league ID, FPL league URL, or league name conversationally. If a name has multiple matches, the client should ask the user to pick the right league before writing.

Generate Commentary

1. Queue a job
POST /api/jobs/commentary
Content-Type: application/json

{
  "leagueId": "314",
  "generationMode": "auto"
}
2. Poll status
GET /api/jobs/{jobId}
3. Use the result

Completed jobs return commentary text, generation mode, an audio URL when audio was generated, and a temporary share URL when available.

Endpoints

GET

/health

Returns service health and server time.

GET

/api/league-search

Searches public Fantasy Premier League leagues by name. Requires a query parameter of at least two characters.

POST

/api/jobs/commentary

Queues regular gameweek commentary. Use generationMode of audio, text, or auto.

POST

/api/jobs/season-wrapped

Queues an end-of-season wrapped job for supported seasons.

GET

/api/jobs/{jobId}

Polls a queued job until it is completed or failed.

GET

/audio/{audioKey}

Returns generated MP3 audio.