All blocks

Operations

Data lifecycle

Data exports per user or organization from every installed module's tables and the app's, written to a private bucket by the app's export job, and organization deletion with a grace period that disables the tenant before a purge job deletes its rows.

DocsModes:managedcustom
terminal
npx better-supabase sql add data-lifecycle
better-supabase.config.ts
import { defineConfig } from "better-supabase/config";

export default defineConfig({
  sql: {
    modules: {
      // Required by data-lifecycle; sql add installs them too.
      "updated-at": {},
      tenant: {},
      access: {},
      // Modes: "managed", "custom". The default is "managed".
      "data-lifecycle": { mode: "managed" },
    },
  },
});