Place Order
Trading
Place Order
Submit a new trading order to the CLOB (Central Limit Order Book)
POST
Place Order
Overview
The Place Order endpoint allows authenticated users to submit trading orders for prediction market outcomes. Orders can be market orders (immediate execution) or limit orders (executed at specific price levels).Authentication
This endpoint requires CLOB authentication with HMAC signature verification. Required Headers:KUEST_ADDRESS- User’s wallet addressKUEST_API_KEY- API key from trading auth credentialsKUEST_PASSPHRASE- Passphrase from trading auth credentialsKUEST_TIMESTAMP- Current Unix timestamp (seconds)KUEST_SIGNATURE- HMAC signature of the requestContent-Type: application/jsonAccept: application/json
Request Body
The order object containing all order parameters
Random salt value to ensure order uniqueness (bigint as string)
Maker address (proxy wallet address)
Signer address (user’s wallet address)
Taker address (typically zero address for open orders)
Market condition ID
Outcome token ID (bigint as string)
Amount provided by maker in micro units (bigint as string)
Amount provided by taker in micro units (bigint as string)
Order expiration timestamp in seconds (0 for no expiration)
Order nonce (typically 0)
Fee rate in basis points (e.g., “200” for 2%)
Order side:
BUY or SELLSignature type (typically 0 for EIP-712)
EIP-712 signature of the order
Type of order execution:
GTC- Good Till Cancelled (limit order, default)GTD- Good Till Date (limit order with expiration)FOK- Fill Or Kill (must be fully filled immediately)FAK- Fill And Kill (fill partially, cancel remainder)
Owner API key (from CLOB auth credentials)
Response
Unique identifier for the created order
Indicates if the order was successfully placed
Order Amount Calculation
Buy Orders
makerAmount= price × shares (in micro units)takerAmount= shares (in micro units)
Sell Orders
makerAmount= shares (in micro units)takerAmount= price × shares (in micro units)
Order Validation
Before placing an order, the system validates:- User Authentication - Valid user session and trading auth
- Proxy Wallet - User has deployed proxy wallet
- Maker Address - Matches user’s proxy wallet address
- Balance Check - For buy orders: sufficient collateral balance
- Shares Check - For sell orders: sufficient outcome token balance
- Signature - Valid EIP-712 signature
- Market Status - Market is active and tradable
Error Handling
Common error responses:Error message describing what went wrong
Common Errors
condition_paused- Trading is paused for this marketsystem_paused- Trading is temporarily paused system-widenot enough balance / allowance- Insufficient available balanceorder expired- Order expiration timestamp is in the pastinvalid order signature- Signature verification failedorder is invalid. duplicated.- Identical order already existsorder couldn't be fully filled, fok orders are fully filled/killed- FOK order cannot be fillednot enough unlocked balance- Insufficient unlocked collateralpostonly would cross the best bid/ask- Post-only order would execute immediately
Example Request
cURL