Set up your stack
A complete, copy-pasteable integration-agent prompt for each framework + ORM - plus a manual walkthrough. Wire fail-closed multi-tenancy in one paste.
Each page here is a full, imperative integration-agent prompt for one stack - hand it to an AI assistant (Claude Code, Cursor, …) and it works on a new or existing app: it assesses your app first, integrates with your existing models and auth, verifies each change, and finishes by proving isolation with an isolated two-tenant leak test. Every page also has a manual walkthrough with the real code if you'd rather do it by hand.
This is the "batteries-included, but not out-of-the-box" seam: TenancyJS scopes and fails closed for you, but wiring it into your app - and provisioning each tenant's storage
- is a deliberate, reviewed step. These recipes make that step a single paste.
Pick your stack
Express
Express + Prisma
Row-level · PostgreSQL
Express + Knex
Row-level (forced RLS) · PostgreSQL
Express + TypeORM
Row-level (forced RLS) · PostgreSQL
Express + Sequelize
Row-level (forced RLS) · PostgreSQL
Express + Drizzle
Row-level (forced RLS) · PostgreSQL
Express + Mongoose
Row-level · MongoDB
Next.js
Next.js + Prisma
Row-level · PostgreSQL
Next.js + Knex
Row-level (forced RLS) · PostgreSQL
Next.js + TypeORM
Row-level (forced RLS) · PostgreSQL
Next.js + Sequelize
Row-level (forced RLS) · PostgreSQL
Next.js + Drizzle
Row-level (forced RLS) · PostgreSQL
Next.js + Mongoose
Row-level · MongoDB
NestJS
NestJS + Prisma
Row-level · PostgreSQL
NestJS + Knex
Row-level (forced RLS) · PostgreSQL
NestJS + TypeORM
Row-level (forced RLS) · PostgreSQL
NestJS + Sequelize
Row-level (forced RLS) · PostgreSQL
NestJS + Drizzle
Row-level (forced RLS) · PostgreSQL
NestJS + Mongoose
Row-level · MongoDB
AdonisJS
AdonisJS + Lucid — row-level
Shared tables, forced Postgres RLS
AdonisJS + Lucid — schema-per-tenant
One PostgreSQL schema per tenant
AdonisJS + Lucid — database-per-tenant
A database per tenant
All three AdonisJS + Lucid strategies live on one page - each card jumps to its integration-agent prompt.
By strategy
The stack pages above default to row-level. For the other two isolation strategies, one page each covers every ORM (worked integration-agent prompt + a per-ORM swap table), and pairs with the provisioning recipes.
Schema-per-tenant
One PostgreSQL schema per tenant · all SQL ORMs
Database-per-tenant
A database per tenant · PostgreSQL · MySQL · MongoDB
MySQL — database-per-tenant
The MySQL production path · Prisma · TypeORM · Sequelize · Drizzle · Lucid
These recipes default to row-level - the fastest way to a working, tested isolation boundary. For
schema-per-tenant or database-per-tenant, follow the same wiring, then switch the adapter's strategy
and add the provisioning recipe for your ORM.