Skip to main content
This guide covers the full trading workflow on the accounts path (/api/accounts/*).

Find a market

Before placing a trade, fetch the venue-specific identifiers for the outcome you want to trade from the Data API. Pass them to the Trading API in a market bag.
import requests
HEADERS = {"x-api-key": "YOUR_API_KEY"}

markets = requests.get(
    "https://api.predexon.com/v2/polymarket/markets",
    headers=HEADERS,
    params={"status": "open", "sort": "volume", "limit": 5},
).json()

for m in markets["markets"]:
    print(m["title"])
    for o in m["outcomes"]:
        print(f"  {o['label']}  token_id={o['token_id']}")
Each venue requires a different combination of fields in the market bag:
VenueRequired market fieldsNotes
PolymarkettokenIdEach outcome (Yes/No) has its own token ID.
PredicttokenId + marketIdBoth required - marketId is the numeric Predict market ID.
OpiniontokenId + marketIdBoth required - tokenId identifies the outcome side, marketId is the numeric Opinion market ID.
LimitlesstokenId + marketSlugmarketSlug identifies the Limitless market (e.g., "btc-up-or-down-1-hour-1778011201918" - real slugs include a unix-millis suffix).
HyperliquidassetIdIdentifies a specific HIP-4 outcome side.

Choose an order type

Market orders

Execute immediately at the best available price.
  • Market BUY - specify amount (stablecoin to spend). Fills as many shares as possible. (Hyperliquid: takes size, not amount.)
  • Market SELL - specify size (shares to sell). Sells at the best available price.

Limit orders

Sit on the orderbook at a specific price until someone takes the other side.
  • Limit BUY / SELL - specify size and price. Order rests until matched.

Amount vs size vs price

Order TypeRequiredRejected
Market BUYamountsize
Market SELLsizeamount
Limit BUYsize + priceamount
Limit SELLsize + priceamount
Sending the wrong field returns a 400 with a message indicating which field was expected.

Place an order

All orders go to POST /api/accounts/{accountId}/orders with venue set to polymarket, predict, opinion, limitless, or hyperliquid. See the Place Order reference for the full schema and per-venue examples.

Polymarket

BASE = "https://trade.predexon.com"
HEADERS = {"x-api-key": "YOUR_API_KEY", "Content-Type": "application/json"}
account_id = "YOUR_ACCOUNT_ID"

order = requests.post(
    f"{BASE}/api/accounts/{account_id}/orders",
    headers=HEADERS,
    json={
        "venue": "polymarket",
        "market": {"tokenId": "71321045679252212"},
        "side": "buy",
        "type": "market",
        "amount": "10",
    },
).json()
print(f"{order['orderId']} - status: {order['status']}, filled: {order['filled']}")

Predict

order = requests.post(
    f"{BASE}/api/accounts/{account_id}/orders",
    headers=HEADERS,
    json={
        "venue": "predict",
        "market": {
            "tokenId": "103210916722172747942846166716572235061234589599991001208035034049741504775450",
            "marketId": "46954",
        },
        "side": "buy",
        "type": "market",
        "amount": "10.00",
    },
).json()

Opinion

Opinion requires both tokenId (the outcome side) and marketId (the numeric market ID).
order = requests.post(
    f"{BASE}/api/accounts/{account_id}/orders",
    headers=HEADERS,
    json={
        "venue": "opinion",
        "market": {"tokenId": "9123", "marketId": "123"},
        "side": "buy",
        "type": "limit",
        "size": "10",
        "price": "0.42",
    },
).json()

Limitless

Limitless requires both tokenId and marketSlug. Prices snap to 0.001 ticks; size supports up to 3 decimal places.
order = requests.post(
    f"{BASE}/api/accounts/{account_id}/orders",
    headers=HEADERS,
    json={
        "venue": "limitless",
        "market": {
            "tokenId": "55222001234567",
            "marketSlug": "btc-up-or-down-1-hour-1778011201918",
        },
        "side": "buy",
        "type": "limit",
        "size": "10",
        "price": "0.420",
    },
).json()

Hyperliquid

Hyperliquid uses assetId to identify a specific HIP-4 outcome side. Each side of each market has a unique integer assetId; for recurring markets like the daily BTC binary, the asset ID rotates each cycle - fetch the current value from your market data source before each order. Every order - buy or sell - must clear a $10 notional minimum (size × price ≥ 10).
order = requests.post(
    f"{BASE}/api/accounts/{account_id}/orders",
    headers=HEADERS,
    json={
        "venue": "hyperliquid",
        "market": {"assetId": "100000020"},
        "side": "buy",
        "type": "market",
        "size": "11",
    },
).json()
Note: on Hyperliquid, market BUY takes size (the share count to acquire), not amount.

Response shape

Account-path order responses use a normalized shape:
{
  "orderId": "0xe69245af3a00e487",
  "venue": "polymarket",
  "side": "buy",
  "outcome": "Yes",
  "status": "filled",
  "createdAt": "2026-04-15T10:30:00.000Z",
  "size": "15.38",
  "price": "0.6500",
  "filled": "15.38",
  "market": { "tokenId": "71321045679252212", "outcome": "Yes" },
  "fee": { "policyApplied": true, "feeBps": 50, "platformFeeBps": 0, "partnerFeeBps": 50 }
}
status is normalized across venues: open | filled | cancelled | expired | pending | failed.

Venue differences

PolymarketPredictOpinionLimitlessHyperliquid
ChainPolygonBSCBSCBaseHyperCore
CollateralpUSDUSDTUSDTUSDC (native)USDH (USDC-pegged)
market requirestokenIdtokenId + marketIdtokenId + marketIdtokenId + marketSlugassetId
Price tickPer-market (typically 0.01)Per-market (typically 0.01)market-specific0.001 (3 decimals)up to 5 sig figs
Min orderPer CLOB (typically $1)Per CLOB (typically $1)market-specificmarket-specific$10 notional
Order queriesFull market bagFull market bagtokenId unavailable on reads - market contains marketId onlyFull market bagFull market bag
FeesConfigurable partner feeExchange fee varies by market (automatic)Exchange fee varies by market (automatic)Maker: 0%. Taker: 0.4%–3% per Limitless schedulePer Hyperliquid HIP-4 schedule (automatic)

After placing an order

Next Steps

Funding & Withdrawals

Deposit and withdraw funds

Fees & Monetization

Set up partner fees to monetize your app

Place Order Reference

Full endpoint reference

Get Positions Reference

Full endpoint reference