Getting Started
Prerequisites
- Bun 1.0+ — runtime and package manager (bun.sh)
- Node.js 18+ — some dependencies still require it
- Git
Install
git clone https://github.com/nickolaylavrinenko/profitmaker.gitcd profitmakerbun installbun install resolves all workspace dependencies across the four packages.
Project Structure
profitmaker/├── packages/│ ├── types/ # @profitmaker/types -- shared TypeScript types + Zod schemas│ ├── core/ # @profitmaker/core -- CCXT wrappers, providers, encryption, formatters│ ├── server/ # @profitmaker/server -- Express 5 + Socket.IO backend│ └── client/ # @profitmaker/client -- React + Vite frontend├── src/ # Client source (legacy location, used by Vite via client package)├── package.json # Root workspace config└── docs/ # This documentationDevelopment
Start the client (Vite dev server)
bun devOpens at http://localhost:8080. Hot module replacement enabled.
Start the server (optional, for CORS bypass)
bun server:devRuns Express + Socket.IO on http://localhost:3001 with file watching.
The server is optional — the client can use CCXT directly in the browser. The server is needed when exchanges block browser requests (CORS) or for WebSocket streaming via CCXT Pro.
Both together
Open two terminals:
# Terminal 1bun dev
# Terminal 2bun server:devBuild
bun run buildProduces a production Vite build for the client.
Testing
# Run all tests (Vitest for client, bun:test for core)bun test
# Run specific test filebun test packages/core/src/__tests__/ccxt-bun.test.tsLinting
bun lintRuns ESLint on the client package.
Environment Variables
| Variable | Default | Description |
|---|---|---|
PORT | 3001 | Express server port |
API_TOKEN | your-secret-token | Bearer token for server API authentication |
No .env file is required for basic development. The client uses browser-side CCXT by default.
First Run Checklist
bun installbun dev— open http://localhost:8080- You’ll see the default dashboard with Chart, Portfolio, Order Form, and Transaction History widgets
- Right-click the canvas to add more widgets
- (Optional) Set up a master password to encrypt API keys — see Security
- (Optional) Add exchange accounts in the user drawer to trade with real data