API Reference
KhelaDekho. API
Technical reference for KhelaDekho proxy aggregation, live scores, match telemetry, stream proxying, and API endpoints.
Edge API
FastAPI + Worker
Same routes, two runtimes
Score Provider
V1 Scores
Live scores & match data
X-Key
Authentication
Single shared key
Proxied
V2 / V4 / V5
Channel & match streams
Authentication
Single Shared Key
Every API endpoint expects the shared xkey header. The same key is used across the FastAPI app and the Cloudflare Worker. Proxy routes are exempt.
Header:
xkey: <your-shared-key>
Request Format
Requests use a standard REST format returning the shared JSON envelope.
system.out
Header: xkey: <your-shared-key>
Endpoints Spec
system_manifest
| Method & Path | Description | Access Auth |
|---|---|---|
| GET /api/v1/health | Health check | X-Key |
| GET /api/v1/scores | Scores + telemetry. Filters: ?status=live|result|fixture, ?competition=, ?date= | X-Key |
| GET /api/v1/competitions | Competition list with match counts | X-Key |
| GET /api/v1/matches/:id?slug= | Match details, lineups, stats, commentary | X-Key |
| GET /api/v1/player/:id | Player profile, stats, nationality | X-Key |
| GET /api/v1/team/:id | Team info, recent matches | X-Key |
| GET /api/v2/matches | Live matches; then /matches/:slug/channels and /matches/:slug/stream | X-Key |
| GET /api/v4/channels | V4 channel list, stream, stats | X-Key |
| GET /api/v5/matches?sport= | Match list (12 sports: football, cricket, motorsports, basketball, fight, rugby, tennis, golf, american-football, afl, volleyball, 24/7-streams; defaults to football) | X-Key |
| GET /api/v5/matches/:slug/channels?sport= | Channels & substreams for a match | X-Key |
| GET /api/v5/matches/:slug/stream?ch=&sport= | Resolve one channel/substream + proxy | X-Key |
| GET /api/v5/tv/channels | DLHD 24/7 TV channel list (878+ channels) | X-Key |
| GET /api/v5/tv/channel/:id/stream | Resolve a DLHD channel + proxy | X-Key |
Response Examples by Version
V1
GET /api/v1/scores
system.out
V2
GET /api/v2/matches
system.out
V2 / V5
GET .../matches/:slug/channels
system.out
V5
GET /api/v5/matches
system.out
V5
GET .../matches/:slug/stream?ch=
system.out
V5 TV
GET /api/v5/tv/channels
system.out
V5 TV
GET /api/v5/tv/channel/:id/stream
system.out
V4
GET /api/v4/channels
system.out
Error
Standard Error Shape
system.out
Client Code Integrations
V1 Live Scores Integration
KhelaDekho V1 API exposes live scores and match statistics sourced directly from the configured provider. The response envelope formats teams, current live scores, match period/telemetry, and referee logs.
system.out
Python Integration
system.out
Node.js Integration
system.out