Monorepo Map
Cropto is an npm-workspaces monorepo. This section is a folder-by-folder walkthrough of the code you'll actually edit.
text
cropto/
├── apps/
│ ├── api/ → Backend (see "API Backend")
│ ├── web/ → Trading app (see "Web & Admin Frontends")
│ ├── admin/ → Admin panel (see "Web & Admin Frontends")
│ ├── marketing/ → Marketing site (see "Mobile & Marketing")
│ └── mobile/ → Android app (see "Mobile & Marketing")
├── packages/ → Shared TS packages (see "Shared Packages")
├── prisma/ → Schema, migrations, seeds (see "Data Model")
└── docs/ → This siteWhere does X live?
| I want to change… | Look in |
|---|---|
| A business rule (accept an offer, compute P&L) | apps/api/src/services/*.service.ts |
| Request validation | apps/api/src/validators/*.ts (Zod) |
| A route / middleware wiring | apps/api/src/routes/*.routes.ts |
| Auth / role / quota gating | apps/api/src/middleware/*.ts |
| A scheduled job or SMS worker | apps/api/src/workers/*.ts + queues/*.ts |
| A DB shape | prisma/schema.prisma + a new migration |
| A web page | apps/web/src/pages/** |
| A reusable UI primitive | apps/web/src/components/ui/*.tsx |
| Data fetching from the client | packages/hooks + packages/api-client |
| A shared type/enum | packages/types/src/index.ts |
| An admin screen | apps/admin/src/pages/** |
Reading order for a new contributor
prisma/schema.prisma— the domain in one file.apps/api/src/app.ts— how routes and middleware wire together.- A vertical slice end-to-end, e.g. sell leads:
routes/sellLead.routes.ts→services/sellLead.service.ts→validators/sellLead.validator.ts→lib/leadSerializer.ts. - On the client:
apps/web/src/App.tsx(routes) → a page underpages/Sell→ its hook inpackages/hooks.
Continue to API Backend →.
