A modular Go SDK for building multi-chain cryptocurrency wallets and blockchain applications.
go get github.com/status-im/go-wallet-sdk-
pkg/balance/fetcher: High-performance balance fetching with automatic fallback strategies- Native token (ETH) balance fetching for multiple addresses
- ERC20 token balance fetching for multiple addresses and tokens
- Smart fallback between different fetching methods
- Chain-agnostic design
-
pkg/multicall: Efficient batching of contract calls using Multicall3- Batch multiple contract calls into single transactions
- Support for ETH, ERC20, ERC721, and ERC1155 balance queries
- Automatic chunking and error handling
- Synchronous and asynchronous execution modes
pkg/ethclient: Full-featured Ethereum client with go-ethereum compatibility- Complete RPC method coverage (eth_, net_, web3_*)
- Go-ethereum ethclient compatible interface for easy migration
- Chain-agnostic methods for any EVM-compatible network
pkg/gas: Comprehensive gas fee estimation and suggestions- Smart fee estimation for three priority levels (low, medium, high)
- Transaction inclusion time predictions
- Multi-chain support (L1, Arbitrum, Optimism, Linea)
- Network congestion analysis for L1 chains
- Chain-specific optimizations
-
pkg/eventfilter: Efficient event filtering for ERC20, ERC721, and ERC1155 transfers- Minimizes eth_getLogs API calls
- Direction-based filtering (send, receive, both)
- Concurrent query processing
-
pkg/eventlog: Automatic event log detection and parsing- Type-safe access to parsed event data
- Support for Transfer, Approval, and other standard events
- Works seamlessly with eventfilter
-
pkg/accounts/extkeystore: Extended keystore with HD wallet support- BIP32 hierarchical deterministic wallet functionality
- Encrypted storage following Web3 Secret Storage specification
- Child account derivation using BIP44 derivation paths
- Import/export extended keys and standard private keys
- Full account lifecycle management (create, unlock, lock, sign, delete)
-
pkg/accounts/mnemonic: BIP39 mnemonic phrase utilities- Generate cryptographically secure mnemonic phrases (12, 15, 18, 21, 24 words)
- Create BIP32 extended keys from mnemonic phrases
- BIP39 passphrase support for seed extension
- Seamless integration with extkeystore
-
pkg/tokens/types: Core data structures for tokens and token lists- Unified token representation with cross-chain support
- Token list metadata and versioning
- Type-safe address handling and validation
-
pkg/tokens/parsers: Token list parsing from multiple formats- Standard token list format (Uniswap-style)
- Status-specific format with chain grouping
- CoinGecko API format with platform mappings
- List-of-token-lists metadata parsing
-
pkg/tokens/fetcher: HTTP-based token list fetching- Concurrent fetching with goroutines
- HTTP ETag caching for bandwidth efficiency
- JSON schema validation support
- Robust error handling and timeout management
-
pkg/tokens/autofetcher: Automated background token list management- Configurable refresh intervals
- Thread-safe operations with context support
- Pluggable storage backends
- Error reporting via channels
-
pkg/tokens/builder: Incremental token collection building- Builder pattern for stateful construction
- Automatic deduplication by chain ID and address
- Native token generation for supported chains
- Multiple format support through parsers
-
pkg/tokens/manager: High-level token management interface- Multi-source token integration (native, remote, local, custom)
- Thread-safe concurrent access
- Rich query capabilities by chain, address, or list ID
- Automatic refresh and state management
pkg/ens: Ethereum Name Service (ENS) resolution- Forward resolution (ENS name → Ethereum address)
- Reverse resolution (Ethereum address → ENS name)
- Chain support detection via
IsSupportedChain() - Works on any chain where ENS registry is deployed
pkg/contracts: Go bindings for smart contracts- Multicall3 with 200+ chain deployments
- ERC20, ERC721, and ERC1155 token standards
- Automated deployment address management
pkg/common: Shared utilities and constants used across the SDK
cd examples/balance-fetcher-web
go run .Access: http://localhost:8080
cd examples/ethclient-usage
go run .cd examples/gas-comparison
# Test with local mock data
go run . -fake
# Test with real networks (requires Infura API key)
go run . -infura-api-key YOUR_API_KEYcd examples/multiclient3-usage
go run .cd examples/eventfilter-example
go run . -account 0xYourAddress -start 19000000 -end 19100000cd examples/accounts
go run .Access: http://localhost:8081
Interactive web interface for testing extkeystore and standard keystore functionality, including mnemonic generation, account creation, derivation, import/export, and signing.
# Build the shared library first
make shared-library
# Then build and run the C example
cd examples/c-app
make build
cd bin
./c-appDemonstrates how to use the Go Wallet SDK from C applications using the shared library. The example creates an Ethereum client, retrieves the chain ID, and fetches account balances.
The SDK can be compiled as a C shared library for use in non-Go applications:
make shared-libraryThis creates:
build/libgowalletsdk.dylib(macOS) orbuild/libgowalletsdk.so(Linux)build/libgowalletsdk.h(C header file)
The shared library exposes Ethereum client functionality through a C-compatible API. See examples/c-app for a complete C usage example.
# Token Builder - Incremental token collection building
cd examples/token-builder
go run .
# Token Fetcher - HTTP-based token list fetching
cd examples/token-fetcher
go run .
# Token Manager - High-level token management
cd examples/token-manager
go run .
# Token Parser - Parse different token list formats
cd examples/token-parser
go run .cd examples/ens-resolver-example
# Forward resolution (ENS name to address)
go run . -rpc https://eth.llamarpc.com -name vitalik.eth
# Reverse resolution (address to ENS name)
go run . -rpc https://eth.llamarpc.com -address 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045go test ./...go-wallet-sdk/
├── pkg/ # Core SDK packages
│ ├── balance/ # Balance fetching functionality
│ ├── multicall/ # Multicall3 batching
│ ├── ethclient/ # Ethereum client with full RPC support
│ ├── gas/ # Gas estimation and fee suggestions
│ ├── eventfilter/ # Event filtering for transfers
│ ├── eventlog/ # Event log parsing
│ ├── accounts/ # Account management (extkeystore, mnemonic)
│ ├── tokens/ # Token management system
│ │ ├── types/ # Core token data structures
│ │ ├── parsers/ # Token list format parsers
│ │ ├── fetcher/ # HTTP token list fetching
│ │ ├── autofetcher/ # Automated background fetching
│ │ ├── builder/ # Incremental token collection building
│ │ └── manager/ # High-level token management
│ ├── ens/ # ENS name resolution
│ ├── contracts/ # Smart contract bindings
│ └── common/ # Shared utilities
├── cshared/ # C shared library bindings
│ ├── c.go # Memory management utilities
│ ├── ethclient.go # Ethereum client C bindings
│ └── main.go # Entry point for shared library build
├── examples/ # Usage examples
│ ├── balance-fetcher-web/ # Web interface for balance fetching
│ ├── ethclient-usage/ # Ethereum client examples
│ ├── gas-comparison/ # Gas fee comparison tool
│ ├── multiclient3-usage/ # Multicall examples
│ ├── multistandardfetcher-example/ # Multi-standard balance fetching
│ ├── eventfilter-example/ # Event filtering examples
│ ├── accounts/ # Keystore management web interface
│ ├── c-app/ # C application example
│ ├── token-builder/ # Token collection building
│ ├── token-fetcher/ # Token list fetching
│ ├── token-manager/ # Token management
│ ├── token-parser/ # Token list parsing
│ └── ens-resolver-example/ # ENS resolution CLI tool
└── README.md # This file
- Balance Fetcher - Balance fetching functionality
- Multicall - Efficient contract call batching
- Ethereum Client - Complete Ethereum RPC client
- Gas Estimation - Gas fee estimation and suggestions
- Event Filter - Event filtering for transfers
- Event Log Parser - Event log parsing
- Extended Keystore - HD wallet keystore with BIP32 support
- Mnemonic - BIP39 mnemonic phrase utilities
- Token Types - Core token data structures
- Token Parsers - Token list format parsers
- Token Fetcher - HTTP token list fetching
- Token AutoFetcher - Automated background fetching
- Token Builder - Incremental token collection building
- Token Manager - High-level token management
- ENS Resolver - ENS name resolution
- Web Balance Fetcher - Web interface for balance fetching
- Ethereum Client Usage - Ethereum client examples
- Gas Comparison - Gas fee comparison tool
- Multicall Usage - Multicall examples
- Event Filter Example - Event filtering examples
- Accounts Example - Keystore management web interface
- C Application Example - C application using the shared library
- Token Builder - Token collection building
- Token Fetcher - Token list fetching
- Token Manager - Token management
- Token Parser - Token list parsing
- ENS Resolver Example - ENS resolution CLI tool
- Technical Specifications - Complete SDK specifications and architecture
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Submit a pull request
Mozilla Public License Version 2.0 - see LICENSE
Built with ❤️ by the Status team