Use this page as a reference for the key objects returned by the /order endpoint and where each one appears in the request/response flow.
This page focuses on imperative trades.
The previous /quote, /swap, and /swap-instructions model has been deprecated. All
imperative trading flows now use the /order endpoint.
High-Level Model
You request an Order, which returns a Quote and, if userPublicKey is
provided, a Transaction to sign and submit. The response may include a
routePlan (one or more legs) and an executionMode (sync or async).
Example (Trade SOL → USDC)
Input mint: SOL
Output mint: USDC
Flow:
- Call
GET /order with inputMint,
outputMint, and amount.
- Inspect
priceImpactPct, routePlan, and executionMode.
- If
transaction is returned, sign it and send it to Solana.
- For async execution, poll
GET /order-status.
Entity Reference
Order Request (Query Parameters)
Core parameters:
| Field | Type | Notes |
|---|
inputMint | string | Base58 input mint |
outputMint | string | Base58 output mint |
amount | integer | Input amount (scaled integer) |
userPublicKey | string | Wallet; includes transaction in response |
slippageBps | integer | "auto" | Max allowed slippage |
predictionMarketSlippageBps | integer | "auto" | Slippage for prediction orders |
Routing controls:
| Field | Type | Notes |
|---|
dexes | string | Comma-separated include list |
excludeDexes | string | Comma-separated exclude list |
onlyDirectRoutes | boolean | Force single-leg routes |
maxRouteLength | integer | Max legs (ignored if onlyDirectRoutes) |
onlyJitRoutes | boolean | Force JIT routes |
forJitoBundle | boolean | Routes compatible with Jito bundles |
Execution controls:
| Field | Type | Notes |
|---|
allowSyncExec | boolean | Allow sync execution |
allowAsyncExec | boolean | Allow async execution |
restrictRevertMint | boolean | Input must be revert mint for async |
Fees and accounts:
| Field | Type | Notes |
|---|
platformFeeMode | enum | Fee collected from input/output |
platformFeeBps | integer | Platform fee in bps |
platformFeeScale | integer | Prediction market fee scale (3 decimals) |
feeAccount | string | Token account for platform fees |
referralAccount | string | Referral account for fee account creation |
positiveSlippageFeeAccount | string | Account for positive slippage |
positiveSlippageLimitPct | integer | Cap on positive slippage fee |
sponsor | string | Sponsor wallet (gasless) |
destinationTokenAccount | string | Output token account |
destinationWallet | string | Output wallet (ATA if needed) |
revertWallet | string | Revert wallet for async orders |
Transaction configuration:
| Field | Type | Notes |
|---|
wrapAndUnwrapSol | boolean | Use native SOL if true |
prioritizationFeeLamports | integer | enum | Priority fee or level |
computeUnitPriceMicroLamports | integer | CU price (mutually exclusive) |
dynamicComputeUnitLimit | boolean | Simulate to determine CU limit |
includeJitoSandwichMitigationAccount | boolean | string | Jito mitigation |
Prediction market parameters:
| Field | Type | Notes |
|---|
predictionMarketInitPayer | string | Pays market init if uninitialized |
outcomeAccountRentRecipient | string | Rent recipient on close |
Order Response (OrderResponse)
| Field | Type | Notes |
|---|
inputMint | string | Base58 input mint |
inAmount | string | Max input amount (scaled integer) |
outputMint | string | Base58 output mint |
outAmount | string | Expected output amount (scaled integer) |
otherAmountThreshold | string | Min output after fees |
minOutAmount | string | Same as otherAmountThreshold |
slippageBps | integer | Max slippage in bps |
predictionMarketSlippageBps | integer | Prediction order slippage |
priceImpactPct | string | Estimated price impact |
contextSlot | integer | Slot at evaluation time |
executionMode | enum | sync or async |
routePlan | array | Route legs (sync and known routes) |
platformFee | object | null | Platform fee if applied |
initPredictionMarketCost | integer | Lamports to init market |
predictionMarketInitPayerMustSign | boolean | Init payer signature required |
revertMint | string | Revert mint for async orders |
transaction | string | Base64 tx to sign/send |
lastValidBlockHeight | integer | Last valid block height |
computeUnitLimit | integer | Compute unit limit |
prioritizationFeeLamports | integer | Priority fee in lamports |
prioritizationType | object | Priority fee type |
Route Leg (RoutePlanLeg)
Each leg is either a DynamicRoutePlanLeg or SingleMarketRoutePlanLeg.
Common fields:
| Field | Type | Notes |
|---|
venue | string | Venue for the leg |
marketKey | string | Market key for venue |
inputMint | string | Input mint |
outputMint | string | Output mint |
inAmount | string | Max input amount |
outAmount | string | Expected output amount |
inputMintDecimals | integer | Input decimals |
outputMintDecimals | integer | Output decimals |
data | string | Present only on dynamic legs |