Place Market Order
Place a market order that the router splits across routed venues
Overview
Place a market order that the router splits across every routed venue offering the outcome identified bypredexonId. Returns per-venue fills, an aggregate summary, and the routing decision.
The router:
- Expands
predexonIdto the cross-venue equivalence set. - Filters to venues the account has enabled, intersects with those the router is actively streaming.
- For buys — fans out balance reads and aborts if aggregate balance is below the requested notional. For sells — fans out position reads to cap each venue’s allocation by available size.
- Walks the merged fee-inclusive order books from best to worst effective price and computes a per-venue split.
- Dispatches per-venue orders in parallel.
- Collects every dispatch result (success or failure) and returns a unified response.
fills[]. A 201 Created response may still contain per-venue failures — check summary.venuesFailed.
See the Order Router concept page for an end-to-end explanation of how routing and splitting work.
Path Parameters
| Param | Type | Description |
|---|---|---|
accountId | string | Trading account ID. Must belong to the calling API key. See the Trading API accounts docs for how to create and fund one. |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
predexonId | string | Yes | Canonical predexon_id for the outcome. The router expands it to every routed venue listing for that outcome. |
side | string | Yes | buy or sell. |
amount | string | Required on buy | USD/stablecoin notional to spend. Positive decimal string. Must not be set on sell. |
size | string | Required on sell | Number of shares to sell. Positive decimal string. Must not be set on buy. |
Response Fields
Top level
| Field | Type | Description |
|---|---|---|
routerOrderId | string | Unique identifier for this routed order (prefix rord-). |
predexonId | string | Echoes the request predexonId. |
side | string | buy or sell. |
type | string | Always "market". |
errorCode | string? | Present only on a 502 response when every dispatched venue failed. Set to "all_venues_failed". Absent on a 201. |
requestedAmount | string? | Echo of the request amount. Present on buy orders; null on sell orders. |
requestedSize | string? | Echo of the request size. Present on sell orders; null on buy orders. |
fills[] | array | One entry per dispatched venue. |
summary | object | Aggregate fill summary. |
_routing | object | Routing decision transparency — see below. |
x-request-id response header — the router echoes the header on every response. There is no _trace block in the body.
Fill entry
size, price, and amount are normalised to 6-decimal strings across every venue — partners parsing fills get consistent formatting regardless of which venue produced the fill.
| Field | Type | Description |
|---|---|---|
venue | string | polymarket, predict, opinion, or limitless. |
orderId | string | Venue-native order identifier. Use this when reconciling with the venue directly. |
status | string | filled, partial, open, cancelled, or failed. |
size | string | Shares matched on this venue. |
price | string | Volume-weighted average fill price on this venue. |
amount | string | Notional (stablecoin) matched on this venue. |
fee | object? | Venue-native fee data, passed through verbatim from the venue. Absent when the venue does not report one. Shape varies by venue. |
error | string? | Present only when status is failed. |
Summary
| Field | Type | Description |
|---|---|---|
totalSize | string | Aggregate shares matched across all venues. |
totalAmount | string | Aggregate notional matched across all venues. |
avgPrice | string | Volume-weighted average fill price across all venues. |
venuesUsed | int | Number of venues that successfully produced a fill (filled, partial, or open). |
venuesFailed | int | Number of venues whose dispatch failed. A 201 can still have venuesFailed > 0. |
_routing
Transparency block describing how the router made its allocation decision.
| Field | Type | Description |
|---|---|---|
considered[] | array | Venues the router evaluated and could reasonably have routed to. Infrastructure dropouts (missing or disconnected books) are excluded. Read fills[] for what happened — considered[] records the decision set. |
considered[].venue | string | |
considered[].avgPrice | string? | Projected volume-weighted price on this venue. null if no projected fill. |
considered[].topLevelPrice | string? | Top-of-book price on the relevant side. |
considered[].droppedReason | string? | Reason this venue received no allocation. Known values are zero_depth (no depth on the relevant side) and no_position (sell-side only — account holds nothing to sell on this venue). null when the venue was allocated a share. The enum is open-ended; new reasons may be added over time, so treat unknown values as informational. |
considered[].feeBpsAtTop | number | Effective venue fee at the top of book in basis points. May be fractional (e.g. 24.6975). |
reasoning | string | Natural-language explanation of the routing decision. |
Status Codes & Errors
HTTP status is binary:201 when at least one venue produced a fill, 502 when no venue filled. Partial vs. full success is a body-level distinction — read summary.venuesFailed.
summary.venuesFailed === 0— full success. Every dispatched venue filled.summary.venuesFailed > 0with status201— partial success. Some venues filled, others failed. Inspect per-fillstatusandfills[].errorto see which.
errorCode alongside the human-readable error. On 502 all_venues_failed, the response is the full Place Order body (with fills[] and _routing) plus errorCode — diagnose per-venue failures from fills[].error and _routing.considered[].
| Status | errorCode | Meaning |
|---|---|---|
201 | (absent) | At least one venue produced a fill. Full success when summary.venuesFailed === 0; partial success when > 0. |
400 | parse_error | Missing or invalid request body field. |
400 | insufficient_balance | Aggregate balance across enabled venues is below the requested notional (market buy only). |
404 | predexon_not_routable | No routed venue carries the supplied predexonId. |
502 | no_allocations | No venue had sufficient liquidity to allocate any portion of the order. |
502 | all_venues_failed | Every dispatched venue failed. Response includes the full Place Order body for diagnosis. |
503 | registry_unavailable | Routing registry is temporarily unavailable. Retry with exponential back-off. |
Examples
Full success — market buy by notional
Both dispatched venues filled.summary.venuesFailed is 0.
Request:
201):
x-request-id response header carries a request correlation identifier — propagate it when reporting issues so support can correlate your call with router-side logs.
Market sell by size
Partial success — still a 201
At least one venue filled, so the response is still201. summary.venuesFailed is 1, and the failed venue returns an error string for diagnostics. errorCode is absent at the top level because at least one venue filled.
All venues failed (502)
A502 with the full Place Order body. Use fills[].error to diagnose per-venue failures.
Authorizations
Trading key provided by Predexon. The data key used by the Sports Discovery API on api.predexon.com is a separate credential.
Path Parameters
Account ID. Must belong to the calling API key.
Body
Canonical predexon_id for the outcome. The router expands to every routed venue listing for that canonical outcome.
buy, sell USD/stablecoin notional to spend. Required when side is buy. Must not be set when side is sell. Must be a positive decimal string.
Number of shares to sell. Required when side is sell. Must not be set when side is buy. Must be a positive decimal string.
Response
At least one venue produced a fill. Full success when summary.venuesFailed === 0; partial success when > 0 — some venues filled, others failed, inspect per-fill status and fills[].error to see which.
Unique identifier for this routed order (prefix rord-).
Echoes the request predexonId.
buy, sell market Echo of the request amount. Present (as a stringified number) on buy orders; null on sell orders.
Echo of the request size. Present (as a stringified number) on sell orders; null on buy orders.
One entry per venue that was dispatched. A single order can produce multiple fills. size, price, and amount are normalised to 6-decimal strings across every venue.
Transparency block describing how the router made its allocation decision.
Present only on a 502 response when every dispatched venue failed. Set to "all_venues_failed". Absent on a 201 success.
all_venues_failed 