auth/cell_audit_events.ts

Canonical cell-layer audit event registry.

Maps every cell-domain event_type a cell handler emits to its metadata schema. Consumers register the whole bundle in one shot via create_audit_log_config({extra_events: {...cell_audit_events, ...}}) so the cell handlers' deps.audit.emit(...) calls validate against the extended registry. Spreading lets an app fold its own event types in alongside.

Aggregator module by design — not a compat shim. The per-event metadata schemas live in their own files (auth/cell_audit_metadata.ts, auth/cell_grant_audit_metadata.ts, auth/cell_field_audit_metadata.ts, auth/cell_item_audit_metadata.ts); this module is the single registration surface that keeps the keys in lockstep with the handlers.

view source

Declarations
#

cell_audit_events
#

auth/cell_audit_events.ts view source

Readonly<Record<string, ZodType<unknown, unknown, $ZodTypeInternals<unknown, unknown>>>> import {cell_audit_events} from '@fuzdev/fuz_app/auth/cell_audit_events.js';

Cell-layer event_type → metadata schema map for extra_events.

Covers the seven generic cell verbs' mutation events plus the grant / field / item relation events. Read-only verbs (cell_get, cell_list, cell_*_list, cell_audit_list) emit nothing and are absent here.

Depends on
#