Skip to main content
GET
/
v1
/
prediction-market
/
markets
Get Markets
curl --request GET \
  --url https://swap-api.flux.fun/v1/prediction-market/markets \
  --header 'x-api-key: <api-key>'
{
  "markets": [
    {
      "ticker": "KXBTC-24DEC31-T100K",
      "eventTicker": "KXBTC-24DEC31",
      "title": "Will Bitcoin reach $100,000 by Dec 31?",
      "subtitle": "Bitcoin price prediction market",
      "status": "open",
      "marketType": "binary",
      "yesBid": 45,
      "yesAsk": 47,
      "noBid": 53,
      "noAsk": 55,
      "lastPrice": 46,
      "yesBidDollars": "0.45",
      "yesAskDollars": "0.47",
      "noBidDollars": "0.53",
      "noAskDollars": "0.55",
      "lastPriceDollars": "0.46",
      "liquidity": 50000,
      "liquidityDollars": "500.00",
      "volume": 1000000,
      "volume24h": 50000,
      "openInterest": 25000,
      "openTime": "2024-01-01T00:00:00Z",
      "closeTime": "2024-12-31T23:59:59Z",
      "expirationTime": "2025-01-01T12:00:00Z",
      "rulesPrimary": "This market resolves to Yes if Bitcoin trades at or above $100,000",
      "rulesSecondary": "<string>",
      "yesSubTitle": "Bitcoin reaches $100K",
      "noSubTitle": "Bitcoin stays below $100K",
      "iconUrlDarkMode": "example.com/icon.png",
      "iconUrlLightMode": "example.com/icon.png",
      "backgroundColorLightMode": "#AA00FF",
      "backgroundColorDarkMode": "#D24DFF"
    }
  ],
  "count": 20,
  "cursor": "<string>"
}

Authorizations

x-api-key
string
header
required

Query Parameters

limit
number

Maximum number of markets to return. Defaults to 20. Maximum is 1000.

status
string

Market status filter. Options: unopened, open, paused, closed, settled. Defaults to "open".

cursor
string

Pagination cursor for fetching the next page of results.

event_ticker
string

Filter by event ticker. Multiple event tickers can be provided as a comma-separated list (maximum 10).

tickers
string

Filter by specific market tickers. Comma-separated list of market tickers to retrieve.

Response

200 - application/json
markets
object[]
required
count
number
required
Example:

20

cursor
string | null