Skip to content

ETH_snoop provides just the essential scaffolding—listening to on-chain logs, organizing smart contract events, and storing them in a structured database—so that you can quickly integrate and expand it to match the specific needs of your protocol.

License

Notifications You must be signed in to change notification settings

khdream/ETH_snoop

Repository files navigation

ETH Snoop

ETH logs and event indexer

ETH Snoop is a minimal, rust-based event and logs indexer for Ethereum-compatible blockchains, intended as a boilerplate that you can fork and adapt to your own contracts. It provides just the essential scaffolding—listening to on-chain logs, organizing smart contract events, and storing them in a structured database—so that you can quickly integrate and expand it to match the specific needs of your protocol.

Requirements

How to use

@TODO

Build

You can try the indexer locally or using Docker.

  1. Clone the repository
git clone https://github.com/khdream/ETH_snoop && cd ETH_snoop
  1. Build the program
cargo build --release

Docker

Build the docker image

docker build . -t snoop

Copy the .env.example and rename it to .env

Start the indexer

docker compose up

Program flags

Flag Default Purpose
--debug false Enables verbose (debug-level) logging output.
--chain mainnet Specifies the target chain/network to index (e.g. 'mainnet', 'testnet').
--rpc empty URL of the RPC endpoint to fetch chain data and logs.
--database empty PostgreSQL connection URL (e.g. 'postgres://user:password@host/dbname').
--batch-size 50 Number of blocks to fetch in each batch of logs.

About

ETH_snoop provides just the essential scaffolding—listening to on-chain logs, organizing smart contract events, and storing them in a structured database—so that you can quickly integrate and expand it to match the specific needs of your protocol.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published