Skip to main content

Limit Order Structure

Limit orders are the standard 0x Order, which encodes a possible trade between a maker and taker at a fixed price. These orders are typically distributed /orderbook, and can be filled through the functions on the Exchange Proxy.

The LimitOrder struct has the following fields:

makerTokenaddressThe ERC20 token the maker is selling and the maker is selling to the taker. [required]
takerTokenaddressThe ERC20 token the taker is selling and the taker is selling to the maker. [required]
makerAmountuint128The amount of makerToken being sold by the maker. [required]
takerAmountuint128The amount of takerToken being sold by the taker. [required]
takerTokenFeeAmountuint128Amount of takerToken paid by the taker to the feeRecipient. [optional; default 0]
makeraddressThe address of the maker, and signer, of this order. [required]
takeraddressAllowed taker address. Set to zero to allow any taker. [optional; default 0]
senderaddressAllowed address to call fillLimitOrder() (msg.sender). This is the same as taker, expect when using meta-transactions. Set to zero to allow any caller. [optional; default 0]
feeRecipientaddressRecipient of maker token or taker token fees (if non-zero). [optional; default 0]
poolbytes32The staking pool to attribute the 0x protocol fee from this order. Set to zero to attribute to the default pool, not owned by anyone. [optional; default 0]
expiryuint64The Unix timestamp in seconds when this order expires. [required]
saltuint256Arbitrary number to enforce uniqueness of the order hash. [required]