auth/cell_grant_audit_metadata.ts view source
value + type
{ cell_id: Branded<string, "Uuid">; level: "viewer" | "editor"; principal: ({ actor_id: Branded<string, "Uuid">; } & Record<string, unknown>) | ({ role: string; scope_id: Branded<...> | null; } & Record<...>); grant_id: Branded<...>; } & Record<...> type { cell_id: Branded<string, "Uuid">; level: "viewer" | "editor"; principal: ({ actor_id: Branded<string, "Uuid">; } & Record<string, unknown>) | ({ role: string; scope_id: Branded<string, "Uuid"> | null; } & Record<string, unknown>); grant_id: Branded<string, "Uuid">; } & Record<string, unknown>
import {CellGrantCreateAuditMetadata} from '@fuzdev/fuz_app/auth/cell_grant_audit_metadata.js'; Metadata envelope for cell_grant_create.
Emitted on every successful create OR re-share update path
(UPSERT-on-unique-index). The audit reader correlates create-vs-update
via grant_id if needed; the design doesn't require distinguishing
the two at the metadata level.
cell_id
type Branded
level
type "viewer" | "editor"
principal
grant_id
type Branded
[key: string]
type unknown