public schema is reachable by every browser, mobile client and holder of
the anon key through PostgREST. Row Level Security is the fence for every
table that still grants client roles, so one missing or permissive policy
exposes a table. 20260522172925_harden_proxy_only_public_tables.sql revoked
the public default privileges on tables, sequences and functions for
current_user, postgres and the supabase_* owner roles the migration role
belongs to. 20261027151200_restrict_anon_definer_execute.sql can re-grant
default function EXECUTE to authenticated or service_role where that access
came from the implicit global PUBLIC default. Platform-owned default ACLs
(owner supabase_admin) still grant client roles in a full local replay; those
apply only to objects that role creates.
The target is a public schema with no application relations. Application data
lives in private, which anon and authenticated cannot use, and clients
reach it only through server routes that authorize the actor first.
This page is the plan. It applies no migration and is not production
authorization: every production database change in it needs its own approval
(see Approvals).
Current state
Inventory from checked-in source on 2026-11-17 (generated types inpackages/types/src/supabase.ts, migrations in
apps/database/supabase/migrations). Generated types are a source snapshot;
confirm hosted catalog state on a disposable replay before each wave.
The move is an established pattern: 65 migrations named
*private* (for
example 20260521155712_move_more_tables_private.sql and
20260528141100_move_inventory_tables_private.sql) moved tables with
ALTER TABLE … SET SCHEMA private, revoked client roles, added a
service_role policy and re-pinned dependent function search_paths.
private is listed in [api].schemas (apps/database/supabase/config.toml)
so the server can call .schema('private'), while USAGE is revoked from
public, anon and authenticated. 569 source files already use
.schema('private').
Direct callers
Lexical scan of.from('<table>') and .rpc('<fn>') in apps/* and
packages/* (TypeScript, excluding tests, backend, tanstack-web), Dart in
apps/mobile/lib, and Python in apps/discord. A file is classified as:
- browser: a
'use client'module or one that imports the browser Supabase client; - rls: a server module without an admin client, so the query runs as the user and depends on RLS;
- admin: a server module that creates a service-role client.
The per-table classification is in the appendix.
no-ts-caller means no lexical TypeScript, Dart or Python caller; such tables
can still be read by SQL functions, triggers or views, so check pg_depend and
function bodies before treating them as dead.
Sensitivity classes
- Secrets, credentials and auth state: encrypted secrets, OAuth tokens, API keys, mail credentials, payment provider connections, QR login, abuse/suspension controls, platform roles.
- Billing and money: subscriptions, credit balances, invoices, wallets, transactions, payroll/compensation.
- Mail and PII: sent mail, audit, blacklists, notifications and push devices, inquiries and feedback, user and workspace-user profiles.
- Workspace content: AI chats, meeting AI, Mira, tasks, time tracking, calendars, courses, quizzes, external projects.
- Public catalogs: changelog, holidays, exchange rates, short links, public polls and Meet Together plans.
Target pattern
Data access
- Tables and views live in
private,ENABLE ROW LEVEL SECURITY, with oneFOR ALL TO service_rolepolicy andREVOKE ALL … FROM public, anon, authenticated. Views aresecurity_invoker. - Server routes own access. Each route resolves the actor, checks
workspace membership and permission with the request-scoped client, then uses
the admin client on
privateand keeps every child read and write scoped to the verified workspace. Shared data access stays inpackages/internal-apiand the domain*-corepackages; framework adapters inject the client. New handlers go underapps/web/src/app/api/**, notlegacy-api-routes/**. - RPCs. A function that touches only private tables moves to
private, executable byservice_roleonly. Functions that rely onauth.uid()take an explicitp_actor_idthe server resolves, and keep their internal workspace checks. Apublicfunction survives only on the guard’s function allowlist (see Guard) with anauth.uid()check, pinnedsearch_pathending inpg_temp, and explicit grants. - Rollout fallback. Production migrations apply after the production
deployment marker, so code ships before the move. Each moved table is read
through a helper that targets
privatefirst and falls back topublicon42P01,PGRST106orPGRST205, caching the resolved schema per process (precedent:packages/education-core/src/education/private-quiz-answers.ts). The fallback is removed in the next wave once the move is confirmed in production. Rollback of a move therefore needs no code deploy.
Compatibility views
Do not create client-granted compatibility views inpublic. A
security_invoker view fails once the client loses private access, and a
definer view re-creates the exposure. The only allowed form is a
service_role-only public.<name> view over private.<name> when a
service-role caller (for example the Discord bot) cannot ship in time, recorded
on the allowlist with an expiry wave. Mobile compatibility comes from the
release window, not from views.
Realtime
Clients keep subscribing to private Broadcast channels with the server-issued join ticket. Mutating routes publish after commit (server fan-out through Realtime broadcast or the owning Durable Object). Moving a table never adds apostgres_changes subscription; the browser session-surface guard keeps that
count at 0. Each wave removes its moved tables from the supabase_realtime
publication after confirming no subscriber in the realtime log aggregation.
Mobile and SDK
- Each mobile table gets a versioned
/api/v1/...endpoint and acheck-mobile-api-mappingsentry. The app switches in one release (Mobile release M1) shipped before Wave 2. - Revocation of a mobile table waits until the
version-checkminimum supported version is at or above M1 and the old-version share of authenticated traffic is below the agreed threshold (default: under 2% for 14 days). - The SDK is unaffected at the data layer. Any route whose response shape changes keeps the old shape for one minor SDK release.
RLS helpers and storage policies
Policies run as the querying role. Once a table is private, anypublic
policy, view or invoker function that reads it fails for authenticated. Per
wave:
- On a disposable full replay, list dependents with
pg_dependand scanpg_proc.prosrcfor the table name (PL/pgSQL bodies are not tracked bypg_depend). - Re-pin dependent function
search_pathtopublic, private, pg_tempor qualify references. - Membership and permission helpers that client-facing policies still need
(storage
workspacesbucket, any remaining client RLS) move to a non-exposed helper schema, followingworkspace_storage: not in[api].schemas,USAGEgranted toauthenticated, functionsSECURITY DEFINERwith pinned path and EXECUTE only for the roles their policies run as. - Re-run
security-definer-search-paths.sql,security-definer-policy-callers.sqlandworkspace-storage-least-privilege-rls.sql.
Generated types
bun sb:typegen already emits public,private,storage. After each local apply,
regenerate and commit; shared row aliases in packages/types/src/db.ts point at
Database['private']['Tables'][…]. Never hand-edit generated files.
Wave mechanics
Every wave runs the same three phases. Each phase is a separate commit set.
Phase B of wave N+1 and phase C of wave N can share one migration batch and one
approval. Migration rules:
SET SCHEMAtakes anACCESS EXCLUSIVElock briefly: setlock_timeout(for example'3s') and keep each table move short. Keep DDL, constraint validation and concurrent index work in separate files.- Capture ACLs including grantors and grant options, policy definitions and
function definitions before the change so the rollback restores exactly.
Never re-grant
PUBLICoranonin a rollback that did not have them. - Migrations that touch pg_cron targets execute the stored
cron.job.commandon the disposable chain. - Apply locally (
bun sb:reset) throughttr resources run, then typegen. Production runs only throughsupabase-production.yamlafter the staging marker; neverbun sb:push.
Tests per wave
- pgTAP
private-schema-client-denial.sql(new, extended each wave): for every relation inprivate,has_table_privilegeis false foranonandauthenticatedon SELECT, INSERT, UPDATE, DELETE;has_schema_privilegeonprivateUSAGE is false for both; every function inprivateis not executable byPUBLIC,anonorauthenticated; each wave’s tables exist inprivateand not inpublic. - HTTP denial check against local PostgREST: anon key and a user JWT get
PGRST205/404 for/rest/v1/<t>and a permission error withAccept-Profile: private. - Source “no direct client access” check (part of the guard): no moved
table appears in a browser module, a Dart
.from(...), a Python.table(...)withoutschema("private"), or a TypeScript.from(...)without a preceding.schema('private')or the fallback helper. - Focused route tests for every changed route (authorization 401/403/500 mapping, workspace scoping, actor stamping) and the existing domain pgTAP suites for moved RPCs.
- Mobile: repository tests against the new endpoints;
flutter gen-l10nonly if strings change. - Exact-commit CI: Web build and each touched satellite build, type-check, lint, test. No local builds.
Waves
ETAs are focused agent-days for implementation, review and verification, excluding store review and approval waits. Waves 5, 6 and 7 are independent and can run in parallel lanes after Wave 4.
Total: about 64 agent-days serial; about 40 with Waves 5–7 parallel. Add
production approval latency per batch and one mobile store cycle (M1) that runs
during Waves 0–1.
Wave 0: guard and foundations
- Land the guard with the full current allowlist (no table moves).
- Run the read-only hosted catalog check (default ACLs in
public, RLS-off tables, and client grants on them) on staging, then production. Add a default-privilege migration only if the hosted result shows client grants the guard cannot exempt. It loops over the same owner roles as20260522172925, snapshotspg_default_aclbefore and after, and needs approval. - Add the pgTAP denial test, the HTTP denial check and the private-first
fallback helper in
@tuturuuu/supabase(with tests). - Start mobile M1: endpoints for the 6 mobile tables, Flutter repository switch, minimum-version plan.
- Security review of the guard and any default-privilege migration.
Wave 1: secrets, credentials, abuse controls
Tables:workspace_secrets, workspace_encryption_keys,
calendar_auth_tokens, calendar_connections, calendar_sync_*,
workspace_calendar_sync_coordination, workspace_email_credentials,
workspace_api_keys, workspace_api_key_usage_logs, sepay_*,
discord_integrations, qr_login_challenges, live_api_sessions,
blocked_ips, abuse_*, rate_limit_appeals, user_suspensions,
platform_*, workspace_domains, realtime_log_aggregations,
internal_emails.
- Most callers are already admin-backed; user-client readers of
workspace_secrets(in 9 apps/packages) move to a shared server helper that returns only the needed non-secret flags. - Keep the credential-filter rule: never filter by token values in PostgREST
URLs (
oauth-credential-url-filter.test.ts). platform_user_roleshas one browser reader; replace with a server-resolved capability.- Discord bot switches
discord_integrationstoschema("private").
Wave 2: billing, credits, finance
Tables: subscriptions, credit packs, orders,credit_wallets, ai_credit_*,
workspace_ai_credit_balances, workspace_ai_executions, fee_lock*,
finance_*, wallet_*, transaction_*, recurring_transactions,
workspace_wallet_transfers, workspace_role_wallet_whitelist,
currency_exchange_rates, products and stock, workforce_*, and the finance
views.
apps/financereads mostly on the user client; move those reads topackages/finance-core/packages/apisservices that authorize then use the admin client. Browser readers (finance_invoices,wallet_transactions, subscriptions, credit packs, orders) use internal-api routes.- The three
get_finance_invoice_*_by_workspacebrowser RPCs andget_user_workspace_subscription_infomove behind routes. - Payment webhooks (Polar, SePay) are already service-role; only the schema qualifier changes.
- Phase B for
wallet_transactionswaits for the M1 minimum-version gate.
Wave 3: mail, notifications, inbound messages
Tables:sent_emails, email_audit, email_blacklist, post_email_queue,
notifications, notification_preferences, notification_push_devices,
workspace_email_invites, workspace_email_invite_roles,
support_inquiries, user_feedbacks, group_users_with_post_checks.
- Remove
notificationsandnotification_preferencesfromsupabase_realtime; notification delivery is server-owned (packages/ui/src/hooks/notification-subscription.ts). - Email invite browser modules move to the invite routes shared with Wave 8.
Wave 4: people and identity PII
Tables:users, user_private_details, handles, onboarding_progress,
user_configs, workspace_users, workspace_user_*, user_group_*,
workspace_user_groups*, user_indicators, guest_users_lead_generation,
tulearn_parent_*, and the attendance/group views.
- Largest PII surface.
usersanduser_private_detailshave browser readers in shared UI (profile, settings, account switcher); serve them frompackages/users-coreroutes. - Auth triggers that write
users/user_private_detailson sign-up must be re-pinned and tested on the full replay with GoTrue fixtures. - Phase B for
user_private_detailswaits for the M1 gate. workspace_user_linked_usersis read by RLS policies on other tables; move its lookups into the helper schema first.
Wave 5: AI, meetings, memory content
Tables:ai_chat*, ai_model_favorites, workspace_ai_models,
workspace_ai_prompts, meet_ai_*, mira_*, audio_chunks,
recording_sessions, workspace_meetings, workspace_meet_settings,
hive_*, aurora_*, crawled_*, notes, workspace_documents,
workspace_whiteboards, workspace_dataset*, workspace_chat_*.
- Memory tables keep provenance, consent and deletion fences; the move changes location only.
- 15 tables have no application caller (
hive_*runtime tables, legacyworkspace_chat_*). Confirm withpg_dependand function-body scans; move them (not drop) in this wave, and propose drops separately.
Wave 6: tasks, time, calendar content
Tables:tasks, task_*, workspace_boards, board_template*,
workspace_task_*, user_board_list_overrides, time_tracking_*,
workspace_break_types, habit_*, workspace_habit*,
workspace_calendar_*, workspace_cron_*, calendar_event_colors.
- The held board-sprint migrations create
task_sprint_reports(recorded undertypesAhead) and any other sprint table inprivate; the sprint routes read them through.schema('private'). The guard fails apubliccreation. - Largest code surface (
apps/tasks,packages/tasks-api,packages/tasks-ui,apps/calendar,apps/track). Browser modules inapps/tasksandpackages/tasks-uimove to internal-api first. - Remove
workspace_task_labelsand other task tables fromsupabase_realtime; board updates use broadcast fan-out. - Task share links and
task_board_public_linksserve anonymous readers through server routes. - Discord bot switches boards, lists, tasks, assignees and time tracking.
Wave 7: education, external projects, public catalogs
Tables:course_*, workspace_course_*, workspace_quiz*, quiz_*,
workspace_flashcards, tulearn_*, canonical_external_projects,
workspace_external_project_*, discord_guild_members, meet_together_*,
poll*, shortened_links*, link_analytics*, workspace_link_counts,
changelog_entries, vietnamese_holidays.
- Anonymous readers (changelog, short-link redirects, Meet Together guests, polls, published external projects) get cached server endpoints. Short-link redirects keep their latency budget; verify on staging.
Wave 8: workspace core and RBAC
Tables:workspaces, workspace_members, workspace_members_and_invites,
workspace_invites, workspace_invite_*, workspace_guests,
workspace_guest_permissions, workspace_roles, workspace_role_*,
workspace_default_permissions, workspace_settings, workspace_configs,
user_workspace_configs, workspace_ownership_transfers, workspace_teams,
audit_logs.
- Every remaining client policy and storage policy depends on these. Move the
membership and permission helpers (including
has_workspace_permission, called from browser modules) to the helper schema before Phase B. - Phase B for the four mobile tables waits for the M1 gate.
- Run the full storage RLS suite and an exact-commit E2E pass on staging before approval.
Wave 9: functions and views sweep
- Every remaining
publicfunction either moves toprivateor is on the function allowlist with a reason. - The guard enables function enforcement and the relation allowlist is empty.
- Remove the private-first fallback helper callers; the guard then fails on any fallback use.
Approvals and review
- Security review (Selene) for: the guard spec and Wave 0 migration; each wave’s Phase B and C migrations, rollback migration and helper-schema changes; any allowlist addition. Review uses the exact migration SHA.
- User approval (D138) for every production database change. Batch to limit dialogs: Wave 0 default privileges (only if needed); then one dialog per batch of “Phase C of wave N + Phase B of wave N+1”. Each dialog states the tables, the exact SHA, the staging marker, the rollback migration and the evidence (pgTAP, HTTP denial, exact-commit CI).
- Batch migration merges per wave: one combined disposable rehearsal, back-to-back merges, one staging marker, one production sync.
- Production evidence: the
supabase-production.yamlexact-SHA result, a post-apply catalog check (tables inprivate, no client privileges), and a watch of 4xx/5xx rates on the affected routes. A skipped or failed workflow is a blocker.
Guard: no new public relations
Two layers share the allowlistapps/database/public-schema-allowlist.json:
Allowlist
relationsholds every application table and view inpublic(320), each tagged with its wave.typesAheadrecords relations the generated types declare ahead of their migration, each with an owner, wave, reason and hosted evidence. The types check accepts them; the catalog check fails if one appears inpublic, so the migration that creates it must useprivate. An entry can only narrow an allowlisted relation, and it becomes stale once the types drop it.- Moving a relation removes it from
relationsand records it inmoved({ "wave": n, "schema": "private" }). Moved records are permanent. serviceRoleCompatViewsentries carryexpiresAfterWaveandtarget: "private.<name>".defaultAclExemptOwnerslists default-ACL owners the migration role cannot alter, each with a reason; their client grants are reported as warnings.platformObjectsandclientViewExceptionsare shrink-only; the change that introduces either field may populate it.- The allowlist path is listed in
CODEOWNERSfor database and security owners.
Catalog checks (authoritative)
One read-only statement readspg_class, pg_depend and pg_default_acl
(extension-owned relations excluded) and fails on:
- G1, equality. Every application table and view in
publicis inrelationswith the matching kind, and every entry exists. NotypesAheadname exists inpublic. Everymovedname exists inprivateand not inpublic. - G2, exposure. Every
publictable has RLS enabled. No RLS-off table grantsanon,authenticatedorPUBLIC. Nopublicor global default ACL grants those roles on tables or sequences, or function EXECUTE toanonorPUBLIC. Default EXECUTE forauthenticatedis a warning untilfunctions.enforcedis true, then an error. Exempt owners warn. - F1, platform owners. Any
publicrelation or function owned by adefaultAclExemptOwnersrole is an error unless recorded inplatformObjects(relation:<name>orfunction:<name>(<args>), each with a reason). Stale records fail. - F2, client views. A
publicview granted to a client role must havesecurity_invoker=trueor a reasonedclientViewExceptionsentry. Stale entries fail. - G5, compat views. Each
serviceRoleCompatViewsentry exists as a plain view, grants no client role, reads only itstarget, and has not expired (expiresAfterWave≥currentWave).
Static checks
- Shrink-only (G3 fail closed). The allowlist is compared with the one at
the base:
PUBLIC_SCHEMA_BASE_SHA(CI pushes pass the previous main SHA), else the pull request base, else the merge-base withorigin/main. Adding a relation, function or exempt owner fails; removing a relation without amovedrecord fails;currentWavecannot decrease;lintAfterVersioncannot move later; function enforcement cannot be turned off. An unreadable base or base allowlist exits 2. The only exception is the introducing change, whose base has neither the allowlist nor the guard script. - Generated types. Every
publictable and view inpackages/types/src/supabase.tsis allowlisted with the matching kind. Absence from the types is not treated as staleness: committed types can lag the chain, so the catalog owns that direction. - Migration lint over migrations after
lintAfterVersion, comments removed. It fails on apublic(qualified, quoted or unqualified) target that is not allowlisted forCREATE [UNLOGGED] TABLE(includingPARTITION OFandAS),CREATE [MATERIALIZED|RECURSIVE] VIEW,CREATE FOREIGN TABLE,SELECT … INTO,SET SCHEMA publicandRENAME TO; on literal client-roleGRANTs onpublicrelations orALL TABLES IN SCHEMA public; and on client default privileges inpublic. Text inside dollar-quoted bodies is scanned for creation (EXECUTE 'create table …'). Temporary relations,search_path-qualified private targets and dynamic%Itargets are left to the catalog check. New public functions warn untilfunctions.enforced. - Direct client access to
movedrelations: any browser-module reference, any Dart.from()inapps/mobile/lib, any Python.table()inapps/discordwithoutschema("private"), and any TypeScript.from()not immediately chained from.schema('private').
Tests
scripts/check-public-schema-objects.test.js covers each statement kind,
quoting, comments, dollar-quoted bodies, temporary relations, search_path,
dynamic targets, grants and default privileges, function warnings, every
shrink rule, compat-view expiry, the caller rules, and fail-closed base
resolution in a temporary repository.
apps/database/scripts/public-schema-catalog.test.mjs covers G1, G2 and G5
on catalog fixtures and fail-closed output parsing.
Replay findings
The first full replay matched the allowlist except for three findings, all resolved in the allowlist:workspace_external_project_page_versionsis created inpublicby20261109010100and is missing from the committed types.task_sprint_reportsis declared in the types and has no migration. The production readback confirms it is absent there too, so it is recorded undertypesAhead.supabase_admindefault ACLs inpublicgrantanonandauthenticatedon tables, sequences and functions; the owner is exempt pending the hosted catalog result.
public table has RLS enabled. In the replay all 320 public
relations and 650 functions are owned by postgres, and all 26 client-granted
views use security_invoker, so platformObjects and clientViewExceptions
start empty. 254 public relations (228 tables and 26 views) still grant
client roles behind RLS or security_invoker; the waves remove those grants.
The production readback (2026-11-17) matches: 320 relations (293 tables and
27 views), all owned by postgres, no RLS-off tables, and the same client
grants relation for relation as the replay.
Appendix: table inventory
Counts are distinct apps or packages per caller class from the lexical scan.mobile and discord mark direct Flutter and Python access.
Wave 1: secrets, credentials and abuse controls (31)
Wave 1: secrets, credentials and abuse controls (31)
abuse_activity_signals (rls:1); abuse_events (rls:2, admin:2); abuse_reputation_subjects (rls:1);
abuse_step_up_challenges (rls:1, admin:1); abuse_trust_overrides (rls:1); blocked_ips (rls:2, admin:1);
calendar_auth_tokens (rls:4, admin:4); calendar_connections (rls:3, admin:4); calendar_sync_dashboard (rls:3,
admin:1); calendar_sync_states (no-ts-caller); discord_integrations (discord, rls:2, admin:2); internal_emails
(rls:1, admin:1); live_api_sessions (rls:1, admin:1); platform_email_roles (admin:2);
platform_entity_creation_limits (admin:1); platform_user_roles (browser:1, rls:3, admin:4); qr_login_challenges
(admin:4); rate_limit_appeals (rls:1, admin:1); realtime_log_aggregations (rls:1); sepay_connections (rls:2,
admin:2); sepay_wallet_links (admin:2); sepay_webhook_endpoints (rls:2, admin:2); sepay_webhook_events (admin:2);
user_suspensions (admin:2); workspace_api_key_usage_logs (rls:2, admin:3); workspace_api_keys (rls:2, admin:4);
workspace_calendar_sync_coordination (browser:1); workspace_domains (rls:1); workspace_email_credentials (rls:4,
admin:4); workspace_encryption_keys (admin:8); workspace_secrets (rls:9, admin:17).Wave 2: billing, credits and finance (41)
Wave 2: billing, credits and finance (41)
ai_credit_feature_access (rls:1); ai_credit_plan_allocations (rls:2, admin:5); ai_credit_transactions (rls:4,
admin:2); credit_wallets (rls:1); currency_exchange_rates (rls:1, admin:3); distinct_invoice_creators (view,
no-ts-caller); distinct_transaction_creators (view, rls:1); fee_lock_events (rls:1); fee_lock_invoice_links
(rls:1); fee_lock_lines (rls:1); fee_lock_revisions (rls:1); fee_locks (rls:1); fee_notice_templates (rls:1);
finance_budgets (rls:1); finance_invoice_products (rls:2, admin:4); finance_invoice_promotions (rls:1, admin:3);
finance_invoice_user_groups (rls:1); finance_invoices (browser:1, rls:3, admin:8); product_categories (rls:3,
admin:4); product_stock_changes (rls:4, admin:2); recurring_transactions (rls:1); transaction_categories (rls:7,
admin:6); transaction_tags (rls:2, admin:2); user_group_linked_products (rls:1, admin:3); wallet_interest_configs
(rls:1); wallet_interest_rates (rls:1); wallet_transaction_tags (rls:1, admin:4); wallet_transactions (mobile,
browser:1, rls:4, admin:7); wallet_transactions_secure (view, no-ts-caller); wallet_types (no-ts-caller);
workforce_benefits (no-ts-caller); workforce_compensation (no-ts-caller); workforce_contracts (rls:1);
workspace_ai_credit_balances (rls:1, admin:1); workspace_ai_executions (admin:3); workspace_credit_pack_purchases
(browser:1, rls:1, admin:1); workspace_orders (browser:1, rls:1); workspace_products (rls:4, admin:4);
workspace_role_wallet_whitelist (rls:2, admin:1); workspace_subscriptions (browser:3, rls:3, admin:5);
workspace_wallet_transfers (rls:1, admin:2).Wave 3: mail, notifications and inbound messages (12)
Wave 3: mail, notifications and inbound messages (12)
email_audit (browser:1, rls:3, admin:3); email_blacklist (browser:1, rls:3, admin:1); group_users_with_post_checks
(view, no-ts-caller); notification_preferences (rls:1, admin:1); notification_push_devices (rls:1, admin:2);
notifications (rls:2, admin:2); post_email_queue (rls:3, admin:3); sent_emails (rls:3, admin:3);
support_inquiries (admin:3); user_feedbacks (rls:1, admin:3); workspace_email_invite_roles (no-ts-caller);
workspace_email_invites (browser:2, rls:4, admin:2).Wave 4: people and identity PII (29)
Wave 4: people and identity PII (29)
group_user_with_attendance (view, no-ts-caller); group_with_attendance (view, no-ts-caller);
guest_users_lead_generation (no-ts-caller); handles (no-ts-caller); onboarding_progress (browser:1, rls:1,
admin:1); tulearn_parent_invites (rls:1); tulearn_parent_student_links (rls:1, admin:2); user_configs (admin:3);
user_group_attendance (rls:3, admin:4); user_group_metrics (rls:2, admin:4); user_groups_with_tags (view,
no-ts-caller); user_indicators (rls:1, admin:5); user_private_details (mobile, browser:6, rls:12, admin:11); users
(browser:5, rls:10, admin:13); workspace_default_included_user_groups (no-ts-caller); workspace_user_fields
(admin:2); workspace_user_group_tag_groups (rls:1, admin:3); workspace_user_group_tags (rls:3, admin:3);
workspace_user_groups (rls:5, admin:10); workspace_user_groups_users (rls:5, admin:5);
workspace_user_groups_with_amount (view, admin:1); workspace_user_groups_with_guest (view, admin:2);
workspace_user_linked_users (rls:11, admin:10); workspace_user_profile_link_submissions (admin:1);
workspace_user_profile_links (admin:1); workspace_user_profile_links_with_stats (view, admin:1);
workspace_user_status_changes (admin:3); workspace_users (browser:1, rls:9, admin:8); workspace_users_with_groups
(view, no-ts-caller).Wave 5: AI, meetings and memory content (50)
Wave 5: AI, meetings and memory content (50)
ai_chat_messages (rls:3, admin:5); ai_chats (browser:1, rls:4, admin:4); ai_model_favorites (rls:1);
audio_chunks (admin:1); aurora_ml_forecast (admin:1); aurora_ml_metrics (admin:1); aurora_statistical_forecast
(admin:1); aurora_statistical_metrics (admin:1); crawled_url_next_urls (rls:1, admin:2); crawled_urls (rls:1,
admin:2); entity_limit_source__workspace_whiteboards (view, no-ts-caller); hive_members (admin:2);
hive_npc_memories (no-ts-caller); hive_npc_runs (no-ts-caller); hive_npcs (no-ts-caller);
hive_research_session_events (no-ts-caller); hive_research_sessions (no-ts-caller); hive_servers (no-ts-caller);
hive_workflow_runs (no-ts-caller); hive_workflows (no-ts-caller); hive_world_events (no-ts-caller);
hive_world_states (no-ts-caller); meet_ai_chunks (rls:1, admin:1); meet_ai_memories (admin:1); meet_ai_sessions
(rls:1, admin:1); meet_ai_user_preferences (admin:1); mira_daily_stats (rls:2, admin:1); mira_focus_sessions
(rls:1, admin:1); mira_memories (admin:1); mira_pets (rls:2, admin:1); mira_soul (rls:2); mira_user_accessories
(admin:1); mira_user_achievements (admin:1); notes (rls:2, admin:2); recording_sessions (rls:1, admin:1);
workspace_ai_models (rls:2, admin:2); workspace_ai_prompts (rls:1, admin:2); workspace_chat_channels
(no-ts-caller); workspace_chat_messages (no-ts-caller); workspace_chat_participants (no-ts-caller);
workspace_chat_typing_indicators (no-ts-caller); workspace_dataset_cells (rls:2); workspace_dataset_columns
(rls:2, admin:1); workspace_dataset_row_cells (view, rls:2); workspace_dataset_rows (rls:2, admin:1);
workspace_datasets (rls:2, admin:2); workspace_documents (rls:2, admin:2); workspace_meet_settings (no-ts-caller);
workspace_meetings (rls:2, admin:4); workspace_whiteboards (rls:1, admin:1).Wave 6: tasks, time and calendar content (77)
Wave 6: tasks, time and calendar content (77)
board_template_shares (rls:2); board_templates (browser:1, rls:3, admin:3); calendar_event_colors (no-ts-caller);
entity_limit_source__tasks (view, no-ts-caller); habit_calendar_events (rls:3, admin:2); habit_completions (rls:3,
admin:1); habit_skipped_occurrences (rls:3); task_assignees (discord, browser:1, rls:4, admin:3);
task_board_public_links (admin:1); task_board_shares (browser:1, rls:4, admin:4); task_board_status_templates
(admin:1); task_calendar_events (browser:1, rls:3, admin:3); task_capacity_rule_labels (no-ts-caller);
task_capacity_rule_lists (no-ts-caller); task_capacity_rule_projects (no-ts-caller); task_capacity_rules (rls:1);
task_cycle_tasks (admin:1); task_cycles (rls:2, admin:1); task_drafts (rls:1, admin:1); task_history (rls:1,
admin:1); task_initiatives (admin:2); task_labels (browser:1, rls:2, admin:2); task_leaderboard_members (rls:1,
admin:1); task_leaderboard_teams (rls:1); task_leaderboards (rls:1); task_lists (discord, browser:2, rls:5,
admin:5); task_plan_items (rls:1); task_plan_shares (rls:1); task_plan_workspaces (rls:1, admin:1); task_plans
(rls:1, admin:1); task_profile_progress_settings (no-ts-caller); task_progress_achievements (rls:1, admin:1);
task_progress_entries (rls:1, admin:1); task_progress_goals (rls:1, admin:1); task_progress_metrics (rls:1,
admin:1); task_progress_user_achievements (rls:1, admin:1); task_progress_user_stats (admin:1);
task_project_initiatives (admin:1); task_project_tasks (browser:1, rls:2, admin:2);
task_project_update_attachments (rls:1); task_project_update_comments (rls:1, admin:1);
task_project_update_reactions (rls:1); task_project_updates (rls:1, admin:1); task_projects (browser:1, rls:3,
admin:5); task_relationships (rls:1, admin:1); task_share_link_uses (admin:1); task_share_links (rls:1, admin:1);
task_shares (rls:1, admin:1); task_sprint_reports (rls:1); task_templates (no-ts-caller);
task_user_override_labels (rls:1); task_user_override_projects (rls:1); task_user_overrides (rls:3, admin:2);
task_user_scheduling_settings (browser:2, rls:3, admin:3); task_watchers (no-ts-caller); tasks (discord,
browser:3, rls:6, admin:4); time_tracker_daily_activity (view, no-ts-caller); time_tracking_breaks (rls:2, admin:3);
time_tracking_categories (rls:4, admin:2); time_tracking_goals (rls:2, admin:2); time_tracking_session_analytics
(view, no-ts-caller); time_tracking_sessions (discord, rls:4, admin:4); user_board_list_overrides (rls:1, admin:1);
workspace_boards (discord, browser:3, rls:4, admin:3); workspace_break_types (rls:2, admin:2);
workspace_calendar_categories (admin:1); workspace_calendar_events (browser:1, rls:6, admin:10);
workspace_calendar_hour_settings (rls:3); workspace_cron_executions (rls:1); workspace_cron_jobs (rls:1, admin:2);
workspace_habit_tracker_entries (rls:1); workspace_habit_tracker_entry_receipts (no-ts-caller);
workspace_habit_tracker_streak_actions (rls:1); workspace_habit_trackers (rls:1); workspace_habits (rls:3,
admin:4); workspace_task_labels (browser:1, rls:3, admin:3); workspace_task_reminder_settings (admin:1).Wave 7: education, external projects and public catalogs (59)
Wave 7: education, external projects and public catalogs (59)
canonical_external_projects (rls:2, admin:3); changelog_entries (rls:2, admin:2); course_certificates
(no-ts-caller); course_module_completion_status (rls:1, admin:1); course_module_flashcards (rls:1, admin:3);
course_module_quiz_sets (rls:1, admin:3); course_module_quiz_submissions (rls:2, admin:2); course_module_quizzes
(rls:2, admin:3); course_test_attempt_answers (rls:1); course_test_attempts (rls:1, admin:1); course_test_modules
(no-ts-caller); course_test_quizzes (rls:2); course_tests (rls:1, admin:1); discord_guild_members (discord,
rls:3); link_analytics (admin:2); link_analytics_device_insights (view, no-ts-caller); link_analytics_geo_insights
(view, no-ts-caller); link_analytics_summary (view, admin:1); meet_together_finalized_timeframes (admin:1);
meet_together_guest_timeblocks (admin:3); meet_together_guests (rls:1, admin:1); meet_together_plans (discord,
rls:1, admin:4); meet_together_user_timeblocks (admin:3); meet_together_users (view, admin:2); poll_guest_votes
(admin:3); poll_options (admin:3); poll_user_votes (admin:3); polls (admin:3); quiz_options (rls:1, admin:2);
quiz_set_quizzes (rls:1, admin:1); shortened_links (discord, admin:3); shortened_links_creator_stats (view,
admin:1); shortened_links_domain_stats (view, admin:1); tulearn_gamification_events (no-ts-caller);
tulearn_learner_state (admin:1); vietnamese_holidays (rls:2); workspace_course_module_groups (rls:1, admin:1);
workspace_course_modules (browser:2, rls:2, admin:3); workspace_external_project_assets (rls:1, admin:3);
workspace_external_project_binding_audits (rls:2, admin:3); workspace_external_project_bindings (rls:2, admin:3);
workspace_external_project_blocks (admin:3); workspace_external_project_collections (admin:3);
workspace_external_project_entries (rls:1, admin:3); workspace_external_project_entry_placements (no-ts-caller);
workspace_external_project_entry_relations (admin:3); workspace_external_project_entry_taxonomy_assignments
(no-ts-caller); workspace_external_project_field_definitions (admin:2); workspace_external_project_import_jobs
(admin:2); workspace_external_project_publish_events (admin:2);
workspace_external_project_relation_definition_targets (admin:2); workspace_external_project_relation_definitions
(admin:2); workspace_external_project_taxonomies (no-ts-caller); workspace_flashcards (rls:1, admin:3);
workspace_link_counts (view, admin:1); workspace_quiz_attempt_answers (rls:1, admin:1); workspace_quiz_attempts
(rls:1, admin:1); workspace_quiz_sets (rls:1, admin:1); workspace_quizzes (rls:2, admin:3).Wave 8: workspace core and RBAC (21)
Wave 8: workspace core and RBAC (21)
audit_logs (view, no-ts-caller); entity_limit_source__workspaces (view, no-ts-caller); user_workspace_configs
(rls:3, admin:1); workspace_configs (rls:9, admin:10); workspace_default_permissions (mobile, browser:1, rls:3,
admin:4); workspace_guest_permissions (admin:1); workspace_guests (admin:1); workspace_invite_link_uses (admin:1);
workspace_invite_links (admin:1); workspace_invite_links_with_stats (view, admin:1); workspace_invite_roles
(no-ts-caller); workspace_invites (browser:2, rls:4, admin:2); workspace_members (mobile, discord, browser:3,
rls:13, admin:12); workspace_members_and_invites (view, browser:1, rls:3, admin:1); workspace_ownership_transfers
(no-ts-caller); workspace_role_members (mobile, browser:1, rls:4, admin:3); workspace_role_permissions (rls:1,
admin:2); workspace_roles (rls:1, admin:2); workspace_settings (rls:6, admin:4); workspace_teams (no-ts-caller);
workspaces (mobile, browser:7, rls:16, admin:23).