Making withdraw request

In MAAT, to withdraw staked funds, you need to first create a withdraw request. This is done by calling the requestWithdraw function on the Gateway contract.

function requestWithdraw(
    address token,
    uint shares,
    uint32 dstEid,
    address receiver
) external;

Parameters:

  • token: The address of the token you wish to withdraw.

  • shares: The amount of shares you wish to withdraw.

  • dstEid: The destination LayerZero Endpoint ID ID where the withdrawal will be managed.

  • receiver: The address that will receive the withdrawn funds.

Process

  • Once the requestWithdraw function is called, your shares will be locked until the request is executed.

  • Ensure that you are using supported chains and tokens when making a withdraw request.

Last updated