API reference · Live events

List ended events

GET/v1/events/ended

Events that ended in the last days, newest first, with the same rows as the live calendar.

On this page

Auth. None. Without a token the call is served as Free (the Free delay and request budget, shared per IP); send Authorization: Bearer lb_… for your plan's.

Limits. Counts against your plan's API requests (60, 600 or 3,000 a minute on Free, Builder and Standard).

Parameters

Query parameters

NameTypeRequiredDescription
daysintegernoHow many days back. 1 to 365. Default 30.
limitintegernoPage size. 1 to 1000. Default 200.
cursorstringnonext_cursor from the previous page.
fieldsstringnolite (default) or full.

Request

Terminal
curl "https://api.langbot.ai/v1/events/ended?days=7&limit=1"

Response

200 OK

JSON
{
  "ts": 1793685870750,
  "days": 7,
  "fields": "lite",
  "limit": 1,
  "next_cursor": "bzox",
  "events": [
    {
      "id": "ev_kxnhllindsay_27",
      "title": "NHL Ted Lindsay Award",
      "kind": "sports",
      "starts_at": 1791424800000,
      "ends_at": 1814968800000,
      "status": "ended",
      "speaker_keys": [],
      "meta": {
        "time_known": false,
        "window": false,
        "category": "Sports",
        "venue": "kalshi",
        "speaker_key": "nhllind"
      },
      "rights": "unknown",
      "phrases": ["no", "yes"],
      "markets": [
        {
          "ticker": "KXNHLLINDSAY-27-CHELLEBUYCK37",
          "venue": "kalshi",
          "event_id": "ev_kxnhllindsay_27",
          "title": "Ted Lindsay Award: Connor Hellebuyck wins",
          "phrases": ["yes", "no"],
          "status": "open",
          "close_ts": 1814968800000,
          "meta": {}
        },
        {
          "ticker": "KXNHLLINDSAY-27-ISHESTERKIN31",
          "venue": "kalshi",
          "event_id": "ev_kxnhllindsay_27",
          "title": "Ted Lindsay Award: Igor Shesterkin wins",
          "phrases": ["yes", "no"],
          "status": "open",
          "close_ts": 1814968800000,
          "meta": {}
        }
      ],
      "sources": []
    }
  ]
}

A real response from the API; long lists are cut to their first items.

Errors

StatuscodeWhen
401token_invalidA token was sent and not recognised. Send a valid one, or none to call anonymously.
422validation_errorA parameter failed validation; detail[].loc names it.
429rate_limitedOver your request budget; wait Retry-After seconds.

Every error body is {"detail": …, "code": "…"}; branch on code. All codes: Errors.