A comprehensive virtual currency wallet service facilitating seamless transactions, withdrawals, deposits, and fund aggregation. Designed to operate independently from business services, it leverages HTTP-based inter-service communication for enhanced modularity.
Key Features
- Multi-chain Support: Ethereum (ERC20), Tron (TRC20), Binance Chain (BEP20), OKC (KIP20), Bitcoin.
- Pro Version: Enhanced commercial-grade features (available via GitHub Issues).
SDKs:
Getting Started
Installation & Setup
git clone https://github.com/lmxdawn/wallet.git
cd wallet
go build [-tags "doc"] # Optional: Include Swagger docs
./wallet -c config/config-example.yml Configuration
- Edit
config.ymland relaunch with./wallet -c config.yml. - Access Swagger UI:
http://localhost:10009/swagger/index.html.
Core Workflows
Deposits
- Continuously scan latest blocks for transactions.
- Validate if recipient addresses (
to) match service-generated wallets. - Ensure transaction hash idempotency to avoid duplicate processing.
๐ Explore advanced wallet solutions
Withdrawals
- User initiates withdrawal; service signs transaction with configured private key.
- Record transaction hash and monitor for completion.
- Apply idempotency checks for transaction status updates.
Fund Aggregation
- Periodically transfer balances from generated addresses to a centralized cold wallet.
- Optimize gas fees by triggering aggregation only after reaching threshold amounts.
Technical Stack
- Logging:
zerolog - CLI Tools:
cli(urfave) - Config Management:
configor - Dependencies: Go 1.16+, Redis 3, MySQL 5.7
FAQ
How do I access the Pro version?
Contact via GitHub Issues or reach out to appeth on WeChat (mention "GitHub" in request).
What chains are supported?
Ethereum, Tron, Binance Chain, OKC, and Bitcoin (see roadmap for updates).
How are private keys managed?
Use create2 for contract-based wallets to avoid bulk private key storage risks.
๐ Learn more about secure wallet practices
Additional Resources
- Contract Tools: Generate ABIs with
solcjsand bindings viaabigen. - Database Models: Execute
script/Generate MyPOJOs.groovyfor auto-generated models.
Designed for commercial scalability and audited in live projects. Contributions welcome!