Transaction Hash:
Block:
16678221 at Feb-21-2023 04:59:23 PM +UTC
Transaction Fee:
0.001737244819636248 ETH
$6.56
Gas Used:
43,126 Gas / 40.283003748 Gwei
Account State Difference:
Address | Before | After | State Difference | ||
---|---|---|---|---|---|
0x690B9A9E...Db4FaC990
Miner
| (builder0x69) | 2.050910463464055604 Eth | 2.050953589464055604 Eth | 0.000043126 | |
0xE179272E...689CD0252 |
0.043099232832640451 Eth
Nonce: 35
|
0.041361988013004203 Eth
Nonce: 36
| 0.001737244819636248 |
Execution Trace
ETH 0.000103718066079562
SwappableBridge.swapAndBridge( amountIn=100000000000000, amountOutMin=198078078244688802, dstChainId=154, to=0xE179272Ef3eaDe0B2C914c4Edd26B57689CD0252, refundAddress=0xE179272Ef3eaDe0B2C914c4Edd26B57689CD0252, zroPaymentAddress=0x0000000000000000000000000000000000000000, adapterParams=0x )
-
UniswapV2Router02.STATICCALL( )
ETH 0.0001
UniswapV2Router02.swapExactETHForTokens( amountOutMin=198078078244688802, path=[0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2, 0xdD69DB25F6D620A7baD3023c5d32761D353D3De9], to=0x0A9f824C05A74F577A536A8A0c673183a872Dff4, deadline=1676998763 )
-
UniswapV2Pair.STATICCALL( )
-
swapAndBridge[SwappableBridge (ln:18)]
WETH[SwappableBridge (ln:22)]
swapExactETHForTokens[SwappableBridge (ln:24)]
sendFrom[SwappableBridge (ln:25)]
File 1 of 3: SwappableBridge
File 2 of 3: UniswapV2Router02
File 3 of 3: UniswapV2Pair
12345678910111213141516// SPDX-License-Identifier: MITpragma solidity ^0.8.0;import "@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol";import "@layerzerolabs/solidity-examples/contracts/token/oft/IOFTCore.sol";import "./INativeOFT.sol";contract SwappableBridge {IOFTCore public immutable oft;INativeOFT public immutable nativeOft;IUniswapV2Router02 public immutable uniswapRouter;constructor(address _oft, address _nativeOft, address _uniswapRouter) {require(_oft != address(0), "SwappableBridge: invalid OFT address");require(_nativeOft != address(0), "SwappableBridge: invalid Native OFT address");require(_uniswapRouter != address(0), "SwappableBridge: invalid Uniswap Router address");oft = IOFTCore(_oft);nativeOft = INativeOFT(_nativeOft);uniswapRouter = IUniswapV2Router02(_uniswapRouter);
File 2 of 3: UniswapV2Router02
12345678910111213141516pragma solidity =0.6.6;interface IUniswapV2Factory {event PairCreated(address indexed token0, address indexed token1, address pair, uint);function feeTo() external view returns (address);function feeToSetter() external view returns (address);function getPair(address tokenA, address tokenB) external view returns (address pair);function allPairs(uint) external view returns (address pair);function allPairsLength() external view returns (uint);function createPair(address tokenA, address tokenB) external returns (address pair);function setFeeTo(address) external;function setFeeToSetter(address) external;
File 3 of 3: UniswapV2Pair
12345678910111213141516// File: contracts/interfaces/IUniswapV2Pair.solpragma solidity >=0.5.0;interface IUniswapV2Pair {event Approval(address indexed owner, address indexed spender, uint value);event Transfer(address indexed from, address indexed to, uint value);function name() external pure returns (string memory);function symbol() external pure returns (string memory);function decimals() external pure returns (uint8);function totalSupply() external view returns (uint);function balanceOf(address owner) external view returns (uint);function allowance(address owner, address spender) external view returns (uint);function approve(address spender, uint value) external returns (bool);