PayFlow is a Next.js and Supabase payment workflow sandbox for merchant transfers, payment requests, approvals, FX conversion, settlements, and compliance-grade audit trails, designed for Vercel deployment with Supabase Auth, Postgres, RLS, and a mock provider adapter.
The previous multi-app structure has been removed from the active app shape. Current development happens from the repository root.
- Node.js
>=20.19.0 - npm
The Node requirement matches the Next.js 16 baseline used by this project.
- Next.js App Router with TypeScript
- Supabase Auth, Postgres, and RLS
- Vercel hosting and cron jobs
- Mock provider adapter for local payment workflow development
- React and Tailwind CSS
- Vitest for unit tests
- Playwright for e2e smoke tests
Install dependencies:
npm installCreate local environment variables:
cp .env.example .env.localFor local Supabase development, start Supabase with the configuration in supabase/config.toml, then replace the publishable and secret key placeholders in .env.local with values from your local Supabase project.
Start the development server:
npm run devOpen http://localhost:3000.
The required Vercel cron contract keeps /api/cron/fx-refresh on the hourly schedule 0 * * * *. Hourly cron requires Vercel Pro or Enterprise; Hobby users must change that schedule to daily or disable hourly FX refresh before deploying. Vercel Cron invokes route handlers with HTTP GET, so future cron routes should implement GET handlers and validate CRON_SECRET before running scheduled work.
npm run dev # Start Next.js locally
npm run build # Build the app
npm run start # Start a production build
npm run lint # Run ESLint
npm run typecheck # Run TypeScript checks
npm run test # Run Vitest unit tests
npm run test:e2e # Run Playwright e2e tests
npm run verify # Typecheck, lint, unit test, and buildsrc/app/contains the root Next.js App Router entry points.src/test/setup.tsconfigures unit test setup.tests/unit/contains Vitest tests.tests/e2e/contains Playwright tests.
Supabase schema, authentication, and payment workflows will be added in later migration tasks.