Skip to content
Developer docsMCP · Streamable HTTP · Enterprise

MCP · Enterprise only

Racing data inside your AI assistant.

The RacingAPI.net MCP server lets compatible AI clients call 13 core racing feeds plus three saved-selection endpoints, read-only. It is available on Enterprise. The core REST API remains available on every plan; AI-assisted tips are Enterprise only.

https://racingapi.net/api/mcp

What it is

MCP (Model Context Protocol) is an open standard that lets AI clients call external tools. Our server is a real bridge to the racing feed: every tool call retrieves supplied data. It is separate from the support chat on this site.

  • Transport: stateless Streamable HTTP. POST with JSON responses. GET SSE streams are not supported.
  • Scope: racing:read. No account, key or billing access.
  • Core feeds contain supplied facts. Saved tips are experimental rankings with AI-written explanations, not guaranteed outcomes or calibrated probabilities.

Eligibility

You need an Enterprise plan with active API access. Lower plans receive HTTP 403 from the MCP server. Manage connections in Dashboard, Connect AI.

Connect a client

Browser sign-in (OAuth)

In a client that supports remote MCP connectors, add a custom connector with the server URL. The client opens RacingAPI.net; sign in, review the consent screen, choose one of your active API keys and approve. Availability depends on the client, your client plan and any organisation admin restrictions; we have not verified every browser-based platform.

Key header (Cursor, VS Code, Claude Code)

Send an existing API key as X-API-Key. Keys are created in API keys and shown once.

{
  "mcpServers": {
    "racingapi": {
      "url": "https://racingapi.net/api/mcp",
      "headers": { "X-API-Key": "YOUR_API_KEY" }
    }
  }
}

OAuth details

ItemValue
FlowOAuth 2.1 authorization code with PKCE (S256)
Scoperacing:read
Access token1 hour
Refresh token30 days, rotated on every use
ApprovalExplicit consent on RacingAPI.net. Never automatic.

Resource discovery is at /.well-known/oauth-protected-resource/api/mcp; authorisation-server discovery is at /.well-known/oauth-authorization-server. Clients must validate their OAuth state and keep the PKCE verifier private. Pending consent expires after ten minutes; approved codes expire after three minutes and are single-use. A reused refresh token revokes its connection, so refresh once at a time and save the replacement token atomically.

OAuth tokens are not REST keys

Access tokens only work on the MCP server. Use API keys for /v1 REST requests.

Tools

Current tool catalogue. Statistics and form reflect what is supplied in the daily feed, not a complete career record or guaranteed ten-year archive.

ToolDescriptionREST equivalent
get_tipsSaved experimental selections and AI-written explanations; check status and freshness./v1/tips
get_race_tipSaved selection, explanation and odds for one race./v1/races/{raceId}/tip
get_tip_explanationSame saved two-sentence explanation and version as the race tip./v1/races/{raceId}/tip/explanation
get_racecardsRacecards for a meeting date (default today, Europe/London)./v1/racecards
get_raceOne race card with runners by race ID./v1/races/{raceId}
get_resultsSettled results for a date./v1/results
get_resultOne supplied result by race ID./v1/results/{raceId}
search_horsesFind declared horses by name in one daily feed./v1/horses/search
get_horseHorse details by horse ID./v1/horses/{horseId}
get_horse_formForm sections supplied in the daily feed./v1/horses/{horseId}/form
get_jockeyJockey bookings and connection figures in the daily feed./v1/jockeys/{jockeyId}
get_trainerTrainer runners and connection figures in the daily feed./v1/trainers/{trainerId}
get_racecoursesCourses appearing in the selected daily feed./v1/racecourses
get_racecourseOne racecourse in the selected daily feed./v1/racecourses/{courseId}
get_silkRacing colours as PNG for a declared horseId and raceId./v1/silks/{horseId}
get_oddsAvailable bookmaker prices supplied for a race, ready to compare./v1/odds/{raceId}
  • get_odds returns the bookmaker prices supplied for a race so you can compare them.
  • get_silk takes horseId, raceId and date and returns the PNG image.
  • History uses an explicit date on the regular tools, subject to availability.

Dates and region

Region is fixed to uk (UK and Ireland). Dates use YYYY-MM-DD and default to today in Europe/London unless you pass an explicit date.

All arguments go inside params.arguments when calling a tool. Do not send a region or arbitrary REST URL. Identifier values are strings of up to 12 digits, taken from a feed response for the same date. Unknown argument names are rejected.

ToolRequired argumentsOptional arguments
get_tipsNonedate, page, limit
get_race_tip / get_tip_explanationraceIddate
get_racecards / get_results / get_racecoursesNonedate, page, limit
get_race / get_resultraceIddate
search_horsesq (1–100 characters)date, page, limit
get_horsehorseIddate
get_horse_formhorseIddate, raceId
get_jockeyjockeyIddate
get_trainertrainerIddate
get_racecoursecourseIddate
get_silkhorseId, raceIddate
get_oddsraceIddate, page, limit

Pagination starts at page 1, with limit 50 by default and a maximum of 100. JSON feed responses are returned as a text content item containing the usual meta and data envelope; silk responses use an MCP image content item containing the actual base64-encoded PNG. Tool discovery returns the authoritative input schemas.

For get_horse_form, pass optional raceId from the same racecard to select declaration-specific statistics. Without it, the first matching declaration is selected and identified in the response. Render all supplied form sections; an empty array means no summary statistics were supplied.

The REST tomorrow=true selector is not an MCP tool argument in this release. Use REST for that dedicated feed; do not assume that a future date selects the same source feed. Dates must be calendar dates, not words such as “today” or “tomorrow”.

Raw protocol

Useful for testing. Protocol version 2025-03-26. Replace the placeholder with a token issued by the OAuth flow, or send X-API-Key: YOUR_API_KEY instead.

curl -s https://racingapi.net/api/mcp \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-03-26","capabilities":{},"clientInfo":{"name":"curl","version":"1.0"}}}'

Normal MCP clients send notifications/initialized after the handshake (HTTP 202). No session ID is issued. Subsequent calls should send the negotiated protocol version. Discovery also exposes the racingapi://guide resource and the explore-racing prompt. Use an MCP client library for production integration.

Usage and limits

Feed-retrieving tool calls share your Enterprise allowance: 10 requests per second and unlimited monthly volume. The handshake and tools/list do not count as feed usage.

A separate anti-abuse ceiling of 1,200 protocol HTTP requests per minute per IP also applies, including discovery calls. This is not an additional feed allowance. Tool calls can consume feed allowance even when the upstream data request fails after admission.

Errors

Authentication and protocol failures use HTTP status codes. Once a tool call is accepted, feed failures normally arrive in an HTTP 200 JSON-RPC response with result.isError: true. Read its text content as JSON to inspect error, status, message and optional retryAfter; HTTP 200 alone does not mean the feed request succeeded. The protocol anti-abuse ceiling can instead return HTTP 429 with a Retry-After header.

SituationResponse
Missing, expired or revoked token or keyHTTP 401. Reconnect or refresh.
Account not Enterprise or access inactiveHTTP 403
Rate limit exceededMCP tool error with retryAfter; wait before retrying (429 semantics)
Feed has no data for the requestTool result explains nothing was supplied. Nothing is invented.

Privacy and revocation

  • The AI client you choose receives the data it retrieves. Its costs, terms and privacy policy are separate from ours.
  • Revoke an OAuth connection in Connect AI, revoke its linked key, or move off Enterprise to stop access. API-key-header integrations do not create OAuth connection entries; revoke or rotate their API key to disconnect them.
  • See the Privacy policy and Terms for the MCP sections.