This introductory example illustrates how to use Steel to directly query the balanceOf
function of any ERC20 token contract, providing a verifiable proof of a user's token balance.
Explore a more advanced interaction between Steel and a custom Ethereum smart contract. This counter contract utilizes off-chain Steel proofs to:
- Increment a counter based on user-submitted proofs.
- Verify ERC20 token ownership (minimum 1 token required) before incrementing.
- Leverage RISC Zero as a coprocessor for efficient proof generation and verification.
This example shows how the Steel library can be used to call multiple view functions of a contract. This example generates a proof of a Compound cToken's APR (Annual Percentage Rate), showcasing the potential for on-chain verification of complex financial metrics.