v0.13.0
Minor Changes
-
Schema authoring: split model routing into two orthogonal axes —
policy(row access) andgroups(sync-group routing).Breaking (schema authoring). The flat, collision-prone model options are replaced by two namespaced ones:
policy— row-access / tenant isolation (named after Postgres/Supabase RLS policies: the rule that scopes which rows a tenant may read). A discriminated union onbyreplaces the oldorgScoped/scopedVia/orgColumntrio:{ by: 'column' }— row-local tenancy column (the default when omitted; column name still overridable).{ by: 'parent', fk, parent }— inherit tenancy through a foreign key when the table has no tenancy column of its own (e.g.slide_layers→slides).- Type
TenancyInputis renamedPolicyInput;policyInputSchema/resolvePolicyare now exported.
groups: { root, grants, roles }— which delta channels a row fans into (orthogonal topolicy, which governs read access). One namespaced object replaces the old flatscope/grants/entityRoles:root(wasscope) — mark a model a scope root; its records form the group<kind>:<id>. Renamed so it no longer collides with the oldscopedViatenancy sugar or the innergrants.scoperelation name.grants— a membership edge granting an identity access to a scope root.roles(wasentityRoles) — explicit non-relational record→group roles; accepts one role or an array.groupsInputSchema/GroupsInputare now exported.
CLI.
config.jsonnow stores per-project profile key pairs (profiles: Record<string, ProfileKeys>) instead of a single top-level pair; older flat layouts are folded into the active profile automatically on read, so existing logins keep working.login/projectsupdated to the profile model.