🪙 A flexible, strategy-driven cryptocurrency trading bot written in Go.
- 📊 Multiple trading strategies support (MACD, etc.)
- 🔒 Safe automated trading with clear architecture
- 📱 Telegram bot interface
- 💾 PostgreSQL for persistence
- ☁️ Optional S3 integration
- 🔧 Configurable via YAML and environment variables
- Clone the repository
git clone https://github.com/your-username/mercator.git- Set up configuration
cp .local.env.example .local.env- Start PostgreSQL
make start-postgres
make create-db
make migrate-up- Run the bot
make runThe bot can be configured using both YAML files and environment variables:
app:
log_level: "info"
log_format: "text"
wallet:
use_local_file: true
mock_balance_file: "balance.json"Environment variables:
BINANCE_API_KEY- Your Binance API keyBINANCE_SECRET_KEY- Your Binance Secret keyTELEGRAM_BOT_TOKEN- Telegram Bot TokenDB_DRIVER- Database driver (default: postgres)DB_SOURCE- Database connection string
├── cmd # Application entrypoints
├── config # Configuration
├── internal # Internal packages
│ ├── app # Application setup
│ ├── domain # Domain models
│ ├── handlers # Request handlers
│ ├── infra # Infrastructure layer
│ ├── reporters# Output formatting
│ └── services # Business logic
This project is licensed under the MIT License - see the LICENSE file for details.