Skip to content

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 site

Where 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 validationapps/api/src/validators/*.ts (Zod)
A route / middleware wiringapps/api/src/routes/*.routes.ts
Auth / role / quota gatingapps/api/src/middleware/*.ts
A scheduled job or SMS workerapps/api/src/workers/*.ts + queues/*.ts
A DB shapeprisma/schema.prisma + a new migration
A web pageapps/web/src/pages/**
A reusable UI primitiveapps/web/src/components/ui/*.tsx
Data fetching from the clientpackages/hooks + packages/api-client
A shared type/enumpackages/types/src/index.ts
An admin screenapps/admin/src/pages/**

Reading order for a new contributor ​

  1. prisma/schema.prisma — the domain in one file.
  2. apps/api/src/app.ts — how routes and middleware wire together.
  3. 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.
  4. On the client: apps/web/src/App.tsx (routes) → a page under pages/Sell → its hook in packages/hooks.

Continue to API Backend →.

Internal technical documentation — Cropto