League

HTTP Request

GET https://api.b365api.com/v3/league

curl "https://api.b365api.com/v3/league?token=YOUR_TOKEN&sport_id=1"

URL Parameters

Parameter Required? Description
sport_id Yes R-SportID
cc No Eg: 'co' for Colombia (R-Countries)
max_id No with SQL id < max_id

HTTP Response

league.json

FAQ

how to load all leagues

Tech background: it's very slow to call the SQL with large OFFSET like LIMIT 92000, 100

so we decided to use max_id parameter. the data is returned by id DESC, so first call without max_id parameter, then use the smallest id as max_id parameter for next call. eg:

/v3/league?sport_id=1 returns min id as 40397 (from pager.min_id), next call can be /v3/league?sport_id=1&max_id=40397, then min id will be 38740 (from pager.min_id), next call can be /v3/league?sport_id=1&max_id=38740. until max_id <= 0 or empty response.

contact support at betsapi.com for any questions or feedback.

Changes

2025-09-25 (v3)

  • due to performance issue, add 'max_id' to replace 'page' parameter

results matching ""

    No results matching ""