Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
tl;dr;
ReservedDepositis a smart contract that enables tax-efficient Bitcoin custody within the tBTC v2 ecosystem. It allows users to reserve specific Bitcoin UTXOs (Unspent Transaction Outputs) for a predetermined period while still being able to mint and use tBTC tokens.Goal
This feature positions tBTC as the most sophisticated and compliant Bitcoin bridge in DeFi by:
Fee structure
Base Fee (0.1% annual): Compensates for locking specific UTXOs
Minimum Fee (0.01 BTC annual): Ensures meaningful revenue even for short reservations
Fee Examples
The fee structure is designed to:
Please consider the fees as an example, I expect someone smarter than me to come up with a better idea.
I also made the max hold for 4 years. There might need to be a min as well.
Here are some mermaid graphs on how the integration would work:
sequenceDiagram participant User participant Bitcoin as Bitcoin Network participant Bridge as Bridge Contract participant RD as ReservedDeposit Library participant Bank as Bank Contract participant Wallet as tBTC Wallet Note over User,Wallet: PHASE 1: BITCOIN DEPOSIT User->>Bitcoin: Send 1 BTC to P2(W)SH address Bitcoin-->>User: Transaction confirmed Note over User,Wallet: PHASE 2: REVEAL & RESERVE User->>Bridge: revealReservedDeposit(fundingTx, reveal, 365 days, btcAddress) Bridge->>RD: Process reservation RD->>RD: Calculate storage fee (0.01 BTC) RD->>RD: Create reservation record RD->>Bank: increaseBalance(user, 0.99 tBTC) Bank-->>User: Receive 0.99 tBTC Note over User,Wallet: PHASE 3: HOLDING PERIOD (1 Year) User->>User: Hold tBTC, use in DeFi Note over User,Wallet: PHASE 4A: REDEMPTION (Before Expiry) User->>Bridge: redeemReservedDeposit(utxoHash) Bridge->>RD: Process redemption RD->>Bank: decreaseBalance(0.99 tBTC) RD->>RD: Create priority redemption Wallet->>Bitcoin: Send exact UTXO back Bitcoin-->>User: Receive same 1 BTC Note over User,Wallet: PHASE 4B: LIQUIDATION (After Expiry) User->>Bridge: liquidateExpiredReservation(utxoHash) Bridge->>RD: Process liquidation RD->>RD: Move UTXO to general pool RD->>Bank: increaseBalance(liquidator, 0.001 tBTC bonus)