Persisted BYO backend

examples/rfq-nextjs/server/postgresByo.ts is the authorized persisted adapter. It replaces claimed permissions and supplierId from a server persona directory. It is not an in-memory store pretending to be production.

const { adapter, registerPersona } = createPostgresByoAdapter({
  workspaceId: process.env.BSW_WORKSPACE_ID!,
  appId: process.env.RFQ_APP_ID!,
  environment: "test",
});
registerPersona("user_ada", { permissions: ["buyer_read", "buyer_edit", "buyer_decide"] });
registerPersona("user_north", {
  permissions: ["supplier_read", "supplier_quote", "supplier_clarify"],
  supplierId: "sup_north",
});
pnpm --filter @bootstrapware/rfq-example conformance

Conformance walks create, publish, quote, close, compare, and select against that adapter. Browser-supplied permissions are discarded. A second tenant or a revoked supplier must not read the first tenant's quotes.

Related: Adapter · Next.js