Quotes
A quote is a priced, time-bounded offer that binds contract, side, size, price, fee and quantity together, and tells your ledger exactly what to reserve. It is the record an order is checked against.
Create a quote
quotes:write, plus X-Parity-User.{
"marketId": "ctr_9f31c2…", // required. The contract id from /api/v1/events
"side": "YES", // required. YES | NO
"action": "buy", // optional, defaults to "buy"
"stake": 50 // cash. > 0 and ≤ 1,000,000
}{
"marketId": "ctr_9f31c2…",
"side": "YES",
"action": "sell",
"contracts": 68.6111 // quantity. The only way to exit in full.
}| Field | Type | Notes |
|---|---|---|
marketId | string | The opaque ctr_ contract id published by /api/v1/events. An id that names no contract is 404 market_not_found. |
side | string | YES or NO. Uppercase. |
action | string | buy opens or adds; sell exits. |
stake | number | Gross cash in dollars, bounded on both ends: below a cent buys nothing, and there is a maximum. |
contracts | number | Quantity. Sizes a sell only. |
Swipe the table sideways for more columns.
Sizing: exactly one of stake or contracts
Send one. Both is 400 invalid_request, so a stale stake sent beside a computed contracts cannot trade an unintended size.
- A buy is sized in cash. A buy sized in
contractsis refused, because it would commit the player to whatever that quantity costs at fill time. - An exit is sized in contracts. To close 68.6111 contracts by cash you would have to invert Parity's fee rounding; slightly high oversells and slightly low leaves an unsellable fraction. Naming the quantity avoids that.
The fee comes off the top
A $50 stake at 120bps wagers $49.40. The fee is taken from the stake, not added on top, so the cash committed is the authorizationAmount and a fully filled order releases nothing beyond any unused venue fee reservation (below). A $50 stake is never charged $50.60.
stake 50.00
platformFee 0.60 = 50.00 × 120bps
tradeAmount 49.40 ← what buys contracts
contracts 68.6111 = 49.40 ÷ 0.72On a live buy, the venue's fee is reserved inside the stake too
On a live account the venue charges its own taker fee on top of what it is sent, so the quote reserves room for that fee inside the stake: venueFee is the amount reserved, tradeAmount is the stake less the platform fee and that reservation, and contracts, potentialPayout and potentialProfit are priced on that tradeAmount, which is what is sent. The customer is never debited more than the stake.
The reservation assumes a fill at a better price than quoted, where the fee per dollar is higher, so the venue usually charges less. Book what the order reports: operatorMoney.venueFee on the order is the venue fee charged to the customer, which is what the venue charged, capped at the room the authorization has left, with Parity absorbing anything above it; the unused part of the reservation comes back in releaseAmount; and filledQuantity is what the player holds. See The money contract.
On a live account venueFee also carries Parity's execution fee, which the market takes in the same fee as its own taker fee. allIn.charges lists it as builder_fee, marked includedIn: "venueFee", so you can see how much of the venue fee it is. It is already inside venueFee: never add it to the debit again.
Where your terms set a fee of your own, it comes off the stake beside the platform fee, a buy only: allIn.operatorFee and operatorMoney.operatorFee carry it, tradeAmount is net of it, and you keep it, less any share your terms give your aggregator or Parity.
A live buy sends at least $1
The market takes no buy under $1, measured on what is sent (the stake less the platform fee and the venue fee reservation). A smaller live buy is refused at quote time with 422 invalid_stake, so the player never sees a ticket the market would refuse. At the standard platform fee, $1.10 or more clears this on every market; below that it depends on the market's fee. A sandbox account has no minimum.
The quote object
{
"quoteId": "fc3be731-98dc-4c03-80ac-23576a708d9c",
"contractId": "ctr_9f31c2…",
"side": "YES",
"action": "buy",
"executionPrice": 0.72, // WHAT YOU ARE CHARGED, 0-1
"limitPrice": 0.72, // the worst level the trade may reach; the order's limit
"priceBasis": "book", // book | reference
"priceSource": "venue_book", // venue_book | stored_book | stored_reference
"stake": 50,
"platformFee": 0.6,
"platformFeeBps": 120,
"commercialTerms": { "termsId": "…", "feeBps": 120, "revShareBps": 0 },
"venueFee": null,
"tradeAmount": 49.4,
"contracts": 68.6111,
"potentialPayout": 68.61,
"potentialProfit": 18.61,
"requestedStake": 50, // what you asked for
"supportedStake": null, // set when the book supports less than the request
"maxWagerNow": null, // set when YOUR exposure window narrowed it
"narrowedBy": null, // depth | tenant_exposure | null
"expiresAt": "2026-08-20T04:44:02.120Z",
"sourceTimestamp": "2026-08-20T04:43:27.496Z",
"simulated": true,
"freshness": { "level": "fresh", "ageSeconds": 5, "feed": "websocket" },
"routing": { "consideredVenues": 1, "routable": false },
"depth": null, // what the book could absorb, where levels are published
"liveBook": { // the live book this was priced from, or null
"yes": { "bid": 0.71, "ask": 0.72 },
"no": { "bid": 0.28, "ask": 0.29 },
"readAt": "2026-08-20T04:43:27.496Z"
},
"priceQuality": { "midPrice": 0.715, "spread": 0.01, "impliedReturn": 0.981 },
"allIn": { // the whole trade for display. Book operatorMoney, not this
"stake": 50,
"parityFee": 0.6,
"operatorFee": 0, // your own fee, where your terms set one
"operatorFeeBps": null,
"venueFee": null,
"venueRate": null,
"venueRateSource": "unknown",
"tradeAmount": 49.4,
"contracts": 68.6111,
"executablePrice": 0.72,
"decimalOdds": 1.3722,
"totalCustomerDebit": 50,
"potentialPayout": 68.61,
"netResult": 18.61,
"charges": [
{ "name": "parity_platform_fee", "customerPays": 0.6, "splitOfExisting": 0, "bps": 120, "unconfigured": false },
{ "name": "operator_fee", "customerPays": 0, "splitOfExisting": 0, "bps": null, "unconfigured": true },
{ "name": "builder_fee", "customerPays": 0, "splitOfExisting": 0, "bps": 0, "unconfigured": false, "includedIn": "venueFee" },
{ "name": "operator_revenue_share", "customerPays": 0, "splitOfExisting": 0, "bps": 0, "unconfigured": false },
{ "name": "aggregator", "customerPays": 0, "splitOfExisting": 0, "bps": null, "unconfigured": true }
],
"feeConfigVersion": 1
},
"operatorMoney": {
"currency": "USD",
"authorizationAmount": "50.00", // RESERVE THIS
"actualDebit": "50.00",
"releaseAmount": "0.00",
"tradeAmount": "49.40",
"platformFee": "0.60",
"operatorFee": "0.00",
"venueFee": "0.00",
"venueFeeKnown": false
},
"operatorExitMoney": null
}{
…
"action": "sell",
"operatorMoney": null, // deliberately null on an exit
"operatorExitMoney": {
"currency": "USD",
"sellProceeds": "48.72", // CREDIT THIS. Already net of both fees.
"platformFee": "0.59",
"venueFee": "0.00",
"venueFeeKnown": false
}
}Two objects, one for each direction
A buy is a debit and a sell is a credit. With one object for both, a wallet would see an authorizationAmount on a sale and debit the player for selling their own position, so the entry object is null on an exit.
Both carry exact decimal strings. On the entry object, authorizationAmount = actualDebit + releaseAmount and actualDebit = tradeAmount + platformFee + operatorFee + venueFee hold exactly; check them with no tolerance.
| Field | Meaning |
|---|---|
quoteId | Present this to the order endpoint. Spendable once. |
executionPrice | The price per contract this quote will fill at, 0-1. A buy takes the ask, a sell takes the bid; buying NO costs 1 − bid. Never a midpoint. |
limitPrice | The deepest price level the trade reaches, 0-1, and the limit the order is placed at (widened by any maxSlippage you grant, rounded only in the player's favour). On a trade that stays on the best level it equals executionPrice; on a thin book that walks several levels, executionPrice is their average and limitPrice is the last level. |
liveBook | The bid and ask on both outcomes as Parity read the venue for this quote, with readAt, so a page can show the price the trade is priced at. Null unless priceSource is venue_book. |
priceBasis | book means a real side of a real book. reference means no usable two-way price existed and this is an estimate: display it as one, or not at all. |
commercialTerms | The terms this quote was struck under, so your reconciliation can check the rate directly. |
venueFee | On a live buy, the venue fee reserved inside the stake, with venueFeeKnown: true on operatorMoney. It is sized for a fill at a better price than quoted, so the venue usually charges less; the order reports the venue fee charged to the customer, capped at the room the authorization has left, with Parity absorbing anything above it. On a live cash out it is an estimate from the market’s published fee curve, rounded up to the cent, so the proceeds shown are not overstated; the order books what the sale actually returned. null when the execution fee is not priced into the quote, as on a sandbox account. The money objects then report it as 0.00 with venueFeeKnown: false, so you can see the difference between “free” and “unknown”. |
liveEquivalent | Sandbox buys only. The same quote priced as on a live account, with the venue fee and the builder fee reserved: venueFee, contracts, potentialPayout and operatorMoney. A live payout is lower than a sandbox one, so certify your payout display against these figures. Read only; the sandbox fill is unchanged. |
contracts | Quantity, rounded to four decimals on the wire; the stored quote keeps full precision for the fill check. On a live buy it is priced on the tradeAmount, net of the reserved venue fee. On a live cash out it is the exact quantity that will be sent. A sandbox sale sized in contracts sells exactly the contracts you asked (13.37 asked sells 13.37), and operatorExitMoney is priced on that count: its value at the quoted price, less the fee, to the cent. |
potentialPayout | $1.00 per contract if the side is right, rounded down to the cent. |
potentialProfit | potentialPayout − the full stake, fee included. |
expiresAt | Absolute. 30 seconds by default on an ordinary market, 10 seconds on one in play or within 15 minutes of its close, 5 seconds on an up or down crypto contract (5 minute, 15 minute and 4 hour series). |
sourceTimestamp | When the underlying price was published upstream. Null when unknown. |
freshness | The server’s verdict on the price’s age: level, ageSeconds, feed. Show it; do not recompute it. |
routing | How many sources could have competed, and whether any may. The alternatives are never listed. |
simulated | true when the fill is produced locally rather than at a venue. |
Swipe the table sideways for more columns.
This surface has no venue, venueListingId or upstream market id. A contract is addressed only by its ctr_… id, the one the catalogue publishes and the order returns.
The reference probability is not on the quote
To show a player both, read yesCents from the catalogue and executionPrice from the quote. Label the first as the probability and the second as the price.
Expiry
- A quote stands for 30 seconds by default, 10 seconds on a fixture in play or a market within 15 minutes of its close, and 5 seconds on an up or down crypto contract (5 minute, 15 minute and 4 hour series).
expiresAtis absolute: use it instead of your own timer, and do not hard-code these numbers. - Expiry is checked against the stored timestamp, never one the client sends, so a client cannot hold a favourable price after the market moves.
- An expired quote is
409 quote_expiredand is never re-priced, because the player would trade at a price they did not see. - A quote is spendable once. A second order against the same
quoteIdis409 quote_already_used. - A quote issued to one operator cannot be spent by another:
403 quote_not_yours.
Stale prices: a cap before a refusal
A small trade on a slightly old price is normal; a large one at the same moment may be someone acting on news Parity has not seen yet. So there are two answers.
| Response | Meaning | What to do |
|---|---|---|
422 stake_exceeds_stale_limit | Merely stale. The price is tradeable at a smaller size; this stake is not. | Re-request at no more than maxStake, which the refusal carries as a number beside detail. |
409 price_stale | Too old to trade at any size. | Wait for the next tick and re-quote. Not a payload problem. |
Swipe the table sideways for more columns.
The cap is checked against the ticket's stake, which is normalised and rounded, not against the raw request.
When a quote is refused
| Status | error | What happened | What to do |
|---|---|---|---|
404 | market_not_found | No such contract. | Re-read the catalogue. Check the ctr_ id you sent. |
403 | market_not_offered | The contract exists; your operator is not offered it. Not a 404, so you do not debug your ids. | Commercial, not technical. Escalate instead of retrying. |
409 | price_stale | The upstream price is too old to trade at any size. | Wait for the next tick and re-quote. |
422 | stake_exceeds_stale_limit | Merely stale (or aging past its cap): a small stake is fine, this one is not. | Re-request at no more than maxStake. |
422 | market_not_open | The contract has closed, resolved or been voided. Or it is an up or down window that has not opened yet, or a 5 minute, 15 minute or 4 hour window for a coin other than BTC, ETH, SOL and XRP, or a commodity up or down window on an account that does not have them enabled. | Stop offering it. detail carries the status, or the time the window opens. |
422 | no_price | No usable price could be derived for that side. | Show “no price”. Do not fall back to the reference. |
422 | invalid_stake | The stake buys zero contracts; or, on a live account, a buy would send the market less than $1 once the platform fee and the venue fee reservation are taken out; or a live cash out was sized with stake rather than contracts. | Raise the stake (on a live account, $1.10 clears the minimum on every market at the standard platform fee), or size the sell in contracts. |
422 | insufficient_position | Live accounts, sells. More contracts than the player holds free to sell, counting contracts already promised to their other cash outs in progress. | Offer sellableContracts, which the refusal carries. |
422 | below_venue_minimum | Live accounts, sells. Fewer contracts than the market’s minimum sale. A whole position under the minimum cannot be cashed out at all and settles normally. | Raise the sale to minimumContracts if the player holds enough; otherwise do not offer a cash out on this position. |
403 | sell_not_available | Live accounts, sells. Cashing out before settlement is turned off. The position stays open and settles normally. | Hide the cash-out control until it is available again. |
403 | cash_out_paused | Sells, any account. Cash outs are paused for now, for every account or for yours. The position stays open until the market settles. | Show the cash-out control as paused and ask again later. |
503 | trading_paused | The trading pause on your account is on. No new trades are taken; open positions settle normally. | Wait for the pause to be lifted. |
503 | order_lane_unavailable | Live accounts. The service that sends live orders has not reported recently, for example during a restart. Nothing was quoted. | Retry in a minute. |
503 | live_execution_unavailable | Live execution is unavailable for this account right now. Nothing was quoted. | Retry later. |
400 | invalid_request | The body failed validation, including sending both stake and contracts, or neither. | Read detail for the failing field. |
400 | missing_user | No X-Parity-User header. | Send your own id for the player. |
400 | invalid_json | The body did not parse. | Fix the request. |
409 | market_paused | The venue was read for this quote and offers nothing on the side being traded this instant (any contract whose book Parity reads, not only a five-minute one), or the contract settles on a protocol Parity does not trade (detail: “This market is not available to trade yet.”). | Re-quote in a moment; the empty-book case clears by itself. The protocol case does not: stop offering the contract. |
409 | line_not_available | The line is not wagerable. On a fast up-or-down contract (the 5 minute, 15 minute and 4 hour series): the outcome being bought is executable above 95c; the other outcome is still quoted on its own price. On any contract: after every fee the wager could not return more than it costs even if it wins. Buys only: a holder of the near-certain side can always quote an exit. maxCents carries the offending price. | Re-quote. The verdict is recomputed from the book on every request. |
409 | price_unverified | There is no book behind the price, or the live book could not be read for this quote. A quote is priced from the live book or not at all, never from an older stored price or the reference probability. | Retry in a moment. The request is fine; the market state stopped it. |
409 | over_tenant_exposure | Your operator has committed its aggregate stake for the current window, across the API and the embed together. A budget with room for a smaller ticket produces a smaller quote instead (narrowedBy: tenant_exposure). | Wait retryAfterMs, then re-quote. Re-pricing does not help. |
409 | stake_exceeds_available_depth | The book cannot cover the requested stake at these terms. | Re-quote at supportedStake; the refusal carries it beside requestedStake. |
403 | user_suspended | You suspended this player. | Not retryable. Lift the suspension on your side. |
403 | over_wager_limit | Above a maximum wager in force for this account. | Send no more than maxStake. It works immediately. |
403 | over_period_limit | This account has staked its allowance for a rolling window. A smaller stake may not help. | Wait rather than re-pricing. The allowance refills with time. |
Swipe the table sideways for more columns.
What a quote refusal carries
Always error and detail. Where a refusal is about a number, the number is a field too, so you never parse prose: maxStake on stake_exceeds_stale_limit and over_wager_limit, maxCents on line_not_available, retryAfterMs on over_tenant_exposure, and requestedStake with supportedStake on stake_exceeds_available_depth, and sellableContracts with minimumContracts on a live cash out refused as insufficient_position or below_venue_minimum. Branch on error, show detail.
On a quote, 409 means re-quote and 422 means fix the request
On POST /api/v1/quotes a 409 means the request was correct but the state moved: ask again shortly. A 422 means the request must change; retrying it unchanged fails forever.
The order routes are different: branch on error, never on the status alone. A 409 reconciliation_required is not a refusal, so keep the hold and resolve the order from your own clientOrderId; 409 quote_already_used names the order that spent the quote; and 409 idempotency_conflict means your clientOrderId already names an order placed against a different quote. See Errors.
With the SDK
The type signatures enforce the two sizing rules, so a buy cannot be sized in contracts or an exit in cash.
const player = parity.forUser('user-4471');
const buy = await player.quoteBuy({ contractId, side: 'YES', stake: '50.00' });
// buy.operatorMoney.authorizationAmount → "50.00", a branded Decimal string
const exit = await player.quoteSell({ contractId, side: 'YES', contracts: 68.6111 });
// exit.operatorExitMoney.sellProceeds → "48.72"
const order = await player.submitOrder({ quoteId: buy.quoteId, clientOrderId: 'ticket-9031' });Money comes back as a branded Decimal string that cannot silently become a number, with toMinorUnits / addDecimal helpers for arithmetic. See the SDK.