How it works
EtaBridge has adapters deployed on each supported chain. These adapters contain liquidity. Bridging happens in the following scenario:
User signs an approval transaction for X amount of tokens to bridge.
User calls the
bridgeTokensmethod on the source chain. The smart contract takes X amount of tokens and initiates a LayerZero message.After validation by DVNs, the LayerZero executor delivers the message to the destination chain adapter, which allocates (X - fee) amount of tokens and sends them to the user.
In order to execute a transaction on the destination chain, the adapter on that chain must have enough liquidity on its balance. If at that moment the adapter doesn't have enough liquidity, the transaction issued by the LayerZero executor will fail. If a message fails due to lack of liquidity, the user needs to wait until liquidity is rebalanced and execute the message manually (or reach out to the team for help). On https://app.etabridge.com UI we display a warning and prevent the user from bridging if the destination adapter does not have enough liquidity. However, if you are going to call the smart contract directly or build your own UI, you should check if there is a sufficient amount of liquidity on the destination chain before initiating a transaction.
If message delivery fails for any reason on the destination chain, it can be executed later manually.
Last updated