Skip to main content

Basis Point Pricing

All prices in the PMX orderbook are expressed in basis points (bps), where 10,000 bps = $1.00 USDC.
bpsUSD PriceImplied Probability
100$0.011%
2500$0.2525%
5000$0.5050%
7500$0.7575%
9900$0.9999%
Valid price range for limit orders: 1–9,999 bps. Market orders allow up to 10,000 bps as a slippage limit.

Converting bps to dollars

const usdPrice = priceBps / 10000;
// 5500 bps → $0.55

Converting dollars to bps

const priceBps = Math.round(usdPrice * 10000);
// $0.55 → 5500 bps

Raw Token Amounts

All token and USDC quantities use raw units with 6 decimal places (matching the SPL Token standard on Solana).
Human AmountRaw UnitsField Value
1 token1,000,000"1000000"
0.5 tokens500,000"500000"
$1.00 USDC1,000,000"1000000"
$100 USDC100,000,000"100000000"
Quantities are always represented as strings in API responses to preserve precision for large numbers.

Converting human amounts to raw

const rawAmount = Math.floor(humanAmount * 1_000_000).toString();
// 50 tokens → "50000000"

Converting raw to human amounts

const humanAmount = parseInt(rawAmount) / 1_000_000;
// "50000000" → 50

Computing Committed Amount

When you place a buy order, USDC is locked (committed) based on the order price and quantity:
committedAmount = ceil(quantity * priceBps / 10000)
For sell orders, the committed amount equals the quantity of outcome tokens being sold:
committedAmount = quantity

JavaScript example

// Buy 50 YES tokens at 55 cents ($0.55 = 5500 bps)
const quantity = 50_000_000n;   // 50 tokens
const priceBps = 5500n;

// Ceiling division to prevent dust leak
const committed = (quantity * priceBps + 9999n) / 10000n;
// = 27,500,000 raw USDC = $27.50

Computing Market Prices

You can derive useful pricing information from the orderbook endpoint and the market endpoint.

Best Bid & Ask

Available directly from GET /markets/{marketId} or the best_bid_ask WebSocket event:
{
  "bestBid": { "yes": 5400, "no": 4500 },
  "bestAsk": { "yes": 5600, "no": 4700 }
}

Midpoint Price

The midpoint is the average of the best bid and best ask:
function midpoint(bestBid, bestAsk) {
  if (bestBid === null || bestAsk === null) return null;
  return (bestBid + bestAsk) / 2;
}

// YES midpoint: (5400 + 5600) / 2 = 5500 bps = $0.55

Spread

The spread is the difference between the best ask and best bid:
function spread(bestBid, bestAsk) {
  if (bestBid === null || bestAsk === null) return null;
  return bestAsk - bestBid;
}

// YES spread: 5600 - 5400 = 200 bps = $0.02

Last Trade Price

Available from GET /markets/{marketId}:
{
  "lastPrice": { "yes": 5500, "no": 4500 }
}

Complementary Pricing

In a binary market, YES and NO prices are linked. When yesPriceBps + noPriceBps >= 10000, complementary matching occurs.
YES PriceNO PriceSumComplementary?
5500450010000Yes (exact)
6000420010200Yes (200 bps surplus)
550040009500No (500 bps gap)
When a complementary fill occurs, the vault mints one YES and one NO token, backed by the combined USDC from both buyers. Any surplus bps (above 10,000) accrues as protocol revenue.

Minimum Order Requirements

RequirementValue
Minimum quantity1,000,000 raw (1 token)
Minimum notional10,000 raw ($0.01 USDC)
The notional value is quantity * priceBps / 10000. Both minimums must be met for an order to be accepted (market orders are exempt from the notional minimum).