Prood
Getting Started

Installation

Clone the Prood monorepo, install dependencies, migrate the database, and start development servers.

Prood uses a pnpm + Turborepo monorepo. All applications live under apps/ and shared libraries under packages/.

Prerequisites

Install the following before proceeding:

  • Node.js 24+ — required by all apps (engines.node >= 24)
  • pnpm 10 — package manager (corepack enable or npm i -g pnpm)
  • Neon Postgres — provision a database and copy the connection string

Optional services for full functionality:

ServiceUsed byPurpose
Upstash Redisapps/checkoutCheckout session persistence
Vercel Blob or S3@prood/storage-*Product image uploads
Stripe / Easypay / IfthenpayPayment providersLive payment flows

Step 1 — Clone and install

git clone <your-repo-url>
cd prood-commerce-platform
pnpm install

This installs all workspace packages and runs postinstall hooks (including fumadocs-mdx for the docs app).

Step 2 — Environment configuration

Copy the example env file and fill in required values:

cp .env.example .env.local
pnpm env:link

At minimum, set:

DATABASE_URL="postgresql://user:password@host/db?sslmode=require"
BETTER_AUTH_SECRET="<openssl rand -base64 32>"
DEFAULT_TENANT_ORG_ID="org_demo"

See Environment variables for the complete reference.

Step 3 — Database setup

Run the combined setup script:

pnpm db:setup

This executes:

ScriptWhat it does
pnpm db:migrateRuns @prood/platform migrations, applies RLS policies, seeds demo catalog
pnpm db:authPushes Better Auth schema via Drizzle (pnpm --filter storefront db:push)

Verify the seed

Connect to your database and confirm products exist:

SELECT set_config('app.current_org_id', 'org_demo', false);
SELECT id, name FROM products LIMIT 5;

RLS requires app.current_org_id to be set — this is what @prood/commerce withTenant() does automatically.

Step 4 — Start development

pnpm dev

Turbo runs all apps in parallel. Individual apps can also be started:

pnpm --filter storefront dev    # :3000
pnpm --filter dashboard dev     # :3002
pnpm --filter checkout dev      # :3004
pnpm --filter api dev           # :3005
pnpm --filter docs dev          # :3003

Monorepo structure

Drag to pan · Scroll to zoom

Build and quality scripts

CommandDescription
pnpm buildBuild all apps and packages via Turbo
pnpm typecheckTypeScript check across the monorepo
pnpm lintESLint across the monorepo
pnpm --filter @prood/platform buildBuild the platform package only

Adding UI components

Shared shadcn primitives live in @prood/ui:

pnpm dlx shadcn@latest add button -c packages/ui

Commerce-specific components (product grid, cart drawer, checkout stepper, etc.) are in packages/ui/src/components/ and imported as @prood/ui/components/<name>.

Troubleshooting

DATABASE_URL not set

Every app that touches auth or commerce requires DATABASE_URL. Ensure .env.local exists at the repo root and pnpm env:link has been run.

Checkout sessions fail to create

apps/checkout requires Upstash Redis. Set UPSTASH_REDIS_REST_URL and UPSTASH_REDIS_REST_TOKEN in .env.local. Without Redis, session creation returns 500.

Storefront shows 404 in production

If no tenant matches the request host and DEFAULT_TENANT_ORG_ID is unset, the storefront calls notFound(). In development, it falls back to the demo org.

Auth tables missing

Run pnpm db:auth or the full pnpm db:setup. Auth tables are separate from the commerce schema and must be pushed via Drizzle.

On this page