The machine-readable contract for Live Tennis API — real-time tennis scores, players, rankings, match-winner market prices and model win-probability over REST and WebSocket.
| File | Purpose |
|---|---|
openapi.yaml |
The specification — OpenAPI 3.1.0, 12 endpoints, 11 schemas |
docs/ |
Rendered reference, published to https://docs.livetennisapi.com |
The spec is the source of truth for our official SDKs. If the spec and an SDK disagree, the spec is right and the SDK has a bug.
Point any OpenAPI-compatible tool at the raw file:
https://raw.githubusercontent.com/livetennisapi/openapi/main/openapi.yaml
Generate a client in your language of choice:
# openapi-generator
openapi-generator generate \
-i https://raw.githubusercontent.com/livetennisapi/openapi/main/openapi.yaml \
-g go -o ./livetennis-goOr import it into Postman, Insomnia, Bruno, Hoppscotch, or Scalar directly.
Prefer an official SDK? They handle auth, retries, pagination, tier errors and the WebSocket feed for you. See the organisation profile for the current list.
Base URL — https://api.livetennisapi.com/api/public/v1
Auth — either header works:
Authorization: Bearer twjp_…
X-API-Key: twjp_…
Tiers — BASIC (matches, scores, players, fixtures, history) · PRO (+ events, markets)
· ULTRA (+ analysis, model fields, WebSocket). Calling above your tier returns
403 {"error":"upgrade_required"}.
Conventions
- Timestamps are UTC ISO 8601 with a
Zsuffix. - Lists return
{data, meta}; single resources return the object directly. limitdefaults to 50, caps at 200; paginate withoffset.- Ignore unknown fields. Additive changes ship within
v1— a client that rejects unrecognised fields will break. Every official SDK parses permissively for this reason.
The spec is versioned alongside the API's v1 surface. Changes within v1 are additive
only — new endpoints, new optional fields. Removing a field or changing its type would
require v2.
CI lints every change with Spectral and fails
the build on a breaking diff against main.
Found a mismatch between this spec and what the API actually returns? That's a bug worth reporting — open an issue with the endpoint, the request, and the response you got.
Everything in the Live Tennis API developer surface:
| Install | Source | Package | |
|---|---|---|---|
| Python client | pip install livetennisapi |
repo | package |
| JavaScript / TypeScript client | npm install livetennisapi |
repo | package |
| MCP server for LLM agents | npx livetennisapi-mcp |
repo | package |
- API reference — https://docs.livetennisapi.com (plain-HTML version, no JavaScript required)
- Website and plans — https://livetennisapi.com
The specification document in this repository is MIT licensed — generate clients, vendor it, do what you like with it.
Use of the API service itself is governed by the Terms of Service.