Skip to Content
PredictorSDK

GET /v1/markets takes a provider filter, and rejects a provider it does not recognize

NewFixSDK

The unified catalog is large — 1.76 million markets today — and GET /v1/markets walks providers in a fixed sequence: kalshi, polymarket, predict, sxbet, hyperliquid, alpha-arcade. Kalshi alone has exceeded 789,000 rows, so a caller who wanted SX Bet markets had to page through every Kalshi, Polymarket and Predict row to reach them. There was no way to ask for one provider, and the parameter people reasonably guessed at was accepted and thrown away.

There is now a provider filter.

GET /v1/markets?provider=sxbet
GET /v1/markets?provider=polymarket&category=sports

It selects on each row's own provider value, so it takes the same token Sources lists as that platform's source key, and it composes with category as an intersection.

Two things change about the response, and both are the point of the filter. Every data[] row carries the requested provider — previously ?provider=sxbet returned the head of the Kalshi index. And pagination.total counts only that provider's rows rather than the whole catalog, so the per-provider totals add up to the unfiltered total instead of repeating it six times. has_more and next_cursor describe the filtered traversal too, so paging through one provider ends when that provider ends.

An unrecognized value is now a 400, where it used to be silently dropped. ?platform=sxbet, ?provider=sx_bet, ?provider=notaplatform — all of them previously returned 200 with a full page of Kalshi markets and the whole catalog's total, which reads as "the filter worked and these are the results." Only the six canonical IDs are accepted, case-insensitively, and the error names the legal ones:

{
  "error": "invalid provider: must be one of kalshi, polymarket, predict, sxbet, hyperliquid, alpha-arcade",
  "status_code": 400
}

That includes spellings the platform override on GET /v1/markets/{market_id} and GET /v1/events/{event_id} tolerates (sx_bet, hl, aa). Those two parameters are a different feature — they name the venue a single identifier should be resolved against, not a filter on a list — and the accepted set here is exactly the published enum so a typo cannot look like a successful filter.

What may need changing

  • If you were already sending platform= or provider= to this endpoint and ignoring the result, nothing changes for platform= (it is still not a parameter on this route, and still ignored) — but provider= with a value outside the six now returns 400 instead of an unfiltered page. Read the six values from the error message or from GET /v1/categories' neighbour, Sources.
  • provider is part of pagination scope. Keep the same value when following a next_cursor; changing or dropping it mid-traversal returns 400 pagination cursor does not match the current filters, the same way category already did.
  • pagination.total under a filter is the filtered count. If you were treating total as the catalog size, read it from an unfiltered call.

Unfiltered pagination is unchanged: same order, same totals, same cursors. The SDKs gain an optional provider argument on getMarkets.

On this page