Skip to main content

0x Cheat Sheet

0x Protocol Version

We are currently on v4 of the 0x protocol

Swap API Endpoints

Tx Relay API Endpoints

Orderbook API Endpoints

Exchange Proxy Addresses

This is the primary contract for all interactions with the protocol. It is also the allowance-target/spender/operator for any ERC20, ERC721, and ERC1155 assets being traded. For most networks the address is identical, but be aware that a small number (marked with a *) are slightly different. The ABI can be found in the protocol repo's IZeroEx.json file. All 0x contract addresses can be found in the protocol repo's addresses.json file.

  • Ethereum (Mainnet): 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Ethereum (Goerli): 0xf91bb752490473b8342a3e964e855b9f9a2a668e*
  • Polygon: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Polygon (Mumbai): 0xf471d32cb40837bf24529fcf17418fc1a4807626*
  • Binance Smart Chain: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Optimism: 0xdef1abe32c034e558cdd535791643c58a13acc10*
  • Fantom: 0xdef189deaef76e379df891899eb5a00a94cbc250*
  • Celo: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Avalanche: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Arbitrum: 0xdef1c0ded9bec7f1a1670819833240f027b25eff

Ancillary Contract Addresses

These contracts are used within the 0x ecosystem but are not intended for direct interaction with users except in rare circumstances. They are less likely to remain fixed (compared to the Exchange Proxy Address). The latest addresses can be found in the protocol repo's addresses.json file. A subset of commonly used addresses can be found in contract-addresses.md.

0x Order Types

An order is a message passed into the 0x Protocol to facilitate a trade (see How does 0x work?). The order types that we support include:

Order TypeSummaryOrder StructureSupported Token Trade Types
Limit OrdersThese are the standard 0x Order, which encodes a possible trade between a maker and taker at a fixed price.Limit Order StructureERC20 <-> ERC20 trade
RFQ OrdersThese are a stripped down version of standard limit orders, supporting fewer fields and a leaner settlement process. These orders are fielded just-in-time, directly from market makers, during the construction of a swap quote on 0x API, and can be filled through the fillRfqOrder() function on the Exchange Proxy.RFQ Order StructureERC20 <-> ERC20 trade