Skip to main content

Search Markets

GET
Search for prediction markets by keyword, tag, or slug.

Parameters

NameTypeDefaultDescription
qstring-Search query
slugstring-Exact market slug match
tagstring-Category: crypto, politics, sports, entertainment
limitint10Max results (max: 100)
offsetint0Pagination offset
sortstringvolumevolume, liquidity, end_date, recent
min_volumeint100Minimum volume in USD
accepting_ordersbooltrueOnly tradeable markets
ending_soonboolfalsePrioritize markets ending within 24h

Example

curl "https://luckylobster.io/api/agent/v1/markets/search?q=bitcoin&sort=volume" \
  -H "Authorization: Bearer ll_live_..."
Response
{
  "success": true,
  "data": [
    {
      "id": "1314069",
      "slug": "bitcoin-up-or-down-on-february-3",
      "question": "Bitcoin Up or Down on February 3?",
      "outcomes": ["Up", "Down"],
      "outcomePrices": ["0.65", "0.35"],
      "volume": "409100.65",
      "liquidity": "39255.13",
      "acceptingOrders": true
    }
  ],
  "context": {
    "topMatch": { "id": "1314069", "question": "..." }
  }
}

Get Market Details

GET
Get detailed information about a specific market including token IDs for trading.

Example

curl "https://luckylobster.io/api/agent/v1/markets/1314069" \
  -H "Authorization: Bearer ll_live_..."
Response
{
  "success": true,
  "data": {
    "id": "1314069",
    "conditionId": "0xf46bf33576e8341821161316705ab2357312f58d58b7d157cb8dca73b656b326",
    "question": "Bitcoin Up or Down on February 3?",
    "tokens": [
      {"tokenId": "36656454529662513...", "outcome": "Up", "price": "0.345"},
      {"tokenId": "10609233133841503...", "outcome": "Down", "price": "0.655"}
    ],
    "clobTokenIds": ["36656454529662513...", "10609233133841503..."],
    "spreads": [
      {"outcome": "Up", "bid": "0.34", "ask": "0.35", "spread": "0.01"}
    ]
  }
}

Crypto Markets

GET
Quick lookup for crypto up/down markets.

Parameters

NameTypeDescription
assetstringbtc, eth, sol, doge, etc.
timeframestringdaily, hourly, 15m

Example

curl "https://luckylobster.io/api/agent/v1/markets/crypto?asset=btc&timeframe=daily" \
  -H "Authorization: Bearer ll_live_..."

Find by Slug

GET
Find a market by its exact Polymarket URL slug.

Example

curl "https://luckylobster.io/api/agent/v1/markets/by-slug?slug=btc-updown-15m-1770129900" \
  -H "Authorization: Bearer ll_live_..."

Order Book

GET
Get the full order book for a token.

Parameters

NameTypeDescription
token_idstringToken ID (required)
token_idsstringComma-separated for batch (max 20)

Example

curl "https://luckylobster.io/api/agent/v1/orderbook?token_id=36656454529662513..." \
  -H "Authorization: Bearer ll_live_..."
Response
{
  "success": true,
  "data": {
    "tokenId": "36656454529662513...",
    "bids": [
      {"price": "0.65", "size": "1000"},
      {"price": "0.64", "size": "500"}
    ],
    "asks": [
      {"price": "0.66", "size": "800"}
    ],
    "summary": {
      "bestBid": "0.65",
      "bestAsk": "0.66",
      "spread": "0.01"
    }
  }
}

Prices

GET
Get current prices for tokens.

Parameters

NameTypeDescription
token_idstringToken ID (required)
token_idsstringComma-separated for batch

Example

curl "https://luckylobster.io/api/agent/v1/prices?token_id=36656454529662513..." \
  -H "Authorization: Bearer ll_live_..."
Response
{
  "success": true,
  "data": {
    "tokenId": "36656454529662513...",
    "midpoint": "0.655",
    "buyPrice": "0.66",
    "sellPrice": "0.65",
    "lastTradePrice": "0.65"
  }
}

Spread

GET
Get the bid-ask spread for a token.

Example

curl "https://luckylobster.io/api/agent/v1/spread?token_id=36656454529662513..." \
  -H "Authorization: Bearer ll_live_..."
Response
{
  "success": true,
  "data": {
    "bid": "0.65",
    "ask": "0.66",
    "spread": "0.01",
    "spreadPercent": "1.52"
  }
}

Market Data (All-in-One)

GET
Get comprehensive market data in a single request.

Example

curl "https://luckylobster.io/api/agent/v1/market-data?token_id=36656454529662513..." \
  -H "Authorization: Bearer ll_live_..."
Returns prices, spread, and order book summary combined.