Project document
Architecture
System structure, service boundaries, integrations, and recommended organization.
Layers
- Presentation layer for public, user, and admin interfaces.
- Application layer for routes and orchestration.
- Domain/services layer for auth, market, billing, and portfolio logic.
- Integration layer for Groq, Finnhub, Alpha Vantage, CoinGecko, TradingView, and Stripe.
- Persistence layer with MongoDB.
Principles
- Keep provider-specific code behind adapters.
- Keep plan and feature enforcement centralized.
- Use server-side checks for authorization and entitlements.