Burn stBTC and Redeem BTC Process

During Lorenzo Phase One when there were no YATs, a user only need to burn stBTCs to redeem BTCs from Lorenzo. However, after the issuance of YATs during Phase Two, when a user want to redeem their BTC, the user not only needs to burn the corresponding stBTCs but also needs to burn an equivalent amount of SPTs. Only then will Lorenzo refund BTCs to the user.

SPT Token

After the maturity of YATs, they become non-tradable and transform into an equivalent amount of non-tradable SPTs when used by users to claim earnings. These SPTs enter a unified queue. Each SPT corresponds to a BTC staked to a specific project and records which Staking Agent is managing the corresponding BTC. When redeeming BTCs, the user needs to burn an equivalent amount of SPTs, and the issuing Staking Agent is responsible for returning the BTCs. Specifically, as shown in the figure, when a user claims the YAT earnings and convert YATs to SPTs, the user has the right to prioritize the burning of an amount of stBTCs that does not exceed the amount of the generated SPTs, and reclaims an equivalent amount of BTCs. Any remaining unused SPTs are placed into a queue for other users who need to withdraw stBTCs, allowing them to burn SPTs and receive BTCs in return.

Redeem stBTC When Claiming YAT

As shown in the above figure, in order to redeem stBTCs while claiming YATs, the user should go through the following steps:

  1. The user invokes the interface in the YAT_Control_Module to claim rewards and burn stBTCs.

  2. The YAT_Control_Module assists the user in claiming rewards from the corresponding RewardToken contract and simultaneously requesting the withdrawal of stBTCs.

  3. After successful claiming of rewards, YATs are converted to SPTs. The YAT_Control_Module burns the user’s stBTCs and emits an event for external systems to listen to.

  4. The Lorenzo_monitor program is responsible for the subsequent logic of providing BTCs to the user.

  5. The corresponding Staking Agent returns BTCs to the user.

Only Claims YAT and Generates SPT

As shown in the above figure, in order to only claims YATs and generate SPTs the following process is taken:

  1. The user invokes the YAT_Control_Module to claim rewards.

  2. The YAT_Control_Module assists the user in claiming rewards from the corresponding RewardToken contract.

  3. After successfully claiming the rewards, the YAT is converted into an SPT and added to a queue.

Only Use stBTC to Claim BTC

As shown in the above figure, in order to only use stBTCs to claim BTCs:

  1. The user calls the YAT_Control_Module to query available SPTs in the queue.

  2. The YAT_Control_Module assists the user in burning SPTs equivalent to the amount of stBTCs from the queue.

  3. After successful burning, the YAT_Control_Module burns the user’s stBTCs and emits an event for external systems to listen to.

  4. The Lorenzo_monitor program handles the subsequent logic of providing BTCs to the user.

  5. The corresponding Staking Agent returns BTCs to the user.

Last updated