https://github.com/libevm/reth-custom-api-example
Example to extend Reth to include custom APIs
https://github.com/libevm/reth-custom-api-example
Last synced: 28 days ago
JSON representation
Example to extend Reth to include custom APIs
- Host: GitHub
- URL: https://github.com/libevm/reth-custom-api-example
- Owner: libevm
- License: mit
- Created: 2023-09-01T04:05:31.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-14T20:01:39.000Z (over 1 year ago)
- Last Synced: 2025-05-07T06:15:02.603Z (28 days ago)
- Language: Rust
- Size: 6.84 KB
- Stars: 28
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-reth - reth-custom-api-example - custom-api)) (Tutorials ##)
README
# reth-custom-api-example
Example to extend Reth to include custom APIs.
This example adds a new custom api `eth_getGasUsedByBlock` to the node.
# Build
```
cargo run -- node --extend-eth-namespace --dev --http --http.api=eth,debug,reth --dev.block-time 12s --datadir /tmp/reth
```or
```
cargo build --release
./target/release/reth-custom-api-example node --extend-eth-namespace --dev --http --http.api=eth,debug,reth --dev.block-time 12s --datadir /tmp/reth
```# Test
```
cargo test
```