Sports Db Client
The TheSportsDB client.
val client = SportsDbClient() // free key 123, v1 only
val premium = SportsDbClient { apiKey = "..." } // v1 and v2
val arsenal = client.v1.lookup.team(133604)
val today = premium.v2.tv.country("Canada")Content copied to clipboard
One client is safe to share across coroutines and threads; its rate limiter and cache are shared by all calls made through it. Create one per API key and reuse it.
Functions
Link copied to clipboard
Whether SportsDbConfig.apiKey is a premium key: v2 accepts it. Makes one call (v2 lookup/league/4328) unless the key is the free key.