Userflow
Last updated
Last updated
User deposits funds into the exchange
User places market, limit, or stop-loss orders using the front-end
The front-end verifies user balances are sufficient for the trade
The order details are passed to the off-chain
The matching engine runs a second verifcation of user balances
If a limit order is not matched it is placed into the orderbook as a maker order
If the order is matched, it will prompt the taker to approve the transaction using their wallet provider
Once approved, the order is sent to the exchange contract where it checks a verification signature for order detail authenticity provided by a verfier.
The exchange contract places the pending trade details into "Pending Orders"
The exchange contract reviews the order details and verifies for a third time that the user balances are sufficient for the trade and executes the trade between the users
Margin trades are processed in the same manner as above, but takes into consideration different factors such as "Total Portfolio Value", "Initial Margin Requirements", and "Maintenance Margin Requirements" as outlined further in the section.