Experimental project 🤓
Simple logger for the swap events between crypto currencies using the open source uniswap protocol on the Ethereum Blockchain.
Currently it only supports the DAI/USDC pool.
I will be experimenting and adding more pool to learn more about Blockchain development.
- Local Rust setup
- Infura endpoint
- Create a
web3
object using your Infura endpoint - Create a contract object using the provided contract address
- In this case it's the DAI/USDC contract
- Create a
SwapLogger
object, and inject the web3 and the contract objects into it. - call the async function
display_logs
, which subscribes to the latest updates on the Ethereum block chain.
- Run
cargo run
to run the app
- Run
cargo test
to run the test cases