Provides Rosetta API compatibility for Optimism Bedrock, a low-cost and lightning-fast Ethereum L2 blockchain.
op-rosetta
is an executable client extending the rosetta-geth-sdk which itself extends rosetta-sdk-go.
To learn more about the Rosetta API, you can find more online at rosetta-api.org.
- Run
make build
to build Rosetta Server - Configure the following environment variables
MODE: ONLINE or OFFLINE
PORT: Rosetta Server port
BLOCKCHAIN: Blockchain (e.g. Optimism)
NETWORK: Network (e.g. Goerli)
FILTER: true (Rosetta Validation validates tokens according to the filter) or false (Rosetta Validation validates all tokens)
GENESIS_BLOCK_HASH: Genesis block hash
GETH: Native node URL
CHAIN_CONFIG: '{ "chainId": <Chain ID>, "terminalTotalDifficultyPassed": true }'
- Run
make run
to run Rosetta Server
βββ assets
β βββ rosetta.png
βββ cmd
β βββ main.go -> The `op-rosetta` executable entrypoint
βββ pkg
βββ client/ -> Rosetta API client
βββ common/ -> Standalone common functionality
βββ config/ -> Configuration options
βββ handlers/ -> Rosetta API handlers
βββ logging/ -> Logging utilities
βββ utils/ -> Package utilities
All files within this repository, including code adapted from rosetta-geth-sdk, is licensed under the terms of the Apache 2.0 License unless explicitly stated otherwise.