Skip to main content
GET
/
v1
/
prediction-market
/
search
Search prediction markets by query
curl --request GET \
  --url https://swap-api.flux.fun/v1/prediction-market/search \
  --header 'x-api-key: <api-key>'
{
  "total_results_count": 42,
  "current_page": [
    {
      "series_ticker": "SERIES-BTC-2024",
      "series_title": "Bitcoin Price Series 2024",
      "event_ticker": "EVENT-BTC-2024",
      "event_subtitle": "Bitcoin price prediction event",
      "event_title": "Bitcoin Price Event 2024",
      "category": "Science and Technology",
      "total_series_volume": 1000000,
      "total_volume": 500000,
      "total_market_count": 10,
      "active_market_count": 8,
      "markets": [
        {
          "ticker": "KXBTC-24DEC31-T100K",
          "yes_bid": 45,
          "yes_ask": 47,
          "last_price": 46,
          "yes_bid_dollars": "0.45",
          "yes_ask_dollars": "0.47",
          "last_price_dollars": "0.46",
          "price_delta": 1.5,
          "close_ts": "2024-12-31T23:59:59Z",
          "expected_expiration_ts": "2025-01-01T12:00:00Z",
          "open_ts": "2024-01-01T00:00:00Z",
          "score": 0.95,
          "yes_subtitle": "<string>",
          "no_subtitle": "<string>",
          "title": "<string>",
          "potential_payout_from_100_dollars": {},
          "icon_url_dark_mode": "<string>",
          "icon_url_light_mode": "<string>",
          "background_color_light_mode": "<string>",
          "background_color_dark_mode": "<string>"
        }
      ]
    }
  ],
  "next_cursor": "<string>"
}

Authorizations

x-api-key
string
header
required

Query Parameters

query
string
required

Search query

Example:

"bitcoin"

page_size
number
default:25

Results per page (default: 25)

Example:

25

order_by
string
default:querymatch

Sort order (default: querymatch)

Example:

"trending"

fuzzy_threshold
number
default:4

Fuzzy search threshold (default: 4)

Example:

4

with_milestones
boolean
default:true

Include milestones (default: true)

Example:

true

cursor
string

Pagination cursor

Example:

"cursor123"

status
enum<string>

Market status filter

Available options:
open,
unopened,
closed,
settled
category
string

Category filter

Example:

"Science and Technology"

frequency
enum<string>

Frequency filter

Available options:
hourly,
daily,
weekly,
monthly,
annual

Response

200 - application/json
total_results_count
number
required

Total number of results

Example:

42

current_page
object[]
required

Current page of search results

next_cursor
string | null

Cursor for next page