Cross-Chain Trading

DODO's Cross-Chain Trading feature enables users to exchange assets on one chain for different assets on another using a cross-chain token bridge. This feature supports the exchange of dozens of tokens across a variety of different chains, and allows users to transfer assets safely and quickly by aggregating multiple platforms and protocols.
The DODO Cross-Chain Trading API supports the following functionalities:
  • Cross Chain Supported Token List: This interface returns supported chains, tokens, and channel product data for display to users.
  • Cross Chain Routes: This interface returns swap routes and price quotes based on the user's selected transaction pair and amount to sell.
  • Cross Chain Transaction Encoding: After the user selects one of the routes obtained via the Cross Chain Routes interface, they call the interface to obtain the sent transaction data. The 'encodeParams' parameter of this interface is obtained from the selected route.
  • Cross Chain Order Creation: After calling the 'web3.eth.sendTransaction' method to send the transaction to the chain, the user calls this interface to save the transaction data.
  • Cross Chain Order List: This interface is called to obtain the user's latest order record data. If the interface did not return the latest data, the reason may be that the interface data has a cache, which lasts for about 15 seconds.
  • Cross Chain Order Details: This interface returns detailed data for a given order, with a cache time of approximately 15 seconds.
  • Cross Chain New Order Status: This interface is used to get information on status changes related to users' cross chain orders, with a cache time of approximately 15 seconds.