TradeVerse is a modular monolith backend application built using Go (Gin) and PostgreSQL. It implements role-based trading workflows, wallet accounting, and subscription lifecycle management using structured service-layer business logic.
TradeVerse follows a modular monolith design with clear separation between HTTP handling, business logic, and data access layers.
It includes:
- Role-based authentication (Admin / Trader / Customer)
- Wallet system with transaction ledger
- Subscription lifecycle automation
- Trader signal publishing
- Admin configuration and pricing management
- Cron-based background jobs
- Go (Gin Framework)
- PostgreSQL
- GORM
- JWT Authentication
- Cron Jobs (Schedulers)
- Server-rendered Admin UI
- Layered Architecture (Handler → Service → Repository)
- Docker (local setup)
The project follows a layered architecture with clear separation of responsibilities:
- Handler Layer — HTTP request parsing and routing
- Service Layer — Business rules and transaction orchestration
- Repository Layer — Database access using GORM
- Domain Models — Core entities and validation logic
Client → Router → Handler → Service → Repository → PostgreSQL
- Signup / Login
- Browse traders
- Subscribe / Unsubscribe
- Deposit / Withdraw wallet funds
- View transaction history
- View subscribed trader signals
- Create and manage trading signals
- Publish live trades
- Create subscription plans
- View subscriber information
- Manage users and traders
- Configure pricing and commissions
- Monitor subscriptions
- View basic analytics
- Deposit and withdraw functionality
- Transaction ledger stored in PostgreSQL
- Balance updates executed within database transactions to ensure atomicity and consistency
Subscription status is validated using scheduled cron jobs:
- Automatic expiry of inactive subscriptions
- Access restriction after expiry
- Periodic verification of subscription validity
- Periodic fetching of market price data (OHLC format)
- Stored in normalized database tables
- Used for trader signal context
tradeverse/ ├── cmd/ │ ├── admin/ │ ├── trader/ │ └── customer/ ├── config/ ├── internal/ │ ├── admin/ │ ├── trader/ │ └── customer/ ├── migrations/ ├── pkg/ │ ├── auth/ │ ├── models/ │ ├── seeder/ │ └── utils/ ├── static/ ├── templates/ └── README.md
git clone https://github.com/fathimasithara01/tradeverse cd tradeverse
cp .env.example .env
go mod tidy
go run internal/migrations/main.go
go run pkg/seeder/main.go
go run cmd/server/main.go
- Local Docker setup for development and testing
- No distributed scaling setup
- No Kubernetes or cloud deployment included
Fathima Sithara Backend Engineer (Golang) GitHub: https://github.com/fathimasithara01