Skip to main content
POST
Submits a signed order. The signature is verified against the custody contract’s domain, the order is checked for liveness on chain, the trader’s balance is reserved off-chain, and the order is matched against the book. If it fills, a settlement is staged in the same call and its calldata comes back in the response, ready for the venue operator to sign. If it rests, settlement is null. Send the same expiry, nonce and salt that Prepare Order returned. All three are part of the signed struct, so any difference changes the hash and the signature is rejected.

Idempotency

Accepts an optional Idempotency-Key header. Sending one is strongly recommended: a retry after a network timeout would otherwise be refused as a DUPLICATE_ORDER rather than returning the original result.

Body Parameters

string
required
Target book. Must be ACTIVE and reachable from your instance.
string
required
The trader’s wallet. Must be the address that produced the signature.
string
required
BUY or SELL.
string
required
Limit price in order book units. Must be a multiple of the book’s tickSize.
string
required
Base quantity in order book units. Must sit between the book’s minOrderSize and maxOrderSize.
integer
required
Unix seconds from the prepared order.
string
required
Nonce from the prepared order.
string
required
32-byte hex salt from the prepared order.
string
required
The trader’s EIP-712 signature over the prepared order. An EOA signature or an EIP-1271 smart contract wallet signature is accepted.
string
default:"LIMIT"
Only LIMIT is accepted. Anything else returns MARKET_ORDER_NOT_SUPPORTED, because a market order carries no price for a signature to bind.
string
default:"GTC"
GTC rests until filled, cancelled or expired. IOC fills what it can and cancels the rest. FOK must fill entirely. Use a limit price with IOC to sweep the book.
boolean
default:"false"
Reject the order rather than let it take. Checked against the whole eligible peer set.
string
default:"NONE"
NONE, CANCEL_TAKER, CANCEL_MAKER or CANCEL_BOTH. An unrecognised value falls back to NONE.

What runs before the order rests

The checks run in a fixed order, so the first refusal names the earliest condition that failed.
1

Field shape

The order struct is rebuilt from your fields. Quantity and price must convert to whole token units, and expiry, nonce and salt must be in range.
2

Signature

The order hash is derived from that struct, and the signature must recover to userAddress or validate through the wallet’s own EIP-1271 check.
3

Book rules

Size against minOrderSize and maxOrderSize, price against tickSize, the reference price band where one is configured, any account restriction on which books may be traded, and the post-only check against the eligible peer set.
4

Liveness

The signature must not already be cancelled, nonce-invalidated or filled on chain, and must not already be resting on the book. See Signed order liveness.
5

Balance

The tradable balance, net of the trader’s existing reservations, must cover the order.
6

Delivery

On a sell, the token’s own compliance layer must permit the delivery. See Delivery checks.
7

Stale depth

Resting orders the incoming order could reach are re-read on chain, and any the chain has retired are cancelled before a trade can be booked against them.

Response Fields

Returns 201.
object
A settlement whose revert is permanent is diagnosed at staging and unwound immediately: the trade is reversed, both reservations are released, and settlement.error.unwound is true. The order in the response is re-read after the unwind, so it reflects the reversal rather than the fill that was rolled back.

Error Codes