Donatuz L3 Bridging
Overview
This document explains the process of bridging ETH from Ethereum mainnet (L1) to Base
(L2), and then from Base to Donatuz (L3). The process involves two main steps:
1. Bridging ETH from Ethereum mainnet to Base
2. Bridging ETH from Base to Donatuz L3.
1. Bridging ETH from Ethereum Mainnet (L1) to Base (L2)
Contract Used
- Contract Address: 0x3154Cf16ccdb4C6d922629664174b904d80F2C35
- Contract Name: L1StandardBridge
RPC URL
- https://eth-mainnet.g.alchemy.com/v2/JwkRF_vQJWBYFj5wXkkhUnYi1A5TwFhs
Chain ID
- 1
Process
1. The script connects to the Ethereum mainnet using a JSON-RPC provider.
2. The L1StandardBridge contract is instantiated using its address and ABI.
3. The `bridgeETHToBase` function is called with the amount of ETH to bridge.
4. The function estimates the gas required for the transaction and fetches current gas prices.
5. It then calls the `depositETH` function on the Base Bridge contract with the following
parameters:
- `_minGasLimit`: Set to 200,000
- `_extraData`: Set to "0x" (empty bytes)
- `value`: The amount of ETH to bridge in wei
6. The transaction is sent with adjusted gas parameters, including a 20% buffer on the
estimated gas limit.
7. The script waits for the transaction confirmation and logs the details.
Notable Points
- The script uses dynamic gas pricing to ensure the transaction is competitive in the current
market.
- The process takes about 2-3 minutes for the funds to arrive on Base.
2. Bridging ETH from Base (L2) to Donatuz (L3)
Contract Used
- Contract Address: 0xb765Df9d2925a82678F4B7bc60eF5294c1604514
- Contract Name: Optimism Portal Proxy
RPC URL
- https://base-mainnet.g.alchemy.com/v2/JwkRF_vQJWBYFj5wXkkhUnYi1A5TwFhs
Chain Id
- 8453
Process
1. The script connects to the Base network using its RPC URL.
2. The Optimism Portal Proxy contract is instantiated using its address and ABI.
3. The `bridgeETHToL3` function is called with the amount of ETH to bridge.
4. The function checks the current balance and estimates the gas required for the
transaction.
5. It calculates the maximum amount that can be bridged, considering gas costs.
6. The `depositTransaction` function is called on the Optimism Portal Proxy contract with the
following parameters:
- `_to`: Set to the wallet's address
- `_value`: The amount of ETH to bridge
- `_gasLimit`: Set to 100,000
- `_isCreation`: Set to false
- `_data`: Set to "0x" (empty bytes)
7. The transaction is sent with adjusted gas parameters, including a 50% buffer on the
estimated gas limit.
8. The script waits for the transaction confirmation and logs the details.
Notable Points
- The script dynamically calculates the maximum amount that can be bridged based on the
current balance and gas costs.
- It uses a 50% buffer on the gas estimate to ensure the transaction has enough gas to
complete.
- The process may take few seconds time for the funds to appear on Donatuz L3.
Donatuz L3
Network Details
- Chain Name: Donatuz Mainnet
- Technology Stack: OP Stack (derived from Optimism) / Base / EigenDA
- Chain ID: 42026
Key Features
- Layer 3 Solution: Built on top of Base (L2), which itself is built on Ethereum (L1)
- OP Stack: Utilizes the Optimism technology stack for scalability and efficiency
- EigenDA Integration: Incorporates EigenDA for enhanced data availability and security
Bridging Implications
- Fast Finality: The use of OP Stack technology allows for quick transaction finality,
explaining the few seconds needed for funds to appear after bridging
- Compatibility: Being built on the OP Stack ensures compatibility with Base and other OP
Stack-based networks, facilitating seamless bridging
- Enhanced Scalability: As an L3 solution, Donatuz offers additional scalability benefits on
top of the L2 advantages provided by Base
Conclusion
This bridging process enables the transfer of ETH across three distinct layers of blockchain
networks: from Ethereum mainnet (L1) to Base (L2), and finally to Donatuz (L3). The scripts
provide an automated way to initiate these transfers and verify balances on each network.
The multi-layer approach (L1 > L2 > L3) offers compounded benefits in terms of scalability
and efficiency. While the L1 to L2 bridge (Ethereum to Base) may take a few minutes, the L2
to L3 bridge (Base to Donatuz) is notably faster, typically completing in just a few seconds.
Users should be aware of the different chain IDs and RPC URLs for each network involved
in the bridging process to ensure proper configuration and interaction with the correct
networks at each step.